diff --git a/java-accessapproval/README.md b/java-accessapproval/README.md index 6b963e60ae1f..af62c4be7737 100644 --- a/java-accessapproval/README.md +++ b/java-accessapproval/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-accessapproval - 2.103.0 + 2.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-accessapproval' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-accessapproval:2.103.0' +implementation 'com.google.cloud:google-cloud-accessapproval:2.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-accessapproval" % "2.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-accessapproval" % "2.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-accessapproval/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-accessapproval.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-accessapproval/2.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-accessapproval/2.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-accesscontextmanager/README.md b/java-accesscontextmanager/README.md index eb5b11fcaa42..fa778f5fb073 100644 --- a/java-accesscontextmanager/README.md +++ b/java-accesscontextmanager/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-identity-accesscontextmanager - 1.103.0 + 1.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-identity-accesscontextmanager' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-identity-accesscontextmanager:1.103.0' +implementation 'com.google.cloud:google-identity-accesscontextmanager:1.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-identity-accesscontextmanager" % "1.103.0" +libraryDependencies += "com.google.cloud" % "google-identity-accesscontextmanager" % "1.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-identity-accesscontextmanager/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-identity-accesscontextmanager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-identity-accesscontextmanager/1.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-identity-accesscontextmanager/1.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-admanager/README.md b/java-admanager/README.md index beeb0a931990..e506d16b3897 100644 --- a/java-admanager/README.md +++ b/java-admanager/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.api-ads ad-manager - 0.61.0 + 0.62.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.api-ads:ad-manager:0.61.0' +implementation 'com.google.api-ads:ad-manager:0.62.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.api-ads" % "ad-manager" % "0.61.0" +libraryDependencies += "com.google.api-ads" % "ad-manager" % "0.62.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/ad-manager/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.api-ads/ad-manager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.api-ads/ad-manager/0.61.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.api-ads/ad-manager/0.62.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-advisorynotifications/README.md b/java-advisorynotifications/README.md index ed395eb6e320..4d79068949ee 100644 --- a/java-advisorynotifications/README.md +++ b/java-advisorynotifications/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-advisorynotifications - 0.91.0 + 0.92.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-advisorynotifications' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-advisorynotifications:0.91.0' +implementation 'com.google.cloud:google-cloud-advisorynotifications:0.92.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-advisorynotifications" % "0.91.0" +libraryDependencies += "com.google.cloud" % "google-cloud-advisorynotifications" % "0.92.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-advisorynotifications/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-advisorynotifications.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-advisorynotifications/0.91.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-advisorynotifications/0.92.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-agentidentity/README.md b/java-agentidentity/README.md index 12057602bcda..4cded7678d53 100644 --- a/java-agentidentity/README.md +++ b/java-agentidentity/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-agentidentity - 0.8.0 + 0.9.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-agentidentity' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-agentidentity:0.8.0' +implementation 'com.google.cloud:google-cloud-agentidentity:0.9.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-agentidentity" % "0.8.0" +libraryDependencies += "com.google.cloud" % "google-cloud-agentidentity" % "0.9.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-agentidentity/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-agentidentity.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-agentidentity/0.8.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-agentidentity/0.9.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-agentregistry/README.md b/java-agentregistry/README.md index b79f5dd6baec..53831757a9d1 100644 --- a/java-agentregistry/README.md +++ b/java-agentregistry/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-agentregistry - 0.9.0 + 0.10.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-agentregistry' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-agentregistry:0.9.0' +implementation 'com.google.cloud:google-cloud-agentregistry:0.10.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-agentregistry" % "0.9.0" +libraryDependencies += "com.google.cloud" % "google-cloud-agentregistry" % "0.10.0" ``` ## Authentication @@ -188,7 +188,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-agentregistry/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-agentregistry.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-agentregistry/0.9.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-agentregistry/0.10.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryClient.java b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryClient.java index 51ef4d4cb78d..70fa58b0a8ce 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryClient.java +++ b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryClient.java @@ -47,7 +47,7 @@ // AUTO-GENERATED DOCUMENTATION AND CLASS. /** - * Service Description: Service for managing Agents, Endpoints, McpServers, Services, and Bindings. + * Service Description: Service for managing Agent Registry resources. * *

This class provides the ability to make remote calls to the backing service through method * calls that map to API methods. Sample code to get started: @@ -59,7 +59,7 @@ * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * AgentName name = AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]"); + * AgentName name = AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]"); * Agent response = agentRegistryClient.getAgent(name); * } * } @@ -448,294 +448,4232 @@ * * * - *

ListLocations - *

Lists information about the supported locations for this service. - *

This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. - *

For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. + *

CreateSkill + *

========================================================================= # Skills Collection APIs + *

Creates a Skill resource container, optionally publishing the initial SkillRevision inline in a single, atomic CRUD roundtrip. * *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

* + *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ * *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

* * * * - *

GetLocation - *

Gets information about a location. + *

GetSkill + *

Fetches the active configuration and metadata of a Skill. * *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

* + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

* * * - * - * - *

See the individual methods for example code. - * - *

Many parameters require resource names to be formatted in a particular way. To assist with - * these names, this class includes a format method for each type of name, and additionally a parse - * method to extract the individual identifiers contained within names that are returned. - * - *

This class can be customized by passing in a custom instance of AgentRegistrySettings to - * create(). For example: - * - *

To customize credentials: - * - *

{@code
- * // This snippet has been automatically generated and should be regarded as a code template only.
- * // It will require modifications to work:
- * // - It may require correct/in-range values for request initialization.
- * // - It may require specifying regional endpoints when creating the service client as shown in
- * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
- * AgentRegistrySettings agentRegistrySettings =
- *     AgentRegistrySettings.newBuilder()
- *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
- *         .build();
- * AgentRegistryClient agentRegistryClient = AgentRegistryClient.create(agentRegistrySettings);
- * }
- * - *

To customize the endpoint: - * - *

{@code
- * // This snippet has been automatically generated and should be regarded as a code template only.
- * // It will require modifications to work:
- * // - It may require correct/in-range values for request initialization.
- * // - It may require specifying regional endpoints when creating the service client as shown in
- * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
- * AgentRegistrySettings agentRegistrySettings =
- *     AgentRegistrySettings.newBuilder().setEndpoint(myEndpoint).build();
- * AgentRegistryClient agentRegistryClient = AgentRegistryClient.create(agentRegistrySettings);
- * }
- * - *

To use REST (HTTP1.1/JSON) transport (instead of gRPC) for sending and receiving requests over - * the wire: - * - *

{@code
- * // This snippet has been automatically generated and should be regarded as a code template only.
- * // It will require modifications to work:
- * // - It may require correct/in-range values for request initialization.
- * // - It may require specifying regional endpoints when creating the service client as shown in
- * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
- * AgentRegistrySettings agentRegistrySettings =
- *     AgentRegistrySettings.newHttpJsonBuilder().build();
- * AgentRegistryClient agentRegistryClient = AgentRegistryClient.create(agentRegistrySettings);
- * }
- * - *

Please refer to the GitHub repository's samples for more quickstart code snippets. - */ -@NullMarked -@Generated("by gapic-generator-java") -public class AgentRegistryClient implements BackgroundResource { - private final @Nullable AgentRegistrySettings settings; - private final AgentRegistryStub stub; - private final OperationsClient httpJsonOperationsClient; - private final com.google.longrunning.OperationsClient operationsClient; - - /** Constructs an instance of AgentRegistryClient with default settings. */ - public static final AgentRegistryClient create() throws IOException { - return create(AgentRegistrySettings.newBuilder().build()); - } - - /** - * Constructs an instance of AgentRegistryClient, using the given settings. The channels are - * created based on the settings passed in, or defaults for any settings that are not set. - */ - public static final AgentRegistryClient create(AgentRegistrySettings settings) - throws IOException { - return new AgentRegistryClient(settings); - } - - /** - * Constructs an instance of AgentRegistryClient, using the given stub for making calls. This is - * for advanced usage - prefer using create(AgentRegistrySettings). - */ - public static final AgentRegistryClient create(AgentRegistryStub stub) { - return new AgentRegistryClient(stub); - } - - /** - * Constructs an instance of AgentRegistryClient, using the given settings. This is protected so - * that it is easy to make a subclass, but otherwise, the static factory methods should be - * preferred. - */ - protected AgentRegistryClient(AgentRegistrySettings settings) throws IOException { - this.settings = settings; - this.stub = ((AgentRegistryStubSettings) settings.getStubSettings()).createStub(); - this.operationsClient = - com.google.longrunning.OperationsClient.create(this.stub.getOperationsStub()); - this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); - } - - protected AgentRegistryClient(AgentRegistryStub stub) { - this.settings = null; - this.stub = stub; - this.operationsClient = - com.google.longrunning.OperationsClient.create(this.stub.getOperationsStub()); - this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); - } - - public final @Nullable AgentRegistrySettings getSettings() { - return settings; - } - - public AgentRegistryStub getStub() { - return stub; - } - - /** - * Returns the OperationsClient that can be used to query the status of a long-running operation - * returned by another API method call. - */ - public final com.google.longrunning.OperationsClient getOperationsClient() { - return operationsClient; - } - - /** - * Returns the OperationsClient that can be used to query the status of a long-running operation - * returned by another API method call. - */ - @BetaApi - public final OperationsClient getHttpJsonOperationsClient() { - return httpJsonOperationsClient; - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists Agents in a given project and location. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
-   *   for (Agent element : agentRegistryClient.listAgents(parent).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param parent Required. Parent value for ListAgentsRequest - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListAgentsPagedResponse listAgents(@Nullable LocationName parent) { - ListAgentsRequest request = - ListAgentsRequest.newBuilder().setParent(parent == null ? null : parent.toString()).build(); - return listAgents(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists Agents in a given project and location. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
-   *   for (Agent element : agentRegistryClient.listAgents(parent).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param parent Required. Parent value for ListAgentsRequest - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListAgentsPagedResponse listAgents(String parent) { - ListAgentsRequest request = ListAgentsRequest.newBuilder().setParent(parent).build(); - return listAgents(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists Agents in a given project and location. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   ListAgentsRequest request =
-   *       ListAgentsRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .setFilter("filter-1274492040")
-   *           .setOrderBy("orderBy-1207110587")
-   *           .build();
-   *   for (Agent element : agentRegistryClient.listAgents(request).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListAgentsPagedResponse listAgents(ListAgentsRequest request) { - return listAgentsPagedCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists Agents in a given project and location. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   ListAgentsRequest request =
-   *       ListAgentsRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setPageSize(883849137)
+ *    
+ *      

UpdateSkill + *

Updates Skill metadata or overrides active pointers/state using REST standard PATCH. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

DeleteSkill + *

Deletes a Skill container along with all its revisions. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

ListSkills + *

Lists logical Skills available in a project. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

SearchSkills + *

Custom deep-search method to filter by frontmatter or query SKILL.md text blobs. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

CreateSkillRevision + *

Creates a new immutable revision and triggers validation pipelines. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

GetSkillRevision + *

Gets details of a single immutable Revision. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

DeleteSkillRevision + *

Deletes a specific revision (restricted to admins to purge accidentally committed secrets). + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

ListSkillRevisions + *

Lists all revisions belonging to a parent Skill. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

GetPublisher + *

Fetches details of a specific Publisher. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

ListPublishers + *

Lists all Publishers in a location. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

GetAiApplication + *

Gets details of a single AI Application. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

ListAiApplications + *

Lists AI Applications in a given project and location. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

GetAiApplicationAgent + *

Gets details of a single Agent under an AI Application. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

ListAiApplicationAgents + *

Lists Agents under an AI Application. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

GetAiApplicationMcpServer + *

Gets details of a single McpServer under an AI Application. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

ListAiApplicationMcpServers + *

Lists McpServers under an AI Application. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

GetFinding + *

Gets details of a single Finding. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

ListFindings + *

Lists Findings in a given project and location. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

GetAiApplicationEndpoint + *

Gets details of a single Endpoint under an AI Application. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

ListAiApplicationEndpoints + *

Lists Endpoints under an AI Application. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

GetSkillEncryptionSpec + *

========================================================================= # Skill Encryption Spec Service Methods + *

Gets the customer-managed encryption key (CMEK) configuration for Skills in a specific project and location. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

UpdateSkillEncryptionSpec + *

Updates the customer-managed encryption key (CMEK) configuration for Skills in a specific project and location. + *

This method is only allowed when no Skills exist in the target project and location. If any Skill already exists in the location, the request fails with `FAILED_PRECONDITION`. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

ListLocations + *

Lists information about the supported locations for this service. + *

This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + *

GetLocation + *

Gets information about a location. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * + * + * + *

See the individual methods for example code. + * + *

Many parameters require resource names to be formatted in a particular way. To assist with + * these names, this class includes a format method for each type of name, and additionally a parse + * method to extract the individual identifiers contained within names that are returned. + * + *

This class can be customized by passing in a custom instance of AgentRegistrySettings to + * create(). For example: + * + *

To customize credentials: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * AgentRegistrySettings agentRegistrySettings =
+ *     AgentRegistrySettings.newBuilder()
+ *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ *         .build();
+ * AgentRegistryClient agentRegistryClient = AgentRegistryClient.create(agentRegistrySettings);
+ * }
+ * + *

To customize the endpoint: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * AgentRegistrySettings agentRegistrySettings =
+ *     AgentRegistrySettings.newBuilder().setEndpoint(myEndpoint).build();
+ * AgentRegistryClient agentRegistryClient = AgentRegistryClient.create(agentRegistrySettings);
+ * }
+ * + *

To use REST (HTTP1.1/JSON) transport (instead of gRPC) for sending and receiving requests over + * the wire: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * AgentRegistrySettings agentRegistrySettings =
+ *     AgentRegistrySettings.newHttpJsonBuilder().build();
+ * AgentRegistryClient agentRegistryClient = AgentRegistryClient.create(agentRegistrySettings);
+ * }
+ * + *

Please refer to the GitHub repository's samples for more quickstart code snippets. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class AgentRegistryClient implements BackgroundResource { + private final @Nullable AgentRegistrySettings settings; + private final AgentRegistryStub stub; + private final OperationsClient httpJsonOperationsClient; + private final com.google.longrunning.OperationsClient operationsClient; + + /** Constructs an instance of AgentRegistryClient with default settings. */ + public static final AgentRegistryClient create() throws IOException { + return create(AgentRegistrySettings.newBuilder().build()); + } + + /** + * Constructs an instance of AgentRegistryClient, using the given settings. The channels are + * created based on the settings passed in, or defaults for any settings that are not set. + */ + public static final AgentRegistryClient create(AgentRegistrySettings settings) + throws IOException { + return new AgentRegistryClient(settings); + } + + /** + * Constructs an instance of AgentRegistryClient, using the given stub for making calls. This is + * for advanced usage - prefer using create(AgentRegistrySettings). + */ + public static final AgentRegistryClient create(AgentRegistryStub stub) { + return new AgentRegistryClient(stub); + } + + /** + * Constructs an instance of AgentRegistryClient, using the given settings. This is protected so + * that it is easy to make a subclass, but otherwise, the static factory methods should be + * preferred. + */ + protected AgentRegistryClient(AgentRegistrySettings settings) throws IOException { + this.settings = settings; + this.stub = ((AgentRegistryStubSettings) settings.getStubSettings()).createStub(); + this.operationsClient = + com.google.longrunning.OperationsClient.create(this.stub.getOperationsStub()); + this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); + } + + protected AgentRegistryClient(AgentRegistryStub stub) { + this.settings = null; + this.stub = stub; + this.operationsClient = + com.google.longrunning.OperationsClient.create(this.stub.getOperationsStub()); + this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); + } + + public final @Nullable AgentRegistrySettings getSettings() { + return settings; + } + + public AgentRegistryStub getStub() { + return stub; + } + + /** + * Returns the OperationsClient that can be used to query the status of a long-running operation + * returned by another API method call. + */ + public final com.google.longrunning.OperationsClient getOperationsClient() { + return operationsClient; + } + + /** + * Returns the OperationsClient that can be used to query the status of a long-running operation + * returned by another API method call. + */ + @BetaApi + public final OperationsClient getHttpJsonOperationsClient() { + return httpJsonOperationsClient; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Agents in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Agent element : agentRegistryClient.listAgents(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. Parent value for ListAgentsRequest + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAgentsPagedResponse listAgents(@Nullable LocationName parent) { + ListAgentsRequest request = + ListAgentsRequest.newBuilder().setParent(parent == null ? null : parent.toString()).build(); + return listAgents(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Agents in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Agent element : agentRegistryClient.listAgents(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. Parent value for ListAgentsRequest + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAgentsPagedResponse listAgents(String parent) { + ListAgentsRequest request = ListAgentsRequest.newBuilder().setParent(parent).build(); + return listAgents(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Agents in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListAgentsRequest request =
+   *       ListAgentsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   for (Agent element : agentRegistryClient.listAgents(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAgentsPagedResponse listAgents(ListAgentsRequest request) { + return listAgentsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Agents in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListAgentsRequest request =
+   *       ListAgentsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.listAgentsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Agent element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listAgentsPagedCallable() { + return stub.listAgentsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Agents in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListAgentsRequest request =
+   *       ListAgentsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   while (true) {
+   *     ListAgentsResponse response = agentRegistryClient.listAgentsCallable().call(request);
+   *     for (Agent element : response.getAgentsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listAgentsCallable() { + return stub.listAgentsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Searches Agents in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Agent element : agentRegistryClient.searchAgents(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. Parent value for SearchAgentsRequest. Format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SearchAgentsPagedResponse searchAgents(@Nullable LocationName parent) { + SearchAgentsRequest request = + SearchAgentsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return searchAgents(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Searches Agents in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Agent element : agentRegistryClient.searchAgents(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. Parent value for SearchAgentsRequest. Format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SearchAgentsPagedResponse searchAgents(String parent) { + SearchAgentsRequest request = SearchAgentsRequest.newBuilder().setParent(parent).build(); + return searchAgents(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Searches Agents in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   SearchAgentsRequest request =
+   *       SearchAgentsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setSearchString("searchString120312793")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (Agent element : agentRegistryClient.searchAgents(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SearchAgentsPagedResponse searchAgents(SearchAgentsRequest request) { + return searchAgentsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Searches Agents in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   SearchAgentsRequest request =
+   *       SearchAgentsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setSearchString("searchString120312793")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.searchAgentsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Agent element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + searchAgentsPagedCallable() { + return stub.searchAgentsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Searches Agents in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   SearchAgentsRequest request =
+   *       SearchAgentsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setSearchString("searchString120312793")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     SearchAgentsResponse response = agentRegistryClient.searchAgentsCallable().call(request);
+   *     for (Agent element : response.getAgentsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable searchAgentsCallable() { + return stub.searchAgentsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Agent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   AgentName name = AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]");
+   *   Agent response = agentRegistryClient.getAgent(name);
+   * }
+   * }
+ * + * @param name Required. Name of the resource + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Agent getAgent(@Nullable AgentName name) { + GetAgentRequest request = + GetAgentRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getAgent(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Agent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String name =
+   *       AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]").toString();
+   *   Agent response = agentRegistryClient.getAgent(name);
+   * }
+   * }
+ * + * @param name Required. Name of the resource + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Agent getAgent(String name) { + GetAgentRequest request = GetAgentRequest.newBuilder().setName(name).build(); + return getAgent(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Agent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetAgentRequest request =
+   *       GetAgentRequest.newBuilder()
+   *           .setName(
+   *               AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]")
+   *                   .toString())
+   *           .build();
+   *   Agent response = agentRegistryClient.getAgent(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Agent getAgent(GetAgentRequest request) { + return getAgentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Agent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetAgentRequest request =
+   *       GetAgentRequest.newBuilder()
+   *           .setName(
+   *               AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]")
+   *                   .toString())
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.getAgentCallable().futureCall(request);
+   *   // Do something.
+   *   Agent response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getAgentCallable() { + return stub.getAgentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Endpoints in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Endpoint element : agentRegistryClient.listEndpoints(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The project and location to list endpoints in. Expected format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListEndpointsPagedResponse listEndpoints(@Nullable LocationName parent) { + ListEndpointsRequest request = + ListEndpointsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listEndpoints(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Endpoints in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Endpoint element : agentRegistryClient.listEndpoints(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The project and location to list endpoints in. Expected format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListEndpointsPagedResponse listEndpoints(String parent) { + ListEndpointsRequest request = ListEndpointsRequest.newBuilder().setParent(parent).build(); + return listEndpoints(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Endpoints in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListEndpointsRequest request =
+   *       ListEndpointsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   for (Endpoint element : agentRegistryClient.listEndpoints(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListEndpointsPagedResponse listEndpoints(ListEndpointsRequest request) { + return listEndpointsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Endpoints in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListEndpointsRequest request =
+   *       ListEndpointsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   ApiFuture future =
+   *       agentRegistryClient.listEndpointsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Endpoint element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listEndpointsPagedCallable() { + return stub.listEndpointsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Endpoints in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListEndpointsRequest request =
+   *       ListEndpointsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   while (true) {
+   *     ListEndpointsResponse response = agentRegistryClient.listEndpointsCallable().call(request);
+   *     for (Endpoint element : response.getEndpointsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listEndpointsCallable() { + return stub.listEndpointsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Endpoint. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   EndpointName name =
+   *       EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]");
+   *   Endpoint response = agentRegistryClient.getEndpoint(name);
+   * }
+   * }
+ * + * @param name Required. The name of the endpoint to retrieve. Format: + * `projects/{project}/locations/{location}/endpoints/{endpoint}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Endpoint getEndpoint(@Nullable EndpointName name) { + GetEndpointRequest request = + GetEndpointRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getEndpoint(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Endpoint. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String name =
+   *       EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]")
+   *           .toString();
+   *   Endpoint response = agentRegistryClient.getEndpoint(name);
+   * }
+   * }
+ * + * @param name Required. The name of the endpoint to retrieve. Format: + * `projects/{project}/locations/{location}/endpoints/{endpoint}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Endpoint getEndpoint(String name) { + GetEndpointRequest request = GetEndpointRequest.newBuilder().setName(name).build(); + return getEndpoint(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Endpoint. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetEndpointRequest request =
+   *       GetEndpointRequest.newBuilder()
+   *           .setName(
+   *               EndpointName.ofProjectLocationEndpointName(
+   *                       "[PROJECT]", "[LOCATION]", "[ENDPOINT]")
+   *                   .toString())
+   *           .build();
+   *   Endpoint response = agentRegistryClient.getEndpoint(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Endpoint getEndpoint(GetEndpointRequest request) { + return getEndpointCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Endpoint. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetEndpointRequest request =
+   *       GetEndpointRequest.newBuilder()
+   *           .setName(
+   *               EndpointName.ofProjectLocationEndpointName(
+   *                       "[PROJECT]", "[LOCATION]", "[ENDPOINT]")
+   *                   .toString())
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.getEndpointCallable().futureCall(request);
+   *   // Do something.
+   *   Endpoint response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getEndpointCallable() { + return stub.getEndpointCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists McpServers in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (McpServer element : agentRegistryClient.listMcpServers(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. Parent value for ListMcpServersRequest. Format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListMcpServersPagedResponse listMcpServers(@Nullable LocationName parent) { + ListMcpServersRequest request = + ListMcpServersRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listMcpServers(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists McpServers in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (McpServer element : agentRegistryClient.listMcpServers(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. Parent value for ListMcpServersRequest. Format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListMcpServersPagedResponse listMcpServers(String parent) { + ListMcpServersRequest request = ListMcpServersRequest.newBuilder().setParent(parent).build(); + return listMcpServers(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists McpServers in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListMcpServersRequest request =
+   *       ListMcpServersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   for (McpServer element : agentRegistryClient.listMcpServers(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListMcpServersPagedResponse listMcpServers(ListMcpServersRequest request) { + return listMcpServersPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists McpServers in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListMcpServersRequest request =
+   *       ListMcpServersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   ApiFuture future =
+   *       agentRegistryClient.listMcpServersPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (McpServer element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listMcpServersPagedCallable() { + return stub.listMcpServersPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists McpServers in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListMcpServersRequest request =
+   *       ListMcpServersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   while (true) {
+   *     ListMcpServersResponse response =
+   *         agentRegistryClient.listMcpServersCallable().call(request);
+   *     for (McpServer element : response.getMcpServersList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listMcpServersCallable() { + return stub.listMcpServersCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Searches McpServers in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (McpServer element : agentRegistryClient.searchMcpServers(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. Parent value for SearchMcpServersRequest. Format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SearchMcpServersPagedResponse searchMcpServers(@Nullable LocationName parent) { + SearchMcpServersRequest request = + SearchMcpServersRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return searchMcpServers(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Searches McpServers in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (McpServer element : agentRegistryClient.searchMcpServers(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. Parent value for SearchMcpServersRequest. Format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SearchMcpServersPagedResponse searchMcpServers(String parent) { + SearchMcpServersRequest request = + SearchMcpServersRequest.newBuilder().setParent(parent).build(); + return searchMcpServers(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Searches McpServers in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   SearchMcpServersRequest request =
+   *       SearchMcpServersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setSearchString("searchString120312793")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (McpServer element : agentRegistryClient.searchMcpServers(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SearchMcpServersPagedResponse searchMcpServers(SearchMcpServersRequest request) { + return searchMcpServersPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Searches McpServers in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   SearchMcpServersRequest request =
+   *       SearchMcpServersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setSearchString("searchString120312793")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future =
+   *       agentRegistryClient.searchMcpServersPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (McpServer element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + searchMcpServersPagedCallable() { + return stub.searchMcpServersPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Searches McpServers in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   SearchMcpServersRequest request =
+   *       SearchMcpServersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setSearchString("searchString120312793")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     SearchMcpServersResponse response =
+   *         agentRegistryClient.searchMcpServersCallable().call(request);
+   *     for (McpServer element : response.getMcpServersList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + searchMcpServersCallable() { + return stub.searchMcpServersCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single McpServer. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   McpServerName name =
+   *       McpServerName.ofProjectLocationMcpServerName("[PROJECT]", "[LOCATION]", "[MCP_SERVER]");
+   *   McpServer response = agentRegistryClient.getMcpServer(name);
+   * }
+   * }
+ * + * @param name Required. Name of the resource + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final McpServer getMcpServer(@Nullable McpServerName name) { + GetMcpServerRequest request = + GetMcpServerRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getMcpServer(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single McpServer. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String name =
+   *       McpServerName.ofProjectLocationMcpServerName("[PROJECT]", "[LOCATION]", "[MCP_SERVER]")
+   *           .toString();
+   *   McpServer response = agentRegistryClient.getMcpServer(name);
+   * }
+   * }
+ * + * @param name Required. Name of the resource + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final McpServer getMcpServer(String name) { + GetMcpServerRequest request = GetMcpServerRequest.newBuilder().setName(name).build(); + return getMcpServer(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single McpServer. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetMcpServerRequest request =
+   *       GetMcpServerRequest.newBuilder()
+   *           .setName(
+   *               McpServerName.ofProjectLocationMcpServerName(
+   *                       "[PROJECT]", "[LOCATION]", "[MCP_SERVER]")
+   *                   .toString())
+   *           .build();
+   *   McpServer response = agentRegistryClient.getMcpServer(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final McpServer getMcpServer(GetMcpServerRequest request) { + return getMcpServerCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single McpServer. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetMcpServerRequest request =
+   *       GetMcpServerRequest.newBuilder()
+   *           .setName(
+   *               McpServerName.ofProjectLocationMcpServerName(
+   *                       "[PROJECT]", "[LOCATION]", "[MCP_SERVER]")
+   *                   .toString())
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.getMcpServerCallable().futureCall(request);
+   *   // Do something.
+   *   McpServer response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getMcpServerCallable() { + return stub.getMcpServerCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Services in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Service element : agentRegistryClient.listServices(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The project and location to list services in. Expected format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListServicesPagedResponse listServices(@Nullable LocationName parent) { + ListServicesRequest request = + ListServicesRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listServices(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Services in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Service element : agentRegistryClient.listServices(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The project and location to list services in. Expected format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListServicesPagedResponse listServices(String parent) { + ListServicesRequest request = ListServicesRequest.newBuilder().setParent(parent).build(); + return listServices(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Services in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListServicesRequest request =
+   *       ListServicesRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   for (Service element : agentRegistryClient.listServices(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListServicesPagedResponse listServices(ListServicesRequest request) { + return listServicesPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Services in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListServicesRequest request =
+   *       ListServicesRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   ApiFuture future =
+   *       agentRegistryClient.listServicesPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Service element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listServicesPagedCallable() { + return stub.listServicesPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Services in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListServicesRequest request =
+   *       ListServicesRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   while (true) {
+   *     ListServicesResponse response = agentRegistryClient.listServicesCallable().call(request);
+   *     for (Service element : response.getServicesList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listServicesCallable() { + return stub.listServicesCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ServiceName name = ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]");
+   *   Service response = agentRegistryClient.getService(name);
+   * }
+   * }
+ * + * @param name Required. The name of the Service. Format: + * `projects/{project}/locations/{location}/services/{service}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Service getService(@Nullable ServiceName name) { + GetServiceRequest request = + GetServiceRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getService(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String name = ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString();
+   *   Service response = agentRegistryClient.getService(name);
+   * }
+   * }
+ * + * @param name Required. The name of the Service. Format: + * `projects/{project}/locations/{location}/services/{service}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Service getService(String name) { + GetServiceRequest request = GetServiceRequest.newBuilder().setName(name).build(); + return getService(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetServiceRequest request =
+   *       GetServiceRequest.newBuilder()
+   *           .setName(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
+   *           .build();
+   *   Service response = agentRegistryClient.getService(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Service getService(GetServiceRequest request) { + return getServiceCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetServiceRequest request =
+   *       GetServiceRequest.newBuilder()
+   *           .setName(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.getServiceCallable().futureCall(request);
+   *   // Do something.
+   *   Service response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getServiceCallable() { + return stub.getServiceCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Service in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   Service service = Service.newBuilder().build();
+   *   String serviceId = "serviceId-194185552";
+   *   Service response = agentRegistryClient.createServiceAsync(parent, service, serviceId).get();
+   * }
+   * }
+ * + * @param parent Required. The project and location to create the Service in. Expected format: + * `projects/{project}/locations/{location}`. + * @param service Required. The Service resource that is being created. Format: + * `projects/{project}/locations/{location}/services/{service}`. + * @param serviceId Required. The ID to use for the service, which will become the final component + * of the service's resource name. + *

This value should be 4-63 characters, and valid characters are `/[a-z][0-9]-/`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createServiceAsync( + @Nullable LocationName parent, Service service, String serviceId) { + CreateServiceRequest request = + CreateServiceRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setService(service) + .setServiceId(serviceId) + .build(); + return createServiceAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Service in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   Service service = Service.newBuilder().build();
+   *   String serviceId = "serviceId-194185552";
+   *   Service response = agentRegistryClient.createServiceAsync(parent, service, serviceId).get();
+   * }
+   * }
+ * + * @param parent Required. The project and location to create the Service in. Expected format: + * `projects/{project}/locations/{location}`. + * @param service Required. The Service resource that is being created. Format: + * `projects/{project}/locations/{location}/services/{service}`. + * @param serviceId Required. The ID to use for the service, which will become the final component + * of the service's resource name. + *

This value should be 4-63 characters, and valid characters are `/[a-z][0-9]-/`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createServiceAsync( + String parent, Service service, String serviceId) { + CreateServiceRequest request = + CreateServiceRequest.newBuilder() + .setParent(parent) + .setService(service) + .setServiceId(serviceId) + .build(); + return createServiceAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Service in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   CreateServiceRequest request =
+   *       CreateServiceRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setServiceId("serviceId-194185552")
+   *           .setService(Service.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   Service response = agentRegistryClient.createServiceAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createServiceAsync( + CreateServiceRequest request) { + return createServiceOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Service in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   CreateServiceRequest request =
+   *       CreateServiceRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setServiceId("serviceId-194185552")
+   *           .setService(Service.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   OperationFuture future =
+   *       agentRegistryClient.createServiceOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Service response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + createServiceOperationCallable() { + return stub.createServiceOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Service in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   CreateServiceRequest request =
+   *       CreateServiceRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setServiceId("serviceId-194185552")
+   *           .setService(Service.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.createServiceCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable createServiceCallable() { + return stub.createServiceCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   Service service = Service.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   Service response = agentRegistryClient.updateServiceAsync(service, updateMask).get();
+   * }
+   * }
+ * + * @param service Required. The Service resource that is being updated. Format: + * `projects/{project}/locations/{location}/services/{service}`. + * @param updateMask Optional. Field mask is used to specify the fields to be overwritten in the + * Service resource by the update. The fields specified in the update_mask are relative to the + * resource, not the full request. A field will be overwritten if it is in the mask. If the + * user does not provide a mask then all fields present in the request will be overwritten. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateServiceAsync( + Service service, FieldMask updateMask) { + UpdateServiceRequest request = + UpdateServiceRequest.newBuilder().setService(service).setUpdateMask(updateMask).build(); + return updateServiceAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   UpdateServiceRequest request =
+   *       UpdateServiceRequest.newBuilder()
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setService(Service.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   Service response = agentRegistryClient.updateServiceAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateServiceAsync( + UpdateServiceRequest request) { + return updateServiceOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   UpdateServiceRequest request =
+   *       UpdateServiceRequest.newBuilder()
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setService(Service.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   OperationFuture future =
+   *       agentRegistryClient.updateServiceOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Service response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + updateServiceOperationCallable() { + return stub.updateServiceOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   UpdateServiceRequest request =
+   *       UpdateServiceRequest.newBuilder()
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setService(Service.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.updateServiceCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable updateServiceCallable() { + return stub.updateServiceCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ServiceName name = ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]");
+   *   agentRegistryClient.deleteServiceAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the Service. Format: + * `projects/{project}/locations/{location}/services/{service}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteServiceAsync( + @Nullable ServiceName name) { + DeleteServiceRequest request = + DeleteServiceRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return deleteServiceAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String name = ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString();
+   *   agentRegistryClient.deleteServiceAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the Service. Format: + * `projects/{project}/locations/{location}/services/{service}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteServiceAsync(String name) { + DeleteServiceRequest request = DeleteServiceRequest.newBuilder().setName(name).build(); + return deleteServiceAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   DeleteServiceRequest request =
+   *       DeleteServiceRequest.newBuilder()
+   *           .setName(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   agentRegistryClient.deleteServiceAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteServiceAsync( + DeleteServiceRequest request) { + return deleteServiceOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   DeleteServiceRequest request =
+   *       DeleteServiceRequest.newBuilder()
+   *           .setName(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   OperationFuture future =
+   *       agentRegistryClient.deleteServiceOperationCallable().futureCall(request);
+   *   // Do something.
+   *   future.get();
+   * }
+   * }
+ */ + public final OperationCallable + deleteServiceOperationCallable() { + return stub.deleteServiceOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   DeleteServiceRequest request =
+   *       DeleteServiceRequest.newBuilder()
+   *           .setName(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.deleteServiceCallable().futureCall(request);
+   *   // Do something.
+   *   future.get();
+   * }
+   * }
+ */ + public final UnaryCallable deleteServiceCallable() { + return stub.deleteServiceCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Bindings in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Binding element : agentRegistryClient.listBindings(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The project and location to list bindings in. Expected format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListBindingsPagedResponse listBindings(@Nullable LocationName parent) { + ListBindingsRequest request = + ListBindingsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listBindings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Bindings in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Binding element : agentRegistryClient.listBindings(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The project and location to list bindings in. Expected format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListBindingsPagedResponse listBindings(String parent) { + ListBindingsRequest request = ListBindingsRequest.newBuilder().setParent(parent).build(); + return listBindings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Bindings in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListBindingsRequest request =
+   *       ListBindingsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   for (Binding element : agentRegistryClient.listBindings(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListBindingsPagedResponse listBindings(ListBindingsRequest request) { + return listBindingsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Bindings in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListBindingsRequest request =
+   *       ListBindingsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   ApiFuture future =
+   *       agentRegistryClient.listBindingsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Binding element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listBindingsPagedCallable() { + return stub.listBindingsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Bindings in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListBindingsRequest request =
+   *       ListBindingsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   while (true) {
+   *     ListBindingsResponse response = agentRegistryClient.listBindingsCallable().call(request);
+   *     for (Binding element : response.getBindingsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listBindingsCallable() { + return stub.listBindingsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   BindingName name = BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]");
+   *   Binding response = agentRegistryClient.getBinding(name);
+   * }
+   * }
+ * + * @param name Required. The name of the Binding. Format: + * `projects/{project}/locations/{location}/bindings/{binding}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Binding getBinding(@Nullable BindingName name) { + GetBindingRequest request = + GetBindingRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getBinding(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String name = BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString();
+   *   Binding response = agentRegistryClient.getBinding(name);
+   * }
+   * }
+ * + * @param name Required. The name of the Binding. Format: + * `projects/{project}/locations/{location}/bindings/{binding}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Binding getBinding(String name) { + GetBindingRequest request = GetBindingRequest.newBuilder().setName(name).build(); + return getBinding(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetBindingRequest request =
+   *       GetBindingRequest.newBuilder()
+   *           .setName(BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString())
+   *           .build();
+   *   Binding response = agentRegistryClient.getBinding(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Binding getBinding(GetBindingRequest request) { + return getBindingCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetBindingRequest request =
+   *       GetBindingRequest.newBuilder()
+   *           .setName(BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString())
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.getBindingCallable().futureCall(request);
+   *   // Do something.
+   *   Binding response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getBindingCallable() { + return stub.getBindingCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Binding in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   Binding binding = Binding.newBuilder().build();
+   *   String bindingId = "bindingId-920966528";
+   *   Binding response = agentRegistryClient.createBindingAsync(parent, binding, bindingId).get();
+   * }
+   * }
+ * + * @param parent Required. The project and location to create the Binding in. Expected format: + * `projects/{project}/locations/{location}`. + * @param binding Required. The Binding resource that is being created. + * @param bindingId Required. The ID to use for the binding, which will become the final component + * of the binding's resource name. + *

This value should be 4-63 characters, and must conform to RFC-1034. Specifically, it + * must match the regular expression `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createBindingAsync( + @Nullable LocationName parent, Binding binding, String bindingId) { + CreateBindingRequest request = + CreateBindingRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setBinding(binding) + .setBindingId(bindingId) + .build(); + return createBindingAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Binding in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   Binding binding = Binding.newBuilder().build();
+   *   String bindingId = "bindingId-920966528";
+   *   Binding response = agentRegistryClient.createBindingAsync(parent, binding, bindingId).get();
+   * }
+   * }
+ * + * @param parent Required. The project and location to create the Binding in. Expected format: + * `projects/{project}/locations/{location}`. + * @param binding Required. The Binding resource that is being created. + * @param bindingId Required. The ID to use for the binding, which will become the final component + * of the binding's resource name. + *

This value should be 4-63 characters, and must conform to RFC-1034. Specifically, it + * must match the regular expression `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createBindingAsync( + String parent, Binding binding, String bindingId) { + CreateBindingRequest request = + CreateBindingRequest.newBuilder() + .setParent(parent) + .setBinding(binding) + .setBindingId(bindingId) + .build(); + return createBindingAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Binding in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   CreateBindingRequest request =
+   *       CreateBindingRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setBindingId("bindingId-920966528")
+   *           .setBinding(Binding.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   Binding response = agentRegistryClient.createBindingAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createBindingAsync( + CreateBindingRequest request) { + return createBindingOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Binding in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   CreateBindingRequest request =
+   *       CreateBindingRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setBindingId("bindingId-920966528")
+   *           .setBinding(Binding.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   OperationFuture future =
+   *       agentRegistryClient.createBindingOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Binding response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + createBindingOperationCallable() { + return stub.createBindingOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Binding in a given project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   CreateBindingRequest request =
+   *       CreateBindingRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setBindingId("bindingId-920966528")
+   *           .setBinding(Binding.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.createBindingCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable createBindingCallable() { + return stub.createBindingCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   Binding binding = Binding.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   Binding response = agentRegistryClient.updateBindingAsync(binding, updateMask).get();
+   * }
+   * }
+ * + * @param binding Required. The Binding resource that is being updated. + * @param updateMask Optional. Field mask is used to specify the fields to be overwritten in the + * Binding resource by the update. The fields specified in the update_mask are relative to the + * resource, not the full request. A field will be overwritten if it is in the mask. If the + * user does not provide a mask then all fields present in the request will be overwritten. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateBindingAsync( + Binding binding, FieldMask updateMask) { + UpdateBindingRequest request = + UpdateBindingRequest.newBuilder().setBinding(binding).setUpdateMask(updateMask).build(); + return updateBindingAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   UpdateBindingRequest request =
+   *       UpdateBindingRequest.newBuilder()
+   *           .setBinding(Binding.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   Binding response = agentRegistryClient.updateBindingAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateBindingAsync( + UpdateBindingRequest request) { + return updateBindingOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   UpdateBindingRequest request =
+   *       UpdateBindingRequest.newBuilder()
+   *           .setBinding(Binding.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   OperationFuture future =
+   *       agentRegistryClient.updateBindingOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Binding response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + updateBindingOperationCallable() { + return stub.updateBindingOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   UpdateBindingRequest request =
+   *       UpdateBindingRequest.newBuilder()
+   *           .setBinding(Binding.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.updateBindingCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable updateBindingCallable() { + return stub.updateBindingCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   BindingName name = BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]");
+   *   agentRegistryClient.deleteBindingAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the Binding. Format: + * `projects/{project}/locations/{location}/bindings/{binding}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteBindingAsync( + @Nullable BindingName name) { + DeleteBindingRequest request = + DeleteBindingRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return deleteBindingAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String name = BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString();
+   *   agentRegistryClient.deleteBindingAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the Binding. Format: + * `projects/{project}/locations/{location}/bindings/{binding}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteBindingAsync(String name) { + DeleteBindingRequest request = DeleteBindingRequest.newBuilder().setName(name).build(); + return deleteBindingAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   DeleteBindingRequest request =
+   *       DeleteBindingRequest.newBuilder()
+   *           .setName(BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   agentRegistryClient.deleteBindingAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteBindingAsync( + DeleteBindingRequest request) { + return deleteBindingOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   DeleteBindingRequest request =
+   *       DeleteBindingRequest.newBuilder()
+   *           .setName(BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   OperationFuture future =
+   *       agentRegistryClient.deleteBindingOperationCallable().futureCall(request);
+   *   // Do something.
+   *   future.get();
+   * }
+   * }
+ */ + public final OperationCallable + deleteBindingOperationCallable() { + return stub.deleteBindingOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Binding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   DeleteBindingRequest request =
+   *       DeleteBindingRequest.newBuilder()
+   *           .setName(BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.deleteBindingCallable().futureCall(request);
+   *   // Do something.
+   *   future.get();
+   * }
+   * }
+ */ + public final UnaryCallable deleteBindingCallable() { + return stub.deleteBindingCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetches available Bindings. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Binding element : agentRegistryClient.fetchAvailableBindings(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent, in the format `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final FetchAvailableBindingsPagedResponse fetchAvailableBindings( + @Nullable LocationName parent) { + FetchAvailableBindingsRequest request = + FetchAvailableBindingsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return fetchAvailableBindings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetches available Bindings. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Binding element : agentRegistryClient.fetchAvailableBindings(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent, in the format `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final FetchAvailableBindingsPagedResponse fetchAvailableBindings(String parent) { + FetchAvailableBindingsRequest request = + FetchAvailableBindingsRequest.newBuilder().setParent(parent).build(); + return fetchAvailableBindings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetches available Bindings. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   FetchAvailableBindingsRequest request =
+   *       FetchAvailableBindingsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (Binding element : agentRegistryClient.fetchAvailableBindings(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final FetchAvailableBindingsPagedResponse fetchAvailableBindings( + FetchAvailableBindingsRequest request) { + return fetchAvailableBindingsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetches available Bindings. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   FetchAvailableBindingsRequest request =
+   *       FetchAvailableBindingsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future =
+   *       agentRegistryClient.fetchAvailableBindingsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Binding element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + fetchAvailableBindingsPagedCallable() { + return stub.fetchAvailableBindingsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetches available Bindings. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   FetchAvailableBindingsRequest request =
+   *       FetchAvailableBindingsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     FetchAvailableBindingsResponse response =
+   *         agentRegistryClient.fetchAvailableBindingsCallable().call(request);
+   *     for (Binding element : response.getBindingsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + fetchAvailableBindingsCallable() { + return stub.fetchAvailableBindingsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * ========================================================================= # Skills Collection + * APIs + * + *

Creates a Skill resource container, optionally publishing the initial SkillRevision inline + * in a single, atomic CRUD roundtrip. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   Skill skill = Skill.newBuilder().build();
+   *   String skillId = "skillId2147320652";
+   *   Skill response = agentRegistryClient.createSkillAsync(parent, skill, skillId).get();
+   * }
+   * }
+ * + * @param parent Required. The project and location location to bootstrap. + * @param skill Required. Skill container body config. + * @param skillId Required. Custom, user-defined unique container identifier. Must be unique + * within the parent project and location. This value should be 4-64 characters, and valid + * characters are `/[a-z][0-9]-/`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createSkillAsync( + @Nullable LocationName parent, Skill skill, String skillId) { + CreateSkillRequest request = + CreateSkillRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setSkill(skill) + .setSkillId(skillId) + .build(); + return createSkillAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * ========================================================================= # Skills Collection + * APIs + * + *

Creates a Skill resource container, optionally publishing the initial SkillRevision inline + * in a single, atomic CRUD roundtrip. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   Skill skill = Skill.newBuilder().build();
+   *   String skillId = "skillId2147320652";
+   *   Skill response = agentRegistryClient.createSkillAsync(parent, skill, skillId).get();
+   * }
+   * }
+ * + * @param parent Required. The project and location location to bootstrap. + * @param skill Required. Skill container body config. + * @param skillId Required. Custom, user-defined unique container identifier. Must be unique + * within the parent project and location. This value should be 4-64 characters, and valid + * characters are `/[a-z][0-9]-/`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createSkillAsync( + String parent, Skill skill, String skillId) { + CreateSkillRequest request = + CreateSkillRequest.newBuilder() + .setParent(parent) + .setSkill(skill) + .setSkillId(skillId) + .build(); + return createSkillAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * ========================================================================= # Skills Collection + * APIs + * + *

Creates a Skill resource container, optionally publishing the initial SkillRevision inline + * in a single, atomic CRUD roundtrip. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   CreateSkillRequest request =
+   *       CreateSkillRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setSkillId("skillId2147320652")
+   *           .setSkill(Skill.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   Skill response = agentRegistryClient.createSkillAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createSkillAsync( + CreateSkillRequest request) { + return createSkillOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * ========================================================================= # Skills Collection + * APIs + * + *

Creates a Skill resource container, optionally publishing the initial SkillRevision inline + * in a single, atomic CRUD roundtrip. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   CreateSkillRequest request =
+   *       CreateSkillRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setSkillId("skillId2147320652")
+   *           .setSkill(Skill.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   OperationFuture future =
+   *       agentRegistryClient.createSkillOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Skill response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + createSkillOperationCallable() { + return stub.createSkillOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * ========================================================================= # Skills Collection + * APIs + * + *

Creates a Skill resource container, optionally publishing the initial SkillRevision inline + * in a single, atomic CRUD roundtrip. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   CreateSkillRequest request =
+   *       CreateSkillRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setSkillId("skillId2147320652")
+   *           .setSkill(Skill.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.createSkillCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable createSkillCallable() { + return stub.createSkillCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetches the active configuration and metadata of a Skill. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]");
+   *   Skill response = agentRegistryClient.getSkill(name);
+   * }
+   * }
+ * + * @param name Required. Target resource container name. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Skill getSkill(@Nullable SkillName name) { + GetSkillRequest request = + GetSkillRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getSkill(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetches the active configuration and metadata of a Skill. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString();
+   *   Skill response = agentRegistryClient.getSkill(name);
+   * }
+   * }
+ * + * @param name Required. Target resource container name. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Skill getSkill(String name) { + GetSkillRequest request = GetSkillRequest.newBuilder().setName(name).build(); + return getSkill(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetches the active configuration and metadata of a Skill. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetSkillRequest request =
+   *       GetSkillRequest.newBuilder()
+   *           .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString())
+   *           .build();
+   *   Skill response = agentRegistryClient.getSkill(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Skill getSkill(GetSkillRequest request) { + return getSkillCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetches the active configuration and metadata of a Skill. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetSkillRequest request =
+   *       GetSkillRequest.newBuilder()
+   *           .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString())
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.getSkillCallable().futureCall(request);
+   *   // Do something.
+   *   Skill response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getSkillCallable() { + return stub.getSkillCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates Skill metadata or overrides active pointers/state using REST standard PATCH. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   Skill skill = Skill.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   Skill response = agentRegistryClient.updateSkillAsync(skill, updateMask).get();
+   * }
+   * }
+ * + * @param skill Required. Mutable Skill container config fields to write. + * @param updateMask Optional. Standard update target mask mapping relative fields. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateSkillAsync( + Skill skill, FieldMask updateMask) { + UpdateSkillRequest request = + UpdateSkillRequest.newBuilder().setSkill(skill).setUpdateMask(updateMask).build(); + return updateSkillAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates Skill metadata or overrides active pointers/state using REST standard PATCH. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   UpdateSkillRequest request =
+   *       UpdateSkillRequest.newBuilder()
+   *           .setSkill(Skill.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   Skill response = agentRegistryClient.updateSkillAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateSkillAsync( + UpdateSkillRequest request) { + return updateSkillOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates Skill metadata or overrides active pointers/state using REST standard PATCH. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   UpdateSkillRequest request =
+   *       UpdateSkillRequest.newBuilder()
+   *           .setSkill(Skill.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   OperationFuture future =
+   *       agentRegistryClient.updateSkillOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Skill response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + updateSkillOperationCallable() { + return stub.updateSkillOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates Skill metadata or overrides active pointers/state using REST standard PATCH. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   UpdateSkillRequest request =
+   *       UpdateSkillRequest.newBuilder()
+   *           .setSkill(Skill.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.updateSkillCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable updateSkillCallable() { + return stub.updateSkillCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a Skill container along with all its revisions. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]");
+   *   agentRegistryClient.deleteSkillAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. Target Skill container name to remove. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteSkillAsync( + @Nullable SkillName name) { + DeleteSkillRequest request = + DeleteSkillRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return deleteSkillAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a Skill container along with all its revisions. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString();
+   *   agentRegistryClient.deleteSkillAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. Target Skill container name to remove. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteSkillAsync(String name) { + DeleteSkillRequest request = DeleteSkillRequest.newBuilder().setName(name).build(); + return deleteSkillAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a Skill container along with all its revisions. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   DeleteSkillRequest request =
+   *       DeleteSkillRequest.newBuilder()
+   *           .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString())
+   *           .setRequestId("requestId693933066")
+   *           .setForce(true)
+   *           .build();
+   *   agentRegistryClient.deleteSkillAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteSkillAsync( + DeleteSkillRequest request) { + return deleteSkillOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a Skill container along with all its revisions. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   DeleteSkillRequest request =
+   *       DeleteSkillRequest.newBuilder()
+   *           .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString())
+   *           .setRequestId("requestId693933066")
+   *           .setForce(true)
+   *           .build();
+   *   OperationFuture future =
+   *       agentRegistryClient.deleteSkillOperationCallable().futureCall(request);
+   *   // Do something.
+   *   future.get();
+   * }
+   * }
+ */ + public final OperationCallable + deleteSkillOperationCallable() { + return stub.deleteSkillOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a Skill container along with all its revisions. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   DeleteSkillRequest request =
+   *       DeleteSkillRequest.newBuilder()
+   *           .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString())
+   *           .setRequestId("requestId693933066")
+   *           .setForce(true)
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.deleteSkillCallable().futureCall(request);
+   *   // Do something.
+   *   future.get();
+   * }
+   * }
+ */ + public final UnaryCallable deleteSkillCallable() { + return stub.deleteSkillCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists logical Skills available in a project. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Skill element : agentRegistryClient.listSkills(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. Parent value for ListSkillsRequest + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListSkillsPagedResponse listSkills(@Nullable LocationName parent) { + ListSkillsRequest request = + ListSkillsRequest.newBuilder().setParent(parent == null ? null : parent.toString()).build(); + return listSkills(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists logical Skills available in a project. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Skill element : agentRegistryClient.listSkills(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. Parent value for ListSkillsRequest + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListSkillsPagedResponse listSkills(String parent) { + ListSkillsRequest request = ListSkillsRequest.newBuilder().setParent(parent).build(); + return listSkills(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists logical Skills available in a project. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListSkillsRequest request =
+   *       ListSkillsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   for (Skill element : agentRegistryClient.listSkills(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListSkillsPagedResponse listSkills(ListSkillsRequest request) { + return listSkillsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists logical Skills available in a project. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListSkillsRequest request =
+   *       ListSkillsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   ApiFuture future = agentRegistryClient.listSkillsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Skill element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listSkillsPagedCallable() { + return stub.listSkillsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists logical Skills available in a project. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListSkillsRequest request =
+   *       ListSkillsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   while (true) {
+   *     ListSkillsResponse response = agentRegistryClient.listSkillsCallable().call(request);
+   *     for (Skill element : response.getSkillsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listSkillsCallable() { + return stub.listSkillsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Custom deep-search method to filter by frontmatter or query SKILL.md text blobs. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   SearchSkillsRequest request =
+   *       SearchSkillsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setSearchType(SearchType.forNumber(0))
+   *           .setSearchString("searchString120312793")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
    *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (Skill element : agentRegistryClient.searchSkills(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SearchSkillsPagedResponse searchSkills(SearchSkillsRequest request) { + return searchSkillsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Custom deep-search method to filter by frontmatter or query SKILL.md text blobs. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   SearchSkillsRequest request =
+   *       SearchSkillsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setSearchType(SearchType.forNumber(0))
+   *           .setSearchString("searchString120312793")
    *           .setFilter("filter-1274492040")
-   *           .setOrderBy("orderBy-1207110587")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
    *           .build();
-   *   ApiFuture future = agentRegistryClient.listAgentsPagedCallable().futureCall(request);
+   *   ApiFuture future = agentRegistryClient.searchSkillsPagedCallable().futureCall(request);
    *   // Do something.
-   *   for (Agent element : future.get().iterateAll()) {
+   *   for (Skill element : future.get().iterateAll()) {
    *     // doThingsWith(element);
    *   }
    * }
    * }
*/ - public final UnaryCallable listAgentsPagedCallable() { - return stub.listAgentsPagedCallable(); + public final UnaryCallable + searchSkillsPagedCallable() { + return stub.searchSkillsPagedCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Agents in a given project and location. + * Custom deep-search method to filter by frontmatter or query SKILL.md text blobs. * *

Sample code: * @@ -746,17 +4684,18 @@ public final UnaryCallable listAgent * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListAgentsRequest request = - * ListAgentsRequest.newBuilder() + * SearchSkillsRequest request = + * SearchSkillsRequest.newBuilder() * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * .setSearchType(SearchType.forNumber(0)) + * .setSearchString("searchString120312793") + * .setFilter("filter-1274492040") * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") - * .setOrderBy("orderBy-1207110587") * .build(); * while (true) { - * ListAgentsResponse response = agentRegistryClient.listAgentsCallable().call(request); - * for (Agent element : response.getAgentsList()) { + * SearchSkillsResponse response = agentRegistryClient.searchSkillsCallable().call(request); + * for (Skill element : response.getSkillsList()) { * // doThingsWith(element); * } * String nextPageToken = response.getNextPageToken(); @@ -769,13 +4708,13 @@ public final UnaryCallable listAgent * } * }

*/ - public final UnaryCallable listAgentsCallable() { - return stub.listAgentsCallable(); + public final UnaryCallable searchSkillsCallable() { + return stub.searchSkillsCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Searches Agents in a given project and location. + * Creates a new immutable revision and triggers validation pipelines. * *

Sample code: * @@ -786,28 +4725,36 @@ public final UnaryCallable listAgentsCall * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - * for (Agent element : agentRegistryClient.searchAgents(parent).iterateAll()) { - * // doThingsWith(element); - * } + * SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + * SkillRevision skillRevision = SkillRevision.newBuilder().build(); + * String skillRevisionId = "skillRevisionId-983110777"; + * SkillRevision response = + * agentRegistryClient + * .createSkillRevisionAsync(parent, skillRevision, skillRevisionId) + * .get(); * } * } * - * @param parent Required. Parent value for SearchAgentsRequest. Format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent logical container name. + * @param skillRevision Required. Immutable SkillRevision snapshot definition schema. + * @param skillRevisionId Optional. Custom, user-defined unique revision identifier. Format: 4-63 + * characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final SearchAgentsPagedResponse searchAgents(@Nullable LocationName parent) { - SearchAgentsRequest request = - SearchAgentsRequest.newBuilder() + public final OperationFuture createSkillRevisionAsync( + @Nullable SkillName parent, SkillRevision skillRevision, String skillRevisionId) { + CreateSkillRevisionRequest request = + CreateSkillRevisionRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) + .setSkillRevision(skillRevision) + .setSkillRevisionId(skillRevisionId) .build(); - return searchAgents(request); + return createSkillRevisionAsync(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Searches Agents in a given project and location. + * Creates a new immutable revision and triggers validation pipelines. * *

Sample code: * @@ -818,25 +4765,36 @@ public final SearchAgentsPagedResponse searchAgents(@Nullable LocationName paren * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); - * for (Agent element : agentRegistryClient.searchAgents(parent).iterateAll()) { - * // doThingsWith(element); - * } + * String parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString(); + * SkillRevision skillRevision = SkillRevision.newBuilder().build(); + * String skillRevisionId = "skillRevisionId-983110777"; + * SkillRevision response = + * agentRegistryClient + * .createSkillRevisionAsync(parent, skillRevision, skillRevisionId) + * .get(); * } * } * - * @param parent Required. Parent value for SearchAgentsRequest. Format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent logical container name. + * @param skillRevision Required. Immutable SkillRevision snapshot definition schema. + * @param skillRevisionId Optional. Custom, user-defined unique revision identifier. Format: 4-63 + * characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final SearchAgentsPagedResponse searchAgents(String parent) { - SearchAgentsRequest request = SearchAgentsRequest.newBuilder().setParent(parent).build(); - return searchAgents(request); + public final OperationFuture createSkillRevisionAsync( + String parent, SkillRevision skillRevision, String skillRevisionId) { + CreateSkillRevisionRequest request = + CreateSkillRevisionRequest.newBuilder() + .setParent(parent) + .setSkillRevision(skillRevision) + .setSkillRevisionId(skillRevisionId) + .build(); + return createSkillRevisionAsync(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Searches Agents in a given project and location. + * Creates a new immutable revision and triggers validation pipelines. * *

Sample code: * @@ -847,29 +4805,28 @@ public final SearchAgentsPagedResponse searchAgents(String parent) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * SearchAgentsRequest request = - * SearchAgentsRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setSearchString("searchString120312793") - * .setPageSize(883849137) - * .setPageToken("pageToken873572522") + * CreateSkillRevisionRequest request = + * CreateSkillRevisionRequest.newBuilder() + * .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + * .setSkillRevision(SkillRevision.newBuilder().build()) + * .setSkillRevisionId("skillRevisionId-983110777") + * .setRequestId("requestId693933066") * .build(); - * for (Agent element : agentRegistryClient.searchAgents(request).iterateAll()) { - * // doThingsWith(element); - * } + * SkillRevision response = agentRegistryClient.createSkillRevisionAsync(request).get(); * } * } * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final SearchAgentsPagedResponse searchAgents(SearchAgentsRequest request) { - return searchAgentsPagedCallable().call(request); + public final OperationFuture createSkillRevisionAsync( + CreateSkillRevisionRequest request) { + return createSkillRevisionOperationCallable().futureCall(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Searches Agents in a given project and location. + * Creates a new immutable revision and triggers validation pipelines. * *

Sample code: * @@ -880,29 +4837,28 @@ public final SearchAgentsPagedResponse searchAgents(SearchAgentsRequest request) * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * SearchAgentsRequest request = - * SearchAgentsRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setSearchString("searchString120312793") - * .setPageSize(883849137) - * .setPageToken("pageToken873572522") + * CreateSkillRevisionRequest request = + * CreateSkillRevisionRequest.newBuilder() + * .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + * .setSkillRevision(SkillRevision.newBuilder().build()) + * .setSkillRevisionId("skillRevisionId-983110777") + * .setRequestId("requestId693933066") * .build(); - * ApiFuture future = agentRegistryClient.searchAgentsPagedCallable().futureCall(request); + * OperationFuture future = + * agentRegistryClient.createSkillRevisionOperationCallable().futureCall(request); * // Do something. - * for (Agent element : future.get().iterateAll()) { - * // doThingsWith(element); - * } + * SkillRevision response = future.get(); * } * } */ - public final UnaryCallable - searchAgentsPagedCallable() { - return stub.searchAgentsPagedCallable(); + public final OperationCallable + createSkillRevisionOperationCallable() { + return stub.createSkillRevisionOperationCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Searches Agents in a given project and location. + * Creates a new immutable revision and triggers validation pipelines. * *

Sample code: * @@ -913,35 +4869,27 @@ public final SearchAgentsPagedResponse searchAgents(SearchAgentsRequest request) * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * SearchAgentsRequest request = - * SearchAgentsRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setSearchString("searchString120312793") - * .setPageSize(883849137) - * .setPageToken("pageToken873572522") + * CreateSkillRevisionRequest request = + * CreateSkillRevisionRequest.newBuilder() + * .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + * .setSkillRevision(SkillRevision.newBuilder().build()) + * .setSkillRevisionId("skillRevisionId-983110777") + * .setRequestId("requestId693933066") * .build(); - * while (true) { - * SearchAgentsResponse response = agentRegistryClient.searchAgentsCallable().call(request); - * for (Agent element : response.getAgentsList()) { - * // doThingsWith(element); - * } - * String nextPageToken = response.getNextPageToken(); - * if (!Strings.isNullOrEmpty(nextPageToken)) { - * request = request.toBuilder().setPageToken(nextPageToken).build(); - * } else { - * break; - * } - * } + * ApiFuture future = + * agentRegistryClient.createSkillRevisionCallable().futureCall(request); + * // Do something. + * Operation response = future.get(); * } * } */ - public final UnaryCallable searchAgentsCallable() { - return stub.searchAgentsCallable(); + public final UnaryCallable createSkillRevisionCallable() { + return stub.createSkillRevisionCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Agent. + * Gets details of a single immutable Revision. * *

Sample code: * @@ -952,23 +4900,24 @@ public final UnaryCallable searchAgen * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * AgentName name = AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]"); - * Agent response = agentRegistryClient.getAgent(name); + * SkillRevisionName name = + * SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]"); + * SkillRevision response = agentRegistryClient.getSkillRevision(name); * } * } * - * @param name Required. Name of the resource + * @param name Required. Target revision name. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Agent getAgent(@Nullable AgentName name) { - GetAgentRequest request = - GetAgentRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return getAgent(request); + public final SkillRevision getSkillRevision(@Nullable SkillRevisionName name) { + GetSkillRevisionRequest request = + GetSkillRevisionRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getSkillRevision(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Agent. + * Gets details of a single immutable Revision. * *

Sample code: * @@ -979,22 +4928,174 @@ public final Agent getAgent(@Nullable AgentName name) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String name = AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]").toString(); - * Agent response = agentRegistryClient.getAgent(name); + * String name = + * SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString(); + * SkillRevision response = agentRegistryClient.getSkillRevision(name); * } * } * - * @param name Required. Name of the resource + * @param name Required. Target revision name. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SkillRevision getSkillRevision(String name) { + GetSkillRevisionRequest request = GetSkillRevisionRequest.newBuilder().setName(name).build(); + return getSkillRevision(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single immutable Revision. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetSkillRevisionRequest request =
+   *       GetSkillRevisionRequest.newBuilder()
+   *           .setName(
+   *               SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]")
+   *                   .toString())
+   *           .build();
+   *   SkillRevision response = agentRegistryClient.getSkillRevision(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SkillRevision getSkillRevision(GetSkillRevisionRequest request) { + return getSkillRevisionCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single immutable Revision. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetSkillRevisionRequest request =
+   *       GetSkillRevisionRequest.newBuilder()
+   *           .setName(
+   *               SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]")
+   *                   .toString())
+   *           .build();
+   *   ApiFuture future =
+   *       agentRegistryClient.getSkillRevisionCallable().futureCall(request);
+   *   // Do something.
+   *   SkillRevision response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getSkillRevisionCallable() { + return stub.getSkillRevisionCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a specific revision (restricted to admins to purge accidentally committed secrets). + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   SkillRevisionName name =
+   *       SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]");
+   *   agentRegistryClient.deleteSkillRevisionAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. Target revision name to remove. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteSkillRevisionAsync( + @Nullable SkillRevisionName name) { + DeleteSkillRevisionRequest request = + DeleteSkillRevisionRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return deleteSkillRevisionAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a specific revision (restricted to admins to purge accidentally committed secrets). + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String name =
+   *       SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString();
+   *   agentRegistryClient.deleteSkillRevisionAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. Target revision name to remove. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteSkillRevisionAsync(String name) { + DeleteSkillRevisionRequest request = + DeleteSkillRevisionRequest.newBuilder().setName(name).build(); + return deleteSkillRevisionAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a specific revision (restricted to admins to purge accidentally committed secrets). + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   DeleteSkillRevisionRequest request =
+   *       DeleteSkillRevisionRequest.newBuilder()
+   *           .setName(
+   *               SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]")
+   *                   .toString())
+   *           .setRequestId("requestId693933066")
+   *           .build();
+   *   agentRegistryClient.deleteSkillRevisionAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Agent getAgent(String name) { - GetAgentRequest request = GetAgentRequest.newBuilder().setName(name).build(); - return getAgent(request); + public final OperationFuture deleteSkillRevisionAsync( + DeleteSkillRevisionRequest request) { + return deleteSkillRevisionOperationCallable().futureCall(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Agent. + * Deletes a specific revision (restricted to admins to purge accidentally committed secrets). * *

Sample code: * @@ -1005,24 +5106,28 @@ public final Agent getAgent(String name) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * GetAgentRequest request = - * GetAgentRequest.newBuilder() - * .setName(AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]").toString()) + * DeleteSkillRevisionRequest request = + * DeleteSkillRevisionRequest.newBuilder() + * .setName( + * SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]") + * .toString()) + * .setRequestId("requestId693933066") * .build(); - * Agent response = agentRegistryClient.getAgent(request); + * OperationFuture future = + * agentRegistryClient.deleteSkillRevisionOperationCallable().futureCall(request); + * // Do something. + * future.get(); * } * } - * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Agent getAgent(GetAgentRequest request) { - return getAgentCallable().call(request); + public final OperationCallable + deleteSkillRevisionOperationCallable() { + return stub.deleteSkillRevisionOperationCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Agent. + * Deletes a specific revision (restricted to admins to purge accidentally committed secrets). * *

Sample code: * @@ -1033,23 +5138,27 @@ public final Agent getAgent(GetAgentRequest request) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * GetAgentRequest request = - * GetAgentRequest.newBuilder() - * .setName(AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]").toString()) + * DeleteSkillRevisionRequest request = + * DeleteSkillRevisionRequest.newBuilder() + * .setName( + * SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]") + * .toString()) + * .setRequestId("requestId693933066") * .build(); - * ApiFuture future = agentRegistryClient.getAgentCallable().futureCall(request); + * ApiFuture future = + * agentRegistryClient.deleteSkillRevisionCallable().futureCall(request); * // Do something. - * Agent response = future.get(); + * future.get(); * } * } */ - public final UnaryCallable getAgentCallable() { - return stub.getAgentCallable(); + public final UnaryCallable deleteSkillRevisionCallable() { + return stub.deleteSkillRevisionCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Endpoints in a given project and location. + * Lists all revisions belonging to a parent Skill. * *

Sample code: * @@ -1060,28 +5169,27 @@ public final UnaryCallable getAgentCallable() { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - * for (Endpoint element : agentRegistryClient.listEndpoints(parent).iterateAll()) { + * SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + * for (SkillRevision element : agentRegistryClient.listSkillRevisions(parent).iterateAll()) { * // doThingsWith(element); * } * } * } * - * @param parent Required. The project and location to list endpoints in. Expected format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent logical container name to query. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListEndpointsPagedResponse listEndpoints(@Nullable LocationName parent) { - ListEndpointsRequest request = - ListEndpointsRequest.newBuilder() + public final ListSkillRevisionsPagedResponse listSkillRevisions(@Nullable SkillName parent) { + ListSkillRevisionsRequest request = + ListSkillRevisionsRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) .build(); - return listEndpoints(request); + return listSkillRevisions(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Endpoints in a given project and location. + * Lists all revisions belonging to a parent Skill. * *

Sample code: * @@ -1092,25 +5200,25 @@ public final ListEndpointsPagedResponse listEndpoints(@Nullable LocationName par * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); - * for (Endpoint element : agentRegistryClient.listEndpoints(parent).iterateAll()) { + * String parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString(); + * for (SkillRevision element : agentRegistryClient.listSkillRevisions(parent).iterateAll()) { * // doThingsWith(element); * } * } * } * - * @param parent Required. The project and location to list endpoints in. Expected format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent logical container name to query. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListEndpointsPagedResponse listEndpoints(String parent) { - ListEndpointsRequest request = ListEndpointsRequest.newBuilder().setParent(parent).build(); - return listEndpoints(request); + public final ListSkillRevisionsPagedResponse listSkillRevisions(String parent) { + ListSkillRevisionsRequest request = + ListSkillRevisionsRequest.newBuilder().setParent(parent).build(); + return listSkillRevisions(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Endpoints in a given project and location. + * Lists all revisions belonging to a parent Skill. * *

Sample code: * @@ -1121,14 +5229,13 @@ public final ListEndpointsPagedResponse listEndpoints(String parent) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListEndpointsRequest request = - * ListEndpointsRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * ListSkillRevisionsRequest request = + * ListSkillRevisionsRequest.newBuilder() + * .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") * .build(); - * for (Endpoint element : agentRegistryClient.listEndpoints(request).iterateAll()) { + * for (SkillRevision element : agentRegistryClient.listSkillRevisions(request).iterateAll()) { * // doThingsWith(element); * } * } @@ -1137,13 +5244,14 @@ public final ListEndpointsPagedResponse listEndpoints(String parent) { * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListEndpointsPagedResponse listEndpoints(ListEndpointsRequest request) { - return listEndpointsPagedCallable().call(request); + public final ListSkillRevisionsPagedResponse listSkillRevisions( + ListSkillRevisionsRequest request) { + return listSkillRevisionsPagedCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Endpoints in a given project and location. + * Lists all revisions belonging to a parent Skill. * *

Sample code: * @@ -1154,30 +5262,29 @@ public final ListEndpointsPagedResponse listEndpoints(ListEndpointsRequest reque * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListEndpointsRequest request = - * ListEndpointsRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * ListSkillRevisionsRequest request = + * ListSkillRevisionsRequest.newBuilder() + * .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") * .build(); - * ApiFuture future = - * agentRegistryClient.listEndpointsPagedCallable().futureCall(request); + * ApiFuture future = + * agentRegistryClient.listSkillRevisionsPagedCallable().futureCall(request); * // Do something. - * for (Endpoint element : future.get().iterateAll()) { + * for (SkillRevision element : future.get().iterateAll()) { * // doThingsWith(element); * } * } * } */ - public final UnaryCallable - listEndpointsPagedCallable() { - return stub.listEndpointsPagedCallable(); + public final UnaryCallable + listSkillRevisionsPagedCallable() { + return stub.listSkillRevisionsPagedCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Endpoints in a given project and location. + * Lists all revisions belonging to a parent Skill. * *

Sample code: * @@ -1188,16 +5295,16 @@ public final ListEndpointsPagedResponse listEndpoints(ListEndpointsRequest reque * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListEndpointsRequest request = - * ListEndpointsRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * ListSkillRevisionsRequest request = + * ListSkillRevisionsRequest.newBuilder() + * .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") * .build(); * while (true) { - * ListEndpointsResponse response = agentRegistryClient.listEndpointsCallable().call(request); - * for (Endpoint element : response.getEndpointsList()) { + * ListSkillRevisionsResponse response = + * agentRegistryClient.listSkillRevisionsCallable().call(request); + * for (SkillRevision element : response.getSkillRevisionsList()) { * // doThingsWith(element); * } * String nextPageToken = response.getNextPageToken(); @@ -1210,13 +5317,14 @@ public final ListEndpointsPagedResponse listEndpoints(ListEndpointsRequest reque * } * } */ - public final UnaryCallable listEndpointsCallable() { - return stub.listEndpointsCallable(); + public final UnaryCallable + listSkillRevisionsCallable() { + return stub.listSkillRevisionsCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Endpoint. + * Fetches details of a specific Publisher. * *

Sample code: * @@ -1227,24 +5335,24 @@ public final UnaryCallable listEndp * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * EndpointName name = EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]"); - * Endpoint response = agentRegistryClient.getEndpoint(name); + * PublisherName name = PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]"); + * Publisher response = agentRegistryClient.getPublisher(name); * } * } * - * @param name Required. The name of the endpoint to retrieve. Format: - * `projects/{project}/locations/{location}/endpoints/{endpoint}` + * @param name Required. Target publisher resource name. Format: + * `projects/{project}/locations/{location}/publishers/{publisher}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Endpoint getEndpoint(@Nullable EndpointName name) { - GetEndpointRequest request = - GetEndpointRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return getEndpoint(request); + public final Publisher getPublisher(@Nullable PublisherName name) { + GetPublisherRequest request = + GetPublisherRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getPublisher(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Endpoint. + * Fetches details of a specific Publisher. * *

Sample code: * @@ -1255,23 +5363,23 @@ public final Endpoint getEndpoint(@Nullable EndpointName name) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String name = EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]").toString(); - * Endpoint response = agentRegistryClient.getEndpoint(name); + * String name = PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString(); + * Publisher response = agentRegistryClient.getPublisher(name); * } * } * - * @param name Required. The name of the endpoint to retrieve. Format: - * `projects/{project}/locations/{location}/endpoints/{endpoint}` + * @param name Required. Target publisher resource name. Format: + * `projects/{project}/locations/{location}/publishers/{publisher}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Endpoint getEndpoint(String name) { - GetEndpointRequest request = GetEndpointRequest.newBuilder().setName(name).build(); - return getEndpoint(request); + public final Publisher getPublisher(String name) { + GetPublisherRequest request = GetPublisherRequest.newBuilder().setName(name).build(); + return getPublisher(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Endpoint. + * Fetches details of a specific Publisher. * *

Sample code: * @@ -1282,24 +5390,24 @@ public final Endpoint getEndpoint(String name) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * GetEndpointRequest request = - * GetEndpointRequest.newBuilder() - * .setName(EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]").toString()) + * GetPublisherRequest request = + * GetPublisherRequest.newBuilder() + * .setName(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) * .build(); - * Endpoint response = agentRegistryClient.getEndpoint(request); + * Publisher response = agentRegistryClient.getPublisher(request); * } * } * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Endpoint getEndpoint(GetEndpointRequest request) { - return getEndpointCallable().call(request); + public final Publisher getPublisher(GetPublisherRequest request) { + return getPublisherCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Endpoint. + * Fetches details of a specific Publisher. * *

Sample code: * @@ -1310,23 +5418,23 @@ public final Endpoint getEndpoint(GetEndpointRequest request) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * GetEndpointRequest request = - * GetEndpointRequest.newBuilder() - * .setName(EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]").toString()) + * GetPublisherRequest request = + * GetPublisherRequest.newBuilder() + * .setName(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) * .build(); - * ApiFuture future = agentRegistryClient.getEndpointCallable().futureCall(request); + * ApiFuture future = agentRegistryClient.getPublisherCallable().futureCall(request); * // Do something. - * Endpoint response = future.get(); + * Publisher response = future.get(); * } * } */ - public final UnaryCallable getEndpointCallable() { - return stub.getEndpointCallable(); + public final UnaryCallable getPublisherCallable() { + return stub.getPublisherCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists McpServers in a given project and location. + * Lists all Publishers in a location. * *

Sample code: * @@ -1338,27 +5446,27 @@ public final UnaryCallable getEndpointCallable() { * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - * for (McpServer element : agentRegistryClient.listMcpServers(parent).iterateAll()) { + * for (Publisher element : agentRegistryClient.listPublishers(parent).iterateAll()) { * // doThingsWith(element); * } * } * } * - * @param parent Required. Parent value for ListMcpServersRequest. Format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent location to query. Format: + * `projects/{project}/locations/{location}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListMcpServersPagedResponse listMcpServers(@Nullable LocationName parent) { - ListMcpServersRequest request = - ListMcpServersRequest.newBuilder() + public final ListPublishersPagedResponse listPublishers(@Nullable LocationName parent) { + ListPublishersRequest request = + ListPublishersRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) .build(); - return listMcpServers(request); + return listPublishers(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists McpServers in a given project and location. + * Lists all Publishers in a location. * *

Sample code: * @@ -1370,24 +5478,24 @@ public final ListMcpServersPagedResponse listMcpServers(@Nullable LocationName p * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { * String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); - * for (McpServer element : agentRegistryClient.listMcpServers(parent).iterateAll()) { + * for (Publisher element : agentRegistryClient.listPublishers(parent).iterateAll()) { * // doThingsWith(element); * } * } * } * - * @param parent Required. Parent value for ListMcpServersRequest. Format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent location to query. Format: + * `projects/{project}/locations/{location}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListMcpServersPagedResponse listMcpServers(String parent) { - ListMcpServersRequest request = ListMcpServersRequest.newBuilder().setParent(parent).build(); - return listMcpServers(request); + public final ListPublishersPagedResponse listPublishers(String parent) { + ListPublishersRequest request = ListPublishersRequest.newBuilder().setParent(parent).build(); + return listPublishers(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists McpServers in a given project and location. + * Lists all Publishers in a location. * *

Sample code: * @@ -1398,15 +5506,13 @@ public final ListMcpServersPagedResponse listMcpServers(String parent) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListMcpServersRequest request = - * ListMcpServersRequest.newBuilder() + * ListPublishersRequest request = + * ListPublishersRequest.newBuilder() * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") - * .setOrderBy("orderBy-1207110587") * .build(); - * for (McpServer element : agentRegistryClient.listMcpServers(request).iterateAll()) { + * for (Publisher element : agentRegistryClient.listPublishers(request).iterateAll()) { * // doThingsWith(element); * } * } @@ -1415,13 +5521,13 @@ public final ListMcpServersPagedResponse listMcpServers(String parent) { * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListMcpServersPagedResponse listMcpServers(ListMcpServersRequest request) { - return listMcpServersPagedCallable().call(request); + public final ListPublishersPagedResponse listPublishers(ListPublishersRequest request) { + return listPublishersPagedCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists McpServers in a given project and location. + * Lists all Publishers in a location. * *

Sample code: * @@ -1432,31 +5538,29 @@ public final ListMcpServersPagedResponse listMcpServers(ListMcpServersRequest re * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListMcpServersRequest request = - * ListMcpServersRequest.newBuilder() + * ListPublishersRequest request = + * ListPublishersRequest.newBuilder() * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") - * .setOrderBy("orderBy-1207110587") * .build(); - * ApiFuture future = - * agentRegistryClient.listMcpServersPagedCallable().futureCall(request); + * ApiFuture future = + * agentRegistryClient.listPublishersPagedCallable().futureCall(request); * // Do something. - * for (McpServer element : future.get().iterateAll()) { + * for (Publisher element : future.get().iterateAll()) { * // doThingsWith(element); * } * } * } */ - public final UnaryCallable - listMcpServersPagedCallable() { - return stub.listMcpServersPagedCallable(); + public final UnaryCallable + listPublishersPagedCallable() { + return stub.listPublishersPagedCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists McpServers in a given project and location. + * Lists all Publishers in a location. * *

Sample code: * @@ -1467,18 +5571,16 @@ public final ListMcpServersPagedResponse listMcpServers(ListMcpServersRequest re * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListMcpServersRequest request = - * ListMcpServersRequest.newBuilder() + * ListPublishersRequest request = + * ListPublishersRequest.newBuilder() * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") - * .setOrderBy("orderBy-1207110587") * .build(); * while (true) { - * ListMcpServersResponse response = - * agentRegistryClient.listMcpServersCallable().call(request); - * for (McpServer element : response.getMcpServersList()) { + * ListPublishersResponse response = + * agentRegistryClient.listPublishersCallable().call(request); + * for (Publisher element : response.getPublishersList()) { * // doThingsWith(element); * } * String nextPageToken = response.getNextPageToken(); @@ -1491,14 +5593,127 @@ public final ListMcpServersPagedResponse listMcpServers(ListMcpServersRequest re * } * } */ - public final UnaryCallable - listMcpServersCallable() { - return stub.listMcpServersCallable(); + public final UnaryCallable + listPublishersCallable() { + return stub.listPublishersCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Searches McpServers in a given project and location. + * Gets details of a single AI Application. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   AiApplicationName name = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]");
+   *   AiApplication response = agentRegistryClient.getAiApplication(name);
+   * }
+   * }
+ * + * @param name Required. Target AI Application resource name. Format: + * `projects/{project}/locations/{location}/aiApplications/{ai_application}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AiApplication getAiApplication(@Nullable AiApplicationName name) { + GetAiApplicationRequest request = + GetAiApplicationRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getAiApplication(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single AI Application. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   String name = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString();
+   *   AiApplication response = agentRegistryClient.getAiApplication(name);
+   * }
+   * }
+ * + * @param name Required. Target AI Application resource name. Format: + * `projects/{project}/locations/{location}/aiApplications/{ai_application}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AiApplication getAiApplication(String name) { + GetAiApplicationRequest request = GetAiApplicationRequest.newBuilder().setName(name).build(); + return getAiApplication(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single AI Application. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetAiApplicationRequest request =
+   *       GetAiApplicationRequest.newBuilder()
+   *           .setName(
+   *               AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString())
+   *           .build();
+   *   AiApplication response = agentRegistryClient.getAiApplication(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AiApplication getAiApplication(GetAiApplicationRequest request) { + return getAiApplicationCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single AI Application. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   GetAiApplicationRequest request =
+   *       GetAiApplicationRequest.newBuilder()
+   *           .setName(
+   *               AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString())
+   *           .build();
+   *   ApiFuture future =
+   *       agentRegistryClient.getAiApplicationCallable().futureCall(request);
+   *   // Do something.
+   *   AiApplication response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getAiApplicationCallable() { + return stub.getAiApplicationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AI Applications in a given project and location. * *

Sample code: * @@ -1510,27 +5725,27 @@ public final ListMcpServersPagedResponse listMcpServers(ListMcpServersRequest re * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - * for (McpServer element : agentRegistryClient.searchMcpServers(parent).iterateAll()) { + * for (AiApplication element : agentRegistryClient.listAiApplications(parent).iterateAll()) { * // doThingsWith(element); * } * } * } * - * @param parent Required. Parent value for SearchMcpServersRequest. Format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent project and location to query. Format: + * `projects/{project}/locations/{location}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final SearchMcpServersPagedResponse searchMcpServers(@Nullable LocationName parent) { - SearchMcpServersRequest request = - SearchMcpServersRequest.newBuilder() + public final ListAiApplicationsPagedResponse listAiApplications(@Nullable LocationName parent) { + ListAiApplicationsRequest request = + ListAiApplicationsRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) .build(); - return searchMcpServers(request); + return listAiApplications(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Searches McpServers in a given project and location. + * Lists AI Applications in a given project and location. * *

Sample code: * @@ -1542,25 +5757,25 @@ public final SearchMcpServersPagedResponse searchMcpServers(@Nullable LocationNa * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { * String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); - * for (McpServer element : agentRegistryClient.searchMcpServers(parent).iterateAll()) { + * for (AiApplication element : agentRegistryClient.listAiApplications(parent).iterateAll()) { * // doThingsWith(element); * } * } * } * - * @param parent Required. Parent value for SearchMcpServersRequest. Format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent project and location to query. Format: + * `projects/{project}/locations/{location}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final SearchMcpServersPagedResponse searchMcpServers(String parent) { - SearchMcpServersRequest request = - SearchMcpServersRequest.newBuilder().setParent(parent).build(); - return searchMcpServers(request); + public final ListAiApplicationsPagedResponse listAiApplications(String parent) { + ListAiApplicationsRequest request = + ListAiApplicationsRequest.newBuilder().setParent(parent).build(); + return listAiApplications(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Searches McpServers in a given project and location. + * Lists AI Applications in a given project and location. * *

Sample code: * @@ -1571,14 +5786,15 @@ public final SearchMcpServersPagedResponse searchMcpServers(String parent) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * SearchMcpServersRequest request = - * SearchMcpServersRequest.newBuilder() + * ListAiApplicationsRequest request = + * ListAiApplicationsRequest.newBuilder() * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setSearchString("searchString120312793") * .setPageSize(883849137) * .setPageToken("pageToken873572522") + * .setFilter("filter-1274492040") + * .setOrderBy("orderBy-1207110587") * .build(); - * for (McpServer element : agentRegistryClient.searchMcpServers(request).iterateAll()) { + * for (AiApplication element : agentRegistryClient.listAiApplications(request).iterateAll()) { * // doThingsWith(element); * } * } @@ -1587,13 +5803,14 @@ public final SearchMcpServersPagedResponse searchMcpServers(String parent) { * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final SearchMcpServersPagedResponse searchMcpServers(SearchMcpServersRequest request) { - return searchMcpServersPagedCallable().call(request); + public final ListAiApplicationsPagedResponse listAiApplications( + ListAiApplicationsRequest request) { + return listAiApplicationsPagedCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Searches McpServers in a given project and location. + * Lists AI Applications in a given project and location. * *

Sample code: * @@ -1604,30 +5821,31 @@ public final SearchMcpServersPagedResponse searchMcpServers(SearchMcpServersRequ * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * SearchMcpServersRequest request = - * SearchMcpServersRequest.newBuilder() + * ListAiApplicationsRequest request = + * ListAiApplicationsRequest.newBuilder() * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setSearchString("searchString120312793") * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .build(); - * ApiFuture future = - * agentRegistryClient.searchMcpServersPagedCallable().futureCall(request); + * .setFilter("filter-1274492040") + * .setOrderBy("orderBy-1207110587") + * .build(); + * ApiFuture future = + * agentRegistryClient.listAiApplicationsPagedCallable().futureCall(request); * // Do something. - * for (McpServer element : future.get().iterateAll()) { + * for (AiApplication element : future.get().iterateAll()) { * // doThingsWith(element); * } * } * } */ - public final UnaryCallable - searchMcpServersPagedCallable() { - return stub.searchMcpServersPagedCallable(); + public final UnaryCallable + listAiApplicationsPagedCallable() { + return stub.listAiApplicationsPagedCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Searches McpServers in a given project and location. + * Lists AI Applications in a given project and location. * *

Sample code: * @@ -1638,17 +5856,18 @@ public final SearchMcpServersPagedResponse searchMcpServers(SearchMcpServersRequ * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * SearchMcpServersRequest request = - * SearchMcpServersRequest.newBuilder() + * ListAiApplicationsRequest request = + * ListAiApplicationsRequest.newBuilder() * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setSearchString("searchString120312793") * .setPageSize(883849137) * .setPageToken("pageToken873572522") + * .setFilter("filter-1274492040") + * .setOrderBy("orderBy-1207110587") * .build(); * while (true) { - * SearchMcpServersResponse response = - * agentRegistryClient.searchMcpServersCallable().call(request); - * for (McpServer element : response.getMcpServersList()) { + * ListAiApplicationsResponse response = + * agentRegistryClient.listAiApplicationsCallable().call(request); + * for (AiApplication element : response.getAiApplicationsList()) { * // doThingsWith(element); * } * String nextPageToken = response.getNextPageToken(); @@ -1661,14 +5880,14 @@ public final SearchMcpServersPagedResponse searchMcpServers(SearchMcpServersRequ * } * } */ - public final UnaryCallable - searchMcpServersCallable() { - return stub.searchMcpServersCallable(); + public final UnaryCallable + listAiApplicationsCallable() { + return stub.listAiApplicationsCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single McpServer. + * Gets details of a single Agent under an AI Application. * *

Sample code: * @@ -1679,23 +5898,28 @@ public final SearchMcpServersPagedResponse searchMcpServers(SearchMcpServersRequ * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * McpServerName name = McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]"); - * McpServer response = agentRegistryClient.getMcpServer(name); + * AgentName name = + * AgentName.ofProjectLocationAiApplicationAgentName( + * "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]"); + * Agent response = agentRegistryClient.getAiApplicationAgent(name); * } * } * - * @param name Required. Name of the resource + * @param name Required. Name of the resource. Format: + * `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final McpServer getMcpServer(@Nullable McpServerName name) { - GetMcpServerRequest request = - GetMcpServerRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return getMcpServer(request); + public final Agent getAiApplicationAgent(@Nullable AgentName name) { + GetAiApplicationAgentRequest request = + GetAiApplicationAgentRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getAiApplicationAgent(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single McpServer. + * Gets details of a single Agent under an AI Application. * *

Sample code: * @@ -1706,22 +5930,25 @@ public final McpServer getMcpServer(@Nullable McpServerName name) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String name = McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]").toString(); - * McpServer response = agentRegistryClient.getMcpServer(name); + * String name = + * AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]").toString(); + * Agent response = agentRegistryClient.getAiApplicationAgent(name); * } * } * - * @param name Required. Name of the resource + * @param name Required. Name of the resource. Format: + * `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final McpServer getMcpServer(String name) { - GetMcpServerRequest request = GetMcpServerRequest.newBuilder().setName(name).build(); - return getMcpServer(request); + public final Agent getAiApplicationAgent(String name) { + GetAiApplicationAgentRequest request = + GetAiApplicationAgentRequest.newBuilder().setName(name).build(); + return getAiApplicationAgent(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single McpServer. + * Gets details of a single Agent under an AI Application. * *

Sample code: * @@ -1732,24 +5959,27 @@ public final McpServer getMcpServer(String name) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * GetMcpServerRequest request = - * GetMcpServerRequest.newBuilder() - * .setName(McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]").toString()) + * GetAiApplicationAgentRequest request = + * GetAiApplicationAgentRequest.newBuilder() + * .setName( + * AgentName.ofProjectLocationAiApplicationAgentName( + * "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]") + * .toString()) * .build(); - * McpServer response = agentRegistryClient.getMcpServer(request); + * Agent response = agentRegistryClient.getAiApplicationAgent(request); * } * } * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final McpServer getMcpServer(GetMcpServerRequest request) { - return getMcpServerCallable().call(request); + public final Agent getAiApplicationAgent(GetAiApplicationAgentRequest request) { + return getAiApplicationAgentCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single McpServer. + * Gets details of a single Agent under an AI Application. * *

Sample code: * @@ -1760,23 +5990,27 @@ public final McpServer getMcpServer(GetMcpServerRequest request) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * GetMcpServerRequest request = - * GetMcpServerRequest.newBuilder() - * .setName(McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]").toString()) + * GetAiApplicationAgentRequest request = + * GetAiApplicationAgentRequest.newBuilder() + * .setName( + * AgentName.ofProjectLocationAiApplicationAgentName( + * "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]") + * .toString()) * .build(); - * ApiFuture future = agentRegistryClient.getMcpServerCallable().futureCall(request); + * ApiFuture future = + * agentRegistryClient.getAiApplicationAgentCallable().futureCall(request); * // Do something. - * McpServer response = future.get(); + * Agent response = future.get(); * } * } */ - public final UnaryCallable getMcpServerCallable() { - return stub.getMcpServerCallable(); + public final UnaryCallable getAiApplicationAgentCallable() { + return stub.getAiApplicationAgentCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Services in a given project and location. + * Lists Agents under an AI Application. * *

Sample code: * @@ -1787,28 +6021,30 @@ public final UnaryCallable getMcpServerCallable( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - * for (Service element : agentRegistryClient.listServices(parent).iterateAll()) { + * AiApplicationName parent = + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + * for (Agent element : agentRegistryClient.listAiApplicationAgents(parent).iterateAll()) { * // doThingsWith(element); * } * } * } * - * @param parent Required. The project and location to list services in. Expected format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent value (AI Application) for ListAiApplicationAgentsRequest. + * Format: `projects/{project}/locations/{location}/aiApplications/{ai_application}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListServicesPagedResponse listServices(@Nullable LocationName parent) { - ListServicesRequest request = - ListServicesRequest.newBuilder() + public final ListAiApplicationAgentsPagedResponse listAiApplicationAgents( + @Nullable AiApplicationName parent) { + ListAiApplicationAgentsRequest request = + ListAiApplicationAgentsRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) .build(); - return listServices(request); + return listAiApplicationAgents(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Services in a given project and location. + * Lists Agents under an AI Application. * *

Sample code: * @@ -1819,25 +6055,27 @@ public final ListServicesPagedResponse listServices(@Nullable LocationName paren * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); - * for (Service element : agentRegistryClient.listServices(parent).iterateAll()) { + * String parent = + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString(); + * for (Agent element : agentRegistryClient.listAiApplicationAgents(parent).iterateAll()) { * // doThingsWith(element); * } * } * } * - * @param parent Required. The project and location to list services in. Expected format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent value (AI Application) for ListAiApplicationAgentsRequest. + * Format: `projects/{project}/locations/{location}/aiApplications/{ai_application}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListServicesPagedResponse listServices(String parent) { - ListServicesRequest request = ListServicesRequest.newBuilder().setParent(parent).build(); - return listServices(request); + public final ListAiApplicationAgentsPagedResponse listAiApplicationAgents(String parent) { + ListAiApplicationAgentsRequest request = + ListAiApplicationAgentsRequest.newBuilder().setParent(parent).build(); + return listAiApplicationAgents(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Services in a given project and location. + * Lists Agents under an AI Application. * *

Sample code: * @@ -1848,14 +6086,14 @@ public final ListServicesPagedResponse listServices(String parent) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListServicesRequest request = - * ListServicesRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * ListAiApplicationAgentsRequest request = + * ListAiApplicationAgentsRequest.newBuilder() + * .setParent( + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") * .build(); - * for (Service element : agentRegistryClient.listServices(request).iterateAll()) { + * for (Agent element : agentRegistryClient.listAiApplicationAgents(request).iterateAll()) { * // doThingsWith(element); * } * } @@ -1864,13 +6102,14 @@ public final ListServicesPagedResponse listServices(String parent) { * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListServicesPagedResponse listServices(ListServicesRequest request) { - return listServicesPagedCallable().call(request); + public final ListAiApplicationAgentsPagedResponse listAiApplicationAgents( + ListAiApplicationAgentsRequest request) { + return listAiApplicationAgentsPagedCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Services in a given project and location. + * Lists Agents under an AI Application. * *

Sample code: * @@ -1881,30 +6120,30 @@ public final ListServicesPagedResponse listServices(ListServicesRequest request) * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListServicesRequest request = - * ListServicesRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * ListAiApplicationAgentsRequest request = + * ListAiApplicationAgentsRequest.newBuilder() + * .setParent( + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") * .build(); - * ApiFuture future = - * agentRegistryClient.listServicesPagedCallable().futureCall(request); + * ApiFuture future = + * agentRegistryClient.listAiApplicationAgentsPagedCallable().futureCall(request); * // Do something. - * for (Service element : future.get().iterateAll()) { + * for (Agent element : future.get().iterateAll()) { * // doThingsWith(element); * } * } * } */ - public final UnaryCallable - listServicesPagedCallable() { - return stub.listServicesPagedCallable(); + public final UnaryCallable + listAiApplicationAgentsPagedCallable() { + return stub.listAiApplicationAgentsPagedCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Services in a given project and location. + * Lists Agents under an AI Application. * *

Sample code: * @@ -1915,16 +6154,17 @@ public final ListServicesPagedResponse listServices(ListServicesRequest request) * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListServicesRequest request = - * ListServicesRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * ListAiApplicationAgentsRequest request = + * ListAiApplicationAgentsRequest.newBuilder() + * .setParent( + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") * .build(); * while (true) { - * ListServicesResponse response = agentRegistryClient.listServicesCallable().call(request); - * for (Service element : response.getServicesList()) { + * ListAiApplicationAgentsResponse response = + * agentRegistryClient.listAiApplicationAgentsCallable().call(request); + * for (Agent element : response.getAgentsList()) { * // doThingsWith(element); * } * String nextPageToken = response.getNextPageToken(); @@ -1937,13 +6177,14 @@ public final ListServicesPagedResponse listServices(ListServicesRequest request) * } * } */ - public final UnaryCallable listServicesCallable() { - return stub.listServicesCallable(); + public final UnaryCallable + listAiApplicationAgentsCallable() { + return stub.listAiApplicationAgentsCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Service. + * Gets details of a single McpServer under an AI Application. * *

Sample code: * @@ -1954,24 +6195,28 @@ public final UnaryCallable listServic * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ServiceName name = ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]"); - * Service response = agentRegistryClient.getService(name); + * McpServerName name = + * McpServerName.ofProjectLocationAiApplicationMcpServerName( + * "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]"); + * McpServer response = agentRegistryClient.getAiApplicationMcpServer(name); * } * } * - * @param name Required. The name of the Service. Format: - * `projects/{project}/locations/{location}/services/{service}`. + * @param name Required. Name of the resource. Format: + * `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Service getService(@Nullable ServiceName name) { - GetServiceRequest request = - GetServiceRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return getService(request); + public final McpServer getAiApplicationMcpServer(@Nullable McpServerName name) { + GetAiApplicationMcpServerRequest request = + GetAiApplicationMcpServerRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getAiApplicationMcpServer(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Service. + * Gets details of a single McpServer under an AI Application. * *

Sample code: * @@ -1982,23 +6227,26 @@ public final Service getService(@Nullable ServiceName name) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String name = ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString(); - * Service response = agentRegistryClient.getService(name); + * String name = + * McpServerName.ofProjectLocationMcpServerName("[PROJECT]", "[LOCATION]", "[MCP_SERVER]") + * .toString(); + * McpServer response = agentRegistryClient.getAiApplicationMcpServer(name); * } * } * - * @param name Required. The name of the Service. Format: - * `projects/{project}/locations/{location}/services/{service}`. + * @param name Required. Name of the resource. Format: + * `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Service getService(String name) { - GetServiceRequest request = GetServiceRequest.newBuilder().setName(name).build(); - return getService(request); + public final McpServer getAiApplicationMcpServer(String name) { + GetAiApplicationMcpServerRequest request = + GetAiApplicationMcpServerRequest.newBuilder().setName(name).build(); + return getAiApplicationMcpServer(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Service. + * Gets details of a single McpServer under an AI Application. * *

Sample code: * @@ -2009,24 +6257,27 @@ public final Service getService(String name) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * GetServiceRequest request = - * GetServiceRequest.newBuilder() - * .setName(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString()) + * GetAiApplicationMcpServerRequest request = + * GetAiApplicationMcpServerRequest.newBuilder() + * .setName( + * McpServerName.ofProjectLocationAiApplicationMcpServerName( + * "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]") + * .toString()) * .build(); - * Service response = agentRegistryClient.getService(request); + * McpServer response = agentRegistryClient.getAiApplicationMcpServer(request); * } * } * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Service getService(GetServiceRequest request) { - return getServiceCallable().call(request); + public final McpServer getAiApplicationMcpServer(GetAiApplicationMcpServerRequest request) { + return getAiApplicationMcpServerCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Service. + * Gets details of a single McpServer under an AI Application. * *

Sample code: * @@ -2037,23 +6288,28 @@ public final Service getService(GetServiceRequest request) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * GetServiceRequest request = - * GetServiceRequest.newBuilder() - * .setName(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString()) + * GetAiApplicationMcpServerRequest request = + * GetAiApplicationMcpServerRequest.newBuilder() + * .setName( + * McpServerName.ofProjectLocationAiApplicationMcpServerName( + * "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]") + * .toString()) * .build(); - * ApiFuture future = agentRegistryClient.getServiceCallable().futureCall(request); + * ApiFuture future = + * agentRegistryClient.getAiApplicationMcpServerCallable().futureCall(request); * // Do something. - * Service response = future.get(); + * McpServer response = future.get(); * } * } */ - public final UnaryCallable getServiceCallable() { - return stub.getServiceCallable(); + public final UnaryCallable + getAiApplicationMcpServerCallable() { + return stub.getAiApplicationMcpServerCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new Service in a given project and location. + * Lists McpServers under an AI Application. * *

Sample code: * @@ -2064,36 +6320,31 @@ public final UnaryCallable getServiceCallable() { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - * Service service = Service.newBuilder().build(); - * String serviceId = "serviceId-194185552"; - * Service response = agentRegistryClient.createServiceAsync(parent, service, serviceId).get(); + * AiApplicationName parent = + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + * for (McpServer element : + * agentRegistryClient.listAiApplicationMcpServers(parent).iterateAll()) { + * // doThingsWith(element); + * } * } * } * - * @param parent Required. The project and location to create the Service in. Expected format: - * `projects/{project}/locations/{location}`. - * @param service Required. The Service resource that is being created. Format: - * `projects/{project}/locations/{location}/services/{service}`. - * @param serviceId Required. The ID to use for the service, which will become the final component - * of the service's resource name. - *

This value should be 4-63 characters, and valid characters are `/[a-z][0-9]-/`. + * @param parent Required. Parent value (AI Application) for ListAiApplicationMcpServersRequest. + * Format: `projects/{project}/locations/{location}/aiApplications/{ai_application}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture createServiceAsync( - @Nullable LocationName parent, Service service, String serviceId) { - CreateServiceRequest request = - CreateServiceRequest.newBuilder() + public final ListAiApplicationMcpServersPagedResponse listAiApplicationMcpServers( + @Nullable AiApplicationName parent) { + ListAiApplicationMcpServersRequest request = + ListAiApplicationMcpServersRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) - .setService(service) - .setServiceId(serviceId) .build(); - return createServiceAsync(request); + return listAiApplicationMcpServers(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new Service in a given project and location. + * Lists McpServers under an AI Application. * *

Sample code: * @@ -2104,36 +6355,168 @@ public final OperationFuture createServiceAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); - * Service service = Service.newBuilder().build(); - * String serviceId = "serviceId-194185552"; - * Service response = agentRegistryClient.createServiceAsync(parent, service, serviceId).get(); + * String parent = + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString(); + * for (McpServer element : + * agentRegistryClient.listAiApplicationMcpServers(parent).iterateAll()) { + * // doThingsWith(element); + * } * } * } * - * @param parent Required. The project and location to create the Service in. Expected format: - * `projects/{project}/locations/{location}`. - * @param service Required. The Service resource that is being created. Format: - * `projects/{project}/locations/{location}/services/{service}`. - * @param serviceId Required. The ID to use for the service, which will become the final component - * of the service's resource name. - *

This value should be 4-63 characters, and valid characters are `/[a-z][0-9]-/`. + * @param parent Required. Parent value (AI Application) for ListAiApplicationMcpServersRequest. + * Format: `projects/{project}/locations/{location}/aiApplications/{ai_application}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAiApplicationMcpServersPagedResponse listAiApplicationMcpServers(String parent) { + ListAiApplicationMcpServersRequest request = + ListAiApplicationMcpServersRequest.newBuilder().setParent(parent).build(); + return listAiApplicationMcpServers(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists McpServers under an AI Application. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListAiApplicationMcpServersRequest request =
+   *       ListAiApplicationMcpServersRequest.newBuilder()
+   *           .setParent(
+   *               AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (McpServer element :
+   *       agentRegistryClient.listAiApplicationMcpServers(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAiApplicationMcpServersPagedResponse listAiApplicationMcpServers( + ListAiApplicationMcpServersRequest request) { + return listAiApplicationMcpServersPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists McpServers under an AI Application. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListAiApplicationMcpServersRequest request =
+   *       ListAiApplicationMcpServersRequest.newBuilder()
+   *           .setParent(
+   *               AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future =
+   *       agentRegistryClient.listAiApplicationMcpServersPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (McpServer element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersPagedResponse> + listAiApplicationMcpServersPagedCallable() { + return stub.listAiApplicationMcpServersPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists McpServers under an AI Application. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   ListAiApplicationMcpServersRequest request =
+   *       ListAiApplicationMcpServersRequest.newBuilder()
+   *           .setParent(
+   *               AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     ListAiApplicationMcpServersResponse response =
+   *         agentRegistryClient.listAiApplicationMcpServersCallable().call(request);
+   *     for (McpServer element : response.getMcpServersList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersResponse> + listAiApplicationMcpServersCallable() { + return stub.listAiApplicationMcpServersCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Finding. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
+   *   FindingName name = FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]");
+   *   Finding response = agentRegistryClient.getFinding(name);
+   * }
+   * }
+ * + * @param name Required. The name of the Finding to retrieve. Format: + * `projects/{project}/locations/{location}/findings/{finding}`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture createServiceAsync( - String parent, Service service, String serviceId) { - CreateServiceRequest request = - CreateServiceRequest.newBuilder() - .setParent(parent) - .setService(service) - .setServiceId(serviceId) - .build(); - return createServiceAsync(request); + public final Finding getFinding(@Nullable FindingName name) { + GetFindingRequest request = + GetFindingRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getFinding(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new Service in a given project and location. + * Gets details of a single Finding. * *

Sample code: * @@ -2144,28 +6527,23 @@ public final OperationFuture createServiceAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * CreateServiceRequest request = - * CreateServiceRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setServiceId("serviceId-194185552") - * .setService(Service.newBuilder().build()) - * .setRequestId("requestId693933066") - * .build(); - * Service response = agentRegistryClient.createServiceAsync(request).get(); + * String name = FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]").toString(); + * Finding response = agentRegistryClient.getFinding(name); * } * } * - * @param request The request object containing all of the parameters for the API call. + * @param name Required. The name of the Finding to retrieve. Format: + * `projects/{project}/locations/{location}/findings/{finding}`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture createServiceAsync( - CreateServiceRequest request) { - return createServiceOperationCallable().futureCall(request); + public final Finding getFinding(String name) { + GetFindingRequest request = GetFindingRequest.newBuilder().setName(name).build(); + return getFinding(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new Service in a given project and location. + * Gets details of a single Finding. * *

Sample code: * @@ -2176,28 +6554,24 @@ public final OperationFuture createServiceAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * CreateServiceRequest request = - * CreateServiceRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setServiceId("serviceId-194185552") - * .setService(Service.newBuilder().build()) - * .setRequestId("requestId693933066") + * GetFindingRequest request = + * GetFindingRequest.newBuilder() + * .setName(FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]").toString()) * .build(); - * OperationFuture future = - * agentRegistryClient.createServiceOperationCallable().futureCall(request); - * // Do something. - * Service response = future.get(); + * Finding response = agentRegistryClient.getFinding(request); * } * } + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationCallable - createServiceOperationCallable() { - return stub.createServiceOperationCallable(); + public final Finding getFinding(GetFindingRequest request) { + return getFindingCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new Service in a given project and location. + * Gets details of a single Finding. * *

Sample code: * @@ -2208,26 +6582,23 @@ public final OperationFuture createServiceAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * CreateServiceRequest request = - * CreateServiceRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setServiceId("serviceId-194185552") - * .setService(Service.newBuilder().build()) - * .setRequestId("requestId693933066") + * GetFindingRequest request = + * GetFindingRequest.newBuilder() + * .setName(FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]").toString()) * .build(); - * ApiFuture future = agentRegistryClient.createServiceCallable().futureCall(request); + * ApiFuture future = agentRegistryClient.getFindingCallable().futureCall(request); * // Do something. - * Operation response = future.get(); + * Finding response = future.get(); * } * } */ - public final UnaryCallable createServiceCallable() { - return stub.createServiceCallable(); + public final UnaryCallable getFindingCallable() { + return stub.getFindingCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Updates the parameters of a single Service. + * Lists Findings in a given project and location. * *

Sample code: * @@ -2238,30 +6609,28 @@ public final UnaryCallable createServiceCallabl * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * Service service = Service.newBuilder().build(); - * FieldMask updateMask = FieldMask.newBuilder().build(); - * Service response = agentRegistryClient.updateServiceAsync(service, updateMask).get(); + * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + * for (Finding element : agentRegistryClient.listFindings(parent).iterateAll()) { + * // doThingsWith(element); + * } * } * } * - * @param service Required. The Service resource that is being updated. Format: - * `projects/{project}/locations/{location}/services/{service}`. - * @param updateMask Optional. Field mask is used to specify the fields to be overwritten in the - * Service resource by the update. The fields specified in the update_mask are relative to the - * resource, not the full request. A field will be overwritten if it is in the mask. If the - * user does not provide a mask then all fields present in the request will be overwritten. + * @param parent Required. Parent value for ListFindingsRequest. Format: + * `projects/{project}/locations/{location}`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture updateServiceAsync( - Service service, FieldMask updateMask) { - UpdateServiceRequest request = - UpdateServiceRequest.newBuilder().setService(service).setUpdateMask(updateMask).build(); - return updateServiceAsync(request); + public final ListFindingsPagedResponse listFindings(@Nullable LocationName parent) { + ListFindingsRequest request = + ListFindingsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listFindings(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Updates the parameters of a single Service. + * Lists Findings in a given project and location. * *

Sample code: * @@ -2272,27 +6641,25 @@ public final OperationFuture updateServiceAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * UpdateServiceRequest request = - * UpdateServiceRequest.newBuilder() - * .setUpdateMask(FieldMask.newBuilder().build()) - * .setService(Service.newBuilder().build()) - * .setRequestId("requestId693933066") - * .build(); - * Service response = agentRegistryClient.updateServiceAsync(request).get(); + * String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + * for (Finding element : agentRegistryClient.listFindings(parent).iterateAll()) { + * // doThingsWith(element); + * } * } * } * - * @param request The request object containing all of the parameters for the API call. + * @param parent Required. Parent value for ListFindingsRequest. Format: + * `projects/{project}/locations/{location}`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture updateServiceAsync( - UpdateServiceRequest request) { - return updateServiceOperationCallable().futureCall(request); + public final ListFindingsPagedResponse listFindings(String parent) { + ListFindingsRequest request = ListFindingsRequest.newBuilder().setParent(parent).build(); + return listFindings(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Updates the parameters of a single Service. + * Lists Findings in a given project and location. * *

Sample code: * @@ -2303,27 +6670,30 @@ public final OperationFuture updateServiceAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * UpdateServiceRequest request = - * UpdateServiceRequest.newBuilder() - * .setUpdateMask(FieldMask.newBuilder().build()) - * .setService(Service.newBuilder().build()) - * .setRequestId("requestId693933066") + * ListFindingsRequest request = + * ListFindingsRequest.newBuilder() + * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * .setPageSize(883849137) + * .setPageToken("pageToken873572522") + * .setFilter("filter-1274492040") + * .setOrderBy("orderBy-1207110587") * .build(); - * OperationFuture future = - * agentRegistryClient.updateServiceOperationCallable().futureCall(request); - * // Do something. - * Service response = future.get(); + * for (Finding element : agentRegistryClient.listFindings(request).iterateAll()) { + * // doThingsWith(element); + * } * } * } + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationCallable - updateServiceOperationCallable() { - return stub.updateServiceOperationCallable(); + public final ListFindingsPagedResponse listFindings(ListFindingsRequest request) { + return listFindingsPagedCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Updates the parameters of a single Service. + * Lists Findings in a given project and location. * *

Sample code: * @@ -2334,25 +6704,31 @@ public final OperationFuture updateServiceAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * UpdateServiceRequest request = - * UpdateServiceRequest.newBuilder() - * .setUpdateMask(FieldMask.newBuilder().build()) - * .setService(Service.newBuilder().build()) - * .setRequestId("requestId693933066") + * ListFindingsRequest request = + * ListFindingsRequest.newBuilder() + * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * .setPageSize(883849137) + * .setPageToken("pageToken873572522") + * .setFilter("filter-1274492040") + * .setOrderBy("orderBy-1207110587") * .build(); - * ApiFuture future = agentRegistryClient.updateServiceCallable().futureCall(request); + * ApiFuture future = + * agentRegistryClient.listFindingsPagedCallable().futureCall(request); * // Do something. - * Operation response = future.get(); + * for (Finding element : future.get().iterateAll()) { + * // doThingsWith(element); + * } * } * } */ - public final UnaryCallable updateServiceCallable() { - return stub.updateServiceCallable(); + public final UnaryCallable + listFindingsPagedCallable() { + return stub.listFindingsPagedCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Deletes a single Service. + * Lists Findings in a given project and location. * *

Sample code: * @@ -2363,25 +6739,36 @@ public final UnaryCallable updateServiceCallabl * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ServiceName name = ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]"); - * agentRegistryClient.deleteServiceAsync(name).get(); + * ListFindingsRequest request = + * ListFindingsRequest.newBuilder() + * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * .setPageSize(883849137) + * .setPageToken("pageToken873572522") + * .setFilter("filter-1274492040") + * .setOrderBy("orderBy-1207110587") + * .build(); + * while (true) { + * ListFindingsResponse response = agentRegistryClient.listFindingsCallable().call(request); + * for (Finding element : response.getFindingsList()) { + * // doThingsWith(element); + * } + * String nextPageToken = response.getNextPageToken(); + * if (!Strings.isNullOrEmpty(nextPageToken)) { + * request = request.toBuilder().setPageToken(nextPageToken).build(); + * } else { + * break; + * } + * } * } * } - * - * @param name Required. The name of the Service. Format: - * `projects/{project}/locations/{location}/services/{service}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture deleteServiceAsync( - @Nullable ServiceName name) { - DeleteServiceRequest request = - DeleteServiceRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return deleteServiceAsync(request); + public final UnaryCallable listFindingsCallable() { + return stub.listFindingsCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Deletes a single Service. + * Gets details of a single Endpoint under an AI Application. * *

Sample code: * @@ -2392,23 +6779,28 @@ public final OperationFuture deleteServiceAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String name = ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString(); - * agentRegistryClient.deleteServiceAsync(name).get(); + * EndpointName name = + * EndpointName.ofProjectLocationAiApplicationEndpointName( + * "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]"); + * Endpoint response = agentRegistryClient.getAiApplicationEndpoint(name); * } * } * - * @param name Required. The name of the Service. Format: - * `projects/{project}/locations/{location}/services/{service}`. + * @param name Required. Name of the resource. Format: + * `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture deleteServiceAsync(String name) { - DeleteServiceRequest request = DeleteServiceRequest.newBuilder().setName(name).build(); - return deleteServiceAsync(request); + public final Endpoint getAiApplicationEndpoint(@Nullable EndpointName name) { + GetAiApplicationEndpointRequest request = + GetAiApplicationEndpointRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getAiApplicationEndpoint(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Deletes a single Service. + * Gets details of a single Endpoint under an AI Application. * *

Sample code: * @@ -2419,26 +6811,26 @@ public final OperationFuture deleteServiceAsync(String * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * DeleteServiceRequest request = - * DeleteServiceRequest.newBuilder() - * .setName(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString()) - * .setRequestId("requestId693933066") - * .build(); - * agentRegistryClient.deleteServiceAsync(request).get(); + * String name = + * EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]") + * .toString(); + * Endpoint response = agentRegistryClient.getAiApplicationEndpoint(name); * } * } * - * @param request The request object containing all of the parameters for the API call. + * @param name Required. Name of the resource. Format: + * `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture deleteServiceAsync( - DeleteServiceRequest request) { - return deleteServiceOperationCallable().futureCall(request); + public final Endpoint getAiApplicationEndpoint(String name) { + GetAiApplicationEndpointRequest request = + GetAiApplicationEndpointRequest.newBuilder().setName(name).build(); + return getAiApplicationEndpoint(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Deletes a single Service. + * Gets details of a single Endpoint under an AI Application. * *

Sample code: * @@ -2449,26 +6841,27 @@ public final OperationFuture deleteServiceAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * DeleteServiceRequest request = - * DeleteServiceRequest.newBuilder() - * .setName(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString()) - * .setRequestId("requestId693933066") + * GetAiApplicationEndpointRequest request = + * GetAiApplicationEndpointRequest.newBuilder() + * .setName( + * EndpointName.ofProjectLocationAiApplicationEndpointName( + * "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]") + * .toString()) * .build(); - * OperationFuture future = - * agentRegistryClient.deleteServiceOperationCallable().futureCall(request); - * // Do something. - * future.get(); + * Endpoint response = agentRegistryClient.getAiApplicationEndpoint(request); * } * } + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationCallable - deleteServiceOperationCallable() { - return stub.deleteServiceOperationCallable(); + public final Endpoint getAiApplicationEndpoint(GetAiApplicationEndpointRequest request) { + return getAiApplicationEndpointCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Deletes a single Service. + * Gets details of a single Endpoint under an AI Application. * *

Sample code: * @@ -2479,24 +6872,28 @@ public final OperationFuture deleteServiceAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * DeleteServiceRequest request = - * DeleteServiceRequest.newBuilder() - * .setName(ServiceName.of("[PROJECT]", "[LOCATION]", "[SERVICE]").toString()) - * .setRequestId("requestId693933066") + * GetAiApplicationEndpointRequest request = + * GetAiApplicationEndpointRequest.newBuilder() + * .setName( + * EndpointName.ofProjectLocationAiApplicationEndpointName( + * "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]") + * .toString()) * .build(); - * ApiFuture future = agentRegistryClient.deleteServiceCallable().futureCall(request); + * ApiFuture future = + * agentRegistryClient.getAiApplicationEndpointCallable().futureCall(request); * // Do something. - * future.get(); + * Endpoint response = future.get(); * } * } */ - public final UnaryCallable deleteServiceCallable() { - return stub.deleteServiceCallable(); + public final UnaryCallable + getAiApplicationEndpointCallable() { + return stub.getAiApplicationEndpointCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Bindings in a given project and location. + * Lists Endpoints under an AI Application. * *

Sample code: * @@ -2507,28 +6904,30 @@ public final UnaryCallable deleteServiceCallabl * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - * for (Binding element : agentRegistryClient.listBindings(parent).iterateAll()) { + * AiApplicationName parent = + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + * for (Endpoint element : agentRegistryClient.listAiApplicationEndpoints(parent).iterateAll()) { * // doThingsWith(element); * } * } * } * - * @param parent Required. The project and location to list bindings in. Expected format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent value (AI Application) for ListAiApplicationEndpointsRequest. + * Format: `projects/{project}/locations/{location}/aiApplications/{ai_application}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListBindingsPagedResponse listBindings(@Nullable LocationName parent) { - ListBindingsRequest request = - ListBindingsRequest.newBuilder() + public final ListAiApplicationEndpointsPagedResponse listAiApplicationEndpoints( + @Nullable AiApplicationName parent) { + ListAiApplicationEndpointsRequest request = + ListAiApplicationEndpointsRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) .build(); - return listBindings(request); + return listAiApplicationEndpoints(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Bindings in a given project and location. + * Lists Endpoints under an AI Application. * *

Sample code: * @@ -2539,25 +6938,27 @@ public final ListBindingsPagedResponse listBindings(@Nullable LocationName paren * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); - * for (Binding element : agentRegistryClient.listBindings(parent).iterateAll()) { + * String parent = + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString(); + * for (Endpoint element : agentRegistryClient.listAiApplicationEndpoints(parent).iterateAll()) { * // doThingsWith(element); * } * } * } * - * @param parent Required. The project and location to list bindings in. Expected format: - * `projects/{project}/locations/{location}`. + * @param parent Required. Parent value (AI Application) for ListAiApplicationEndpointsRequest. + * Format: `projects/{project}/locations/{location}/aiApplications/{ai_application}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListBindingsPagedResponse listBindings(String parent) { - ListBindingsRequest request = ListBindingsRequest.newBuilder().setParent(parent).build(); - return listBindings(request); + public final ListAiApplicationEndpointsPagedResponse listAiApplicationEndpoints(String parent) { + ListAiApplicationEndpointsRequest request = + ListAiApplicationEndpointsRequest.newBuilder().setParent(parent).build(); + return listAiApplicationEndpoints(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Bindings in a given project and location. + * Lists Endpoints under an AI Application. * *

Sample code: * @@ -2568,15 +6969,15 @@ public final ListBindingsPagedResponse listBindings(String parent) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListBindingsRequest request = - * ListBindingsRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * ListAiApplicationEndpointsRequest request = + * ListAiApplicationEndpointsRequest.newBuilder() + * .setParent( + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") - * .setOrderBy("orderBy-1207110587") * .build(); - * for (Binding element : agentRegistryClient.listBindings(request).iterateAll()) { + * for (Endpoint element : + * agentRegistryClient.listAiApplicationEndpoints(request).iterateAll()) { * // doThingsWith(element); * } * } @@ -2585,13 +6986,14 @@ public final ListBindingsPagedResponse listBindings(String parent) { * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListBindingsPagedResponse listBindings(ListBindingsRequest request) { - return listBindingsPagedCallable().call(request); + public final ListAiApplicationEndpointsPagedResponse listAiApplicationEndpoints( + ListAiApplicationEndpointsRequest request) { + return listAiApplicationEndpointsPagedCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Bindings in a given project and location. + * Lists Endpoints under an AI Application. * *

Sample code: * @@ -2602,31 +7004,31 @@ public final ListBindingsPagedResponse listBindings(ListBindingsRequest request) * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListBindingsRequest request = - * ListBindingsRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * ListAiApplicationEndpointsRequest request = + * ListAiApplicationEndpointsRequest.newBuilder() + * .setParent( + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") - * .setOrderBy("orderBy-1207110587") * .build(); - * ApiFuture future = - * agentRegistryClient.listBindingsPagedCallable().futureCall(request); + * ApiFuture future = + * agentRegistryClient.listAiApplicationEndpointsPagedCallable().futureCall(request); * // Do something. - * for (Binding element : future.get().iterateAll()) { + * for (Endpoint element : future.get().iterateAll()) { * // doThingsWith(element); * } * } * } */ - public final UnaryCallable - listBindingsPagedCallable() { - return stub.listBindingsPagedCallable(); + public final UnaryCallable< + ListAiApplicationEndpointsRequest, ListAiApplicationEndpointsPagedResponse> + listAiApplicationEndpointsPagedCallable() { + return stub.listAiApplicationEndpointsPagedCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists Bindings in a given project and location. + * Lists Endpoints under an AI Application. * *

Sample code: * @@ -2637,17 +7039,17 @@ public final ListBindingsPagedResponse listBindings(ListBindingsRequest request) * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * ListBindingsRequest request = - * ListBindingsRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + * ListAiApplicationEndpointsRequest request = + * ListAiApplicationEndpointsRequest.newBuilder() + * .setParent( + * AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) * .setPageSize(883849137) * .setPageToken("pageToken873572522") - * .setFilter("filter-1274492040") - * .setOrderBy("orderBy-1207110587") * .build(); - * while (true) { - * ListBindingsResponse response = agentRegistryClient.listBindingsCallable().call(request); - * for (Binding element : response.getBindingsList()) { + * while (true) { + * ListAiApplicationEndpointsResponse response = + * agentRegistryClient.listAiApplicationEndpointsCallable().call(request); + * for (Endpoint element : response.getEndpointsList()) { * // doThingsWith(element); * } * String nextPageToken = response.getNextPageToken(); @@ -2660,13 +7062,18 @@ public final ListBindingsPagedResponse listBindings(ListBindingsRequest request) * } * } */ - public final UnaryCallable listBindingsCallable() { - return stub.listBindingsCallable(); + public final UnaryCallable + listAiApplicationEndpointsCallable() { + return stub.listAiApplicationEndpointsCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Binding. + * ========================================================================= # Skill Encryption + * Spec Service Methods + * + *

Gets the customer-managed encryption key (CMEK) configuration for Skills in a specific + * project and location. * *

Sample code: * @@ -2677,24 +7084,30 @@ public final UnaryCallable listBindin * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * BindingName name = BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]"); - * Binding response = agentRegistryClient.getBinding(name); + * SkillEncryptionSpecName name = SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]"); + * SkillEncryptionSpec response = agentRegistryClient.getSkillEncryptionSpec(name); * } * } * - * @param name Required. The name of the Binding. Format: - * `projects/{project}/locations/{location}/bindings/{binding}`. + * @param name Required. The name of the SkillEncryptionSpec to retrieve. Format: + * `projects/{project}/locations/{location}/skillEncryptionSpec`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Binding getBinding(@Nullable BindingName name) { - GetBindingRequest request = - GetBindingRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return getBinding(request); + public final SkillEncryptionSpec getSkillEncryptionSpec(@Nullable SkillEncryptionSpecName name) { + GetSkillEncryptionSpecRequest request = + GetSkillEncryptionSpecRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getSkillEncryptionSpec(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Binding. + * ========================================================================= # Skill Encryption + * Spec Service Methods + * + *

Gets the customer-managed encryption key (CMEK) configuration for Skills in a specific + * project and location. * *

Sample code: * @@ -2705,23 +7118,28 @@ public final Binding getBinding(@Nullable BindingName name) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String name = BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString(); - * Binding response = agentRegistryClient.getBinding(name); + * String name = SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString(); + * SkillEncryptionSpec response = agentRegistryClient.getSkillEncryptionSpec(name); * } * } * - * @param name Required. The name of the Binding. Format: - * `projects/{project}/locations/{location}/bindings/{binding}`. + * @param name Required. The name of the SkillEncryptionSpec to retrieve. Format: + * `projects/{project}/locations/{location}/skillEncryptionSpec`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Binding getBinding(String name) { - GetBindingRequest request = GetBindingRequest.newBuilder().setName(name).build(); - return getBinding(request); + public final SkillEncryptionSpec getSkillEncryptionSpec(String name) { + GetSkillEncryptionSpecRequest request = + GetSkillEncryptionSpecRequest.newBuilder().setName(name).build(); + return getSkillEncryptionSpec(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Binding. + * ========================================================================= # Skill Encryption + * Spec Service Methods + * + *

Gets the customer-managed encryption key (CMEK) configuration for Skills in a specific + * project and location. * *

Sample code: * @@ -2732,24 +7150,28 @@ public final Binding getBinding(String name) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * GetBindingRequest request = - * GetBindingRequest.newBuilder() - * .setName(BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString()) + * GetSkillEncryptionSpecRequest request = + * GetSkillEncryptionSpecRequest.newBuilder() + * .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) * .build(); - * Binding response = agentRegistryClient.getBinding(request); + * SkillEncryptionSpec response = agentRegistryClient.getSkillEncryptionSpec(request); * } * } * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Binding getBinding(GetBindingRequest request) { - return getBindingCallable().call(request); + public final SkillEncryptionSpec getSkillEncryptionSpec(GetSkillEncryptionSpecRequest request) { + return getSkillEncryptionSpecCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets details of a single Binding. + * ========================================================================= # Skill Encryption + * Spec Service Methods + * + *

Gets the customer-managed encryption key (CMEK) configuration for Skills in a specific + * project and location. * *

Sample code: * @@ -2760,63 +7182,29 @@ public final Binding getBinding(GetBindingRequest request) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * GetBindingRequest request = - * GetBindingRequest.newBuilder() - * .setName(BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString()) + * GetSkillEncryptionSpecRequest request = + * GetSkillEncryptionSpecRequest.newBuilder() + * .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) * .build(); - * ApiFuture future = agentRegistryClient.getBindingCallable().futureCall(request); + * ApiFuture future = + * agentRegistryClient.getSkillEncryptionSpecCallable().futureCall(request); * // Do something. - * Binding response = future.get(); + * SkillEncryptionSpec response = future.get(); * } * } */ - public final UnaryCallable getBindingCallable() { - return stub.getBindingCallable(); + public final UnaryCallable + getSkillEncryptionSpecCallable() { + return stub.getSkillEncryptionSpecCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new Binding in a given project and location. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
-   *   Binding binding = Binding.newBuilder().build();
-   *   String bindingId = "bindingId-920966528";
-   *   Binding response = agentRegistryClient.createBindingAsync(parent, binding, bindingId).get();
-   * }
-   * }
+ * Updates the customer-managed encryption key (CMEK) configuration for Skills in a specific + * project and location. * - * @param parent Required. The project and location to create the Binding in. Expected format: - * `projects/{project}/locations/{location}`. - * @param binding Required. The Binding resource that is being created. - * @param bindingId Required. The ID to use for the binding, which will become the final component - * of the binding's resource name. - *

This value should be 4-63 characters, and must conform to RFC-1034. Specifically, it - * must match the regular expression `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture createBindingAsync( - @Nullable LocationName parent, Binding binding, String bindingId) { - CreateBindingRequest request = - CreateBindingRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .setBinding(binding) - .setBindingId(bindingId) - .build(); - return createBindingAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a new Binding in a given project and location. + *

This method is only allowed when no Skills exist in the target project and location. If any + * Skill already exists in the location, the request fails with `FAILED_PRECONDITION`. * *

Sample code: * @@ -2827,36 +7215,39 @@ public final OperationFuture createBindingAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); - * Binding binding = Binding.newBuilder().build(); - * String bindingId = "bindingId-920966528"; - * Binding response = agentRegistryClient.createBindingAsync(parent, binding, bindingId).get(); + * SkillEncryptionSpec skillEncryptionSpec = SkillEncryptionSpec.newBuilder().build(); + * FieldMask updateMask = FieldMask.newBuilder().build(); + * SkillEncryptionSpec response = + * agentRegistryClient.updateSkillEncryptionSpecAsync(skillEncryptionSpec, updateMask).get(); * } * } * - * @param parent Required. The project and location to create the Binding in. Expected format: - * `projects/{project}/locations/{location}`. - * @param binding Required. The Binding resource that is being created. - * @param bindingId Required. The ID to use for the binding, which will become the final component - * of the binding's resource name. - *

This value should be 4-63 characters, and must conform to RFC-1034. Specifically, it - * must match the regular expression `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`. + * @param skillEncryptionSpec Required. The SkillEncryptionSpec to update. + * @param updateMask Optional. Field mask is used to specify the fields to be overwritten in the + * SkillEncryptionSpec resource by the update. The fields specified in the update_mask are + * relative to the resource, not the full request. A field will be overwritten if it is in the + * mask. If the user does not provide a mask then all fields present in the request will be + * overwritten. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture createBindingAsync( - String parent, Binding binding, String bindingId) { - CreateBindingRequest request = - CreateBindingRequest.newBuilder() - .setParent(parent) - .setBinding(binding) - .setBindingId(bindingId) + public final OperationFuture + updateSkillEncryptionSpecAsync( + SkillEncryptionSpec skillEncryptionSpec, FieldMask updateMask) { + UpdateSkillEncryptionSpecRequest request = + UpdateSkillEncryptionSpecRequest.newBuilder() + .setSkillEncryptionSpec(skillEncryptionSpec) + .setUpdateMask(updateMask) .build(); - return createBindingAsync(request); + return updateSkillEncryptionSpecAsync(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new Binding in a given project and location. + * Updates the customer-managed encryption key (CMEK) configuration for Skills in a specific + * project and location. + * + *

This method is only allowed when no Skills exist in the target project and location. If any + * Skill already exists in the location, the request fails with `FAILED_PRECONDITION`. * *

Sample code: * @@ -2867,28 +7258,31 @@ public final OperationFuture createBindingAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * CreateBindingRequest request = - * CreateBindingRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setBindingId("bindingId-920966528") - * .setBinding(Binding.newBuilder().build()) - * .setRequestId("requestId693933066") + * UpdateSkillEncryptionSpecRequest request = + * UpdateSkillEncryptionSpecRequest.newBuilder() + * .setSkillEncryptionSpec(SkillEncryptionSpec.newBuilder().build()) + * .setUpdateMask(FieldMask.newBuilder().build()) * .build(); - * Binding response = agentRegistryClient.createBindingAsync(request).get(); + * SkillEncryptionSpec response = + * agentRegistryClient.updateSkillEncryptionSpecAsync(request).get(); * } * } * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture createBindingAsync( - CreateBindingRequest request) { - return createBindingOperationCallable().futureCall(request); + public final OperationFuture + updateSkillEncryptionSpecAsync(UpdateSkillEncryptionSpecRequest request) { + return updateSkillEncryptionSpecOperationCallable().futureCall(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new Binding in a given project and location. + * Updates the customer-managed encryption key (CMEK) configuration for Skills in a specific + * project and location. + * + *

This method is only allowed when no Skills exist in the target project and location. If any + * Skill already exists in the location, the request fails with `FAILED_PRECONDITION`. * *

Sample code: * @@ -2899,28 +7293,31 @@ public final OperationFuture createBindingAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * CreateBindingRequest request = - * CreateBindingRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setBindingId("bindingId-920966528") - * .setBinding(Binding.newBuilder().build()) - * .setRequestId("requestId693933066") + * UpdateSkillEncryptionSpecRequest request = + * UpdateSkillEncryptionSpecRequest.newBuilder() + * .setSkillEncryptionSpec(SkillEncryptionSpec.newBuilder().build()) + * .setUpdateMask(FieldMask.newBuilder().build()) * .build(); - * OperationFuture future = - * agentRegistryClient.createBindingOperationCallable().futureCall(request); + * OperationFuture future = + * agentRegistryClient.updateSkillEncryptionSpecOperationCallable().futureCall(request); * // Do something. - * Binding response = future.get(); + * SkillEncryptionSpec response = future.get(); * } * } */ - public final OperationCallable - createBindingOperationCallable() { - return stub.createBindingOperationCallable(); + public final OperationCallable< + UpdateSkillEncryptionSpecRequest, SkillEncryptionSpec, OperationMetadata> + updateSkillEncryptionSpecOperationCallable() { + return stub.updateSkillEncryptionSpecOperationCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new Binding in a given project and location. + * Updates the customer-managed encryption key (CMEK) configuration for Skills in a specific + * project and location. + * + *

This method is only allowed when no Skills exist in the target project and location. If any + * Skill already exists in the location, the request fails with `FAILED_PRECONDITION`. * *

Sample code: * @@ -2931,26 +7328,38 @@ public final OperationFuture createBindingAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * CreateBindingRequest request = - * CreateBindingRequest.newBuilder() - * .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) - * .setBindingId("bindingId-920966528") - * .setBinding(Binding.newBuilder().build()) - * .setRequestId("requestId693933066") + * UpdateSkillEncryptionSpecRequest request = + * UpdateSkillEncryptionSpecRequest.newBuilder() + * .setSkillEncryptionSpec(SkillEncryptionSpec.newBuilder().build()) + * .setUpdateMask(FieldMask.newBuilder().build()) * .build(); - * ApiFuture future = agentRegistryClient.createBindingCallable().futureCall(request); + * ApiFuture future = + * agentRegistryClient.updateSkillEncryptionSpecCallable().futureCall(request); * // Do something. * Operation response = future.get(); * } * } */ - public final UnaryCallable createBindingCallable() { - return stub.createBindingCallable(); + public final UnaryCallable + updateSkillEncryptionSpecCallable() { + return stub.updateSkillEncryptionSpecCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Updates the parameters of a single Binding. + * Lists information about the supported locations for this service. + * + *

This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. * *

Sample code: * @@ -2961,29 +7370,41 @@ public final UnaryCallable createBindingCallabl * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * Binding binding = Binding.newBuilder().build(); - * FieldMask updateMask = FieldMask.newBuilder().build(); - * Binding response = agentRegistryClient.updateBindingAsync(binding, updateMask).get(); + * ListLocationsRequest request = + * ListLocationsRequest.newBuilder() + * .setName("name3373707") + * .setFilter("filter-1274492040") + * .setPageSize(883849137) + * .setPageToken("pageToken873572522") + * .build(); + * for (Location element : agentRegistryClient.listLocations(request).iterateAll()) { + * // doThingsWith(element); + * } * } * } * - * @param binding Required. The Binding resource that is being updated. - * @param updateMask Optional. Field mask is used to specify the fields to be overwritten in the - * Binding resource by the update. The fields specified in the update_mask are relative to the - * resource, not the full request. A field will be overwritten if it is in the mask. If the - * user does not provide a mask then all fields present in the request will be overwritten. + * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture updateBindingAsync( - Binding binding, FieldMask updateMask) { - UpdateBindingRequest request = - UpdateBindingRequest.newBuilder().setBinding(binding).setUpdateMask(updateMask).build(); - return updateBindingAsync(request); + public final ListLocationsPagedResponse listLocations(ListLocationsRequest request) { + return listLocationsPagedCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Updates the parameters of a single Binding. + * Lists information about the supported locations for this service. + * + *

This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. * *

Sample code: * @@ -2994,27 +7415,42 @@ public final OperationFuture updateBindingAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * UpdateBindingRequest request = - * UpdateBindingRequest.newBuilder() - * .setBinding(Binding.newBuilder().build()) - * .setUpdateMask(FieldMask.newBuilder().build()) - * .setRequestId("requestId693933066") + * ListLocationsRequest request = + * ListLocationsRequest.newBuilder() + * .setName("name3373707") + * .setFilter("filter-1274492040") + * .setPageSize(883849137) + * .setPageToken("pageToken873572522") * .build(); - * Binding response = agentRegistryClient.updateBindingAsync(request).get(); + * ApiFuture future = + * agentRegistryClient.listLocationsPagedCallable().futureCall(request); + * // Do something. + * for (Location element : future.get().iterateAll()) { + * // doThingsWith(element); + * } * } * } - * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture updateBindingAsync( - UpdateBindingRequest request) { - return updateBindingOperationCallable().futureCall(request); + public final UnaryCallable + listLocationsPagedCallable() { + return stub.listLocationsPagedCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Updates the parameters of a single Binding. + * Lists information about the supported locations for this service. + * + *

This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. * *

Sample code: * @@ -3025,27 +7461,35 @@ public final OperationFuture updateBindingAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * UpdateBindingRequest request = - * UpdateBindingRequest.newBuilder() - * .setBinding(Binding.newBuilder().build()) - * .setUpdateMask(FieldMask.newBuilder().build()) - * .setRequestId("requestId693933066") + * ListLocationsRequest request = + * ListLocationsRequest.newBuilder() + * .setName("name3373707") + * .setFilter("filter-1274492040") + * .setPageSize(883849137) + * .setPageToken("pageToken873572522") * .build(); - * OperationFuture future = - * agentRegistryClient.updateBindingOperationCallable().futureCall(request); - * // Do something. - * Binding response = future.get(); + * while (true) { + * ListLocationsResponse response = agentRegistryClient.listLocationsCallable().call(request); + * for (Location element : response.getLocationsList()) { + * // doThingsWith(element); + * } + * String nextPageToken = response.getNextPageToken(); + * if (!Strings.isNullOrEmpty(nextPageToken)) { + * request = request.toBuilder().setPageToken(nextPageToken).build(); + * } else { + * break; + * } + * } * } * } */ - public final OperationCallable - updateBindingOperationCallable() { - return stub.updateBindingOperationCallable(); + public final UnaryCallable listLocationsCallable() { + return stub.listLocationsCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Updates the parameters of a single Binding. + * Gets information about a location. * *

Sample code: * @@ -3056,25 +7500,21 @@ public final OperationFuture updateBindingAsync( * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * UpdateBindingRequest request = - * UpdateBindingRequest.newBuilder() - * .setBinding(Binding.newBuilder().build()) - * .setUpdateMask(FieldMask.newBuilder().build()) - * .setRequestId("requestId693933066") - * .build(); - * ApiFuture future = agentRegistryClient.updateBindingCallable().futureCall(request); - * // Do something. - * Operation response = future.get(); + * GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + * Location response = agentRegistryClient.getLocation(request); * } * } + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final UnaryCallable updateBindingCallable() { - return stub.updateBindingCallable(); + public final Location getLocation(GetLocationRequest request) { + return getLocationCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Deletes a single Binding. + * Gets information about a location. * *

Sample code: * @@ -3085,1141 +7525,1400 @@ public final UnaryCallable updateBindingCallabl * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * BindingName name = BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]"); - * agentRegistryClient.deleteBindingAsync(name).get(); + * GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + * ApiFuture future = agentRegistryClient.getLocationCallable().futureCall(request); + * // Do something. + * Location response = future.get(); * } * } - * - * @param name Required. The name of the Binding. Format: - * `projects/{project}/locations/{location}/bindings/{binding}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final OperationFuture deleteBindingAsync( - @Nullable BindingName name) { - DeleteBindingRequest request = - DeleteBindingRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return deleteBindingAsync(request); + public final UnaryCallable getLocationCallable() { + return stub.getLocationCallable(); + } + + @Override + public final void close() { + stub.close(); + } + + @Override + public void shutdown() { + stub.shutdown(); + } + + @Override + public boolean isShutdown() { + return stub.isShutdown(); + } + + @Override + public boolean isTerminated() { + return stub.isTerminated(); + } + + @Override + public void shutdownNow() { + stub.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return stub.awaitTermination(duration, unit); + } + + public static class ListAgentsPagedResponse + extends AbstractPagedListResponse< + ListAgentsRequest, + ListAgentsResponse, + Agent, + ListAgentsPage, + ListAgentsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListAgentsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, input -> new ListAgentsPagedResponse(input), MoreExecutors.directExecutor()); + } + + private ListAgentsPagedResponse(ListAgentsPage page) { + super(page, ListAgentsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListAgentsPage + extends AbstractPage { + + private ListAgentsPage( + @Nullable PageContext context, + @Nullable ListAgentsResponse response) { + super(context, response); + } + + private static ListAgentsPage createEmptyPage() { + return new ListAgentsPage(null, null); + } + + @Override + protected ListAgentsPage createPage( + @Nullable PageContext context, + @Nullable ListAgentsResponse response) { + return new ListAgentsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListAgentsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListAgentsRequest, + ListAgentsResponse, + Agent, + ListAgentsPage, + ListAgentsFixedSizeCollection> { + + private ListAgentsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListAgentsFixedSizeCollection createEmptyCollection() { + return new ListAgentsFixedSizeCollection(null, 0); + } + + @Override + protected ListAgentsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListAgentsFixedSizeCollection(pages, collectionSize); + } + } + + public static class SearchAgentsPagedResponse + extends AbstractPagedListResponse< + SearchAgentsRequest, + SearchAgentsResponse, + Agent, + SearchAgentsPage, + SearchAgentsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + SearchAgentsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new SearchAgentsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private SearchAgentsPagedResponse(SearchAgentsPage page) { + super(page, SearchAgentsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class SearchAgentsPage + extends AbstractPage { + + private SearchAgentsPage( + @Nullable PageContext context, + @Nullable SearchAgentsResponse response) { + super(context, response); + } + + private static SearchAgentsPage createEmptyPage() { + return new SearchAgentsPage(null, null); + } + + @Override + protected SearchAgentsPage createPage( + @Nullable PageContext context, + @Nullable SearchAgentsResponse response) { + return new SearchAgentsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class SearchAgentsFixedSizeCollection + extends AbstractFixedSizeCollection< + SearchAgentsRequest, + SearchAgentsResponse, + Agent, + SearchAgentsPage, + SearchAgentsFixedSizeCollection> { + + private SearchAgentsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static SearchAgentsFixedSizeCollection createEmptyCollection() { + return new SearchAgentsFixedSizeCollection(null, 0); + } + + @Override + protected SearchAgentsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new SearchAgentsFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListEndpointsPagedResponse + extends AbstractPagedListResponse< + ListEndpointsRequest, + ListEndpointsResponse, + Endpoint, + ListEndpointsPage, + ListEndpointsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListEndpointsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListEndpointsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListEndpointsPagedResponse(ListEndpointsPage page) { + super(page, ListEndpointsFixedSizeCollection.createEmptyCollection()); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a single Binding. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   String name = BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString();
-   *   agentRegistryClient.deleteBindingAsync(name).get();
-   * }
-   * }
- * - * @param name Required. The name of the Binding. Format: - * `projects/{project}/locations/{location}/bindings/{binding}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture deleteBindingAsync(String name) { - DeleteBindingRequest request = DeleteBindingRequest.newBuilder().setName(name).build(); - return deleteBindingAsync(request); + public static class ListEndpointsPage + extends AbstractPage< + ListEndpointsRequest, ListEndpointsResponse, Endpoint, ListEndpointsPage> { + + private ListEndpointsPage( + @Nullable PageContext context, + @Nullable ListEndpointsResponse response) { + super(context, response); + } + + private static ListEndpointsPage createEmptyPage() { + return new ListEndpointsPage(null, null); + } + + @Override + protected ListEndpointsPage createPage( + @Nullable PageContext context, + @Nullable ListEndpointsResponse response) { + return new ListEndpointsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a single Binding. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   DeleteBindingRequest request =
-   *       DeleteBindingRequest.newBuilder()
-   *           .setName(BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString())
-   *           .setRequestId("requestId693933066")
-   *           .build();
-   *   agentRegistryClient.deleteBindingAsync(request).get();
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture deleteBindingAsync( - DeleteBindingRequest request) { - return deleteBindingOperationCallable().futureCall(request); + public static class ListEndpointsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListEndpointsRequest, + ListEndpointsResponse, + Endpoint, + ListEndpointsPage, + ListEndpointsFixedSizeCollection> { + + private ListEndpointsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListEndpointsFixedSizeCollection createEmptyCollection() { + return new ListEndpointsFixedSizeCollection(null, 0); + } + + @Override + protected ListEndpointsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListEndpointsFixedSizeCollection(pages, collectionSize); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a single Binding. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   DeleteBindingRequest request =
-   *       DeleteBindingRequest.newBuilder()
-   *           .setName(BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString())
-   *           .setRequestId("requestId693933066")
-   *           .build();
-   *   OperationFuture future =
-   *       agentRegistryClient.deleteBindingOperationCallable().futureCall(request);
-   *   // Do something.
-   *   future.get();
-   * }
-   * }
- */ - public final OperationCallable - deleteBindingOperationCallable() { - return stub.deleteBindingOperationCallable(); + public static class ListMcpServersPagedResponse + extends AbstractPagedListResponse< + ListMcpServersRequest, + ListMcpServersResponse, + McpServer, + ListMcpServersPage, + ListMcpServersFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListMcpServersPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListMcpServersPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListMcpServersPagedResponse(ListMcpServersPage page) { + super(page, ListMcpServersFixedSizeCollection.createEmptyCollection()); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a single Binding. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   DeleteBindingRequest request =
-   *       DeleteBindingRequest.newBuilder()
-   *           .setName(BindingName.of("[PROJECT]", "[LOCATION]", "[BINDING]").toString())
-   *           .setRequestId("requestId693933066")
-   *           .build();
-   *   ApiFuture future = agentRegistryClient.deleteBindingCallable().futureCall(request);
-   *   // Do something.
-   *   future.get();
-   * }
-   * }
- */ - public final UnaryCallable deleteBindingCallable() { - return stub.deleteBindingCallable(); + public static class ListMcpServersPage + extends AbstractPage< + ListMcpServersRequest, ListMcpServersResponse, McpServer, ListMcpServersPage> { + + private ListMcpServersPage( + @Nullable PageContext context, + @Nullable ListMcpServersResponse response) { + super(context, response); + } + + private static ListMcpServersPage createEmptyPage() { + return new ListMcpServersPage(null, null); + } + + @Override + protected ListMcpServersPage createPage( + @Nullable PageContext context, + @Nullable ListMcpServersResponse response) { + return new ListMcpServersPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Fetches available Bindings. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
-   *   for (Binding element : agentRegistryClient.fetchAvailableBindings(parent).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param parent Required. The parent, in the format `projects/{project}/locations/{location}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final FetchAvailableBindingsPagedResponse fetchAvailableBindings( - @Nullable LocationName parent) { - FetchAvailableBindingsRequest request = - FetchAvailableBindingsRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .build(); - return fetchAvailableBindings(request); + public static class ListMcpServersFixedSizeCollection + extends AbstractFixedSizeCollection< + ListMcpServersRequest, + ListMcpServersResponse, + McpServer, + ListMcpServersPage, + ListMcpServersFixedSizeCollection> { + + private ListMcpServersFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListMcpServersFixedSizeCollection createEmptyCollection() { + return new ListMcpServersFixedSizeCollection(null, 0); + } + + @Override + protected ListMcpServersFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListMcpServersFixedSizeCollection(pages, collectionSize); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Fetches available Bindings. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
-   *   for (Binding element : agentRegistryClient.fetchAvailableBindings(parent).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param parent Required. The parent, in the format `projects/{project}/locations/{location}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final FetchAvailableBindingsPagedResponse fetchAvailableBindings(String parent) { - FetchAvailableBindingsRequest request = - FetchAvailableBindingsRequest.newBuilder().setParent(parent).build(); - return fetchAvailableBindings(request); - } + public static class SearchMcpServersPagedResponse + extends AbstractPagedListResponse< + SearchMcpServersRequest, + SearchMcpServersResponse, + McpServer, + SearchMcpServersPage, + SearchMcpServersFixedSizeCollection> { - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Fetches available Bindings. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   FetchAvailableBindingsRequest request =
-   *       FetchAvailableBindingsRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   for (Binding element : agentRegistryClient.fetchAvailableBindings(request).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final FetchAvailableBindingsPagedResponse fetchAvailableBindings( - FetchAvailableBindingsRequest request) { - return fetchAvailableBindingsPagedCallable().call(request); + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + SearchMcpServersPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new SearchMcpServersPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private SearchMcpServersPagedResponse(SearchMcpServersPage page) { + super(page, SearchMcpServersFixedSizeCollection.createEmptyCollection()); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Fetches available Bindings. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   FetchAvailableBindingsRequest request =
-   *       FetchAvailableBindingsRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   ApiFuture future =
-   *       agentRegistryClient.fetchAvailableBindingsPagedCallable().futureCall(request);
-   *   // Do something.
-   *   for (Binding element : future.get().iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- */ - public final UnaryCallable - fetchAvailableBindingsPagedCallable() { - return stub.fetchAvailableBindingsPagedCallable(); + public static class SearchMcpServersPage + extends AbstractPage< + SearchMcpServersRequest, SearchMcpServersResponse, McpServer, SearchMcpServersPage> { + + private SearchMcpServersPage( + @Nullable PageContext context, + @Nullable SearchMcpServersResponse response) { + super(context, response); + } + + private static SearchMcpServersPage createEmptyPage() { + return new SearchMcpServersPage(null, null); + } + + @Override + protected SearchMcpServersPage createPage( + @Nullable PageContext context, + @Nullable SearchMcpServersResponse response) { + return new SearchMcpServersPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Fetches available Bindings. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   FetchAvailableBindingsRequest request =
-   *       FetchAvailableBindingsRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   while (true) {
-   *     FetchAvailableBindingsResponse response =
-   *         agentRegistryClient.fetchAvailableBindingsCallable().call(request);
-   *     for (Binding element : response.getBindingsList()) {
-   *       // doThingsWith(element);
-   *     }
-   *     String nextPageToken = response.getNextPageToken();
-   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
-   *       request = request.toBuilder().setPageToken(nextPageToken).build();
-   *     } else {
-   *       break;
-   *     }
-   *   }
-   * }
-   * }
- */ - public final UnaryCallable - fetchAvailableBindingsCallable() { - return stub.fetchAvailableBindingsCallable(); + public static class SearchMcpServersFixedSizeCollection + extends AbstractFixedSizeCollection< + SearchMcpServersRequest, + SearchMcpServersResponse, + McpServer, + SearchMcpServersPage, + SearchMcpServersFixedSizeCollection> { + + private SearchMcpServersFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static SearchMcpServersFixedSizeCollection createEmptyCollection() { + return new SearchMcpServersFixedSizeCollection(null, 0); + } + + @Override + protected SearchMcpServersFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new SearchMcpServersFixedSizeCollection(pages, collectionSize); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists information about the supported locations for this service. - * - *

This method lists locations based on the resource scope provided inthe - * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: - * ***Global locations**: If `name` is empty, the method lists thepublic - * locations available to all projects. * **Project-specificlocations**: If - * `name` follows the format`projects/{project}`, the method lists locations visible to - * thatspecific project. This includes public, private, or otherproject-specific locations enabled - * for the project. - * - *

For gRPC and client library implementations, the resource name ispassed as the `name` field. - * For direct service calls, the resourcename isincorporated into the request path based on the - * specific serviceimplementation and version. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   ListLocationsRequest request =
-   *       ListLocationsRequest.newBuilder()
-   *           .setName("name3373707")
-   *           .setFilter("filter-1274492040")
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   for (Location element : agentRegistryClient.listLocations(request).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListLocationsPagedResponse listLocations(ListLocationsRequest request) { - return listLocationsPagedCallable().call(request); + public static class ListServicesPagedResponse + extends AbstractPagedListResponse< + ListServicesRequest, + ListServicesResponse, + Service, + ListServicesPage, + ListServicesFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListServicesPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListServicesPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListServicesPagedResponse(ListServicesPage page) { + super(page, ListServicesFixedSizeCollection.createEmptyCollection()); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists information about the supported locations for this service. - * - *

This method lists locations based on the resource scope provided inthe - * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: - * ***Global locations**: If `name` is empty, the method lists thepublic - * locations available to all projects. * **Project-specificlocations**: If - * `name` follows the format`projects/{project}`, the method lists locations visible to - * thatspecific project. This includes public, private, or otherproject-specific locations enabled - * for the project. - * - *

For gRPC and client library implementations, the resource name ispassed as the `name` field. - * For direct service calls, the resourcename isincorporated into the request path based on the - * specific serviceimplementation and version. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   ListLocationsRequest request =
-   *       ListLocationsRequest.newBuilder()
-   *           .setName("name3373707")
-   *           .setFilter("filter-1274492040")
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   ApiFuture future =
-   *       agentRegistryClient.listLocationsPagedCallable().futureCall(request);
-   *   // Do something.
-   *   for (Location element : future.get().iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- */ - public final UnaryCallable - listLocationsPagedCallable() { - return stub.listLocationsPagedCallable(); + public static class ListServicesPage + extends AbstractPage { + + private ListServicesPage( + @Nullable PageContext context, + @Nullable ListServicesResponse response) { + super(context, response); + } + + private static ListServicesPage createEmptyPage() { + return new ListServicesPage(null, null); + } + + @Override + protected ListServicesPage createPage( + @Nullable PageContext context, + @Nullable ListServicesResponse response) { + return new ListServicesPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists information about the supported locations for this service. - * - *

This method lists locations based on the resource scope provided inthe - * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: - * ***Global locations**: If `name` is empty, the method lists thepublic - * locations available to all projects. * **Project-specificlocations**: If - * `name` follows the format`projects/{project}`, the method lists locations visible to - * thatspecific project. This includes public, private, or otherproject-specific locations enabled - * for the project. - * - *

For gRPC and client library implementations, the resource name ispassed as the `name` field. - * For direct service calls, the resourcename isincorporated into the request path based on the - * specific serviceimplementation and version. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   ListLocationsRequest request =
-   *       ListLocationsRequest.newBuilder()
-   *           .setName("name3373707")
-   *           .setFilter("filter-1274492040")
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   while (true) {
-   *     ListLocationsResponse response = agentRegistryClient.listLocationsCallable().call(request);
-   *     for (Location element : response.getLocationsList()) {
-   *       // doThingsWith(element);
-   *     }
-   *     String nextPageToken = response.getNextPageToken();
-   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
-   *       request = request.toBuilder().setPageToken(nextPageToken).build();
-   *     } else {
-   *       break;
-   *     }
-   *   }
-   * }
-   * }
- */ - public final UnaryCallable listLocationsCallable() { - return stub.listLocationsCallable(); + public static class ListServicesFixedSizeCollection + extends AbstractFixedSizeCollection< + ListServicesRequest, + ListServicesResponse, + Service, + ListServicesPage, + ListServicesFixedSizeCollection> { + + private ListServicesFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListServicesFixedSizeCollection createEmptyCollection() { + return new ListServicesFixedSizeCollection(null, 0); + } + + @Override + protected ListServicesFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListServicesFixedSizeCollection(pages, collectionSize); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Gets information about a location. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
-   *   Location response = agentRegistryClient.getLocation(request);
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Location getLocation(GetLocationRequest request) { - return getLocationCallable().call(request); + public static class ListBindingsPagedResponse + extends AbstractPagedListResponse< + ListBindingsRequest, + ListBindingsResponse, + Binding, + ListBindingsPage, + ListBindingsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListBindingsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListBindingsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListBindingsPagedResponse(ListBindingsPage page) { + super(page, ListBindingsFixedSizeCollection.createEmptyCollection()); + } } - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Gets information about a location. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) {
-   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
-   *   ApiFuture future = agentRegistryClient.getLocationCallable().futureCall(request);
-   *   // Do something.
-   *   Location response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable getLocationCallable() { - return stub.getLocationCallable(); + public static class ListBindingsPage + extends AbstractPage { + + private ListBindingsPage( + @Nullable PageContext context, + @Nullable ListBindingsResponse response) { + super(context, response); + } + + private static ListBindingsPage createEmptyPage() { + return new ListBindingsPage(null, null); + } + + @Override + protected ListBindingsPage createPage( + @Nullable PageContext context, + @Nullable ListBindingsResponse response) { + return new ListBindingsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListBindingsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListBindingsRequest, + ListBindingsResponse, + Binding, + ListBindingsPage, + ListBindingsFixedSizeCollection> { + + private ListBindingsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListBindingsFixedSizeCollection createEmptyCollection() { + return new ListBindingsFixedSizeCollection(null, 0); + } + + @Override + protected ListBindingsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListBindingsFixedSizeCollection(pages, collectionSize); + } } - @Override - public final void close() { - stub.close(); + public static class FetchAvailableBindingsPagedResponse + extends AbstractPagedListResponse< + FetchAvailableBindingsRequest, + FetchAvailableBindingsResponse, + Binding, + FetchAvailableBindingsPage, + FetchAvailableBindingsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + FetchAvailableBindingsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new FetchAvailableBindingsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private FetchAvailableBindingsPagedResponse(FetchAvailableBindingsPage page) { + super(page, FetchAvailableBindingsFixedSizeCollection.createEmptyCollection()); + } } - @Override - public void shutdown() { - stub.shutdown(); + public static class FetchAvailableBindingsPage + extends AbstractPage< + FetchAvailableBindingsRequest, + FetchAvailableBindingsResponse, + Binding, + FetchAvailableBindingsPage> { + + private FetchAvailableBindingsPage( + @Nullable + PageContext + context, + @Nullable FetchAvailableBindingsResponse response) { + super(context, response); + } + + private static FetchAvailableBindingsPage createEmptyPage() { + return new FetchAvailableBindingsPage(null, null); + } + + @Override + protected FetchAvailableBindingsPage createPage( + @Nullable + PageContext + context, + @Nullable FetchAvailableBindingsResponse response) { + return new FetchAvailableBindingsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable + PageContext + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } } - @Override - public boolean isShutdown() { - return stub.isShutdown(); + public static class FetchAvailableBindingsFixedSizeCollection + extends AbstractFixedSizeCollection< + FetchAvailableBindingsRequest, + FetchAvailableBindingsResponse, + Binding, + FetchAvailableBindingsPage, + FetchAvailableBindingsFixedSizeCollection> { + + private FetchAvailableBindingsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static FetchAvailableBindingsFixedSizeCollection createEmptyCollection() { + return new FetchAvailableBindingsFixedSizeCollection(null, 0); + } + + @Override + protected FetchAvailableBindingsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new FetchAvailableBindingsFixedSizeCollection(pages, collectionSize); + } } - @Override - public boolean isTerminated() { - return stub.isTerminated(); + public static class ListSkillsPagedResponse + extends AbstractPagedListResponse< + ListSkillsRequest, + ListSkillsResponse, + Skill, + ListSkillsPage, + ListSkillsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListSkillsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, input -> new ListSkillsPagedResponse(input), MoreExecutors.directExecutor()); + } + + private ListSkillsPagedResponse(ListSkillsPage page) { + super(page, ListSkillsFixedSizeCollection.createEmptyCollection()); + } } - @Override - public void shutdownNow() { - stub.shutdownNow(); + public static class ListSkillsPage + extends AbstractPage { + + private ListSkillsPage( + @Nullable PageContext context, + @Nullable ListSkillsResponse response) { + super(context, response); + } + + private static ListSkillsPage createEmptyPage() { + return new ListSkillsPage(null, null); + } + + @Override + protected ListSkillsPage createPage( + @Nullable PageContext context, + @Nullable ListSkillsResponse response) { + return new ListSkillsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } } - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return stub.awaitTermination(duration, unit); + public static class ListSkillsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListSkillsRequest, + ListSkillsResponse, + Skill, + ListSkillsPage, + ListSkillsFixedSizeCollection> { + + private ListSkillsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListSkillsFixedSizeCollection createEmptyCollection() { + return new ListSkillsFixedSizeCollection(null, 0); + } + + @Override + protected ListSkillsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListSkillsFixedSizeCollection(pages, collectionSize); + } } - public static class ListAgentsPagedResponse + public static class SearchSkillsPagedResponse extends AbstractPagedListResponse< - ListAgentsRequest, - ListAgentsResponse, - Agent, - ListAgentsPage, - ListAgentsFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListAgentsPage.createEmptyPage().createPageAsync(context, futureResponse); + SearchSkillsRequest, + SearchSkillsResponse, + Skill, + SearchSkillsPage, + SearchSkillsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + SearchSkillsPage.createEmptyPage().createPageAsync(context, futureResponse); return ApiFutures.transform( - futurePage, input -> new ListAgentsPagedResponse(input), MoreExecutors.directExecutor()); + futurePage, + input -> new SearchSkillsPagedResponse(input), + MoreExecutors.directExecutor()); } - private ListAgentsPagedResponse(ListAgentsPage page) { - super(page, ListAgentsFixedSizeCollection.createEmptyCollection()); + private SearchSkillsPagedResponse(SearchSkillsPage page) { + super(page, SearchSkillsFixedSizeCollection.createEmptyCollection()); } } - public static class ListAgentsPage - extends AbstractPage { + public static class SearchSkillsPage + extends AbstractPage { - private ListAgentsPage( - @Nullable PageContext context, - @Nullable ListAgentsResponse response) { + private SearchSkillsPage( + @Nullable PageContext context, + @Nullable SearchSkillsResponse response) { super(context, response); } - private static ListAgentsPage createEmptyPage() { - return new ListAgentsPage(null, null); + private static SearchSkillsPage createEmptyPage() { + return new SearchSkillsPage(null, null); } @Override - protected ListAgentsPage createPage( - @Nullable PageContext context, - @Nullable ListAgentsResponse response) { - return new ListAgentsPage(context, response); + protected SearchSkillsPage createPage( + @Nullable PageContext context, + @Nullable SearchSkillsResponse response) { + return new SearchSkillsPage(context, response); } @Override - public ApiFuture createPageAsync( - @Nullable PageContext context, - ApiFuture futureResponse) { + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { return super.createPageAsync(context, futureResponse); } } - public static class ListAgentsFixedSizeCollection + public static class SearchSkillsFixedSizeCollection extends AbstractFixedSizeCollection< - ListAgentsRequest, - ListAgentsResponse, - Agent, - ListAgentsPage, - ListAgentsFixedSizeCollection> { - - private ListAgentsFixedSizeCollection( - @Nullable List pages, int collectionSize) { + SearchSkillsRequest, + SearchSkillsResponse, + Skill, + SearchSkillsPage, + SearchSkillsFixedSizeCollection> { + + private SearchSkillsFixedSizeCollection( + @Nullable List pages, int collectionSize) { super(pages, collectionSize); } - private static ListAgentsFixedSizeCollection createEmptyCollection() { - return new ListAgentsFixedSizeCollection(null, 0); + private static SearchSkillsFixedSizeCollection createEmptyCollection() { + return new SearchSkillsFixedSizeCollection(null, 0); } @Override - protected ListAgentsFixedSizeCollection createCollection( - @Nullable List pages, int collectionSize) { - return new ListAgentsFixedSizeCollection(pages, collectionSize); + protected SearchSkillsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new SearchSkillsFixedSizeCollection(pages, collectionSize); } } - public static class SearchAgentsPagedResponse + public static class ListSkillRevisionsPagedResponse extends AbstractPagedListResponse< - SearchAgentsRequest, - SearchAgentsResponse, - Agent, - SearchAgentsPage, - SearchAgentsFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - SearchAgentsPage.createEmptyPage().createPageAsync(context, futureResponse); + ListSkillRevisionsRequest, + ListSkillRevisionsResponse, + SkillRevision, + ListSkillRevisionsPage, + ListSkillRevisionsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListSkillRevisionsPage.createEmptyPage().createPageAsync(context, futureResponse); return ApiFutures.transform( futurePage, - input -> new SearchAgentsPagedResponse(input), + input -> new ListSkillRevisionsPagedResponse(input), MoreExecutors.directExecutor()); } - private SearchAgentsPagedResponse(SearchAgentsPage page) { - super(page, SearchAgentsFixedSizeCollection.createEmptyCollection()); + private ListSkillRevisionsPagedResponse(ListSkillRevisionsPage page) { + super(page, ListSkillRevisionsFixedSizeCollection.createEmptyCollection()); } } - public static class SearchAgentsPage - extends AbstractPage { + public static class ListSkillRevisionsPage + extends AbstractPage< + ListSkillRevisionsRequest, + ListSkillRevisionsResponse, + SkillRevision, + ListSkillRevisionsPage> { - private SearchAgentsPage( - @Nullable PageContext context, - @Nullable SearchAgentsResponse response) { + private ListSkillRevisionsPage( + @Nullable PageContext + context, + @Nullable ListSkillRevisionsResponse response) { super(context, response); } - private static SearchAgentsPage createEmptyPage() { - return new SearchAgentsPage(null, null); + private static ListSkillRevisionsPage createEmptyPage() { + return new ListSkillRevisionsPage(null, null); } @Override - protected SearchAgentsPage createPage( - @Nullable PageContext context, - @Nullable SearchAgentsResponse response) { - return new SearchAgentsPage(context, response); + protected ListSkillRevisionsPage createPage( + @Nullable PageContext + context, + @Nullable ListSkillRevisionsResponse response) { + return new ListSkillRevisionsPage(context, response); } @Override - public ApiFuture createPageAsync( - @Nullable PageContext context, - ApiFuture futureResponse) { + public ApiFuture createPageAsync( + @Nullable PageContext + context, + ApiFuture futureResponse) { return super.createPageAsync(context, futureResponse); } } - public static class SearchAgentsFixedSizeCollection + public static class ListSkillRevisionsFixedSizeCollection extends AbstractFixedSizeCollection< - SearchAgentsRequest, - SearchAgentsResponse, - Agent, - SearchAgentsPage, - SearchAgentsFixedSizeCollection> { - - private SearchAgentsFixedSizeCollection( - @Nullable List pages, int collectionSize) { + ListSkillRevisionsRequest, + ListSkillRevisionsResponse, + SkillRevision, + ListSkillRevisionsPage, + ListSkillRevisionsFixedSizeCollection> { + + private ListSkillRevisionsFixedSizeCollection( + @Nullable List pages, int collectionSize) { super(pages, collectionSize); } - private static SearchAgentsFixedSizeCollection createEmptyCollection() { - return new SearchAgentsFixedSizeCollection(null, 0); + private static ListSkillRevisionsFixedSizeCollection createEmptyCollection() { + return new ListSkillRevisionsFixedSizeCollection(null, 0); } @Override - protected SearchAgentsFixedSizeCollection createCollection( - @Nullable List pages, int collectionSize) { - return new SearchAgentsFixedSizeCollection(pages, collectionSize); + protected ListSkillRevisionsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListSkillRevisionsFixedSizeCollection(pages, collectionSize); } } - public static class ListEndpointsPagedResponse + public static class ListPublishersPagedResponse extends AbstractPagedListResponse< - ListEndpointsRequest, - ListEndpointsResponse, - Endpoint, - ListEndpointsPage, - ListEndpointsFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListEndpointsPage.createEmptyPage().createPageAsync(context, futureResponse); + ListPublishersRequest, + ListPublishersResponse, + Publisher, + ListPublishersPage, + ListPublishersFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListPublishersPage.createEmptyPage().createPageAsync(context, futureResponse); return ApiFutures.transform( futurePage, - input -> new ListEndpointsPagedResponse(input), + input -> new ListPublishersPagedResponse(input), MoreExecutors.directExecutor()); } - private ListEndpointsPagedResponse(ListEndpointsPage page) { - super(page, ListEndpointsFixedSizeCollection.createEmptyCollection()); + private ListPublishersPagedResponse(ListPublishersPage page) { + super(page, ListPublishersFixedSizeCollection.createEmptyCollection()); } } - public static class ListEndpointsPage + public static class ListPublishersPage extends AbstractPage< - ListEndpointsRequest, ListEndpointsResponse, Endpoint, ListEndpointsPage> { + ListPublishersRequest, ListPublishersResponse, Publisher, ListPublishersPage> { - private ListEndpointsPage( - @Nullable PageContext context, - @Nullable ListEndpointsResponse response) { + private ListPublishersPage( + @Nullable PageContext context, + @Nullable ListPublishersResponse response) { super(context, response); } - private static ListEndpointsPage createEmptyPage() { - return new ListEndpointsPage(null, null); + private static ListPublishersPage createEmptyPage() { + return new ListPublishersPage(null, null); } @Override - protected ListEndpointsPage createPage( - @Nullable PageContext context, - @Nullable ListEndpointsResponse response) { - return new ListEndpointsPage(context, response); + protected ListPublishersPage createPage( + @Nullable PageContext context, + @Nullable ListPublishersResponse response) { + return new ListPublishersPage(context, response); } - - @Override - public ApiFuture createPageAsync( - @Nullable PageContext context, - ApiFuture futureResponse) { + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { return super.createPageAsync(context, futureResponse); } } - public static class ListEndpointsFixedSizeCollection + public static class ListPublishersFixedSizeCollection extends AbstractFixedSizeCollection< - ListEndpointsRequest, - ListEndpointsResponse, - Endpoint, - ListEndpointsPage, - ListEndpointsFixedSizeCollection> { - - private ListEndpointsFixedSizeCollection( - @Nullable List pages, int collectionSize) { + ListPublishersRequest, + ListPublishersResponse, + Publisher, + ListPublishersPage, + ListPublishersFixedSizeCollection> { + + private ListPublishersFixedSizeCollection( + @Nullable List pages, int collectionSize) { super(pages, collectionSize); } - private static ListEndpointsFixedSizeCollection createEmptyCollection() { - return new ListEndpointsFixedSizeCollection(null, 0); + private static ListPublishersFixedSizeCollection createEmptyCollection() { + return new ListPublishersFixedSizeCollection(null, 0); } @Override - protected ListEndpointsFixedSizeCollection createCollection( - @Nullable List pages, int collectionSize) { - return new ListEndpointsFixedSizeCollection(pages, collectionSize); + protected ListPublishersFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListPublishersFixedSizeCollection(pages, collectionSize); } } - public static class ListMcpServersPagedResponse + public static class ListAiApplicationsPagedResponse extends AbstractPagedListResponse< - ListMcpServersRequest, - ListMcpServersResponse, - McpServer, - ListMcpServersPage, - ListMcpServersFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListMcpServersPage.createEmptyPage().createPageAsync(context, futureResponse); + ListAiApplicationsRequest, + ListAiApplicationsResponse, + AiApplication, + ListAiApplicationsPage, + ListAiApplicationsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListAiApplicationsPage.createEmptyPage().createPageAsync(context, futureResponse); return ApiFutures.transform( futurePage, - input -> new ListMcpServersPagedResponse(input), + input -> new ListAiApplicationsPagedResponse(input), MoreExecutors.directExecutor()); } - private ListMcpServersPagedResponse(ListMcpServersPage page) { - super(page, ListMcpServersFixedSizeCollection.createEmptyCollection()); + private ListAiApplicationsPagedResponse(ListAiApplicationsPage page) { + super(page, ListAiApplicationsFixedSizeCollection.createEmptyCollection()); } } - public static class ListMcpServersPage + public static class ListAiApplicationsPage extends AbstractPage< - ListMcpServersRequest, ListMcpServersResponse, McpServer, ListMcpServersPage> { + ListAiApplicationsRequest, + ListAiApplicationsResponse, + AiApplication, + ListAiApplicationsPage> { - private ListMcpServersPage( - @Nullable PageContext context, - @Nullable ListMcpServersResponse response) { + private ListAiApplicationsPage( + @Nullable PageContext + context, + @Nullable ListAiApplicationsResponse response) { super(context, response); } - private static ListMcpServersPage createEmptyPage() { - return new ListMcpServersPage(null, null); + private static ListAiApplicationsPage createEmptyPage() { + return new ListAiApplicationsPage(null, null); } @Override - protected ListMcpServersPage createPage( - @Nullable PageContext context, - @Nullable ListMcpServersResponse response) { - return new ListMcpServersPage(context, response); + protected ListAiApplicationsPage createPage( + @Nullable PageContext + context, + @Nullable ListAiApplicationsResponse response) { + return new ListAiApplicationsPage(context, response); } @Override - public ApiFuture createPageAsync( - @Nullable PageContext context, - ApiFuture futureResponse) { + public ApiFuture createPageAsync( + @Nullable PageContext + context, + ApiFuture futureResponse) { return super.createPageAsync(context, futureResponse); } } - public static class ListMcpServersFixedSizeCollection + public static class ListAiApplicationsFixedSizeCollection extends AbstractFixedSizeCollection< - ListMcpServersRequest, - ListMcpServersResponse, - McpServer, - ListMcpServersPage, - ListMcpServersFixedSizeCollection> { - - private ListMcpServersFixedSizeCollection( - @Nullable List pages, int collectionSize) { + ListAiApplicationsRequest, + ListAiApplicationsResponse, + AiApplication, + ListAiApplicationsPage, + ListAiApplicationsFixedSizeCollection> { + + private ListAiApplicationsFixedSizeCollection( + @Nullable List pages, int collectionSize) { super(pages, collectionSize); } - private static ListMcpServersFixedSizeCollection createEmptyCollection() { - return new ListMcpServersFixedSizeCollection(null, 0); + private static ListAiApplicationsFixedSizeCollection createEmptyCollection() { + return new ListAiApplicationsFixedSizeCollection(null, 0); } @Override - protected ListMcpServersFixedSizeCollection createCollection( - @Nullable List pages, int collectionSize) { - return new ListMcpServersFixedSizeCollection(pages, collectionSize); + protected ListAiApplicationsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListAiApplicationsFixedSizeCollection(pages, collectionSize); } } - public static class SearchMcpServersPagedResponse + public static class ListAiApplicationAgentsPagedResponse extends AbstractPagedListResponse< - SearchMcpServersRequest, - SearchMcpServersResponse, - McpServer, - SearchMcpServersPage, - SearchMcpServersFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - SearchMcpServersPage.createEmptyPage().createPageAsync(context, futureResponse); + ListAiApplicationAgentsRequest, + ListAiApplicationAgentsResponse, + Agent, + ListAiApplicationAgentsPage, + ListAiApplicationAgentsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListAiApplicationAgentsPage.createEmptyPage().createPageAsync(context, futureResponse); return ApiFutures.transform( futurePage, - input -> new SearchMcpServersPagedResponse(input), + input -> new ListAiApplicationAgentsPagedResponse(input), MoreExecutors.directExecutor()); } - private SearchMcpServersPagedResponse(SearchMcpServersPage page) { - super(page, SearchMcpServersFixedSizeCollection.createEmptyCollection()); + private ListAiApplicationAgentsPagedResponse(ListAiApplicationAgentsPage page) { + super(page, ListAiApplicationAgentsFixedSizeCollection.createEmptyCollection()); } } - public static class SearchMcpServersPage + public static class ListAiApplicationAgentsPage extends AbstractPage< - SearchMcpServersRequest, SearchMcpServersResponse, McpServer, SearchMcpServersPage> { + ListAiApplicationAgentsRequest, + ListAiApplicationAgentsResponse, + Agent, + ListAiApplicationAgentsPage> { - private SearchMcpServersPage( - @Nullable PageContext context, - @Nullable SearchMcpServersResponse response) { + private ListAiApplicationAgentsPage( + @Nullable + PageContext + context, + @Nullable ListAiApplicationAgentsResponse response) { super(context, response); } - private static SearchMcpServersPage createEmptyPage() { - return new SearchMcpServersPage(null, null); + private static ListAiApplicationAgentsPage createEmptyPage() { + return new ListAiApplicationAgentsPage(null, null); } @Override - protected SearchMcpServersPage createPage( - @Nullable PageContext context, - @Nullable SearchMcpServersResponse response) { - return new SearchMcpServersPage(context, response); + protected ListAiApplicationAgentsPage createPage( + @Nullable + PageContext + context, + @Nullable ListAiApplicationAgentsResponse response) { + return new ListAiApplicationAgentsPage(context, response); } @Override - public ApiFuture createPageAsync( - @Nullable PageContext context, - ApiFuture futureResponse) { + public ApiFuture createPageAsync( + @Nullable + PageContext + context, + ApiFuture futureResponse) { return super.createPageAsync(context, futureResponse); } } - public static class SearchMcpServersFixedSizeCollection + public static class ListAiApplicationAgentsFixedSizeCollection extends AbstractFixedSizeCollection< - SearchMcpServersRequest, - SearchMcpServersResponse, - McpServer, - SearchMcpServersPage, - SearchMcpServersFixedSizeCollection> { + ListAiApplicationAgentsRequest, + ListAiApplicationAgentsResponse, + Agent, + ListAiApplicationAgentsPage, + ListAiApplicationAgentsFixedSizeCollection> { - private SearchMcpServersFixedSizeCollection( - @Nullable List pages, int collectionSize) { + private ListAiApplicationAgentsFixedSizeCollection( + @Nullable List pages, int collectionSize) { super(pages, collectionSize); } - private static SearchMcpServersFixedSizeCollection createEmptyCollection() { - return new SearchMcpServersFixedSizeCollection(null, 0); + private static ListAiApplicationAgentsFixedSizeCollection createEmptyCollection() { + return new ListAiApplicationAgentsFixedSizeCollection(null, 0); } @Override - protected SearchMcpServersFixedSizeCollection createCollection( - @Nullable List pages, int collectionSize) { - return new SearchMcpServersFixedSizeCollection(pages, collectionSize); + protected ListAiApplicationAgentsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListAiApplicationAgentsFixedSizeCollection(pages, collectionSize); } } - public static class ListServicesPagedResponse + public static class ListAiApplicationMcpServersPagedResponse extends AbstractPagedListResponse< - ListServicesRequest, - ListServicesResponse, - Service, - ListServicesPage, - ListServicesFixedSizeCollection> { + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + McpServer, + ListAiApplicationMcpServersPage, + ListAiApplicationMcpServersFixedSizeCollection> { - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListServicesPage.createEmptyPage().createPageAsync(context, futureResponse); + public static ApiFuture createAsync( + PageContext< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersResponse, McpServer> + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListAiApplicationMcpServersPage.createEmptyPage() + .createPageAsync(context, futureResponse); return ApiFutures.transform( futurePage, - input -> new ListServicesPagedResponse(input), + input -> new ListAiApplicationMcpServersPagedResponse(input), MoreExecutors.directExecutor()); } - private ListServicesPagedResponse(ListServicesPage page) { - super(page, ListServicesFixedSizeCollection.createEmptyCollection()); + private ListAiApplicationMcpServersPagedResponse(ListAiApplicationMcpServersPage page) { + super(page, ListAiApplicationMcpServersFixedSizeCollection.createEmptyCollection()); } } - public static class ListServicesPage - extends AbstractPage { + public static class ListAiApplicationMcpServersPage + extends AbstractPage< + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + McpServer, + ListAiApplicationMcpServersPage> { - private ListServicesPage( - @Nullable PageContext context, - @Nullable ListServicesResponse response) { + private ListAiApplicationMcpServersPage( + @Nullable + PageContext< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersResponse, McpServer> + context, + @Nullable ListAiApplicationMcpServersResponse response) { super(context, response); } - private static ListServicesPage createEmptyPage() { - return new ListServicesPage(null, null); + private static ListAiApplicationMcpServersPage createEmptyPage() { + return new ListAiApplicationMcpServersPage(null, null); } @Override - protected ListServicesPage createPage( - @Nullable PageContext context, - @Nullable ListServicesResponse response) { - return new ListServicesPage(context, response); + protected ListAiApplicationMcpServersPage createPage( + @Nullable + PageContext< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersResponse, McpServer> + context, + @Nullable ListAiApplicationMcpServersResponse response) { + return new ListAiApplicationMcpServersPage(context, response); } @Override - public ApiFuture createPageAsync( - @Nullable PageContext context, - ApiFuture futureResponse) { + public ApiFuture createPageAsync( + @Nullable + PageContext< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersResponse, McpServer> + context, + ApiFuture futureResponse) { return super.createPageAsync(context, futureResponse); } } - public static class ListServicesFixedSizeCollection + public static class ListAiApplicationMcpServersFixedSizeCollection extends AbstractFixedSizeCollection< - ListServicesRequest, - ListServicesResponse, - Service, - ListServicesPage, - ListServicesFixedSizeCollection> { + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + McpServer, + ListAiApplicationMcpServersPage, + ListAiApplicationMcpServersFixedSizeCollection> { - private ListServicesFixedSizeCollection( - @Nullable List pages, int collectionSize) { + private ListAiApplicationMcpServersFixedSizeCollection( + @Nullable List pages, int collectionSize) { super(pages, collectionSize); } - private static ListServicesFixedSizeCollection createEmptyCollection() { - return new ListServicesFixedSizeCollection(null, 0); + private static ListAiApplicationMcpServersFixedSizeCollection createEmptyCollection() { + return new ListAiApplicationMcpServersFixedSizeCollection(null, 0); } @Override - protected ListServicesFixedSizeCollection createCollection( - @Nullable List pages, int collectionSize) { - return new ListServicesFixedSizeCollection(pages, collectionSize); + protected ListAiApplicationMcpServersFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListAiApplicationMcpServersFixedSizeCollection(pages, collectionSize); } } - public static class ListBindingsPagedResponse + public static class ListFindingsPagedResponse extends AbstractPagedListResponse< - ListBindingsRequest, - ListBindingsResponse, - Binding, - ListBindingsPage, - ListBindingsFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListBindingsPage.createEmptyPage().createPageAsync(context, futureResponse); + ListFindingsRequest, + ListFindingsResponse, + Finding, + ListFindingsPage, + ListFindingsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListFindingsPage.createEmptyPage().createPageAsync(context, futureResponse); return ApiFutures.transform( futurePage, - input -> new ListBindingsPagedResponse(input), + input -> new ListFindingsPagedResponse(input), MoreExecutors.directExecutor()); } - private ListBindingsPagedResponse(ListBindingsPage page) { - super(page, ListBindingsFixedSizeCollection.createEmptyCollection()); + private ListFindingsPagedResponse(ListFindingsPage page) { + super(page, ListFindingsFixedSizeCollection.createEmptyCollection()); } } - public static class ListBindingsPage - extends AbstractPage { + public static class ListFindingsPage + extends AbstractPage { - private ListBindingsPage( - @Nullable PageContext context, - @Nullable ListBindingsResponse response) { + private ListFindingsPage( + @Nullable PageContext context, + @Nullable ListFindingsResponse response) { super(context, response); } - private static ListBindingsPage createEmptyPage() { - return new ListBindingsPage(null, null); + private static ListFindingsPage createEmptyPage() { + return new ListFindingsPage(null, null); } @Override - protected ListBindingsPage createPage( - @Nullable PageContext context, - @Nullable ListBindingsResponse response) { - return new ListBindingsPage(context, response); + protected ListFindingsPage createPage( + @Nullable PageContext context, + @Nullable ListFindingsResponse response) { + return new ListFindingsPage(context, response); } @Override - public ApiFuture createPageAsync( - @Nullable PageContext context, - ApiFuture futureResponse) { + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { return super.createPageAsync(context, futureResponse); } } - public static class ListBindingsFixedSizeCollection + public static class ListFindingsFixedSizeCollection extends AbstractFixedSizeCollection< - ListBindingsRequest, - ListBindingsResponse, - Binding, - ListBindingsPage, - ListBindingsFixedSizeCollection> { - - private ListBindingsFixedSizeCollection( - @Nullable List pages, int collectionSize) { + ListFindingsRequest, + ListFindingsResponse, + Finding, + ListFindingsPage, + ListFindingsFixedSizeCollection> { + + private ListFindingsFixedSizeCollection( + @Nullable List pages, int collectionSize) { super(pages, collectionSize); } - private static ListBindingsFixedSizeCollection createEmptyCollection() { - return new ListBindingsFixedSizeCollection(null, 0); + private static ListFindingsFixedSizeCollection createEmptyCollection() { + return new ListFindingsFixedSizeCollection(null, 0); } @Override - protected ListBindingsFixedSizeCollection createCollection( - @Nullable List pages, int collectionSize) { - return new ListBindingsFixedSizeCollection(pages, collectionSize); + protected ListFindingsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListFindingsFixedSizeCollection(pages, collectionSize); } } - public static class FetchAvailableBindingsPagedResponse + public static class ListAiApplicationEndpointsPagedResponse extends AbstractPagedListResponse< - FetchAvailableBindingsRequest, - FetchAvailableBindingsResponse, - Binding, - FetchAvailableBindingsPage, - FetchAvailableBindingsFixedSizeCollection> { + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + Endpoint, + ListAiApplicationEndpointsPage, + ListAiApplicationEndpointsFixedSizeCollection> { - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - FetchAvailableBindingsPage.createEmptyPage().createPageAsync(context, futureResponse); + public static ApiFuture createAsync( + PageContext + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListAiApplicationEndpointsPage.createEmptyPage().createPageAsync(context, futureResponse); return ApiFutures.transform( futurePage, - input -> new FetchAvailableBindingsPagedResponse(input), + input -> new ListAiApplicationEndpointsPagedResponse(input), MoreExecutors.directExecutor()); } - private FetchAvailableBindingsPagedResponse(FetchAvailableBindingsPage page) { - super(page, FetchAvailableBindingsFixedSizeCollection.createEmptyCollection()); + private ListAiApplicationEndpointsPagedResponse(ListAiApplicationEndpointsPage page) { + super(page, ListAiApplicationEndpointsFixedSizeCollection.createEmptyCollection()); } } - public static class FetchAvailableBindingsPage + public static class ListAiApplicationEndpointsPage extends AbstractPage< - FetchAvailableBindingsRequest, - FetchAvailableBindingsResponse, - Binding, - FetchAvailableBindingsPage> { + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + Endpoint, + ListAiApplicationEndpointsPage> { - private FetchAvailableBindingsPage( + private ListAiApplicationEndpointsPage( @Nullable - PageContext + PageContext< + ListAiApplicationEndpointsRequest, ListAiApplicationEndpointsResponse, Endpoint> context, - @Nullable FetchAvailableBindingsResponse response) { + @Nullable ListAiApplicationEndpointsResponse response) { super(context, response); } - private static FetchAvailableBindingsPage createEmptyPage() { - return new FetchAvailableBindingsPage(null, null); + private static ListAiApplicationEndpointsPage createEmptyPage() { + return new ListAiApplicationEndpointsPage(null, null); } @Override - protected FetchAvailableBindingsPage createPage( + protected ListAiApplicationEndpointsPage createPage( @Nullable - PageContext + PageContext< + ListAiApplicationEndpointsRequest, ListAiApplicationEndpointsResponse, Endpoint> context, - @Nullable FetchAvailableBindingsResponse response) { - return new FetchAvailableBindingsPage(context, response); + @Nullable ListAiApplicationEndpointsResponse response) { + return new ListAiApplicationEndpointsPage(context, response); } @Override - public ApiFuture createPageAsync( + public ApiFuture createPageAsync( @Nullable - PageContext + PageContext< + ListAiApplicationEndpointsRequest, ListAiApplicationEndpointsResponse, Endpoint> context, - ApiFuture futureResponse) { + ApiFuture futureResponse) { return super.createPageAsync(context, futureResponse); } } - public static class FetchAvailableBindingsFixedSizeCollection + public static class ListAiApplicationEndpointsFixedSizeCollection extends AbstractFixedSizeCollection< - FetchAvailableBindingsRequest, - FetchAvailableBindingsResponse, - Binding, - FetchAvailableBindingsPage, - FetchAvailableBindingsFixedSizeCollection> { + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + Endpoint, + ListAiApplicationEndpointsPage, + ListAiApplicationEndpointsFixedSizeCollection> { - private FetchAvailableBindingsFixedSizeCollection( - @Nullable List pages, int collectionSize) { + private ListAiApplicationEndpointsFixedSizeCollection( + @Nullable List pages, int collectionSize) { super(pages, collectionSize); } - private static FetchAvailableBindingsFixedSizeCollection createEmptyCollection() { - return new FetchAvailableBindingsFixedSizeCollection(null, 0); + private static ListAiApplicationEndpointsFixedSizeCollection createEmptyCollection() { + return new ListAiApplicationEndpointsFixedSizeCollection(null, 0); } @Override - protected FetchAvailableBindingsFixedSizeCollection createCollection( - @Nullable List pages, int collectionSize) { - return new FetchAvailableBindingsFixedSizeCollection(pages, collectionSize); + protected ListAiApplicationEndpointsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListAiApplicationEndpointsFixedSizeCollection(pages, collectionSize); } } diff --git a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistrySettings.java b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistrySettings.java index 63a480df5def..102b91c0f497 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistrySettings.java +++ b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistrySettings.java @@ -18,13 +18,22 @@ import static com.google.cloud.agentregistry.v1.AgentRegistryClient.FetchAvailableBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListFindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListLocationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListPublishersPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListServicesPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillRevisionsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchAgentsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchSkillsPagedResponse; import com.google.api.core.ApiFunction; import com.google.api.core.BetaApi; @@ -274,6 +283,189 @@ public UnaryCallSettings deleteBindingSettings( return ((AgentRegistryStubSettings) getStubSettings()).fetchAvailableBindingsSettings(); } + /** Returns the object with the settings used for calls to createSkill. */ + public UnaryCallSettings createSkillSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).createSkillSettings(); + } + + /** Returns the object with the settings used for calls to createSkill. */ + public OperationCallSettings + createSkillOperationSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).createSkillOperationSettings(); + } + + /** Returns the object with the settings used for calls to getSkill. */ + public UnaryCallSettings getSkillSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).getSkillSettings(); + } + + /** Returns the object with the settings used for calls to updateSkill. */ + public UnaryCallSettings updateSkillSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).updateSkillSettings(); + } + + /** Returns the object with the settings used for calls to updateSkill. */ + public OperationCallSettings + updateSkillOperationSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).updateSkillOperationSettings(); + } + + /** Returns the object with the settings used for calls to deleteSkill. */ + public UnaryCallSettings deleteSkillSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).deleteSkillSettings(); + } + + /** Returns the object with the settings used for calls to deleteSkill. */ + public OperationCallSettings + deleteSkillOperationSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).deleteSkillOperationSettings(); + } + + /** Returns the object with the settings used for calls to listSkills. */ + public PagedCallSettings + listSkillsSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).listSkillsSettings(); + } + + /** Returns the object with the settings used for calls to searchSkills. */ + public PagedCallSettings + searchSkillsSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).searchSkillsSettings(); + } + + /** Returns the object with the settings used for calls to createSkillRevision. */ + public UnaryCallSettings createSkillRevisionSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).createSkillRevisionSettings(); + } + + /** Returns the object with the settings used for calls to createSkillRevision. */ + public OperationCallSettings + createSkillRevisionOperationSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).createSkillRevisionOperationSettings(); + } + + /** Returns the object with the settings used for calls to getSkillRevision. */ + public UnaryCallSettings getSkillRevisionSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).getSkillRevisionSettings(); + } + + /** Returns the object with the settings used for calls to deleteSkillRevision. */ + public UnaryCallSettings deleteSkillRevisionSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).deleteSkillRevisionSettings(); + } + + /** Returns the object with the settings used for calls to deleteSkillRevision. */ + public OperationCallSettings + deleteSkillRevisionOperationSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).deleteSkillRevisionOperationSettings(); + } + + /** Returns the object with the settings used for calls to listSkillRevisions. */ + public PagedCallSettings< + ListSkillRevisionsRequest, ListSkillRevisionsResponse, ListSkillRevisionsPagedResponse> + listSkillRevisionsSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).listSkillRevisionsSettings(); + } + + /** Returns the object with the settings used for calls to getPublisher. */ + public UnaryCallSettings getPublisherSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).getPublisherSettings(); + } + + /** Returns the object with the settings used for calls to listPublishers. */ + public PagedCallSettings< + ListPublishersRequest, ListPublishersResponse, ListPublishersPagedResponse> + listPublishersSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).listPublishersSettings(); + } + + /** Returns the object with the settings used for calls to getAiApplication. */ + public UnaryCallSettings getAiApplicationSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).getAiApplicationSettings(); + } + + /** Returns the object with the settings used for calls to listAiApplications. */ + public PagedCallSettings< + ListAiApplicationsRequest, ListAiApplicationsResponse, ListAiApplicationsPagedResponse> + listAiApplicationsSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).listAiApplicationsSettings(); + } + + /** Returns the object with the settings used for calls to getAiApplicationAgent. */ + public UnaryCallSettings getAiApplicationAgentSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).getAiApplicationAgentSettings(); + } + + /** Returns the object with the settings used for calls to listAiApplicationAgents. */ + public PagedCallSettings< + ListAiApplicationAgentsRequest, + ListAiApplicationAgentsResponse, + ListAiApplicationAgentsPagedResponse> + listAiApplicationAgentsSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).listAiApplicationAgentsSettings(); + } + + /** Returns the object with the settings used for calls to getAiApplicationMcpServer. */ + public UnaryCallSettings + getAiApplicationMcpServerSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).getAiApplicationMcpServerSettings(); + } + + /** Returns the object with the settings used for calls to listAiApplicationMcpServers. */ + public PagedCallSettings< + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + ListAiApplicationMcpServersPagedResponse> + listAiApplicationMcpServersSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).listAiApplicationMcpServersSettings(); + } + + /** Returns the object with the settings used for calls to getFinding. */ + public UnaryCallSettings getFindingSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).getFindingSettings(); + } + + /** Returns the object with the settings used for calls to listFindings. */ + public PagedCallSettings + listFindingsSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).listFindingsSettings(); + } + + /** Returns the object with the settings used for calls to getAiApplicationEndpoint. */ + public UnaryCallSettings + getAiApplicationEndpointSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).getAiApplicationEndpointSettings(); + } + + /** Returns the object with the settings used for calls to listAiApplicationEndpoints. */ + public PagedCallSettings< + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + ListAiApplicationEndpointsPagedResponse> + listAiApplicationEndpointsSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).listAiApplicationEndpointsSettings(); + } + + /** Returns the object with the settings used for calls to getSkillEncryptionSpec. */ + public UnaryCallSettings + getSkillEncryptionSpecSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).getSkillEncryptionSpecSettings(); + } + + /** Returns the object with the settings used for calls to updateSkillEncryptionSpec. */ + public UnaryCallSettings + updateSkillEncryptionSpecSettings() { + return ((AgentRegistryStubSettings) getStubSettings()).updateSkillEncryptionSpecSettings(); + } + + /** Returns the object with the settings used for calls to updateSkillEncryptionSpec. */ + public OperationCallSettings< + UpdateSkillEncryptionSpecRequest, SkillEncryptionSpec, OperationMetadata> + updateSkillEncryptionSpecOperationSettings() { + return ((AgentRegistryStubSettings) getStubSettings()) + .updateSkillEncryptionSpecOperationSettings(); + } + /** Returns the object with the settings used for calls to listLocations. */ public PagedCallSettings listLocationsSettings() { @@ -545,6 +737,196 @@ public UnaryCallSettings.Builder deleteBindingS return getStubSettingsBuilder().fetchAvailableBindingsSettings(); } + /** Returns the builder for the settings used for calls to createSkill. */ + public UnaryCallSettings.Builder createSkillSettings() { + return getStubSettingsBuilder().createSkillSettings(); + } + + /** Returns the builder for the settings used for calls to createSkill. */ + public OperationCallSettings.Builder + createSkillOperationSettings() { + return getStubSettingsBuilder().createSkillOperationSettings(); + } + + /** Returns the builder for the settings used for calls to getSkill. */ + public UnaryCallSettings.Builder getSkillSettings() { + return getStubSettingsBuilder().getSkillSettings(); + } + + /** Returns the builder for the settings used for calls to updateSkill. */ + public UnaryCallSettings.Builder updateSkillSettings() { + return getStubSettingsBuilder().updateSkillSettings(); + } + + /** Returns the builder for the settings used for calls to updateSkill. */ + public OperationCallSettings.Builder + updateSkillOperationSettings() { + return getStubSettingsBuilder().updateSkillOperationSettings(); + } + + /** Returns the builder for the settings used for calls to deleteSkill. */ + public UnaryCallSettings.Builder deleteSkillSettings() { + return getStubSettingsBuilder().deleteSkillSettings(); + } + + /** Returns the builder for the settings used for calls to deleteSkill. */ + public OperationCallSettings.Builder + deleteSkillOperationSettings() { + return getStubSettingsBuilder().deleteSkillOperationSettings(); + } + + /** Returns the builder for the settings used for calls to listSkills. */ + public PagedCallSettings.Builder + listSkillsSettings() { + return getStubSettingsBuilder().listSkillsSettings(); + } + + /** Returns the builder for the settings used for calls to searchSkills. */ + public PagedCallSettings.Builder< + SearchSkillsRequest, SearchSkillsResponse, SearchSkillsPagedResponse> + searchSkillsSettings() { + return getStubSettingsBuilder().searchSkillsSettings(); + } + + /** Returns the builder for the settings used for calls to createSkillRevision. */ + public UnaryCallSettings.Builder + createSkillRevisionSettings() { + return getStubSettingsBuilder().createSkillRevisionSettings(); + } + + /** Returns the builder for the settings used for calls to createSkillRevision. */ + public OperationCallSettings.Builder< + CreateSkillRevisionRequest, SkillRevision, OperationMetadata> + createSkillRevisionOperationSettings() { + return getStubSettingsBuilder().createSkillRevisionOperationSettings(); + } + + /** Returns the builder for the settings used for calls to getSkillRevision. */ + public UnaryCallSettings.Builder + getSkillRevisionSettings() { + return getStubSettingsBuilder().getSkillRevisionSettings(); + } + + /** Returns the builder for the settings used for calls to deleteSkillRevision. */ + public UnaryCallSettings.Builder + deleteSkillRevisionSettings() { + return getStubSettingsBuilder().deleteSkillRevisionSettings(); + } + + /** Returns the builder for the settings used for calls to deleteSkillRevision. */ + public OperationCallSettings.Builder + deleteSkillRevisionOperationSettings() { + return getStubSettingsBuilder().deleteSkillRevisionOperationSettings(); + } + + /** Returns the builder for the settings used for calls to listSkillRevisions. */ + public PagedCallSettings.Builder< + ListSkillRevisionsRequest, ListSkillRevisionsResponse, ListSkillRevisionsPagedResponse> + listSkillRevisionsSettings() { + return getStubSettingsBuilder().listSkillRevisionsSettings(); + } + + /** Returns the builder for the settings used for calls to getPublisher. */ + public UnaryCallSettings.Builder getPublisherSettings() { + return getStubSettingsBuilder().getPublisherSettings(); + } + + /** Returns the builder for the settings used for calls to listPublishers. */ + public PagedCallSettings.Builder< + ListPublishersRequest, ListPublishersResponse, ListPublishersPagedResponse> + listPublishersSettings() { + return getStubSettingsBuilder().listPublishersSettings(); + } + + /** Returns the builder for the settings used for calls to getAiApplication. */ + public UnaryCallSettings.Builder + getAiApplicationSettings() { + return getStubSettingsBuilder().getAiApplicationSettings(); + } + + /** Returns the builder for the settings used for calls to listAiApplications. */ + public PagedCallSettings.Builder< + ListAiApplicationsRequest, ListAiApplicationsResponse, ListAiApplicationsPagedResponse> + listAiApplicationsSettings() { + return getStubSettingsBuilder().listAiApplicationsSettings(); + } + + /** Returns the builder for the settings used for calls to getAiApplicationAgent. */ + public UnaryCallSettings.Builder + getAiApplicationAgentSettings() { + return getStubSettingsBuilder().getAiApplicationAgentSettings(); + } + + /** Returns the builder for the settings used for calls to listAiApplicationAgents. */ + public PagedCallSettings.Builder< + ListAiApplicationAgentsRequest, + ListAiApplicationAgentsResponse, + ListAiApplicationAgentsPagedResponse> + listAiApplicationAgentsSettings() { + return getStubSettingsBuilder().listAiApplicationAgentsSettings(); + } + + /** Returns the builder for the settings used for calls to getAiApplicationMcpServer. */ + public UnaryCallSettings.Builder + getAiApplicationMcpServerSettings() { + return getStubSettingsBuilder().getAiApplicationMcpServerSettings(); + } + + /** Returns the builder for the settings used for calls to listAiApplicationMcpServers. */ + public PagedCallSettings.Builder< + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + ListAiApplicationMcpServersPagedResponse> + listAiApplicationMcpServersSettings() { + return getStubSettingsBuilder().listAiApplicationMcpServersSettings(); + } + + /** Returns the builder for the settings used for calls to getFinding. */ + public UnaryCallSettings.Builder getFindingSettings() { + return getStubSettingsBuilder().getFindingSettings(); + } + + /** Returns the builder for the settings used for calls to listFindings. */ + public PagedCallSettings.Builder< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse> + listFindingsSettings() { + return getStubSettingsBuilder().listFindingsSettings(); + } + + /** Returns the builder for the settings used for calls to getAiApplicationEndpoint. */ + public UnaryCallSettings.Builder + getAiApplicationEndpointSettings() { + return getStubSettingsBuilder().getAiApplicationEndpointSettings(); + } + + /** Returns the builder for the settings used for calls to listAiApplicationEndpoints. */ + public PagedCallSettings.Builder< + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + ListAiApplicationEndpointsPagedResponse> + listAiApplicationEndpointsSettings() { + return getStubSettingsBuilder().listAiApplicationEndpointsSettings(); + } + + /** Returns the builder for the settings used for calls to getSkillEncryptionSpec. */ + public UnaryCallSettings.Builder + getSkillEncryptionSpecSettings() { + return getStubSettingsBuilder().getSkillEncryptionSpecSettings(); + } + + /** Returns the builder for the settings used for calls to updateSkillEncryptionSpec. */ + public UnaryCallSettings.Builder + updateSkillEncryptionSpecSettings() { + return getStubSettingsBuilder().updateSkillEncryptionSpecSettings(); + } + + /** Returns the builder for the settings used for calls to updateSkillEncryptionSpec. */ + public OperationCallSettings.Builder< + UpdateSkillEncryptionSpecRequest, SkillEncryptionSpec, OperationMetadata> + updateSkillEncryptionSpecOperationSettings() { + return getStubSettingsBuilder().updateSkillEncryptionSpecOperationSettings(); + } + /** Returns the builder for the settings used for calls to listLocations. */ public PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> diff --git a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/gapic_metadata.json b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/gapic_metadata.json index 27dc690c6170..606230a622cd 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/gapic_metadata.json +++ b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/gapic_metadata.json @@ -16,62 +16,134 @@ "CreateService": { "methods": ["createServiceAsync", "createServiceAsync", "createServiceAsync", "createServiceOperationCallable", "createServiceCallable"] }, + "CreateSkill": { + "methods": ["createSkillAsync", "createSkillAsync", "createSkillAsync", "createSkillOperationCallable", "createSkillCallable"] + }, + "CreateSkillRevision": { + "methods": ["createSkillRevisionAsync", "createSkillRevisionAsync", "createSkillRevisionAsync", "createSkillRevisionOperationCallable", "createSkillRevisionCallable"] + }, "DeleteBinding": { "methods": ["deleteBindingAsync", "deleteBindingAsync", "deleteBindingAsync", "deleteBindingOperationCallable", "deleteBindingCallable"] }, "DeleteService": { "methods": ["deleteServiceAsync", "deleteServiceAsync", "deleteServiceAsync", "deleteServiceOperationCallable", "deleteServiceCallable"] }, + "DeleteSkill": { + "methods": ["deleteSkillAsync", "deleteSkillAsync", "deleteSkillAsync", "deleteSkillOperationCallable", "deleteSkillCallable"] + }, + "DeleteSkillRevision": { + "methods": ["deleteSkillRevisionAsync", "deleteSkillRevisionAsync", "deleteSkillRevisionAsync", "deleteSkillRevisionOperationCallable", "deleteSkillRevisionCallable"] + }, "FetchAvailableBindings": { "methods": ["fetchAvailableBindings", "fetchAvailableBindings", "fetchAvailableBindings", "fetchAvailableBindingsPagedCallable", "fetchAvailableBindingsCallable"] }, "GetAgent": { "methods": ["getAgent", "getAgent", "getAgent", "getAgentCallable"] }, + "GetAiApplication": { + "methods": ["getAiApplication", "getAiApplication", "getAiApplication", "getAiApplicationCallable"] + }, + "GetAiApplicationAgent": { + "methods": ["getAiApplicationAgent", "getAiApplicationAgent", "getAiApplicationAgent", "getAiApplicationAgentCallable"] + }, + "GetAiApplicationEndpoint": { + "methods": ["getAiApplicationEndpoint", "getAiApplicationEndpoint", "getAiApplicationEndpoint", "getAiApplicationEndpointCallable"] + }, + "GetAiApplicationMcpServer": { + "methods": ["getAiApplicationMcpServer", "getAiApplicationMcpServer", "getAiApplicationMcpServer", "getAiApplicationMcpServerCallable"] + }, "GetBinding": { "methods": ["getBinding", "getBinding", "getBinding", "getBindingCallable"] }, "GetEndpoint": { "methods": ["getEndpoint", "getEndpoint", "getEndpoint", "getEndpointCallable"] }, + "GetFinding": { + "methods": ["getFinding", "getFinding", "getFinding", "getFindingCallable"] + }, "GetLocation": { "methods": ["getLocation", "getLocationCallable"] }, "GetMcpServer": { "methods": ["getMcpServer", "getMcpServer", "getMcpServer", "getMcpServerCallable"] }, + "GetPublisher": { + "methods": ["getPublisher", "getPublisher", "getPublisher", "getPublisherCallable"] + }, "GetService": { "methods": ["getService", "getService", "getService", "getServiceCallable"] }, + "GetSkill": { + "methods": ["getSkill", "getSkill", "getSkill", "getSkillCallable"] + }, + "GetSkillEncryptionSpec": { + "methods": ["getSkillEncryptionSpec", "getSkillEncryptionSpec", "getSkillEncryptionSpec", "getSkillEncryptionSpecCallable"] + }, + "GetSkillRevision": { + "methods": ["getSkillRevision", "getSkillRevision", "getSkillRevision", "getSkillRevisionCallable"] + }, "ListAgents": { "methods": ["listAgents", "listAgents", "listAgents", "listAgentsPagedCallable", "listAgentsCallable"] }, + "ListAiApplicationAgents": { + "methods": ["listAiApplicationAgents", "listAiApplicationAgents", "listAiApplicationAgents", "listAiApplicationAgentsPagedCallable", "listAiApplicationAgentsCallable"] + }, + "ListAiApplicationEndpoints": { + "methods": ["listAiApplicationEndpoints", "listAiApplicationEndpoints", "listAiApplicationEndpoints", "listAiApplicationEndpointsPagedCallable", "listAiApplicationEndpointsCallable"] + }, + "ListAiApplicationMcpServers": { + "methods": ["listAiApplicationMcpServers", "listAiApplicationMcpServers", "listAiApplicationMcpServers", "listAiApplicationMcpServersPagedCallable", "listAiApplicationMcpServersCallable"] + }, + "ListAiApplications": { + "methods": ["listAiApplications", "listAiApplications", "listAiApplications", "listAiApplicationsPagedCallable", "listAiApplicationsCallable"] + }, "ListBindings": { "methods": ["listBindings", "listBindings", "listBindings", "listBindingsPagedCallable", "listBindingsCallable"] }, "ListEndpoints": { "methods": ["listEndpoints", "listEndpoints", "listEndpoints", "listEndpointsPagedCallable", "listEndpointsCallable"] }, + "ListFindings": { + "methods": ["listFindings", "listFindings", "listFindings", "listFindingsPagedCallable", "listFindingsCallable"] + }, "ListLocations": { "methods": ["listLocations", "listLocationsPagedCallable", "listLocationsCallable"] }, "ListMcpServers": { "methods": ["listMcpServers", "listMcpServers", "listMcpServers", "listMcpServersPagedCallable", "listMcpServersCallable"] }, + "ListPublishers": { + "methods": ["listPublishers", "listPublishers", "listPublishers", "listPublishersPagedCallable", "listPublishersCallable"] + }, "ListServices": { "methods": ["listServices", "listServices", "listServices", "listServicesPagedCallable", "listServicesCallable"] }, + "ListSkillRevisions": { + "methods": ["listSkillRevisions", "listSkillRevisions", "listSkillRevisions", "listSkillRevisionsPagedCallable", "listSkillRevisionsCallable"] + }, + "ListSkills": { + "methods": ["listSkills", "listSkills", "listSkills", "listSkillsPagedCallable", "listSkillsCallable"] + }, "SearchAgents": { "methods": ["searchAgents", "searchAgents", "searchAgents", "searchAgentsPagedCallable", "searchAgentsCallable"] }, "SearchMcpServers": { "methods": ["searchMcpServers", "searchMcpServers", "searchMcpServers", "searchMcpServersPagedCallable", "searchMcpServersCallable"] }, + "SearchSkills": { + "methods": ["searchSkills", "searchSkillsPagedCallable", "searchSkillsCallable"] + }, "UpdateBinding": { "methods": ["updateBindingAsync", "updateBindingAsync", "updateBindingOperationCallable", "updateBindingCallable"] }, "UpdateService": { "methods": ["updateServiceAsync", "updateServiceAsync", "updateServiceOperationCallable", "updateServiceCallable"] + }, + "UpdateSkill": { + "methods": ["updateSkillAsync", "updateSkillAsync", "updateSkillOperationCallable", "updateSkillCallable"] + }, + "UpdateSkillEncryptionSpec": { + "methods": ["updateSkillEncryptionSpecAsync", "updateSkillEncryptionSpecAsync", "updateSkillEncryptionSpecOperationCallable", "updateSkillEncryptionSpecCallable"] } } } diff --git a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/package-info.java b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/package-info.java index d21ff3ab2b69..2fba7046b773 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/package-info.java +++ b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/package-info.java @@ -21,8 +21,7 @@ * *

======================= AgentRegistryClient ======================= * - *

Service Description: Service for managing Agents, Endpoints, McpServers, Services, and - * Bindings. + *

Service Description: Service for managing Agent Registry resources. * *

Sample for AgentRegistryClient: * @@ -33,7 +32,7 @@ * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - * AgentName name = AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]"); + * AgentName name = AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]"); * Agent response = agentRegistryClient.getAgent(name); * } * } diff --git a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/AgentRegistryStub.java b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/AgentRegistryStub.java index ebb2a8db2475..b2fcbb81b859 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/AgentRegistryStub.java +++ b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/AgentRegistryStub.java @@ -18,50 +18,98 @@ import static com.google.cloud.agentregistry.v1.AgentRegistryClient.FetchAvailableBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListFindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListLocationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListPublishersPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListServicesPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillRevisionsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchAgentsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchSkillsPagedResponse; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AiApplication; import com.google.cloud.agentregistry.v1.Binding; import com.google.cloud.agentregistry.v1.CreateBindingRequest; import com.google.cloud.agentregistry.v1.CreateServiceRequest; +import com.google.cloud.agentregistry.v1.CreateSkillRequest; +import com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest; import com.google.cloud.agentregistry.v1.DeleteBindingRequest; import com.google.cloud.agentregistry.v1.DeleteServiceRequest; +import com.google.cloud.agentregistry.v1.DeleteSkillRequest; +import com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest; import com.google.cloud.agentregistry.v1.Endpoint; import com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest; import com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse; +import com.google.cloud.agentregistry.v1.Finding; import com.google.cloud.agentregistry.v1.GetAgentRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationRequest; import com.google.cloud.agentregistry.v1.GetBindingRequest; import com.google.cloud.agentregistry.v1.GetEndpointRequest; +import com.google.cloud.agentregistry.v1.GetFindingRequest; import com.google.cloud.agentregistry.v1.GetMcpServerRequest; +import com.google.cloud.agentregistry.v1.GetPublisherRequest; import com.google.cloud.agentregistry.v1.GetServiceRequest; +import com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest; +import com.google.cloud.agentregistry.v1.GetSkillRequest; +import com.google.cloud.agentregistry.v1.GetSkillRevisionRequest; import com.google.cloud.agentregistry.v1.ListAgentsRequest; import com.google.cloud.agentregistry.v1.ListAgentsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationsResponse; import com.google.cloud.agentregistry.v1.ListBindingsRequest; import com.google.cloud.agentregistry.v1.ListBindingsResponse; import com.google.cloud.agentregistry.v1.ListEndpointsRequest; import com.google.cloud.agentregistry.v1.ListEndpointsResponse; +import com.google.cloud.agentregistry.v1.ListFindingsRequest; +import com.google.cloud.agentregistry.v1.ListFindingsResponse; import com.google.cloud.agentregistry.v1.ListMcpServersRequest; import com.google.cloud.agentregistry.v1.ListMcpServersResponse; +import com.google.cloud.agentregistry.v1.ListPublishersRequest; +import com.google.cloud.agentregistry.v1.ListPublishersResponse; import com.google.cloud.agentregistry.v1.ListServicesRequest; import com.google.cloud.agentregistry.v1.ListServicesResponse; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse; +import com.google.cloud.agentregistry.v1.ListSkillsRequest; +import com.google.cloud.agentregistry.v1.ListSkillsResponse; import com.google.cloud.agentregistry.v1.McpServer; import com.google.cloud.agentregistry.v1.OperationMetadata; +import com.google.cloud.agentregistry.v1.Publisher; import com.google.cloud.agentregistry.v1.SearchAgentsRequest; import com.google.cloud.agentregistry.v1.SearchAgentsResponse; import com.google.cloud.agentregistry.v1.SearchMcpServersRequest; import com.google.cloud.agentregistry.v1.SearchMcpServersResponse; +import com.google.cloud.agentregistry.v1.SearchSkillsRequest; +import com.google.cloud.agentregistry.v1.SearchSkillsResponse; import com.google.cloud.agentregistry.v1.Service; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.cloud.agentregistry.v1.SkillRevision; import com.google.cloud.agentregistry.v1.UpdateBindingRequest; import com.google.cloud.agentregistry.v1.UpdateServiceRequest; +import com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest; +import com.google.cloud.agentregistry.v1.UpdateSkillRequest; import com.google.cloud.location.GetLocationRequest; import com.google.cloud.location.ListLocationsRequest; import com.google.cloud.location.ListLocationsResponse; @@ -237,6 +285,191 @@ public UnaryCallable deleteBindingCallable() { throw new UnsupportedOperationException("Not implemented: fetchAvailableBindingsCallable()"); } + public OperationCallable + createSkillOperationCallable() { + throw new UnsupportedOperationException("Not implemented: createSkillOperationCallable()"); + } + + public UnaryCallable createSkillCallable() { + throw new UnsupportedOperationException("Not implemented: createSkillCallable()"); + } + + public UnaryCallable getSkillCallable() { + throw new UnsupportedOperationException("Not implemented: getSkillCallable()"); + } + + public OperationCallable + updateSkillOperationCallable() { + throw new UnsupportedOperationException("Not implemented: updateSkillOperationCallable()"); + } + + public UnaryCallable updateSkillCallable() { + throw new UnsupportedOperationException("Not implemented: updateSkillCallable()"); + } + + public OperationCallable + deleteSkillOperationCallable() { + throw new UnsupportedOperationException("Not implemented: deleteSkillOperationCallable()"); + } + + public UnaryCallable deleteSkillCallable() { + throw new UnsupportedOperationException("Not implemented: deleteSkillCallable()"); + } + + public UnaryCallable listSkillsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listSkillsPagedCallable()"); + } + + public UnaryCallable listSkillsCallable() { + throw new UnsupportedOperationException("Not implemented: listSkillsCallable()"); + } + + public UnaryCallable searchSkillsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: searchSkillsPagedCallable()"); + } + + public UnaryCallable searchSkillsCallable() { + throw new UnsupportedOperationException("Not implemented: searchSkillsCallable()"); + } + + public OperationCallable + createSkillRevisionOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: createSkillRevisionOperationCallable()"); + } + + public UnaryCallable createSkillRevisionCallable() { + throw new UnsupportedOperationException("Not implemented: createSkillRevisionCallable()"); + } + + public UnaryCallable getSkillRevisionCallable() { + throw new UnsupportedOperationException("Not implemented: getSkillRevisionCallable()"); + } + + public OperationCallable + deleteSkillRevisionOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: deleteSkillRevisionOperationCallable()"); + } + + public UnaryCallable deleteSkillRevisionCallable() { + throw new UnsupportedOperationException("Not implemented: deleteSkillRevisionCallable()"); + } + + public UnaryCallable + listSkillRevisionsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listSkillRevisionsPagedCallable()"); + } + + public UnaryCallable + listSkillRevisionsCallable() { + throw new UnsupportedOperationException("Not implemented: listSkillRevisionsCallable()"); + } + + public UnaryCallable getPublisherCallable() { + throw new UnsupportedOperationException("Not implemented: getPublisherCallable()"); + } + + public UnaryCallable + listPublishersPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listPublishersPagedCallable()"); + } + + public UnaryCallable listPublishersCallable() { + throw new UnsupportedOperationException("Not implemented: listPublishersCallable()"); + } + + public UnaryCallable getAiApplicationCallable() { + throw new UnsupportedOperationException("Not implemented: getAiApplicationCallable()"); + } + + public UnaryCallable + listAiApplicationsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listAiApplicationsPagedCallable()"); + } + + public UnaryCallable + listAiApplicationsCallable() { + throw new UnsupportedOperationException("Not implemented: listAiApplicationsCallable()"); + } + + public UnaryCallable getAiApplicationAgentCallable() { + throw new UnsupportedOperationException("Not implemented: getAiApplicationAgentCallable()"); + } + + public UnaryCallable + listAiApplicationAgentsPagedCallable() { + throw new UnsupportedOperationException( + "Not implemented: listAiApplicationAgentsPagedCallable()"); + } + + public UnaryCallable + listAiApplicationAgentsCallable() { + throw new UnsupportedOperationException("Not implemented: listAiApplicationAgentsCallable()"); + } + + public UnaryCallable + getAiApplicationMcpServerCallable() { + throw new UnsupportedOperationException("Not implemented: getAiApplicationMcpServerCallable()"); + } + + public UnaryCallable + listAiApplicationMcpServersPagedCallable() { + throw new UnsupportedOperationException( + "Not implemented: listAiApplicationMcpServersPagedCallable()"); + } + + public UnaryCallable + listAiApplicationMcpServersCallable() { + throw new UnsupportedOperationException( + "Not implemented: listAiApplicationMcpServersCallable()"); + } + + public UnaryCallable getFindingCallable() { + throw new UnsupportedOperationException("Not implemented: getFindingCallable()"); + } + + public UnaryCallable listFindingsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listFindingsPagedCallable()"); + } + + public UnaryCallable listFindingsCallable() { + throw new UnsupportedOperationException("Not implemented: listFindingsCallable()"); + } + + public UnaryCallable + getAiApplicationEndpointCallable() { + throw new UnsupportedOperationException("Not implemented: getAiApplicationEndpointCallable()"); + } + + public UnaryCallable + listAiApplicationEndpointsPagedCallable() { + throw new UnsupportedOperationException( + "Not implemented: listAiApplicationEndpointsPagedCallable()"); + } + + public UnaryCallable + listAiApplicationEndpointsCallable() { + throw new UnsupportedOperationException( + "Not implemented: listAiApplicationEndpointsCallable()"); + } + + public UnaryCallable + getSkillEncryptionSpecCallable() { + throw new UnsupportedOperationException("Not implemented: getSkillEncryptionSpecCallable()"); + } + + public OperationCallable + updateSkillEncryptionSpecOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: updateSkillEncryptionSpecOperationCallable()"); + } + + public UnaryCallable + updateSkillEncryptionSpecCallable() { + throw new UnsupportedOperationException("Not implemented: updateSkillEncryptionSpecCallable()"); + } + public UnaryCallable listLocationsPagedCallable() { throw new UnsupportedOperationException("Not implemented: listLocationsPagedCallable()"); diff --git a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/AgentRegistryStubSettings.java b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/AgentRegistryStubSettings.java index 19e649fabea4..4f827e4f7670 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/AgentRegistryStubSettings.java +++ b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/AgentRegistryStubSettings.java @@ -18,13 +18,22 @@ import static com.google.cloud.agentregistry.v1.AgentRegistryClient.FetchAvailableBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListFindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListLocationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListPublishersPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListServicesPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillRevisionsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchAgentsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchSkillsPagedResponse; import com.google.api.core.ApiFunction; import com.google.api.core.ApiFuture; @@ -58,38 +67,77 @@ import com.google.api.gax.rpc.UnaryCallSettings; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AiApplication; import com.google.cloud.agentregistry.v1.Binding; import com.google.cloud.agentregistry.v1.CreateBindingRequest; import com.google.cloud.agentregistry.v1.CreateServiceRequest; +import com.google.cloud.agentregistry.v1.CreateSkillRequest; +import com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest; import com.google.cloud.agentregistry.v1.DeleteBindingRequest; import com.google.cloud.agentregistry.v1.DeleteServiceRequest; +import com.google.cloud.agentregistry.v1.DeleteSkillRequest; +import com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest; import com.google.cloud.agentregistry.v1.Endpoint; import com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest; import com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse; +import com.google.cloud.agentregistry.v1.Finding; import com.google.cloud.agentregistry.v1.GetAgentRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationRequest; import com.google.cloud.agentregistry.v1.GetBindingRequest; import com.google.cloud.agentregistry.v1.GetEndpointRequest; +import com.google.cloud.agentregistry.v1.GetFindingRequest; import com.google.cloud.agentregistry.v1.GetMcpServerRequest; +import com.google.cloud.agentregistry.v1.GetPublisherRequest; import com.google.cloud.agentregistry.v1.GetServiceRequest; +import com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest; +import com.google.cloud.agentregistry.v1.GetSkillRequest; +import com.google.cloud.agentregistry.v1.GetSkillRevisionRequest; import com.google.cloud.agentregistry.v1.ListAgentsRequest; import com.google.cloud.agentregistry.v1.ListAgentsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationsResponse; import com.google.cloud.agentregistry.v1.ListBindingsRequest; import com.google.cloud.agentregistry.v1.ListBindingsResponse; import com.google.cloud.agentregistry.v1.ListEndpointsRequest; import com.google.cloud.agentregistry.v1.ListEndpointsResponse; +import com.google.cloud.agentregistry.v1.ListFindingsRequest; +import com.google.cloud.agentregistry.v1.ListFindingsResponse; import com.google.cloud.agentregistry.v1.ListMcpServersRequest; import com.google.cloud.agentregistry.v1.ListMcpServersResponse; +import com.google.cloud.agentregistry.v1.ListPublishersRequest; +import com.google.cloud.agentregistry.v1.ListPublishersResponse; import com.google.cloud.agentregistry.v1.ListServicesRequest; import com.google.cloud.agentregistry.v1.ListServicesResponse; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse; +import com.google.cloud.agentregistry.v1.ListSkillsRequest; +import com.google.cloud.agentregistry.v1.ListSkillsResponse; import com.google.cloud.agentregistry.v1.McpServer; import com.google.cloud.agentregistry.v1.OperationMetadata; +import com.google.cloud.agentregistry.v1.Publisher; import com.google.cloud.agentregistry.v1.SearchAgentsRequest; import com.google.cloud.agentregistry.v1.SearchAgentsResponse; import com.google.cloud.agentregistry.v1.SearchMcpServersRequest; import com.google.cloud.agentregistry.v1.SearchMcpServersResponse; +import com.google.cloud.agentregistry.v1.SearchSkillsRequest; +import com.google.cloud.agentregistry.v1.SearchSkillsResponse; import com.google.cloud.agentregistry.v1.Service; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.cloud.agentregistry.v1.SkillRevision; import com.google.cloud.agentregistry.v1.UpdateBindingRequest; import com.google.cloud.agentregistry.v1.UpdateServiceRequest; +import com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest; +import com.google.cloud.agentregistry.v1.UpdateSkillRequest; import com.google.cloud.location.GetLocationRequest; import com.google.cloud.location.ListLocationsRequest; import com.google.cloud.location.ListLocationsResponse; @@ -244,6 +292,73 @@ public class AgentRegistryStubSettings extends StubSettings fetchAvailableBindingsSettings; + private final UnaryCallSettings createSkillSettings; + private final OperationCallSettings + createSkillOperationSettings; + private final UnaryCallSettings getSkillSettings; + private final UnaryCallSettings updateSkillSettings; + private final OperationCallSettings + updateSkillOperationSettings; + private final UnaryCallSettings deleteSkillSettings; + private final OperationCallSettings + deleteSkillOperationSettings; + private final PagedCallSettings + listSkillsSettings; + private final PagedCallSettings< + SearchSkillsRequest, SearchSkillsResponse, SearchSkillsPagedResponse> + searchSkillsSettings; + private final UnaryCallSettings + createSkillRevisionSettings; + private final OperationCallSettings + createSkillRevisionOperationSettings; + private final UnaryCallSettings getSkillRevisionSettings; + private final UnaryCallSettings + deleteSkillRevisionSettings; + private final OperationCallSettings + deleteSkillRevisionOperationSettings; + private final PagedCallSettings< + ListSkillRevisionsRequest, ListSkillRevisionsResponse, ListSkillRevisionsPagedResponse> + listSkillRevisionsSettings; + private final UnaryCallSettings getPublisherSettings; + private final PagedCallSettings< + ListPublishersRequest, ListPublishersResponse, ListPublishersPagedResponse> + listPublishersSettings; + private final UnaryCallSettings getAiApplicationSettings; + private final PagedCallSettings< + ListAiApplicationsRequest, ListAiApplicationsResponse, ListAiApplicationsPagedResponse> + listAiApplicationsSettings; + private final UnaryCallSettings + getAiApplicationAgentSettings; + private final PagedCallSettings< + ListAiApplicationAgentsRequest, + ListAiApplicationAgentsResponse, + ListAiApplicationAgentsPagedResponse> + listAiApplicationAgentsSettings; + private final UnaryCallSettings + getAiApplicationMcpServerSettings; + private final PagedCallSettings< + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + ListAiApplicationMcpServersPagedResponse> + listAiApplicationMcpServersSettings; + private final UnaryCallSettings getFindingSettings; + private final PagedCallSettings< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse> + listFindingsSettings; + private final UnaryCallSettings + getAiApplicationEndpointSettings; + private final PagedCallSettings< + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + ListAiApplicationEndpointsPagedResponse> + listAiApplicationEndpointsSettings; + private final UnaryCallSettings + getSkillEncryptionSpecSettings; + private final UnaryCallSettings + updateSkillEncryptionSpecSettings; + private final OperationCallSettings< + UpdateSkillEncryptionSpecRequest, SkillEncryptionSpec, OperationMetadata> + updateSkillEncryptionSpecOperationSettings; private final PagedCallSettings< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> listLocationsSettings; @@ -531,6 +646,346 @@ public Iterable extractResources(FetchAvailableBindingsResponse payload } }; + private static final PagedListDescriptor + LIST_SKILLS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListSkillsRequest injectToken(ListSkillsRequest payload, String token) { + return ListSkillsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListSkillsRequest injectPageSize(ListSkillsRequest payload, int pageSize) { + return ListSkillsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListSkillsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListSkillsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListSkillsResponse payload) { + return payload.getSkillsList(); + } + }; + + private static final PagedListDescriptor + SEARCH_SKILLS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public SearchSkillsRequest injectToken(SearchSkillsRequest payload, String token) { + return SearchSkillsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public SearchSkillsRequest injectPageSize(SearchSkillsRequest payload, int pageSize) { + return SearchSkillsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(SearchSkillsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(SearchSkillsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(SearchSkillsResponse payload) { + return payload.getSkillsList(); + } + }; + + private static final PagedListDescriptor< + ListSkillRevisionsRequest, ListSkillRevisionsResponse, SkillRevision> + LIST_SKILL_REVISIONS_PAGE_STR_DESC = + new PagedListDescriptor< + ListSkillRevisionsRequest, ListSkillRevisionsResponse, SkillRevision>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListSkillRevisionsRequest injectToken( + ListSkillRevisionsRequest payload, String token) { + return ListSkillRevisionsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListSkillRevisionsRequest injectPageSize( + ListSkillRevisionsRequest payload, int pageSize) { + return ListSkillRevisionsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListSkillRevisionsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListSkillRevisionsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListSkillRevisionsResponse payload) { + return payload.getSkillRevisionsList(); + } + }; + + private static final PagedListDescriptor + LIST_PUBLISHERS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListPublishersRequest injectToken(ListPublishersRequest payload, String token) { + return ListPublishersRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListPublishersRequest injectPageSize( + ListPublishersRequest payload, int pageSize) { + return ListPublishersRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListPublishersRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListPublishersResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListPublishersResponse payload) { + return payload.getPublishersList(); + } + }; + + private static final PagedListDescriptor< + ListAiApplicationsRequest, ListAiApplicationsResponse, AiApplication> + LIST_AI_APPLICATIONS_PAGE_STR_DESC = + new PagedListDescriptor< + ListAiApplicationsRequest, ListAiApplicationsResponse, AiApplication>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListAiApplicationsRequest injectToken( + ListAiApplicationsRequest payload, String token) { + return ListAiApplicationsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListAiApplicationsRequest injectPageSize( + ListAiApplicationsRequest payload, int pageSize) { + return ListAiApplicationsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListAiApplicationsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListAiApplicationsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListAiApplicationsResponse payload) { + return payload.getAiApplicationsList(); + } + }; + + private static final PagedListDescriptor< + ListAiApplicationAgentsRequest, ListAiApplicationAgentsResponse, Agent> + LIST_AI_APPLICATION_AGENTS_PAGE_STR_DESC = + new PagedListDescriptor< + ListAiApplicationAgentsRequest, ListAiApplicationAgentsResponse, Agent>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListAiApplicationAgentsRequest injectToken( + ListAiApplicationAgentsRequest payload, String token) { + return ListAiApplicationAgentsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListAiApplicationAgentsRequest injectPageSize( + ListAiApplicationAgentsRequest payload, int pageSize) { + return ListAiApplicationAgentsRequest.newBuilder(payload) + .setPageSize(pageSize) + .build(); + } + + @Override + public Integer extractPageSize(ListAiApplicationAgentsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListAiApplicationAgentsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListAiApplicationAgentsResponse payload) { + return payload.getAgentsList(); + } + }; + + private static final PagedListDescriptor< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersResponse, McpServer> + LIST_AI_APPLICATION_MCP_SERVERS_PAGE_STR_DESC = + new PagedListDescriptor< + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + McpServer>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListAiApplicationMcpServersRequest injectToken( + ListAiApplicationMcpServersRequest payload, String token) { + return ListAiApplicationMcpServersRequest.newBuilder(payload) + .setPageToken(token) + .build(); + } + + @Override + public ListAiApplicationMcpServersRequest injectPageSize( + ListAiApplicationMcpServersRequest payload, int pageSize) { + return ListAiApplicationMcpServersRequest.newBuilder(payload) + .setPageSize(pageSize) + .build(); + } + + @Override + public Integer extractPageSize(ListAiApplicationMcpServersRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListAiApplicationMcpServersResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources( + ListAiApplicationMcpServersResponse payload) { + return payload.getMcpServersList(); + } + }; + + private static final PagedListDescriptor + LIST_FINDINGS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListFindingsRequest injectToken(ListFindingsRequest payload, String token) { + return ListFindingsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListFindingsRequest injectPageSize(ListFindingsRequest payload, int pageSize) { + return ListFindingsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListFindingsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListFindingsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListFindingsResponse payload) { + return payload.getFindingsList(); + } + }; + + private static final PagedListDescriptor< + ListAiApplicationEndpointsRequest, ListAiApplicationEndpointsResponse, Endpoint> + LIST_AI_APPLICATION_ENDPOINTS_PAGE_STR_DESC = + new PagedListDescriptor< + ListAiApplicationEndpointsRequest, ListAiApplicationEndpointsResponse, Endpoint>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListAiApplicationEndpointsRequest injectToken( + ListAiApplicationEndpointsRequest payload, String token) { + return ListAiApplicationEndpointsRequest.newBuilder(payload) + .setPageToken(token) + .build(); + } + + @Override + public ListAiApplicationEndpointsRequest injectPageSize( + ListAiApplicationEndpointsRequest payload, int pageSize) { + return ListAiApplicationEndpointsRequest.newBuilder(payload) + .setPageSize(pageSize) + .build(); + } + + @Override + public Integer extractPageSize(ListAiApplicationEndpointsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListAiApplicationEndpointsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListAiApplicationEndpointsResponse payload) { + return payload.getEndpointsList(); + } + }; + private static final PagedListDescriptor LIST_LOCATIONS_PAGE_STR_DESC = new PagedListDescriptor() { @@ -711,32 +1166,226 @@ public ApiFuture getFuturePagedResponse( }; private static final PagedListResponseFactory< - ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> - LIST_LOCATIONS_PAGE_STR_FACT = + ListSkillsRequest, ListSkillsResponse, ListSkillsPagedResponse> + LIST_SKILLS_PAGE_STR_FACT = new PagedListResponseFactory< - ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse>() { + ListSkillsRequest, ListSkillsResponse, ListSkillsPagedResponse>() { @Override - public ApiFuture getFuturePagedResponse( - UnaryCallable callable, - ListLocationsRequest request, + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListSkillsRequest request, ApiCallContext context, - ApiFuture futureResponse) { - PageContext pageContext = - PageContext.create(callable, LIST_LOCATIONS_PAGE_STR_DESC, request, context); - return ListLocationsPagedResponse.createAsync(pageContext, futureResponse); + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_SKILLS_PAGE_STR_DESC, request, context); + return ListSkillsPagedResponse.createAsync(pageContext, futureResponse); } }; - /** Returns the object with the settings used for calls to listAgents. */ - public PagedCallSettings - listAgentsSettings() { - return listAgentsSettings; - } - - /** Returns the object with the settings used for calls to searchAgents. */ - public PagedCallSettings - searchAgentsSettings() { - return searchAgentsSettings; + private static final PagedListResponseFactory< + SearchSkillsRequest, SearchSkillsResponse, SearchSkillsPagedResponse> + SEARCH_SKILLS_PAGE_STR_FACT = + new PagedListResponseFactory< + SearchSkillsRequest, SearchSkillsResponse, SearchSkillsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + SearchSkillsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, SEARCH_SKILLS_PAGE_STR_DESC, request, context); + return SearchSkillsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListSkillRevisionsRequest, ListSkillRevisionsResponse, ListSkillRevisionsPagedResponse> + LIST_SKILL_REVISIONS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListSkillRevisionsRequest, + ListSkillRevisionsResponse, + ListSkillRevisionsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListSkillRevisionsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext + pageContext = + PageContext.create( + callable, LIST_SKILL_REVISIONS_PAGE_STR_DESC, request, context); + return ListSkillRevisionsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListPublishersRequest, ListPublishersResponse, ListPublishersPagedResponse> + LIST_PUBLISHERS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListPublishersRequest, ListPublishersResponse, ListPublishersPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListPublishersRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_PUBLISHERS_PAGE_STR_DESC, request, context); + return ListPublishersPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListAiApplicationsRequest, ListAiApplicationsResponse, ListAiApplicationsPagedResponse> + LIST_AI_APPLICATIONS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListAiApplicationsRequest, + ListAiApplicationsResponse, + ListAiApplicationsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListAiApplicationsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext + pageContext = + PageContext.create( + callable, LIST_AI_APPLICATIONS_PAGE_STR_DESC, request, context); + return ListAiApplicationsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListAiApplicationAgentsRequest, + ListAiApplicationAgentsResponse, + ListAiApplicationAgentsPagedResponse> + LIST_AI_APPLICATION_AGENTS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListAiApplicationAgentsRequest, + ListAiApplicationAgentsResponse, + ListAiApplicationAgentsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable + callable, + ListAiApplicationAgentsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext + pageContext = + PageContext.create( + callable, LIST_AI_APPLICATION_AGENTS_PAGE_STR_DESC, request, context); + return ListAiApplicationAgentsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + ListAiApplicationMcpServersPagedResponse> + LIST_AI_APPLICATION_MCP_SERVERS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + ListAiApplicationMcpServersPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersResponse> + callable, + ListAiApplicationMcpServersRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext< + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + McpServer> + pageContext = + PageContext.create( + callable, + LIST_AI_APPLICATION_MCP_SERVERS_PAGE_STR_DESC, + request, + context); + return ListAiApplicationMcpServersPagedResponse.createAsync( + pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse> + LIST_FINDINGS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListFindingsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_FINDINGS_PAGE_STR_DESC, request, context); + return ListFindingsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + ListAiApplicationEndpointsPagedResponse> + LIST_AI_APPLICATION_ENDPOINTS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + ListAiApplicationEndpointsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable + callable, + ListAiApplicationEndpointsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext< + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + Endpoint> + pageContext = + PageContext.create( + callable, LIST_AI_APPLICATION_ENDPOINTS_PAGE_STR_DESC, request, context); + return ListAiApplicationEndpointsPagedResponse.createAsync( + pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + LIST_LOCATIONS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListLocationsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_LOCATIONS_PAGE_STR_DESC, request, context); + return ListLocationsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + /** Returns the object with the settings used for calls to listAgents. */ + public PagedCallSettings + listAgentsSettings() { + return listAgentsSettings; + } + + /** Returns the object with the settings used for calls to searchAgents. */ + public PagedCallSettings + searchAgentsSettings() { + return searchAgentsSettings; } /** Returns the object with the settings used for calls to getAgent. */ @@ -871,6 +1520,188 @@ public UnaryCallSettings deleteBindingSettings( return fetchAvailableBindingsSettings; } + /** Returns the object with the settings used for calls to createSkill. */ + public UnaryCallSettings createSkillSettings() { + return createSkillSettings; + } + + /** Returns the object with the settings used for calls to createSkill. */ + public OperationCallSettings + createSkillOperationSettings() { + return createSkillOperationSettings; + } + + /** Returns the object with the settings used for calls to getSkill. */ + public UnaryCallSettings getSkillSettings() { + return getSkillSettings; + } + + /** Returns the object with the settings used for calls to updateSkill. */ + public UnaryCallSettings updateSkillSettings() { + return updateSkillSettings; + } + + /** Returns the object with the settings used for calls to updateSkill. */ + public OperationCallSettings + updateSkillOperationSettings() { + return updateSkillOperationSettings; + } + + /** Returns the object with the settings used for calls to deleteSkill. */ + public UnaryCallSettings deleteSkillSettings() { + return deleteSkillSettings; + } + + /** Returns the object with the settings used for calls to deleteSkill. */ + public OperationCallSettings + deleteSkillOperationSettings() { + return deleteSkillOperationSettings; + } + + /** Returns the object with the settings used for calls to listSkills. */ + public PagedCallSettings + listSkillsSettings() { + return listSkillsSettings; + } + + /** Returns the object with the settings used for calls to searchSkills. */ + public PagedCallSettings + searchSkillsSettings() { + return searchSkillsSettings; + } + + /** Returns the object with the settings used for calls to createSkillRevision. */ + public UnaryCallSettings createSkillRevisionSettings() { + return createSkillRevisionSettings; + } + + /** Returns the object with the settings used for calls to createSkillRevision. */ + public OperationCallSettings + createSkillRevisionOperationSettings() { + return createSkillRevisionOperationSettings; + } + + /** Returns the object with the settings used for calls to getSkillRevision. */ + public UnaryCallSettings getSkillRevisionSettings() { + return getSkillRevisionSettings; + } + + /** Returns the object with the settings used for calls to deleteSkillRevision. */ + public UnaryCallSettings deleteSkillRevisionSettings() { + return deleteSkillRevisionSettings; + } + + /** Returns the object with the settings used for calls to deleteSkillRevision. */ + public OperationCallSettings + deleteSkillRevisionOperationSettings() { + return deleteSkillRevisionOperationSettings; + } + + /** Returns the object with the settings used for calls to listSkillRevisions. */ + public PagedCallSettings< + ListSkillRevisionsRequest, ListSkillRevisionsResponse, ListSkillRevisionsPagedResponse> + listSkillRevisionsSettings() { + return listSkillRevisionsSettings; + } + + /** Returns the object with the settings used for calls to getPublisher. */ + public UnaryCallSettings getPublisherSettings() { + return getPublisherSettings; + } + + /** Returns the object with the settings used for calls to listPublishers. */ + public PagedCallSettings< + ListPublishersRequest, ListPublishersResponse, ListPublishersPagedResponse> + listPublishersSettings() { + return listPublishersSettings; + } + + /** Returns the object with the settings used for calls to getAiApplication. */ + public UnaryCallSettings getAiApplicationSettings() { + return getAiApplicationSettings; + } + + /** Returns the object with the settings used for calls to listAiApplications. */ + public PagedCallSettings< + ListAiApplicationsRequest, ListAiApplicationsResponse, ListAiApplicationsPagedResponse> + listAiApplicationsSettings() { + return listAiApplicationsSettings; + } + + /** Returns the object with the settings used for calls to getAiApplicationAgent. */ + public UnaryCallSettings getAiApplicationAgentSettings() { + return getAiApplicationAgentSettings; + } + + /** Returns the object with the settings used for calls to listAiApplicationAgents. */ + public PagedCallSettings< + ListAiApplicationAgentsRequest, + ListAiApplicationAgentsResponse, + ListAiApplicationAgentsPagedResponse> + listAiApplicationAgentsSettings() { + return listAiApplicationAgentsSettings; + } + + /** Returns the object with the settings used for calls to getAiApplicationMcpServer. */ + public UnaryCallSettings + getAiApplicationMcpServerSettings() { + return getAiApplicationMcpServerSettings; + } + + /** Returns the object with the settings used for calls to listAiApplicationMcpServers. */ + public PagedCallSettings< + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + ListAiApplicationMcpServersPagedResponse> + listAiApplicationMcpServersSettings() { + return listAiApplicationMcpServersSettings; + } + + /** Returns the object with the settings used for calls to getFinding. */ + public UnaryCallSettings getFindingSettings() { + return getFindingSettings; + } + + /** Returns the object with the settings used for calls to listFindings. */ + public PagedCallSettings + listFindingsSettings() { + return listFindingsSettings; + } + + /** Returns the object with the settings used for calls to getAiApplicationEndpoint. */ + public UnaryCallSettings + getAiApplicationEndpointSettings() { + return getAiApplicationEndpointSettings; + } + + /** Returns the object with the settings used for calls to listAiApplicationEndpoints. */ + public PagedCallSettings< + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + ListAiApplicationEndpointsPagedResponse> + listAiApplicationEndpointsSettings() { + return listAiApplicationEndpointsSettings; + } + + /** Returns the object with the settings used for calls to getSkillEncryptionSpec. */ + public UnaryCallSettings + getSkillEncryptionSpecSettings() { + return getSkillEncryptionSpecSettings; + } + + /** Returns the object with the settings used for calls to updateSkillEncryptionSpec. */ + public UnaryCallSettings + updateSkillEncryptionSpecSettings() { + return updateSkillEncryptionSpecSettings; + } + + /** Returns the object with the settings used for calls to updateSkillEncryptionSpec. */ + public OperationCallSettings< + UpdateSkillEncryptionSpecRequest, SkillEncryptionSpec, OperationMetadata> + updateSkillEncryptionSpecOperationSettings() { + return updateSkillEncryptionSpecOperationSettings; + } + /** Returns the object with the settings used for calls to listLocations. */ public PagedCallSettings listLocationsSettings() { @@ -1018,6 +1849,41 @@ protected AgentRegistryStubSettings(Builder settingsBuilder) throws IOException deleteBindingSettings = settingsBuilder.deleteBindingSettings().build(); deleteBindingOperationSettings = settingsBuilder.deleteBindingOperationSettings().build(); fetchAvailableBindingsSettings = settingsBuilder.fetchAvailableBindingsSettings().build(); + createSkillSettings = settingsBuilder.createSkillSettings().build(); + createSkillOperationSettings = settingsBuilder.createSkillOperationSettings().build(); + getSkillSettings = settingsBuilder.getSkillSettings().build(); + updateSkillSettings = settingsBuilder.updateSkillSettings().build(); + updateSkillOperationSettings = settingsBuilder.updateSkillOperationSettings().build(); + deleteSkillSettings = settingsBuilder.deleteSkillSettings().build(); + deleteSkillOperationSettings = settingsBuilder.deleteSkillOperationSettings().build(); + listSkillsSettings = settingsBuilder.listSkillsSettings().build(); + searchSkillsSettings = settingsBuilder.searchSkillsSettings().build(); + createSkillRevisionSettings = settingsBuilder.createSkillRevisionSettings().build(); + createSkillRevisionOperationSettings = + settingsBuilder.createSkillRevisionOperationSettings().build(); + getSkillRevisionSettings = settingsBuilder.getSkillRevisionSettings().build(); + deleteSkillRevisionSettings = settingsBuilder.deleteSkillRevisionSettings().build(); + deleteSkillRevisionOperationSettings = + settingsBuilder.deleteSkillRevisionOperationSettings().build(); + listSkillRevisionsSettings = settingsBuilder.listSkillRevisionsSettings().build(); + getPublisherSettings = settingsBuilder.getPublisherSettings().build(); + listPublishersSettings = settingsBuilder.listPublishersSettings().build(); + getAiApplicationSettings = settingsBuilder.getAiApplicationSettings().build(); + listAiApplicationsSettings = settingsBuilder.listAiApplicationsSettings().build(); + getAiApplicationAgentSettings = settingsBuilder.getAiApplicationAgentSettings().build(); + listAiApplicationAgentsSettings = settingsBuilder.listAiApplicationAgentsSettings().build(); + getAiApplicationMcpServerSettings = settingsBuilder.getAiApplicationMcpServerSettings().build(); + listAiApplicationMcpServersSettings = + settingsBuilder.listAiApplicationMcpServersSettings().build(); + getFindingSettings = settingsBuilder.getFindingSettings().build(); + listFindingsSettings = settingsBuilder.listFindingsSettings().build(); + getAiApplicationEndpointSettings = settingsBuilder.getAiApplicationEndpointSettings().build(); + listAiApplicationEndpointsSettings = + settingsBuilder.listAiApplicationEndpointsSettings().build(); + getSkillEncryptionSpecSettings = settingsBuilder.getSkillEncryptionSpecSettings().build(); + updateSkillEncryptionSpecSettings = settingsBuilder.updateSkillEncryptionSpecSettings().build(); + updateSkillEncryptionSpecOperationSettings = + settingsBuilder.updateSkillEncryptionSpecOperationSettings().build(); listLocationsSettings = settingsBuilder.listLocationsSettings().build(); getLocationSettings = settingsBuilder.getLocationSettings().build(); } @@ -1083,6 +1949,78 @@ public static class Builder extends StubSettings.Builder fetchAvailableBindingsSettings; + private final UnaryCallSettings.Builder createSkillSettings; + private final OperationCallSettings.Builder + createSkillOperationSettings; + private final UnaryCallSettings.Builder getSkillSettings; + private final UnaryCallSettings.Builder updateSkillSettings; + private final OperationCallSettings.Builder + updateSkillOperationSettings; + private final UnaryCallSettings.Builder deleteSkillSettings; + private final OperationCallSettings.Builder + deleteSkillOperationSettings; + private final PagedCallSettings.Builder< + ListSkillsRequest, ListSkillsResponse, ListSkillsPagedResponse> + listSkillsSettings; + private final PagedCallSettings.Builder< + SearchSkillsRequest, SearchSkillsResponse, SearchSkillsPagedResponse> + searchSkillsSettings; + private final UnaryCallSettings.Builder + createSkillRevisionSettings; + private final OperationCallSettings.Builder< + CreateSkillRevisionRequest, SkillRevision, OperationMetadata> + createSkillRevisionOperationSettings; + private final UnaryCallSettings.Builder + getSkillRevisionSettings; + private final UnaryCallSettings.Builder + deleteSkillRevisionSettings; + private final OperationCallSettings.Builder< + DeleteSkillRevisionRequest, Empty, OperationMetadata> + deleteSkillRevisionOperationSettings; + private final PagedCallSettings.Builder< + ListSkillRevisionsRequest, ListSkillRevisionsResponse, ListSkillRevisionsPagedResponse> + listSkillRevisionsSettings; + private final UnaryCallSettings.Builder getPublisherSettings; + private final PagedCallSettings.Builder< + ListPublishersRequest, ListPublishersResponse, ListPublishersPagedResponse> + listPublishersSettings; + private final UnaryCallSettings.Builder + getAiApplicationSettings; + private final PagedCallSettings.Builder< + ListAiApplicationsRequest, ListAiApplicationsResponse, ListAiApplicationsPagedResponse> + listAiApplicationsSettings; + private final UnaryCallSettings.Builder + getAiApplicationAgentSettings; + private final PagedCallSettings.Builder< + ListAiApplicationAgentsRequest, + ListAiApplicationAgentsResponse, + ListAiApplicationAgentsPagedResponse> + listAiApplicationAgentsSettings; + private final UnaryCallSettings.Builder + getAiApplicationMcpServerSettings; + private final PagedCallSettings.Builder< + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + ListAiApplicationMcpServersPagedResponse> + listAiApplicationMcpServersSettings; + private final UnaryCallSettings.Builder getFindingSettings; + private final PagedCallSettings.Builder< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse> + listFindingsSettings; + private final UnaryCallSettings.Builder + getAiApplicationEndpointSettings; + private final PagedCallSettings.Builder< + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + ListAiApplicationEndpointsPagedResponse> + listAiApplicationEndpointsSettings; + private final UnaryCallSettings.Builder + getSkillEncryptionSpecSettings; + private final UnaryCallSettings.Builder + updateSkillEncryptionSpecSettings; + private final OperationCallSettings.Builder< + UpdateSkillEncryptionSpecRequest, SkillEncryptionSpec, OperationMetadata> + updateSkillEncryptionSpecOperationSettings; private final PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> listLocationsSettings; @@ -1164,6 +2102,39 @@ protected Builder(@Nullable ClientContext clientContext) { deleteBindingOperationSettings = OperationCallSettings.newBuilder(); fetchAvailableBindingsSettings = PagedCallSettings.newBuilder(FETCH_AVAILABLE_BINDINGS_PAGE_STR_FACT); + createSkillSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createSkillOperationSettings = OperationCallSettings.newBuilder(); + getSkillSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateSkillSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateSkillOperationSettings = OperationCallSettings.newBuilder(); + deleteSkillSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteSkillOperationSettings = OperationCallSettings.newBuilder(); + listSkillsSettings = PagedCallSettings.newBuilder(LIST_SKILLS_PAGE_STR_FACT); + searchSkillsSettings = PagedCallSettings.newBuilder(SEARCH_SKILLS_PAGE_STR_FACT); + createSkillRevisionSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createSkillRevisionOperationSettings = OperationCallSettings.newBuilder(); + getSkillRevisionSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteSkillRevisionSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteSkillRevisionOperationSettings = OperationCallSettings.newBuilder(); + listSkillRevisionsSettings = PagedCallSettings.newBuilder(LIST_SKILL_REVISIONS_PAGE_STR_FACT); + getPublisherSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listPublishersSettings = PagedCallSettings.newBuilder(LIST_PUBLISHERS_PAGE_STR_FACT); + getAiApplicationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listAiApplicationsSettings = PagedCallSettings.newBuilder(LIST_AI_APPLICATIONS_PAGE_STR_FACT); + getAiApplicationAgentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listAiApplicationAgentsSettings = + PagedCallSettings.newBuilder(LIST_AI_APPLICATION_AGENTS_PAGE_STR_FACT); + getAiApplicationMcpServerSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listAiApplicationMcpServersSettings = + PagedCallSettings.newBuilder(LIST_AI_APPLICATION_MCP_SERVERS_PAGE_STR_FACT); + getFindingSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listFindingsSettings = PagedCallSettings.newBuilder(LIST_FINDINGS_PAGE_STR_FACT); + getAiApplicationEndpointSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listAiApplicationEndpointsSettings = + PagedCallSettings.newBuilder(LIST_AI_APPLICATION_ENDPOINTS_PAGE_STR_FACT); + getSkillEncryptionSpecSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateSkillEncryptionSpecSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateSkillEncryptionSpecOperationSettings = OperationCallSettings.newBuilder(); listLocationsSettings = PagedCallSettings.newBuilder(LIST_LOCATIONS_PAGE_STR_FACT); getLocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -1188,6 +2159,30 @@ protected Builder(@Nullable ClientContext clientContext) { updateBindingSettings, deleteBindingSettings, fetchAvailableBindingsSettings, + createSkillSettings, + getSkillSettings, + updateSkillSettings, + deleteSkillSettings, + listSkillsSettings, + searchSkillsSettings, + createSkillRevisionSettings, + getSkillRevisionSettings, + deleteSkillRevisionSettings, + listSkillRevisionsSettings, + getPublisherSettings, + listPublishersSettings, + getAiApplicationSettings, + listAiApplicationsSettings, + getAiApplicationAgentSettings, + listAiApplicationAgentsSettings, + getAiApplicationMcpServerSettings, + listAiApplicationMcpServersSettings, + getFindingSettings, + listFindingsSettings, + getAiApplicationEndpointSettings, + listAiApplicationEndpointsSettings, + getSkillEncryptionSpecSettings, + updateSkillEncryptionSpecSettings, listLocationsSettings, getLocationSettings); initDefaults(this); @@ -1221,6 +2216,40 @@ protected Builder(AgentRegistryStubSettings settings) { deleteBindingSettings = settings.deleteBindingSettings.toBuilder(); deleteBindingOperationSettings = settings.deleteBindingOperationSettings.toBuilder(); fetchAvailableBindingsSettings = settings.fetchAvailableBindingsSettings.toBuilder(); + createSkillSettings = settings.createSkillSettings.toBuilder(); + createSkillOperationSettings = settings.createSkillOperationSettings.toBuilder(); + getSkillSettings = settings.getSkillSettings.toBuilder(); + updateSkillSettings = settings.updateSkillSettings.toBuilder(); + updateSkillOperationSettings = settings.updateSkillOperationSettings.toBuilder(); + deleteSkillSettings = settings.deleteSkillSettings.toBuilder(); + deleteSkillOperationSettings = settings.deleteSkillOperationSettings.toBuilder(); + listSkillsSettings = settings.listSkillsSettings.toBuilder(); + searchSkillsSettings = settings.searchSkillsSettings.toBuilder(); + createSkillRevisionSettings = settings.createSkillRevisionSettings.toBuilder(); + createSkillRevisionOperationSettings = + settings.createSkillRevisionOperationSettings.toBuilder(); + getSkillRevisionSettings = settings.getSkillRevisionSettings.toBuilder(); + deleteSkillRevisionSettings = settings.deleteSkillRevisionSettings.toBuilder(); + deleteSkillRevisionOperationSettings = + settings.deleteSkillRevisionOperationSettings.toBuilder(); + listSkillRevisionsSettings = settings.listSkillRevisionsSettings.toBuilder(); + getPublisherSettings = settings.getPublisherSettings.toBuilder(); + listPublishersSettings = settings.listPublishersSettings.toBuilder(); + getAiApplicationSettings = settings.getAiApplicationSettings.toBuilder(); + listAiApplicationsSettings = settings.listAiApplicationsSettings.toBuilder(); + getAiApplicationAgentSettings = settings.getAiApplicationAgentSettings.toBuilder(); + listAiApplicationAgentsSettings = settings.listAiApplicationAgentsSettings.toBuilder(); + getAiApplicationMcpServerSettings = settings.getAiApplicationMcpServerSettings.toBuilder(); + listAiApplicationMcpServersSettings = + settings.listAiApplicationMcpServersSettings.toBuilder(); + getFindingSettings = settings.getFindingSettings.toBuilder(); + listFindingsSettings = settings.listFindingsSettings.toBuilder(); + getAiApplicationEndpointSettings = settings.getAiApplicationEndpointSettings.toBuilder(); + listAiApplicationEndpointsSettings = settings.listAiApplicationEndpointsSettings.toBuilder(); + getSkillEncryptionSpecSettings = settings.getSkillEncryptionSpecSettings.toBuilder(); + updateSkillEncryptionSpecSettings = settings.updateSkillEncryptionSpecSettings.toBuilder(); + updateSkillEncryptionSpecOperationSettings = + settings.updateSkillEncryptionSpecOperationSettings.toBuilder(); listLocationsSettings = settings.listLocationsSettings.toBuilder(); getLocationSettings = settings.getLocationSettings.toBuilder(); @@ -1245,6 +2274,30 @@ protected Builder(AgentRegistryStubSettings settings) { updateBindingSettings, deleteBindingSettings, fetchAvailableBindingsSettings, + createSkillSettings, + getSkillSettings, + updateSkillSettings, + deleteSkillSettings, + listSkillsSettings, + searchSkillsSettings, + createSkillRevisionSettings, + getSkillRevisionSettings, + deleteSkillRevisionSettings, + listSkillRevisionsSettings, + getPublisherSettings, + listPublishersSettings, + getAiApplicationSettings, + listAiApplicationsSettings, + getAiApplicationAgentSettings, + listAiApplicationAgentsSettings, + getAiApplicationMcpServerSettings, + listAiApplicationMcpServersSettings, + getFindingSettings, + listFindingsSettings, + getAiApplicationEndpointSettings, + listAiApplicationEndpointsSettings, + getSkillEncryptionSpecSettings, + updateSkillEncryptionSpecSettings, listLocationsSettings, getLocationSettings); } @@ -1369,6 +2422,126 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + builder + .createSkillSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + + builder + .getSkillSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .updateSkillSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + + builder + .deleteSkillSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + + builder + .listSkillsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .searchSkillsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .createSkillRevisionSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + + builder + .getSkillRevisionSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .deleteSkillRevisionSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + + builder + .listSkillRevisionsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .getPublisherSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .listPublishersSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .getAiApplicationSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .listAiApplicationsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .getAiApplicationAgentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .listAiApplicationAgentsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .getAiApplicationMcpServerSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .listAiApplicationMcpServersSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .getFindingSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .listFindingsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .getAiApplicationEndpointSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .listAiApplicationEndpointsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .getSkillEncryptionSpecSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .updateSkillEncryptionSpecSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + builder .listLocationsSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) @@ -1523,6 +2696,148 @@ private static Builder initDefaults(Builder builder) { .setTotalTimeoutDuration(Duration.ofMillis(300000L)) .build())); + builder + .createSkillOperationSettings() + .setInitialCallSettings( + UnaryCallSettings.newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Skill.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .updateSkillOperationSettings() + .setInitialCallSettings( + UnaryCallSettings.newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Skill.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .deleteSkillOperationSettings() + .setInitialCallSettings( + UnaryCallSettings.newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Empty.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .createSkillRevisionOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(SkillRevision.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .deleteSkillRevisionOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Empty.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .updateSkillEncryptionSpecOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + . + newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(SkillEncryptionSpec.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + return builder; } @@ -1689,6 +3004,196 @@ public UnaryCallSettings.Builder deleteBindingS return fetchAvailableBindingsSettings; } + /** Returns the builder for the settings used for calls to createSkill. */ + public UnaryCallSettings.Builder createSkillSettings() { + return createSkillSettings; + } + + /** Returns the builder for the settings used for calls to createSkill. */ + public OperationCallSettings.Builder + createSkillOperationSettings() { + return createSkillOperationSettings; + } + + /** Returns the builder for the settings used for calls to getSkill. */ + public UnaryCallSettings.Builder getSkillSettings() { + return getSkillSettings; + } + + /** Returns the builder for the settings used for calls to updateSkill. */ + public UnaryCallSettings.Builder updateSkillSettings() { + return updateSkillSettings; + } + + /** Returns the builder for the settings used for calls to updateSkill. */ + public OperationCallSettings.Builder + updateSkillOperationSettings() { + return updateSkillOperationSettings; + } + + /** Returns the builder for the settings used for calls to deleteSkill. */ + public UnaryCallSettings.Builder deleteSkillSettings() { + return deleteSkillSettings; + } + + /** Returns the builder for the settings used for calls to deleteSkill. */ + public OperationCallSettings.Builder + deleteSkillOperationSettings() { + return deleteSkillOperationSettings; + } + + /** Returns the builder for the settings used for calls to listSkills. */ + public PagedCallSettings.Builder + listSkillsSettings() { + return listSkillsSettings; + } + + /** Returns the builder for the settings used for calls to searchSkills. */ + public PagedCallSettings.Builder< + SearchSkillsRequest, SearchSkillsResponse, SearchSkillsPagedResponse> + searchSkillsSettings() { + return searchSkillsSettings; + } + + /** Returns the builder for the settings used for calls to createSkillRevision. */ + public UnaryCallSettings.Builder + createSkillRevisionSettings() { + return createSkillRevisionSettings; + } + + /** Returns the builder for the settings used for calls to createSkillRevision. */ + public OperationCallSettings.Builder< + CreateSkillRevisionRequest, SkillRevision, OperationMetadata> + createSkillRevisionOperationSettings() { + return createSkillRevisionOperationSettings; + } + + /** Returns the builder for the settings used for calls to getSkillRevision. */ + public UnaryCallSettings.Builder + getSkillRevisionSettings() { + return getSkillRevisionSettings; + } + + /** Returns the builder for the settings used for calls to deleteSkillRevision. */ + public UnaryCallSettings.Builder + deleteSkillRevisionSettings() { + return deleteSkillRevisionSettings; + } + + /** Returns the builder for the settings used for calls to deleteSkillRevision. */ + public OperationCallSettings.Builder + deleteSkillRevisionOperationSettings() { + return deleteSkillRevisionOperationSettings; + } + + /** Returns the builder for the settings used for calls to listSkillRevisions. */ + public PagedCallSettings.Builder< + ListSkillRevisionsRequest, ListSkillRevisionsResponse, ListSkillRevisionsPagedResponse> + listSkillRevisionsSettings() { + return listSkillRevisionsSettings; + } + + /** Returns the builder for the settings used for calls to getPublisher. */ + public UnaryCallSettings.Builder getPublisherSettings() { + return getPublisherSettings; + } + + /** Returns the builder for the settings used for calls to listPublishers. */ + public PagedCallSettings.Builder< + ListPublishersRequest, ListPublishersResponse, ListPublishersPagedResponse> + listPublishersSettings() { + return listPublishersSettings; + } + + /** Returns the builder for the settings used for calls to getAiApplication. */ + public UnaryCallSettings.Builder + getAiApplicationSettings() { + return getAiApplicationSettings; + } + + /** Returns the builder for the settings used for calls to listAiApplications. */ + public PagedCallSettings.Builder< + ListAiApplicationsRequest, ListAiApplicationsResponse, ListAiApplicationsPagedResponse> + listAiApplicationsSettings() { + return listAiApplicationsSettings; + } + + /** Returns the builder for the settings used for calls to getAiApplicationAgent. */ + public UnaryCallSettings.Builder + getAiApplicationAgentSettings() { + return getAiApplicationAgentSettings; + } + + /** Returns the builder for the settings used for calls to listAiApplicationAgents. */ + public PagedCallSettings.Builder< + ListAiApplicationAgentsRequest, + ListAiApplicationAgentsResponse, + ListAiApplicationAgentsPagedResponse> + listAiApplicationAgentsSettings() { + return listAiApplicationAgentsSettings; + } + + /** Returns the builder for the settings used for calls to getAiApplicationMcpServer. */ + public UnaryCallSettings.Builder + getAiApplicationMcpServerSettings() { + return getAiApplicationMcpServerSettings; + } + + /** Returns the builder for the settings used for calls to listAiApplicationMcpServers. */ + public PagedCallSettings.Builder< + ListAiApplicationMcpServersRequest, + ListAiApplicationMcpServersResponse, + ListAiApplicationMcpServersPagedResponse> + listAiApplicationMcpServersSettings() { + return listAiApplicationMcpServersSettings; + } + + /** Returns the builder for the settings used for calls to getFinding. */ + public UnaryCallSettings.Builder getFindingSettings() { + return getFindingSettings; + } + + /** Returns the builder for the settings used for calls to listFindings. */ + public PagedCallSettings.Builder< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse> + listFindingsSettings() { + return listFindingsSettings; + } + + /** Returns the builder for the settings used for calls to getAiApplicationEndpoint. */ + public UnaryCallSettings.Builder + getAiApplicationEndpointSettings() { + return getAiApplicationEndpointSettings; + } + + /** Returns the builder for the settings used for calls to listAiApplicationEndpoints. */ + public PagedCallSettings.Builder< + ListAiApplicationEndpointsRequest, + ListAiApplicationEndpointsResponse, + ListAiApplicationEndpointsPagedResponse> + listAiApplicationEndpointsSettings() { + return listAiApplicationEndpointsSettings; + } + + /** Returns the builder for the settings used for calls to getSkillEncryptionSpec. */ + public UnaryCallSettings.Builder + getSkillEncryptionSpecSettings() { + return getSkillEncryptionSpecSettings; + } + + /** Returns the builder for the settings used for calls to updateSkillEncryptionSpec. */ + public UnaryCallSettings.Builder + updateSkillEncryptionSpecSettings() { + return updateSkillEncryptionSpecSettings; + } + + /** Returns the builder for the settings used for calls to updateSkillEncryptionSpec. */ + public OperationCallSettings.Builder< + UpdateSkillEncryptionSpecRequest, SkillEncryptionSpec, OperationMetadata> + updateSkillEncryptionSpecOperationSettings() { + return updateSkillEncryptionSpecOperationSettings; + } + /** Returns the builder for the settings used for calls to listLocations. */ public PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> diff --git a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/GrpcAgentRegistryStub.java b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/GrpcAgentRegistryStub.java index 3de96dc1b9b5..3098760c43e4 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/GrpcAgentRegistryStub.java +++ b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/GrpcAgentRegistryStub.java @@ -18,13 +18,22 @@ import static com.google.cloud.agentregistry.v1.AgentRegistryClient.FetchAvailableBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListFindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListLocationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListPublishersPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListServicesPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillRevisionsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchAgentsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchSkillsPagedResponse; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; @@ -35,38 +44,77 @@ import com.google.api.gax.rpc.RequestParamsBuilder; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AiApplication; import com.google.cloud.agentregistry.v1.Binding; import com.google.cloud.agentregistry.v1.CreateBindingRequest; import com.google.cloud.agentregistry.v1.CreateServiceRequest; +import com.google.cloud.agentregistry.v1.CreateSkillRequest; +import com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest; import com.google.cloud.agentregistry.v1.DeleteBindingRequest; import com.google.cloud.agentregistry.v1.DeleteServiceRequest; +import com.google.cloud.agentregistry.v1.DeleteSkillRequest; +import com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest; import com.google.cloud.agentregistry.v1.Endpoint; import com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest; import com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse; +import com.google.cloud.agentregistry.v1.Finding; import com.google.cloud.agentregistry.v1.GetAgentRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationRequest; import com.google.cloud.agentregistry.v1.GetBindingRequest; import com.google.cloud.agentregistry.v1.GetEndpointRequest; +import com.google.cloud.agentregistry.v1.GetFindingRequest; import com.google.cloud.agentregistry.v1.GetMcpServerRequest; +import com.google.cloud.agentregistry.v1.GetPublisherRequest; import com.google.cloud.agentregistry.v1.GetServiceRequest; +import com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest; +import com.google.cloud.agentregistry.v1.GetSkillRequest; +import com.google.cloud.agentregistry.v1.GetSkillRevisionRequest; import com.google.cloud.agentregistry.v1.ListAgentsRequest; import com.google.cloud.agentregistry.v1.ListAgentsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationsResponse; import com.google.cloud.agentregistry.v1.ListBindingsRequest; import com.google.cloud.agentregistry.v1.ListBindingsResponse; import com.google.cloud.agentregistry.v1.ListEndpointsRequest; import com.google.cloud.agentregistry.v1.ListEndpointsResponse; +import com.google.cloud.agentregistry.v1.ListFindingsRequest; +import com.google.cloud.agentregistry.v1.ListFindingsResponse; import com.google.cloud.agentregistry.v1.ListMcpServersRequest; import com.google.cloud.agentregistry.v1.ListMcpServersResponse; +import com.google.cloud.agentregistry.v1.ListPublishersRequest; +import com.google.cloud.agentregistry.v1.ListPublishersResponse; import com.google.cloud.agentregistry.v1.ListServicesRequest; import com.google.cloud.agentregistry.v1.ListServicesResponse; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse; +import com.google.cloud.agentregistry.v1.ListSkillsRequest; +import com.google.cloud.agentregistry.v1.ListSkillsResponse; import com.google.cloud.agentregistry.v1.McpServer; import com.google.cloud.agentregistry.v1.OperationMetadata; +import com.google.cloud.agentregistry.v1.Publisher; import com.google.cloud.agentregistry.v1.SearchAgentsRequest; import com.google.cloud.agentregistry.v1.SearchAgentsResponse; import com.google.cloud.agentregistry.v1.SearchMcpServersRequest; import com.google.cloud.agentregistry.v1.SearchMcpServersResponse; +import com.google.cloud.agentregistry.v1.SearchSkillsRequest; +import com.google.cloud.agentregistry.v1.SearchSkillsResponse; import com.google.cloud.agentregistry.v1.Service; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.cloud.agentregistry.v1.SkillRevision; import com.google.cloud.agentregistry.v1.UpdateBindingRequest; import com.google.cloud.agentregistry.v1.UpdateServiceRequest; +import com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest; +import com.google.cloud.agentregistry.v1.UpdateSkillRequest; import com.google.cloud.location.GetLocationRequest; import com.google.cloud.location.ListLocationsRequest; import com.google.cloud.location.ListLocationsResponse; @@ -296,6 +344,279 @@ public class GrpcAgentRegistryStub extends AgentRegistryStub { .setSampledToLocalTracing(true) .build(); + private static final MethodDescriptor createSkillMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/CreateSkill") + .setRequestMarshaller(ProtoUtils.marshaller(CreateSkillRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor getSkillMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/GetSkill") + .setRequestMarshaller(ProtoUtils.marshaller(GetSkillRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Skill.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor updateSkillMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/UpdateSkill") + .setRequestMarshaller(ProtoUtils.marshaller(UpdateSkillRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor deleteSkillMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/DeleteSkill") + .setRequestMarshaller(ProtoUtils.marshaller(DeleteSkillRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + listSkillsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/ListSkills") + .setRequestMarshaller(ProtoUtils.marshaller(ListSkillsRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(ListSkillsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + searchSkillsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/SearchSkills") + .setRequestMarshaller(ProtoUtils.marshaller(SearchSkillsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(SearchSkillsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + createSkillRevisionMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/CreateSkillRevision") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateSkillRevisionRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getSkillRevisionMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/GetSkillRevision") + .setRequestMarshaller( + ProtoUtils.marshaller(GetSkillRevisionRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(SkillRevision.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + deleteSkillRevisionMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/DeleteSkillRevision") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteSkillRevisionRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + listSkillRevisionsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/ListSkillRevisions") + .setRequestMarshaller( + ProtoUtils.marshaller(ListSkillRevisionsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListSkillRevisionsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getPublisherMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/GetPublisher") + .setRequestMarshaller(ProtoUtils.marshaller(GetPublisherRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Publisher.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + listPublishersMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/ListPublishers") + .setRequestMarshaller( + ProtoUtils.marshaller(ListPublishersRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListPublishersResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getAiApplicationMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/GetAiApplication") + .setRequestMarshaller( + ProtoUtils.marshaller(GetAiApplicationRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(AiApplication.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + listAiApplicationsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/ListAiApplications") + .setRequestMarshaller( + ProtoUtils.marshaller(ListAiApplicationsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListAiApplicationsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getAiApplicationAgentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/GetAiApplicationAgent") + .setRequestMarshaller( + ProtoUtils.marshaller(GetAiApplicationAgentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Agent.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor< + ListAiApplicationAgentsRequest, ListAiApplicationAgentsResponse> + listAiApplicationAgentsMethodDescriptor = + MethodDescriptor + .newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/ListAiApplicationAgents") + .setRequestMarshaller( + ProtoUtils.marshaller(ListAiApplicationAgentsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListAiApplicationAgentsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getAiApplicationMcpServerMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/GetAiApplicationMcpServer") + .setRequestMarshaller( + ProtoUtils.marshaller(GetAiApplicationMcpServerRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(McpServer.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersResponse> + listAiApplicationMcpServersMethodDescriptor = + MethodDescriptor + .newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/ListAiApplicationMcpServers") + .setRequestMarshaller( + ProtoUtils.marshaller(ListAiApplicationMcpServersRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListAiApplicationMcpServersResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor getFindingMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/GetFinding") + .setRequestMarshaller(ProtoUtils.marshaller(GetFindingRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Finding.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + listFindingsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/ListFindings") + .setRequestMarshaller(ProtoUtils.marshaller(ListFindingsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListFindingsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getAiApplicationEndpointMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/GetAiApplicationEndpoint") + .setRequestMarshaller( + ProtoUtils.marshaller(GetAiApplicationEndpointRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Endpoint.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor< + ListAiApplicationEndpointsRequest, ListAiApplicationEndpointsResponse> + listAiApplicationEndpointsMethodDescriptor = + MethodDescriptor + .newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/ListAiApplicationEndpoints") + .setRequestMarshaller( + ProtoUtils.marshaller(ListAiApplicationEndpointsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListAiApplicationEndpointsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getSkillEncryptionSpecMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/GetSkillEncryptionSpec") + .setRequestMarshaller( + ProtoUtils.marshaller(GetSkillEncryptionSpecRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(SkillEncryptionSpec.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + updateSkillEncryptionSpecMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/UpdateSkillEncryptionSpec") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateSkillEncryptionSpecRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + private static final MethodDescriptor listLocationsMethodDescriptor = MethodDescriptor.newBuilder() @@ -365,6 +686,72 @@ public class GrpcAgentRegistryStub extends AgentRegistryStub { fetchAvailableBindingsCallable; private final UnaryCallable fetchAvailableBindingsPagedCallable; + private final UnaryCallable createSkillCallable; + private final OperationCallable + createSkillOperationCallable; + private final UnaryCallable getSkillCallable; + private final UnaryCallable updateSkillCallable; + private final OperationCallable + updateSkillOperationCallable; + private final UnaryCallable deleteSkillCallable; + private final OperationCallable + deleteSkillOperationCallable; + private final UnaryCallable listSkillsCallable; + private final UnaryCallable listSkillsPagedCallable; + private final UnaryCallable searchSkillsCallable; + private final UnaryCallable + searchSkillsPagedCallable; + private final UnaryCallable createSkillRevisionCallable; + private final OperationCallable + createSkillRevisionOperationCallable; + private final UnaryCallable getSkillRevisionCallable; + private final UnaryCallable deleteSkillRevisionCallable; + private final OperationCallable + deleteSkillRevisionOperationCallable; + private final UnaryCallable + listSkillRevisionsCallable; + private final UnaryCallable + listSkillRevisionsPagedCallable; + private final UnaryCallable getPublisherCallable; + private final UnaryCallable listPublishersCallable; + private final UnaryCallable + listPublishersPagedCallable; + private final UnaryCallable getAiApplicationCallable; + private final UnaryCallable + listAiApplicationsCallable; + private final UnaryCallable + listAiApplicationsPagedCallable; + private final UnaryCallable getAiApplicationAgentCallable; + private final UnaryCallable + listAiApplicationAgentsCallable; + private final UnaryCallable + listAiApplicationAgentsPagedCallable; + private final UnaryCallable + getAiApplicationMcpServerCallable; + private final UnaryCallable< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersResponse> + listAiApplicationMcpServersCallable; + private final UnaryCallable< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersPagedResponse> + listAiApplicationMcpServersPagedCallable; + private final UnaryCallable getFindingCallable; + private final UnaryCallable listFindingsCallable; + private final UnaryCallable + listFindingsPagedCallable; + private final UnaryCallable + getAiApplicationEndpointCallable; + private final UnaryCallable + listAiApplicationEndpointsCallable; + private final UnaryCallable< + ListAiApplicationEndpointsRequest, ListAiApplicationEndpointsPagedResponse> + listAiApplicationEndpointsPagedCallable; + private final UnaryCallable + getSkillEncryptionSpecCallable; + private final UnaryCallable + updateSkillEncryptionSpecCallable; + private final OperationCallable< + UpdateSkillEncryptionSpecRequest, SkillEncryptionSpec, OperationMetadata> + updateSkillEncryptionSpecOperationCallable; private final UnaryCallable listLocationsCallable; private final UnaryCallable listLocationsPagedCallable; @@ -623,6 +1010,284 @@ protected GrpcAgentRegistryStub( }) .setResourceNameExtractor(request -> request.getParent()) .build(); + GrpcCallSettings createSkillTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createSkillMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings getSkillTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getSkillMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings updateSkillTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateSkillMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("skill.name", String.valueOf(request.getSkill().getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings deleteSkillTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteSkillMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings listSkillsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listSkillsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings searchSkillsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(searchSkillsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings createSkillRevisionTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createSkillRevisionMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings getSkillRevisionTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getSkillRevisionMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings deleteSkillRevisionTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteSkillRevisionMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + listSkillRevisionsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listSkillRevisionsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings getPublisherTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getPublisherMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + listPublishersTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listPublishersMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings getAiApplicationTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getAiApplicationMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + listAiApplicationsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listAiApplicationsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings getAiApplicationAgentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getAiApplicationAgentMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + listAiApplicationAgentsTransportSettings = + GrpcCallSettings + .newBuilder() + .setMethodDescriptor(listAiApplicationAgentsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings + getAiApplicationMcpServerTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getAiApplicationMcpServerMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + listAiApplicationMcpServersTransportSettings = + GrpcCallSettings + . + newBuilder() + .setMethodDescriptor(listAiApplicationMcpServersMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings getFindingTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getFindingMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings listFindingsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listFindingsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings + getAiApplicationEndpointTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getAiApplicationEndpointMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + listAiApplicationEndpointsTransportSettings = + GrpcCallSettings + .newBuilder() + .setMethodDescriptor(listAiApplicationEndpointsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings + getSkillEncryptionSpecTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getSkillEncryptionSpecMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + updateSkillEncryptionSpecTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateSkillEncryptionSpecMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add( + "skill_encryption_spec.name", + String.valueOf(request.getSkillEncryptionSpec().getName())); + return builder.build(); + }) + .build(); GrpcCallSettings listLocationsTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(listLocationsMethodDescriptor) @@ -765,6 +1430,175 @@ protected GrpcAgentRegistryStub( fetchAvailableBindingsTransportSettings, settings.fetchAvailableBindingsSettings(), clientContext); + this.createSkillCallable = + callableFactory.createUnaryCallable( + createSkillTransportSettings, settings.createSkillSettings(), clientContext); + this.createSkillOperationCallable = + callableFactory.createOperationCallable( + createSkillTransportSettings, + settings.createSkillOperationSettings(), + clientContext, + operationsStub); + this.getSkillCallable = + callableFactory.createUnaryCallable( + getSkillTransportSettings, settings.getSkillSettings(), clientContext); + this.updateSkillCallable = + callableFactory.createUnaryCallable( + updateSkillTransportSettings, settings.updateSkillSettings(), clientContext); + this.updateSkillOperationCallable = + callableFactory.createOperationCallable( + updateSkillTransportSettings, + settings.updateSkillOperationSettings(), + clientContext, + operationsStub); + this.deleteSkillCallable = + callableFactory.createUnaryCallable( + deleteSkillTransportSettings, settings.deleteSkillSettings(), clientContext); + this.deleteSkillOperationCallable = + callableFactory.createOperationCallable( + deleteSkillTransportSettings, + settings.deleteSkillOperationSettings(), + clientContext, + operationsStub); + this.listSkillsCallable = + callableFactory.createUnaryCallable( + listSkillsTransportSettings, settings.listSkillsSettings(), clientContext); + this.listSkillsPagedCallable = + callableFactory.createPagedCallable( + listSkillsTransportSettings, settings.listSkillsSettings(), clientContext); + this.searchSkillsCallable = + callableFactory.createUnaryCallable( + searchSkillsTransportSettings, settings.searchSkillsSettings(), clientContext); + this.searchSkillsPagedCallable = + callableFactory.createPagedCallable( + searchSkillsTransportSettings, settings.searchSkillsSettings(), clientContext); + this.createSkillRevisionCallable = + callableFactory.createUnaryCallable( + createSkillRevisionTransportSettings, + settings.createSkillRevisionSettings(), + clientContext); + this.createSkillRevisionOperationCallable = + callableFactory.createOperationCallable( + createSkillRevisionTransportSettings, + settings.createSkillRevisionOperationSettings(), + clientContext, + operationsStub); + this.getSkillRevisionCallable = + callableFactory.createUnaryCallable( + getSkillRevisionTransportSettings, settings.getSkillRevisionSettings(), clientContext); + this.deleteSkillRevisionCallable = + callableFactory.createUnaryCallable( + deleteSkillRevisionTransportSettings, + settings.deleteSkillRevisionSettings(), + clientContext); + this.deleteSkillRevisionOperationCallable = + callableFactory.createOperationCallable( + deleteSkillRevisionTransportSettings, + settings.deleteSkillRevisionOperationSettings(), + clientContext, + operationsStub); + this.listSkillRevisionsCallable = + callableFactory.createUnaryCallable( + listSkillRevisionsTransportSettings, + settings.listSkillRevisionsSettings(), + clientContext); + this.listSkillRevisionsPagedCallable = + callableFactory.createPagedCallable( + listSkillRevisionsTransportSettings, + settings.listSkillRevisionsSettings(), + clientContext); + this.getPublisherCallable = + callableFactory.createUnaryCallable( + getPublisherTransportSettings, settings.getPublisherSettings(), clientContext); + this.listPublishersCallable = + callableFactory.createUnaryCallable( + listPublishersTransportSettings, settings.listPublishersSettings(), clientContext); + this.listPublishersPagedCallable = + callableFactory.createPagedCallable( + listPublishersTransportSettings, settings.listPublishersSettings(), clientContext); + this.getAiApplicationCallable = + callableFactory.createUnaryCallable( + getAiApplicationTransportSettings, settings.getAiApplicationSettings(), clientContext); + this.listAiApplicationsCallable = + callableFactory.createUnaryCallable( + listAiApplicationsTransportSettings, + settings.listAiApplicationsSettings(), + clientContext); + this.listAiApplicationsPagedCallable = + callableFactory.createPagedCallable( + listAiApplicationsTransportSettings, + settings.listAiApplicationsSettings(), + clientContext); + this.getAiApplicationAgentCallable = + callableFactory.createUnaryCallable( + getAiApplicationAgentTransportSettings, + settings.getAiApplicationAgentSettings(), + clientContext); + this.listAiApplicationAgentsCallable = + callableFactory.createUnaryCallable( + listAiApplicationAgentsTransportSettings, + settings.listAiApplicationAgentsSettings(), + clientContext); + this.listAiApplicationAgentsPagedCallable = + callableFactory.createPagedCallable( + listAiApplicationAgentsTransportSettings, + settings.listAiApplicationAgentsSettings(), + clientContext); + this.getAiApplicationMcpServerCallable = + callableFactory.createUnaryCallable( + getAiApplicationMcpServerTransportSettings, + settings.getAiApplicationMcpServerSettings(), + clientContext); + this.listAiApplicationMcpServersCallable = + callableFactory.createUnaryCallable( + listAiApplicationMcpServersTransportSettings, + settings.listAiApplicationMcpServersSettings(), + clientContext); + this.listAiApplicationMcpServersPagedCallable = + callableFactory.createPagedCallable( + listAiApplicationMcpServersTransportSettings, + settings.listAiApplicationMcpServersSettings(), + clientContext); + this.getFindingCallable = + callableFactory.createUnaryCallable( + getFindingTransportSettings, settings.getFindingSettings(), clientContext); + this.listFindingsCallable = + callableFactory.createUnaryCallable( + listFindingsTransportSettings, settings.listFindingsSettings(), clientContext); + this.listFindingsPagedCallable = + callableFactory.createPagedCallable( + listFindingsTransportSettings, settings.listFindingsSettings(), clientContext); + this.getAiApplicationEndpointCallable = + callableFactory.createUnaryCallable( + getAiApplicationEndpointTransportSettings, + settings.getAiApplicationEndpointSettings(), + clientContext); + this.listAiApplicationEndpointsCallable = + callableFactory.createUnaryCallable( + listAiApplicationEndpointsTransportSettings, + settings.listAiApplicationEndpointsSettings(), + clientContext); + this.listAiApplicationEndpointsPagedCallable = + callableFactory.createPagedCallable( + listAiApplicationEndpointsTransportSettings, + settings.listAiApplicationEndpointsSettings(), + clientContext); + this.getSkillEncryptionSpecCallable = + callableFactory.createUnaryCallable( + getSkillEncryptionSpecTransportSettings, + settings.getSkillEncryptionSpecSettings(), + clientContext); + this.updateSkillEncryptionSpecCallable = + callableFactory.createUnaryCallable( + updateSkillEncryptionSpecTransportSettings, + settings.updateSkillEncryptionSpecSettings(), + clientContext); + this.updateSkillEncryptionSpecOperationCallable = + callableFactory.createOperationCallable( + updateSkillEncryptionSpecTransportSettings, + settings.updateSkillEncryptionSpecOperationSettings(), + clientContext, + operationsStub); this.listLocationsCallable = callableFactory.createUnaryCallable( listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); @@ -960,6 +1794,222 @@ public UnaryCallable deleteBindingCallable() { return fetchAvailableBindingsPagedCallable; } + @Override + public UnaryCallable createSkillCallable() { + return createSkillCallable; + } + + @Override + public OperationCallable + createSkillOperationCallable() { + return createSkillOperationCallable; + } + + @Override + public UnaryCallable getSkillCallable() { + return getSkillCallable; + } + + @Override + public UnaryCallable updateSkillCallable() { + return updateSkillCallable; + } + + @Override + public OperationCallable + updateSkillOperationCallable() { + return updateSkillOperationCallable; + } + + @Override + public UnaryCallable deleteSkillCallable() { + return deleteSkillCallable; + } + + @Override + public OperationCallable + deleteSkillOperationCallable() { + return deleteSkillOperationCallable; + } + + @Override + public UnaryCallable listSkillsCallable() { + return listSkillsCallable; + } + + @Override + public UnaryCallable listSkillsPagedCallable() { + return listSkillsPagedCallable; + } + + @Override + public UnaryCallable searchSkillsCallable() { + return searchSkillsCallable; + } + + @Override + public UnaryCallable searchSkillsPagedCallable() { + return searchSkillsPagedCallable; + } + + @Override + public UnaryCallable createSkillRevisionCallable() { + return createSkillRevisionCallable; + } + + @Override + public OperationCallable + createSkillRevisionOperationCallable() { + return createSkillRevisionOperationCallable; + } + + @Override + public UnaryCallable getSkillRevisionCallable() { + return getSkillRevisionCallable; + } + + @Override + public UnaryCallable deleteSkillRevisionCallable() { + return deleteSkillRevisionCallable; + } + + @Override + public OperationCallable + deleteSkillRevisionOperationCallable() { + return deleteSkillRevisionOperationCallable; + } + + @Override + public UnaryCallable + listSkillRevisionsCallable() { + return listSkillRevisionsCallable; + } + + @Override + public UnaryCallable + listSkillRevisionsPagedCallable() { + return listSkillRevisionsPagedCallable; + } + + @Override + public UnaryCallable getPublisherCallable() { + return getPublisherCallable; + } + + @Override + public UnaryCallable listPublishersCallable() { + return listPublishersCallable; + } + + @Override + public UnaryCallable + listPublishersPagedCallable() { + return listPublishersPagedCallable; + } + + @Override + public UnaryCallable getAiApplicationCallable() { + return getAiApplicationCallable; + } + + @Override + public UnaryCallable + listAiApplicationsCallable() { + return listAiApplicationsCallable; + } + + @Override + public UnaryCallable + listAiApplicationsPagedCallable() { + return listAiApplicationsPagedCallable; + } + + @Override + public UnaryCallable getAiApplicationAgentCallable() { + return getAiApplicationAgentCallable; + } + + @Override + public UnaryCallable + listAiApplicationAgentsCallable() { + return listAiApplicationAgentsCallable; + } + + @Override + public UnaryCallable + listAiApplicationAgentsPagedCallable() { + return listAiApplicationAgentsPagedCallable; + } + + @Override + public UnaryCallable + getAiApplicationMcpServerCallable() { + return getAiApplicationMcpServerCallable; + } + + @Override + public UnaryCallable + listAiApplicationMcpServersCallable() { + return listAiApplicationMcpServersCallable; + } + + @Override + public UnaryCallable + listAiApplicationMcpServersPagedCallable() { + return listAiApplicationMcpServersPagedCallable; + } + + @Override + public UnaryCallable getFindingCallable() { + return getFindingCallable; + } + + @Override + public UnaryCallable listFindingsCallable() { + return listFindingsCallable; + } + + @Override + public UnaryCallable listFindingsPagedCallable() { + return listFindingsPagedCallable; + } + + @Override + public UnaryCallable + getAiApplicationEndpointCallable() { + return getAiApplicationEndpointCallable; + } + + @Override + public UnaryCallable + listAiApplicationEndpointsCallable() { + return listAiApplicationEndpointsCallable; + } + + @Override + public UnaryCallable + listAiApplicationEndpointsPagedCallable() { + return listAiApplicationEndpointsPagedCallable; + } + + @Override + public UnaryCallable + getSkillEncryptionSpecCallable() { + return getSkillEncryptionSpecCallable; + } + + @Override + public UnaryCallable + updateSkillEncryptionSpecCallable() { + return updateSkillEncryptionSpecCallable; + } + + @Override + public OperationCallable + updateSkillEncryptionSpecOperationCallable() { + return updateSkillEncryptionSpecOperationCallable; + } + @Override public UnaryCallable listLocationsCallable() { return listLocationsCallable; diff --git a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/HttpJsonAgentRegistryStub.java b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/HttpJsonAgentRegistryStub.java index 7cbf79bff575..cad6d0e36ae4 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/HttpJsonAgentRegistryStub.java +++ b/java-agentregistry/google-cloud-agentregistry/src/main/java/com/google/cloud/agentregistry/v1/stub/HttpJsonAgentRegistryStub.java @@ -18,13 +18,22 @@ import static com.google.cloud.agentregistry.v1.AgentRegistryClient.FetchAvailableBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListFindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListLocationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListPublishersPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListServicesPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillRevisionsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchAgentsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchSkillsPagedResponse; import com.google.api.HttpRule; import com.google.api.core.InternalApi; @@ -43,38 +52,77 @@ import com.google.api.gax.rpc.RequestParamsBuilder; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AiApplication; import com.google.cloud.agentregistry.v1.Binding; import com.google.cloud.agentregistry.v1.CreateBindingRequest; import com.google.cloud.agentregistry.v1.CreateServiceRequest; +import com.google.cloud.agentregistry.v1.CreateSkillRequest; +import com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest; import com.google.cloud.agentregistry.v1.DeleteBindingRequest; import com.google.cloud.agentregistry.v1.DeleteServiceRequest; +import com.google.cloud.agentregistry.v1.DeleteSkillRequest; +import com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest; import com.google.cloud.agentregistry.v1.Endpoint; import com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest; import com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse; +import com.google.cloud.agentregistry.v1.Finding; import com.google.cloud.agentregistry.v1.GetAgentRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest; +import com.google.cloud.agentregistry.v1.GetAiApplicationRequest; import com.google.cloud.agentregistry.v1.GetBindingRequest; import com.google.cloud.agentregistry.v1.GetEndpointRequest; +import com.google.cloud.agentregistry.v1.GetFindingRequest; import com.google.cloud.agentregistry.v1.GetMcpServerRequest; +import com.google.cloud.agentregistry.v1.GetPublisherRequest; import com.google.cloud.agentregistry.v1.GetServiceRequest; +import com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest; +import com.google.cloud.agentregistry.v1.GetSkillRequest; +import com.google.cloud.agentregistry.v1.GetSkillRevisionRequest; import com.google.cloud.agentregistry.v1.ListAgentsRequest; import com.google.cloud.agentregistry.v1.ListAgentsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse; +import com.google.cloud.agentregistry.v1.ListAiApplicationsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationsResponse; import com.google.cloud.agentregistry.v1.ListBindingsRequest; import com.google.cloud.agentregistry.v1.ListBindingsResponse; import com.google.cloud.agentregistry.v1.ListEndpointsRequest; import com.google.cloud.agentregistry.v1.ListEndpointsResponse; +import com.google.cloud.agentregistry.v1.ListFindingsRequest; +import com.google.cloud.agentregistry.v1.ListFindingsResponse; import com.google.cloud.agentregistry.v1.ListMcpServersRequest; import com.google.cloud.agentregistry.v1.ListMcpServersResponse; +import com.google.cloud.agentregistry.v1.ListPublishersRequest; +import com.google.cloud.agentregistry.v1.ListPublishersResponse; import com.google.cloud.agentregistry.v1.ListServicesRequest; import com.google.cloud.agentregistry.v1.ListServicesResponse; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse; +import com.google.cloud.agentregistry.v1.ListSkillsRequest; +import com.google.cloud.agentregistry.v1.ListSkillsResponse; import com.google.cloud.agentregistry.v1.McpServer; import com.google.cloud.agentregistry.v1.OperationMetadata; +import com.google.cloud.agentregistry.v1.Publisher; import com.google.cloud.agentregistry.v1.SearchAgentsRequest; import com.google.cloud.agentregistry.v1.SearchAgentsResponse; import com.google.cloud.agentregistry.v1.SearchMcpServersRequest; import com.google.cloud.agentregistry.v1.SearchMcpServersResponse; +import com.google.cloud.agentregistry.v1.SearchSkillsRequest; +import com.google.cloud.agentregistry.v1.SearchSkillsResponse; import com.google.cloud.agentregistry.v1.Service; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.cloud.agentregistry.v1.SkillRevision; import com.google.cloud.agentregistry.v1.UpdateBindingRequest; import com.google.cloud.agentregistry.v1.UpdateServiceRequest; +import com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest; +import com.google.cloud.agentregistry.v1.UpdateSkillRequest; import com.google.cloud.location.GetLocationRequest; import com.google.cloud.location.ListLocationsRequest; import com.google.cloud.location.ListLocationsResponse; @@ -104,8 +152,11 @@ public class HttpJsonAgentRegistryStub extends AgentRegistryStub { private static final TypeRegistry typeRegistry = TypeRegistry.newBuilder() .add(Empty.getDescriptor()) + .add(SkillEncryptionSpec.getDescriptor()) .add(OperationMetadata.getDescriptor()) .add(Binding.getDescriptor()) + .add(SkillRevision.getDescriptor()) + .add(Skill.getDescriptor()) .add(Service.getDescriptor()) .build(); @@ -827,6 +878,908 @@ public class HttpJsonAgentRegistryStub extends AgentRegistryStub { .build()) .build(); + private static final ApiMethodDescriptor + createSkillMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/CreateSkill") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/skills", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "requestId", request.getRequestId()); + serializer.putQueryParam(fields, "skillId", request.getSkillId()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("skill", request.getSkill(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (CreateSkillRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor getSkillMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/GetSkill") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/skills/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Skill.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + updateSkillMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/UpdateSkill") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{skill.name=projects/*/locations/*/skills/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, "skill.name", request.getSkill().getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "requestId", request.getRequestId()); + serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("skill", request.getSkill(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (UpdateSkillRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + deleteSkillMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/DeleteSkill") + .setHttpMethod("DELETE") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/skills/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "force", request.getForce()); + serializer.putQueryParam(fields, "requestId", request.getRequestId()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (DeleteSkillRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + listSkillsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/ListSkills") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/skills", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "filter", request.getFilter()); + serializer.putQueryParam(fields, "orderBy", request.getOrderBy()); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListSkillsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + searchSkillsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/SearchSkills") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/skills:search", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setAdditionalPaths("/v1/{parent=projects/*/locations/*}/skills:search") + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("*", request.toBuilder().clearParent().build(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(SearchSkillsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + createSkillRevisionMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/CreateSkillRevision") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*/skills/*}/revisions", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "requestId", request.getRequestId()); + serializer.putQueryParam( + fields, "skillRevisionId", request.getSkillRevisionId()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("skillRevision", request.getSkillRevision(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (CreateSkillRevisionRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + getSkillRevisionMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/GetSkillRevision") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/skills/*/revisions/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(SkillRevision.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + deleteSkillRevisionMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/DeleteSkillRevision") + .setHttpMethod("DELETE") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/skills/*/revisions/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "requestId", request.getRequestId()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (DeleteSkillRevisionRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + listSkillRevisionsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/ListSkillRevisions") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*/skills/*}/revisions", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListSkillRevisionsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getPublisherMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/GetPublisher") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/publishers/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Publisher.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + listPublishersMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/ListPublishers") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/publishers", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListPublishersResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getAiApplicationMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/GetAiApplication") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/aiApplications/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(AiApplication.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + listAiApplicationsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/ListAiApplications") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/aiApplications", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "filter", request.getFilter()); + serializer.putQueryParam(fields, "orderBy", request.getOrderBy()); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListAiApplicationsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getAiApplicationAgentMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/GetAiApplicationAgent") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/aiApplications/*/agents/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Agent.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor< + ListAiApplicationAgentsRequest, ListAiApplicationAgentsResponse> + listAiApplicationAgentsMethodDescriptor = + ApiMethodDescriptor + .newBuilder() + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/ListAiApplicationAgents") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*/aiApplications/*}/agents", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListAiApplicationAgentsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getAiApplicationMcpServerMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/GetAiApplicationMcpServer") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/aiApplications/*/mcpServers/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(McpServer.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersResponse> + listAiApplicationMcpServersMethodDescriptor = + ApiMethodDescriptor + .newBuilder() + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/ListAiApplicationMcpServers") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*/aiApplications/*}/mcpServers", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListAiApplicationMcpServersResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor getFindingMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/GetFinding") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/findings/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Finding.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + listFindingsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.agentregistry.v1.AgentRegistry/ListFindings") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/findings", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "filter", request.getFilter()); + serializer.putQueryParam(fields, "orderBy", request.getOrderBy()); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListFindingsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getAiApplicationEndpointMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/GetAiApplicationEndpoint") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/aiApplications/*/endpoints/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Endpoint.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor< + ListAiApplicationEndpointsRequest, ListAiApplicationEndpointsResponse> + listAiApplicationEndpointsMethodDescriptor = + ApiMethodDescriptor + .newBuilder() + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/ListAiApplicationEndpoints") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*/aiApplications/*}/endpoints", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListAiApplicationEndpointsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getSkillEncryptionSpecMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/GetSkillEncryptionSpec") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/skillEncryptionSpec}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(SkillEncryptionSpec.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + updateSkillEncryptionSpecMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.agentregistry.v1.AgentRegistry/UpdateSkillEncryptionSpec") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{skillEncryptionSpec.name=projects/*/locations/*/skillEncryptionSpec}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, + "skillEncryptionSpec.name", + request.getSkillEncryptionSpec().getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody( + "skillEncryptionSpec", + request.getSkillEncryptionSpec(), + true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (UpdateSkillEncryptionSpecRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + private static final ApiMethodDescriptor listLocationsMethodDescriptor = ApiMethodDescriptor.newBuilder() @@ -943,6 +1896,72 @@ public class HttpJsonAgentRegistryStub extends AgentRegistryStub { fetchAvailableBindingsCallable; private final UnaryCallable fetchAvailableBindingsPagedCallable; + private final UnaryCallable createSkillCallable; + private final OperationCallable + createSkillOperationCallable; + private final UnaryCallable getSkillCallable; + private final UnaryCallable updateSkillCallable; + private final OperationCallable + updateSkillOperationCallable; + private final UnaryCallable deleteSkillCallable; + private final OperationCallable + deleteSkillOperationCallable; + private final UnaryCallable listSkillsCallable; + private final UnaryCallable listSkillsPagedCallable; + private final UnaryCallable searchSkillsCallable; + private final UnaryCallable + searchSkillsPagedCallable; + private final UnaryCallable createSkillRevisionCallable; + private final OperationCallable + createSkillRevisionOperationCallable; + private final UnaryCallable getSkillRevisionCallable; + private final UnaryCallable deleteSkillRevisionCallable; + private final OperationCallable + deleteSkillRevisionOperationCallable; + private final UnaryCallable + listSkillRevisionsCallable; + private final UnaryCallable + listSkillRevisionsPagedCallable; + private final UnaryCallable getPublisherCallable; + private final UnaryCallable listPublishersCallable; + private final UnaryCallable + listPublishersPagedCallable; + private final UnaryCallable getAiApplicationCallable; + private final UnaryCallable + listAiApplicationsCallable; + private final UnaryCallable + listAiApplicationsPagedCallable; + private final UnaryCallable getAiApplicationAgentCallable; + private final UnaryCallable + listAiApplicationAgentsCallable; + private final UnaryCallable + listAiApplicationAgentsPagedCallable; + private final UnaryCallable + getAiApplicationMcpServerCallable; + private final UnaryCallable< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersResponse> + listAiApplicationMcpServersCallable; + private final UnaryCallable< + ListAiApplicationMcpServersRequest, ListAiApplicationMcpServersPagedResponse> + listAiApplicationMcpServersPagedCallable; + private final UnaryCallable getFindingCallable; + private final UnaryCallable listFindingsCallable; + private final UnaryCallable + listFindingsPagedCallable; + private final UnaryCallable + getAiApplicationEndpointCallable; + private final UnaryCallable + listAiApplicationEndpointsCallable; + private final UnaryCallable< + ListAiApplicationEndpointsRequest, ListAiApplicationEndpointsPagedResponse> + listAiApplicationEndpointsPagedCallable; + private final UnaryCallable + getSkillEncryptionSpecCallable; + private final UnaryCallable + updateSkillEncryptionSpecCallable; + private final OperationCallable< + UpdateSkillEncryptionSpecRequest, SkillEncryptionSpec, OperationMetadata> + updateSkillEncryptionSpecOperationCallable; private final UnaryCallable listLocationsCallable; private final UnaryCallable listLocationsPagedCallable; @@ -1200,9 +2219,297 @@ protected HttpJsonAgentRegistryStub( }) .setResourceNameExtractor(request -> request.getName()) .build(); - HttpJsonCallSettings createBindingTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(createBindingMethodDescriptor) + HttpJsonCallSettings createBindingTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createBindingMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings updateBindingTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateBindingMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("binding.name", String.valueOf(request.getBinding().getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings deleteBindingTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(deleteBindingMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings + fetchAvailableBindingsTransportSettings = + HttpJsonCallSettings + .newBuilder() + .setMethodDescriptor(fetchAvailableBindingsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings createSkillTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createSkillMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings getSkillTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getSkillMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings updateSkillTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateSkillMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("skill.name", String.valueOf(request.getSkill().getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings deleteSkillTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(deleteSkillMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings listSkillsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listSkillsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings searchSkillsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(searchSkillsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings + createSkillRevisionTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createSkillRevisionMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings getSkillRevisionTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getSkillRevisionMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings + deleteSkillRevisionTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(deleteSkillRevisionMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings + listSkillRevisionsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listSkillRevisionsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings getPublisherTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getPublisherMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings + listPublishersTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listPublishersMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings getAiApplicationTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getAiApplicationMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings + listAiApplicationsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listAiApplicationsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings + getAiApplicationAgentTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getAiApplicationAgentMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings + listAiApplicationAgentsTransportSettings = + HttpJsonCallSettings + .newBuilder() + .setMethodDescriptor(listAiApplicationAgentsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings + getAiApplicationMcpServerTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getAiApplicationMcpServerMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings + listAiApplicationMcpServersTransportSettings = + HttpJsonCallSettings + . + newBuilder() + .setMethodDescriptor(listAiApplicationMcpServersMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings getFindingTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getFindingMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings listFindingsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listFindingsMethodDescriptor) .setTypeRegistry(typeRegistry) .setParamsExtractor( request -> { @@ -1212,34 +2519,24 @@ protected HttpJsonAgentRegistryStub( }) .setResourceNameExtractor(request -> request.getParent()) .build(); - HttpJsonCallSettings updateBindingTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(updateBindingMethodDescriptor) - .setTypeRegistry(typeRegistry) - .setParamsExtractor( - request -> { - RequestParamsBuilder builder = RequestParamsBuilder.create(); - builder.add("binding.name", String.valueOf(request.getBinding().getName())); - return builder.build(); - }) - .build(); - HttpJsonCallSettings deleteBindingTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(deleteBindingMethodDescriptor) - .setTypeRegistry(typeRegistry) - .setParamsExtractor( - request -> { - RequestParamsBuilder builder = RequestParamsBuilder.create(); - builder.add("name", String.valueOf(request.getName())); - return builder.build(); - }) - .setResourceNameExtractor(request -> request.getName()) - .build(); - HttpJsonCallSettings - fetchAvailableBindingsTransportSettings = + HttpJsonCallSettings + getAiApplicationEndpointTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getAiApplicationEndpointMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings + listAiApplicationEndpointsTransportSettings = HttpJsonCallSettings - .newBuilder() - .setMethodDescriptor(fetchAvailableBindingsMethodDescriptor) + .newBuilder() + .setMethodDescriptor(listAiApplicationEndpointsMethodDescriptor) .setTypeRegistry(typeRegistry) .setParamsExtractor( request -> { @@ -1249,6 +2546,33 @@ protected HttpJsonAgentRegistryStub( }) .setResourceNameExtractor(request -> request.getParent()) .build(); + HttpJsonCallSettings + getSkillEncryptionSpecTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getSkillEncryptionSpecMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings + updateSkillEncryptionSpecTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateSkillEncryptionSpecMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add( + "skill_encryption_spec.name", + String.valueOf(request.getSkillEncryptionSpec().getName())); + return builder.build(); + }) + .build(); HttpJsonCallSettings listLocationsTransportSettings = HttpJsonCallSettings.newBuilder() @@ -1394,6 +2718,175 @@ protected HttpJsonAgentRegistryStub( fetchAvailableBindingsTransportSettings, settings.fetchAvailableBindingsSettings(), clientContext); + this.createSkillCallable = + callableFactory.createUnaryCallable( + createSkillTransportSettings, settings.createSkillSettings(), clientContext); + this.createSkillOperationCallable = + callableFactory.createOperationCallable( + createSkillTransportSettings, + settings.createSkillOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.getSkillCallable = + callableFactory.createUnaryCallable( + getSkillTransportSettings, settings.getSkillSettings(), clientContext); + this.updateSkillCallable = + callableFactory.createUnaryCallable( + updateSkillTransportSettings, settings.updateSkillSettings(), clientContext); + this.updateSkillOperationCallable = + callableFactory.createOperationCallable( + updateSkillTransportSettings, + settings.updateSkillOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.deleteSkillCallable = + callableFactory.createUnaryCallable( + deleteSkillTransportSettings, settings.deleteSkillSettings(), clientContext); + this.deleteSkillOperationCallable = + callableFactory.createOperationCallable( + deleteSkillTransportSettings, + settings.deleteSkillOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.listSkillsCallable = + callableFactory.createUnaryCallable( + listSkillsTransportSettings, settings.listSkillsSettings(), clientContext); + this.listSkillsPagedCallable = + callableFactory.createPagedCallable( + listSkillsTransportSettings, settings.listSkillsSettings(), clientContext); + this.searchSkillsCallable = + callableFactory.createUnaryCallable( + searchSkillsTransportSettings, settings.searchSkillsSettings(), clientContext); + this.searchSkillsPagedCallable = + callableFactory.createPagedCallable( + searchSkillsTransportSettings, settings.searchSkillsSettings(), clientContext); + this.createSkillRevisionCallable = + callableFactory.createUnaryCallable( + createSkillRevisionTransportSettings, + settings.createSkillRevisionSettings(), + clientContext); + this.createSkillRevisionOperationCallable = + callableFactory.createOperationCallable( + createSkillRevisionTransportSettings, + settings.createSkillRevisionOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.getSkillRevisionCallable = + callableFactory.createUnaryCallable( + getSkillRevisionTransportSettings, settings.getSkillRevisionSettings(), clientContext); + this.deleteSkillRevisionCallable = + callableFactory.createUnaryCallable( + deleteSkillRevisionTransportSettings, + settings.deleteSkillRevisionSettings(), + clientContext); + this.deleteSkillRevisionOperationCallable = + callableFactory.createOperationCallable( + deleteSkillRevisionTransportSettings, + settings.deleteSkillRevisionOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.listSkillRevisionsCallable = + callableFactory.createUnaryCallable( + listSkillRevisionsTransportSettings, + settings.listSkillRevisionsSettings(), + clientContext); + this.listSkillRevisionsPagedCallable = + callableFactory.createPagedCallable( + listSkillRevisionsTransportSettings, + settings.listSkillRevisionsSettings(), + clientContext); + this.getPublisherCallable = + callableFactory.createUnaryCallable( + getPublisherTransportSettings, settings.getPublisherSettings(), clientContext); + this.listPublishersCallable = + callableFactory.createUnaryCallable( + listPublishersTransportSettings, settings.listPublishersSettings(), clientContext); + this.listPublishersPagedCallable = + callableFactory.createPagedCallable( + listPublishersTransportSettings, settings.listPublishersSettings(), clientContext); + this.getAiApplicationCallable = + callableFactory.createUnaryCallable( + getAiApplicationTransportSettings, settings.getAiApplicationSettings(), clientContext); + this.listAiApplicationsCallable = + callableFactory.createUnaryCallable( + listAiApplicationsTransportSettings, + settings.listAiApplicationsSettings(), + clientContext); + this.listAiApplicationsPagedCallable = + callableFactory.createPagedCallable( + listAiApplicationsTransportSettings, + settings.listAiApplicationsSettings(), + clientContext); + this.getAiApplicationAgentCallable = + callableFactory.createUnaryCallable( + getAiApplicationAgentTransportSettings, + settings.getAiApplicationAgentSettings(), + clientContext); + this.listAiApplicationAgentsCallable = + callableFactory.createUnaryCallable( + listAiApplicationAgentsTransportSettings, + settings.listAiApplicationAgentsSettings(), + clientContext); + this.listAiApplicationAgentsPagedCallable = + callableFactory.createPagedCallable( + listAiApplicationAgentsTransportSettings, + settings.listAiApplicationAgentsSettings(), + clientContext); + this.getAiApplicationMcpServerCallable = + callableFactory.createUnaryCallable( + getAiApplicationMcpServerTransportSettings, + settings.getAiApplicationMcpServerSettings(), + clientContext); + this.listAiApplicationMcpServersCallable = + callableFactory.createUnaryCallable( + listAiApplicationMcpServersTransportSettings, + settings.listAiApplicationMcpServersSettings(), + clientContext); + this.listAiApplicationMcpServersPagedCallable = + callableFactory.createPagedCallable( + listAiApplicationMcpServersTransportSettings, + settings.listAiApplicationMcpServersSettings(), + clientContext); + this.getFindingCallable = + callableFactory.createUnaryCallable( + getFindingTransportSettings, settings.getFindingSettings(), clientContext); + this.listFindingsCallable = + callableFactory.createUnaryCallable( + listFindingsTransportSettings, settings.listFindingsSettings(), clientContext); + this.listFindingsPagedCallable = + callableFactory.createPagedCallable( + listFindingsTransportSettings, settings.listFindingsSettings(), clientContext); + this.getAiApplicationEndpointCallable = + callableFactory.createUnaryCallable( + getAiApplicationEndpointTransportSettings, + settings.getAiApplicationEndpointSettings(), + clientContext); + this.listAiApplicationEndpointsCallable = + callableFactory.createUnaryCallable( + listAiApplicationEndpointsTransportSettings, + settings.listAiApplicationEndpointsSettings(), + clientContext); + this.listAiApplicationEndpointsPagedCallable = + callableFactory.createPagedCallable( + listAiApplicationEndpointsTransportSettings, + settings.listAiApplicationEndpointsSettings(), + clientContext); + this.getSkillEncryptionSpecCallable = + callableFactory.createUnaryCallable( + getSkillEncryptionSpecTransportSettings, + settings.getSkillEncryptionSpecSettings(), + clientContext); + this.updateSkillEncryptionSpecCallable = + callableFactory.createUnaryCallable( + updateSkillEncryptionSpecTransportSettings, + settings.updateSkillEncryptionSpecSettings(), + clientContext); + this.updateSkillEncryptionSpecOperationCallable = + callableFactory.createOperationCallable( + updateSkillEncryptionSpecTransportSettings, + settings.updateSkillEncryptionSpecOperationSettings(), + clientContext, + httpJsonOperationsStub); this.listLocationsCallable = callableFactory.createUnaryCallable( listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); @@ -1430,6 +2923,30 @@ public static List getMethodDescriptors() { methodDescriptors.add(updateBindingMethodDescriptor); methodDescriptors.add(deleteBindingMethodDescriptor); methodDescriptors.add(fetchAvailableBindingsMethodDescriptor); + methodDescriptors.add(createSkillMethodDescriptor); + methodDescriptors.add(getSkillMethodDescriptor); + methodDescriptors.add(updateSkillMethodDescriptor); + methodDescriptors.add(deleteSkillMethodDescriptor); + methodDescriptors.add(listSkillsMethodDescriptor); + methodDescriptors.add(searchSkillsMethodDescriptor); + methodDescriptors.add(createSkillRevisionMethodDescriptor); + methodDescriptors.add(getSkillRevisionMethodDescriptor); + methodDescriptors.add(deleteSkillRevisionMethodDescriptor); + methodDescriptors.add(listSkillRevisionsMethodDescriptor); + methodDescriptors.add(getPublisherMethodDescriptor); + methodDescriptors.add(listPublishersMethodDescriptor); + methodDescriptors.add(getAiApplicationMethodDescriptor); + methodDescriptors.add(listAiApplicationsMethodDescriptor); + methodDescriptors.add(getAiApplicationAgentMethodDescriptor); + methodDescriptors.add(listAiApplicationAgentsMethodDescriptor); + methodDescriptors.add(getAiApplicationMcpServerMethodDescriptor); + methodDescriptors.add(listAiApplicationMcpServersMethodDescriptor); + methodDescriptors.add(getFindingMethodDescriptor); + methodDescriptors.add(listFindingsMethodDescriptor); + methodDescriptors.add(getAiApplicationEndpointMethodDescriptor); + methodDescriptors.add(listAiApplicationEndpointsMethodDescriptor); + methodDescriptors.add(getSkillEncryptionSpecMethodDescriptor); + methodDescriptors.add(updateSkillEncryptionSpecMethodDescriptor); methodDescriptors.add(listLocationsMethodDescriptor); methodDescriptors.add(getLocationMethodDescriptor); return methodDescriptors; @@ -1616,6 +3133,222 @@ public UnaryCallable deleteBindingCallable() { return fetchAvailableBindingsPagedCallable; } + @Override + public UnaryCallable createSkillCallable() { + return createSkillCallable; + } + + @Override + public OperationCallable + createSkillOperationCallable() { + return createSkillOperationCallable; + } + + @Override + public UnaryCallable getSkillCallable() { + return getSkillCallable; + } + + @Override + public UnaryCallable updateSkillCallable() { + return updateSkillCallable; + } + + @Override + public OperationCallable + updateSkillOperationCallable() { + return updateSkillOperationCallable; + } + + @Override + public UnaryCallable deleteSkillCallable() { + return deleteSkillCallable; + } + + @Override + public OperationCallable + deleteSkillOperationCallable() { + return deleteSkillOperationCallable; + } + + @Override + public UnaryCallable listSkillsCallable() { + return listSkillsCallable; + } + + @Override + public UnaryCallable listSkillsPagedCallable() { + return listSkillsPagedCallable; + } + + @Override + public UnaryCallable searchSkillsCallable() { + return searchSkillsCallable; + } + + @Override + public UnaryCallable searchSkillsPagedCallable() { + return searchSkillsPagedCallable; + } + + @Override + public UnaryCallable createSkillRevisionCallable() { + return createSkillRevisionCallable; + } + + @Override + public OperationCallable + createSkillRevisionOperationCallable() { + return createSkillRevisionOperationCallable; + } + + @Override + public UnaryCallable getSkillRevisionCallable() { + return getSkillRevisionCallable; + } + + @Override + public UnaryCallable deleteSkillRevisionCallable() { + return deleteSkillRevisionCallable; + } + + @Override + public OperationCallable + deleteSkillRevisionOperationCallable() { + return deleteSkillRevisionOperationCallable; + } + + @Override + public UnaryCallable + listSkillRevisionsCallable() { + return listSkillRevisionsCallable; + } + + @Override + public UnaryCallable + listSkillRevisionsPagedCallable() { + return listSkillRevisionsPagedCallable; + } + + @Override + public UnaryCallable getPublisherCallable() { + return getPublisherCallable; + } + + @Override + public UnaryCallable listPublishersCallable() { + return listPublishersCallable; + } + + @Override + public UnaryCallable + listPublishersPagedCallable() { + return listPublishersPagedCallable; + } + + @Override + public UnaryCallable getAiApplicationCallable() { + return getAiApplicationCallable; + } + + @Override + public UnaryCallable + listAiApplicationsCallable() { + return listAiApplicationsCallable; + } + + @Override + public UnaryCallable + listAiApplicationsPagedCallable() { + return listAiApplicationsPagedCallable; + } + + @Override + public UnaryCallable getAiApplicationAgentCallable() { + return getAiApplicationAgentCallable; + } + + @Override + public UnaryCallable + listAiApplicationAgentsCallable() { + return listAiApplicationAgentsCallable; + } + + @Override + public UnaryCallable + listAiApplicationAgentsPagedCallable() { + return listAiApplicationAgentsPagedCallable; + } + + @Override + public UnaryCallable + getAiApplicationMcpServerCallable() { + return getAiApplicationMcpServerCallable; + } + + @Override + public UnaryCallable + listAiApplicationMcpServersCallable() { + return listAiApplicationMcpServersCallable; + } + + @Override + public UnaryCallable + listAiApplicationMcpServersPagedCallable() { + return listAiApplicationMcpServersPagedCallable; + } + + @Override + public UnaryCallable getFindingCallable() { + return getFindingCallable; + } + + @Override + public UnaryCallable listFindingsCallable() { + return listFindingsCallable; + } + + @Override + public UnaryCallable listFindingsPagedCallable() { + return listFindingsPagedCallable; + } + + @Override + public UnaryCallable + getAiApplicationEndpointCallable() { + return getAiApplicationEndpointCallable; + } + + @Override + public UnaryCallable + listAiApplicationEndpointsCallable() { + return listAiApplicationEndpointsCallable; + } + + @Override + public UnaryCallable + listAiApplicationEndpointsPagedCallable() { + return listAiApplicationEndpointsPagedCallable; + } + + @Override + public UnaryCallable + getSkillEncryptionSpecCallable() { + return getSkillEncryptionSpecCallable; + } + + @Override + public UnaryCallable + updateSkillEncryptionSpecCallable() { + return updateSkillEncryptionSpecCallable; + } + + @Override + public OperationCallable + updateSkillEncryptionSpecOperationCallable() { + return updateSkillEncryptionSpecOperationCallable; + } + @Override public UnaryCallable listLocationsCallable() { return listLocationsCallable; diff --git a/java-agentregistry/google-cloud-agentregistry/src/main/resources/META-INF/native-image/com.google.cloud.agentregistry.v1/reflect-config.json b/java-agentregistry/google-cloud-agentregistry/src/main/resources/META-INF/native-image/com.google.cloud.agentregistry.v1/reflect-config.json index 56a42f75c994..49f67b397dc7 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/main/resources/META-INF/native-image/com.google.cloud.agentregistry.v1/reflect-config.json +++ b/java-agentregistry/google-cloud-agentregistry/src/main/resources/META-INF/native-image/com.google.cloud.agentregistry.v1/reflect-config.json @@ -611,6 +611,51 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.agentregistry.v1.AiApplication", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.AiApplication$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.AiApplication$State", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ArchiveUploadSource", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ArchiveUploadSource$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.agentregistry.v1.Binding", "queryAllDeclaredConstructors": true, @@ -719,6 +764,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.agentregistry.v1.CreateSkillRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.CreateSkillRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.agentregistry.v1.DeleteBindingRequest", "queryAllDeclaredConstructors": true, @@ -755,6 +836,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.agentregistry.v1.DeleteSkillRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.DeleteSkillRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.agentregistry.v1.Endpoint", "queryAllDeclaredConstructors": true, @@ -810,7 +927,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.GetAgentRequest", + "name": "com.google.cloud.agentregistry.v1.Finding", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -819,7 +936,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.GetAgentRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.Finding$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -828,7 +945,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.GetBindingRequest", + "name": "com.google.cloud.agentregistry.v1.Finding$File", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -837,7 +954,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.GetBindingRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.Finding$File$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -846,7 +963,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.GetEndpointRequest", + "name": "com.google.cloud.agentregistry.v1.Finding$FindingClass", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -855,7 +972,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.GetEndpointRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.Frontmatter", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -864,7 +981,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.GetMcpServerRequest", + "name": "com.google.cloud.agentregistry.v1.Frontmatter$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -873,7 +990,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.GetMcpServerRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.GcsSource", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -882,7 +999,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.GetServiceRequest", + "name": "com.google.cloud.agentregistry.v1.GcsSource$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -891,7 +1008,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.GetServiceRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.GetAgentRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -900,7 +1017,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Interface", + "name": "com.google.cloud.agentregistry.v1.GetAgentRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -909,7 +1026,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Interface$Builder", + "name": "com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -918,7 +1035,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Interface$ProtocolBinding", + "name": "com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -927,7 +1044,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListAgentsRequest", + "name": "com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -936,7 +1053,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListAgentsRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -945,7 +1062,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListAgentsResponse", + "name": "com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -954,7 +1071,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListAgentsResponse$Builder", + "name": "com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -963,7 +1080,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListBindingsRequest", + "name": "com.google.cloud.agentregistry.v1.GetAiApplicationRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -972,7 +1089,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListBindingsRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.GetAiApplicationRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -981,7 +1098,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListBindingsResponse", + "name": "com.google.cloud.agentregistry.v1.GetBindingRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -990,7 +1107,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListBindingsResponse$Builder", + "name": "com.google.cloud.agentregistry.v1.GetBindingRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -999,7 +1116,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListEndpointsRequest", + "name": "com.google.cloud.agentregistry.v1.GetEndpointRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1008,7 +1125,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListEndpointsRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.GetEndpointRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1017,7 +1134,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListEndpointsResponse", + "name": "com.google.cloud.agentregistry.v1.GetFindingRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1026,7 +1143,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListEndpointsResponse$Builder", + "name": "com.google.cloud.agentregistry.v1.GetFindingRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1035,7 +1152,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListMcpServersRequest", + "name": "com.google.cloud.agentregistry.v1.GetMcpServerRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1044,7 +1161,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListMcpServersRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.GetMcpServerRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1053,7 +1170,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListMcpServersResponse", + "name": "com.google.cloud.agentregistry.v1.GetPublisherRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1062,7 +1179,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListMcpServersResponse$Builder", + "name": "com.google.cloud.agentregistry.v1.GetPublisherRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1071,7 +1188,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListServicesRequest", + "name": "com.google.cloud.agentregistry.v1.GetServiceRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1080,7 +1197,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListServicesRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.GetServiceRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1089,7 +1206,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListServicesResponse", + "name": "com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1098,7 +1215,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.ListServicesResponse$Builder", + "name": "com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1107,7 +1224,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.McpServer", + "name": "com.google.cloud.agentregistry.v1.GetSkillRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1116,7 +1233,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.McpServer$Builder", + "name": "com.google.cloud.agentregistry.v1.GetSkillRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1125,7 +1242,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.McpServer$Tool", + "name": "com.google.cloud.agentregistry.v1.GetSkillRevisionRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1134,7 +1251,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.McpServer$Tool$Annotations", + "name": "com.google.cloud.agentregistry.v1.GetSkillRevisionRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1143,7 +1260,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.McpServer$Tool$Annotations$Builder", + "name": "com.google.cloud.agentregistry.v1.Interface", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1152,7 +1269,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.McpServer$Tool$Builder", + "name": "com.google.cloud.agentregistry.v1.Interface$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1161,7 +1278,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.OperationMetadata", + "name": "com.google.cloud.agentregistry.v1.Interface$ProtocolBinding", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1170,7 +1287,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.OperationMetadata$Builder", + "name": "com.google.cloud.agentregistry.v1.ListAgentsRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1179,7 +1296,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.SearchAgentsRequest", + "name": "com.google.cloud.agentregistry.v1.ListAgentsRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1188,7 +1305,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.SearchAgentsRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.ListAgentsResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1197,7 +1314,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.SearchAgentsResponse", + "name": "com.google.cloud.agentregistry.v1.ListAgentsResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1206,7 +1323,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.SearchAgentsResponse$Builder", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1215,7 +1332,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.SearchMcpServersRequest", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1224,7 +1341,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.SearchMcpServersRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1233,7 +1350,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.SearchMcpServersResponse", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1242,7 +1359,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.SearchMcpServersResponse$Builder", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1251,7 +1368,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Service", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1260,7 +1377,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Service$AgentSpec", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1269,7 +1386,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Service$AgentSpec$Builder", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1278,7 +1395,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Service$AgentSpec$Type", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1287,7 +1404,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Service$Builder", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1296,7 +1413,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Service$EndpointSpec", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1305,7 +1422,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Service$EndpointSpec$Builder", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1314,7 +1431,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Service$EndpointSpec$Type", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationsRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1323,7 +1440,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Service$McpServerSpec", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationsRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1332,7 +1449,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Service$McpServerSpec$Builder", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationsResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1341,7 +1458,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.Service$McpServerSpec$Type", + "name": "com.google.cloud.agentregistry.v1.ListAiApplicationsResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1350,7 +1467,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.UpdateBindingRequest", + "name": "com.google.cloud.agentregistry.v1.ListBindingsRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1359,7 +1476,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.UpdateBindingRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.ListBindingsRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1368,7 +1485,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.UpdateServiceRequest", + "name": "com.google.cloud.agentregistry.v1.ListBindingsResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -1377,7 +1494,1078 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.agentregistry.v1.UpdateServiceRequest$Builder", + "name": "com.google.cloud.agentregistry.v1.ListBindingsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListEndpointsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListEndpointsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListEndpointsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListEndpointsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListFindingsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListFindingsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListFindingsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListFindingsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListMcpServersRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListMcpServersRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListMcpServersResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListMcpServersResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListPublishersRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListPublishersRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListPublishersResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListPublishersResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListServicesRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListServicesRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListServicesResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListServicesResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListSkillsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListSkillsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListSkillsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ListSkillsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.McpServer", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.McpServer$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.McpServer$Tool", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.McpServer$Tool$Annotations", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.McpServer$Tool$Annotations$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.McpServer$Tool$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.OperationMetadata", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.OperationMetadata$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Publisher", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Publisher$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Publisher$PublisherTier", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ScanningConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ScanningConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.ScanningConfig$Policy", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchAgentsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchAgentsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchAgentsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchAgentsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchMcpServersRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchMcpServersRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchMcpServersResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchMcpServersResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchSkillsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchSkillsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchSkillsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchSkillsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SearchType", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Service", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Service$AgentSpec", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Service$AgentSpec$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Service$AgentSpec$Type", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Service$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Service$EndpointSpec", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Service$EndpointSpec$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Service$EndpointSpec$Type", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Service$McpServerSpec", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Service$McpServerSpec$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Service$McpServerSpec$Type", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Severity", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Skill", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Skill$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Skill$State", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Skill$TargetState", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.Skill$Type", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SkillEncryptionSpec", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SkillEncryptionSpec$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SkillRevision", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SkillRevision$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SkillRevision$ScanResult", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SkillRevision$ScanResult$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SkillRevision$ScanResult$ScanState", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.SkillRevision$State", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.UpdateBindingRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.UpdateBindingRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.UpdateServiceRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.UpdateServiceRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.UpdateSkillRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.agentregistry.v1.UpdateSkillRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Application", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Application$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Application$State", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.ApplicationProperties", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.ApplicationProperties$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.ApplicationType", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.ApplicationType$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.ApplicationType$Type", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Attributes", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Attributes$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.ContactInfo", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.ContactInfo$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Criticality", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Criticality$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Criticality$Type", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Environment", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Environment$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Environment$Type", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.ExtendedMetadata", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.ExtendedMetadata$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.FunctionalType", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.FunctionalType$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.FunctionalType$Type", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Identity", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Identity$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.RegistrationType", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.RegistrationType$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.RegistrationType$Type", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Scope", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Scope$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apphub.v1.Scope$Type", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, diff --git a/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/AgentRegistryClientHttpJsonTest.java b/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/AgentRegistryClientHttpJsonTest.java index af744bb879bc..b517b029431f 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/AgentRegistryClientHttpJsonTest.java +++ b/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/AgentRegistryClientHttpJsonTest.java @@ -18,13 +18,22 @@ import static com.google.cloud.agentregistry.v1.AgentRegistryClient.FetchAvailableBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListFindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListLocationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListPublishersPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListServicesPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillRevisionsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchAgentsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchSkillsPagedResponse; import com.google.api.gax.core.NoCredentialsProvider; import com.google.api.gax.httpjson.GaxHttpJsonProperties; @@ -36,6 +45,8 @@ import com.google.api.gax.rpc.StatusCode; import com.google.api.gax.rpc.testing.FakeStatusCode; import com.google.cloud.agentregistry.v1.stub.HttpJsonAgentRegistryStub; +import com.google.cloud.apphub.v1.ApplicationProperties; +import com.google.cloud.apphub.v1.Attributes; import com.google.cloud.location.GetLocationRequest; import com.google.cloud.location.ListLocationsRequest; import com.google.cloud.location.ListLocationsResponse; @@ -300,7 +311,9 @@ public void searchAgentsExceptionTest2() throws Exception { public void getAgentTest() throws Exception { Agent expectedResponse = Agent.newBuilder() - .setName(AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]").toString()) + .setName( + AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]") + .toString()) .setAgentId("agentId-1060987136") .setLocation("location1901043637") .setDisplayName("displayName1714148973") @@ -316,7 +329,7 @@ public void getAgentTest() throws Exception { .build(); mockService.addResponse(expectedResponse); - AgentName name = AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]"); + AgentName name = AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]"); Agent actualResponse = client.getAgent(name); Assert.assertEquals(expectedResponse, actualResponse); @@ -344,7 +357,7 @@ public void getAgentExceptionTest() throws Exception { mockService.addException(exception); try { - AgentName name = AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]"); + AgentName name = AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]"); client.getAgent(name); Assert.fail("No exception raised"); } catch (InvalidArgumentException e) { @@ -356,7 +369,9 @@ public void getAgentExceptionTest() throws Exception { public void getAgentTest2() throws Exception { Agent expectedResponse = Agent.newBuilder() - .setName(AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]").toString()) + .setName( + AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]") + .toString()) .setAgentId("agentId-1060987136") .setLocation("location1901043637") .setDisplayName("displayName1714148973") @@ -512,7 +527,9 @@ public void listEndpointsExceptionTest2() throws Exception { public void getEndpointTest() throws Exception { Endpoint expectedResponse = Endpoint.newBuilder() - .setName(EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]").toString()) + .setName( + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) .setEndpointId("endpointId-1837754992") .setDisplayName("displayName1714148973") .setDescription("description-1724546052") @@ -523,7 +540,8 @@ public void getEndpointTest() throws Exception { .build(); mockService.addResponse(expectedResponse); - EndpointName name = EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]"); + EndpointName name = + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]"); Endpoint actualResponse = client.getEndpoint(name); Assert.assertEquals(expectedResponse, actualResponse); @@ -551,7 +569,8 @@ public void getEndpointExceptionTest() throws Exception { mockService.addException(exception); try { - EndpointName name = EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]"); + EndpointName name = + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]"); client.getEndpoint(name); Assert.fail("No exception raised"); } catch (InvalidArgumentException e) { @@ -563,7 +582,9 @@ public void getEndpointExceptionTest() throws Exception { public void getEndpointTest2() throws Exception { Endpoint expectedResponse = Endpoint.newBuilder() - .setName(EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]").toString()) + .setName( + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) .setEndpointId("endpointId-1837754992") .setDisplayName("displayName1714148973") .setDescription("description-1724546052") @@ -814,7 +835,10 @@ public void searchMcpServersExceptionTest2() throws Exception { public void getMcpServerTest() throws Exception { McpServer expectedResponse = McpServer.newBuilder() - .setName(McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]").toString()) + .setName( + McpServerName.ofProjectLocationMcpServerName( + "[PROJECT]", "[LOCATION]", "[MCP_SERVER]") + .toString()) .setMcpServerId("mcpServerId298140536") .setDisplayName("displayName1714148973") .setDescription("description-1724546052") @@ -826,7 +850,8 @@ public void getMcpServerTest() throws Exception { .build(); mockService.addResponse(expectedResponse); - McpServerName name = McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]"); + McpServerName name = + McpServerName.ofProjectLocationMcpServerName("[PROJECT]", "[LOCATION]", "[MCP_SERVER]"); McpServer actualResponse = client.getMcpServer(name); Assert.assertEquals(expectedResponse, actualResponse); @@ -854,7 +879,8 @@ public void getMcpServerExceptionTest() throws Exception { mockService.addException(exception); try { - McpServerName name = McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]"); + McpServerName name = + McpServerName.ofProjectLocationMcpServerName("[PROJECT]", "[LOCATION]", "[MCP_SERVER]"); client.getMcpServer(name); Assert.fail("No exception raised"); } catch (InvalidArgumentException e) { @@ -866,7 +892,10 @@ public void getMcpServerExceptionTest() throws Exception { public void getMcpServerTest2() throws Exception { McpServer expectedResponse = McpServer.newBuilder() - .setName(McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]").toString()) + .setName( + McpServerName.ofProjectLocationMcpServerName( + "[PROJECT]", "[LOCATION]", "[MCP_SERVER]") + .toString()) .setMcpServerId("mcpServerId298140536") .setDisplayName("displayName1714148973") .setDescription("description-1724546052") @@ -1980,6 +2009,2449 @@ public void fetchAvailableBindingsExceptionTest2() throws Exception { } } + @Test + public void createSkillTest() throws Exception { + Skill expectedResponse = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createSkillTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Skill skill = Skill.newBuilder().build(); + String skillId = "skillId2147320652"; + + Skill actualResponse = client.createSkillAsync(parent, skill, skillId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createSkillExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Skill skill = Skill.newBuilder().build(); + String skillId = "skillId2147320652"; + client.createSkillAsync(parent, skill, skillId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void createSkillTest2() throws Exception { + Skill expectedResponse = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createSkillTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String parent = "projects/project-5833/locations/location-5833"; + Skill skill = Skill.newBuilder().build(); + String skillId = "skillId2147320652"; + + Skill actualResponse = client.createSkillAsync(parent, skill, skillId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createSkillExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + Skill skill = Skill.newBuilder().build(); + String skillId = "skillId2147320652"; + client.createSkillAsync(parent, skill, skillId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void getSkillTest() throws Exception { + Skill expectedResponse = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + + Skill actualResponse = client.getSkill(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getSkillExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + client.getSkill(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getSkillTest2() throws Exception { + Skill expectedResponse = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-9310/locations/location-9310/skills/skill-9310"; + + Skill actualResponse = client.getSkill(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getSkillExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-9310/locations/location-9310/skills/skill-9310"; + client.getSkill(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateSkillTest() throws Exception { + Skill expectedResponse = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateSkillTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + Skill skill = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Skill actualResponse = client.updateSkillAsync(skill, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void updateSkillExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + Skill skill = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]") + .toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateSkillAsync(skill, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteSkillTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteSkillTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + + client.deleteSkillAsync(name).get(); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteSkillExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + client.deleteSkillAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteSkillTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteSkillTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String name = "projects/project-9310/locations/location-9310/skills/skill-9310"; + + client.deleteSkillAsync(name).get(); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteSkillExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-9310/locations/location-9310/skills/skill-9310"; + client.deleteSkillAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void listSkillsTest() throws Exception { + Skill responsesElement = Skill.newBuilder().build(); + ListSkillsResponse expectedResponse = + ListSkillsResponse.newBuilder() + .setNextPageToken("") + .addAllSkills(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListSkillsPagedResponse pagedListResponse = client.listSkills(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSkillsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listSkillsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listSkills(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listSkillsTest2() throws Exception { + Skill responsesElement = Skill.newBuilder().build(); + ListSkillsResponse expectedResponse = + ListSkillsResponse.newBuilder() + .setNextPageToken("") + .addAllSkills(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + + ListSkillsPagedResponse pagedListResponse = client.listSkills(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSkillsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listSkillsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + client.listSkills(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void searchSkillsTest() throws Exception { + Skill responsesElement = Skill.newBuilder().build(); + SearchSkillsResponse expectedResponse = + SearchSkillsResponse.newBuilder() + .setNextPageToken("") + .addAllSkills(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + SearchSkillsRequest request = + SearchSkillsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setSearchType(SearchType.forNumber(0)) + .setSearchString("searchString120312793") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + + SearchSkillsPagedResponse pagedListResponse = client.searchSkills(request); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSkillsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void searchSkillsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + SearchSkillsRequest request = + SearchSkillsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setSearchType(SearchType.forNumber(0)) + .setSearchString("searchString120312793") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + client.searchSkills(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createSkillRevisionTest() throws Exception { + SkillRevision expectedResponse = + SkillRevision.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setSha256Hash("sha256Hash127958997") + .setFrontmatter(Frontmatter.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setSizeBytes(-1796325715) + .setUid("uid115792") + .setScanResult(SkillRevision.ScanResult.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createSkillRevisionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + SkillRevision skillRevision = SkillRevision.newBuilder().build(); + String skillRevisionId = "skillRevisionId-983110777"; + + SkillRevision actualResponse = + client.createSkillRevisionAsync(parent, skillRevision, skillRevisionId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createSkillRevisionExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + SkillRevision skillRevision = SkillRevision.newBuilder().build(); + String skillRevisionId = "skillRevisionId-983110777"; + client.createSkillRevisionAsync(parent, skillRevision, skillRevisionId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void createSkillRevisionTest2() throws Exception { + SkillRevision expectedResponse = + SkillRevision.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setSha256Hash("sha256Hash127958997") + .setFrontmatter(Frontmatter.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setSizeBytes(-1796325715) + .setUid("uid115792") + .setScanResult(SkillRevision.ScanResult.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createSkillRevisionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String parent = "projects/project-4787/locations/location-4787/skills/skill-4787"; + SkillRevision skillRevision = SkillRevision.newBuilder().build(); + String skillRevisionId = "skillRevisionId-983110777"; + + SkillRevision actualResponse = + client.createSkillRevisionAsync(parent, skillRevision, skillRevisionId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createSkillRevisionExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-4787/locations/location-4787/skills/skill-4787"; + SkillRevision skillRevision = SkillRevision.newBuilder().build(); + String skillRevisionId = "skillRevisionId-983110777"; + client.createSkillRevisionAsync(parent, skillRevision, skillRevisionId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void getSkillRevisionTest() throws Exception { + SkillRevision expectedResponse = + SkillRevision.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setSha256Hash("sha256Hash127958997") + .setFrontmatter(Frontmatter.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setSizeBytes(-1796325715) + .setUid("uid115792") + .setScanResult(SkillRevision.ScanResult.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + SkillRevisionName name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]"); + + SkillRevision actualResponse = client.getSkillRevision(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getSkillRevisionExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + SkillRevisionName name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]"); + client.getSkillRevision(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getSkillRevisionTest2() throws Exception { + SkillRevision expectedResponse = + SkillRevision.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setSha256Hash("sha256Hash127958997") + .setFrontmatter(Frontmatter.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setSizeBytes(-1796325715) + .setUid("uid115792") + .setScanResult(SkillRevision.ScanResult.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-9446/locations/location-9446/skills/skill-9446/revisions/revision-9446"; + + SkillRevision actualResponse = client.getSkillRevision(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getSkillRevisionExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-9446/locations/location-9446/skills/skill-9446/revisions/revision-9446"; + client.getSkillRevision(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteSkillRevisionTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteSkillRevisionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + SkillRevisionName name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]"); + + client.deleteSkillRevisionAsync(name).get(); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteSkillRevisionExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + SkillRevisionName name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]"); + client.deleteSkillRevisionAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteSkillRevisionTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteSkillRevisionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String name = + "projects/project-9446/locations/location-9446/skills/skill-9446/revisions/revision-9446"; + + client.deleteSkillRevisionAsync(name).get(); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteSkillRevisionExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-9446/locations/location-9446/skills/skill-9446/revisions/revision-9446"; + client.deleteSkillRevisionAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void listSkillRevisionsTest() throws Exception { + SkillRevision responsesElement = SkillRevision.newBuilder().build(); + ListSkillRevisionsResponse expectedResponse = + ListSkillRevisionsResponse.newBuilder() + .setNextPageToken("") + .addAllSkillRevisions(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + + ListSkillRevisionsPagedResponse pagedListResponse = client.listSkillRevisions(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSkillRevisionsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listSkillRevisionsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + client.listSkillRevisions(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listSkillRevisionsTest2() throws Exception { + SkillRevision responsesElement = SkillRevision.newBuilder().build(); + ListSkillRevisionsResponse expectedResponse = + ListSkillRevisionsResponse.newBuilder() + .setNextPageToken("") + .addAllSkillRevisions(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-4787/locations/location-4787/skills/skill-4787"; + + ListSkillRevisionsPagedResponse pagedListResponse = client.listSkillRevisions(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSkillRevisionsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listSkillRevisionsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-4787/locations/location-4787/skills/skill-4787"; + client.listSkillRevisions(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getPublisherTest() throws Exception { + Publisher expectedResponse = + Publisher.newBuilder() + .setName(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setVerifiedPrefix("verifiedPrefix250185594") + .setDisplayName("displayName1714148973") + .setDocumentationUri("documentationUri-1487620014") + .setSupportUri("supportUri-613906659") + .build(); + mockService.addResponse(expectedResponse); + + PublisherName name = PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]"); + + Publisher actualResponse = client.getPublisher(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getPublisherExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + PublisherName name = PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]"); + client.getPublisher(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getPublisherTest2() throws Exception { + Publisher expectedResponse = + Publisher.newBuilder() + .setName(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setVerifiedPrefix("verifiedPrefix250185594") + .setDisplayName("displayName1714148973") + .setDocumentationUri("documentationUri-1487620014") + .setSupportUri("supportUri-613906659") + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-6489/locations/location-6489/publishers/publisher-6489"; + + Publisher actualResponse = client.getPublisher(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getPublisherExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-6489/locations/location-6489/publishers/publisher-6489"; + client.getPublisher(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listPublishersTest() throws Exception { + Publisher responsesElement = Publisher.newBuilder().build(); + ListPublishersResponse expectedResponse = + ListPublishersResponse.newBuilder() + .setNextPageToken("") + .addAllPublishers(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListPublishersPagedResponse pagedListResponse = client.listPublishers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getPublishersList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listPublishersExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listPublishers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listPublishersTest2() throws Exception { + Publisher responsesElement = Publisher.newBuilder().build(); + ListPublishersResponse expectedResponse = + ListPublishersResponse.newBuilder() + .setNextPageToken("") + .addAllPublishers(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + + ListPublishersPagedResponse pagedListResponse = client.listPublishers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getPublishersList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listPublishersExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + client.listPublishers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationTest() throws Exception { + AiApplication expectedResponse = + AiApplication.newBuilder() + .setName(AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setAttributes(Attributes.newBuilder().build()) + .setApplicationProperties(ApplicationProperties.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + AiApplicationName name = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + + AiApplication actualResponse = client.getAiApplication(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getAiApplicationExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + AiApplicationName name = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + client.getAiApplication(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationTest2() throws Exception { + AiApplication expectedResponse = + AiApplication.newBuilder() + .setName(AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setAttributes(Attributes.newBuilder().build()) + .setApplicationProperties(ApplicationProperties.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-8741/locations/location-8741/aiApplications/aiApplication-8741"; + + AiApplication actualResponse = client.getAiApplication(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getAiApplicationExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-8741/locations/location-8741/aiApplications/aiApplication-8741"; + client.getAiApplication(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationsTest() throws Exception { + AiApplication responsesElement = AiApplication.newBuilder().build(); + ListAiApplicationsResponse expectedResponse = + ListAiApplicationsResponse.newBuilder() + .setNextPageToken("") + .addAllAiApplications(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListAiApplicationsPagedResponse pagedListResponse = client.listAiApplications(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAiApplicationsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listAiApplicationsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listAiApplications(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationsTest2() throws Exception { + AiApplication responsesElement = AiApplication.newBuilder().build(); + ListAiApplicationsResponse expectedResponse = + ListAiApplicationsResponse.newBuilder() + .setNextPageToken("") + .addAllAiApplications(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + + ListAiApplicationsPagedResponse pagedListResponse = client.listAiApplications(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAiApplicationsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listAiApplicationsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + client.listAiApplications(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationAgentTest() throws Exception { + Agent expectedResponse = + Agent.newBuilder() + .setName( + AgentName.ofProjectLocationAiApplicationAgentName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]") + .toString()) + .setAgentId("agentId-1060987136") + .setLocation("location1901043637") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setVersion("version351608024") + .addAllProtocols(new ArrayList()) + .addAllSkills(new ArrayList()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .setCard(Agent.Card.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + AgentName name = + AgentName.ofProjectLocationAiApplicationAgentName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]"); + + Agent actualResponse = client.getAiApplicationAgent(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getAiApplicationAgentExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + AgentName name = + AgentName.ofProjectLocationAiApplicationAgentName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]"); + client.getAiApplicationAgent(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationAgentTest2() throws Exception { + Agent expectedResponse = + Agent.newBuilder() + .setName( + AgentName.ofProjectLocationAiApplicationAgentName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]") + .toString()) + .setAgentId("agentId-1060987136") + .setLocation("location1901043637") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setVersion("version351608024") + .addAllProtocols(new ArrayList()) + .addAllSkills(new ArrayList()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .setCard(Agent.Card.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-9267/locations/location-9267/aiApplications/aiApplication-9267/agents/agent-9267"; + + Agent actualResponse = client.getAiApplicationAgent(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getAiApplicationAgentExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-9267/locations/location-9267/aiApplications/aiApplication-9267/agents/agent-9267"; + client.getAiApplicationAgent(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationAgentsTest() throws Exception { + Agent responsesElement = Agent.newBuilder().build(); + ListAiApplicationAgentsResponse expectedResponse = + ListAiApplicationAgentsResponse.newBuilder() + .setNextPageToken("") + .addAllAgents(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + AiApplicationName parent = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + + ListAiApplicationAgentsPagedResponse pagedListResponse = client.listAiApplicationAgents(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAgentsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listAiApplicationAgentsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + AiApplicationName parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + client.listAiApplicationAgents(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationAgentsTest2() throws Exception { + Agent responsesElement = Agent.newBuilder().build(); + ListAiApplicationAgentsResponse expectedResponse = + ListAiApplicationAgentsResponse.newBuilder() + .setNextPageToken("") + .addAllAgents(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = + "projects/project-6948/locations/location-6948/aiApplications/aiApplication-6948"; + + ListAiApplicationAgentsPagedResponse pagedListResponse = client.listAiApplicationAgents(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAgentsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listAiApplicationAgentsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = + "projects/project-6948/locations/location-6948/aiApplications/aiApplication-6948"; + client.listAiApplicationAgents(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationMcpServerTest() throws Exception { + McpServer expectedResponse = + McpServer.newBuilder() + .setName( + McpServerName.ofProjectLocationAiApplicationMcpServerName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]") + .toString()) + .setMcpServerId("mcpServerId298140536") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .addAllInterfaces(new ArrayList()) + .addAllTools(new ArrayList()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .build(); + mockService.addResponse(expectedResponse); + + McpServerName name = + McpServerName.ofProjectLocationAiApplicationMcpServerName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]"); + + McpServer actualResponse = client.getAiApplicationMcpServer(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getAiApplicationMcpServerExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + McpServerName name = + McpServerName.ofProjectLocationAiApplicationMcpServerName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]"); + client.getAiApplicationMcpServer(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationMcpServerTest2() throws Exception { + McpServer expectedResponse = + McpServer.newBuilder() + .setName( + McpServerName.ofProjectLocationAiApplicationMcpServerName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]") + .toString()) + .setMcpServerId("mcpServerId298140536") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .addAllInterfaces(new ArrayList()) + .addAllTools(new ArrayList()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-6507/locations/location-6507/aiApplications/aiApplication-6507/mcpServers/mcpServer-6507"; + + McpServer actualResponse = client.getAiApplicationMcpServer(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getAiApplicationMcpServerExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-6507/locations/location-6507/aiApplications/aiApplication-6507/mcpServers/mcpServer-6507"; + client.getAiApplicationMcpServer(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationMcpServersTest() throws Exception { + McpServer responsesElement = McpServer.newBuilder().build(); + ListAiApplicationMcpServersResponse expectedResponse = + ListAiApplicationMcpServersResponse.newBuilder() + .setNextPageToken("") + .addAllMcpServers(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + AiApplicationName parent = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + + ListAiApplicationMcpServersPagedResponse pagedListResponse = + client.listAiApplicationMcpServers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getMcpServersList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listAiApplicationMcpServersExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + AiApplicationName parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + client.listAiApplicationMcpServers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationMcpServersTest2() throws Exception { + McpServer responsesElement = McpServer.newBuilder().build(); + ListAiApplicationMcpServersResponse expectedResponse = + ListAiApplicationMcpServersResponse.newBuilder() + .setNextPageToken("") + .addAllMcpServers(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = + "projects/project-6948/locations/location-6948/aiApplications/aiApplication-6948"; + + ListAiApplicationMcpServersPagedResponse pagedListResponse = + client.listAiApplicationMcpServers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getMcpServersList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listAiApplicationMcpServersExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = + "projects/project-6948/locations/location-6948/aiApplications/aiApplication-6948"; + client.listAiApplicationMcpServers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getFindingTest() throws Exception { + Finding expectedResponse = + Finding.newBuilder() + .setName(FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSeverity(Severity.forNumber(0)) + .addAllFiles(new ArrayList()) + .setDetail("detail-1335224239") + .setResource("resource-341064690") + .build(); + mockService.addResponse(expectedResponse); + + FindingName name = FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]"); + + Finding actualResponse = client.getFinding(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getFindingExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + FindingName name = FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]"); + client.getFinding(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getFindingTest2() throws Exception { + Finding expectedResponse = + Finding.newBuilder() + .setName(FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSeverity(Severity.forNumber(0)) + .addAllFiles(new ArrayList()) + .setDetail("detail-1335224239") + .setResource("resource-341064690") + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-1658/locations/location-1658/findings/finding-1658"; + + Finding actualResponse = client.getFinding(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getFindingExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-1658/locations/location-1658/findings/finding-1658"; + client.getFinding(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listFindingsTest() throws Exception { + Finding responsesElement = Finding.newBuilder().build(); + ListFindingsResponse expectedResponse = + ListFindingsResponse.newBuilder() + .setNextPageToken("") + .addAllFindings(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListFindingsPagedResponse pagedListResponse = client.listFindings(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getFindingsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listFindingsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listFindings(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listFindingsTest2() throws Exception { + Finding responsesElement = Finding.newBuilder().build(); + ListFindingsResponse expectedResponse = + ListFindingsResponse.newBuilder() + .setNextPageToken("") + .addAllFindings(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + + ListFindingsPagedResponse pagedListResponse = client.listFindings(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getFindingsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listFindingsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + client.listFindings(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationEndpointTest() throws Exception { + Endpoint expectedResponse = + Endpoint.newBuilder() + .setName( + EndpointName.ofProjectLocationAiApplicationEndpointName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]") + .toString()) + .setEndpointId("endpointId-1837754992") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .addAllInterfaces(new ArrayList()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .build(); + mockService.addResponse(expectedResponse); + + EndpointName name = + EndpointName.ofProjectLocationAiApplicationEndpointName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]"); + + Endpoint actualResponse = client.getAiApplicationEndpoint(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getAiApplicationEndpointExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + EndpointName name = + EndpointName.ofProjectLocationAiApplicationEndpointName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]"); + client.getAiApplicationEndpoint(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationEndpointTest2() throws Exception { + Endpoint expectedResponse = + Endpoint.newBuilder() + .setName( + EndpointName.ofProjectLocationAiApplicationEndpointName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]") + .toString()) + .setEndpointId("endpointId-1837754992") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .addAllInterfaces(new ArrayList()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-5947/locations/location-5947/aiApplications/aiApplication-5947/endpoints/endpoint-5947"; + + Endpoint actualResponse = client.getAiApplicationEndpoint(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getAiApplicationEndpointExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-5947/locations/location-5947/aiApplications/aiApplication-5947/endpoints/endpoint-5947"; + client.getAiApplicationEndpoint(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationEndpointsTest() throws Exception { + Endpoint responsesElement = Endpoint.newBuilder().build(); + ListAiApplicationEndpointsResponse expectedResponse = + ListAiApplicationEndpointsResponse.newBuilder() + .setNextPageToken("") + .addAllEndpoints(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + AiApplicationName parent = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + + ListAiApplicationEndpointsPagedResponse pagedListResponse = + client.listAiApplicationEndpoints(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getEndpointsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listAiApplicationEndpointsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + AiApplicationName parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + client.listAiApplicationEndpoints(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationEndpointsTest2() throws Exception { + Endpoint responsesElement = Endpoint.newBuilder().build(); + ListAiApplicationEndpointsResponse expectedResponse = + ListAiApplicationEndpointsResponse.newBuilder() + .setNextPageToken("") + .addAllEndpoints(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = + "projects/project-6948/locations/location-6948/aiApplications/aiApplication-6948"; + + ListAiApplicationEndpointsPagedResponse pagedListResponse = + client.listAiApplicationEndpoints(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getEndpointsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listAiApplicationEndpointsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = + "projects/project-6948/locations/location-6948/aiApplications/aiApplication-6948"; + client.listAiApplicationEndpoints(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getSkillEncryptionSpecTest() throws Exception { + SkillEncryptionSpec expectedResponse = + SkillEncryptionSpec.newBuilder() + .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) + .setCryptoKeyName("cryptoKeyName1447084425") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + SkillEncryptionSpecName name = SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]"); + + SkillEncryptionSpec actualResponse = client.getSkillEncryptionSpec(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getSkillEncryptionSpecExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + SkillEncryptionSpecName name = SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]"); + client.getSkillEncryptionSpec(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getSkillEncryptionSpecTest2() throws Exception { + SkillEncryptionSpec expectedResponse = + SkillEncryptionSpec.newBuilder() + .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) + .setCryptoKeyName("cryptoKeyName1447084425") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-2502/locations/location-2502/skillEncryptionSpec"; + + SkillEncryptionSpec actualResponse = client.getSkillEncryptionSpec(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getSkillEncryptionSpecExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-2502/locations/location-2502/skillEncryptionSpec"; + client.getSkillEncryptionSpec(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateSkillEncryptionSpecTest() throws Exception { + SkillEncryptionSpec expectedResponse = + SkillEncryptionSpec.newBuilder() + .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) + .setCryptoKeyName("cryptoKeyName1447084425") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateSkillEncryptionSpecTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + SkillEncryptionSpec skillEncryptionSpec = + SkillEncryptionSpec.newBuilder() + .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) + .setCryptoKeyName("cryptoKeyName1447084425") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + SkillEncryptionSpec actualResponse = + client.updateSkillEncryptionSpecAsync(skillEncryptionSpec, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void updateSkillEncryptionSpecExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + SkillEncryptionSpec skillEncryptionSpec = + SkillEncryptionSpec.newBuilder() + .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) + .setCryptoKeyName("cryptoKeyName1447084425") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateSkillEncryptionSpecAsync(skillEncryptionSpec, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + @Test public void listLocationsTest() throws Exception { Location responsesElement = Location.newBuilder().build(); diff --git a/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/AgentRegistryClientTest.java b/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/AgentRegistryClientTest.java index 80f6d7eb86f1..a1a9ee191471 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/AgentRegistryClientTest.java +++ b/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/AgentRegistryClientTest.java @@ -18,13 +18,22 @@ import static com.google.cloud.agentregistry.v1.AgentRegistryClient.FetchAvailableBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationAgentsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListAiApplicationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListBindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListEndpointsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListFindingsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListLocationsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListPublishersPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListServicesPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillRevisionsPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.ListSkillsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchAgentsPagedResponse; import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchMcpServersPagedResponse; +import static com.google.cloud.agentregistry.v1.AgentRegistryClient.SearchSkillsPagedResponse; import com.google.api.gax.core.NoCredentialsProvider; import com.google.api.gax.grpc.GaxGrpcProperties; @@ -34,6 +43,8 @@ import com.google.api.gax.rpc.ApiClientHeaderProvider; import com.google.api.gax.rpc.InvalidArgumentException; import com.google.api.gax.rpc.StatusCode; +import com.google.cloud.apphub.v1.ApplicationProperties; +import com.google.cloud.apphub.v1.Attributes; import com.google.cloud.location.GetLocationRequest; import com.google.cloud.location.ListLocationsRequest; import com.google.cloud.location.ListLocationsResponse; @@ -283,7 +294,9 @@ public void searchAgentsExceptionTest2() throws Exception { public void getAgentTest() throws Exception { Agent expectedResponse = Agent.newBuilder() - .setName(AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]").toString()) + .setName( + AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]") + .toString()) .setAgentId("agentId-1060987136") .setLocation("location1901043637") .setDisplayName("displayName1714148973") @@ -299,7 +312,7 @@ public void getAgentTest() throws Exception { .build(); mockAgentRegistry.addResponse(expectedResponse); - AgentName name = AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]"); + AgentName name = AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]"); Agent actualResponse = client.getAgent(name); Assert.assertEquals(expectedResponse, actualResponse); @@ -321,7 +334,7 @@ public void getAgentExceptionTest() throws Exception { mockAgentRegistry.addException(exception); try { - AgentName name = AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]"); + AgentName name = AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]"); client.getAgent(name); Assert.fail("No exception raised"); } catch (InvalidArgumentException e) { @@ -333,7 +346,9 @@ public void getAgentExceptionTest() throws Exception { public void getAgentTest2() throws Exception { Agent expectedResponse = Agent.newBuilder() - .setName(AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]").toString()) + .setName( + AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]") + .toString()) .setAgentId("agentId-1060987136") .setLocation("location1901043637") .setDisplayName("displayName1714148973") @@ -471,7 +486,9 @@ public void listEndpointsExceptionTest2() throws Exception { public void getEndpointTest() throws Exception { Endpoint expectedResponse = Endpoint.newBuilder() - .setName(EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]").toString()) + .setName( + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) .setEndpointId("endpointId-1837754992") .setDisplayName("displayName1714148973") .setDescription("description-1724546052") @@ -482,7 +499,8 @@ public void getEndpointTest() throws Exception { .build(); mockAgentRegistry.addResponse(expectedResponse); - EndpointName name = EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]"); + EndpointName name = + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]"); Endpoint actualResponse = client.getEndpoint(name); Assert.assertEquals(expectedResponse, actualResponse); @@ -504,7 +522,8 @@ public void getEndpointExceptionTest() throws Exception { mockAgentRegistry.addException(exception); try { - EndpointName name = EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]"); + EndpointName name = + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]"); client.getEndpoint(name); Assert.fail("No exception raised"); } catch (InvalidArgumentException e) { @@ -516,7 +535,9 @@ public void getEndpointExceptionTest() throws Exception { public void getEndpointTest2() throws Exception { Endpoint expectedResponse = Endpoint.newBuilder() - .setName(EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]").toString()) + .setName( + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) .setEndpointId("endpointId-1837754992") .setDisplayName("displayName1714148973") .setDescription("description-1724546052") @@ -737,7 +758,10 @@ public void searchMcpServersExceptionTest2() throws Exception { public void getMcpServerTest() throws Exception { McpServer expectedResponse = McpServer.newBuilder() - .setName(McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]").toString()) + .setName( + McpServerName.ofProjectLocationMcpServerName( + "[PROJECT]", "[LOCATION]", "[MCP_SERVER]") + .toString()) .setMcpServerId("mcpServerId298140536") .setDisplayName("displayName1714148973") .setDescription("description-1724546052") @@ -749,7 +773,8 @@ public void getMcpServerTest() throws Exception { .build(); mockAgentRegistry.addResponse(expectedResponse); - McpServerName name = McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]"); + McpServerName name = + McpServerName.ofProjectLocationMcpServerName("[PROJECT]", "[LOCATION]", "[MCP_SERVER]"); McpServer actualResponse = client.getMcpServer(name); Assert.assertEquals(expectedResponse, actualResponse); @@ -771,7 +796,8 @@ public void getMcpServerExceptionTest() throws Exception { mockAgentRegistry.addException(exception); try { - McpServerName name = McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]"); + McpServerName name = + McpServerName.ofProjectLocationMcpServerName("[PROJECT]", "[LOCATION]", "[MCP_SERVER]"); client.getMcpServer(name); Assert.fail("No exception raised"); } catch (InvalidArgumentException e) { @@ -783,7 +809,10 @@ public void getMcpServerExceptionTest() throws Exception { public void getMcpServerTest2() throws Exception { McpServer expectedResponse = McpServer.newBuilder() - .setName(McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]").toString()) + .setName( + McpServerName.ofProjectLocationMcpServerName( + "[PROJECT]", "[LOCATION]", "[MCP_SERVER]") + .toString()) .setMcpServerId("mcpServerId298140536") .setDisplayName("displayName1714148973") .setDescription("description-1724546052") @@ -1777,6 +1806,2179 @@ public void fetchAvailableBindingsExceptionTest2() throws Exception { } } + @Test + public void createSkillTest() throws Exception { + Skill expectedResponse = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createSkillTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentRegistry.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Skill skill = Skill.newBuilder().build(); + String skillId = "skillId2147320652"; + + Skill actualResponse = client.createSkillAsync(parent, skill, skillId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateSkillRequest actualRequest = ((CreateSkillRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(skill, actualRequest.getSkill()); + Assert.assertEquals(skillId, actualRequest.getSkillId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createSkillExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Skill skill = Skill.newBuilder().build(); + String skillId = "skillId2147320652"; + client.createSkillAsync(parent, skill, skillId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void createSkillTest2() throws Exception { + Skill expectedResponse = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createSkillTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentRegistry.addResponse(resultOperation); + + String parent = "parent-995424086"; + Skill skill = Skill.newBuilder().build(); + String skillId = "skillId2147320652"; + + Skill actualResponse = client.createSkillAsync(parent, skill, skillId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateSkillRequest actualRequest = ((CreateSkillRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(skill, actualRequest.getSkill()); + Assert.assertEquals(skillId, actualRequest.getSkillId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createSkillExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String parent = "parent-995424086"; + Skill skill = Skill.newBuilder().build(); + String skillId = "skillId2147320652"; + client.createSkillAsync(parent, skill, skillId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void getSkillTest() throws Exception { + Skill expectedResponse = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + + Skill actualResponse = client.getSkill(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetSkillRequest actualRequest = ((GetSkillRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getSkillExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + client.getSkill(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getSkillTest2() throws Exception { + Skill expectedResponse = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String name = "name3373707"; + + Skill actualResponse = client.getSkill(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetSkillRequest actualRequest = ((GetSkillRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getSkillExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String name = "name3373707"; + client.getSkill(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateSkillTest() throws Exception { + Skill expectedResponse = + Skill.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefaultRevision( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setFrontmatter(Frontmatter.newBuilder().build()) + .setSkillId("skillId2147320652") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setPublisher(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setInitialRevision(SkillRevision.newBuilder().build()) + .setScanningConfig(ScanningConfig.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateSkillTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentRegistry.addResponse(resultOperation); + + Skill skill = Skill.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Skill actualResponse = client.updateSkillAsync(skill, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateSkillRequest actualRequest = ((UpdateSkillRequest) actualRequests.get(0)); + + Assert.assertEquals(skill, actualRequest.getSkill()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateSkillExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + Skill skill = Skill.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateSkillAsync(skill, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteSkillTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteSkillTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentRegistry.addResponse(resultOperation); + + SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + + client.deleteSkillAsync(name).get(); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteSkillRequest actualRequest = ((DeleteSkillRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteSkillExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + client.deleteSkillAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteSkillTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteSkillTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentRegistry.addResponse(resultOperation); + + String name = "name3373707"; + + client.deleteSkillAsync(name).get(); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteSkillRequest actualRequest = ((DeleteSkillRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteSkillExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String name = "name3373707"; + client.deleteSkillAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void listSkillsTest() throws Exception { + Skill responsesElement = Skill.newBuilder().build(); + ListSkillsResponse expectedResponse = + ListSkillsResponse.newBuilder() + .setNextPageToken("") + .addAllSkills(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListSkillsPagedResponse pagedListResponse = client.listSkills(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSkillsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListSkillsRequest actualRequest = ((ListSkillsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listSkillsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listSkills(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listSkillsTest2() throws Exception { + Skill responsesElement = Skill.newBuilder().build(); + ListSkillsResponse expectedResponse = + ListSkillsResponse.newBuilder() + .setNextPageToken("") + .addAllSkills(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListSkillsPagedResponse pagedListResponse = client.listSkills(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSkillsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListSkillsRequest actualRequest = ((ListSkillsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listSkillsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String parent = "parent-995424086"; + client.listSkills(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void searchSkillsTest() throws Exception { + Skill responsesElement = Skill.newBuilder().build(); + SearchSkillsResponse expectedResponse = + SearchSkillsResponse.newBuilder() + .setNextPageToken("") + .addAllSkills(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + SearchSkillsRequest request = + SearchSkillsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setSearchType(SearchType.forNumber(0)) + .setSearchString("searchString120312793") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + + SearchSkillsPagedResponse pagedListResponse = client.searchSkills(request); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSkillsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + SearchSkillsRequest actualRequest = ((SearchSkillsRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getParent(), actualRequest.getParent()); + Assert.assertEquals(request.getSearchType(), actualRequest.getSearchType()); + Assert.assertEquals(request.getSearchString(), actualRequest.getSearchString()); + Assert.assertEquals(request.getFilter(), actualRequest.getFilter()); + Assert.assertEquals(request.getPageSize(), actualRequest.getPageSize()); + Assert.assertEquals(request.getPageToken(), actualRequest.getPageToken()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void searchSkillsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + SearchSkillsRequest request = + SearchSkillsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setSearchType(SearchType.forNumber(0)) + .setSearchString("searchString120312793") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + client.searchSkills(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createSkillRevisionTest() throws Exception { + SkillRevision expectedResponse = + SkillRevision.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setSha256Hash("sha256Hash127958997") + .setFrontmatter(Frontmatter.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setSizeBytes(-1796325715) + .setUid("uid115792") + .setScanResult(SkillRevision.ScanResult.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createSkillRevisionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentRegistry.addResponse(resultOperation); + + SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + SkillRevision skillRevision = SkillRevision.newBuilder().build(); + String skillRevisionId = "skillRevisionId-983110777"; + + SkillRevision actualResponse = + client.createSkillRevisionAsync(parent, skillRevision, skillRevisionId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateSkillRevisionRequest actualRequest = ((CreateSkillRevisionRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(skillRevision, actualRequest.getSkillRevision()); + Assert.assertEquals(skillRevisionId, actualRequest.getSkillRevisionId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createSkillRevisionExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + SkillRevision skillRevision = SkillRevision.newBuilder().build(); + String skillRevisionId = "skillRevisionId-983110777"; + client.createSkillRevisionAsync(parent, skillRevision, skillRevisionId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void createSkillRevisionTest2() throws Exception { + SkillRevision expectedResponse = + SkillRevision.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setSha256Hash("sha256Hash127958997") + .setFrontmatter(Frontmatter.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setSizeBytes(-1796325715) + .setUid("uid115792") + .setScanResult(SkillRevision.ScanResult.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createSkillRevisionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentRegistry.addResponse(resultOperation); + + String parent = "parent-995424086"; + SkillRevision skillRevision = SkillRevision.newBuilder().build(); + String skillRevisionId = "skillRevisionId-983110777"; + + SkillRevision actualResponse = + client.createSkillRevisionAsync(parent, skillRevision, skillRevisionId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateSkillRevisionRequest actualRequest = ((CreateSkillRevisionRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(skillRevision, actualRequest.getSkillRevision()); + Assert.assertEquals(skillRevisionId, actualRequest.getSkillRevisionId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createSkillRevisionExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String parent = "parent-995424086"; + SkillRevision skillRevision = SkillRevision.newBuilder().build(); + String skillRevisionId = "skillRevisionId-983110777"; + client.createSkillRevisionAsync(parent, skillRevision, skillRevisionId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void getSkillRevisionTest() throws Exception { + SkillRevision expectedResponse = + SkillRevision.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setSha256Hash("sha256Hash127958997") + .setFrontmatter(Frontmatter.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setSizeBytes(-1796325715) + .setUid("uid115792") + .setScanResult(SkillRevision.ScanResult.newBuilder().build()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + SkillRevisionName name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]"); + + SkillRevision actualResponse = client.getSkillRevision(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetSkillRevisionRequest actualRequest = ((GetSkillRevisionRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getSkillRevisionExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + SkillRevisionName name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]"); + client.getSkillRevision(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getSkillRevisionTest2() throws Exception { + SkillRevision expectedResponse = + SkillRevision.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString()) + .setSha256Hash("sha256Hash127958997") + .setFrontmatter(Frontmatter.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setSizeBytes(-1796325715) + .setUid("uid115792") + .setScanResult(SkillRevision.ScanResult.newBuilder().build()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String name = "name3373707"; + + SkillRevision actualResponse = client.getSkillRevision(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetSkillRevisionRequest actualRequest = ((GetSkillRevisionRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getSkillRevisionExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String name = "name3373707"; + client.getSkillRevision(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteSkillRevisionTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteSkillRevisionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentRegistry.addResponse(resultOperation); + + SkillRevisionName name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]"); + + client.deleteSkillRevisionAsync(name).get(); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteSkillRevisionRequest actualRequest = ((DeleteSkillRevisionRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteSkillRevisionExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + SkillRevisionName name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]"); + client.deleteSkillRevisionAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteSkillRevisionTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteSkillRevisionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentRegistry.addResponse(resultOperation); + + String name = "name3373707"; + + client.deleteSkillRevisionAsync(name).get(); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteSkillRevisionRequest actualRequest = ((DeleteSkillRevisionRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteSkillRevisionExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String name = "name3373707"; + client.deleteSkillRevisionAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void listSkillRevisionsTest() throws Exception { + SkillRevision responsesElement = SkillRevision.newBuilder().build(); + ListSkillRevisionsResponse expectedResponse = + ListSkillRevisionsResponse.newBuilder() + .setNextPageToken("") + .addAllSkillRevisions(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + + ListSkillRevisionsPagedResponse pagedListResponse = client.listSkillRevisions(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSkillRevisionsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListSkillRevisionsRequest actualRequest = ((ListSkillRevisionsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listSkillRevisionsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + client.listSkillRevisions(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listSkillRevisionsTest2() throws Exception { + SkillRevision responsesElement = SkillRevision.newBuilder().build(); + ListSkillRevisionsResponse expectedResponse = + ListSkillRevisionsResponse.newBuilder() + .setNextPageToken("") + .addAllSkillRevisions(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListSkillRevisionsPagedResponse pagedListResponse = client.listSkillRevisions(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSkillRevisionsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListSkillRevisionsRequest actualRequest = ((ListSkillRevisionsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listSkillRevisionsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String parent = "parent-995424086"; + client.listSkillRevisions(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getPublisherTest() throws Exception { + Publisher expectedResponse = + Publisher.newBuilder() + .setName(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setVerifiedPrefix("verifiedPrefix250185594") + .setDisplayName("displayName1714148973") + .setDocumentationUri("documentationUri-1487620014") + .setSupportUri("supportUri-613906659") + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + PublisherName name = PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]"); + + Publisher actualResponse = client.getPublisher(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetPublisherRequest actualRequest = ((GetPublisherRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getPublisherExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + PublisherName name = PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]"); + client.getPublisher(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getPublisherTest2() throws Exception { + Publisher expectedResponse = + Publisher.newBuilder() + .setName(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .setVerifiedPrefix("verifiedPrefix250185594") + .setDisplayName("displayName1714148973") + .setDocumentationUri("documentationUri-1487620014") + .setSupportUri("supportUri-613906659") + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String name = "name3373707"; + + Publisher actualResponse = client.getPublisher(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetPublisherRequest actualRequest = ((GetPublisherRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getPublisherExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String name = "name3373707"; + client.getPublisher(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listPublishersTest() throws Exception { + Publisher responsesElement = Publisher.newBuilder().build(); + ListPublishersResponse expectedResponse = + ListPublishersResponse.newBuilder() + .setNextPageToken("") + .addAllPublishers(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListPublishersPagedResponse pagedListResponse = client.listPublishers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getPublishersList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListPublishersRequest actualRequest = ((ListPublishersRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listPublishersExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listPublishers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listPublishersTest2() throws Exception { + Publisher responsesElement = Publisher.newBuilder().build(); + ListPublishersResponse expectedResponse = + ListPublishersResponse.newBuilder() + .setNextPageToken("") + .addAllPublishers(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListPublishersPagedResponse pagedListResponse = client.listPublishers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getPublishersList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListPublishersRequest actualRequest = ((ListPublishersRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listPublishersExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String parent = "parent-995424086"; + client.listPublishers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationTest() throws Exception { + AiApplication expectedResponse = + AiApplication.newBuilder() + .setName(AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setAttributes(Attributes.newBuilder().build()) + .setApplicationProperties(ApplicationProperties.newBuilder().build()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + AiApplicationName name = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + + AiApplication actualResponse = client.getAiApplication(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAiApplicationRequest actualRequest = ((GetAiApplicationRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAiApplicationExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + AiApplicationName name = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + client.getAiApplication(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationTest2() throws Exception { + AiApplication expectedResponse = + AiApplication.newBuilder() + .setName(AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setAttributes(Attributes.newBuilder().build()) + .setApplicationProperties(ApplicationProperties.newBuilder().build()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String name = "name3373707"; + + AiApplication actualResponse = client.getAiApplication(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAiApplicationRequest actualRequest = ((GetAiApplicationRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAiApplicationExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String name = "name3373707"; + client.getAiApplication(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationsTest() throws Exception { + AiApplication responsesElement = AiApplication.newBuilder().build(); + ListAiApplicationsResponse expectedResponse = + ListAiApplicationsResponse.newBuilder() + .setNextPageToken("") + .addAllAiApplications(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListAiApplicationsPagedResponse pagedListResponse = client.listAiApplications(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAiApplicationsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAiApplicationsRequest actualRequest = ((ListAiApplicationsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAiApplicationsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listAiApplications(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationsTest2() throws Exception { + AiApplication responsesElement = AiApplication.newBuilder().build(); + ListAiApplicationsResponse expectedResponse = + ListAiApplicationsResponse.newBuilder() + .setNextPageToken("") + .addAllAiApplications(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListAiApplicationsPagedResponse pagedListResponse = client.listAiApplications(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAiApplicationsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAiApplicationsRequest actualRequest = ((ListAiApplicationsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAiApplicationsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String parent = "parent-995424086"; + client.listAiApplications(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationAgentTest() throws Exception { + Agent expectedResponse = + Agent.newBuilder() + .setName( + AgentName.ofProjectLocationAiApplicationAgentName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]") + .toString()) + .setAgentId("agentId-1060987136") + .setLocation("location1901043637") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setVersion("version351608024") + .addAllProtocols(new ArrayList()) + .addAllSkills(new ArrayList()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .setCard(Agent.Card.newBuilder().build()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + AgentName name = + AgentName.ofProjectLocationAiApplicationAgentName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]"); + + Agent actualResponse = client.getAiApplicationAgent(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAiApplicationAgentRequest actualRequest = + ((GetAiApplicationAgentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAiApplicationAgentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + AgentName name = + AgentName.ofProjectLocationAiApplicationAgentName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]"); + client.getAiApplicationAgent(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationAgentTest2() throws Exception { + Agent expectedResponse = + Agent.newBuilder() + .setName( + AgentName.ofProjectLocationAiApplicationAgentName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]") + .toString()) + .setAgentId("agentId-1060987136") + .setLocation("location1901043637") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setVersion("version351608024") + .addAllProtocols(new ArrayList()) + .addAllSkills(new ArrayList()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .setCard(Agent.Card.newBuilder().build()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String name = "name3373707"; + + Agent actualResponse = client.getAiApplicationAgent(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAiApplicationAgentRequest actualRequest = + ((GetAiApplicationAgentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAiApplicationAgentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String name = "name3373707"; + client.getAiApplicationAgent(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationAgentsTest() throws Exception { + Agent responsesElement = Agent.newBuilder().build(); + ListAiApplicationAgentsResponse expectedResponse = + ListAiApplicationAgentsResponse.newBuilder() + .setNextPageToken("") + .addAllAgents(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + AiApplicationName parent = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + + ListAiApplicationAgentsPagedResponse pagedListResponse = client.listAiApplicationAgents(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAgentsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAiApplicationAgentsRequest actualRequest = + ((ListAiApplicationAgentsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAiApplicationAgentsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + AiApplicationName parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + client.listAiApplicationAgents(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationAgentsTest2() throws Exception { + Agent responsesElement = Agent.newBuilder().build(); + ListAiApplicationAgentsResponse expectedResponse = + ListAiApplicationAgentsResponse.newBuilder() + .setNextPageToken("") + .addAllAgents(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListAiApplicationAgentsPagedResponse pagedListResponse = client.listAiApplicationAgents(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAgentsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAiApplicationAgentsRequest actualRequest = + ((ListAiApplicationAgentsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAiApplicationAgentsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String parent = "parent-995424086"; + client.listAiApplicationAgents(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationMcpServerTest() throws Exception { + McpServer expectedResponse = + McpServer.newBuilder() + .setName( + McpServerName.ofProjectLocationAiApplicationMcpServerName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]") + .toString()) + .setMcpServerId("mcpServerId298140536") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .addAllInterfaces(new ArrayList()) + .addAllTools(new ArrayList()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + McpServerName name = + McpServerName.ofProjectLocationAiApplicationMcpServerName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]"); + + McpServer actualResponse = client.getAiApplicationMcpServer(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAiApplicationMcpServerRequest actualRequest = + ((GetAiApplicationMcpServerRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAiApplicationMcpServerExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + McpServerName name = + McpServerName.ofProjectLocationAiApplicationMcpServerName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]"); + client.getAiApplicationMcpServer(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationMcpServerTest2() throws Exception { + McpServer expectedResponse = + McpServer.newBuilder() + .setName( + McpServerName.ofProjectLocationAiApplicationMcpServerName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]") + .toString()) + .setMcpServerId("mcpServerId298140536") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .addAllInterfaces(new ArrayList()) + .addAllTools(new ArrayList()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String name = "name3373707"; + + McpServer actualResponse = client.getAiApplicationMcpServer(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAiApplicationMcpServerRequest actualRequest = + ((GetAiApplicationMcpServerRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAiApplicationMcpServerExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String name = "name3373707"; + client.getAiApplicationMcpServer(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationMcpServersTest() throws Exception { + McpServer responsesElement = McpServer.newBuilder().build(); + ListAiApplicationMcpServersResponse expectedResponse = + ListAiApplicationMcpServersResponse.newBuilder() + .setNextPageToken("") + .addAllMcpServers(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + AiApplicationName parent = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + + ListAiApplicationMcpServersPagedResponse pagedListResponse = + client.listAiApplicationMcpServers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getMcpServersList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAiApplicationMcpServersRequest actualRequest = + ((ListAiApplicationMcpServersRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAiApplicationMcpServersExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + AiApplicationName parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + client.listAiApplicationMcpServers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationMcpServersTest2() throws Exception { + McpServer responsesElement = McpServer.newBuilder().build(); + ListAiApplicationMcpServersResponse expectedResponse = + ListAiApplicationMcpServersResponse.newBuilder() + .setNextPageToken("") + .addAllMcpServers(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListAiApplicationMcpServersPagedResponse pagedListResponse = + client.listAiApplicationMcpServers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getMcpServersList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAiApplicationMcpServersRequest actualRequest = + ((ListAiApplicationMcpServersRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAiApplicationMcpServersExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String parent = "parent-995424086"; + client.listAiApplicationMcpServers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getFindingTest() throws Exception { + Finding expectedResponse = + Finding.newBuilder() + .setName(FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSeverity(Severity.forNumber(0)) + .addAllFiles(new ArrayList()) + .setDetail("detail-1335224239") + .setResource("resource-341064690") + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + FindingName name = FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]"); + + Finding actualResponse = client.getFinding(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetFindingRequest actualRequest = ((GetFindingRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getFindingExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + FindingName name = FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]"); + client.getFinding(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getFindingTest2() throws Exception { + Finding expectedResponse = + Finding.newBuilder() + .setName(FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSeverity(Severity.forNumber(0)) + .addAllFiles(new ArrayList()) + .setDetail("detail-1335224239") + .setResource("resource-341064690") + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String name = "name3373707"; + + Finding actualResponse = client.getFinding(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetFindingRequest actualRequest = ((GetFindingRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getFindingExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String name = "name3373707"; + client.getFinding(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listFindingsTest() throws Exception { + Finding responsesElement = Finding.newBuilder().build(); + ListFindingsResponse expectedResponse = + ListFindingsResponse.newBuilder() + .setNextPageToken("") + .addAllFindings(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListFindingsPagedResponse pagedListResponse = client.listFindings(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getFindingsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListFindingsRequest actualRequest = ((ListFindingsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listFindingsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listFindings(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listFindingsTest2() throws Exception { + Finding responsesElement = Finding.newBuilder().build(); + ListFindingsResponse expectedResponse = + ListFindingsResponse.newBuilder() + .setNextPageToken("") + .addAllFindings(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListFindingsPagedResponse pagedListResponse = client.listFindings(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getFindingsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListFindingsRequest actualRequest = ((ListFindingsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listFindingsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String parent = "parent-995424086"; + client.listFindings(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationEndpointTest() throws Exception { + Endpoint expectedResponse = + Endpoint.newBuilder() + .setName( + EndpointName.ofProjectLocationAiApplicationEndpointName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]") + .toString()) + .setEndpointId("endpointId-1837754992") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .addAllInterfaces(new ArrayList()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + EndpointName name = + EndpointName.ofProjectLocationAiApplicationEndpointName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]"); + + Endpoint actualResponse = client.getAiApplicationEndpoint(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAiApplicationEndpointRequest actualRequest = + ((GetAiApplicationEndpointRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAiApplicationEndpointExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + EndpointName name = + EndpointName.ofProjectLocationAiApplicationEndpointName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]"); + client.getAiApplicationEndpoint(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAiApplicationEndpointTest2() throws Exception { + Endpoint expectedResponse = + Endpoint.newBuilder() + .setName( + EndpointName.ofProjectLocationAiApplicationEndpointName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]") + .toString()) + .setEndpointId("endpointId-1837754992") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .addAllInterfaces(new ArrayList()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllAttributes(new HashMap()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String name = "name3373707"; + + Endpoint actualResponse = client.getAiApplicationEndpoint(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAiApplicationEndpointRequest actualRequest = + ((GetAiApplicationEndpointRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAiApplicationEndpointExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String name = "name3373707"; + client.getAiApplicationEndpoint(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationEndpointsTest() throws Exception { + Endpoint responsesElement = Endpoint.newBuilder().build(); + ListAiApplicationEndpointsResponse expectedResponse = + ListAiApplicationEndpointsResponse.newBuilder() + .setNextPageToken("") + .addAllEndpoints(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + AiApplicationName parent = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + + ListAiApplicationEndpointsPagedResponse pagedListResponse = + client.listAiApplicationEndpoints(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getEndpointsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAiApplicationEndpointsRequest actualRequest = + ((ListAiApplicationEndpointsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAiApplicationEndpointsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + AiApplicationName parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + client.listAiApplicationEndpoints(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAiApplicationEndpointsTest2() throws Exception { + Endpoint responsesElement = Endpoint.newBuilder().build(); + ListAiApplicationEndpointsResponse expectedResponse = + ListAiApplicationEndpointsResponse.newBuilder() + .setNextPageToken("") + .addAllEndpoints(Arrays.asList(responsesElement)) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListAiApplicationEndpointsPagedResponse pagedListResponse = + client.listAiApplicationEndpoints(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getEndpointsList().get(0), resources.get(0)); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAiApplicationEndpointsRequest actualRequest = + ((ListAiApplicationEndpointsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAiApplicationEndpointsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String parent = "parent-995424086"; + client.listAiApplicationEndpoints(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getSkillEncryptionSpecTest() throws Exception { + SkillEncryptionSpec expectedResponse = + SkillEncryptionSpec.newBuilder() + .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) + .setCryptoKeyName("cryptoKeyName1447084425") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + SkillEncryptionSpecName name = SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]"); + + SkillEncryptionSpec actualResponse = client.getSkillEncryptionSpec(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetSkillEncryptionSpecRequest actualRequest = + ((GetSkillEncryptionSpecRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getSkillEncryptionSpecExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + SkillEncryptionSpecName name = SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]"); + client.getSkillEncryptionSpec(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getSkillEncryptionSpecTest2() throws Exception { + SkillEncryptionSpec expectedResponse = + SkillEncryptionSpec.newBuilder() + .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) + .setCryptoKeyName("cryptoKeyName1447084425") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + mockAgentRegistry.addResponse(expectedResponse); + + String name = "name3373707"; + + SkillEncryptionSpec actualResponse = client.getSkillEncryptionSpec(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetSkillEncryptionSpecRequest actualRequest = + ((GetSkillEncryptionSpecRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getSkillEncryptionSpecExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + String name = "name3373707"; + client.getSkillEncryptionSpec(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateSkillEncryptionSpecTest() throws Exception { + SkillEncryptionSpec expectedResponse = + SkillEncryptionSpec.newBuilder() + .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) + .setCryptoKeyName("cryptoKeyName1447084425") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateSkillEncryptionSpecTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentRegistry.addResponse(resultOperation); + + SkillEncryptionSpec skillEncryptionSpec = SkillEncryptionSpec.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + SkillEncryptionSpec actualResponse = + client.updateSkillEncryptionSpecAsync(skillEncryptionSpec, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentRegistry.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateSkillEncryptionSpecRequest actualRequest = + ((UpdateSkillEncryptionSpecRequest) actualRequests.get(0)); + + Assert.assertEquals(skillEncryptionSpec, actualRequest.getSkillEncryptionSpec()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateSkillEncryptionSpecExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentRegistry.addException(exception); + + try { + SkillEncryptionSpec skillEncryptionSpec = SkillEncryptionSpec.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateSkillEncryptionSpecAsync(skillEncryptionSpec, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + @Test public void listLocationsTest() throws Exception { Location responsesElement = Location.newBuilder().build(); diff --git a/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/MockAgentRegistryImpl.java b/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/MockAgentRegistryImpl.java index cd5da34ee8a4..04b40abda5db 100644 --- a/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/MockAgentRegistryImpl.java +++ b/java-agentregistry/google-cloud-agentregistry/src/test/java/com/google/cloud/agentregistry/v1/MockAgentRegistryImpl.java @@ -455,4 +455,516 @@ public void fetchAvailableBindings( Exception.class.getName()))); } } + + @Override + public void createSkill(CreateSkillRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method CreateSkill, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getSkill(GetSkillRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Skill) { + requests.add(request); + responseObserver.onNext(((Skill) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetSkill, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Skill.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void updateSkill(UpdateSkillRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method UpdateSkill, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteSkill(DeleteSkillRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method DeleteSkill, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listSkills( + ListSkillsRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListSkillsResponse) { + requests.add(request); + responseObserver.onNext(((ListSkillsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListSkills, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListSkillsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void searchSkills( + SearchSkillsRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof SearchSkillsResponse) { + requests.add(request); + responseObserver.onNext(((SearchSkillsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method SearchSkills, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + SearchSkillsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void createSkillRevision( + CreateSkillRevisionRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method CreateSkillRevision, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getSkillRevision( + GetSkillRevisionRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof SkillRevision) { + requests.add(request); + responseObserver.onNext(((SkillRevision) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetSkillRevision, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + SkillRevision.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteSkillRevision( + DeleteSkillRevisionRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method DeleteSkillRevision, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listSkillRevisions( + ListSkillRevisionsRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListSkillRevisionsResponse) { + requests.add(request); + responseObserver.onNext(((ListSkillRevisionsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListSkillRevisions, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListSkillRevisionsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getPublisher( + GetPublisherRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Publisher) { + requests.add(request); + responseObserver.onNext(((Publisher) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetPublisher, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Publisher.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listPublishers( + ListPublishersRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListPublishersResponse) { + requests.add(request); + responseObserver.onNext(((ListPublishersResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListPublishers, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListPublishersResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getAiApplication( + GetAiApplicationRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof AiApplication) { + requests.add(request); + responseObserver.onNext(((AiApplication) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetAiApplication, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + AiApplication.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listAiApplications( + ListAiApplicationsRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListAiApplicationsResponse) { + requests.add(request); + responseObserver.onNext(((ListAiApplicationsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListAiApplications, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListAiApplicationsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getAiApplicationAgent( + GetAiApplicationAgentRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Agent) { + requests.add(request); + responseObserver.onNext(((Agent) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetAiApplicationAgent, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + Agent.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listAiApplicationAgents( + ListAiApplicationAgentsRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListAiApplicationAgentsResponse) { + requests.add(request); + responseObserver.onNext(((ListAiApplicationAgentsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListAiApplicationAgents, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + ListAiApplicationAgentsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getAiApplicationMcpServer( + GetAiApplicationMcpServerRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof McpServer) { + requests.add(request); + responseObserver.onNext(((McpServer) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetAiApplicationMcpServer, expected %s" + + " or %s", + response == null ? "null" : response.getClass().getName(), + McpServer.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listAiApplicationMcpServers( + ListAiApplicationMcpServersRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListAiApplicationMcpServersResponse) { + requests.add(request); + responseObserver.onNext(((ListAiApplicationMcpServersResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListAiApplicationMcpServers, expected" + + " %s or %s", + response == null ? "null" : response.getClass().getName(), + ListAiApplicationMcpServersResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getFinding(GetFindingRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Finding) { + requests.add(request); + responseObserver.onNext(((Finding) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetFinding, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Finding.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listFindings( + ListFindingsRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListFindingsResponse) { + requests.add(request); + responseObserver.onNext(((ListFindingsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListFindings, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListFindingsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getAiApplicationEndpoint( + GetAiApplicationEndpointRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Endpoint) { + requests.add(request); + responseObserver.onNext(((Endpoint) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetAiApplicationEndpoint, expected %s" + + " or %s", + response == null ? "null" : response.getClass().getName(), + Endpoint.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listAiApplicationEndpoints( + ListAiApplicationEndpointsRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListAiApplicationEndpointsResponse) { + requests.add(request); + responseObserver.onNext(((ListAiApplicationEndpointsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListAiApplicationEndpoints, expected %s" + + " or %s", + response == null ? "null" : response.getClass().getName(), + ListAiApplicationEndpointsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getSkillEncryptionSpec( + GetSkillEncryptionSpecRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof SkillEncryptionSpec) { + requests.add(request); + responseObserver.onNext(((SkillEncryptionSpec) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetSkillEncryptionSpec, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + SkillEncryptionSpec.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void updateSkillEncryptionSpec( + UpdateSkillEncryptionSpecRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method UpdateSkillEncryptionSpec, expected %s" + + " or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } } diff --git a/java-agentregistry/grpc-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryGrpc.java b/java-agentregistry/grpc-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryGrpc.java index 45abe3ea6a14..c54a91ff4e78 100644 --- a/java-agentregistry/grpc-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryGrpc.java +++ b/java-agentregistry/grpc-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryGrpc.java @@ -21,7 +21,7 @@ * * *

- * Service for managing Agents, Endpoints, McpServers, Services, and Bindings.
+ * Service for managing Agent Registry resources.
  * 
*/ @io.grpc.stub.annotations.GrpcGenerated @@ -900,6 +900,1140 @@ private AgentRegistryGrpc() {} return getFetchAvailableBindingsMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.CreateSkillRequest, com.google.longrunning.Operation> + getCreateSkillMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateSkill", + requestType = com.google.cloud.agentregistry.v1.CreateSkillRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.CreateSkillRequest, com.google.longrunning.Operation> + getCreateSkillMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.CreateSkillRequest, com.google.longrunning.Operation> + getCreateSkillMethod; + if ((getCreateSkillMethod = AgentRegistryGrpc.getCreateSkillMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getCreateSkillMethod = AgentRegistryGrpc.getCreateSkillMethod) == null) { + AgentRegistryGrpc.getCreateSkillMethod = + getCreateSkillMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateSkill")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.CreateSkillRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new AgentRegistryMethodDescriptorSupplier("CreateSkill")) + .build(); + } + } + } + return getCreateSkillMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetSkillRequest, + com.google.cloud.agentregistry.v1.Skill> + getGetSkillMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetSkill", + requestType = com.google.cloud.agentregistry.v1.GetSkillRequest.class, + responseType = com.google.cloud.agentregistry.v1.Skill.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetSkillRequest, + com.google.cloud.agentregistry.v1.Skill> + getGetSkillMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetSkillRequest, + com.google.cloud.agentregistry.v1.Skill> + getGetSkillMethod; + if ((getGetSkillMethod = AgentRegistryGrpc.getGetSkillMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getGetSkillMethod = AgentRegistryGrpc.getGetSkillMethod) == null) { + AgentRegistryGrpc.getGetSkillMethod = + getGetSkillMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetSkill")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.GetSkillRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.Skill.getDefaultInstance())) + .setSchemaDescriptor(new AgentRegistryMethodDescriptorSupplier("GetSkill")) + .build(); + } + } + } + return getGetSkillMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.UpdateSkillRequest, com.google.longrunning.Operation> + getUpdateSkillMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateSkill", + requestType = com.google.cloud.agentregistry.v1.UpdateSkillRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.UpdateSkillRequest, com.google.longrunning.Operation> + getUpdateSkillMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.UpdateSkillRequest, com.google.longrunning.Operation> + getUpdateSkillMethod; + if ((getUpdateSkillMethod = AgentRegistryGrpc.getUpdateSkillMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getUpdateSkillMethod = AgentRegistryGrpc.getUpdateSkillMethod) == null) { + AgentRegistryGrpc.getUpdateSkillMethod = + getUpdateSkillMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateSkill")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.UpdateSkillRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new AgentRegistryMethodDescriptorSupplier("UpdateSkill")) + .build(); + } + } + } + return getUpdateSkillMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.DeleteSkillRequest, com.google.longrunning.Operation> + getDeleteSkillMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteSkill", + requestType = com.google.cloud.agentregistry.v1.DeleteSkillRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.DeleteSkillRequest, com.google.longrunning.Operation> + getDeleteSkillMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.DeleteSkillRequest, com.google.longrunning.Operation> + getDeleteSkillMethod; + if ((getDeleteSkillMethod = AgentRegistryGrpc.getDeleteSkillMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getDeleteSkillMethod = AgentRegistryGrpc.getDeleteSkillMethod) == null) { + AgentRegistryGrpc.getDeleteSkillMethod = + getDeleteSkillMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteSkill")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.DeleteSkillRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new AgentRegistryMethodDescriptorSupplier("DeleteSkill")) + .build(); + } + } + } + return getDeleteSkillMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListSkillsRequest, + com.google.cloud.agentregistry.v1.ListSkillsResponse> + getListSkillsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListSkills", + requestType = com.google.cloud.agentregistry.v1.ListSkillsRequest.class, + responseType = com.google.cloud.agentregistry.v1.ListSkillsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListSkillsRequest, + com.google.cloud.agentregistry.v1.ListSkillsResponse> + getListSkillsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListSkillsRequest, + com.google.cloud.agentregistry.v1.ListSkillsResponse> + getListSkillsMethod; + if ((getListSkillsMethod = AgentRegistryGrpc.getListSkillsMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getListSkillsMethod = AgentRegistryGrpc.getListSkillsMethod) == null) { + AgentRegistryGrpc.getListSkillsMethod = + getListSkillsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListSkills")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListSkillsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListSkillsResponse + .getDefaultInstance())) + .setSchemaDescriptor(new AgentRegistryMethodDescriptorSupplier("ListSkills")) + .build(); + } + } + } + return getListSkillsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.SearchSkillsRequest, + com.google.cloud.agentregistry.v1.SearchSkillsResponse> + getSearchSkillsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "SearchSkills", + requestType = com.google.cloud.agentregistry.v1.SearchSkillsRequest.class, + responseType = com.google.cloud.agentregistry.v1.SearchSkillsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.SearchSkillsRequest, + com.google.cloud.agentregistry.v1.SearchSkillsResponse> + getSearchSkillsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.SearchSkillsRequest, + com.google.cloud.agentregistry.v1.SearchSkillsResponse> + getSearchSkillsMethod; + if ((getSearchSkillsMethod = AgentRegistryGrpc.getSearchSkillsMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getSearchSkillsMethod = AgentRegistryGrpc.getSearchSkillsMethod) == null) { + AgentRegistryGrpc.getSearchSkillsMethod = + getSearchSkillsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "SearchSkills")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.SearchSkillsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.SearchSkillsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("SearchSkills")) + .build(); + } + } + } + return getSearchSkillsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest, + com.google.longrunning.Operation> + getCreateSkillRevisionMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateSkillRevision", + requestType = com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest, + com.google.longrunning.Operation> + getCreateSkillRevisionMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest, + com.google.longrunning.Operation> + getCreateSkillRevisionMethod; + if ((getCreateSkillRevisionMethod = AgentRegistryGrpc.getCreateSkillRevisionMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getCreateSkillRevisionMethod = AgentRegistryGrpc.getCreateSkillRevisionMethod) + == null) { + AgentRegistryGrpc.getCreateSkillRevisionMethod = + getCreateSkillRevisionMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "CreateSkillRevision")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("CreateSkillRevision")) + .build(); + } + } + } + return getCreateSkillRevisionMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest, + com.google.cloud.agentregistry.v1.SkillRevision> + getGetSkillRevisionMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetSkillRevision", + requestType = com.google.cloud.agentregistry.v1.GetSkillRevisionRequest.class, + responseType = com.google.cloud.agentregistry.v1.SkillRevision.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest, + com.google.cloud.agentregistry.v1.SkillRevision> + getGetSkillRevisionMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest, + com.google.cloud.agentregistry.v1.SkillRevision> + getGetSkillRevisionMethod; + if ((getGetSkillRevisionMethod = AgentRegistryGrpc.getGetSkillRevisionMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getGetSkillRevisionMethod = AgentRegistryGrpc.getGetSkillRevisionMethod) == null) { + AgentRegistryGrpc.getGetSkillRevisionMethod = + getGetSkillRevisionMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetSkillRevision")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("GetSkillRevision")) + .build(); + } + } + } + return getGetSkillRevisionMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest, + com.google.longrunning.Operation> + getDeleteSkillRevisionMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteSkillRevision", + requestType = com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest, + com.google.longrunning.Operation> + getDeleteSkillRevisionMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest, + com.google.longrunning.Operation> + getDeleteSkillRevisionMethod; + if ((getDeleteSkillRevisionMethod = AgentRegistryGrpc.getDeleteSkillRevisionMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getDeleteSkillRevisionMethod = AgentRegistryGrpc.getDeleteSkillRevisionMethod) + == null) { + AgentRegistryGrpc.getDeleteSkillRevisionMethod = + getDeleteSkillRevisionMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "DeleteSkillRevision")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("DeleteSkillRevision")) + .build(); + } + } + } + return getDeleteSkillRevisionMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest, + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse> + getListSkillRevisionsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListSkillRevisions", + requestType = com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest.class, + responseType = com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest, + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse> + getListSkillRevisionsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest, + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse> + getListSkillRevisionsMethod; + if ((getListSkillRevisionsMethod = AgentRegistryGrpc.getListSkillRevisionsMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getListSkillRevisionsMethod = AgentRegistryGrpc.getListSkillRevisionsMethod) == null) { + AgentRegistryGrpc.getListSkillRevisionsMethod = + getListSkillRevisionsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListSkillRevisions")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("ListSkillRevisions")) + .build(); + } + } + } + return getListSkillRevisionsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetPublisherRequest, + com.google.cloud.agentregistry.v1.Publisher> + getGetPublisherMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetPublisher", + requestType = com.google.cloud.agentregistry.v1.GetPublisherRequest.class, + responseType = com.google.cloud.agentregistry.v1.Publisher.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetPublisherRequest, + com.google.cloud.agentregistry.v1.Publisher> + getGetPublisherMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetPublisherRequest, + com.google.cloud.agentregistry.v1.Publisher> + getGetPublisherMethod; + if ((getGetPublisherMethod = AgentRegistryGrpc.getGetPublisherMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getGetPublisherMethod = AgentRegistryGrpc.getGetPublisherMethod) == null) { + AgentRegistryGrpc.getGetPublisherMethod = + getGetPublisherMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetPublisher")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.GetPublisherRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.Publisher.getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("GetPublisher")) + .build(); + } + } + } + return getGetPublisherMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListPublishersRequest, + com.google.cloud.agentregistry.v1.ListPublishersResponse> + getListPublishersMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListPublishers", + requestType = com.google.cloud.agentregistry.v1.ListPublishersRequest.class, + responseType = com.google.cloud.agentregistry.v1.ListPublishersResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListPublishersRequest, + com.google.cloud.agentregistry.v1.ListPublishersResponse> + getListPublishersMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListPublishersRequest, + com.google.cloud.agentregistry.v1.ListPublishersResponse> + getListPublishersMethod; + if ((getListPublishersMethod = AgentRegistryGrpc.getListPublishersMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getListPublishersMethod = AgentRegistryGrpc.getListPublishersMethod) == null) { + AgentRegistryGrpc.getListPublishersMethod = + getListPublishersMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListPublishers")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListPublishersRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListPublishersResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("ListPublishers")) + .build(); + } + } + } + return getListPublishersMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationRequest, + com.google.cloud.agentregistry.v1.AiApplication> + getGetAiApplicationMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetAiApplication", + requestType = com.google.cloud.agentregistry.v1.GetAiApplicationRequest.class, + responseType = com.google.cloud.agentregistry.v1.AiApplication.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationRequest, + com.google.cloud.agentregistry.v1.AiApplication> + getGetAiApplicationMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationRequest, + com.google.cloud.agentregistry.v1.AiApplication> + getGetAiApplicationMethod; + if ((getGetAiApplicationMethod = AgentRegistryGrpc.getGetAiApplicationMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getGetAiApplicationMethod = AgentRegistryGrpc.getGetAiApplicationMethod) == null) { + AgentRegistryGrpc.getGetAiApplicationMethod = + getGetAiApplicationMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetAiApplication")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.GetAiApplicationRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.AiApplication.getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("GetAiApplication")) + .build(); + } + } + } + return getGetAiApplicationMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse> + getListAiApplicationsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListAiApplications", + requestType = com.google.cloud.agentregistry.v1.ListAiApplicationsRequest.class, + responseType = com.google.cloud.agentregistry.v1.ListAiApplicationsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse> + getListAiApplicationsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse> + getListAiApplicationsMethod; + if ((getListAiApplicationsMethod = AgentRegistryGrpc.getListAiApplicationsMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getListAiApplicationsMethod = AgentRegistryGrpc.getListAiApplicationsMethod) == null) { + AgentRegistryGrpc.getListAiApplicationsMethod = + getListAiApplicationsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListAiApplications")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("ListAiApplications")) + .build(); + } + } + } + return getListAiApplicationsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest, + com.google.cloud.agentregistry.v1.Agent> + getGetAiApplicationAgentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetAiApplicationAgent", + requestType = com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest.class, + responseType = com.google.cloud.agentregistry.v1.Agent.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest, + com.google.cloud.agentregistry.v1.Agent> + getGetAiApplicationAgentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest, + com.google.cloud.agentregistry.v1.Agent> + getGetAiApplicationAgentMethod; + if ((getGetAiApplicationAgentMethod = AgentRegistryGrpc.getGetAiApplicationAgentMethod) + == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getGetAiApplicationAgentMethod = AgentRegistryGrpc.getGetAiApplicationAgentMethod) + == null) { + AgentRegistryGrpc.getGetAiApplicationAgentMethod = + getGetAiApplicationAgentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetAiApplicationAgent")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.Agent.getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("GetAiApplicationAgent")) + .build(); + } + } + } + return getGetAiApplicationAgentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse> + getListAiApplicationAgentsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListAiApplicationAgents", + requestType = com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest.class, + responseType = com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse> + getListAiApplicationAgentsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse> + getListAiApplicationAgentsMethod; + if ((getListAiApplicationAgentsMethod = AgentRegistryGrpc.getListAiApplicationAgentsMethod) + == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getListAiApplicationAgentsMethod = AgentRegistryGrpc.getListAiApplicationAgentsMethod) + == null) { + AgentRegistryGrpc.getListAiApplicationAgentsMethod = + getListAiApplicationAgentsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListAiApplicationAgents")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("ListAiApplicationAgents")) + .build(); + } + } + } + return getListAiApplicationAgentsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest, + com.google.cloud.agentregistry.v1.McpServer> + getGetAiApplicationMcpServerMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetAiApplicationMcpServer", + requestType = com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest.class, + responseType = com.google.cloud.agentregistry.v1.McpServer.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest, + com.google.cloud.agentregistry.v1.McpServer> + getGetAiApplicationMcpServerMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest, + com.google.cloud.agentregistry.v1.McpServer> + getGetAiApplicationMcpServerMethod; + if ((getGetAiApplicationMcpServerMethod = AgentRegistryGrpc.getGetAiApplicationMcpServerMethod) + == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getGetAiApplicationMcpServerMethod = + AgentRegistryGrpc.getGetAiApplicationMcpServerMethod) + == null) { + AgentRegistryGrpc.getGetAiApplicationMcpServerMethod = + getGetAiApplicationMcpServerMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetAiApplicationMcpServer")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.McpServer.getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("GetAiApplicationMcpServer")) + .build(); + } + } + } + return getGetAiApplicationMcpServerMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse> + getListAiApplicationMcpServersMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListAiApplicationMcpServers", + requestType = com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest.class, + responseType = com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse> + getListAiApplicationMcpServersMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse> + getListAiApplicationMcpServersMethod; + if ((getListAiApplicationMcpServersMethod = + AgentRegistryGrpc.getListAiApplicationMcpServersMethod) + == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getListAiApplicationMcpServersMethod = + AgentRegistryGrpc.getListAiApplicationMcpServersMethod) + == null) { + AgentRegistryGrpc.getListAiApplicationMcpServersMethod = + getListAiApplicationMcpServersMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListAiApplicationMcpServers")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("ListAiApplicationMcpServers")) + .build(); + } + } + } + return getListAiApplicationMcpServersMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetFindingRequest, + com.google.cloud.agentregistry.v1.Finding> + getGetFindingMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetFinding", + requestType = com.google.cloud.agentregistry.v1.GetFindingRequest.class, + responseType = com.google.cloud.agentregistry.v1.Finding.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetFindingRequest, + com.google.cloud.agentregistry.v1.Finding> + getGetFindingMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetFindingRequest, + com.google.cloud.agentregistry.v1.Finding> + getGetFindingMethod; + if ((getGetFindingMethod = AgentRegistryGrpc.getGetFindingMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getGetFindingMethod = AgentRegistryGrpc.getGetFindingMethod) == null) { + AgentRegistryGrpc.getGetFindingMethod = + getGetFindingMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetFinding")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.GetFindingRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.Finding.getDefaultInstance())) + .setSchemaDescriptor(new AgentRegistryMethodDescriptorSupplier("GetFinding")) + .build(); + } + } + } + return getGetFindingMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListFindingsRequest, + com.google.cloud.agentregistry.v1.ListFindingsResponse> + getListFindingsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListFindings", + requestType = com.google.cloud.agentregistry.v1.ListFindingsRequest.class, + responseType = com.google.cloud.agentregistry.v1.ListFindingsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListFindingsRequest, + com.google.cloud.agentregistry.v1.ListFindingsResponse> + getListFindingsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListFindingsRequest, + com.google.cloud.agentregistry.v1.ListFindingsResponse> + getListFindingsMethod; + if ((getListFindingsMethod = AgentRegistryGrpc.getListFindingsMethod) == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getListFindingsMethod = AgentRegistryGrpc.getListFindingsMethod) == null) { + AgentRegistryGrpc.getListFindingsMethod = + getListFindingsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListFindings")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListFindingsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListFindingsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("ListFindings")) + .build(); + } + } + } + return getListFindingsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest, + com.google.cloud.agentregistry.v1.Endpoint> + getGetAiApplicationEndpointMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetAiApplicationEndpoint", + requestType = com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest.class, + responseType = com.google.cloud.agentregistry.v1.Endpoint.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest, + com.google.cloud.agentregistry.v1.Endpoint> + getGetAiApplicationEndpointMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest, + com.google.cloud.agentregistry.v1.Endpoint> + getGetAiApplicationEndpointMethod; + if ((getGetAiApplicationEndpointMethod = AgentRegistryGrpc.getGetAiApplicationEndpointMethod) + == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getGetAiApplicationEndpointMethod = + AgentRegistryGrpc.getGetAiApplicationEndpointMethod) + == null) { + AgentRegistryGrpc.getGetAiApplicationEndpointMethod = + getGetAiApplicationEndpointMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetAiApplicationEndpoint")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.Endpoint.getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("GetAiApplicationEndpoint")) + .build(); + } + } + } + return getGetAiApplicationEndpointMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse> + getListAiApplicationEndpointsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListAiApplicationEndpoints", + requestType = com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest.class, + responseType = com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse> + getListAiApplicationEndpointsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse> + getListAiApplicationEndpointsMethod; + if ((getListAiApplicationEndpointsMethod = + AgentRegistryGrpc.getListAiApplicationEndpointsMethod) + == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getListAiApplicationEndpointsMethod = + AgentRegistryGrpc.getListAiApplicationEndpointsMethod) + == null) { + AgentRegistryGrpc.getListAiApplicationEndpointsMethod = + getListAiApplicationEndpointsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListAiApplicationEndpoints")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("ListAiApplicationEndpoints")) + .build(); + } + } + } + return getListAiApplicationEndpointsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest, + com.google.cloud.agentregistry.v1.SkillEncryptionSpec> + getGetSkillEncryptionSpecMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetSkillEncryptionSpec", + requestType = com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest.class, + responseType = com.google.cloud.agentregistry.v1.SkillEncryptionSpec.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest, + com.google.cloud.agentregistry.v1.SkillEncryptionSpec> + getGetSkillEncryptionSpecMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest, + com.google.cloud.agentregistry.v1.SkillEncryptionSpec> + getGetSkillEncryptionSpecMethod; + if ((getGetSkillEncryptionSpecMethod = AgentRegistryGrpc.getGetSkillEncryptionSpecMethod) + == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getGetSkillEncryptionSpecMethod = AgentRegistryGrpc.getGetSkillEncryptionSpecMethod) + == null) { + AgentRegistryGrpc.getGetSkillEncryptionSpecMethod = + getGetSkillEncryptionSpecMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetSkillEncryptionSpec")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.SkillEncryptionSpec + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("GetSkillEncryptionSpec")) + .build(); + } + } + } + return getGetSkillEncryptionSpecMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest, + com.google.longrunning.Operation> + getUpdateSkillEncryptionSpecMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateSkillEncryptionSpec", + requestType = com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest, + com.google.longrunning.Operation> + getUpdateSkillEncryptionSpecMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest, + com.google.longrunning.Operation> + getUpdateSkillEncryptionSpecMethod; + if ((getUpdateSkillEncryptionSpecMethod = AgentRegistryGrpc.getUpdateSkillEncryptionSpecMethod) + == null) { + synchronized (AgentRegistryGrpc.class) { + if ((getUpdateSkillEncryptionSpecMethod = + AgentRegistryGrpc.getUpdateSkillEncryptionSpecMethod) + == null) { + AgentRegistryGrpc.getUpdateSkillEncryptionSpecMethod = + getUpdateSkillEncryptionSpecMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "UpdateSkillEncryptionSpec")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new AgentRegistryMethodDescriptorSupplier("UpdateSkillEncryptionSpec")) + .build(); + } + } + } + return getUpdateSkillEncryptionSpecMethod; + } + /** Creates a new async stub that supports all call types for the service */ public static AgentRegistryStub newStub(io.grpc.Channel channel) { io.grpc.stub.AbstractStub.StubFactory factory = @@ -913,360 +2047,2088 @@ public AgentRegistryStub newStub( return AgentRegistryStub.newStub(factory, channel); } - /** Creates a new blocking-style stub that supports all types of calls on the service */ - public static AgentRegistryBlockingV2Stub newBlockingV2Stub(io.grpc.Channel channel) { - io.grpc.stub.AbstractStub.StubFactory factory = - new io.grpc.stub.AbstractStub.StubFactory() { - @java.lang.Override - public AgentRegistryBlockingV2Stub newStub( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new AgentRegistryBlockingV2Stub(channel, callOptions); - } - }; - return AgentRegistryBlockingV2Stub.newStub(factory, channel); - } + /** Creates a new blocking-style stub that supports all types of calls on the service */ + public static AgentRegistryBlockingV2Stub newBlockingV2Stub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public AgentRegistryBlockingV2Stub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentRegistryBlockingV2Stub(channel, callOptions); + } + }; + return AgentRegistryBlockingV2Stub.newStub(factory, channel); + } + + /** + * Creates a new blocking-style stub that supports unary and streaming output calls on the service + */ + public static AgentRegistryBlockingStub newBlockingStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public AgentRegistryBlockingStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentRegistryBlockingStub(channel, callOptions); + } + }; + return AgentRegistryBlockingStub.newStub(factory, channel); + } + + /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ + public static AgentRegistryFutureStub newFutureStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public AgentRegistryFutureStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentRegistryFutureStub(channel, callOptions); + } + }; + return AgentRegistryFutureStub.newStub(factory, channel); + } + + /** + * + * + *
+   * Service for managing Agent Registry resources.
+   * 
+ */ + public interface AsyncService { + + /** + * + * + *
+     * Lists Agents in a given project and location.
+     * 
+ */ + default void listAgents( + com.google.cloud.agentregistry.v1.ListAgentsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getListAgentsMethod(), responseObserver); + } + + /** + * + * + *
+     * Searches Agents in a given project and location.
+     * 
+ */ + default void searchAgents( + com.google.cloud.agentregistry.v1.SearchAgentsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getSearchAgentsMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Agent.
+     * 
+ */ + default void getAgent( + com.google.cloud.agentregistry.v1.GetAgentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetAgentMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists Endpoints in a given project and location.
+     * 
+ */ + default void listEndpoints( + com.google.cloud.agentregistry.v1.ListEndpointsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListEndpointsMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Endpoint.
+     * 
+ */ + default void getEndpoint( + com.google.cloud.agentregistry.v1.GetEndpointRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetEndpointMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists McpServers in a given project and location.
+     * 
+ */ + default void listMcpServers( + com.google.cloud.agentregistry.v1.ListMcpServersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListMcpServersMethod(), responseObserver); + } + + /** + * + * + *
+     * Searches McpServers in a given project and location.
+     * 
+ */ + default void searchMcpServers( + com.google.cloud.agentregistry.v1.SearchMcpServersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getSearchMcpServersMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets details of a single McpServer.
+     * 
+ */ + default void getMcpServer( + com.google.cloud.agentregistry.v1.GetMcpServerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetMcpServerMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists Services in a given project and location.
+     * 
+ */ + default void listServices( + com.google.cloud.agentregistry.v1.ListServicesRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListServicesMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Service.
+     * 
+ */ + default void getService( + com.google.cloud.agentregistry.v1.GetServiceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetServiceMethod(), responseObserver); + } + + /** + * + * + *
+     * Creates a new Service in a given project and location.
+     * 
+ */ + default void createService( + com.google.cloud.agentregistry.v1.CreateServiceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateServiceMethod(), responseObserver); + } + + /** + * + * + *
+     * Updates the parameters of a single Service.
+     * 
+ */ + default void updateService( + com.google.cloud.agentregistry.v1.UpdateServiceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateServiceMethod(), responseObserver); + } + + /** + * + * + *
+     * Deletes a single Service.
+     * 
+ */ + default void deleteService( + com.google.cloud.agentregistry.v1.DeleteServiceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteServiceMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists Bindings in a given project and location.
+     * 
+ */ + default void listBindings( + com.google.cloud.agentregistry.v1.ListBindingsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListBindingsMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Binding.
+     * 
+ */ + default void getBinding( + com.google.cloud.agentregistry.v1.GetBindingRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetBindingMethod(), responseObserver); + } + + /** + * + * + *
+     * Creates a new Binding in a given project and location.
+     * 
+ */ + default void createBinding( + com.google.cloud.agentregistry.v1.CreateBindingRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateBindingMethod(), responseObserver); + } + + /** + * + * + *
+     * Updates the parameters of a single Binding.
+     * 
+ */ + default void updateBinding( + com.google.cloud.agentregistry.v1.UpdateBindingRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateBindingMethod(), responseObserver); + } + + /** + * + * + *
+     * Deletes a single Binding.
+     * 
+ */ + default void deleteBinding( + com.google.cloud.agentregistry.v1.DeleteBindingRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteBindingMethod(), responseObserver); + } + + /** + * + * + *
+     * Fetches available Bindings.
+     * 
+ */ + default void fetchAvailableBindings( + com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse> + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getFetchAvailableBindingsMethod(), responseObserver); + } + + /** + * + * + *
+     * =========================================================================
+     * # Skills Collection APIs
+     * Creates a Skill resource container, optionally publishing the initial
+     * SkillRevision inline in a single, atomic CRUD roundtrip.
+     * 
+ */ + default void createSkill( + com.google.cloud.agentregistry.v1.CreateSkillRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateSkillMethod(), responseObserver); + } + + /** + * + * + *
+     * Fetches the active configuration and metadata of a Skill.
+     * 
+ */ + default void getSkill( + com.google.cloud.agentregistry.v1.GetSkillRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetSkillMethod(), responseObserver); + } + + /** + * + * + *
+     * Updates Skill metadata or overrides active pointers/state using REST
+     * standard PATCH.
+     * 
+ */ + default void updateSkill( + com.google.cloud.agentregistry.v1.UpdateSkillRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateSkillMethod(), responseObserver); + } + + /** + * + * + *
+     * Deletes a Skill container along with all its revisions.
+     * 
+ */ + default void deleteSkill( + com.google.cloud.agentregistry.v1.DeleteSkillRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteSkillMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists logical Skills available in a project.
+     * 
+ */ + default void listSkills( + com.google.cloud.agentregistry.v1.ListSkillsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getListSkillsMethod(), responseObserver); + } + + /** + * + * + *
+     * Custom deep-search method to filter by frontmatter or query SKILL.md text
+     * blobs.
+     * 
+ */ + default void searchSkills( + com.google.cloud.agentregistry.v1.SearchSkillsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getSearchSkillsMethod(), responseObserver); + } + + /** + * + * + *
+     * Creates a new immutable revision and triggers validation pipelines.
+     * 
+ */ + default void createSkillRevision( + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateSkillRevisionMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets details of a single immutable Revision.
+     * 
+ */ + default void getSkillRevision( + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetSkillRevisionMethod(), responseObserver); + } + + /** + * + * + *
+     * Deletes a specific revision (restricted to admins to purge accidentally
+     * committed secrets).
+     * 
+ */ + default void deleteSkillRevision( + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteSkillRevisionMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists all revisions belonging to a parent Skill.
+     * 
+ */ + default void listSkillRevisions( + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListSkillRevisionsMethod(), responseObserver); + } + + /** + * + * + *
+     * Fetches details of a specific Publisher.
+     * 
+ */ + default void getPublisher( + com.google.cloud.agentregistry.v1.GetPublisherRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetPublisherMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists all Publishers in a location.
+     * 
+ */ + default void listPublishers( + com.google.cloud.agentregistry.v1.ListPublishersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListPublishersMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets details of a single AI Application.
+     * 
+ */ + default void getAiApplication( + com.google.cloud.agentregistry.v1.GetAiApplicationRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetAiApplicationMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists AI Applications in a given project and location.
+     * 
+ */ + default void listAiApplications( + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListAiApplicationsMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Agent under an AI Application.
+     * 
+ */ + default void getAiApplicationAgent( + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetAiApplicationAgentMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists Agents under an AI Application.
+     * 
+ */ + default void listAiApplicationAgents( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse> + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListAiApplicationAgentsMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets details of a single McpServer under an AI Application.
+     * 
+ */ + default void getAiApplicationMcpServer( + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetAiApplicationMcpServerMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists McpServers under an AI Application.
+     * 
+ */ + default void listAiApplicationMcpServers( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse> + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListAiApplicationMcpServersMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Finding.
+     * 
+ */ + default void getFinding( + com.google.cloud.agentregistry.v1.GetFindingRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetFindingMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists Findings in a given project and location.
+     * 
+ */ + default void listFindings( + com.google.cloud.agentregistry.v1.ListFindingsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListFindingsMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Endpoint under an AI Application.
+     * 
+ */ + default void getAiApplicationEndpoint( + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetAiApplicationEndpointMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists Endpoints under an AI Application.
+     * 
+ */ + default void listAiApplicationEndpoints( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse> + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListAiApplicationEndpointsMethod(), responseObserver); + } + + /** + * + * + *
+     * =========================================================================
+     * # Skill Encryption Spec Service Methods
+     * Gets the customer-managed encryption key (CMEK) configuration for Skills in
+     * a specific project and location.
+     * 
+ */ + default void getSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetSkillEncryptionSpecMethod(), responseObserver); + } + + /** + * + * + *
+     * Updates the customer-managed encryption key (CMEK) configuration for Skills
+     * in a specific project and location.
+     * This method is only allowed when no Skills exist in the target project and
+     * location. If any Skill already exists in the location, the request fails
+     * with `FAILED_PRECONDITION`.
+     * 
+ */ + default void updateSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateSkillEncryptionSpecMethod(), responseObserver); + } + } + + /** + * Base class for the server implementation of the service AgentRegistry. + * + *
+   * Service for managing Agent Registry resources.
+   * 
+ */ + public abstract static class AgentRegistryImplBase + implements io.grpc.BindableService, AsyncService { + + @java.lang.Override + public final io.grpc.ServerServiceDefinition bindService() { + return AgentRegistryGrpc.bindService(this); + } + } + + /** + * A stub to allow clients to do asynchronous rpc calls to service AgentRegistry. + * + *
+   * Service for managing Agent Registry resources.
+   * 
+ */ + public static final class AgentRegistryStub + extends io.grpc.stub.AbstractAsyncStub { + private AgentRegistryStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected AgentRegistryStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentRegistryStub(channel, callOptions); + } + + /** + * + * + *
+     * Lists Agents in a given project and location.
+     * 
+ */ + public void listAgents( + com.google.cloud.agentregistry.v1.ListAgentsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListAgentsMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
+     * Searches Agents in a given project and location.
+     * 
+ */ + public void searchAgents( + com.google.cloud.agentregistry.v1.SearchAgentsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getSearchAgentsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Agent.
+     * 
+ */ + public void getAgent( + com.google.cloud.agentregistry.v1.GetAgentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetAgentMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
+     * Lists Endpoints in a given project and location.
+     * 
+ */ + public void listEndpoints( + com.google.cloud.agentregistry.v1.ListEndpointsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListEndpointsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Endpoint.
+     * 
+ */ + public void getEndpoint( + com.google.cloud.agentregistry.v1.GetEndpointRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetEndpointMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists McpServers in a given project and location.
+     * 
+ */ + public void listMcpServers( + com.google.cloud.agentregistry.v1.ListMcpServersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListMcpServersMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Searches McpServers in a given project and location.
+     * 
+ */ + public void searchMcpServers( + com.google.cloud.agentregistry.v1.SearchMcpServersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getSearchMcpServersMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets details of a single McpServer.
+     * 
+ */ + public void getMcpServer( + com.google.cloud.agentregistry.v1.GetMcpServerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetMcpServerMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists Services in a given project and location.
+     * 
+ */ + public void listServices( + com.google.cloud.agentregistry.v1.ListServicesRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListServicesMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Service.
+     * 
+ */ + public void getService( + com.google.cloud.agentregistry.v1.GetServiceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetServiceMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
+     * Creates a new Service in a given project and location.
+     * 
+ */ + public void createService( + com.google.cloud.agentregistry.v1.CreateServiceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateServiceMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Updates the parameters of a single Service.
+     * 
+ */ + public void updateService( + com.google.cloud.agentregistry.v1.UpdateServiceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateServiceMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Deletes a single Service.
+     * 
+ */ + public void deleteService( + com.google.cloud.agentregistry.v1.DeleteServiceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteServiceMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists Bindings in a given project and location.
+     * 
+ */ + public void listBindings( + com.google.cloud.agentregistry.v1.ListBindingsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListBindingsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Binding.
+     * 
+ */ + public void getBinding( + com.google.cloud.agentregistry.v1.GetBindingRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetBindingMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
+     * Creates a new Binding in a given project and location.
+     * 
+ */ + public void createBinding( + com.google.cloud.agentregistry.v1.CreateBindingRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateBindingMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Updates the parameters of a single Binding.
+     * 
+ */ + public void updateBinding( + com.google.cloud.agentregistry.v1.UpdateBindingRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateBindingMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Deletes a single Binding.
+     * 
+ */ + public void deleteBinding( + com.google.cloud.agentregistry.v1.DeleteBindingRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteBindingMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Fetches available Bindings.
+     * 
+ */ + public void fetchAvailableBindings( + com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse> + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getFetchAvailableBindingsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * =========================================================================
+     * # Skills Collection APIs
+     * Creates a Skill resource container, optionally publishing the initial
+     * SkillRevision inline in a single, atomic CRUD roundtrip.
+     * 
+ */ + public void createSkill( + com.google.cloud.agentregistry.v1.CreateSkillRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateSkillMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Fetches the active configuration and metadata of a Skill.
+     * 
+ */ + public void getSkill( + com.google.cloud.agentregistry.v1.GetSkillRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetSkillMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
+     * Updates Skill metadata or overrides active pointers/state using REST
+     * standard PATCH.
+     * 
+ */ + public void updateSkill( + com.google.cloud.agentregistry.v1.UpdateSkillRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateSkillMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Deletes a Skill container along with all its revisions.
+     * 
+ */ + public void deleteSkill( + com.google.cloud.agentregistry.v1.DeleteSkillRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteSkillMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists logical Skills available in a project.
+     * 
+ */ + public void listSkills( + com.google.cloud.agentregistry.v1.ListSkillsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListSkillsMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
+     * Custom deep-search method to filter by frontmatter or query SKILL.md text
+     * blobs.
+     * 
+ */ + public void searchSkills( + com.google.cloud.agentregistry.v1.SearchSkillsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getSearchSkillsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Creates a new immutable revision and triggers validation pipelines.
+     * 
+ */ + public void createSkillRevision( + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateSkillRevisionMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets details of a single immutable Revision.
+     * 
+ */ + public void getSkillRevision( + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetSkillRevisionMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Deletes a specific revision (restricted to admins to purge accidentally
+     * committed secrets).
+     * 
+ */ + public void deleteSkillRevision( + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteSkillRevisionMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists all revisions belonging to a parent Skill.
+     * 
+ */ + public void listSkillRevisions( + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListSkillRevisionsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Fetches details of a specific Publisher.
+     * 
+ */ + public void getPublisher( + com.google.cloud.agentregistry.v1.GetPublisherRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetPublisherMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists all Publishers in a location.
+     * 
+ */ + public void listPublishers( + com.google.cloud.agentregistry.v1.ListPublishersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListPublishersMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets details of a single AI Application.
+     * 
+ */ + public void getAiApplication( + com.google.cloud.agentregistry.v1.GetAiApplicationRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetAiApplicationMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists AI Applications in a given project and location.
+     * 
+ */ + public void listAiApplications( + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListAiApplicationsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Agent under an AI Application.
+     * 
+ */ + public void getAiApplicationAgent( + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetAiApplicationAgentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists Agents under an AI Application.
+     * 
+ */ + public void listAiApplicationAgents( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse> + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListAiApplicationAgentsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets details of a single McpServer under an AI Application.
+     * 
+ */ + public void getAiApplicationMcpServer( + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetAiApplicationMcpServerMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists McpServers under an AI Application.
+     * 
+ */ + public void listAiApplicationMcpServers( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse> + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListAiApplicationMcpServersMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Finding.
+     * 
+ */ + public void getFinding( + com.google.cloud.agentregistry.v1.GetFindingRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetFindingMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
+     * Lists Findings in a given project and location.
+     * 
+ */ + public void listFindings( + com.google.cloud.agentregistry.v1.ListFindingsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListFindingsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets details of a single Endpoint under an AI Application.
+     * 
+ */ + public void getAiApplicationEndpoint( + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetAiApplicationEndpointMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists Endpoints under an AI Application.
+     * 
+ */ + public void listAiApplicationEndpoints( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse> + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListAiApplicationEndpointsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * =========================================================================
+     * # Skill Encryption Spec Service Methods
+     * Gets the customer-managed encryption key (CMEK) configuration for Skills in
+     * a specific project and location.
+     * 
+ */ + public void getSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetSkillEncryptionSpecMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Updates the customer-managed encryption key (CMEK) configuration for Skills
+     * in a specific project and location.
+     * This method is only allowed when no Skills exist in the target project and
+     * location. If any Skill already exists in the location, the request fails
+     * with `FAILED_PRECONDITION`.
+     * 
+ */ + public void updateSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateSkillEncryptionSpecMethod(), getCallOptions()), + request, + responseObserver); + } + } + + /** + * A stub to allow clients to do synchronous rpc calls to service AgentRegistry. + * + *
+   * Service for managing Agent Registry resources.
+   * 
+ */ + public static final class AgentRegistryBlockingV2Stub + extends io.grpc.stub.AbstractBlockingStub { + private AgentRegistryBlockingV2Stub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected AgentRegistryBlockingV2Stub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentRegistryBlockingV2Stub(channel, callOptions); + } + + /** + * + * + *
+     * Lists Agents in a given project and location.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.ListAgentsResponse listAgents( + com.google.cloud.agentregistry.v1.ListAgentsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListAgentsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Searches Agents in a given project and location.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.SearchAgentsResponse searchAgents( + com.google.cloud.agentregistry.v1.SearchAgentsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getSearchAgentsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets details of a single Agent.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.Agent getAgent( + com.google.cloud.agentregistry.v1.GetAgentRequest request) throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetAgentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists Endpoints in a given project and location.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.ListEndpointsResponse listEndpoints( + com.google.cloud.agentregistry.v1.ListEndpointsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListEndpointsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets details of a single Endpoint.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.Endpoint getEndpoint( + com.google.cloud.agentregistry.v1.GetEndpointRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetEndpointMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists McpServers in a given project and location.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.ListMcpServersResponse listMcpServers( + com.google.cloud.agentregistry.v1.ListMcpServersRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListMcpServersMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Searches McpServers in a given project and location.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.SearchMcpServersResponse searchMcpServers( + com.google.cloud.agentregistry.v1.SearchMcpServersRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getSearchMcpServersMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets details of a single McpServer.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.McpServer getMcpServer( + com.google.cloud.agentregistry.v1.GetMcpServerRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetMcpServerMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists Services in a given project and location.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.ListServicesResponse listServices( + com.google.cloud.agentregistry.v1.ListServicesRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListServicesMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets details of a single Service.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.Service getService( + com.google.cloud.agentregistry.v1.GetServiceRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetServiceMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Creates a new Service in a given project and location.
+     * 
+ */ + public com.google.longrunning.Operation createService( + com.google.cloud.agentregistry.v1.CreateServiceRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getCreateServiceMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Updates the parameters of a single Service.
+     * 
+ */ + public com.google.longrunning.Operation updateService( + com.google.cloud.agentregistry.v1.UpdateServiceRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getUpdateServiceMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Deletes a single Service.
+     * 
+ */ + public com.google.longrunning.Operation deleteService( + com.google.cloud.agentregistry.v1.DeleteServiceRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getDeleteServiceMethod(), getCallOptions(), request); + } - /** - * Creates a new blocking-style stub that supports unary and streaming output calls on the service - */ - public static AgentRegistryBlockingStub newBlockingStub(io.grpc.Channel channel) { - io.grpc.stub.AbstractStub.StubFactory factory = - new io.grpc.stub.AbstractStub.StubFactory() { - @java.lang.Override - public AgentRegistryBlockingStub newStub( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new AgentRegistryBlockingStub(channel, callOptions); - } - }; - return AgentRegistryBlockingStub.newStub(factory, channel); - } + /** + * + * + *
+     * Lists Bindings in a given project and location.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.ListBindingsResponse listBindings( + com.google.cloud.agentregistry.v1.ListBindingsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListBindingsMethod(), getCallOptions(), request); + } - /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ - public static AgentRegistryFutureStub newFutureStub(io.grpc.Channel channel) { - io.grpc.stub.AbstractStub.StubFactory factory = - new io.grpc.stub.AbstractStub.StubFactory() { - @java.lang.Override - public AgentRegistryFutureStub newStub( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new AgentRegistryFutureStub(channel, callOptions); - } - }; - return AgentRegistryFutureStub.newStub(factory, channel); - } + /** + * + * + *
+     * Gets details of a single Binding.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.Binding getBinding( + com.google.cloud.agentregistry.v1.GetBindingRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetBindingMethod(), getCallOptions(), request); + } - /** - * - * - *
-   * Service for managing Agents, Endpoints, McpServers, Services, and Bindings.
-   * 
- */ - public interface AsyncService { + /** + * + * + *
+     * Creates a new Binding in a given project and location.
+     * 
+ */ + public com.google.longrunning.Operation createBinding( + com.google.cloud.agentregistry.v1.CreateBindingRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getCreateBindingMethod(), getCallOptions(), request); + } /** * * *
-     * Lists Agents in a given project and location.
+     * Updates the parameters of a single Binding.
      * 
*/ - default void listAgents( - com.google.cloud.agentregistry.v1.ListAgentsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getListAgentsMethod(), responseObserver); + public com.google.longrunning.Operation updateBinding( + com.google.cloud.agentregistry.v1.UpdateBindingRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getUpdateBindingMethod(), getCallOptions(), request); } /** * * *
-     * Searches Agents in a given project and location.
+     * Deletes a single Binding.
      * 
*/ - default void searchAgents( - com.google.cloud.agentregistry.v1.SearchAgentsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getSearchAgentsMethod(), responseObserver); + public com.google.longrunning.Operation deleteBinding( + com.google.cloud.agentregistry.v1.DeleteBindingRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getDeleteBindingMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single Agent.
+     * Fetches available Bindings.
      * 
*/ - default void getAgent( - com.google.cloud.agentregistry.v1.GetAgentRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetAgentMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse fetchAvailableBindings( + com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getFetchAvailableBindingsMethod(), getCallOptions(), request); } /** * * *
-     * Lists Endpoints in a given project and location.
+     * =========================================================================
+     * # Skills Collection APIs
+     * Creates a Skill resource container, optionally publishing the initial
+     * SkillRevision inline in a single, atomic CRUD roundtrip.
      * 
*/ - default void listEndpoints( - com.google.cloud.agentregistry.v1.ListEndpointsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getListEndpointsMethod(), responseObserver); + public com.google.longrunning.Operation createSkill( + com.google.cloud.agentregistry.v1.CreateSkillRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getCreateSkillMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single Endpoint.
+     * Fetches the active configuration and metadata of a Skill.
      * 
*/ - default void getEndpoint( - com.google.cloud.agentregistry.v1.GetEndpointRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getGetEndpointMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.Skill getSkill( + com.google.cloud.agentregistry.v1.GetSkillRequest request) throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetSkillMethod(), getCallOptions(), request); } /** * * *
-     * Lists McpServers in a given project and location.
+     * Updates Skill metadata or overrides active pointers/state using REST
+     * standard PATCH.
      * 
*/ - default void listMcpServers( - com.google.cloud.agentregistry.v1.ListMcpServersRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getListMcpServersMethod(), responseObserver); + public com.google.longrunning.Operation updateSkill( + com.google.cloud.agentregistry.v1.UpdateSkillRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getUpdateSkillMethod(), getCallOptions(), request); } /** * * *
-     * Searches McpServers in a given project and location.
+     * Deletes a Skill container along with all its revisions.
      * 
*/ - default void searchMcpServers( - com.google.cloud.agentregistry.v1.SearchMcpServersRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getSearchMcpServersMethod(), responseObserver); + public com.google.longrunning.Operation deleteSkill( + com.google.cloud.agentregistry.v1.DeleteSkillRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getDeleteSkillMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single McpServer.
+     * Lists logical Skills available in a project.
      * 
*/ - default void getMcpServer( - com.google.cloud.agentregistry.v1.GetMcpServerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getGetMcpServerMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.ListSkillsResponse listSkills( + com.google.cloud.agentregistry.v1.ListSkillsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListSkillsMethod(), getCallOptions(), request); } /** * * *
-     * Lists Services in a given project and location.
+     * Custom deep-search method to filter by frontmatter or query SKILL.md text
+     * blobs.
      * 
*/ - default void listServices( - com.google.cloud.agentregistry.v1.ListServicesRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getListServicesMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.SearchSkillsResponse searchSkills( + com.google.cloud.agentregistry.v1.SearchSkillsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getSearchSkillsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Creates a new immutable revision and triggers validation pipelines.
+     * 
+ */ + public com.google.longrunning.Operation createSkillRevision( + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getCreateSkillRevisionMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets details of a single immutable Revision.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.SkillRevision getSkillRevision( + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetSkillRevisionMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Deletes a specific revision (restricted to admins to purge accidentally
+     * committed secrets).
+     * 
+ */ + public com.google.longrunning.Operation deleteSkillRevision( + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getDeleteSkillRevisionMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists all revisions belonging to a parent Skill.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse listSkillRevisions( + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListSkillRevisionsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Fetches details of a specific Publisher.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.Publisher getPublisher( + com.google.cloud.agentregistry.v1.GetPublisherRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetPublisherMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists all Publishers in a location.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.ListPublishersResponse listPublishers( + com.google.cloud.agentregistry.v1.ListPublishersRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListPublishersMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets details of a single AI Application.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.AiApplication getAiApplication( + com.google.cloud.agentregistry.v1.GetAiApplicationRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetAiApplicationMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single Service.
+     * Lists AI Applications in a given project and location.
      * 
*/ - default void getService( - com.google.cloud.agentregistry.v1.GetServiceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetServiceMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.ListAiApplicationsResponse listAiApplications( + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListAiApplicationsMethod(), getCallOptions(), request); } /** * * *
-     * Creates a new Service in a given project and location.
+     * Gets details of a single Agent under an AI Application.
      * 
*/ - default void createService( - com.google.cloud.agentregistry.v1.CreateServiceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getCreateServiceMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.Agent getAiApplicationAgent( + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetAiApplicationAgentMethod(), getCallOptions(), request); } /** * * *
-     * Updates the parameters of a single Service.
+     * Lists Agents under an AI Application.
      * 
*/ - default void updateService( - com.google.cloud.agentregistry.v1.UpdateServiceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getUpdateServiceMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse + listAiApplicationAgents( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListAiApplicationAgentsMethod(), getCallOptions(), request); } /** * * *
-     * Deletes a single Service.
+     * Gets details of a single McpServer under an AI Application.
      * 
*/ - default void deleteService( - com.google.cloud.agentregistry.v1.DeleteServiceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getDeleteServiceMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.McpServer getAiApplicationMcpServer( + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetAiApplicationMcpServerMethod(), getCallOptions(), request); } /** * * *
-     * Lists Bindings in a given project and location.
+     * Lists McpServers under an AI Application.
      * 
*/ - default void listBindings( - com.google.cloud.agentregistry.v1.ListBindingsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getListBindingsMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse + listAiApplicationMcpServers( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListAiApplicationMcpServersMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single Binding.
+     * Gets details of a single Finding.
      * 
*/ - default void getBinding( - com.google.cloud.agentregistry.v1.GetBindingRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetBindingMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.Finding getFinding( + com.google.cloud.agentregistry.v1.GetFindingRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetFindingMethod(), getCallOptions(), request); } /** * * *
-     * Creates a new Binding in a given project and location.
+     * Lists Findings in a given project and location.
      * 
*/ - default void createBinding( - com.google.cloud.agentregistry.v1.CreateBindingRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getCreateBindingMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.ListFindingsResponse listFindings( + com.google.cloud.agentregistry.v1.ListFindingsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListFindingsMethod(), getCallOptions(), request); } /** * * *
-     * Updates the parameters of a single Binding.
+     * Gets details of a single Endpoint under an AI Application.
      * 
*/ - default void updateBinding( - com.google.cloud.agentregistry.v1.UpdateBindingRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getUpdateBindingMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.Endpoint getAiApplicationEndpoint( + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetAiApplicationEndpointMethod(), getCallOptions(), request); } /** * * *
-     * Deletes a single Binding.
+     * Lists Endpoints under an AI Application.
      * 
*/ - default void deleteBinding( - com.google.cloud.agentregistry.v1.DeleteBindingRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getDeleteBindingMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse + listAiApplicationEndpoints( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListAiApplicationEndpointsMethod(), getCallOptions(), request); } /** * * *
-     * Fetches available Bindings.
+     * =========================================================================
+     * # Skill Encryption Spec Service Methods
+     * Gets the customer-managed encryption key (CMEK) configuration for Skills in
+     * a specific project and location.
      * 
*/ - default void fetchAvailableBindings( - com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest request, - io.grpc.stub.StreamObserver< - com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse> - responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getFetchAvailableBindingsMethod(), responseObserver); + public com.google.cloud.agentregistry.v1.SkillEncryptionSpec getSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetSkillEncryptionSpecMethod(), getCallOptions(), request); } - } - - /** - * Base class for the server implementation of the service AgentRegistry. - * - *
-   * Service for managing Agents, Endpoints, McpServers, Services, and Bindings.
-   * 
- */ - public abstract static class AgentRegistryImplBase - implements io.grpc.BindableService, AsyncService { - @java.lang.Override - public final io.grpc.ServerServiceDefinition bindService() { - return AgentRegistryGrpc.bindService(this); + /** + * + * + *
+     * Updates the customer-managed encryption key (CMEK) configuration for Skills
+     * in a specific project and location.
+     * This method is only allowed when no Skills exist in the target project and
+     * location. If any Skill already exists in the location, the request fails
+     * with `FAILED_PRECONDITION`.
+     * 
+ */ + public com.google.longrunning.Operation updateSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getUpdateSkillEncryptionSpecMethod(), getCallOptions(), request); } } /** - * A stub to allow clients to do asynchronous rpc calls to service AgentRegistry. + * A stub to allow clients to do limited synchronous rpc calls to service AgentRegistry. * *
-   * Service for managing Agents, Endpoints, McpServers, Services, and Bindings.
+   * Service for managing Agent Registry resources.
    * 
*/ - public static final class AgentRegistryStub - extends io.grpc.stub.AbstractAsyncStub { - private AgentRegistryStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + public static final class AgentRegistryBlockingStub + extends io.grpc.stub.AbstractBlockingStub { + private AgentRegistryBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override - protected AgentRegistryStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new AgentRegistryStub(channel, callOptions); + protected AgentRegistryBlockingStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentRegistryBlockingStub(channel, callOptions); } /** @@ -1276,12 +4138,10 @@ protected AgentRegistryStub build(io.grpc.Channel channel, io.grpc.CallOptions c * Lists Agents in a given project and location. * */ - public void listAgents( - com.google.cloud.agentregistry.v1.ListAgentsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListAgentsMethod(), getCallOptions()), request, responseObserver); + public com.google.cloud.agentregistry.v1.ListAgentsResponse listAgents( + com.google.cloud.agentregistry.v1.ListAgentsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListAgentsMethod(), getCallOptions(), request); } /** @@ -1291,14 +4151,10 @@ public void listAgents( * Searches Agents in a given project and location. * */ - public void searchAgents( - com.google.cloud.agentregistry.v1.SearchAgentsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getSearchAgentsMethod(), getCallOptions()), - request, - responseObserver); + public com.google.cloud.agentregistry.v1.SearchAgentsResponse searchAgents( + com.google.cloud.agentregistry.v1.SearchAgentsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getSearchAgentsMethod(), getCallOptions(), request); } /** @@ -1308,11 +4164,10 @@ public void searchAgents( * Gets details of a single Agent. * */ - public void getAgent( - com.google.cloud.agentregistry.v1.GetAgentRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetAgentMethod(), getCallOptions()), request, responseObserver); + public com.google.cloud.agentregistry.v1.Agent getAgent( + com.google.cloud.agentregistry.v1.GetAgentRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetAgentMethod(), getCallOptions(), request); } /** @@ -1322,14 +4177,10 @@ public void getAgent( * Lists Endpoints in a given project and location. * */ - public void listEndpoints( - com.google.cloud.agentregistry.v1.ListEndpointsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListEndpointsMethod(), getCallOptions()), - request, - responseObserver); + public com.google.cloud.agentregistry.v1.ListEndpointsResponse listEndpoints( + com.google.cloud.agentregistry.v1.ListEndpointsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListEndpointsMethod(), getCallOptions(), request); } /** @@ -1339,13 +4190,10 @@ public void listEndpoints( * Gets details of a single Endpoint. * */ - public void getEndpoint( - com.google.cloud.agentregistry.v1.GetEndpointRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetEndpointMethod(), getCallOptions()), - request, - responseObserver); + public com.google.cloud.agentregistry.v1.Endpoint getEndpoint( + com.google.cloud.agentregistry.v1.GetEndpointRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetEndpointMethod(), getCallOptions(), request); } /** @@ -1355,14 +4203,10 @@ public void getEndpoint( * Lists McpServers in a given project and location. * */ - public void listMcpServers( - com.google.cloud.agentregistry.v1.ListMcpServersRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListMcpServersMethod(), getCallOptions()), - request, - responseObserver); + public com.google.cloud.agentregistry.v1.ListMcpServersResponse listMcpServers( + com.google.cloud.agentregistry.v1.ListMcpServersRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListMcpServersMethod(), getCallOptions(), request); } /** @@ -1372,511 +4216,514 @@ public void listMcpServers( * Searches McpServers in a given project and location. * */ - public void searchMcpServers( - com.google.cloud.agentregistry.v1.SearchMcpServersRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getSearchMcpServersMethod(), getCallOptions()), - request, - responseObserver); + public com.google.cloud.agentregistry.v1.SearchMcpServersResponse searchMcpServers( + com.google.cloud.agentregistry.v1.SearchMcpServersRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getSearchMcpServersMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets details of a single McpServer.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.McpServer getMcpServer( + com.google.cloud.agentregistry.v1.GetMcpServerRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetMcpServerMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists Services in a given project and location.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.ListServicesResponse listServices( + com.google.cloud.agentregistry.v1.ListServicesRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListServicesMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets details of a single Service.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.Service getService( + com.google.cloud.agentregistry.v1.GetServiceRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetServiceMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Creates a new Service in a given project and location.
+     * 
+ */ + public com.google.longrunning.Operation createService( + com.google.cloud.agentregistry.v1.CreateServiceRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateServiceMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Updates the parameters of a single Service.
+     * 
+ */ + public com.google.longrunning.Operation updateService( + com.google.cloud.agentregistry.v1.UpdateServiceRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateServiceMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single McpServer.
+     * Deletes a single Service.
      * 
*/ - public void getMcpServer( - com.google.cloud.agentregistry.v1.GetMcpServerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetMcpServerMethod(), getCallOptions()), - request, - responseObserver); + public com.google.longrunning.Operation deleteService( + com.google.cloud.agentregistry.v1.DeleteServiceRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteServiceMethod(), getCallOptions(), request); } /** * * *
-     * Lists Services in a given project and location.
+     * Lists Bindings in a given project and location.
      * 
*/ - public void listServices( - com.google.cloud.agentregistry.v1.ListServicesRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListServicesMethod(), getCallOptions()), - request, - responseObserver); + public com.google.cloud.agentregistry.v1.ListBindingsResponse listBindings( + com.google.cloud.agentregistry.v1.ListBindingsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListBindingsMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single Service.
+     * Gets details of a single Binding.
      * 
*/ - public void getService( - com.google.cloud.agentregistry.v1.GetServiceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetServiceMethod(), getCallOptions()), request, responseObserver); + public com.google.cloud.agentregistry.v1.Binding getBinding( + com.google.cloud.agentregistry.v1.GetBindingRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetBindingMethod(), getCallOptions(), request); } /** * * *
-     * Creates a new Service in a given project and location.
+     * Creates a new Binding in a given project and location.
      * 
*/ - public void createService( - com.google.cloud.agentregistry.v1.CreateServiceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getCreateServiceMethod(), getCallOptions()), - request, - responseObserver); + public com.google.longrunning.Operation createBinding( + com.google.cloud.agentregistry.v1.CreateBindingRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateBindingMethod(), getCallOptions(), request); } /** * * *
-     * Updates the parameters of a single Service.
+     * Updates the parameters of a single Binding.
      * 
*/ - public void updateService( - com.google.cloud.agentregistry.v1.UpdateServiceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getUpdateServiceMethod(), getCallOptions()), - request, - responseObserver); + public com.google.longrunning.Operation updateBinding( + com.google.cloud.agentregistry.v1.UpdateBindingRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateBindingMethod(), getCallOptions(), request); } /** * * *
-     * Deletes a single Service.
+     * Deletes a single Binding.
      * 
*/ - public void deleteService( - com.google.cloud.agentregistry.v1.DeleteServiceRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getDeleteServiceMethod(), getCallOptions()), - request, - responseObserver); + public com.google.longrunning.Operation deleteBinding( + com.google.cloud.agentregistry.v1.DeleteBindingRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteBindingMethod(), getCallOptions(), request); } /** * * *
-     * Lists Bindings in a given project and location.
+     * Fetches available Bindings.
      * 
*/ - public void listBindings( - com.google.cloud.agentregistry.v1.ListBindingsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListBindingsMethod(), getCallOptions()), - request, - responseObserver); + public com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse fetchAvailableBindings( + com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getFetchAvailableBindingsMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single Binding.
+     * =========================================================================
+     * # Skills Collection APIs
+     * Creates a Skill resource container, optionally publishing the initial
+     * SkillRevision inline in a single, atomic CRUD roundtrip.
      * 
*/ - public void getBinding( - com.google.cloud.agentregistry.v1.GetBindingRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetBindingMethod(), getCallOptions()), request, responseObserver); + public com.google.longrunning.Operation createSkill( + com.google.cloud.agentregistry.v1.CreateSkillRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateSkillMethod(), getCallOptions(), request); } /** * * *
-     * Creates a new Binding in a given project and location.
+     * Fetches the active configuration and metadata of a Skill.
      * 
*/ - public void createBinding( - com.google.cloud.agentregistry.v1.CreateBindingRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getCreateBindingMethod(), getCallOptions()), - request, - responseObserver); + public com.google.cloud.agentregistry.v1.Skill getSkill( + com.google.cloud.agentregistry.v1.GetSkillRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetSkillMethod(), getCallOptions(), request); } /** * * *
-     * Updates the parameters of a single Binding.
+     * Updates Skill metadata or overrides active pointers/state using REST
+     * standard PATCH.
      * 
*/ - public void updateBinding( - com.google.cloud.agentregistry.v1.UpdateBindingRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getUpdateBindingMethod(), getCallOptions()), - request, - responseObserver); + public com.google.longrunning.Operation updateSkill( + com.google.cloud.agentregistry.v1.UpdateSkillRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateSkillMethod(), getCallOptions(), request); } /** * * *
-     * Deletes a single Binding.
+     * Deletes a Skill container along with all its revisions.
      * 
*/ - public void deleteBinding( - com.google.cloud.agentregistry.v1.DeleteBindingRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getDeleteBindingMethod(), getCallOptions()), - request, - responseObserver); + public com.google.longrunning.Operation deleteSkill( + com.google.cloud.agentregistry.v1.DeleteSkillRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteSkillMethod(), getCallOptions(), request); } /** * * *
-     * Fetches available Bindings.
+     * Lists logical Skills available in a project.
      * 
*/ - public void fetchAvailableBindings( - com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest request, - io.grpc.stub.StreamObserver< - com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse> - responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getFetchAvailableBindingsMethod(), getCallOptions()), - request, - responseObserver); - } - } - - /** - * A stub to allow clients to do synchronous rpc calls to service AgentRegistry. - * - *
-   * Service for managing Agents, Endpoints, McpServers, Services, and Bindings.
-   * 
- */ - public static final class AgentRegistryBlockingV2Stub - extends io.grpc.stub.AbstractBlockingStub { - private AgentRegistryBlockingV2Stub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected AgentRegistryBlockingV2Stub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new AgentRegistryBlockingV2Stub(channel, callOptions); + public com.google.cloud.agentregistry.v1.ListSkillsResponse listSkills( + com.google.cloud.agentregistry.v1.ListSkillsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListSkillsMethod(), getCallOptions(), request); } /** * * *
-     * Lists Agents in a given project and location.
+     * Custom deep-search method to filter by frontmatter or query SKILL.md text
+     * blobs.
      * 
*/ - public com.google.cloud.agentregistry.v1.ListAgentsResponse listAgents( - com.google.cloud.agentregistry.v1.ListAgentsRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getListAgentsMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.SearchSkillsResponse searchSkills( + com.google.cloud.agentregistry.v1.SearchSkillsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getSearchSkillsMethod(), getCallOptions(), request); } /** * * *
-     * Searches Agents in a given project and location.
+     * Creates a new immutable revision and triggers validation pipelines.
      * 
*/ - public com.google.cloud.agentregistry.v1.SearchAgentsResponse searchAgents( - com.google.cloud.agentregistry.v1.SearchAgentsRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getSearchAgentsMethod(), getCallOptions(), request); + public com.google.longrunning.Operation createSkillRevision( + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateSkillRevisionMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single Agent.
+     * Gets details of a single immutable Revision.
      * 
*/ - public com.google.cloud.agentregistry.v1.Agent getAgent( - com.google.cloud.agentregistry.v1.GetAgentRequest request) throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getGetAgentMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.SkillRevision getSkillRevision( + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetSkillRevisionMethod(), getCallOptions(), request); } /** * * *
-     * Lists Endpoints in a given project and location.
+     * Deletes a specific revision (restricted to admins to purge accidentally
+     * committed secrets).
      * 
*/ - public com.google.cloud.agentregistry.v1.ListEndpointsResponse listEndpoints( - com.google.cloud.agentregistry.v1.ListEndpointsRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getListEndpointsMethod(), getCallOptions(), request); + public com.google.longrunning.Operation deleteSkillRevision( + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteSkillRevisionMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single Endpoint.
+     * Lists all revisions belonging to a parent Skill.
      * 
*/ - public com.google.cloud.agentregistry.v1.Endpoint getEndpoint( - com.google.cloud.agentregistry.v1.GetEndpointRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getGetEndpointMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse listSkillRevisions( + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListSkillRevisionsMethod(), getCallOptions(), request); } /** * * *
-     * Lists McpServers in a given project and location.
+     * Fetches details of a specific Publisher.
      * 
*/ - public com.google.cloud.agentregistry.v1.ListMcpServersResponse listMcpServers( - com.google.cloud.agentregistry.v1.ListMcpServersRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getListMcpServersMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.Publisher getPublisher( + com.google.cloud.agentregistry.v1.GetPublisherRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetPublisherMethod(), getCallOptions(), request); } /** * * *
-     * Searches McpServers in a given project and location.
+     * Lists all Publishers in a location.
      * 
*/ - public com.google.cloud.agentregistry.v1.SearchMcpServersResponse searchMcpServers( - com.google.cloud.agentregistry.v1.SearchMcpServersRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getSearchMcpServersMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.ListPublishersResponse listPublishers( + com.google.cloud.agentregistry.v1.ListPublishersRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListPublishersMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single McpServer.
+     * Gets details of a single AI Application.
      * 
*/ - public com.google.cloud.agentregistry.v1.McpServer getMcpServer( - com.google.cloud.agentregistry.v1.GetMcpServerRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getGetMcpServerMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.AiApplication getAiApplication( + com.google.cloud.agentregistry.v1.GetAiApplicationRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetAiApplicationMethod(), getCallOptions(), request); } /** * * *
-     * Lists Services in a given project and location.
+     * Lists AI Applications in a given project and location.
      * 
*/ - public com.google.cloud.agentregistry.v1.ListServicesResponse listServices( - com.google.cloud.agentregistry.v1.ListServicesRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getListServicesMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.ListAiApplicationsResponse listAiApplications( + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListAiApplicationsMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single Service.
+     * Gets details of a single Agent under an AI Application.
      * 
*/ - public com.google.cloud.agentregistry.v1.Service getService( - com.google.cloud.agentregistry.v1.GetServiceRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getGetServiceMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.Agent getAiApplicationAgent( + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetAiApplicationAgentMethod(), getCallOptions(), request); } /** * * *
-     * Creates a new Service in a given project and location.
+     * Lists Agents under an AI Application.
      * 
*/ - public com.google.longrunning.Operation createService( - com.google.cloud.agentregistry.v1.CreateServiceRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getCreateServiceMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse + listAiApplicationAgents( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListAiApplicationAgentsMethod(), getCallOptions(), request); } /** * * *
-     * Updates the parameters of a single Service.
+     * Gets details of a single McpServer under an AI Application.
      * 
*/ - public com.google.longrunning.Operation updateService( - com.google.cloud.agentregistry.v1.UpdateServiceRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getUpdateServiceMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.McpServer getAiApplicationMcpServer( + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetAiApplicationMcpServerMethod(), getCallOptions(), request); } /** * * *
-     * Deletes a single Service.
+     * Lists McpServers under an AI Application.
      * 
*/ - public com.google.longrunning.Operation deleteService( - com.google.cloud.agentregistry.v1.DeleteServiceRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getDeleteServiceMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse + listAiApplicationMcpServers( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListAiApplicationMcpServersMethod(), getCallOptions(), request); } /** * - * - *
-     * Lists Bindings in a given project and location.
-     * 
- */ - public com.google.cloud.agentregistry.v1.ListBindingsResponse listBindings( - com.google.cloud.agentregistry.v1.ListBindingsRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getListBindingsMethod(), getCallOptions(), request); + * + *
+     * Gets details of a single Finding.
+     * 
+ */ + public com.google.cloud.agentregistry.v1.Finding getFinding( + com.google.cloud.agentregistry.v1.GetFindingRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetFindingMethod(), getCallOptions(), request); } /** * * *
-     * Gets details of a single Binding.
+     * Lists Findings in a given project and location.
      * 
*/ - public com.google.cloud.agentregistry.v1.Binding getBinding( - com.google.cloud.agentregistry.v1.GetBindingRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getGetBindingMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.ListFindingsResponse listFindings( + com.google.cloud.agentregistry.v1.ListFindingsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListFindingsMethod(), getCallOptions(), request); } /** * * *
-     * Creates a new Binding in a given project and location.
+     * Gets details of a single Endpoint under an AI Application.
      * 
*/ - public com.google.longrunning.Operation createBinding( - com.google.cloud.agentregistry.v1.CreateBindingRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getCreateBindingMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.Endpoint getAiApplicationEndpoint( + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetAiApplicationEndpointMethod(), getCallOptions(), request); } /** * * *
-     * Updates the parameters of a single Binding.
+     * Lists Endpoints under an AI Application.
      * 
*/ - public com.google.longrunning.Operation updateBinding( - com.google.cloud.agentregistry.v1.UpdateBindingRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getUpdateBindingMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse + listAiApplicationEndpoints( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListAiApplicationEndpointsMethod(), getCallOptions(), request); } /** * * *
-     * Deletes a single Binding.
+     * =========================================================================
+     * # Skill Encryption Spec Service Methods
+     * Gets the customer-managed encryption key (CMEK) configuration for Skills in
+     * a specific project and location.
      * 
*/ - public com.google.longrunning.Operation deleteBinding( - com.google.cloud.agentregistry.v1.DeleteBindingRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getDeleteBindingMethod(), getCallOptions(), request); + public com.google.cloud.agentregistry.v1.SkillEncryptionSpec getSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetSkillEncryptionSpecMethod(), getCallOptions(), request); } /** * * *
-     * Fetches available Bindings.
+     * Updates the customer-managed encryption key (CMEK) configuration for Skills
+     * in a specific project and location.
+     * This method is only allowed when no Skills exist in the target project and
+     * location. If any Skill already exists in the location, the request fails
+     * with `FAILED_PRECONDITION`.
      * 
*/ - public com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse fetchAvailableBindings( - com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest request) - throws io.grpc.StatusException { - return io.grpc.stub.ClientCalls.blockingV2UnaryCall( - getChannel(), getFetchAvailableBindingsMethod(), getCallOptions(), request); + public com.google.longrunning.Operation updateSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateSkillEncryptionSpecMethod(), getCallOptions(), request); } } /** - * A stub to allow clients to do limited synchronous rpc calls to service AgentRegistry. + * A stub to allow clients to do ListenableFuture-style rpc calls to service AgentRegistry. * *
-   * Service for managing Agents, Endpoints, McpServers, Services, and Bindings.
+   * Service for managing Agent Registry resources.
    * 
*/ - public static final class AgentRegistryBlockingStub - extends io.grpc.stub.AbstractBlockingStub { - private AgentRegistryBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + public static final class AgentRegistryFutureStub + extends io.grpc.stub.AbstractFutureStub { + private AgentRegistryFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override - protected AgentRegistryBlockingStub build( + protected AgentRegistryFutureStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new AgentRegistryBlockingStub(channel, callOptions); + return new AgentRegistryFutureStub(channel, callOptions); } /** @@ -1886,10 +4733,11 @@ protected AgentRegistryBlockingStub build( * Lists Agents in a given project and location. * */ - public com.google.cloud.agentregistry.v1.ListAgentsResponse listAgents( - com.google.cloud.agentregistry.v1.ListAgentsRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListAgentsMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.ListAgentsResponse> + listAgents(com.google.cloud.agentregistry.v1.ListAgentsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListAgentsMethod(), getCallOptions()), request); } /** @@ -1899,10 +4747,11 @@ public com.google.cloud.agentregistry.v1.ListAgentsResponse listAgents( * Searches Agents in a given project and location. * */ - public com.google.cloud.agentregistry.v1.SearchAgentsResponse searchAgents( - com.google.cloud.agentregistry.v1.SearchAgentsRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getSearchAgentsMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.SearchAgentsResponse> + searchAgents(com.google.cloud.agentregistry.v1.SearchAgentsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getSearchAgentsMethod(), getCallOptions()), request); } /** @@ -1912,10 +4761,11 @@ public com.google.cloud.agentregistry.v1.SearchAgentsResponse searchAgents( * Gets details of a single Agent. * */ - public com.google.cloud.agentregistry.v1.Agent getAgent( - com.google.cloud.agentregistry.v1.GetAgentRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetAgentMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.Agent> + getAgent(com.google.cloud.agentregistry.v1.GetAgentRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetAgentMethod(), getCallOptions()), request); } /** @@ -1925,10 +4775,11 @@ public com.google.cloud.agentregistry.v1.Agent getAgent( * Lists Endpoints in a given project and location. * */ - public com.google.cloud.agentregistry.v1.ListEndpointsResponse listEndpoints( - com.google.cloud.agentregistry.v1.ListEndpointsRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListEndpointsMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.ListEndpointsResponse> + listEndpoints(com.google.cloud.agentregistry.v1.ListEndpointsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListEndpointsMethod(), getCallOptions()), request); } /** @@ -1938,10 +4789,11 @@ public com.google.cloud.agentregistry.v1.ListEndpointsResponse listEndpoints( * Gets details of a single Endpoint. * */ - public com.google.cloud.agentregistry.v1.Endpoint getEndpoint( - com.google.cloud.agentregistry.v1.GetEndpointRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetEndpointMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.Endpoint> + getEndpoint(com.google.cloud.agentregistry.v1.GetEndpointRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetEndpointMethod(), getCallOptions()), request); } /** @@ -1951,10 +4803,11 @@ public com.google.cloud.agentregistry.v1.Endpoint getEndpoint( * Lists McpServers in a given project and location. * */ - public com.google.cloud.agentregistry.v1.ListMcpServersResponse listMcpServers( - com.google.cloud.agentregistry.v1.ListMcpServersRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListMcpServersMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.ListMcpServersResponse> + listMcpServers(com.google.cloud.agentregistry.v1.ListMcpServersRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListMcpServersMethod(), getCallOptions()), request); } /** @@ -1964,10 +4817,11 @@ public com.google.cloud.agentregistry.v1.ListMcpServersResponse listMcpServers( * Searches McpServers in a given project and location. * */ - public com.google.cloud.agentregistry.v1.SearchMcpServersResponse searchMcpServers( - com.google.cloud.agentregistry.v1.SearchMcpServersRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getSearchMcpServersMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.SearchMcpServersResponse> + searchMcpServers(com.google.cloud.agentregistry.v1.SearchMcpServersRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getSearchMcpServersMethod(), getCallOptions()), request); } /** @@ -1977,10 +4831,11 @@ public com.google.cloud.agentregistry.v1.SearchMcpServersResponse searchMcpServe * Gets details of a single McpServer. * */ - public com.google.cloud.agentregistry.v1.McpServer getMcpServer( - com.google.cloud.agentregistry.v1.GetMcpServerRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetMcpServerMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.McpServer> + getMcpServer(com.google.cloud.agentregistry.v1.GetMcpServerRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetMcpServerMethod(), getCallOptions()), request); } /** @@ -1990,10 +4845,11 @@ public com.google.cloud.agentregistry.v1.McpServer getMcpServer( * Lists Services in a given project and location. * */ - public com.google.cloud.agentregistry.v1.ListServicesResponse listServices( - com.google.cloud.agentregistry.v1.ListServicesRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListServicesMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.ListServicesResponse> + listServices(com.google.cloud.agentregistry.v1.ListServicesRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListServicesMethod(), getCallOptions()), request); } /** @@ -2003,10 +4859,11 @@ public com.google.cloud.agentregistry.v1.ListServicesResponse listServices( * Gets details of a single Service. * */ - public com.google.cloud.agentregistry.v1.Service getService( - com.google.cloud.agentregistry.v1.GetServiceRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetServiceMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.Service> + getService(com.google.cloud.agentregistry.v1.GetServiceRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetServiceMethod(), getCallOptions()), request); } /** @@ -2016,10 +4873,10 @@ public com.google.cloud.agentregistry.v1.Service getService( * Creates a new Service in a given project and location. * */ - public com.google.longrunning.Operation createService( - com.google.cloud.agentregistry.v1.CreateServiceRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getCreateServiceMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture + createService(com.google.cloud.agentregistry.v1.CreateServiceRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateServiceMethod(), getCallOptions()), request); } /** @@ -2029,10 +4886,10 @@ public com.google.longrunning.Operation createService( * Updates the parameters of a single Service. * */ - public com.google.longrunning.Operation updateService( - com.google.cloud.agentregistry.v1.UpdateServiceRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getUpdateServiceMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture + updateService(com.google.cloud.agentregistry.v1.UpdateServiceRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateServiceMethod(), getCallOptions()), request); } /** @@ -2042,10 +4899,10 @@ public com.google.longrunning.Operation updateService( * Deletes a single Service. * */ - public com.google.longrunning.Operation deleteService( - com.google.cloud.agentregistry.v1.DeleteServiceRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getDeleteServiceMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture + deleteService(com.google.cloud.agentregistry.v1.DeleteServiceRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteServiceMethod(), getCallOptions()), request); } /** @@ -2055,10 +4912,11 @@ public com.google.longrunning.Operation deleteService( * Lists Bindings in a given project and location. * */ - public com.google.cloud.agentregistry.v1.ListBindingsResponse listBindings( - com.google.cloud.agentregistry.v1.ListBindingsRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListBindingsMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.ListBindingsResponse> + listBindings(com.google.cloud.agentregistry.v1.ListBindingsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListBindingsMethod(), getCallOptions()), request); } /** @@ -2068,10 +4926,11 @@ public com.google.cloud.agentregistry.v1.ListBindingsResponse listBindings( * Gets details of a single Binding. * */ - public com.google.cloud.agentregistry.v1.Binding getBinding( - com.google.cloud.agentregistry.v1.GetBindingRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetBindingMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.Binding> + getBinding(com.google.cloud.agentregistry.v1.GetBindingRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetBindingMethod(), getCallOptions()), request); } /** @@ -2081,10 +4940,10 @@ public com.google.cloud.agentregistry.v1.Binding getBinding( * Creates a new Binding in a given project and location. * */ - public com.google.longrunning.Operation createBinding( - com.google.cloud.agentregistry.v1.CreateBindingRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getCreateBindingMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture + createBinding(com.google.cloud.agentregistry.v1.CreateBindingRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateBindingMethod(), getCallOptions()), request); } /** @@ -2094,317 +4953,389 @@ public com.google.longrunning.Operation createBinding( * Updates the parameters of a single Binding. * */ - public com.google.longrunning.Operation updateBinding( - com.google.cloud.agentregistry.v1.UpdateBindingRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getUpdateBindingMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture + updateBinding(com.google.cloud.agentregistry.v1.UpdateBindingRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateBindingMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Deletes a single Binding.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + deleteBinding(com.google.cloud.agentregistry.v1.DeleteBindingRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteBindingMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Fetches available Bindings.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse> + fetchAvailableBindings( + com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getFetchAvailableBindingsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * =========================================================================
+     * # Skills Collection APIs
+     * Creates a Skill resource container, optionally publishing the initial
+     * SkillRevision inline in a single, atomic CRUD roundtrip.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + createSkill(com.google.cloud.agentregistry.v1.CreateSkillRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateSkillMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Fetches the active configuration and metadata of a Skill.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.Skill> + getSkill(com.google.cloud.agentregistry.v1.GetSkillRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetSkillMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Updates Skill metadata or overrides active pointers/state using REST
+     * standard PATCH.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + updateSkill(com.google.cloud.agentregistry.v1.UpdateSkillRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateSkillMethod(), getCallOptions()), request); } /** * * *
-     * Deletes a single Binding.
+     * Deletes a Skill container along with all its revisions.
      * 
*/ - public com.google.longrunning.Operation deleteBinding( - com.google.cloud.agentregistry.v1.DeleteBindingRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getDeleteBindingMethod(), getCallOptions(), request); + public com.google.common.util.concurrent.ListenableFuture + deleteSkill(com.google.cloud.agentregistry.v1.DeleteSkillRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteSkillMethod(), getCallOptions()), request); } /** * * *
-     * Fetches available Bindings.
+     * Lists logical Skills available in a project.
      * 
*/ - public com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse fetchAvailableBindings( - com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getFetchAvailableBindingsMethod(), getCallOptions(), request); - } - } - - /** - * A stub to allow clients to do ListenableFuture-style rpc calls to service AgentRegistry. - * - *
-   * Service for managing Agents, Endpoints, McpServers, Services, and Bindings.
-   * 
- */ - public static final class AgentRegistryFutureStub - extends io.grpc.stub.AbstractFutureStub { - private AgentRegistryFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected AgentRegistryFutureStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new AgentRegistryFutureStub(channel, callOptions); + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.ListSkillsResponse> + listSkills(com.google.cloud.agentregistry.v1.ListSkillsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListSkillsMethod(), getCallOptions()), request); } /** * * *
-     * Lists Agents in a given project and location.
+     * Custom deep-search method to filter by frontmatter or query SKILL.md text
+     * blobs.
      * 
*/ public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.ListAgentsResponse> - listAgents(com.google.cloud.agentregistry.v1.ListAgentsRequest request) { + com.google.cloud.agentregistry.v1.SearchSkillsResponse> + searchSkills(com.google.cloud.agentregistry.v1.SearchSkillsRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListAgentsMethod(), getCallOptions()), request); + getChannel().newCall(getSearchSkillsMethod(), getCallOptions()), request); } /** * * *
-     * Searches Agents in a given project and location.
+     * Creates a new immutable revision and triggers validation pipelines.
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.SearchAgentsResponse> - searchAgents(com.google.cloud.agentregistry.v1.SearchAgentsRequest request) { + public com.google.common.util.concurrent.ListenableFuture + createSkillRevision(com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getSearchAgentsMethod(), getCallOptions()), request); + getChannel().newCall(getCreateSkillRevisionMethod(), getCallOptions()), request); } /** * * *
-     * Gets details of a single Agent.
+     * Gets details of a single immutable Revision.
      * 
*/ public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.Agent> - getAgent(com.google.cloud.agentregistry.v1.GetAgentRequest request) { + com.google.cloud.agentregistry.v1.SkillRevision> + getSkillRevision(com.google.cloud.agentregistry.v1.GetSkillRevisionRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetAgentMethod(), getCallOptions()), request); + getChannel().newCall(getGetSkillRevisionMethod(), getCallOptions()), request); } /** * * *
-     * Lists Endpoints in a given project and location.
+     * Deletes a specific revision (restricted to admins to purge accidentally
+     * committed secrets).
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.ListEndpointsResponse> - listEndpoints(com.google.cloud.agentregistry.v1.ListEndpointsRequest request) { + public com.google.common.util.concurrent.ListenableFuture + deleteSkillRevision(com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListEndpointsMethod(), getCallOptions()), request); + getChannel().newCall(getDeleteSkillRevisionMethod(), getCallOptions()), request); } /** * * *
-     * Gets details of a single Endpoint.
+     * Lists all revisions belonging to a parent Skill.
      * 
*/ public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.Endpoint> - getEndpoint(com.google.cloud.agentregistry.v1.GetEndpointRequest request) { + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse> + listSkillRevisions(com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetEndpointMethod(), getCallOptions()), request); + getChannel().newCall(getListSkillRevisionsMethod(), getCallOptions()), request); } /** * * *
-     * Lists McpServers in a given project and location.
+     * Fetches details of a specific Publisher.
      * 
*/ public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.ListMcpServersResponse> - listMcpServers(com.google.cloud.agentregistry.v1.ListMcpServersRequest request) { + com.google.cloud.agentregistry.v1.Publisher> + getPublisher(com.google.cloud.agentregistry.v1.GetPublisherRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListMcpServersMethod(), getCallOptions()), request); + getChannel().newCall(getGetPublisherMethod(), getCallOptions()), request); } /** * * *
-     * Searches McpServers in a given project and location.
+     * Lists all Publishers in a location.
      * 
*/ public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.SearchMcpServersResponse> - searchMcpServers(com.google.cloud.agentregistry.v1.SearchMcpServersRequest request) { + com.google.cloud.agentregistry.v1.ListPublishersResponse> + listPublishers(com.google.cloud.agentregistry.v1.ListPublishersRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getSearchMcpServersMethod(), getCallOptions()), request); + getChannel().newCall(getListPublishersMethod(), getCallOptions()), request); } /** * * *
-     * Gets details of a single McpServer.
+     * Gets details of a single AI Application.
      * 
*/ public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.McpServer> - getMcpServer(com.google.cloud.agentregistry.v1.GetMcpServerRequest request) { + com.google.cloud.agentregistry.v1.AiApplication> + getAiApplication(com.google.cloud.agentregistry.v1.GetAiApplicationRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetMcpServerMethod(), getCallOptions()), request); + getChannel().newCall(getGetAiApplicationMethod(), getCallOptions()), request); } /** * * *
-     * Lists Services in a given project and location.
+     * Lists AI Applications in a given project and location.
      * 
*/ public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.ListServicesResponse> - listServices(com.google.cloud.agentregistry.v1.ListServicesRequest request) { + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse> + listAiApplications(com.google.cloud.agentregistry.v1.ListAiApplicationsRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListServicesMethod(), getCallOptions()), request); + getChannel().newCall(getListAiApplicationsMethod(), getCallOptions()), request); } /** * * *
-     * Gets details of a single Service.
+     * Gets details of a single Agent under an AI Application.
      * 
*/ public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.Service> - getService(com.google.cloud.agentregistry.v1.GetServiceRequest request) { + com.google.cloud.agentregistry.v1.Agent> + getAiApplicationAgent( + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetServiceMethod(), getCallOptions()), request); + getChannel().newCall(getGetAiApplicationAgentMethod(), getCallOptions()), request); } /** * * *
-     * Creates a new Service in a given project and location.
+     * Lists Agents under an AI Application.
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture - createService(com.google.cloud.agentregistry.v1.CreateServiceRequest request) { + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse> + listAiApplicationAgents( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getCreateServiceMethod(), getCallOptions()), request); + getChannel().newCall(getListAiApplicationAgentsMethod(), getCallOptions()), request); } /** * * *
-     * Updates the parameters of a single Service.
+     * Gets details of a single McpServer under an AI Application.
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture - updateService(com.google.cloud.agentregistry.v1.UpdateServiceRequest request) { + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.McpServer> + getAiApplicationMcpServer( + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getUpdateServiceMethod(), getCallOptions()), request); + getChannel().newCall(getGetAiApplicationMcpServerMethod(), getCallOptions()), request); } /** * * *
-     * Deletes a single Service.
+     * Lists McpServers under an AI Application.
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture - deleteService(com.google.cloud.agentregistry.v1.DeleteServiceRequest request) { + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse> + listAiApplicationMcpServers( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getDeleteServiceMethod(), getCallOptions()), request); + getChannel().newCall(getListAiApplicationMcpServersMethod(), getCallOptions()), request); } /** * * *
-     * Lists Bindings in a given project and location.
+     * Gets details of a single Finding.
      * 
*/ public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.ListBindingsResponse> - listBindings(com.google.cloud.agentregistry.v1.ListBindingsRequest request) { + com.google.cloud.agentregistry.v1.Finding> + getFinding(com.google.cloud.agentregistry.v1.GetFindingRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListBindingsMethod(), getCallOptions()), request); + getChannel().newCall(getGetFindingMethod(), getCallOptions()), request); } /** * * *
-     * Gets details of a single Binding.
+     * Lists Findings in a given project and location.
      * 
*/ public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.Binding> - getBinding(com.google.cloud.agentregistry.v1.GetBindingRequest request) { + com.google.cloud.agentregistry.v1.ListFindingsResponse> + listFindings(com.google.cloud.agentregistry.v1.ListFindingsRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetBindingMethod(), getCallOptions()), request); + getChannel().newCall(getListFindingsMethod(), getCallOptions()), request); } /** * * *
-     * Creates a new Binding in a given project and location.
+     * Gets details of a single Endpoint under an AI Application.
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture - createBinding(com.google.cloud.agentregistry.v1.CreateBindingRequest request) { + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.Endpoint> + getAiApplicationEndpoint( + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getCreateBindingMethod(), getCallOptions()), request); + getChannel().newCall(getGetAiApplicationEndpointMethod(), getCallOptions()), request); } /** * * *
-     * Updates the parameters of a single Binding.
+     * Lists Endpoints under an AI Application.
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture - updateBinding(com.google.cloud.agentregistry.v1.UpdateBindingRequest request) { + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse> + listAiApplicationEndpoints( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getUpdateBindingMethod(), getCallOptions()), request); + getChannel().newCall(getListAiApplicationEndpointsMethod(), getCallOptions()), request); } /** * * *
-     * Deletes a single Binding.
+     * =========================================================================
+     * # Skill Encryption Spec Service Methods
+     * Gets the customer-managed encryption key (CMEK) configuration for Skills in
+     * a specific project and location.
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture - deleteBinding(com.google.cloud.agentregistry.v1.DeleteBindingRequest request) { + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.agentregistry.v1.SkillEncryptionSpec> + getSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getDeleteBindingMethod(), getCallOptions()), request); + getChannel().newCall(getGetSkillEncryptionSpecMethod(), getCallOptions()), request); } /** * * *
-     * Fetches available Bindings.
+     * Updates the customer-managed encryption key (CMEK) configuration for Skills
+     * in a specific project and location.
+     * This method is only allowed when no Skills exist in the target project and
+     * location. If any Skill already exists in the location, the request fails
+     * with `FAILED_PRECONDITION`.
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture< - com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse> - fetchAvailableBindings( - com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest request) { + public com.google.common.util.concurrent.ListenableFuture + updateSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getFetchAvailableBindingsMethod(), getCallOptions()), request); + getChannel().newCall(getUpdateSkillEncryptionSpecMethod(), getCallOptions()), request); } } @@ -2427,6 +5358,30 @@ protected AgentRegistryFutureStub build( private static final int METHODID_UPDATE_BINDING = 16; private static final int METHODID_DELETE_BINDING = 17; private static final int METHODID_FETCH_AVAILABLE_BINDINGS = 18; + private static final int METHODID_CREATE_SKILL = 19; + private static final int METHODID_GET_SKILL = 20; + private static final int METHODID_UPDATE_SKILL = 21; + private static final int METHODID_DELETE_SKILL = 22; + private static final int METHODID_LIST_SKILLS = 23; + private static final int METHODID_SEARCH_SKILLS = 24; + private static final int METHODID_CREATE_SKILL_REVISION = 25; + private static final int METHODID_GET_SKILL_REVISION = 26; + private static final int METHODID_DELETE_SKILL_REVISION = 27; + private static final int METHODID_LIST_SKILL_REVISIONS = 28; + private static final int METHODID_GET_PUBLISHER = 29; + private static final int METHODID_LIST_PUBLISHERS = 30; + private static final int METHODID_GET_AI_APPLICATION = 31; + private static final int METHODID_LIST_AI_APPLICATIONS = 32; + private static final int METHODID_GET_AI_APPLICATION_AGENT = 33; + private static final int METHODID_LIST_AI_APPLICATION_AGENTS = 34; + private static final int METHODID_GET_AI_APPLICATION_MCP_SERVER = 35; + private static final int METHODID_LIST_AI_APPLICATION_MCP_SERVERS = 36; + private static final int METHODID_GET_FINDING = 37; + private static final int METHODID_LIST_FINDINGS = 38; + private static final int METHODID_GET_AI_APPLICATION_ENDPOINT = 39; + private static final int METHODID_LIST_AI_APPLICATION_ENDPOINTS = 40; + private static final int METHODID_GET_SKILL_ENCRYPTION_SPEC = 41; + private static final int METHODID_UPDATE_SKILL_ENCRYPTION_SPEC = 42; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -2556,6 +5511,150 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse>) responseObserver); break; + case METHODID_CREATE_SKILL: + serviceImpl.createSkill( + (com.google.cloud.agentregistry.v1.CreateSkillRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_SKILL: + serviceImpl.getSkill( + (com.google.cloud.agentregistry.v1.GetSkillRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_UPDATE_SKILL: + serviceImpl.updateSkill( + (com.google.cloud.agentregistry.v1.UpdateSkillRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DELETE_SKILL: + serviceImpl.deleteSkill( + (com.google.cloud.agentregistry.v1.DeleteSkillRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_LIST_SKILLS: + serviceImpl.listSkills( + (com.google.cloud.agentregistry.v1.ListSkillsRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_SEARCH_SKILLS: + serviceImpl.searchSkills( + (com.google.cloud.agentregistry.v1.SearchSkillsRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_CREATE_SKILL_REVISION: + serviceImpl.createSkillRevision( + (com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_SKILL_REVISION: + serviceImpl.getSkillRevision( + (com.google.cloud.agentregistry.v1.GetSkillRevisionRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_DELETE_SKILL_REVISION: + serviceImpl.deleteSkillRevision( + (com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_LIST_SKILL_REVISIONS: + serviceImpl.listSkillRevisions( + (com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse>) + responseObserver); + break; + case METHODID_GET_PUBLISHER: + serviceImpl.getPublisher( + (com.google.cloud.agentregistry.v1.GetPublisherRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_PUBLISHERS: + serviceImpl.listPublishers( + (com.google.cloud.agentregistry.v1.ListPublishersRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListPublishersResponse>) + responseObserver); + break; + case METHODID_GET_AI_APPLICATION: + serviceImpl.getAiApplication( + (com.google.cloud.agentregistry.v1.GetAiApplicationRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_AI_APPLICATIONS: + serviceImpl.listAiApplications( + (com.google.cloud.agentregistry.v1.ListAiApplicationsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse>) + responseObserver); + break; + case METHODID_GET_AI_APPLICATION_AGENT: + serviceImpl.getAiApplicationAgent( + (com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_AI_APPLICATION_AGENTS: + serviceImpl.listAiApplicationAgents( + (com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse>) + responseObserver); + break; + case METHODID_GET_AI_APPLICATION_MCP_SERVER: + serviceImpl.getAiApplicationMcpServer( + (com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_AI_APPLICATION_MCP_SERVERS: + serviceImpl.listAiApplicationMcpServers( + (com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse>) + responseObserver); + break; + case METHODID_GET_FINDING: + serviceImpl.getFinding( + (com.google.cloud.agentregistry.v1.GetFindingRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_FINDINGS: + serviceImpl.listFindings( + (com.google.cloud.agentregistry.v1.ListFindingsRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_GET_AI_APPLICATION_ENDPOINT: + serviceImpl.getAiApplicationEndpoint( + (com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_AI_APPLICATION_ENDPOINTS: + serviceImpl.listAiApplicationEndpoints( + (com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse>) + responseObserver); + break; + case METHODID_GET_SKILL_ENCRYPTION_SPEC: + serviceImpl.getSkillEncryptionSpec( + (com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_UPDATE_SKILL_ENCRYPTION_SPEC: + serviceImpl.updateSkillEncryptionSpec( + (com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; default: throw new AssertionError(); } @@ -2696,6 +5795,166 @@ public static final io.grpc.ServerServiceDefinition bindService(AsyncService ser com.google.cloud.agentregistry.v1.FetchAvailableBindingsRequest, com.google.cloud.agentregistry.v1.FetchAvailableBindingsResponse>( service, METHODID_FETCH_AVAILABLE_BINDINGS))) + .addMethod( + getCreateSkillMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.CreateSkillRequest, + com.google.longrunning.Operation>(service, METHODID_CREATE_SKILL))) + .addMethod( + getGetSkillMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.GetSkillRequest, + com.google.cloud.agentregistry.v1.Skill>(service, METHODID_GET_SKILL))) + .addMethod( + getUpdateSkillMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.UpdateSkillRequest, + com.google.longrunning.Operation>(service, METHODID_UPDATE_SKILL))) + .addMethod( + getDeleteSkillMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.DeleteSkillRequest, + com.google.longrunning.Operation>(service, METHODID_DELETE_SKILL))) + .addMethod( + getListSkillsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.ListSkillsRequest, + com.google.cloud.agentregistry.v1.ListSkillsResponse>( + service, METHODID_LIST_SKILLS))) + .addMethod( + getSearchSkillsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.SearchSkillsRequest, + com.google.cloud.agentregistry.v1.SearchSkillsResponse>( + service, METHODID_SEARCH_SKILLS))) + .addMethod( + getCreateSkillRevisionMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest, + com.google.longrunning.Operation>(service, METHODID_CREATE_SKILL_REVISION))) + .addMethod( + getGetSkillRevisionMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest, + com.google.cloud.agentregistry.v1.SkillRevision>( + service, METHODID_GET_SKILL_REVISION))) + .addMethod( + getDeleteSkillRevisionMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest, + com.google.longrunning.Operation>(service, METHODID_DELETE_SKILL_REVISION))) + .addMethod( + getListSkillRevisionsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest, + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse>( + service, METHODID_LIST_SKILL_REVISIONS))) + .addMethod( + getGetPublisherMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.GetPublisherRequest, + com.google.cloud.agentregistry.v1.Publisher>(service, METHODID_GET_PUBLISHER))) + .addMethod( + getListPublishersMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.ListPublishersRequest, + com.google.cloud.agentregistry.v1.ListPublishersResponse>( + service, METHODID_LIST_PUBLISHERS))) + .addMethod( + getGetAiApplicationMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.GetAiApplicationRequest, + com.google.cloud.agentregistry.v1.AiApplication>( + service, METHODID_GET_AI_APPLICATION))) + .addMethod( + getListAiApplicationsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse>( + service, METHODID_LIST_AI_APPLICATIONS))) + .addMethod( + getGetAiApplicationAgentMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest, + com.google.cloud.agentregistry.v1.Agent>( + service, METHODID_GET_AI_APPLICATION_AGENT))) + .addMethod( + getListAiApplicationAgentsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse>( + service, METHODID_LIST_AI_APPLICATION_AGENTS))) + .addMethod( + getGetAiApplicationMcpServerMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest, + com.google.cloud.agentregistry.v1.McpServer>( + service, METHODID_GET_AI_APPLICATION_MCP_SERVER))) + .addMethod( + getListAiApplicationMcpServersMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse>( + service, METHODID_LIST_AI_APPLICATION_MCP_SERVERS))) + .addMethod( + getGetFindingMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.GetFindingRequest, + com.google.cloud.agentregistry.v1.Finding>(service, METHODID_GET_FINDING))) + .addMethod( + getListFindingsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.ListFindingsRequest, + com.google.cloud.agentregistry.v1.ListFindingsResponse>( + service, METHODID_LIST_FINDINGS))) + .addMethod( + getGetAiApplicationEndpointMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest, + com.google.cloud.agentregistry.v1.Endpoint>( + service, METHODID_GET_AI_APPLICATION_ENDPOINT))) + .addMethod( + getListAiApplicationEndpointsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest, + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse>( + service, METHODID_LIST_AI_APPLICATION_ENDPOINTS))) + .addMethod( + getGetSkillEncryptionSpecMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest, + com.google.cloud.agentregistry.v1.SkillEncryptionSpec>( + service, METHODID_GET_SKILL_ENCRYPTION_SPEC))) + .addMethod( + getUpdateSkillEncryptionSpecMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest, + com.google.longrunning.Operation>( + service, METHODID_UPDATE_SKILL_ENCRYPTION_SPEC))) .build(); } @@ -2766,6 +6025,30 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getUpdateBindingMethod()) .addMethod(getDeleteBindingMethod()) .addMethod(getFetchAvailableBindingsMethod()) + .addMethod(getCreateSkillMethod()) + .addMethod(getGetSkillMethod()) + .addMethod(getUpdateSkillMethod()) + .addMethod(getDeleteSkillMethod()) + .addMethod(getListSkillsMethod()) + .addMethod(getSearchSkillsMethod()) + .addMethod(getCreateSkillRevisionMethod()) + .addMethod(getGetSkillRevisionMethod()) + .addMethod(getDeleteSkillRevisionMethod()) + .addMethod(getListSkillRevisionsMethod()) + .addMethod(getGetPublisherMethod()) + .addMethod(getListPublishersMethod()) + .addMethod(getGetAiApplicationMethod()) + .addMethod(getListAiApplicationsMethod()) + .addMethod(getGetAiApplicationAgentMethod()) + .addMethod(getListAiApplicationAgentsMethod()) + .addMethod(getGetAiApplicationMcpServerMethod()) + .addMethod(getListAiApplicationMcpServersMethod()) + .addMethod(getGetFindingMethod()) + .addMethod(getListFindingsMethod()) + .addMethod(getGetAiApplicationEndpointMethod()) + .addMethod(getListAiApplicationEndpointsMethod()) + .addMethod(getGetSkillEncryptionSpecMethod()) + .addMethod(getUpdateSkillEncryptionSpecMethod()) .build(); } } diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentName.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentName.java index 72f927457e37..c17fe723d608 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentName.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentName.java @@ -17,6 +17,7 @@ package com.google.cloud.agentregistry.v1; import com.google.api.pathtemplate.PathTemplate; +import com.google.api.pathtemplate.ValidationException; import com.google.api.resourcenames.ResourceName; import com.google.common.base.Preconditions; import com.google.common.collect.ImmutableMap; @@ -35,22 +36,39 @@ public class AgentName implements ResourceName { private static final PathTemplate PROJECT_LOCATION_AGENT = PathTemplate.createWithoutUrlEncoding( "projects/{project}/locations/{location}/agents/{agent}"); + private static final PathTemplate PROJECT_LOCATION_AI_APPLICATION_AGENT = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}"); private volatile Map fieldValuesMap; + private PathTemplate pathTemplate; + private String fixedValue; private final String project; private final String location; private final String agent; + private final String aiApplication; @Deprecated protected AgentName() { project = null; location = null; agent = null; + aiApplication = null; } private AgentName(Builder builder) { project = Preconditions.checkNotNull(builder.getProject()); location = Preconditions.checkNotNull(builder.getLocation()); agent = Preconditions.checkNotNull(builder.getAgent()); + aiApplication = null; + pathTemplate = PROJECT_LOCATION_AGENT; + } + + private AgentName(ProjectLocationAiApplicationAgentBuilder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + aiApplication = Preconditions.checkNotNull(builder.getAiApplication()); + agent = Preconditions.checkNotNull(builder.getAgent()); + pathTemplate = PROJECT_LOCATION_AI_APPLICATION_AGENT; } public String getProject() { @@ -65,10 +83,23 @@ public String getAgent() { return agent; } + public String getAiApplication() { + return aiApplication; + } + public static Builder newBuilder() { return new Builder(); } + public static Builder newProjectLocationAgentBuilder() { + return new Builder(); + } + + public static ProjectLocationAiApplicationAgentBuilder + newProjectLocationAiApplicationAgentBuilder() { + return new ProjectLocationAiApplicationAgentBuilder(); + } + public Builder toBuilder() { return new Builder(this); } @@ -77,6 +108,21 @@ public static AgentName of(String project, String location, String agent) { return newBuilder().setProject(project).setLocation(location).setAgent(agent).build(); } + public static AgentName ofProjectLocationAgentName( + String project, String location, String agent) { + return newBuilder().setProject(project).setLocation(location).setAgent(agent).build(); + } + + public static AgentName ofProjectLocationAiApplicationAgentName( + String project, String location, String aiApplication, String agent) { + return newProjectLocationAiApplicationAgentBuilder() + .setProject(project) + .setLocation(location) + .setAiApplication(aiApplication) + .setAgent(agent) + .build(); + } + public static String format(String project, String location, String agent) { return newBuilder() .setProject(project) @@ -86,14 +132,44 @@ public static String format(String project, String location, String agent) { .toString(); } + public static String formatProjectLocationAgentName( + String project, String location, String agent) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setAgent(agent) + .build() + .toString(); + } + + public static String formatProjectLocationAiApplicationAgentName( + String project, String location, String aiApplication, String agent) { + return newProjectLocationAiApplicationAgentBuilder() + .setProject(project) + .setLocation(location) + .setAiApplication(aiApplication) + .setAgent(agent) + .build() + .toString(); + } + public static @Nullable AgentName parse(String formattedString) { if (formattedString.isEmpty()) { return null; } - Map matchMap = - PROJECT_LOCATION_AGENT.validatedMatch( - formattedString, "AgentName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("agent")); + if (PROJECT_LOCATION_AGENT.matches(formattedString)) { + Map matchMap = PROJECT_LOCATION_AGENT.match(formattedString); + return ofProjectLocationAgentName( + matchMap.get("project"), matchMap.get("location"), matchMap.get("agent")); + } else if (PROJECT_LOCATION_AI_APPLICATION_AGENT.matches(formattedString)) { + Map matchMap = PROJECT_LOCATION_AI_APPLICATION_AGENT.match(formattedString); + return ofProjectLocationAiApplicationAgentName( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("ai_application"), + matchMap.get("agent")); + } + throw new ValidationException("AgentName.parse: formattedString not in valid format"); } public static List parseList(List formattedStrings) { @@ -117,7 +193,8 @@ public static List toStringList(List<@Nullable AgentName> values) { } public static boolean isParsableFrom(String formattedString) { - return PROJECT_LOCATION_AGENT.matches(formattedString); + return PROJECT_LOCATION_AGENT.matches(formattedString) + || PROJECT_LOCATION_AI_APPLICATION_AGENT.matches(formattedString); } @Override @@ -135,6 +212,9 @@ public Map getFieldValuesMap() { if (agent != null) { fieldMapBuilder.put("agent", agent); } + if (aiApplication != null) { + fieldMapBuilder.put("ai_application", aiApplication); + } fieldValuesMap = fieldMapBuilder.build(); } } @@ -148,8 +228,7 @@ public String getFieldValue(String fieldName) { @Override public String toString() { - return PROJECT_LOCATION_AGENT.instantiate( - "project", project, "location", location, "agent", agent); + return fixedValue != null ? fixedValue : pathTemplate.instantiate(getFieldValuesMap()); } @Override @@ -161,7 +240,8 @@ public boolean equals(@Nullable Object o) { AgentName that = ((AgentName) o); return Objects.equals(this.project, that.project) && Objects.equals(this.location, that.location) - && Objects.equals(this.agent, that.agent); + && Objects.equals(this.agent, that.agent) + && Objects.equals(this.aiApplication, that.aiApplication); } return false; } @@ -170,11 +250,15 @@ public boolean equals(@Nullable Object o) { public int hashCode() { int h = 1; h *= 1000003; + h ^= Objects.hashCode(fixedValue); + h *= 1000003; h ^= Objects.hashCode(project); h *= 1000003; h ^= Objects.hashCode(location); h *= 1000003; h ^= Objects.hashCode(agent); + h *= 1000003; + h ^= Objects.hashCode(aiApplication); return h; } @@ -214,6 +298,10 @@ public Builder setAgent(String agent) { } private Builder(AgentName agentName) { + Preconditions.checkArgument( + Objects.equals(agentName.pathTemplate, PROJECT_LOCATION_AGENT), + "toBuilder is only supported when AgentName has the pattern of" + + " projects/{project}/locations/{location}/agents/{agent}"); this.project = agentName.project; this.location = agentName.location; this.agent = agentName.agent; @@ -223,4 +311,57 @@ public AgentName build() { return new AgentName(this); } } + + /** + * Builder for + * projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}. + */ + public static class ProjectLocationAiApplicationAgentBuilder { + private String project; + private String location; + private String aiApplication; + private String agent; + + protected ProjectLocationAiApplicationAgentBuilder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAiApplication() { + return aiApplication; + } + + public String getAgent() { + return agent; + } + + public ProjectLocationAiApplicationAgentBuilder setProject(String project) { + this.project = project; + return this; + } + + public ProjectLocationAiApplicationAgentBuilder setLocation(String location) { + this.location = location; + return this; + } + + public ProjectLocationAiApplicationAgentBuilder setAiApplication(String aiApplication) { + this.aiApplication = aiApplication; + return this; + } + + public ProjectLocationAiApplicationAgentBuilder setAgent(String agent) { + this.agent = agent; + return this; + } + + public AgentName build() { + return new AgentName(this); + } + } } diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentProto.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentProto.java index 3707f6a3f3c1..75ccc4531cf5 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentProto.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentProto.java @@ -75,7 +75,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "le/api/field_behavior.proto\032\033google/api/" + "field_info.proto\032\031google/api/resource.pr" + "oto\032.google/cloud/agentregistry/v1/prope" - + "rties.proto\032\034google/protobuf/struct.proto\032\037google/protobuf/timestamp.proto\"\216\n\n" + + "rties.proto\032\034google/protobuf/struct.proto\032\037google/protobuf/timestamp.proto\"\350\n\n" + "\005Agent\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\026\n" + "\010agent_id\030\002 \001(\tB\004\342A\001\003\022\026\n" @@ -123,13 +123,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016A2A_AGENT_CARD\020\001\032J\n" + "\017AttributesEntry\022\013\n" + "\003key\030\001 \001(\t\022&\n" - + "\005value\030\002 \001(\0132\027.google.protobuf.Struct:\0028\001:n\352Ak\n" - + "\"agentregistry.googleapis.com/Agent\0226projects/{project}" - + "/locations/{location}/agents/{agent}*\006agents2\005agentB\335\001\n" + + "\005value\030\002" + + " \001(\0132\027.google.protobuf.Struct:\0028\001:\307\001\352A\303\001\n" + + "\"agentregistry.googleapis.com/Agent\0226projects/{projec" + + "t}/locations/{location}/agents/{agent}\022Vprojects/{project}/locations/{location}/" + + "aiApplications/{ai_application}/agents/{agent}*\006agents2\005agentB\335\001\n" + "!com.google.cloud.agentregistry.v1B\n" - + "AgentProtoP\001ZGcloud.google.com/go/agentregistry/apiv1/agentregistrypb" - + ";agentregistrypb\252\002\035Google.Cloud.AgentReg" - + "istry.V1\312\002\035Google\\Cloud\\AgentRegistry\\V1\352\002" + + "AgentProtoP\001ZGcloud.google.com/go/agentregistry/apiv1/agent" + + "registrypb;agentregistrypb\252\002\035Google.Clou" + + "d.AgentRegistry.V1\312\002\035Google\\Cloud\\AgentRegistry\\V1\352\002" + " Google::Cloud::AgentRegistry::V1b\006proto3" }; descriptor = diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryServiceProto.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryServiceProto.java index f7a695c96bed..81f5bab7dc56 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryServiceProto.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AgentRegistryServiceProto.java @@ -60,6 +60,18 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_agentregistry_v1_GetAgentRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_agentregistry_v1_GetAgentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_GetAiApplicationAgentRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_GetAiApplicationAgentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsResponse_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_agentregistry_v1_ListEndpointsRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -72,6 +84,18 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_agentregistry_v1_GetEndpointRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_agentregistry_v1_GetEndpointRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_GetAiApplicationEndpointRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_GetAiApplicationEndpointRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsResponse_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_agentregistry_v1_ListMcpServersRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -92,6 +116,18 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_agentregistry_v1_GetMcpServerRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_agentregistry_v1_GetMcpServerRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_GetAiApplicationMcpServerRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_GetAiApplicationMcpServerRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersResponse_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_agentregistry_v1_ListServicesRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -152,6 +188,102 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_agentregistry_v1_DeleteBindingRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_agentregistry_v1_DeleteBindingRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_CreateSkillRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_CreateSkillRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_GetSkillRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_GetSkillRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_UpdateSkillRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_UpdateSkillRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_DeleteSkillRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_DeleteSkillRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListSkillsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListSkillsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListSkillsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListSkillsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_SearchSkillsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_SearchSkillsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_SearchSkillsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_SearchSkillsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_CreateSkillRevisionRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_CreateSkillRevisionRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_GetSkillRevisionRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_GetSkillRevisionRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_DeleteSkillRevisionRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_DeleteSkillRevisionRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_GetPublisherRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_GetPublisherRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListPublishersRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListPublishersRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListPublishersResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListPublishersResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_GetAiApplicationRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_GetAiApplicationRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListAiApplicationsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListAiApplicationsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListAiApplicationsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListAiApplicationsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListFindingsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListFindingsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ListFindingsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ListFindingsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_GetFindingRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_GetFindingRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_GetSkillEncryptionSpecRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_GetSkillEncryptionSpecRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_UpdateSkillEncryptionSpecRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_UpdateSkillEncryptionSpecRequest_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -167,24 +299,28 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\032\027google/api/client.proto\032\037google/api/fi" + "eld_behavior.proto\032\033google/api/field_inf" + "o.proto\032\031google/api/resource.proto\032)goog" - + "le/cloud/agentregistry/v1/agent.proto\032+google/cloud/agentregistry/v1/binding.pro" - + "to\032,google/cloud/agentregistry/v1/endpoint.proto\032.google/cloud/agentregistry/v1/" - + "mcp_server.proto\032+google/cloud/agentregistry/v1/service.proto\032#google/longrunnin" - + "g/operations.proto\032\033google/protobuf/empty.proto\032" - + " google/protobuf/field_mask.proto\032\037google/protobuf/timestamp.proto\"\261\001\n" - + "\021ListAgentsRequest\022;\n" - + "\006parent\030\001 \001(" - + "\tB+\342A\001\002\372A$\022\"agentregistry.googleapis.com/Agent\022\027\n" + + "le/cloud/agentregistry/v1/agent.proto\0322google/cloud/agentregistry/v1/ai_applicat" + + "ion.proto\032+google/cloud/agentregistry/v1/binding.proto\032,google/cloud/agentregist" + + "ry/v1/endpoint.proto\032+google/cloud/agentregistry/v1/finding.proto\032.google/cloud/" + + "agentregistry/v1/mcp_server.proto\032+google/cloud/agentregistry/v1/service.proto\032)" + + "google/cloud/agentregistry/v1/skill.proto\0329google/cloud/agentregistry/v1/skill_e" + + "ncryption_spec.proto\032#google/longrunning" + + "/operations.proto\032\033google/protobuf/empty.proto\032" + + " google/protobuf/field_mask.proto\032\037google/protobuf/timestamp.proto\"\260\001\n" + + "\021ListAgentsRequest\022:\n" + + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + + "!locations.googleapis.com/Location\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\022\026\n" + "\010order_by\030\005 \001(\tB\004\342A\001\001\"c\n" + "\022ListAgentsResponse\0224\n" + "\006agents\030\001 \003(\0132$.google.cloud.agentregistry.v1.Agent\022\027\n" - + "\017next_page_token\030\002 \001(\t\"\242\001\n" - + "\023SearchAgentsRequest\022;\n" - + "\006parent\030\001 \001(\tB+\342A\001" - + "\002\372A$\022\"agentregistry.googleapis.com/Agent\022\033\n\r" + + "\017next_page_token\030\002 \001(\t\"\241\001\n" + + "\023SearchAgentsRequest\022:\n" + + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + + "!locations.googleapis.com/Location\022\033\n" + + "\r" + "search_string\030\003 \001(\tB\004\342A\001\001\022\027\n" + "\tpage_size\030\006 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\007 \001(\tB\004\342A\001\001\"e\n" @@ -193,10 +329,21 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017next_page_token\030\002 \001(\t\"L\n" + "\017GetAgentRequest\0229\n" + "\004name\030\001 \001(\tB+\342A\001\002\372A$\n" - + "\"agentregistry.googleapis.com/Agent\"\237\001\n" - + "\024ListEndpointsRequest\022>\n" - + "\006parent\030\001 \001(" - + "\tB.\342A\001\002\372A\'\022%agentregistry.googleapis.com/Endpoint\022\027\n" + + "\"agentregistry.googleapis.com/Agent\"Y\n" + + "\034GetAiApplicationAgentRequest\0229\n" + + "\004name\030\001 \001(\tB+\342A\001\002\372A$\n" + + "\"agentregistry.googleapis.com/Agent\"\230\001\n" + + "\036ListAiApplicationAgentsRequest\022C\n" + + "\006parent\030\001 \001(\tB3\342A\001\002\372A,\n" + + "*agentregistry.googleapis.com/AiApplication\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\"p\n" + + "\037ListAiApplicationAgentsResponse\0224\n" + + "\006agents\030\001 \003(\0132$.google.cloud.agentregistry.v1.Agent\022\027\n" + + "\017next_page_token\030\002 \001(\t\"\233\001\n" + + "\024ListEndpointsRequest\022:\n" + + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + + "!locations.googleapis.com/Location\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\"l\n" @@ -205,20 +352,31 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017next_page_token\030\002 \001(\t\"R\n" + "\022GetEndpointRequest\022<\n" + "\004name\030\001 \001(\tB.\342A\001\002\372A\'\n" - + "%agentregistry.googleapis.com/Endpoint\"\271\001\n" - + "\025ListMcpServersRequest\022?\n" - + "\006parent\030\001 \001(" - + "\tB/\342A\001\002\372A(\022&agentregistry.googleapis.com/McpServer\022\027\n" + + "%agentregistry.googleapis.com/Endpoint\"_\n" + + "\037GetAiApplicationEndpointRequest\022<\n" + + "\004name\030\001 \001(\tB.\342A\001\002\372A\'\n" + + "%agentregistry.googleapis.com/Endpoint\"\233\001\n" + + "!ListAiApplicationEndpointsRequest\022C\n" + + "\006parent\030\001 \001(\tB3\342A\001\002\372A,\n" + + "*agentregistry.googleapis.com/AiApplication\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\"y\n" + + "\"ListAiApplicationEndpointsResponse\022:\n" + + "\tendpoints\030\001 \003(\0132\'.google.cloud.agentregistry.v1.Endpoint\022\027\n" + + "\017next_page_token\030\002 \001(\t\"\264\001\n" + + "\025ListMcpServersRequest\022:\n" + + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + + "!locations.googleapis.com/Location\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\022\026\n" + "\010order_by\030\005 \001(\tB\004\342A\001\001\"p\n" + "\026ListMcpServersResponse\022=\n" + "\013mcp_servers\030\001 \003(\0132(.google.cloud.agentregistry.v1.McpServer\022\027\n" - + "\017next_page_token\030\002 \001(\t\"\252\001\n" - + "\027SearchMcpServersRequest\022?\n" - + "\006parent\030\001 \001(" - + "\tB/\342A\001\002\372A(\022&agentregistry.googleapis.com/McpServer\022\033\n\r" + + "\017next_page_token\030\002 \001(\t\"\245\001\n" + + "\027SearchMcpServersRequest\022:\n" + + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + + "!locations.googleapis.com/Location\022\033\n\r" + "search_string\030\003 \001(\tB\004\342A\001\001\022\027\n" + "\tpage_size\030\006 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\007 \001(\tB\004\342A\001\001\"r\n" @@ -227,10 +385,21 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017next_page_token\030\002 \001(\t\"T\n" + "\023GetMcpServerRequest\022=\n" + "\004name\030\001 \001(\tB/\342A\001\002\372A(\n" - + "&agentregistry.googleapis.com/McpServer\"\235\001\n" + + "&agentregistry.googleapis.com/McpServer\"a\n" + + " GetAiApplicationMcpServerRequest\022=\n" + + "\004name\030\001 \001(\tB/\342A\001\002\372A(\n" + + "&agentregistry.googleapis.com/McpServer\"\234\001\n" + + "\"ListAiApplicationMcpServersRequest\022C\n" + + "\006parent\030\001 \001(\tB3\342A\001\002\372A,\n" + + "*agentregistry.googleapis.com/AiApplication\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\"}\n" + + "#ListAiApplicationMcpServersResponse\022=\n" + + "\013mcp_servers\030\001 \003(\0132(.google.cloud.agentregistry.v1.McpServer\022\027\n" + + "\017next_page_token\030\002 \001(\t\"\235\001\n" + "\023ListServicesRequest\022=\n" - + "\006parent\030\001 \001(" - + "\tB-\342A\001\002\372A&\022$agentregistry.googleapis.com/Service\022\027\n" + + "\006parent\030\001 \001(\t" + + "B-\342A\001\002\372A&\022$agentregistry.googleapis.com/Service\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\"i\n" @@ -242,17 +411,18 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "$agentregistry.googleapis.com/Service\"\320\001\n" + "\024CreateServiceRequest\022=\n" + "\006parent\030\001 \001(" - + "\tB-\342A\001\002\372A&\022$agentregistry.googleapis.com/Service\022\030\n\n" + + "\tB-\342A\001\002\372A&\022$agentregistry.googleapis.com/Service\022\030\n" + + "\n" + "service_id\030\002 \001(\tB\004\342A\001\002\022=\n" - + "\007service\030\003" - + " \001(\0132&.google.cloud.agentregistry.v1.ServiceB\004\342A\001\002\022 \n\n" + + "\007service\030\003 \001(\013" + + "2&.google.cloud.agentregistry.v1.ServiceB\004\342A\001\002\022 \n\n" + "request_id\030\004 \001(" + "\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"\345\001\n" + "\035FetchAvailableBindingsRequest\022\033\n" + "\021source_identifier\030\002 \001(\tH\000\022!\n" + "\021target_identifier\030\003 \001(\tB\004\342A\001\001H\001\022=\n" - + "\006parent\030\001 \001(" - + "\tB-\342A\001\002\372A&\022$agentregistry.googleapis.com/Binding\022\027\n" + + "\006parent\030\001 \001(\tB-\342A\001\002" + + "\372A&\022$agentregistry.googleapis.com/Binding\022\027\n" + "\tpage_size\030\004 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\005 \001(\tB\004\342A\001\001B\010\n" + "\006sourceB\010\n" @@ -282,10 +452,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\026requested_cancellation\030\006 \001(\010B\004\342A\001\003\022\031\n" + "\013api_version\030\007 \001(\tB\004\342A\001\003\"\265\001\n" + "\023ListBindingsRequest\022=\n" - + "\006parent\030\001 \001(" - + "\tB-\342A\001\002\372A&\022$agentregistry.googleapis.com/Binding\022\027\n" - + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n" - + "\n" + + "\006parent\030\001 \001(\tB-\342A\001\002\372A&" + + "\022$agentregistry.googleapis.com/Binding\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\022\026\n" + "\010order_by\030\005 \001(\tB\004\342A\001\001\"i\n" @@ -311,91 +480,328 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "request_id\030\003 \001(\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"u\n" + "\024DeleteBindingRequest\022;\n" + "\004name\030\001 \001(\tB-\342A\001\002\372A&\n" - + "$agentregistry.googleapis.com/Binding\022 \n\n" + + "$agentregistry.googleapis.com/Binding\022 \n" + + "\n" + "request_id\030\002 \001(" - + "\tB\014\342A\001\001\342\214\317\327\010\002\010\0012\214\037\n\r" + + "\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"\306\001\n" + + "\022CreateSkillRequest\022;\n" + + "\006parent\030\001 \001(" + + "\tB+\342A\001\002\372A$\022\"agentregistry.googleapis.com/Skill\022\026\n" + + "\010skill_id\030\002 \001(\tB\004\342A\001\002\0229\n" + + "\005skill\030\003" + + " \001(\0132$.google.cloud.agentregistry.v1.SkillB\004\342A\001\002\022 \n\n" + + "request_id\030\004 \001(\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"L\n" + + "\017GetSkillRequest\0229\n" + + "\004name\030\001 \001(\tB+\342A\001\002\372A$\n" + + "\"agentregistry.googleapis.com/Skill\"\250\001\n" + + "\022UpdateSkillRequest\0229\n" + + "\005skill\030\001" + + " \001(\0132$.google.cloud.agentregistry.v1.SkillB\004\342A\001\002\0225\n" + + "\013update_mask\030\002 \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022" + + " \n\n" + + "request_id\030\003 \001(" + + "\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"\206\001\n" + + "\022DeleteSkillRequest\0229\n" + + "\004name\030\001 \001(\tB+\342A\001\002\372A$\n" + + "\"agentregistry.googleapis.com/Skill\022 \n\n" + + "request_id\030\002 \001(\tB\014\342A\001\001\342\214\317\327\010\002\010\001\022\023\n" + + "\005force\030\003 \001(\010B\004\342A\001\001\"\261\001\n" + + "\021ListSkillsRequest\022;\n" + + "\006parent\030\001 \001(" + + "\tB+\342A\001\002\372A$\022\"agentregistry.googleapis.com/Skill\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + + "\006filter\030\004 \001(\tB\004\342A\001\001\022\026\n" + + "\010order_by\030\005 \001(\tB\004\342A\001\001\"x\n" + + "\022ListSkillsResponse\0224\n" + + "\006skills\030\001 \003(\0132$.google.cloud.agentregistry.v1.Skill\022\027\n" + + "\017next_page_token\030\002 \001(\t\022\023\n" + + "\013unreachable\030\003 \003(\t\"\376\001\n" + + "\023SearchSkillsRequest\022;\n" + + "\006parent\030\001 \001(\t" + + "B+\342A\001\002\372A$\022\"agentregistry.googleapis.com/Skill\022D\n" + + "\013search_type\030\006" + + " \001(\0162).google.cloud.agentregistry.v1.SearchTypeB\004\342A\001\001\022\033\n\r" + + "search_string\030\007 \001(\tB\004\342A\001\001\022\024\n" + + "\006filter\030\005 \001(\tB\004\342A\001\001\022\027\n" + + "\tpage_size\030\003 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\004 \001(\tB\004\342A\001\001\"e\n" + + "\024SearchSkillsResponse\0224\n" + + "\006skills\030\001 \003(\0132$.google.cloud.agentregistry.v1.Skill\022\027\n" + + "\017next_page_token\030\002 \001(\t\"\350\001\n" + + "\032CreateSkillRevisionRequest\022;\n" + + "\006parent\030\001 \001(\tB+\342A\001\002\372A$\n" + + "\"agentregistry.googleapis.com/Skill\022J\n" + + "\016skill_revision\030\002 \001(\0132,.g" + + "oogle.cloud.agentregistry.v1.SkillRevisionB\004\342A\001\002\022\037\n" + + "\021skill_revision_id\030\003 \001(\tB\004\342A\001\001\022 \n\n" + + "request_id\030\004 \001(\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"\\\n" + + "\027GetSkillRevisionRequest\022A\n" + + "\004name\030\001 \001(\tB3\342A\001\002\372A,\n" + + "*agentregistry.googleapis.com/SkillRevision\"\201\001\n" + + "\032DeleteSkillRevisionRequest\022A\n" + + "\004name\030\001 \001(\tB3\342A\001\002\372A,\n" + + "*agentregistry.googleapis.com/SkillRevision\022 \n\n" + + "request_id\030\002 \001(" + + "\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"\213\001\n" + + "\031ListSkillRevisionsRequest\022;\n" + + "\006parent\030\001 \001(\tB+\342A\001\002\372A$\n" + + "\"agentregistry.googleapis.com/Skill\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\"|\n" + + "\032ListSkillRevisionsResponse\022E\n" + + "\017skill_revisions\030\001" + + " \003(\0132,.google.cloud.agentregistry.v1.SkillRevision\022\027\n" + + "\017next_page_token\030\002 \001(\t\"T\n" + + "\023GetPublisherRequest\022=\n" + + "\004name\030\001 \001(\tB/\342A\001\002\372A(\n" + + "&agentregistry.googleapis.com/Publisher\"\213\001\n" + + "\025ListPublishersRequest\022?\n" + + "\006parent\030\001 \001(" + + "\tB/\342A\001\002\372A(\022&agentregistry.googleapis.com/Publisher\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\"o\n" + + "\026ListPublishersResponse\022<\n\n" + + "publishers\030\001 \003(\0132(.google.cloud.agentregistry.v1.Publisher\022\027\n" + + "\017next_page_token\030\002 \001(\t\"\\\n" + + "\027GetAiApplicationRequest\022A\n" + + "\004name\030\001 \001(\tB3\342A\001\002\372A,\n" + + "*agentregistry.googleapis.com/AiApplication\"\301\001\n" + + "\031ListAiApplicationsRequest\022C\n" + + "\006parent\030\001 \001(" + + "\tB3\342A\001\002\372A,\022*agentregistry.googleapis.com/AiApplication\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + + "\006filter\030\004 \001(\tB\004\342A\001\001\022\026\n" + + "\010order_by\030\005 \001(\tB\004\342A\001\001\"\227\001\n" + + "\032ListAiApplicationsResponse\022E\n" + + "\017ai_applications\030\001" + + " \003(\0132,.google.cloud.agentregistry.v1.AiApplication\022\027\n" + + "\017next_page_token\030\002 \001(\t\022\031\n" + + "\013unreachable\030\003 \003(\tB\004\342A\001\006\"\265\001\n" + + "\023ListFindingsRequest\022=\n" + + "\006parent\030\001 \001(\tB-\342A\001\002" + + "\372A&\022$agentregistry.googleapis.com/Finding\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + + "\006filter\030\004 \001(\tB\004\342A\001\001\022\026\n" + + "\010order_by\030\005 \001(\tB\004\342A\001\001\"i\n" + + "\024ListFindingsResponse\0228\n" + + "\010findings\030\001 \003(\0132&.google.cloud.agentregistry.v1.Finding\022\027\n" + + "\017next_page_token\030\002 \001(\t\"P\n" + + "\021GetFindingRequest\022;\n" + + "\004name\030\001 \001(\tB-\342A\001\002\372A&\n" + + "$agentregistry.googleapis.com/Finding\"h\n" + + "\035GetSkillEncryptionSpecRequest\022G\n" + + "\004name\030\001 \001(\tB9\342A\001\002\372A2\n" + + "0agentregistry.googleapis.com/SkillEncryptionSpec\"\262\001\n" + + " UpdateSkillEncryptionSpecRequest\022W\n" + + "\025skill_encryption_spec\030\001 \001(\01322.google.cloud.age" + + "ntregistry.v1.SkillEncryptionSpecB\004\342A\001\002\0225\n" + + "\013update_mask\030\002" + + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001*D\n\n" + + "SearchType\022\033\n" + + "\027SEARCH_TYPE_UNSPECIFIED\020\000\022\013\n" + + "\007KEYWORD\020\001\022\014\n" + + "\010SEMANTIC\020\0022\377F\n\r" + "AgentRegistry\022\256\001\n\n" - + "ListAgents\0220.google.cloud.agentregistry.v1.ListAgent" - + "sRequest\0321.google.cloud.agentregistry.v1" - + ".ListAgentsResponse\";\332A\006parent\202\323\344\223\002,\022*/v" - + "1/{parent=projects/*/locations/*}/agents\022\276\001\n" - + "\014SearchAgents\0222.google.cloud.agentregistry.v1.SearchAgentsRequest\0323.google.c" - + "loud.agentregistry.v1.SearchAgentsRespon" - + "se\"E\332A\006parent\202\323\344\223\0026\"1/v1/{parent=projects/*/locations/*}/agents:search:\001*\022\233\001\n" - + "\010GetAgent\022..google.cloud.agentregistry.v1.G" - + "etAgentRequest\032$.google.cloud.agentregis" - + "try.v1.Agent\"9\332A\004name\202\323\344\223\002,\022*/v1/{name=projects/*/locations/*/agents/*}\022\272\001\n\r" - + "ListEndpoints\0223.google.cloud.agentregistry.v" - + "1.ListEndpointsRequest\0324.google.cloud.ag" - + "entregistry.v1.ListEndpointsResponse\">\332A" - + "\006parent\202\323\344\223\002/\022-/v1/{parent=projects/*/locations/*}/endpoints\022\247\001\n" - + "\013GetEndpoint\0221.google.cloud.agentregistry.v1.GetEndpoint" - + "Request\032\'.google.cloud.agentregistry.v1." - + "Endpoint\"<\332A\004name\202\323\344\223\002/\022-/v1/{name=projects/*/locations/*/endpoints/*}\022\276\001\n" - + "\016ListMcpServers\0224.google.cloud.agentregistry.v" - + "1.ListMcpServersRequest\0325.google.cloud.agentregistry.v1.ListMcpServersResponse\"?" - + "\332A\006parent\202\323\344\223\0020\022./v1/{parent=projects/*/locations/*}/mcpServers\022\316\001\n" - + "\020SearchMcpServers\0226.google.cloud.agentregistry.v1.Sea" - + "rchMcpServersRequest\0327.google.cloud.agen" - + "tregistry.v1.SearchMcpServersResponse\"I\332" - + "A\006parent\202\323\344\223\002:\"5/v1/{parent=projects/*/locations/*}/mcpServers:search:\001*\022\253\001\n" - + "\014GetMcpServer\0222.google.cloud.agentregistry.v" - + "1.GetMcpServerRequest\032(.google.cloud.age" - + "ntregistry.v1.McpServer\"=\332A\004name\202\323\344\223\0020\022." - + "/v1/{name=projects/*/locations/*/mcpServers/*}\022\266\001\n" - + "\014ListServices\0222.google.cloud.agentregistry.v1.ListServicesRequest\0323.go" - + "ogle.cloud.agentregistry.v1.ListServices" - + "Response\"=\332A\006parent\202\323\344\223\002.\022,/v1/{parent=projects/*/locations/*}/services\022\243\001\n\n" - + "GetService\0220.google.cloud.agentregistry.v1.G" - + "etServiceRequest\032&.google.cloud.agentreg" - + "istry.v1.Service\";\332A\004name\202\323\344\223\002.\022,/v1/{na" - + "me=projects/*/locations/*/services/*}\022\335\001\n\r" - + "CreateService\0223.google.cloud.agentregi" - + "stry.v1.CreateServiceRequest\032\035.google.longrunning.Operation\"x\312A\034\n" - + "\007Service\022\021OperationMetadata\332A\031parent,service,service_id" - + "\202\323\344\223\0027\",/v1/{parent=projects/*/locations/*}/services:\007service\022\337\001\n\r" - + "UpdateService\0223.google.cloud.agentregistry.v1.UpdateSe" - + "rviceRequest\032\035.google.longrunning.Operation\"z\312A\034\n" - + "\007Service\022\021OperationMetadata\332A\023s" - + "ervice,update_mask\202\323\344\223\002?24/v1/{service.n" - + "ame=projects/*/locations/*/services/*}:\007service\022\315\001\n\r" - + "DeleteService\0223.google.cloud" - + ".agentregistry.v1.DeleteServiceRequest\032\035.google.longrunning.Operation\"h\312A*\n" - + "\025google.protobuf.Empty\022\021OperationMetadata\332A\004n" - + "ame\202\323\344\223\002.*,/v1/{name=projects/*/locations/*/services/*}\022\266\001\n" - + "\014ListBindings\0222.google.cloud.agentregistry.v1.ListBindingsReq" - + "uest\0323.google.cloud.agentregistry.v1.Lis" - + "tBindingsResponse\"=\332A\006parent\202\323\344\223\002.\022,/v1/" - + "{parent=projects/*/locations/*}/bindings\022\243\001\n\n" - + "GetBinding\0220.google.cloud.agentregistry.v1.GetBindingRequest\032&.google.cloud" - + ".agentregistry.v1.Binding\";\332A\004name\202\323\344\223\002." - + "\022,/v1/{name=projects/*/locations/*/bindings/*}\022\335\001\n\r" - + "CreateBinding\0223.google.cloud." - + "agentregistry.v1.CreateBindingRequest\032\035.google.longrunning.Operation\"x\312A\034\n" - + "\007Binding\022\021OperationMetadata\332A\031parent,binding,b" - + "inding_id\202\323\344\223\0027\",/v1/{parent=projects/*/locations/*}/bindings:\007binding\022\337\001\n\r" - + "UpdateBinding\0223.google.cloud.agentregistry.v1" - + ".UpdateBindingRequest\032\035.google.longrunning.Operation\"z\312A\034\n" - + "\007Binding\022\021OperationMet" - + "adata\332A\023binding,update_mask\202\323\344\223\002?24/v1/{" - + "binding.name=projects/*/locations/*/bindings/*}:\007binding\022\315\001\n\r" - + "DeleteBinding\0223.google.cloud.agentregistry.v1.DeleteBinding" - + "Request\032\035.google.longrunning.Operation\"h\312A*\n" - + "\025google.protobuf.Empty\022\021OperationMet" - + "adata\332A\004name\202\323\344\223\002.*,/v1/{name=projects/*/locations/*/bindings/*}\022\343\001\n" - + "\026FetchAvailableBindings\022<.google.cloud.agentregistry" - + ".v1.FetchAvailableBindingsRequest\032=.google.cloud.agentregistry.v1.FetchAvailable" - + "BindingsResponse\"L\332A\006parent\202\323\344\223\002=\022;/v1/{" - + "parent=projects/*/locations/*}/bindings:" - + "fetchAvailable\032\373\001\312A\034agentregistry.google" - + "apis.com\322A\330\001https://www.googleapis.com/a" - + "uth/agentregistry.read-only,https://www.googleapis.com/auth/agentregistry.read-w" - + "rite,https://www.googleapis.com/auth/clo" - + "ud-platform,https://www.googleapis.com/auth/cloud-platform.read-onlyB\354\001\n" - + "!com.google.cloud.agentregistry.v1B\031AgentRegistr" - + "yServiceProtoP\001ZGcloud.google.com/go/agentregistry/apiv1/agentregistrypb;agentre" - + "gistrypb\252\002\035Google.Cloud.AgentRegistry.V1\312\002\035Google\\Cloud\\AgentRegistry\\V1\352\002" - + " Google::Cloud::AgentRegistry::V1b\006proto3" + + "ListAgents\0220.google.cloud.agentregistry.v1.ListAgents" + + "Request\0321.google.cloud.agentregistry.v1." + + "ListAgentsResponse\";\332A\006parent\202\323\344\223\002,\022*/v1" + + "/{parent=projects/*/locations/*}/agents\022\276\001\n" + + "\014SearchAgents\0222.google.cloud.agentregistry.v1.SearchAgentsRequest\0323.google.cl" + + "oud.agentregistry.v1.SearchAgentsRespons" + + "e\"E\332A\006parent\202\323\344\223\0026\"1/v1/{parent=projects/*/locations/*}/agents:search:\001*\022\233\001\n" + + "\010GetAgent\022..google.cloud.agentregistry.v1.Ge" + + "tAgentRequest\032$.google.cloud.agentregist" + + "ry.v1.Agent\"9\332A\004name\202\323\344\223\002,\022*/v1/{name=projects/*/locations/*/agents/*}\022\272\001\n\r" + + "ListEndpoints\0223.google.cloud.agentregistry.v1" + + ".ListEndpointsRequest\0324.google.cloud.age" + + "ntregistry.v1.ListEndpointsResponse\">\332A\006" + + "parent\202\323\344\223\002/\022-/v1/{parent=projects/*/locations/*}/endpoints\022\247\001\n" + + "\013GetEndpoint\0221.google.cloud.agentregistry.v1.GetEndpointR" + + "equest\032\'.google.cloud.agentregistry.v1.E" + + "ndpoint\"<\332A\004name\202\323\344\223\002/\022-/v1/{name=projects/*/locations/*/endpoints/*}\022\276\001\n" + + "\016ListMcpServers\0224.google.cloud.agentregistry.v1" + + ".ListMcpServersRequest\0325.google.cloud.ag" + + "entregistry.v1.ListMcpServersResponse\"?\332" + + "A\006parent\202\323\344\223\0020\022./v1/{parent=projects/*/locations/*}/mcpServers\022\316\001\n" + + "\020SearchMcpServers\0226.google.cloud.agentregistry.v1.Sear" + + "chMcpServersRequest\0327.google.cloud.agent" + + "registry.v1.SearchMcpServersResponse\"I\332A" + + "\006parent\202\323\344\223\002:\"5/v1/{parent=projects/*/locations/*}/mcpServers:search:\001*\022\253\001\n" + + "\014GetMcpServer\0222.google.cloud.agentregistry.v1" + + ".GetMcpServerRequest\032(.google.cloud.agen" + + "tregistry.v1.McpServer\"=\332A\004name\202\323\344\223\0020\022./" + + "v1/{name=projects/*/locations/*/mcpServers/*}\022\266\001\n" + + "\014ListServices\0222.google.cloud.agentregistry.v1.ListServicesRequest\0323.goo" + + "gle.cloud.agentregistry.v1.ListServicesR" + + "esponse\"=\332A\006parent\202\323\344\223\002.\022,/v1/{parent=projects/*/locations/*}/services\022\243\001\n\n" + + "GetService\0220.google.cloud.agentregistry.v1.Ge" + + "tServiceRequest\032&.google.cloud.agentregi" + + "stry.v1.Service\";\332A\004name\202\323\344\223\002.\022,/v1/{name=projects/*/locations/*/services/*}\022\335\001\n" + + "\r" + + "CreateService\0223.google.cloud.agentregis" + + "try.v1.CreateServiceRequest\032\035.google.longrunning.Operation\"x\312A\034\n" + + "\007Service\022\021OperationMetadata\332A\031parent,service,service_id\202" + + "\323\344\223\0027\",/v1/{parent=projects/*/locations/*}/services:\007service\022\337\001\n\r" + + "UpdateService\0223.google.cloud.agentregistry.v1.UpdateSer" + + "viceRequest\032\035.google.longrunning.Operation\"z\312A\034\n" + + "\007Service\022\021OperationMetadata\332A\023se" + + "rvice,update_mask\202\323\344\223\002?24/v1/{service.na" + + "me=projects/*/locations/*/services/*}:\007service\022\315\001\n\r" + + "DeleteService\0223.google.cloud." + + "agentregistry.v1.DeleteServiceRequest\032\035.google.longrunning.Operation\"h\312A*\n" + + "\025google.protobuf.Empty\022\021OperationMetadata\332A\004na" + + "me\202\323\344\223\002.*,/v1/{name=projects/*/locations/*/services/*}\022\266\001\n" + + "\014ListBindings\0222.google.cloud.agentregistry.v1.ListBindingsRequ" + + "est\0323.google.cloud.agentregistry.v1.List" + + "BindingsResponse\"=\332A\006parent\202\323\344\223\002.\022,/v1/{" + + "parent=projects/*/locations/*}/bindings\022\243\001\n\n" + + "GetBinding\0220.google.cloud.agentregistry.v1.GetBindingRequest\032&.google.cloud." + + "agentregistry.v1.Binding\";\332A\004name\202\323\344\223\002.\022" + + ",/v1/{name=projects/*/locations/*/bindings/*}\022\335\001\n\r" + + "CreateBinding\0223.google.cloud.a" + + "gentregistry.v1.CreateBindingRequest\032\035.google.longrunning.Operation\"x\312A\034\n" + + "\007Binding\022\021OperationMetadata\332A\031parent,binding,bi" + + "nding_id\202\323\344\223\0027\",/v1/{parent=projects/*/locations/*}/bindings:\007binding\022\337\001\n\r" + + "UpdateBinding\0223.google.cloud.agentregistry.v1." + + "UpdateBindingRequest\032\035.google.longrunning.Operation\"z\312A\034\n" + + "\007Binding\022\021OperationMeta" + + "data\332A\023binding,update_mask\202\323\344\223\002?24/v1/{b" + + "inding.name=projects/*/locations/*/bindings/*}:\007binding\022\315\001\n\r" + + "DeleteBinding\0223.google.cloud.agentregistry.v1.DeleteBindingR" + + "equest\032\035.google.longrunning.Operation\"h\312A*\n" + + "\025google.protobuf.Empty\022\021OperationMeta" + + "data\332A\004name\202\323\344\223\002.*,/v1/{name=projects/*/locations/*/bindings/*}\022\343\001\n" + + "\026FetchAvailableBindings\022<.google.cloud.agentregistry." + + "v1.FetchAvailableBindingsRequest\032=.google.cloud.agentregistry.v1.FetchAvailableB" + + "indingsResponse\"L\332A\006parent\202\323\344\223\002=\022;/v1/{p" + + "arent=projects/*/locations/*}/bindings:fetchAvailable\022\317\001\n" + + "\013CreateSkill\0221.google.c" + + "loud.agentregistry.v1.CreateSkillRequest\032\035.google.longrunning.Operation\"n\312A\032\n" + + "\005Skill\022\021OperationMetadata\332A\025parent,skill,sk" + + "ill_id\202\323\344\223\0023\"*/v1/{parent=projects/*/locations/*}/skills:\005skill\022\233\001\n" + + "\010GetSkill\022..google.cloud.agentregistry.v1.GetSkillReq" + + "uest\032$.google.cloud.agentregistry.v1.Ski" + + "ll\"9\332A\004name\202\323\344\223\002,\022*/v1/{name=projects/*/locations/*/skills/*}\022\321\001\n" + + "\013UpdateSkill\0221.google.cloud.agentregistry.v1.UpdateSkil" + + "lRequest\032\035.google.longrunning.Operation\"p\312A\032\n" + + "\005Skill\022\021OperationMetadata\332A\021skill,u" + + "pdate_mask\202\323\344\223\002920/v1/{skill.name=projects/*/locations/*/skills/*}:\005skill\022\307\001\n" + + "\013DeleteSkill\0221.google.cloud.agentregistry.v" + + "1.DeleteSkillRequest\032\035.google.longrunning.Operation\"f\312A*\n" + + "\025google.protobuf.Empty\022" + + "\021OperationMetadata\332A\004name\202\323\344\223\002,**/v1/{name=projects/*/locations/*/skills/*}\022\256\001\n\n" + + "ListSkills\0220.google.cloud.agentregistry.v1.ListSkillsRequest\0321.google.cloud.agen" + + "tregistry.v1.ListSkillsResponse\";\332A\006pare" + + "nt\202\323\344\223\002,\022*/v1/{parent=projects/*/locations/*}/skills\022\352\001\n" + + "\014SearchSkills\0222.google.cloud.agentregistry.v1.SearchSkillsReques" + + "t\0323.google.cloud.agentregistry.v1.Search" + + "SkillsResponse\"q\202\323\344\223\002k\"1/v1/{parent=proj" + + "ects/*/locations/*}/skills:search:\001*Z3\0221" + + "/v1/{parent=projects/*/locations/*}/skills:search\022\217\002\n" + + "\023CreateSkillRevision\0229.google.cloud.agentregistry.v1.CreateSkillRev" + + "isionRequest\032\035.google.longrunning.Operation\"\235\001\312A\"\n\r" + + "SkillRevision\022\021OperationMetadata\332A\'parent,skill_revision,skill_revisi" + + "on_id\202\323\344\223\002H\"6/v1/{parent=projects/*/loca" + + "tions/*/skills/*}/revisions:\016skill_revision\022\277\001\n" + + "\020GetSkillRevision\0226.google.cloud.agentregistry.v1.GetSkillRevisionRequest" + + "\032,.google.cloud.agentregistry.v1.SkillRe" + + "vision\"E\332A\004name\202\323\344\223\0028\0226/v1/{name=project" + + "s/*/locations/*/skills/*/revisions/*}\022\343\001\n" + + "\023DeleteSkillRevision\0229.google.cloud.age" + + "ntregistry.v1.DeleteSkillRevisionRequest\032\035.google.longrunning.Operation\"r\312A*\n" + + "\025google.protobuf.Empty\022\021OperationMetadata\332A" + + "\004name\202\323\344\223\0028*6/v1/{name=projects/*/locations/*/skills/*/revisions/*}\022\322\001\n" + + "\022ListSkillRevisions\0228.google.cloud.agentregistry." + + "v1.ListSkillRevisionsRequest\0329.google.cloud.agentregistry.v1.ListSkillRevisionsR" + + "esponse\"G\332A\006parent\202\323\344\223\0028\0226/v1/{parent=pr" + + "ojects/*/locations/*/skills/*}/revisions\022\253\001\n" + + "\014GetPublisher\0222.google.cloud.agentregistry.v1.GetPublisherRequest\032(.google.c" + + "loud.agentregistry.v1.Publisher\"=\332A\004name" + + "\202\323\344\223\0020\022./v1/{name=projects/*/locations/*/publishers/*}\022\276\001\n" + + "\016ListPublishers\0224.google.cloud.agentregistry.v1.ListPublishers" + + "Request\0325.google.cloud.agentregistry.v1." + + "ListPublishersResponse\"?\332A\006parent\202\323\344\223\0020\022" + + "./v1/{parent=projects/*/locations/*}/publishers\022\273\001\n" + + "\020GetAiApplication\0226.google.cloud.agentregistry.v1.GetAiApplicationReq" + + "uest\032,.google.cloud.agentregistry.v1.AiA" + + "pplication\"A\332A\004name\202\323\344\223\0024\0222/v1/{name=pro" + + "jects/*/locations/*/aiApplications/*}\022\316\001\n" + + "\022ListAiApplications\0228.google.cloud.agen" + + "tregistry.v1.ListAiApplicationsRequest\0329.google.cloud.agentregistry.v1.ListAiApp" + + "licationsResponse\"C\332A\006parent\202\323\344\223\0024\0222/v1/" + + "{parent=projects/*/locations/*}/aiApplic", + "ations\022\306\001\n\025GetAiApplicationAgent\022;.googl" + + "e.cloud.agentregistry.v1.GetAiApplicatio" + + "nAgentRequest\032$.google.cloud.agentregist" + + "ry.v1.Agent\"J\332A\004name\202\323\344\223\002=\022;/v1/{name=pr" + + "ojects/*/locations/*/aiApplications/*/ag" + + "ents/*}\022\346\001\n\027ListAiApplicationAgents\022=.go" + + "ogle.cloud.agentregistry.v1.ListAiApplic" + + "ationAgentsRequest\032>.google.cloud.agentr" + + "egistry.v1.ListAiApplicationAgentsRespon" + + "se\"L\332A\006parent\202\323\344\223\002=\022;/v1/{parent=project" + + "s/*/locations/*/aiApplications/*}/agents" + + "\022\326\001\n\031GetAiApplicationMcpServer\022?.google." + + "cloud.agentregistry.v1.GetAiApplicationM" + + "cpServerRequest\032(.google.cloud.agentregi" + + "stry.v1.McpServer\"N\332A\004name\202\323\344\223\002A\022?/v1/{n" + + "ame=projects/*/locations/*/aiApplication" + + "s/*/mcpServers/*}\022\366\001\n\033ListAiApplicationM" + + "cpServers\022A.google.cloud.agentregistry.v" + + "1.ListAiApplicationMcpServersRequest\032B.g" + + "oogle.cloud.agentregistry.v1.ListAiAppli" + + "cationMcpServersResponse\"P\332A\006parent\202\323\344\223\002" + + "A\022?/v1/{parent=projects/*/locations/*/ai" + + "Applications/*}/mcpServers\022\243\001\n\nGetFindin" + + "g\0220.google.cloud.agentregistry.v1.GetFin" + + "dingRequest\032&.google.cloud.agentregistry" + + ".v1.Finding\";\332A\004name\202\323\344\223\002.\022,/v1/{name=pr" + + "ojects/*/locations/*/findings/*}\022\266\001\n\014Lis" + + "tFindings\0222.google.cloud.agentregistry.v" + + "1.ListFindingsRequest\0323.google.cloud.age" + + "ntregistry.v1.ListFindingsResponse\"=\332A\006p" + + "arent\202\323\344\223\002.\022,/v1/{parent=projects/*/loca" + + "tions/*}/findings\022\322\001\n\030GetAiApplicationEn" + + "dpoint\022>.google.cloud.agentregistry.v1.G" + + "etAiApplicationEndpointRequest\032\'.google." + + "cloud.agentregistry.v1.Endpoint\"M\332A\004name" + + "\202\323\344\223\002@\022>/v1/{name=projects/*/locations/*" + + "/aiApplications/*/endpoints/*}\022\362\001\n\032ListA" + + "iApplicationEndpoints\022@.google.cloud.age" + + "ntregistry.v1.ListAiApplicationEndpoints" + + "Request\032A.google.cloud.agentregistry.v1." + + "ListAiApplicationEndpointsResponse\"O\332A\006p" + + "arent\202\323\344\223\002@\022>/v1/{parent=projects/*/loca" + + "tions/*/aiApplications/*}/endpoints\022\320\001\n\026" + + "GetSkillEncryptionSpec\022<.google.cloud.ag" + + "entregistry.v1.GetSkillEncryptionSpecReq" + + "uest\0322.google.cloud.agentregistry.v1.Ski" + + "llEncryptionSpec\"D\332A\004name\202\323\344\223\0027\0225/v1/{na" + + "me=projects/*/locations/*/skillEncryptio" + + "nSpec}\022\267\002\n\031UpdateSkillEncryptionSpec\022?.g" + + "oogle.cloud.agentregistry.v1.UpdateSkill" + + "EncryptionSpecRequest\032\035.google.longrunni" + + "ng.Operation\"\271\001\312A(\n\023SkillEncryptionSpec\022" + + "\021OperationMetadata\332A!skill_encryption_sp" + + "ec,update_mask\202\323\344\223\002d2K/v1/{skill_encrypt" + + "ion_spec.name=projects/*/locations/*/ski" + + "llEncryptionSpec}:\025skill_encryption_spec" + + "\032\373\001\312A\034agentregistry.googleapis.com\322A\330\001ht" + + "tps://www.googleapis.com/auth/agentregis" + + "try.read-only,https://www.googleapis.com" + + "/auth/agentregistry.read-write,https://w" + + "ww.googleapis.com/auth/cloud-platform,ht" + + "tps://www.googleapis.com/auth/cloud-plat" + + "form.read-onlyB\354\001\n!com.google.cloud.agen" + + "tregistry.v1B\031AgentRegistryServiceProtoP" + + "\001ZGcloud.google.com/go/agentregistry/api" + + "v1/agentregistrypb;agentregistrypb\252\002\035Goo" + + "gle.Cloud.AgentRegistry.V1\312\002\035Google\\Clou" + + "d\\AgentRegistry\\V1\352\002 Google::Cloud::Agen" + + "tRegistry::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -407,10 +813,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.FieldInfoProto.getDescriptor(), com.google.api.ResourceProto.getDescriptor(), com.google.cloud.agentregistry.v1.AgentProto.getDescriptor(), + com.google.cloud.agentregistry.v1.AiApplicationProto.getDescriptor(), com.google.cloud.agentregistry.v1.BindingProto.getDescriptor(), com.google.cloud.agentregistry.v1.EndpointProto.getDescriptor(), + com.google.cloud.agentregistry.v1.FindingProto.getDescriptor(), com.google.cloud.agentregistry.v1.McpServerProto.getDescriptor(), com.google.cloud.agentregistry.v1.ServiceProto.getDescriptor(), + com.google.cloud.agentregistry.v1.SkillProto.getDescriptor(), + com.google.cloud.agentregistry.v1.SkillEncryptionSpecProto.getDescriptor(), com.google.longrunning.OperationsProto.getDescriptor(), com.google.protobuf.EmptyProto.getDescriptor(), com.google.protobuf.FieldMaskProto.getDescriptor(), @@ -456,8 +866,32 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Name", }); - internal_static_google_cloud_agentregistry_v1_ListEndpointsRequest_descriptor = + internal_static_google_cloud_agentregistry_v1_GetAiApplicationAgentRequest_descriptor = getDescriptor().getMessageType(5); + internal_static_google_cloud_agentregistry_v1_GetAiApplicationAgentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_GetAiApplicationAgentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsRequest_descriptor = + getDescriptor().getMessageType(6); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsResponse_descriptor = + getDescriptor().getMessageType(7); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsResponse_descriptor, + new java.lang.String[] { + "Agents", "NextPageToken", + }); + internal_static_google_cloud_agentregistry_v1_ListEndpointsRequest_descriptor = + getDescriptor().getMessageType(8); internal_static_google_cloud_agentregistry_v1_ListEndpointsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_ListEndpointsRequest_descriptor, @@ -465,7 +899,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PageSize", "PageToken", "Filter", }); internal_static_google_cloud_agentregistry_v1_ListEndpointsResponse_descriptor = - getDescriptor().getMessageType(6); + getDescriptor().getMessageType(9); internal_static_google_cloud_agentregistry_v1_ListEndpointsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_ListEndpointsResponse_descriptor, @@ -473,15 +907,39 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Endpoints", "NextPageToken", }); internal_static_google_cloud_agentregistry_v1_GetEndpointRequest_descriptor = - getDescriptor().getMessageType(7); + getDescriptor().getMessageType(10); internal_static_google_cloud_agentregistry_v1_GetEndpointRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_GetEndpointRequest_descriptor, new java.lang.String[] { "Name", }); + internal_static_google_cloud_agentregistry_v1_GetAiApplicationEndpointRequest_descriptor = + getDescriptor().getMessageType(11); + internal_static_google_cloud_agentregistry_v1_GetAiApplicationEndpointRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_GetAiApplicationEndpointRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsRequest_descriptor = + getDescriptor().getMessageType(12); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsResponse_descriptor = + getDescriptor().getMessageType(13); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsResponse_descriptor, + new java.lang.String[] { + "Endpoints", "NextPageToken", + }); internal_static_google_cloud_agentregistry_v1_ListMcpServersRequest_descriptor = - getDescriptor().getMessageType(8); + getDescriptor().getMessageType(14); internal_static_google_cloud_agentregistry_v1_ListMcpServersRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_ListMcpServersRequest_descriptor, @@ -489,7 +947,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PageSize", "PageToken", "Filter", "OrderBy", }); internal_static_google_cloud_agentregistry_v1_ListMcpServersResponse_descriptor = - getDescriptor().getMessageType(9); + getDescriptor().getMessageType(15); internal_static_google_cloud_agentregistry_v1_ListMcpServersResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_ListMcpServersResponse_descriptor, @@ -497,7 +955,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "McpServers", "NextPageToken", }); internal_static_google_cloud_agentregistry_v1_SearchMcpServersRequest_descriptor = - getDescriptor().getMessageType(10); + getDescriptor().getMessageType(16); internal_static_google_cloud_agentregistry_v1_SearchMcpServersRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_SearchMcpServersRequest_descriptor, @@ -505,7 +963,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "SearchString", "PageSize", "PageToken", }); internal_static_google_cloud_agentregistry_v1_SearchMcpServersResponse_descriptor = - getDescriptor().getMessageType(11); + getDescriptor().getMessageType(17); internal_static_google_cloud_agentregistry_v1_SearchMcpServersResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_SearchMcpServersResponse_descriptor, @@ -513,15 +971,39 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "McpServers", "NextPageToken", }); internal_static_google_cloud_agentregistry_v1_GetMcpServerRequest_descriptor = - getDescriptor().getMessageType(12); + getDescriptor().getMessageType(18); internal_static_google_cloud_agentregistry_v1_GetMcpServerRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_GetMcpServerRequest_descriptor, new java.lang.String[] { "Name", }); + internal_static_google_cloud_agentregistry_v1_GetAiApplicationMcpServerRequest_descriptor = + getDescriptor().getMessageType(19); + internal_static_google_cloud_agentregistry_v1_GetAiApplicationMcpServerRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_GetAiApplicationMcpServerRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersRequest_descriptor = + getDescriptor().getMessageType(20); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersResponse_descriptor = + getDescriptor().getMessageType(21); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersResponse_descriptor, + new java.lang.String[] { + "McpServers", "NextPageToken", + }); internal_static_google_cloud_agentregistry_v1_ListServicesRequest_descriptor = - getDescriptor().getMessageType(13); + getDescriptor().getMessageType(22); internal_static_google_cloud_agentregistry_v1_ListServicesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_ListServicesRequest_descriptor, @@ -529,7 +1011,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PageSize", "PageToken", "Filter", }); internal_static_google_cloud_agentregistry_v1_ListServicesResponse_descriptor = - getDescriptor().getMessageType(14); + getDescriptor().getMessageType(23); internal_static_google_cloud_agentregistry_v1_ListServicesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_ListServicesResponse_descriptor, @@ -537,7 +1019,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Services", "NextPageToken", }); internal_static_google_cloud_agentregistry_v1_GetServiceRequest_descriptor = - getDescriptor().getMessageType(15); + getDescriptor().getMessageType(24); internal_static_google_cloud_agentregistry_v1_GetServiceRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_GetServiceRequest_descriptor, @@ -545,7 +1027,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_agentregistry_v1_CreateServiceRequest_descriptor = - getDescriptor().getMessageType(16); + getDescriptor().getMessageType(25); internal_static_google_cloud_agentregistry_v1_CreateServiceRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_CreateServiceRequest_descriptor, @@ -553,7 +1035,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "ServiceId", "Service", "RequestId", }); internal_static_google_cloud_agentregistry_v1_FetchAvailableBindingsRequest_descriptor = - getDescriptor().getMessageType(17); + getDescriptor().getMessageType(26); internal_static_google_cloud_agentregistry_v1_FetchAvailableBindingsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_FetchAvailableBindingsRequest_descriptor, @@ -567,7 +1049,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Target", }); internal_static_google_cloud_agentregistry_v1_FetchAvailableBindingsResponse_descriptor = - getDescriptor().getMessageType(18); + getDescriptor().getMessageType(27); internal_static_google_cloud_agentregistry_v1_FetchAvailableBindingsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_FetchAvailableBindingsResponse_descriptor, @@ -575,7 +1057,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Bindings", "NextPageToken", }); internal_static_google_cloud_agentregistry_v1_UpdateServiceRequest_descriptor = - getDescriptor().getMessageType(19); + getDescriptor().getMessageType(28); internal_static_google_cloud_agentregistry_v1_UpdateServiceRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_UpdateServiceRequest_descriptor, @@ -583,7 +1065,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "UpdateMask", "Service", "RequestId", }); internal_static_google_cloud_agentregistry_v1_DeleteServiceRequest_descriptor = - getDescriptor().getMessageType(20); + getDescriptor().getMessageType(29); internal_static_google_cloud_agentregistry_v1_DeleteServiceRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_DeleteServiceRequest_descriptor, @@ -591,7 +1073,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "RequestId", }); internal_static_google_cloud_agentregistry_v1_OperationMetadata_descriptor = - getDescriptor().getMessageType(21); + getDescriptor().getMessageType(30); internal_static_google_cloud_agentregistry_v1_OperationMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_OperationMetadata_descriptor, @@ -605,7 +1087,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ApiVersion", }); internal_static_google_cloud_agentregistry_v1_ListBindingsRequest_descriptor = - getDescriptor().getMessageType(22); + getDescriptor().getMessageType(31); internal_static_google_cloud_agentregistry_v1_ListBindingsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_ListBindingsRequest_descriptor, @@ -613,7 +1095,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PageSize", "PageToken", "Filter", "OrderBy", }); internal_static_google_cloud_agentregistry_v1_ListBindingsResponse_descriptor = - getDescriptor().getMessageType(23); + getDescriptor().getMessageType(32); internal_static_google_cloud_agentregistry_v1_ListBindingsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_ListBindingsResponse_descriptor, @@ -621,7 +1103,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Bindings", "NextPageToken", }); internal_static_google_cloud_agentregistry_v1_GetBindingRequest_descriptor = - getDescriptor().getMessageType(24); + getDescriptor().getMessageType(33); internal_static_google_cloud_agentregistry_v1_GetBindingRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_GetBindingRequest_descriptor, @@ -629,7 +1111,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_agentregistry_v1_CreateBindingRequest_descriptor = - getDescriptor().getMessageType(25); + getDescriptor().getMessageType(34); internal_static_google_cloud_agentregistry_v1_CreateBindingRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_CreateBindingRequest_descriptor, @@ -637,7 +1119,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "BindingId", "Binding", "RequestId", }); internal_static_google_cloud_agentregistry_v1_UpdateBindingRequest_descriptor = - getDescriptor().getMessageType(26); + getDescriptor().getMessageType(35); internal_static_google_cloud_agentregistry_v1_UpdateBindingRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_UpdateBindingRequest_descriptor, @@ -645,13 +1127,205 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Binding", "UpdateMask", "RequestId", }); internal_static_google_cloud_agentregistry_v1_DeleteBindingRequest_descriptor = - getDescriptor().getMessageType(27); + getDescriptor().getMessageType(36); internal_static_google_cloud_agentregistry_v1_DeleteBindingRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_DeleteBindingRequest_descriptor, new java.lang.String[] { "Name", "RequestId", }); + internal_static_google_cloud_agentregistry_v1_CreateSkillRequest_descriptor = + getDescriptor().getMessageType(37); + internal_static_google_cloud_agentregistry_v1_CreateSkillRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_CreateSkillRequest_descriptor, + new java.lang.String[] { + "Parent", "SkillId", "Skill", "RequestId", + }); + internal_static_google_cloud_agentregistry_v1_GetSkillRequest_descriptor = + getDescriptor().getMessageType(38); + internal_static_google_cloud_agentregistry_v1_GetSkillRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_GetSkillRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_agentregistry_v1_UpdateSkillRequest_descriptor = + getDescriptor().getMessageType(39); + internal_static_google_cloud_agentregistry_v1_UpdateSkillRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_UpdateSkillRequest_descriptor, + new java.lang.String[] { + "Skill", "UpdateMask", "RequestId", + }); + internal_static_google_cloud_agentregistry_v1_DeleteSkillRequest_descriptor = + getDescriptor().getMessageType(40); + internal_static_google_cloud_agentregistry_v1_DeleteSkillRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_DeleteSkillRequest_descriptor, + new java.lang.String[] { + "Name", "RequestId", "Force", + }); + internal_static_google_cloud_agentregistry_v1_ListSkillsRequest_descriptor = + getDescriptor().getMessageType(41); + internal_static_google_cloud_agentregistry_v1_ListSkillsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListSkillsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "Filter", "OrderBy", + }); + internal_static_google_cloud_agentregistry_v1_ListSkillsResponse_descriptor = + getDescriptor().getMessageType(42); + internal_static_google_cloud_agentregistry_v1_ListSkillsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListSkillsResponse_descriptor, + new java.lang.String[] { + "Skills", "NextPageToken", "Unreachable", + }); + internal_static_google_cloud_agentregistry_v1_SearchSkillsRequest_descriptor = + getDescriptor().getMessageType(43); + internal_static_google_cloud_agentregistry_v1_SearchSkillsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_SearchSkillsRequest_descriptor, + new java.lang.String[] { + "Parent", "SearchType", "SearchString", "Filter", "PageSize", "PageToken", + }); + internal_static_google_cloud_agentregistry_v1_SearchSkillsResponse_descriptor = + getDescriptor().getMessageType(44); + internal_static_google_cloud_agentregistry_v1_SearchSkillsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_SearchSkillsResponse_descriptor, + new java.lang.String[] { + "Skills", "NextPageToken", + }); + internal_static_google_cloud_agentregistry_v1_CreateSkillRevisionRequest_descriptor = + getDescriptor().getMessageType(45); + internal_static_google_cloud_agentregistry_v1_CreateSkillRevisionRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_CreateSkillRevisionRequest_descriptor, + new java.lang.String[] { + "Parent", "SkillRevision", "SkillRevisionId", "RequestId", + }); + internal_static_google_cloud_agentregistry_v1_GetSkillRevisionRequest_descriptor = + getDescriptor().getMessageType(46); + internal_static_google_cloud_agentregistry_v1_GetSkillRevisionRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_GetSkillRevisionRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_agentregistry_v1_DeleteSkillRevisionRequest_descriptor = + getDescriptor().getMessageType(47); + internal_static_google_cloud_agentregistry_v1_DeleteSkillRevisionRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_DeleteSkillRevisionRequest_descriptor, + new java.lang.String[] { + "Name", "RequestId", + }); + internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsRequest_descriptor = + getDescriptor().getMessageType(48); + internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsResponse_descriptor = + getDescriptor().getMessageType(49); + internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsResponse_descriptor, + new java.lang.String[] { + "SkillRevisions", "NextPageToken", + }); + internal_static_google_cloud_agentregistry_v1_GetPublisherRequest_descriptor = + getDescriptor().getMessageType(50); + internal_static_google_cloud_agentregistry_v1_GetPublisherRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_GetPublisherRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_agentregistry_v1_ListPublishersRequest_descriptor = + getDescriptor().getMessageType(51); + internal_static_google_cloud_agentregistry_v1_ListPublishersRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListPublishersRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_agentregistry_v1_ListPublishersResponse_descriptor = + getDescriptor().getMessageType(52); + internal_static_google_cloud_agentregistry_v1_ListPublishersResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListPublishersResponse_descriptor, + new java.lang.String[] { + "Publishers", "NextPageToken", + }); + internal_static_google_cloud_agentregistry_v1_GetAiApplicationRequest_descriptor = + getDescriptor().getMessageType(53); + internal_static_google_cloud_agentregistry_v1_GetAiApplicationRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_GetAiApplicationRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationsRequest_descriptor = + getDescriptor().getMessageType(54); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListAiApplicationsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "Filter", "OrderBy", + }); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationsResponse_descriptor = + getDescriptor().getMessageType(55); + internal_static_google_cloud_agentregistry_v1_ListAiApplicationsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListAiApplicationsResponse_descriptor, + new java.lang.String[] { + "AiApplications", "NextPageToken", "Unreachable", + }); + internal_static_google_cloud_agentregistry_v1_ListFindingsRequest_descriptor = + getDescriptor().getMessageType(56); + internal_static_google_cloud_agentregistry_v1_ListFindingsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListFindingsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "Filter", "OrderBy", + }); + internal_static_google_cloud_agentregistry_v1_ListFindingsResponse_descriptor = + getDescriptor().getMessageType(57); + internal_static_google_cloud_agentregistry_v1_ListFindingsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ListFindingsResponse_descriptor, + new java.lang.String[] { + "Findings", "NextPageToken", + }); + internal_static_google_cloud_agentregistry_v1_GetFindingRequest_descriptor = + getDescriptor().getMessageType(58); + internal_static_google_cloud_agentregistry_v1_GetFindingRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_GetFindingRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_agentregistry_v1_GetSkillEncryptionSpecRequest_descriptor = + getDescriptor().getMessageType(59); + internal_static_google_cloud_agentregistry_v1_GetSkillEncryptionSpecRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_GetSkillEncryptionSpecRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_agentregistry_v1_UpdateSkillEncryptionSpecRequest_descriptor = + getDescriptor().getMessageType(60); + internal_static_google_cloud_agentregistry_v1_UpdateSkillEncryptionSpecRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_UpdateSkillEncryptionSpecRequest_descriptor, + new java.lang.String[] { + "SkillEncryptionSpec", "UpdateMask", + }); descriptor.resolveAllFeaturesImmutable(); com.google.api.AnnotationsProto.getDescriptor(); com.google.api.ClientProto.getDescriptor(); @@ -659,10 +1333,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.FieldInfoProto.getDescriptor(); com.google.api.ResourceProto.getDescriptor(); com.google.cloud.agentregistry.v1.AgentProto.getDescriptor(); + com.google.cloud.agentregistry.v1.AiApplicationProto.getDescriptor(); com.google.cloud.agentregistry.v1.BindingProto.getDescriptor(); com.google.cloud.agentregistry.v1.EndpointProto.getDescriptor(); + com.google.cloud.agentregistry.v1.FindingProto.getDescriptor(); com.google.cloud.agentregistry.v1.McpServerProto.getDescriptor(); com.google.cloud.agentregistry.v1.ServiceProto.getDescriptor(); + com.google.cloud.agentregistry.v1.SkillProto.getDescriptor(); + com.google.cloud.agentregistry.v1.SkillEncryptionSpecProto.getDescriptor(); com.google.longrunning.OperationsProto.getDescriptor(); com.google.protobuf.EmptyProto.getDescriptor(); com.google.protobuf.FieldMaskProto.getDescriptor(); diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplication.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplication.java new file mode 100644 index 000000000000..3ab4405a9f98 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplication.java @@ -0,0 +1,2798 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/ai_application.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Represents an AI Application.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.AiApplication} + */ +@com.google.protobuf.Generated +public final class AiApplication extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.AiApplication) + AiApplicationOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AiApplication"); + } + + // Use AiApplication.newBuilder() to construct. + private AiApplication(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AiApplication() { + name_ = ""; + displayName_ = ""; + description_ = ""; + uid_ = ""; + state_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AiApplicationProto + .internal_static_google_cloud_agentregistry_v1_AiApplication_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AiApplicationProto + .internal_static_google_cloud_agentregistry_v1_AiApplication_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.AiApplication.class, + com.google.cloud.agentregistry.v1.AiApplication.Builder.class); + } + + /** + * + * + *
+   * The lifecycle states of an AI Application.
+   * 
+ * + * Protobuf enum {@code google.cloud.agentregistry.v1.AiApplication.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
+     * The resource is being provisioned or created.
+     * 
+ * + * CREATING = 1; + */ + CREATING(1), + /** + * + * + *
+     * The resource is active and ready for use.
+     * 
+ * + * ACTIVE = 2; + */ + ACTIVE(2), + /** + * + * + *
+     * The resource is in the process of being deleted.
+     * 
+ * + * DELETING = 3; + */ + DELETING(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "State"); + } + + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The resource is being provisioned or created.
+     * 
+ * + * CREATING = 1; + */ + public static final int CREATING_VALUE = 1; + + /** + * + * + *
+     * The resource is active and ready for use.
+     * 
+ * + * ACTIVE = 2; + */ + public static final int ACTIVE_VALUE = 2; + + /** + * + * + *
+     * The resource is in the process of being deleted.
+     * 
+ * + * DELETING = 3; + */ + public static final int DELETING_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return CREATING; + case 2: + return ACTIVE; + case 3: + return DELETING; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public State findValueByNumber(int number) { + return State.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AiApplication.getDescriptor().getEnumTypes().get(0); + } + + private static final State[] VALUES = values(); + + public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private State(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.agentregistry.v1.AiApplication.State) + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Identifier. Resource name of the AI Application.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Identifier. Resource name of the AI Application.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object displayName_ = ""; + + /** + * + * + *
+   * Optional. User-defined name for the AI Application.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. User-defined name for the AI Application.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object description_ = ""; + + /** + * + * + *
+   * Optional. User-defined description of the AI Application.
+   * 
+ * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. User-defined description of the AI Application.
+   * 
+ * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UID_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object uid_ = ""; + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the AI Application.
+   * 
+ * + * + * string uid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + @java.lang.Override + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the AI Application.
+   * 
+ * + * + * string uid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
+   * Output only. Creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Output only. Creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
+   * Output only. Creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp updateTime_; + + /** + * + * + *
+   * Output only. Last update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Output only. Last update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + /** + * + * + *
+   * Output only. Last update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + public static final int STATE_FIELD_NUMBER = 7; + private int state_ = 0; + + /** + * + * + *
+   * Output only. The current state of the AI Application.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.AiApplication.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
+   * Output only. The current state of the AI Application.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.AiApplication.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.AiApplication.State getState() { + com.google.cloud.agentregistry.v1.AiApplication.State result = + com.google.cloud.agentregistry.v1.AiApplication.State.forNumber(state_); + return result == null + ? com.google.cloud.agentregistry.v1.AiApplication.State.UNRECOGNIZED + : result; + } + + public static final int ATTRIBUTES_FIELD_NUMBER = 8; + private com.google.cloud.apphub.v1.Attributes attributes_; + + /** + * + * + *
+   * Optional. Consumer provided attributes.
+   * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the attributes field is set. + */ + @java.lang.Override + public boolean hasAttributes() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+   * Optional. Consumer provided attributes.
+   * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The attributes. + */ + @java.lang.Override + public com.google.cloud.apphub.v1.Attributes getAttributes() { + return attributes_ == null + ? com.google.cloud.apphub.v1.Attributes.getDefaultInstance() + : attributes_; + } + + /** + * + * + *
+   * Optional. Consumer provided attributes.
+   * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apphub.v1.AttributesOrBuilder getAttributesOrBuilder() { + return attributes_ == null + ? com.google.cloud.apphub.v1.Attributes.getDefaultInstance() + : attributes_; + } + + public static final int APPLICATION_PROPERTIES_FIELD_NUMBER = 9; + private com.google.cloud.apphub.v1.ApplicationProperties applicationProperties_; + + /** + * + * + *
+   * Output only. Properties of an underlying cloud resource that can comprise
+   * an AI Application.
+   * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the applicationProperties field is set. + */ + @java.lang.Override + public boolean hasApplicationProperties() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+   * Output only. Properties of an underlying cloud resource that can comprise
+   * an AI Application.
+   * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The applicationProperties. + */ + @java.lang.Override + public com.google.cloud.apphub.v1.ApplicationProperties getApplicationProperties() { + return applicationProperties_ == null + ? com.google.cloud.apphub.v1.ApplicationProperties.getDefaultInstance() + : applicationProperties_; + } + + /** + * + * + *
+   * Output only. Properties of an underlying cloud resource that can comprise
+   * an AI Application.
+   * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.apphub.v1.ApplicationPropertiesOrBuilder + getApplicationPropertiesOrBuilder() { + return applicationProperties_ == null + ? com.google.cloud.apphub.v1.ApplicationProperties.getDefaultInstance() + : applicationProperties_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, displayName_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, description_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uid_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, uid_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(6, getUpdateTime()); + } + if (state_ + != com.google.cloud.agentregistry.v1.AiApplication.State.STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(7, state_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(8, getAttributes()); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeMessage(9, getApplicationProperties()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, displayName_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, description_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uid_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, uid_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime()); + } + if (state_ + != com.google.cloud.agentregistry.v1.AiApplication.State.STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, state_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getAttributes()); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(9, getApplicationProperties()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.AiApplication)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.AiApplication other = + (com.google.cloud.agentregistry.v1.AiApplication) obj; + + if (!getName().equals(other.getName())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (!getUid().equals(other.getUid())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (state_ != other.state_) return false; + if (hasAttributes() != other.hasAttributes()) return false; + if (hasAttributes()) { + if (!getAttributes().equals(other.getAttributes())) return false; + } + if (hasApplicationProperties() != other.hasApplicationProperties()) return false; + if (hasApplicationProperties()) { + if (!getApplicationProperties().equals(other.getApplicationProperties())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + hash = (37 * hash) + UID_FIELD_NUMBER; + hash = (53 * hash) + getUid().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + if (hasAttributes()) { + hash = (37 * hash) + ATTRIBUTES_FIELD_NUMBER; + hash = (53 * hash) + getAttributes().hashCode(); + } + if (hasApplicationProperties()) { + hash = (37 * hash) + APPLICATION_PROPERTIES_FIELD_NUMBER; + hash = (53 * hash) + getApplicationProperties().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.AiApplication parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.AiApplication prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Represents an AI Application.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.AiApplication} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.AiApplication) + com.google.cloud.agentregistry.v1.AiApplicationOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AiApplicationProto + .internal_static_google_cloud_agentregistry_v1_AiApplication_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AiApplicationProto + .internal_static_google_cloud_agentregistry_v1_AiApplication_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.AiApplication.class, + com.google.cloud.agentregistry.v1.AiApplication.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.AiApplication.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetCreateTimeFieldBuilder(); + internalGetUpdateTimeFieldBuilder(); + internalGetAttributesFieldBuilder(); + internalGetApplicationPropertiesFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + displayName_ = ""; + description_ = ""; + uid_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + state_ = 0; + attributes_ = null; + if (attributesBuilder_ != null) { + attributesBuilder_.dispose(); + attributesBuilder_ = null; + } + applicationProperties_ = null; + if (applicationPropertiesBuilder_ != null) { + applicationPropertiesBuilder_.dispose(); + applicationPropertiesBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AiApplicationProto + .internal_static_google_cloud_agentregistry_v1_AiApplication_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.AiApplication getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.AiApplication.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.AiApplication build() { + com.google.cloud.agentregistry.v1.AiApplication result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.AiApplication buildPartial() { + com.google.cloud.agentregistry.v1.AiApplication result = + new com.google.cloud.agentregistry.v1.AiApplication(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.AiApplication result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.displayName_ = displayName_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.description_ = description_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.uid_ = uid_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000010) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.state_ = state_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.attributes_ = attributesBuilder_ == null ? attributes_ : attributesBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.applicationProperties_ = + applicationPropertiesBuilder_ == null + ? applicationProperties_ + : applicationPropertiesBuilder_.build(); + to_bitField0_ |= 0x00000008; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.AiApplication) { + return mergeFrom((com.google.cloud.agentregistry.v1.AiApplication) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.AiApplication other) { + if (other == com.google.cloud.agentregistry.v1.AiApplication.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getUid().isEmpty()) { + uid_ = other.uid_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (other.hasAttributes()) { + mergeAttributes(other.getAttributes()); + } + if (other.hasApplicationProperties()) { + mergeApplicationProperties(other.getApplicationProperties()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + uid_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + input.readMessage( + internalGetUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + case 56: + { + state_ = input.readEnum(); + bitField0_ |= 0x00000040; + break; + } // case 56 + case 66: + { + input.readMessage( + internalGetAttributesFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000080; + break; + } // case 66 + case 74: + { + input.readMessage( + internalGetApplicationPropertiesFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000100; + break; + } // case 74 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Identifier. Resource name of the AI Application.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the AI Application.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the AI Application.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the AI Application.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the AI Application.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + + /** + * + * + *
+     * Optional. User-defined name for the AI Application.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. User-defined name for the AI Application.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. User-defined name for the AI Application.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. User-defined name for the AI Application.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + displayName_ = getDefaultInstance().getDisplayName(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. User-defined name for the AI Application.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + + /** + * + * + *
+     * Optional. User-defined description of the AI Application.
+     * 
+ * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. User-defined description of the AI Application.
+     * 
+ * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. User-defined description of the AI Application.
+     * 
+ * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + description_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. User-defined description of the AI Application.
+     * 
+ * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + description_ = getDefaultInstance().getDescription(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. User-defined description of the AI Application.
+     * 
+ * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object uid_ = ""; + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the AI Application.
+     * 
+ * + * + * string uid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the AI Application.
+     * 
+ * + * + * string uid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the AI Application.
+     * 
+ * + * + * string uid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @param value The uid to set. + * @return This builder for chaining. + */ + public Builder setUid(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + uid_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the AI Application.
+     * 
+ * + * + * string uid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearUid() { + uid_ = getDefaultInstance().getUid(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the AI Application.
+     * 
+ * + * + * string uid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for uid to set. + * @return This builder for chaining. + */ + public Builder setUidBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + uid_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
+     * Output only. Creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
+     * Output only. Creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000010); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
+     * Output only. Creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
+     * Output only. Last update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
+     * Output only. Last update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Last update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + } else { + updateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Last update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Last update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && updateTime_ != null + && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getUpdateTimeBuilder().mergeFrom(value); + } else { + updateTime_ = value; + } + } else { + updateTimeBuilder_.mergeFrom(value); + } + if (updateTime_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Last update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000020); + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Last update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Last update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + + /** + * + * + *
+     * Output only. Last update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private int state_ = 0; + + /** + * + * + *
+     * Output only. The current state of the AI Application.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.AiApplication.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
+     * Output only. The current state of the AI Application.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.AiApplication.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The current state of the AI Application.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.AiApplication.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.AiApplication.State getState() { + com.google.cloud.agentregistry.v1.AiApplication.State result = + com.google.cloud.agentregistry.v1.AiApplication.State.forNumber(state_); + return result == null + ? com.google.cloud.agentregistry.v1.AiApplication.State.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Output only. The current state of the AI Application.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.AiApplication.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.agentregistry.v1.AiApplication.State value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000040; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The current state of the AI Application.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.AiApplication.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000040); + state_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.apphub.v1.Attributes attributes_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apphub.v1.Attributes, + com.google.cloud.apphub.v1.Attributes.Builder, + com.google.cloud.apphub.v1.AttributesOrBuilder> + attributesBuilder_; + + /** + * + * + *
+     * Optional. Consumer provided attributes.
+     * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the attributes field is set. + */ + public boolean hasAttributes() { + return ((bitField0_ & 0x00000080) != 0); + } + + /** + * + * + *
+     * Optional. Consumer provided attributes.
+     * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The attributes. + */ + public com.google.cloud.apphub.v1.Attributes getAttributes() { + if (attributesBuilder_ == null) { + return attributes_ == null + ? com.google.cloud.apphub.v1.Attributes.getDefaultInstance() + : attributes_; + } else { + return attributesBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Optional. Consumer provided attributes.
+     * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setAttributes(com.google.cloud.apphub.v1.Attributes value) { + if (attributesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + attributes_ = value; + } else { + attributesBuilder_.setMessage(value); + } + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Consumer provided attributes.
+     * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setAttributes(com.google.cloud.apphub.v1.Attributes.Builder builderForValue) { + if (attributesBuilder_ == null) { + attributes_ = builderForValue.build(); + } else { + attributesBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Consumer provided attributes.
+     * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeAttributes(com.google.cloud.apphub.v1.Attributes value) { + if (attributesBuilder_ == null) { + if (((bitField0_ & 0x00000080) != 0) + && attributes_ != null + && attributes_ != com.google.cloud.apphub.v1.Attributes.getDefaultInstance()) { + getAttributesBuilder().mergeFrom(value); + } else { + attributes_ = value; + } + } else { + attributesBuilder_.mergeFrom(value); + } + if (attributes_ != null) { + bitField0_ |= 0x00000080; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Optional. Consumer provided attributes.
+     * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearAttributes() { + bitField0_ = (bitField0_ & ~0x00000080); + attributes_ = null; + if (attributesBuilder_ != null) { + attributesBuilder_.dispose(); + attributesBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Consumer provided attributes.
+     * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apphub.v1.Attributes.Builder getAttributesBuilder() { + bitField0_ |= 0x00000080; + onChanged(); + return internalGetAttributesFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Optional. Consumer provided attributes.
+     * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apphub.v1.AttributesOrBuilder getAttributesOrBuilder() { + if (attributesBuilder_ != null) { + return attributesBuilder_.getMessageOrBuilder(); + } else { + return attributes_ == null + ? com.google.cloud.apphub.v1.Attributes.getDefaultInstance() + : attributes_; + } + } + + /** + * + * + *
+     * Optional. Consumer provided attributes.
+     * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apphub.v1.Attributes, + com.google.cloud.apphub.v1.Attributes.Builder, + com.google.cloud.apphub.v1.AttributesOrBuilder> + internalGetAttributesFieldBuilder() { + if (attributesBuilder_ == null) { + attributesBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apphub.v1.Attributes, + com.google.cloud.apphub.v1.Attributes.Builder, + com.google.cloud.apphub.v1.AttributesOrBuilder>( + getAttributes(), getParentForChildren(), isClean()); + attributes_ = null; + } + return attributesBuilder_; + } + + private com.google.cloud.apphub.v1.ApplicationProperties applicationProperties_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apphub.v1.ApplicationProperties, + com.google.cloud.apphub.v1.ApplicationProperties.Builder, + com.google.cloud.apphub.v1.ApplicationPropertiesOrBuilder> + applicationPropertiesBuilder_; + + /** + * + * + *
+     * Output only. Properties of an underlying cloud resource that can comprise
+     * an AI Application.
+     * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the applicationProperties field is set. + */ + public boolean hasApplicationProperties() { + return ((bitField0_ & 0x00000100) != 0); + } + + /** + * + * + *
+     * Output only. Properties of an underlying cloud resource that can comprise
+     * an AI Application.
+     * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The applicationProperties. + */ + public com.google.cloud.apphub.v1.ApplicationProperties getApplicationProperties() { + if (applicationPropertiesBuilder_ == null) { + return applicationProperties_ == null + ? com.google.cloud.apphub.v1.ApplicationProperties.getDefaultInstance() + : applicationProperties_; + } else { + return applicationPropertiesBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Properties of an underlying cloud resource that can comprise
+     * an AI Application.
+     * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setApplicationProperties( + com.google.cloud.apphub.v1.ApplicationProperties value) { + if (applicationPropertiesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + applicationProperties_ = value; + } else { + applicationPropertiesBuilder_.setMessage(value); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Properties of an underlying cloud resource that can comprise
+     * an AI Application.
+     * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setApplicationProperties( + com.google.cloud.apphub.v1.ApplicationProperties.Builder builderForValue) { + if (applicationPropertiesBuilder_ == null) { + applicationProperties_ = builderForValue.build(); + } else { + applicationPropertiesBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Properties of an underlying cloud resource that can comprise
+     * an AI Application.
+     * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeApplicationProperties( + com.google.cloud.apphub.v1.ApplicationProperties value) { + if (applicationPropertiesBuilder_ == null) { + if (((bitField0_ & 0x00000100) != 0) + && applicationProperties_ != null + && applicationProperties_ + != com.google.cloud.apphub.v1.ApplicationProperties.getDefaultInstance()) { + getApplicationPropertiesBuilder().mergeFrom(value); + } else { + applicationProperties_ = value; + } + } else { + applicationPropertiesBuilder_.mergeFrom(value); + } + if (applicationProperties_ != null) { + bitField0_ |= 0x00000100; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Properties of an underlying cloud resource that can comprise
+     * an AI Application.
+     * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearApplicationProperties() { + bitField0_ = (bitField0_ & ~0x00000100); + applicationProperties_ = null; + if (applicationPropertiesBuilder_ != null) { + applicationPropertiesBuilder_.dispose(); + applicationPropertiesBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Properties of an underlying cloud resource that can comprise
+     * an AI Application.
+     * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apphub.v1.ApplicationProperties.Builder + getApplicationPropertiesBuilder() { + bitField0_ |= 0x00000100; + onChanged(); + return internalGetApplicationPropertiesFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Properties of an underlying cloud resource that can comprise
+     * an AI Application.
+     * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apphub.v1.ApplicationPropertiesOrBuilder + getApplicationPropertiesOrBuilder() { + if (applicationPropertiesBuilder_ != null) { + return applicationPropertiesBuilder_.getMessageOrBuilder(); + } else { + return applicationProperties_ == null + ? com.google.cloud.apphub.v1.ApplicationProperties.getDefaultInstance() + : applicationProperties_; + } + } + + /** + * + * + *
+     * Output only. Properties of an underlying cloud resource that can comprise
+     * an AI Application.
+     * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apphub.v1.ApplicationProperties, + com.google.cloud.apphub.v1.ApplicationProperties.Builder, + com.google.cloud.apphub.v1.ApplicationPropertiesOrBuilder> + internalGetApplicationPropertiesFieldBuilder() { + if (applicationPropertiesBuilder_ == null) { + applicationPropertiesBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apphub.v1.ApplicationProperties, + com.google.cloud.apphub.v1.ApplicationProperties.Builder, + com.google.cloud.apphub.v1.ApplicationPropertiesOrBuilder>( + getApplicationProperties(), getParentForChildren(), isClean()); + applicationProperties_ = null; + } + return applicationPropertiesBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.AiApplication) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.AiApplication) + private static final com.google.cloud.agentregistry.v1.AiApplication DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.AiApplication(); + } + + public static com.google.cloud.agentregistry.v1.AiApplication getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AiApplication parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.AiApplication getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplicationName.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplicationName.java new file mode 100644 index 000000000000..dd0b99be02a9 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplicationName.java @@ -0,0 +1,230 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class AiApplicationName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_AI_APPLICATION = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/aiApplications/{ai_application}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String aiApplication; + + @Deprecated + protected AiApplicationName() { + project = null; + location = null; + aiApplication = null; + } + + private AiApplicationName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + aiApplication = Preconditions.checkNotNull(builder.getAiApplication()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAiApplication() { + return aiApplication; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static AiApplicationName of(String project, String location, String aiApplication) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setAiApplication(aiApplication) + .build(); + } + + public static String format(String project, String location, String aiApplication) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setAiApplication(aiApplication) + .build() + .toString(); + } + + public static @Nullable AiApplicationName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_AI_APPLICATION.validatedMatch( + formattedString, "AiApplicationName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("ai_application")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable AiApplicationName> values) { + List list = new ArrayList<>(values.size()); + for (AiApplicationName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_AI_APPLICATION.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (aiApplication != null) { + fieldMapBuilder.put("ai_application", aiApplication); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_AI_APPLICATION.instantiate( + "project", project, "location", location, "ai_application", aiApplication); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + AiApplicationName that = ((AiApplicationName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.aiApplication, that.aiApplication); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(aiApplication); + return h; + } + + /** Builder for projects/{project}/locations/{location}/aiApplications/{ai_application}. */ + public static class Builder { + private String project; + private String location; + private String aiApplication; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAiApplication() { + return aiApplication; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setAiApplication(String aiApplication) { + this.aiApplication = aiApplication; + return this; + } + + private Builder(AiApplicationName aiApplicationName) { + this.project = aiApplicationName.project; + this.location = aiApplicationName.location; + this.aiApplication = aiApplicationName.aiApplication; + } + + public AiApplicationName build() { + return new AiApplicationName(this); + } + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplicationOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplicationOrBuilder.java new file mode 100644 index 000000000000..69e0d764f997 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplicationOrBuilder.java @@ -0,0 +1,339 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/ai_application.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface AiApplicationOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.AiApplication) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Identifier. Resource name of the AI Application.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Identifier. Resource name of the AI Application.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Optional. User-defined name for the AI Application.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
+   * Optional. User-defined name for the AI Application.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
+   * Optional. User-defined description of the AI Application.
+   * 
+ * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
+   * Optional. User-defined description of the AI Application.
+   * 
+ * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the AI Application.
+   * 
+ * + * + * string uid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + java.lang.String getUid(); + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the AI Application.
+   * 
+ * + * + * string uid = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + com.google.protobuf.ByteString getUidBytes(); + + /** + * + * + *
+   * Output only. Creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
+   * Output only. Creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
+   * Output only. Creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. Last update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + + /** + * + * + *
+   * Output only. Last update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + + /** + * + * + *
+   * Output only. Last update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. The current state of the AI Application.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.AiApplication.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
+   * Output only. The current state of the AI Application.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.AiApplication.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.agentregistry.v1.AiApplication.State getState(); + + /** + * + * + *
+   * Optional. Consumer provided attributes.
+   * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the attributes field is set. + */ + boolean hasAttributes(); + + /** + * + * + *
+   * Optional. Consumer provided attributes.
+   * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The attributes. + */ + com.google.cloud.apphub.v1.Attributes getAttributes(); + + /** + * + * + *
+   * Optional. Consumer provided attributes.
+   * 
+ * + * + * .google.cloud.apphub.v1.Attributes attributes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apphub.v1.AttributesOrBuilder getAttributesOrBuilder(); + + /** + * + * + *
+   * Output only. Properties of an underlying cloud resource that can comprise
+   * an AI Application.
+   * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the applicationProperties field is set. + */ + boolean hasApplicationProperties(); + + /** + * + * + *
+   * Output only. Properties of an underlying cloud resource that can comprise
+   * an AI Application.
+   * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The applicationProperties. + */ + com.google.cloud.apphub.v1.ApplicationProperties getApplicationProperties(); + + /** + * + * + *
+   * Output only. Properties of an underlying cloud resource that can comprise
+   * an AI Application.
+   * 
+ * + * + * .google.cloud.apphub.v1.ApplicationProperties application_properties = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.apphub.v1.ApplicationPropertiesOrBuilder getApplicationPropertiesOrBuilder(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplicationProto.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplicationProto.java new file mode 100644 index 000000000000..59f98dbd18c3 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/AiApplicationProto.java @@ -0,0 +1,136 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/ai_application.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public final class AiApplicationProto extends com.google.protobuf.GeneratedFile { + private AiApplicationProto() {} + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AiApplicationProto"); + } + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_AiApplication_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_AiApplication_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n" + + "2google/cloud/agentregistry/v1/ai_application.proto\022\035google.cloud.agentregistry" + + ".v1\032\037google/api/field_behavior.proto\032\033go" + + "ogle/api/field_info.proto\032\031google/api/re" + + "source.proto\032(google/cloud/apphub/v1/app" + + "lication.proto\032\'google/cloud/apphub/v1/a" + + "ttributes.proto\032\037google/protobuf/timestamp.proto\"\242\005\n\r" + + "AiApplication\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + + "\014display_name\030\002 \001(\tB\004\342A\001\001\022\031\n" + + "\013description\030\003 \001(\tB\004\342A\001\001\022\031\n" + + "\003uid\030\004 \001(\tB\014\342A\001\003\342\214\317\327\010\002\010\001\0225\n" + + "\013create_time\030\005" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + + "\013update_time\030\006" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022G\n" + + "\005state\030\007" + + " \001(\01622.google.cloud.agentregistry.v1.AiApplication.StateB\004\342A\001\003\022<\n\n" + + "attributes\030\010" + + " \001(\0132\".google.cloud.apphub.v1.AttributesB\004\342A\001\001\022S\n" + + "\026application_properties\030\t" + + " \001(\0132-.google.cloud.apphub.v1.ApplicationPropertiesB\004\342A\001\003\"F\n" + + "\005State\022\025\n" + + "\021STATE_UNSPECIFIED\020\000\022\014\n" + + "\010CREATING\020\001\022\n\n" + + "\006ACTIVE\020\002\022\014\n" + + "\010DELETING\020\003:\230\001\352A\224\001\n" + + "*agentregistry.googleapis.com/AiApplication\022Gprojects/{project" + + "}/locations/{location}/aiApplications/{ai_application}*\016aiApplications2\r" + + "aiApplicationB\345\001\n" + + "!com.google.cloud.agentregistry.v1B\022AiApplicationProtoP\001ZGcloud.google." + + "com/go/agentregistry/apiv1/agentregistry" + + "pb;agentregistrypb\252\002\035Google.Cloud.AgentR" + + "egistry.V1\312\002\035Google\\Cloud\\AgentRegistry\\V1\352\002" + + " Google::Cloud::AgentRegistry::V1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.FieldInfoProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.cloud.apphub.v1.ApplicationProto.getDescriptor(), + com.google.cloud.apphub.v1.AttributesProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_agentregistry_v1_AiApplication_descriptor = + getDescriptor().getMessageType(0); + internal_static_google_cloud_agentregistry_v1_AiApplication_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_AiApplication_descriptor, + new java.lang.String[] { + "Name", + "DisplayName", + "Description", + "Uid", + "CreateTime", + "UpdateTime", + "State", + "Attributes", + "ApplicationProperties", + }); + descriptor.resolveAllFeaturesImmutable(); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.FieldInfoProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.cloud.apphub.v1.ApplicationProto.getDescriptor(); + com.google.cloud.apphub.v1.AttributesProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.FieldInfoProto.fieldInfo); + registry.add(com.google.api.ResourceProto.resource); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ArchiveUploadSource.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ArchiveUploadSource.java new file mode 100644 index 000000000000..431cb13dd5a1 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ArchiveUploadSource.java @@ -0,0 +1,520 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Direct write-only raw archive payload upload.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ArchiveUploadSource} + */ +@com.google.protobuf.Generated +public final class ArchiveUploadSource extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ArchiveUploadSource) + ArchiveUploadSourceOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ArchiveUploadSource"); + } + + // Use ArchiveUploadSource.newBuilder() to construct. + private ArchiveUploadSource(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ArchiveUploadSource() { + archiveContent_ = com.google.protobuf.ByteString.EMPTY; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_ArchiveUploadSource_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_ArchiveUploadSource_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ArchiveUploadSource.class, + com.google.cloud.agentregistry.v1.ArchiveUploadSource.Builder.class); + } + + public static final int ARCHIVE_CONTENT_FIELD_NUMBER = 1; + private com.google.protobuf.ByteString archiveContent_ = com.google.protobuf.ByteString.EMPTY; + + /** + * + * + *
+   * Required. Input only. Write-only raw ZIP/TAR archive payload bytes
+   * containing the skill package.
+   * 
+ * + * + * bytes archive_content = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY]; + * + * + * @return The archiveContent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getArchiveContent() { + return archiveContent_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!archiveContent_.isEmpty()) { + output.writeBytes(1, archiveContent_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!archiveContent_.isEmpty()) { + size += com.google.protobuf.CodedOutputStream.computeBytesSize(1, archiveContent_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ArchiveUploadSource)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ArchiveUploadSource other = + (com.google.cloud.agentregistry.v1.ArchiveUploadSource) obj; + + if (!getArchiveContent().equals(other.getArchiveContent())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ARCHIVE_CONTENT_FIELD_NUMBER; + hash = (53 * hash) + getArchiveContent().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ArchiveUploadSource prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Direct write-only raw archive payload upload.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ArchiveUploadSource} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ArchiveUploadSource) + com.google.cloud.agentregistry.v1.ArchiveUploadSourceOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_ArchiveUploadSource_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_ArchiveUploadSource_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ArchiveUploadSource.class, + com.google.cloud.agentregistry.v1.ArchiveUploadSource.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ArchiveUploadSource.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + archiveContent_ = com.google.protobuf.ByteString.EMPTY; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_ArchiveUploadSource_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ArchiveUploadSource getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ArchiveUploadSource.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ArchiveUploadSource build() { + com.google.cloud.agentregistry.v1.ArchiveUploadSource result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ArchiveUploadSource buildPartial() { + com.google.cloud.agentregistry.v1.ArchiveUploadSource result = + new com.google.cloud.agentregistry.v1.ArchiveUploadSource(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.ArchiveUploadSource result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.archiveContent_ = archiveContent_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ArchiveUploadSource) { + return mergeFrom((com.google.cloud.agentregistry.v1.ArchiveUploadSource) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ArchiveUploadSource other) { + if (other == com.google.cloud.agentregistry.v1.ArchiveUploadSource.getDefaultInstance()) + return this; + if (!other.getArchiveContent().isEmpty()) { + setArchiveContent(other.getArchiveContent()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + archiveContent_ = input.readBytes(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.ByteString archiveContent_ = com.google.protobuf.ByteString.EMPTY; + + /** + * + * + *
+     * Required. Input only. Write-only raw ZIP/TAR archive payload bytes
+     * containing the skill package.
+     * 
+ * + * + * bytes archive_content = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY]; + * + * + * @return The archiveContent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getArchiveContent() { + return archiveContent_; + } + + /** + * + * + *
+     * Required. Input only. Write-only raw ZIP/TAR archive payload bytes
+     * containing the skill package.
+     * 
+ * + * + * bytes archive_content = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY]; + * + * + * @param value The archiveContent to set. + * @return This builder for chaining. + */ + public Builder setArchiveContent(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + archiveContent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Input only. Write-only raw ZIP/TAR archive payload bytes
+     * containing the skill package.
+     * 
+ * + * + * bytes archive_content = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearArchiveContent() { + bitField0_ = (bitField0_ & ~0x00000001); + archiveContent_ = getDefaultInstance().getArchiveContent(); + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ArchiveUploadSource) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ArchiveUploadSource) + private static final com.google.cloud.agentregistry.v1.ArchiveUploadSource DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ArchiveUploadSource(); + } + + public static com.google.cloud.agentregistry.v1.ArchiveUploadSource getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ArchiveUploadSource parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ArchiveUploadSource getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ArchiveUploadSourceOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ArchiveUploadSourceOrBuilder.java new file mode 100644 index 000000000000..da8ef847365e --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ArchiveUploadSourceOrBuilder.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ArchiveUploadSourceOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ArchiveUploadSource) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Input only. Write-only raw ZIP/TAR archive payload bytes
+   * containing the skill package.
+   * 
+ * + * + * bytes archive_content = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = INPUT_ONLY]; + * + * + * @return The archiveContent. + */ + com.google.protobuf.ByteString getArchiveContent(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRequest.java new file mode 100644 index 000000000000..fc5053871157 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRequest.java @@ -0,0 +1,1337 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * =========================================================================
+ * # Skills Messages
+ *
+ * Message requesting creation of a logical Skill container.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.CreateSkillRequest} + */ +@com.google.protobuf.Generated +public final class CreateSkillRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.CreateSkillRequest) + CreateSkillRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "CreateSkillRequest"); + } + + // Use CreateSkillRequest.newBuilder() to construct. + private CreateSkillRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private CreateSkillRequest() { + parent_ = ""; + skillId_ = ""; + requestId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_CreateSkillRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_CreateSkillRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.CreateSkillRequest.class, + com.google.cloud.agentregistry.v1.CreateSkillRequest.Builder.class); + } + + private int bitField0_; + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. The project and location location to bootstrap.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The project and location location to bootstrap.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SKILL_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object skillId_ = ""; + + /** + * + * + *
+   * Required. Custom, user-defined unique container identifier.
+   * Must be unique within the parent project and location.
+   * This value should be 4-64 characters, and valid characters
+   * are `/[a-z][0-9]-/`.
+   * 
+ * + * string skill_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The skillId. + */ + @java.lang.Override + public java.lang.String getSkillId() { + java.lang.Object ref = skillId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + skillId_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Custom, user-defined unique container identifier.
+   * Must be unique within the parent project and location.
+   * This value should be 4-64 characters, and valid characters
+   * are `/[a-z][0-9]-/`.
+   * 
+ * + * string skill_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for skillId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSkillIdBytes() { + java.lang.Object ref = skillId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + skillId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SKILL_FIELD_NUMBER = 3; + private com.google.cloud.agentregistry.v1.Skill skill_; + + /** + * + * + *
+   * Required. Skill container body config.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skill field is set. + */ + @java.lang.Override + public boolean hasSkill() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Required. Skill container body config.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skill. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill getSkill() { + return skill_ == null ? com.google.cloud.agentregistry.v1.Skill.getDefaultInstance() : skill_; + } + + /** + * + * + *
+   * Required. Skill container body config.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillOrBuilder() { + return skill_ == null ? com.google.cloud.agentregistry.v1.Skill.getDefaultInstance() : skill_; + } + + public static final int REQUEST_ID_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object requestId_ = ""; + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + @java.lang.Override + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(skillId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, skillId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getSkill()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, requestId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(skillId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, skillId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getSkill()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, requestId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.CreateSkillRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.CreateSkillRequest other = + (com.google.cloud.agentregistry.v1.CreateSkillRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (!getSkillId().equals(other.getSkillId())) return false; + if (hasSkill() != other.hasSkill()) return false; + if (hasSkill()) { + if (!getSkill().equals(other.getSkill())) return false; + } + if (!getRequestId().equals(other.getRequestId())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + SKILL_ID_FIELD_NUMBER; + hash = (53 * hash) + getSkillId().hashCode(); + if (hasSkill()) { + hash = (37 * hash) + SKILL_FIELD_NUMBER; + hash = (53 * hash) + getSkill().hashCode(); + } + hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; + hash = (53 * hash) + getRequestId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.CreateSkillRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * =========================================================================
+   * # Skills Messages
+   *
+   * Message requesting creation of a logical Skill container.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.CreateSkillRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.CreateSkillRequest) + com.google.cloud.agentregistry.v1.CreateSkillRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_CreateSkillRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_CreateSkillRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.CreateSkillRequest.class, + com.google.cloud.agentregistry.v1.CreateSkillRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.CreateSkillRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetSkillFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + skillId_ = ""; + skill_ = null; + if (skillBuilder_ != null) { + skillBuilder_.dispose(); + skillBuilder_ = null; + } + requestId_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_CreateSkillRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.CreateSkillRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.CreateSkillRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.CreateSkillRequest build() { + com.google.cloud.agentregistry.v1.CreateSkillRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.CreateSkillRequest buildPartial() { + com.google.cloud.agentregistry.v1.CreateSkillRequest result = + new com.google.cloud.agentregistry.v1.CreateSkillRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.CreateSkillRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.skillId_ = skillId_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.skill_ = skillBuilder_ == null ? skill_ : skillBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.requestId_ = requestId_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.CreateSkillRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.CreateSkillRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.CreateSkillRequest other) { + if (other == com.google.cloud.agentregistry.v1.CreateSkillRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getSkillId().isEmpty()) { + skillId_ = other.skillId_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasSkill()) { + mergeSkill(other.getSkill()); + } + if (!other.getRequestId().isEmpty()) { + requestId_ = other.requestId_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + skillId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage(internalGetSkillFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + requestId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. The project and location location to bootstrap.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The project and location location to bootstrap.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The project and location location to bootstrap.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The project and location location to bootstrap.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The project and location location to bootstrap.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object skillId_ = ""; + + /** + * + * + *
+     * Required. Custom, user-defined unique container identifier.
+     * Must be unique within the parent project and location.
+     * This value should be 4-64 characters, and valid characters
+     * are `/[a-z][0-9]-/`.
+     * 
+ * + * string skill_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The skillId. + */ + public java.lang.String getSkillId() { + java.lang.Object ref = skillId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + skillId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Custom, user-defined unique container identifier.
+     * Must be unique within the parent project and location.
+     * This value should be 4-64 characters, and valid characters
+     * are `/[a-z][0-9]-/`.
+     * 
+ * + * string skill_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for skillId. + */ + public com.google.protobuf.ByteString getSkillIdBytes() { + java.lang.Object ref = skillId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + skillId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Custom, user-defined unique container identifier.
+     * Must be unique within the parent project and location.
+     * This value should be 4-64 characters, and valid characters
+     * are `/[a-z][0-9]-/`.
+     * 
+ * + * string skill_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The skillId to set. + * @return This builder for chaining. + */ + public Builder setSkillId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + skillId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Custom, user-defined unique container identifier.
+     * Must be unique within the parent project and location.
+     * This value should be 4-64 characters, and valid characters
+     * are `/[a-z][0-9]-/`.
+     * 
+ * + * string skill_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearSkillId() { + skillId_ = getDefaultInstance().getSkillId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Custom, user-defined unique container identifier.
+     * Must be unique within the parent project and location.
+     * This value should be 4-64 characters, and valid characters
+     * are `/[a-z][0-9]-/`.
+     * 
+ * + * string skill_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for skillId to set. + * @return This builder for chaining. + */ + public Builder setSkillIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + skillId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.cloud.agentregistry.v1.Skill skill_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder> + skillBuilder_; + + /** + * + * + *
+     * Required. Skill container body config.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skill field is set. + */ + public boolean hasSkill() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+     * Required. Skill container body config.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skill. + */ + public com.google.cloud.agentregistry.v1.Skill getSkill() { + if (skillBuilder_ == null) { + return skill_ == null + ? com.google.cloud.agentregistry.v1.Skill.getDefaultInstance() + : skill_; + } else { + return skillBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Required. Skill container body config.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSkill(com.google.cloud.agentregistry.v1.Skill value) { + if (skillBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + skill_ = value; + } else { + skillBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Skill container body config.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSkill(com.google.cloud.agentregistry.v1.Skill.Builder builderForValue) { + if (skillBuilder_ == null) { + skill_ = builderForValue.build(); + } else { + skillBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Skill container body config.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeSkill(com.google.cloud.agentregistry.v1.Skill value) { + if (skillBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && skill_ != null + && skill_ != com.google.cloud.agentregistry.v1.Skill.getDefaultInstance()) { + getSkillBuilder().mergeFrom(value); + } else { + skill_ = value; + } + } else { + skillBuilder_.mergeFrom(value); + } + if (skill_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Required. Skill container body config.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearSkill() { + bitField0_ = (bitField0_ & ~0x00000004); + skill_ = null; + if (skillBuilder_ != null) { + skillBuilder_.dispose(); + skillBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Skill container body config.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.agentregistry.v1.Skill.Builder getSkillBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetSkillFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Required. Skill container body config.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillOrBuilder() { + if (skillBuilder_ != null) { + return skillBuilder_.getMessageOrBuilder(); + } else { + return skill_ == null + ? com.google.cloud.agentregistry.v1.Skill.getDefaultInstance() + : skill_; + } + } + + /** + * + * + *
+     * Required. Skill container body config.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder> + internalGetSkillFieldBuilder() { + if (skillBuilder_ == null) { + skillBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder>( + getSkill(), getParentForChildren(), isClean()); + skill_ = null; + } + return skillBuilder_; + } + + private java.lang.Object requestId_ = ""; + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + requestId_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearRequestId() { + requestId_ = getDefaultInstance().getRequestId(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + requestId_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.CreateSkillRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.CreateSkillRequest) + private static final com.google.cloud.agentregistry.v1.CreateSkillRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.CreateSkillRequest(); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateSkillRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.CreateSkillRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRequestOrBuilder.java new file mode 100644 index 000000000000..025d82e1f599 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRequestOrBuilder.java @@ -0,0 +1,160 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface CreateSkillRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.CreateSkillRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The project and location location to bootstrap.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. The project and location location to bootstrap.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Required. Custom, user-defined unique container identifier.
+   * Must be unique within the parent project and location.
+   * This value should be 4-64 characters, and valid characters
+   * are `/[a-z][0-9]-/`.
+   * 
+ * + * string skill_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The skillId. + */ + java.lang.String getSkillId(); + + /** + * + * + *
+   * Required. Custom, user-defined unique container identifier.
+   * Must be unique within the parent project and location.
+   * This value should be 4-64 characters, and valid characters
+   * are `/[a-z][0-9]-/`.
+   * 
+ * + * string skill_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for skillId. + */ + com.google.protobuf.ByteString getSkillIdBytes(); + + /** + * + * + *
+   * Required. Skill container body config.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skill field is set. + */ + boolean hasSkill(); + + /** + * + * + *
+   * Required. Skill container body config.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skill. + */ + com.google.cloud.agentregistry.v1.Skill getSkill(); + + /** + * + * + *
+   * Required. Skill container body config.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillOrBuilder(); + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + java.lang.String getRequestId(); + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + com.google.protobuf.ByteString getRequestIdBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRevisionRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRevisionRequest.java new file mode 100644 index 000000000000..8cd236d5249b --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRevisionRequest.java @@ -0,0 +1,1333 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Requesting creation of a new SkillRevision snapshot.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.CreateSkillRevisionRequest} + */ +@com.google.protobuf.Generated +public final class CreateSkillRevisionRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.CreateSkillRevisionRequest) + CreateSkillRevisionRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "CreateSkillRevisionRequest"); + } + + // Use CreateSkillRevisionRequest.newBuilder() to construct. + private CreateSkillRevisionRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private CreateSkillRevisionRequest() { + parent_ = ""; + skillRevisionId_ = ""; + requestId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_CreateSkillRevisionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_CreateSkillRevisionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest.class, + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest.Builder.class); + } + + private int bitField0_; + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. Parent logical container name.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Parent logical container name.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SKILL_REVISION_FIELD_NUMBER = 2; + private com.google.cloud.agentregistry.v1.SkillRevision skillRevision_; + + /** + * + * + *
+   * Required. Immutable SkillRevision snapshot definition schema.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skillRevision field is set. + */ + @java.lang.Override + public boolean hasSkillRevision() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Required. Immutable SkillRevision snapshot definition schema.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skillRevision. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision getSkillRevision() { + return skillRevision_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance() + : skillRevision_; + } + + /** + * + * + *
+   * Required. Immutable SkillRevision snapshot definition schema.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder getSkillRevisionOrBuilder() { + return skillRevision_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance() + : skillRevision_; + } + + public static final int SKILL_REVISION_ID_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object skillRevisionId_ = ""; + + /** + * + * + *
+   * Optional. Custom, user-defined unique revision identifier.
+   * Format: 4-63 characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`
+   * 
+ * + * string skill_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The skillRevisionId. + */ + @java.lang.Override + public java.lang.String getSkillRevisionId() { + java.lang.Object ref = skillRevisionId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + skillRevisionId_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Custom, user-defined unique revision identifier.
+   * Format: 4-63 characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`
+   * 
+ * + * string skill_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for skillRevisionId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSkillRevisionIdBytes() { + java.lang.Object ref = skillRevisionId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + skillRevisionId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int REQUEST_ID_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object requestId_ = ""; + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + @java.lang.Override + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getSkillRevision()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(skillRevisionId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, skillRevisionId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, requestId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getSkillRevision()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(skillRevisionId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, skillRevisionId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, requestId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest other = + (com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (hasSkillRevision() != other.hasSkillRevision()) return false; + if (hasSkillRevision()) { + if (!getSkillRevision().equals(other.getSkillRevision())) return false; + } + if (!getSkillRevisionId().equals(other.getSkillRevisionId())) return false; + if (!getRequestId().equals(other.getRequestId())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + if (hasSkillRevision()) { + hash = (37 * hash) + SKILL_REVISION_FIELD_NUMBER; + hash = (53 * hash) + getSkillRevision().hashCode(); + } + hash = (37 * hash) + SKILL_REVISION_ID_FIELD_NUMBER; + hash = (53 * hash) + getSkillRevisionId().hashCode(); + hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; + hash = (53 * hash) + getRequestId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Requesting creation of a new SkillRevision snapshot.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.CreateSkillRevisionRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.CreateSkillRevisionRequest) + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_CreateSkillRevisionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_CreateSkillRevisionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest.class, + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetSkillRevisionFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + skillRevision_ = null; + if (skillRevisionBuilder_ != null) { + skillRevisionBuilder_.dispose(); + skillRevisionBuilder_ = null; + } + skillRevisionId_ = ""; + requestId_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_CreateSkillRevisionRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest build() { + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest buildPartial() { + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest result = + new com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.skillRevision_ = + skillRevisionBuilder_ == null ? skillRevision_ : skillRevisionBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.skillRevisionId_ = skillRevisionId_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.requestId_ = requestId_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest other) { + if (other + == com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.hasSkillRevision()) { + mergeSkillRevision(other.getSkillRevision()); + } + if (!other.getSkillRevisionId().isEmpty()) { + skillRevisionId_ = other.skillRevisionId_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getRequestId().isEmpty()) { + requestId_ = other.requestId_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetSkillRevisionFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + skillRevisionId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + requestId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. Parent logical container name.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Parent logical container name.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Parent logical container name.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent logical container name.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent logical container name.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private com.google.cloud.agentregistry.v1.SkillRevision skillRevision_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision, + com.google.cloud.agentregistry.v1.SkillRevision.Builder, + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder> + skillRevisionBuilder_; + + /** + * + * + *
+     * Required. Immutable SkillRevision snapshot definition schema.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skillRevision field is set. + */ + public boolean hasSkillRevision() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * Required. Immutable SkillRevision snapshot definition schema.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skillRevision. + */ + public com.google.cloud.agentregistry.v1.SkillRevision getSkillRevision() { + if (skillRevisionBuilder_ == null) { + return skillRevision_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance() + : skillRevision_; + } else { + return skillRevisionBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Required. Immutable SkillRevision snapshot definition schema.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSkillRevision(com.google.cloud.agentregistry.v1.SkillRevision value) { + if (skillRevisionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + skillRevision_ = value; + } else { + skillRevisionBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Immutable SkillRevision snapshot definition schema.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSkillRevision( + com.google.cloud.agentregistry.v1.SkillRevision.Builder builderForValue) { + if (skillRevisionBuilder_ == null) { + skillRevision_ = builderForValue.build(); + } else { + skillRevisionBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Immutable SkillRevision snapshot definition schema.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeSkillRevision(com.google.cloud.agentregistry.v1.SkillRevision value) { + if (skillRevisionBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && skillRevision_ != null + && skillRevision_ + != com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance()) { + getSkillRevisionBuilder().mergeFrom(value); + } else { + skillRevision_ = value; + } + } else { + skillRevisionBuilder_.mergeFrom(value); + } + if (skillRevision_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Required. Immutable SkillRevision snapshot definition schema.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearSkillRevision() { + bitField0_ = (bitField0_ & ~0x00000002); + skillRevision_ = null; + if (skillRevisionBuilder_ != null) { + skillRevisionBuilder_.dispose(); + skillRevisionBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Immutable SkillRevision snapshot definition schema.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.agentregistry.v1.SkillRevision.Builder getSkillRevisionBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetSkillRevisionFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Required. Immutable SkillRevision snapshot definition schema.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder getSkillRevisionOrBuilder() { + if (skillRevisionBuilder_ != null) { + return skillRevisionBuilder_.getMessageOrBuilder(); + } else { + return skillRevision_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance() + : skillRevision_; + } + } + + /** + * + * + *
+     * Required. Immutable SkillRevision snapshot definition schema.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision, + com.google.cloud.agentregistry.v1.SkillRevision.Builder, + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder> + internalGetSkillRevisionFieldBuilder() { + if (skillRevisionBuilder_ == null) { + skillRevisionBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision, + com.google.cloud.agentregistry.v1.SkillRevision.Builder, + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder>( + getSkillRevision(), getParentForChildren(), isClean()); + skillRevision_ = null; + } + return skillRevisionBuilder_; + } + + private java.lang.Object skillRevisionId_ = ""; + + /** + * + * + *
+     * Optional. Custom, user-defined unique revision identifier.
+     * Format: 4-63 characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`
+     * 
+ * + * string skill_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The skillRevisionId. + */ + public java.lang.String getSkillRevisionId() { + java.lang.Object ref = skillRevisionId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + skillRevisionId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Custom, user-defined unique revision identifier.
+     * Format: 4-63 characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`
+     * 
+ * + * string skill_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for skillRevisionId. + */ + public com.google.protobuf.ByteString getSkillRevisionIdBytes() { + java.lang.Object ref = skillRevisionId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + skillRevisionId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Custom, user-defined unique revision identifier.
+     * Format: 4-63 characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`
+     * 
+ * + * string skill_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The skillRevisionId to set. + * @return This builder for chaining. + */ + public Builder setSkillRevisionId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + skillRevisionId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Custom, user-defined unique revision identifier.
+     * Format: 4-63 characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`
+     * 
+ * + * string skill_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearSkillRevisionId() { + skillRevisionId_ = getDefaultInstance().getSkillRevisionId(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Custom, user-defined unique revision identifier.
+     * Format: 4-63 characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`
+     * 
+ * + * string skill_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for skillRevisionId to set. + * @return This builder for chaining. + */ + public Builder setSkillRevisionIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + skillRevisionId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object requestId_ = ""; + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + requestId_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearRequestId() { + requestId_ = getDefaultInstance().getRequestId(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + requestId_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.CreateSkillRevisionRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.CreateSkillRevisionRequest) + private static final com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest(); + } + + public static com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateSkillRevisionRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRevisionRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRevisionRequestOrBuilder.java new file mode 100644 index 000000000000..cb83ac538d96 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/CreateSkillRevisionRequestOrBuilder.java @@ -0,0 +1,159 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface CreateSkillRevisionRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.CreateSkillRevisionRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Parent logical container name.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. Parent logical container name.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Required. Immutable SkillRevision snapshot definition schema.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skillRevision field is set. + */ + boolean hasSkillRevision(); + + /** + * + * + *
+   * Required. Immutable SkillRevision snapshot definition schema.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skillRevision. + */ + com.google.cloud.agentregistry.v1.SkillRevision getSkillRevision(); + + /** + * + * + *
+   * Required. Immutable SkillRevision snapshot definition schema.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision skill_revision = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder getSkillRevisionOrBuilder(); + + /** + * + * + *
+   * Optional. Custom, user-defined unique revision identifier.
+   * Format: 4-63 characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`
+   * 
+ * + * string skill_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The skillRevisionId. + */ + java.lang.String getSkillRevisionId(); + + /** + * + * + *
+   * Optional. Custom, user-defined unique revision identifier.
+   * Format: 4-63 characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$`
+   * 
+ * + * string skill_revision_id = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for skillRevisionId. + */ + com.google.protobuf.ByteString getSkillRevisionIdBytes(); + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + java.lang.String getRequestId(); + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + com.google.protobuf.ByteString getRequestIdBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRequest.java new file mode 100644 index 000000000000..8bcd132cd482 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRequest.java @@ -0,0 +1,918 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message requesting deletion of a Skill.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.DeleteSkillRequest} + */ +@com.google.protobuf.Generated +public final class DeleteSkillRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.DeleteSkillRequest) + DeleteSkillRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DeleteSkillRequest"); + } + + // Use DeleteSkillRequest.newBuilder() to construct. + private DeleteSkillRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DeleteSkillRequest() { + name_ = ""; + requestId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_DeleteSkillRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_DeleteSkillRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.DeleteSkillRequest.class, + com.google.cloud.agentregistry.v1.DeleteSkillRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. Target Skill container name to remove.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Target Skill container name to remove.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int REQUEST_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object requestId_ = ""; + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + @java.lang.Override + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FORCE_FIELD_NUMBER = 3; + private boolean force_ = false; + + /** + * + * + *
+   * Optional. If set to true, any child SkillRevisions under this Skill will
+   * also be deleted. Otherwise, the request will only succeed if the Skill has
+   * no child SkillRevisions.
+   * 
+ * + * bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The force. + */ + @java.lang.Override + public boolean getForce() { + return force_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, requestId_); + } + if (force_ != false) { + output.writeBool(3, force_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, requestId_); + } + if (force_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, force_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.DeleteSkillRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.DeleteSkillRequest other = + (com.google.cloud.agentregistry.v1.DeleteSkillRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getRequestId().equals(other.getRequestId())) return false; + if (getForce() != other.getForce()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; + hash = (53 * hash) + getRequestId().hashCode(); + hash = (37 * hash) + FORCE_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getForce()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.DeleteSkillRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message requesting deletion of a Skill.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.DeleteSkillRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.DeleteSkillRequest) + com.google.cloud.agentregistry.v1.DeleteSkillRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_DeleteSkillRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_DeleteSkillRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.DeleteSkillRequest.class, + com.google.cloud.agentregistry.v1.DeleteSkillRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.DeleteSkillRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + requestId_ = ""; + force_ = false; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_DeleteSkillRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.DeleteSkillRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.DeleteSkillRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.DeleteSkillRequest build() { + com.google.cloud.agentregistry.v1.DeleteSkillRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.DeleteSkillRequest buildPartial() { + com.google.cloud.agentregistry.v1.DeleteSkillRequest result = + new com.google.cloud.agentregistry.v1.DeleteSkillRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.DeleteSkillRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.requestId_ = requestId_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.force_ = force_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.DeleteSkillRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.DeleteSkillRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.DeleteSkillRequest other) { + if (other == com.google.cloud.agentregistry.v1.DeleteSkillRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getRequestId().isEmpty()) { + requestId_ = other.requestId_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.getForce() != false) { + setForce(other.getForce()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + requestId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 24: + { + force_ = input.readBool(); + bitField0_ |= 0x00000004; + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. Target Skill container name to remove.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Target Skill container name to remove.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Target Skill container name to remove.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target Skill container name to remove.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target Skill container name to remove.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object requestId_ = ""; + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + requestId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearRequestId() { + requestId_ = getDefaultInstance().getRequestId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + requestId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private boolean force_; + + /** + * + * + *
+     * Optional. If set to true, any child SkillRevisions under this Skill will
+     * also be deleted. Otherwise, the request will only succeed if the Skill has
+     * no child SkillRevisions.
+     * 
+ * + * bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The force. + */ + @java.lang.Override + public boolean getForce() { + return force_; + } + + /** + * + * + *
+     * Optional. If set to true, any child SkillRevisions under this Skill will
+     * also be deleted. Otherwise, the request will only succeed if the Skill has
+     * no child SkillRevisions.
+     * 
+ * + * bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The force to set. + * @return This builder for chaining. + */ + public Builder setForce(boolean value) { + + force_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. If set to true, any child SkillRevisions under this Skill will
+     * also be deleted. Otherwise, the request will only succeed if the Skill has
+     * no child SkillRevisions.
+     * 
+ * + * bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearForce() { + bitField0_ = (bitField0_ & ~0x00000004); + force_ = false; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.DeleteSkillRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.DeleteSkillRequest) + private static final com.google.cloud.agentregistry.v1.DeleteSkillRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.DeleteSkillRequest(); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteSkillRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.DeleteSkillRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRequestOrBuilder.java new file mode 100644 index 000000000000..26d70aafb540 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRequestOrBuilder.java @@ -0,0 +1,103 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface DeleteSkillRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.DeleteSkillRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Target Skill container name to remove.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. Target Skill container name to remove.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + java.lang.String getRequestId(); + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + com.google.protobuf.ByteString getRequestIdBytes(); + + /** + * + * + *
+   * Optional. If set to true, any child SkillRevisions under this Skill will
+   * also be deleted. Otherwise, the request will only succeed if the Skill has
+   * no child SkillRevisions.
+   * 
+ * + * bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The force. + */ + boolean getForce(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRevisionRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRevisionRequest.java new file mode 100644 index 000000000000..793595dbbe90 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRevisionRequest.java @@ -0,0 +1,818 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Requesting deletion of a specific Revision.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.DeleteSkillRevisionRequest} + */ +@com.google.protobuf.Generated +public final class DeleteSkillRevisionRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.DeleteSkillRevisionRequest) + DeleteSkillRevisionRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DeleteSkillRevisionRequest"); + } + + // Use DeleteSkillRevisionRequest.newBuilder() to construct. + private DeleteSkillRevisionRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DeleteSkillRevisionRequest() { + name_ = ""; + requestId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_DeleteSkillRevisionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_DeleteSkillRevisionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest.class, + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. Target revision name to remove.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Target revision name to remove.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int REQUEST_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object requestId_ = ""; + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + @java.lang.Override + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, requestId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, requestId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest other = + (com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getRequestId().equals(other.getRequestId())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; + hash = (53 * hash) + getRequestId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Requesting deletion of a specific Revision.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.DeleteSkillRevisionRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.DeleteSkillRevisionRequest) + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_DeleteSkillRevisionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_DeleteSkillRevisionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest.class, + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + requestId_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_DeleteSkillRevisionRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest build() { + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest buildPartial() { + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest result = + new com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.requestId_ = requestId_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest other) { + if (other + == com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getRequestId().isEmpty()) { + requestId_ = other.requestId_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + requestId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. Target revision name to remove.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Target revision name to remove.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Target revision name to remove.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target revision name to remove.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target revision name to remove.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object requestId_ = ""; + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + requestId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearRequestId() { + requestId_ = getDefaultInstance().getRequestId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + requestId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.DeleteSkillRevisionRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.DeleteSkillRevisionRequest) + private static final com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest(); + } + + public static com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteSkillRevisionRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRevisionRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRevisionRequestOrBuilder.java new file mode 100644 index 000000000000..ad090d4e0f99 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/DeleteSkillRevisionRequestOrBuilder.java @@ -0,0 +1,88 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface DeleteSkillRevisionRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.DeleteSkillRevisionRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Target revision name to remove.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. Target revision name to remove.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + java.lang.String getRequestId(); + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + com.google.protobuf.ByteString getRequestIdBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/EndpointName.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/EndpointName.java index 729ee2fd29e0..bc7c26ac0fd9 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/EndpointName.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/EndpointName.java @@ -17,6 +17,7 @@ package com.google.cloud.agentregistry.v1; import com.google.api.pathtemplate.PathTemplate; +import com.google.api.pathtemplate.ValidationException; import com.google.api.resourcenames.ResourceName; import com.google.common.base.Preconditions; import com.google.common.collect.ImmutableMap; @@ -35,22 +36,39 @@ public class EndpointName implements ResourceName { private static final PathTemplate PROJECT_LOCATION_ENDPOINT = PathTemplate.createWithoutUrlEncoding( "projects/{project}/locations/{location}/endpoints/{endpoint}"); + private static final PathTemplate PROJECT_LOCATION_AI_APPLICATION_ENDPOINT = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}"); private volatile Map fieldValuesMap; + private PathTemplate pathTemplate; + private String fixedValue; private final String project; private final String location; private final String endpoint; + private final String aiApplication; @Deprecated protected EndpointName() { project = null; location = null; endpoint = null; + aiApplication = null; } private EndpointName(Builder builder) { project = Preconditions.checkNotNull(builder.getProject()); location = Preconditions.checkNotNull(builder.getLocation()); endpoint = Preconditions.checkNotNull(builder.getEndpoint()); + aiApplication = null; + pathTemplate = PROJECT_LOCATION_ENDPOINT; + } + + private EndpointName(ProjectLocationAiApplicationEndpointBuilder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + aiApplication = Preconditions.checkNotNull(builder.getAiApplication()); + endpoint = Preconditions.checkNotNull(builder.getEndpoint()); + pathTemplate = PROJECT_LOCATION_AI_APPLICATION_ENDPOINT; } public String getProject() { @@ -65,10 +83,23 @@ public String getEndpoint() { return endpoint; } + public String getAiApplication() { + return aiApplication; + } + public static Builder newBuilder() { return new Builder(); } + public static Builder newProjectLocationEndpointBuilder() { + return new Builder(); + } + + public static ProjectLocationAiApplicationEndpointBuilder + newProjectLocationAiApplicationEndpointBuilder() { + return new ProjectLocationAiApplicationEndpointBuilder(); + } + public Builder toBuilder() { return new Builder(this); } @@ -77,6 +108,21 @@ public static EndpointName of(String project, String location, String endpoint) return newBuilder().setProject(project).setLocation(location).setEndpoint(endpoint).build(); } + public static EndpointName ofProjectLocationEndpointName( + String project, String location, String endpoint) { + return newBuilder().setProject(project).setLocation(location).setEndpoint(endpoint).build(); + } + + public static EndpointName ofProjectLocationAiApplicationEndpointName( + String project, String location, String aiApplication, String endpoint) { + return newProjectLocationAiApplicationEndpointBuilder() + .setProject(project) + .setLocation(location) + .setAiApplication(aiApplication) + .setEndpoint(endpoint) + .build(); + } + public static String format(String project, String location, String endpoint) { return newBuilder() .setProject(project) @@ -86,14 +132,45 @@ public static String format(String project, String location, String endpoint) { .toString(); } + public static String formatProjectLocationEndpointName( + String project, String location, String endpoint) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setEndpoint(endpoint) + .build() + .toString(); + } + + public static String formatProjectLocationAiApplicationEndpointName( + String project, String location, String aiApplication, String endpoint) { + return newProjectLocationAiApplicationEndpointBuilder() + .setProject(project) + .setLocation(location) + .setAiApplication(aiApplication) + .setEndpoint(endpoint) + .build() + .toString(); + } + public static @Nullable EndpointName parse(String formattedString) { if (formattedString.isEmpty()) { return null; } - Map matchMap = - PROJECT_LOCATION_ENDPOINT.validatedMatch( - formattedString, "EndpointName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("endpoint")); + if (PROJECT_LOCATION_ENDPOINT.matches(formattedString)) { + Map matchMap = PROJECT_LOCATION_ENDPOINT.match(formattedString); + return ofProjectLocationEndpointName( + matchMap.get("project"), matchMap.get("location"), matchMap.get("endpoint")); + } else if (PROJECT_LOCATION_AI_APPLICATION_ENDPOINT.matches(formattedString)) { + Map matchMap = + PROJECT_LOCATION_AI_APPLICATION_ENDPOINT.match(formattedString); + return ofProjectLocationAiApplicationEndpointName( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("ai_application"), + matchMap.get("endpoint")); + } + throw new ValidationException("EndpointName.parse: formattedString not in valid format"); } public static List parseList(List formattedStrings) { @@ -117,7 +194,8 @@ public static List toStringList(List<@Nullable EndpointName> values) { } public static boolean isParsableFrom(String formattedString) { - return PROJECT_LOCATION_ENDPOINT.matches(formattedString); + return PROJECT_LOCATION_ENDPOINT.matches(formattedString) + || PROJECT_LOCATION_AI_APPLICATION_ENDPOINT.matches(formattedString); } @Override @@ -135,6 +213,9 @@ public Map getFieldValuesMap() { if (endpoint != null) { fieldMapBuilder.put("endpoint", endpoint); } + if (aiApplication != null) { + fieldMapBuilder.put("ai_application", aiApplication); + } fieldValuesMap = fieldMapBuilder.build(); } } @@ -148,8 +229,7 @@ public String getFieldValue(String fieldName) { @Override public String toString() { - return PROJECT_LOCATION_ENDPOINT.instantiate( - "project", project, "location", location, "endpoint", endpoint); + return fixedValue != null ? fixedValue : pathTemplate.instantiate(getFieldValuesMap()); } @Override @@ -161,7 +241,8 @@ public boolean equals(@Nullable Object o) { EndpointName that = ((EndpointName) o); return Objects.equals(this.project, that.project) && Objects.equals(this.location, that.location) - && Objects.equals(this.endpoint, that.endpoint); + && Objects.equals(this.endpoint, that.endpoint) + && Objects.equals(this.aiApplication, that.aiApplication); } return false; } @@ -170,11 +251,15 @@ public boolean equals(@Nullable Object o) { public int hashCode() { int h = 1; h *= 1000003; + h ^= Objects.hashCode(fixedValue); + h *= 1000003; h ^= Objects.hashCode(project); h *= 1000003; h ^= Objects.hashCode(location); h *= 1000003; h ^= Objects.hashCode(endpoint); + h *= 1000003; + h ^= Objects.hashCode(aiApplication); return h; } @@ -214,6 +299,10 @@ public Builder setEndpoint(String endpoint) { } private Builder(EndpointName endpointName) { + Preconditions.checkArgument( + Objects.equals(endpointName.pathTemplate, PROJECT_LOCATION_ENDPOINT), + "toBuilder is only supported when EndpointName has the pattern of" + + " projects/{project}/locations/{location}/endpoints/{endpoint}"); this.project = endpointName.project; this.location = endpointName.location; this.endpoint = endpointName.endpoint; @@ -223,4 +312,57 @@ public EndpointName build() { return new EndpointName(this); } } + + /** + * Builder for + * projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}. + */ + public static class ProjectLocationAiApplicationEndpointBuilder { + private String project; + private String location; + private String aiApplication; + private String endpoint; + + protected ProjectLocationAiApplicationEndpointBuilder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAiApplication() { + return aiApplication; + } + + public String getEndpoint() { + return endpoint; + } + + public ProjectLocationAiApplicationEndpointBuilder setProject(String project) { + this.project = project; + return this; + } + + public ProjectLocationAiApplicationEndpointBuilder setLocation(String location) { + this.location = location; + return this; + } + + public ProjectLocationAiApplicationEndpointBuilder setAiApplication(String aiApplication) { + this.aiApplication = aiApplication; + return this; + } + + public ProjectLocationAiApplicationEndpointBuilder setEndpoint(String endpoint) { + this.endpoint = endpoint; + return this; + } + + public EndpointName build() { + return new EndpointName(this); + } + } } diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/EndpointProto.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/EndpointProto.java index 071fb5e912c9..abd5a7fcb9ea 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/EndpointProto.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/EndpointProto.java @@ -63,7 +63,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "oogle/api/field_behavior.proto\032\031google/a" + "pi/resource.proto\032.google/cloud/agentreg" + "istry/v1/properties.proto\032\034google/protob" - + "uf/struct.proto\032\037google/protobuf/timestamp.proto\"\300\004\n" + + "uf/struct.proto\032\037google/protobuf/timestamp.proto\"\240\005\n" + "\010Endpoint\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\031\n" + "\013endpoint_id\030\010 \001(\tB\004\342A\001\003\022\032\n" @@ -79,13 +79,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\01327.google.cloud.agentregistry.v1.Endpoint.AttributesEntryB\004\342A\001\003\032J\n" + "\017AttributesEntry\022\013\n" + "\003key\030\001 \001(\t\022&\n" - + "\005value\030\002 \001(\0132\027.google.protobuf.Struct:\0028\001:}\352Az\n" - + "%agentregistry.googleapis.com/Endpoint\022 + * Represents a security Finding. + * + * + * Protobuf type {@code google.cloud.agentregistry.v1.Finding} + */ +@com.google.protobuf.Generated +public final class Finding extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.Finding) + FindingOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Finding"); + } + + // Use Finding.newBuilder() to construct. + private Finding(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Finding() { + name_ = ""; + uid_ = ""; + severity_ = 0; + findingClass_ = 0; + files_ = java.util.Collections.emptyList(); + detail_ = ""; + resource_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.FindingProto + .internal_static_google_cloud_agentregistry_v1_Finding_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.FindingProto + .internal_static_google_cloud_agentregistry_v1_Finding_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.Finding.class, + com.google.cloud.agentregistry.v1.Finding.Builder.class); + } + + /** + * + * + *
+   * Represents what kind of Finding it is.
+   * For more information on finding classes, see
+   * https://cloud.google.com/security-command-center/docs/concepts-vulnerabilities-findings#classes.
+   * 
+ * + * Protobuf enum {@code google.cloud.agentregistry.v1.Finding.FindingClass} + */ + public enum FindingClass implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unspecified finding class.
+     * 
+ * + * FINDING_CLASS_UNSPECIFIED = 0; + */ + FINDING_CLASS_UNSPECIFIED(0), + /** + * + * + *
+     * Describes a potential weakness in software that increases risk to
+     * Confidentiality & Integrity & Availability.
+     * 
+ * + * VULNERABILITY = 1; + */ + VULNERABILITY(1), + /** + * + * + *
+     * Describes a potential security risk due to plaintext credentials,
+     * keys, or tokens being exposed in an asset or workload.
+     * 
+ * + * SECRET = 3; + */ + SECRET(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "FindingClass"); + } + + /** + * + * + *
+     * Unspecified finding class.
+     * 
+ * + * FINDING_CLASS_UNSPECIFIED = 0; + */ + public static final int FINDING_CLASS_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * Describes a potential weakness in software that increases risk to
+     * Confidentiality & Integrity & Availability.
+     * 
+ * + * VULNERABILITY = 1; + */ + public static final int VULNERABILITY_VALUE = 1; + + /** + * + * + *
+     * Describes a potential security risk due to plaintext credentials,
+     * keys, or tokens being exposed in an asset or workload.
+     * 
+ * + * SECRET = 3; + */ + public static final int SECRET_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static FindingClass valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static FindingClass forNumber(int value) { + switch (value) { + case 0: + return FINDING_CLASS_UNSPECIFIED; + case 1: + return VULNERABILITY; + case 3: + return SECRET; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public FindingClass findValueByNumber(int number) { + return FindingClass.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.Finding.getDescriptor().getEnumTypes().get(0); + } + + private static final FindingClass[] VALUES = values(); + + public static FindingClass valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private FindingClass(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.agentregistry.v1.Finding.FindingClass) + } + + public interface FileOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.Finding.File) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Optional. Relative path of the file containing the finding.
+     * 
+ * + * string path = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The path. + */ + java.lang.String getPath(); + + /** + * + * + *
+     * Optional. Relative path of the file containing the finding.
+     * 
+ * + * string path = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for path. + */ + com.google.protobuf.ByteString getPathBytes(); + + /** + * + * + *
+     * Optional. Line number (1-based), or 0 if whole File / unknown.
+     * 
+ * + * int64 line_number = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The lineNumber. + */ + long getLineNumber(); + } + + /** + * + * + *
+   * File location of the finding.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.Finding.File} + */ + public static final class File extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.Finding.File) + FileOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "File"); + } + + // Use File.newBuilder() to construct. + private File(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private File() { + path_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.FindingProto + .internal_static_google_cloud_agentregistry_v1_Finding_File_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.FindingProto + .internal_static_google_cloud_agentregistry_v1_Finding_File_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.Finding.File.class, + com.google.cloud.agentregistry.v1.Finding.File.Builder.class); + } + + public static final int PATH_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object path_ = ""; + + /** + * + * + *
+     * Optional. Relative path of the file containing the finding.
+     * 
+ * + * string path = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The path. + */ + @java.lang.Override + public java.lang.String getPath() { + java.lang.Object ref = path_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + path_ = s; + return s; + } + } + + /** + * + * + *
+     * Optional. Relative path of the file containing the finding.
+     * 
+ * + * string path = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for path. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPathBytes() { + java.lang.Object ref = path_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + path_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int LINE_NUMBER_FIELD_NUMBER = 2; + private long lineNumber_ = 0L; + + /** + * + * + *
+     * Optional. Line number (1-based), or 0 if whole File / unknown.
+     * 
+ * + * int64 line_number = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The lineNumber. + */ + @java.lang.Override + public long getLineNumber() { + return lineNumber_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(path_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, path_); + } + if (lineNumber_ != 0L) { + output.writeInt64(2, lineNumber_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(path_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, path_); + } + if (lineNumber_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, lineNumber_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.Finding.File)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.Finding.File other = + (com.google.cloud.agentregistry.v1.Finding.File) obj; + + if (!getPath().equals(other.getPath())) return false; + if (getLineNumber() != other.getLineNumber()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PATH_FIELD_NUMBER; + hash = (53 * hash) + getPath().hashCode(); + hash = (37 * hash) + LINE_NUMBER_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getLineNumber()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Finding.File parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.Finding.File prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+     * File location of the finding.
+     * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.Finding.File} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.Finding.File) + com.google.cloud.agentregistry.v1.Finding.FileOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.FindingProto + .internal_static_google_cloud_agentregistry_v1_Finding_File_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.FindingProto + .internal_static_google_cloud_agentregistry_v1_Finding_File_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.Finding.File.class, + com.google.cloud.agentregistry.v1.Finding.File.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.Finding.File.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + path_ = ""; + lineNumber_ = 0L; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.FindingProto + .internal_static_google_cloud_agentregistry_v1_Finding_File_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding.File getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.Finding.File.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding.File build() { + com.google.cloud.agentregistry.v1.Finding.File result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding.File buildPartial() { + com.google.cloud.agentregistry.v1.Finding.File result = + new com.google.cloud.agentregistry.v1.Finding.File(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.Finding.File result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.path_ = path_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.lineNumber_ = lineNumber_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.Finding.File) { + return mergeFrom((com.google.cloud.agentregistry.v1.Finding.File) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.Finding.File other) { + if (other == com.google.cloud.agentregistry.v1.Finding.File.getDefaultInstance()) + return this; + if (!other.getPath().isEmpty()) { + path_ = other.path_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getLineNumber() != 0L) { + setLineNumber(other.getLineNumber()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + path_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + lineNumber_ = input.readInt64(); + bitField0_ |= 0x00000002; + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object path_ = ""; + + /** + * + * + *
+       * Optional. Relative path of the file containing the finding.
+       * 
+ * + * string path = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The path. + */ + public java.lang.String getPath() { + java.lang.Object ref = path_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + path_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * Optional. Relative path of the file containing the finding.
+       * 
+ * + * string path = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for path. + */ + public com.google.protobuf.ByteString getPathBytes() { + java.lang.Object ref = path_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + path_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * Optional. Relative path of the file containing the finding.
+       * 
+ * + * string path = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The path to set. + * @return This builder for chaining. + */ + public Builder setPath(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + path_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+       * Optional. Relative path of the file containing the finding.
+       * 
+ * + * string path = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPath() { + path_ = getDefaultInstance().getPath(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+       * Optional. Relative path of the file containing the finding.
+       * 
+ * + * string path = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for path to set. + * @return This builder for chaining. + */ + public Builder setPathBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + path_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private long lineNumber_; + + /** + * + * + *
+       * Optional. Line number (1-based), or 0 if whole File / unknown.
+       * 
+ * + * int64 line_number = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The lineNumber. + */ + @java.lang.Override + public long getLineNumber() { + return lineNumber_; + } + + /** + * + * + *
+       * Optional. Line number (1-based), or 0 if whole File / unknown.
+       * 
+ * + * int64 line_number = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The lineNumber to set. + * @return This builder for chaining. + */ + public Builder setLineNumber(long value) { + + lineNumber_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+       * Optional. Line number (1-based), or 0 if whole File / unknown.
+       * 
+ * + * int64 line_number = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearLineNumber() { + bitField0_ = (bitField0_ & ~0x00000002); + lineNumber_ = 0L; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.Finding.File) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.Finding.File) + private static final com.google.cloud.agentregistry.v1.Finding.File DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.Finding.File(); + } + + public static com.google.cloud.agentregistry.v1.Finding.File getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public File parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding.File getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Identifier. Resource name of the Finding.
+   * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Identifier. Resource name of the Finding.
+   * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object uid_ = ""; + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the Finding.
+   * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + @java.lang.Override + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the Finding.
+   * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 3; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 4; + private com.google.protobuf.Timestamp updateTime_; + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + public static final int SEVERITY_FIELD_NUMBER = 6; + private int severity_ = 0; + + /** + * + * + *
+   * Optional. Severity of the finding.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Severity severity = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for severity. + */ + @java.lang.Override + public int getSeverityValue() { + return severity_; + } + + /** + * + * + *
+   * Optional. Severity of the finding.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Severity severity = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The severity. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Severity getSeverity() { + com.google.cloud.agentregistry.v1.Severity result = + com.google.cloud.agentregistry.v1.Severity.forNumber(severity_); + return result == null ? com.google.cloud.agentregistry.v1.Severity.UNRECOGNIZED : result; + } + + public static final int FINDING_CLASS_FIELD_NUMBER = 7; + private int findingClass_ = 0; + + /** + * + * + *
+   * Optional. Class of the finding.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Finding.FindingClass finding_class = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for findingClass. + */ + @java.lang.Override + public int getFindingClassValue() { + return findingClass_; + } + + /** + * + * + *
+   * Optional. Class of the finding.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Finding.FindingClass finding_class = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The findingClass. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding.FindingClass getFindingClass() { + com.google.cloud.agentregistry.v1.Finding.FindingClass result = + com.google.cloud.agentregistry.v1.Finding.FindingClass.forNumber(findingClass_); + return result == null + ? com.google.cloud.agentregistry.v1.Finding.FindingClass.UNRECOGNIZED + : result; + } + + public static final int FILES_FIELD_NUMBER = 8; + + @SuppressWarnings("serial") + private java.util.List files_; + + /** + * + * + *
+   * Optional. File associated with the finding.
+   * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List getFilesList() { + return files_; + } + + /** + * + * + *
+   * Optional. File associated with the finding.
+   * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List + getFilesOrBuilderList() { + return files_; + } + + /** + * + * + *
+   * Optional. File associated with the finding.
+   * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public int getFilesCount() { + return files_.size(); + } + + /** + * + * + *
+   * Optional. File associated with the finding.
+   * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding.File getFiles(int index) { + return files_.get(index); + } + + /** + * + * + *
+   * Optional. File associated with the finding.
+   * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding.FileOrBuilder getFilesOrBuilder(int index) { + return files_.get(index); + } + + public static final int DETAIL_FIELD_NUMBER = 10; + + @SuppressWarnings("serial") + private volatile java.lang.Object detail_ = ""; + + /** + * + * + *
+   * Optional. Detailed description of the finding.
+   * 
+ * + * string detail = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The detail. + */ + @java.lang.Override + public java.lang.String getDetail() { + java.lang.Object ref = detail_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + detail_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Detailed description of the finding.
+   * 
+ * + * string detail = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for detail. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDetailBytes() { + java.lang.Object ref = detail_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + detail_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int RESOURCE_FIELD_NUMBER = 11; + + @SuppressWarnings("serial") + private volatile java.lang.Object resource_ = ""; + + /** + * + * + *
+   * Optional. The resource that the finding is associated with.
+   * 
+ * + * + * string resource = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. + */ + @java.lang.Override + public java.lang.String getResource() { + java.lang.Object ref = resource_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + resource_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. The resource that the finding is associated with.
+   * 
+ * + * + * string resource = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. + */ + @java.lang.Override + public com.google.protobuf.ByteString getResourceBytes() { + java.lang.Object ref = resource_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + resource_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uid_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, uid_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(4, getUpdateTime()); + } + if (severity_ != com.google.cloud.agentregistry.v1.Severity.SEVERITY_UNSPECIFIED.getNumber()) { + output.writeEnum(6, severity_); + } + if (findingClass_ + != com.google.cloud.agentregistry.v1.Finding.FindingClass.FINDING_CLASS_UNSPECIFIED + .getNumber()) { + output.writeEnum(7, findingClass_); + } + for (int i = 0; i < files_.size(); i++) { + output.writeMessage(8, files_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(detail_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 10, detail_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(resource_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 11, resource_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uid_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, uid_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getUpdateTime()); + } + if (severity_ != com.google.cloud.agentregistry.v1.Severity.SEVERITY_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(6, severity_); + } + if (findingClass_ + != com.google.cloud.agentregistry.v1.Finding.FindingClass.FINDING_CLASS_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, findingClass_); + } + for (int i = 0; i < files_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, files_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(detail_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(10, detail_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(resource_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(11, resource_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.Finding)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.Finding other = + (com.google.cloud.agentregistry.v1.Finding) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUid().equals(other.getUid())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (severity_ != other.severity_) return false; + if (findingClass_ != other.findingClass_) return false; + if (!getFilesList().equals(other.getFilesList())) return false; + if (!getDetail().equals(other.getDetail())) return false; + if (!getResource().equals(other.getResource())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + UID_FIELD_NUMBER; + hash = (53 * hash) + getUid().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + hash = (37 * hash) + SEVERITY_FIELD_NUMBER; + hash = (53 * hash) + severity_; + hash = (37 * hash) + FINDING_CLASS_FIELD_NUMBER; + hash = (53 * hash) + findingClass_; + if (getFilesCount() > 0) { + hash = (37 * hash) + FILES_FIELD_NUMBER; + hash = (53 * hash) + getFilesList().hashCode(); + } + hash = (37 * hash) + DETAIL_FIELD_NUMBER; + hash = (53 * hash) + getDetail().hashCode(); + hash = (37 * hash) + RESOURCE_FIELD_NUMBER; + hash = (53 * hash) + getResource().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.Finding parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Finding parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Finding parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Finding parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Finding parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Finding parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Finding parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Finding parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Finding parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Finding parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Finding parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Finding parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.Finding prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Represents a security Finding.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.Finding} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.Finding) + com.google.cloud.agentregistry.v1.FindingOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.FindingProto + .internal_static_google_cloud_agentregistry_v1_Finding_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.FindingProto + .internal_static_google_cloud_agentregistry_v1_Finding_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.Finding.class, + com.google.cloud.agentregistry.v1.Finding.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.Finding.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetCreateTimeFieldBuilder(); + internalGetUpdateTimeFieldBuilder(); + internalGetFilesFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + uid_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + severity_ = 0; + findingClass_ = 0; + if (filesBuilder_ == null) { + files_ = java.util.Collections.emptyList(); + } else { + files_ = null; + filesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000040); + detail_ = ""; + resource_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.FindingProto + .internal_static_google_cloud_agentregistry_v1_Finding_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.Finding.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding build() { + com.google.cloud.agentregistry.v1.Finding result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding buildPartial() { + com.google.cloud.agentregistry.v1.Finding result = + new com.google.cloud.agentregistry.v1.Finding(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.cloud.agentregistry.v1.Finding result) { + if (filesBuilder_ == null) { + if (((bitField0_ & 0x00000040) != 0)) { + files_ = java.util.Collections.unmodifiableList(files_); + bitField0_ = (bitField0_ & ~0x00000040); + } + result.files_ = files_; + } else { + result.files_ = filesBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.Finding result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.uid_ = uid_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.severity_ = severity_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.findingClass_ = findingClass_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.detail_ = detail_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.resource_ = resource_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.Finding) { + return mergeFrom((com.google.cloud.agentregistry.v1.Finding) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.Finding other) { + if (other == com.google.cloud.agentregistry.v1.Finding.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getUid().isEmpty()) { + uid_ = other.uid_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (other.severity_ != 0) { + setSeverityValue(other.getSeverityValue()); + } + if (other.findingClass_ != 0) { + setFindingClassValue(other.getFindingClassValue()); + } + if (filesBuilder_ == null) { + if (!other.files_.isEmpty()) { + if (files_.isEmpty()) { + files_ = other.files_; + bitField0_ = (bitField0_ & ~0x00000040); + } else { + ensureFilesIsMutable(); + files_.addAll(other.files_); + } + onChanged(); + } + } else { + if (!other.files_.isEmpty()) { + if (filesBuilder_.isEmpty()) { + filesBuilder_.dispose(); + filesBuilder_ = null; + files_ = other.files_; + bitField0_ = (bitField0_ & ~0x00000040); + filesBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetFilesFieldBuilder() + : null; + } else { + filesBuilder_.addAllMessages(other.files_); + } + } + } + if (!other.getDetail().isEmpty()) { + detail_ = other.detail_; + bitField0_ |= 0x00000080; + onChanged(); + } + if (!other.getResource().isEmpty()) { + resource_ = other.resource_; + bitField0_ |= 0x00000100; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + uid_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 48: + { + severity_ = input.readEnum(); + bitField0_ |= 0x00000010; + break; + } // case 48 + case 56: + { + findingClass_ = input.readEnum(); + bitField0_ |= 0x00000020; + break; + } // case 56 + case 66: + { + com.google.cloud.agentregistry.v1.Finding.File m = + input.readMessage( + com.google.cloud.agentregistry.v1.Finding.File.parser(), extensionRegistry); + if (filesBuilder_ == null) { + ensureFilesIsMutable(); + files_.add(m); + } else { + filesBuilder_.addMessage(m); + } + break; + } // case 66 + case 82: + { + detail_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000080; + break; + } // case 82 + case 90: + { + resource_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000100; + break; + } // case 90 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Identifier. Resource name of the Finding.
+     * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the Finding.
+     * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the Finding.
+     * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the Finding.
+     * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the Finding.
+     * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object uid_ = ""; + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the Finding.
+     * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the Finding.
+     * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the Finding.
+     * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @param value The uid to set. + * @return This builder for chaining. + */ + public Builder setUid(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + uid_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the Finding.
+     * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearUid() { + uid_ = getDefaultInstance().getUid(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the Finding.
+     * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for uid to set. + * @return This builder for chaining. + */ + public Builder setUidBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + uid_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000004); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + } else { + updateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && updateTime_ != null + && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getUpdateTimeBuilder().mergeFrom(value); + } else { + updateTime_ = value; + } + } else { + updateTimeBuilder_.mergeFrom(value); + } + if (updateTime_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000008); + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private int severity_ = 0; + + /** + * + * + *
+     * Optional. Severity of the finding.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Severity severity = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for severity. + */ + @java.lang.Override + public int getSeverityValue() { + return severity_; + } + + /** + * + * + *
+     * Optional. Severity of the finding.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Severity severity = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for severity to set. + * @return This builder for chaining. + */ + public Builder setSeverityValue(int value) { + severity_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Severity of the finding.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Severity severity = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The severity. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Severity getSeverity() { + com.google.cloud.agentregistry.v1.Severity result = + com.google.cloud.agentregistry.v1.Severity.forNumber(severity_); + return result == null ? com.google.cloud.agentregistry.v1.Severity.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * Optional. Severity of the finding.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Severity severity = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The severity to set. + * @return This builder for chaining. + */ + public Builder setSeverity(com.google.cloud.agentregistry.v1.Severity value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000010; + severity_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Severity of the finding.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Severity severity = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearSeverity() { + bitField0_ = (bitField0_ & ~0x00000010); + severity_ = 0; + onChanged(); + return this; + } + + private int findingClass_ = 0; + + /** + * + * + *
+     * Optional. Class of the finding.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Finding.FindingClass finding_class = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for findingClass. + */ + @java.lang.Override + public int getFindingClassValue() { + return findingClass_; + } + + /** + * + * + *
+     * Optional. Class of the finding.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Finding.FindingClass finding_class = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for findingClass to set. + * @return This builder for chaining. + */ + public Builder setFindingClassValue(int value) { + findingClass_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Class of the finding.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Finding.FindingClass finding_class = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The findingClass. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding.FindingClass getFindingClass() { + com.google.cloud.agentregistry.v1.Finding.FindingClass result = + com.google.cloud.agentregistry.v1.Finding.FindingClass.forNumber(findingClass_); + return result == null + ? com.google.cloud.agentregistry.v1.Finding.FindingClass.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Optional. Class of the finding.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Finding.FindingClass finding_class = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The findingClass to set. + * @return This builder for chaining. + */ + public Builder setFindingClass(com.google.cloud.agentregistry.v1.Finding.FindingClass value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000020; + findingClass_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Class of the finding.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Finding.FindingClass finding_class = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearFindingClass() { + bitField0_ = (bitField0_ & ~0x00000020); + findingClass_ = 0; + onChanged(); + return this; + } + + private java.util.List files_ = + java.util.Collections.emptyList(); + + private void ensureFilesIsMutable() { + if (!((bitField0_ & 0x00000040) != 0)) { + files_ = new java.util.ArrayList(files_); + bitField0_ |= 0x00000040; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Finding.File, + com.google.cloud.agentregistry.v1.Finding.File.Builder, + com.google.cloud.agentregistry.v1.Finding.FileOrBuilder> + filesBuilder_; + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List getFilesList() { + if (filesBuilder_ == null) { + return java.util.Collections.unmodifiableList(files_); + } else { + return filesBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public int getFilesCount() { + if (filesBuilder_ == null) { + return files_.size(); + } else { + return filesBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.agentregistry.v1.Finding.File getFiles(int index) { + if (filesBuilder_ == null) { + return files_.get(index); + } else { + return filesBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setFiles(int index, com.google.cloud.agentregistry.v1.Finding.File value) { + if (filesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFilesIsMutable(); + files_.set(index, value); + onChanged(); + } else { + filesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setFiles( + int index, com.google.cloud.agentregistry.v1.Finding.File.Builder builderForValue) { + if (filesBuilder_ == null) { + ensureFilesIsMutable(); + files_.set(index, builderForValue.build()); + onChanged(); + } else { + filesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addFiles(com.google.cloud.agentregistry.v1.Finding.File value) { + if (filesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFilesIsMutable(); + files_.add(value); + onChanged(); + } else { + filesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addFiles(int index, com.google.cloud.agentregistry.v1.Finding.File value) { + if (filesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFilesIsMutable(); + files_.add(index, value); + onChanged(); + } else { + filesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addFiles( + com.google.cloud.agentregistry.v1.Finding.File.Builder builderForValue) { + if (filesBuilder_ == null) { + ensureFilesIsMutable(); + files_.add(builderForValue.build()); + onChanged(); + } else { + filesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addFiles( + int index, com.google.cloud.agentregistry.v1.Finding.File.Builder builderForValue) { + if (filesBuilder_ == null) { + ensureFilesIsMutable(); + files_.add(index, builderForValue.build()); + onChanged(); + } else { + filesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addAllFiles( + java.lang.Iterable values) { + if (filesBuilder_ == null) { + ensureFilesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, files_); + onChanged(); + } else { + filesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearFiles() { + if (filesBuilder_ == null) { + files_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000040); + onChanged(); + } else { + filesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeFiles(int index) { + if (filesBuilder_ == null) { + ensureFilesIsMutable(); + files_.remove(index); + onChanged(); + } else { + filesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.agentregistry.v1.Finding.File.Builder getFilesBuilder(int index) { + return internalGetFilesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.agentregistry.v1.Finding.FileOrBuilder getFilesOrBuilder(int index) { + if (filesBuilder_ == null) { + return files_.get(index); + } else { + return filesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List + getFilesOrBuilderList() { + if (filesBuilder_ != null) { + return filesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(files_); + } + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.agentregistry.v1.Finding.File.Builder addFilesBuilder() { + return internalGetFilesFieldBuilder() + .addBuilder(com.google.cloud.agentregistry.v1.Finding.File.getDefaultInstance()); + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.agentregistry.v1.Finding.File.Builder addFilesBuilder(int index) { + return internalGetFilesFieldBuilder() + .addBuilder(index, com.google.cloud.agentregistry.v1.Finding.File.getDefaultInstance()); + } + + /** + * + * + *
+     * Optional. File associated with the finding.
+     * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List + getFilesBuilderList() { + return internalGetFilesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Finding.File, + com.google.cloud.agentregistry.v1.Finding.File.Builder, + com.google.cloud.agentregistry.v1.Finding.FileOrBuilder> + internalGetFilesFieldBuilder() { + if (filesBuilder_ == null) { + filesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Finding.File, + com.google.cloud.agentregistry.v1.Finding.File.Builder, + com.google.cloud.agentregistry.v1.Finding.FileOrBuilder>( + files_, ((bitField0_ & 0x00000040) != 0), getParentForChildren(), isClean()); + files_ = null; + } + return filesBuilder_; + } + + private java.lang.Object detail_ = ""; + + /** + * + * + *
+     * Optional. Detailed description of the finding.
+     * 
+ * + * string detail = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The detail. + */ + public java.lang.String getDetail() { + java.lang.Object ref = detail_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + detail_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Detailed description of the finding.
+     * 
+ * + * string detail = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for detail. + */ + public com.google.protobuf.ByteString getDetailBytes() { + java.lang.Object ref = detail_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + detail_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Detailed description of the finding.
+     * 
+ * + * string detail = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The detail to set. + * @return This builder for chaining. + */ + public Builder setDetail(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + detail_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Detailed description of the finding.
+     * 
+ * + * string detail = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDetail() { + detail_ = getDefaultInstance().getDetail(); + bitField0_ = (bitField0_ & ~0x00000080); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Detailed description of the finding.
+     * 
+ * + * string detail = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for detail to set. + * @return This builder for chaining. + */ + public Builder setDetailBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + detail_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + private java.lang.Object resource_ = ""; + + /** + * + * + *
+     * Optional. The resource that the finding is associated with.
+     * 
+ * + * + * string resource = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. + */ + public java.lang.String getResource() { + java.lang.Object ref = resource_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + resource_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. The resource that the finding is associated with.
+     * 
+ * + * + * string resource = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. + */ + public com.google.protobuf.ByteString getResourceBytes() { + java.lang.Object ref = resource_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + resource_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. The resource that the finding is associated with.
+     * 
+ * + * + * string resource = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The resource to set. + * @return This builder for chaining. + */ + public Builder setResource(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + resource_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The resource that the finding is associated with.
+     * 
+ * + * + * string resource = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearResource() { + resource_ = getDefaultInstance().getResource(); + bitField0_ = (bitField0_ & ~0x00000100); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The resource that the finding is associated with.
+     * 
+ * + * + * string resource = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for resource to set. + * @return This builder for chaining. + */ + public Builder setResourceBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + resource_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.Finding) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.Finding) + private static final com.google.cloud.agentregistry.v1.Finding DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.Finding(); + } + + public static com.google.cloud.agentregistry.v1.Finding getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Finding parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FindingName.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FindingName.java new file mode 100644 index 000000000000..0212a309df4d --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FindingName.java @@ -0,0 +1,226 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class FindingName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_FINDING = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/findings/{finding}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String finding; + + @Deprecated + protected FindingName() { + project = null; + location = null; + finding = null; + } + + private FindingName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + finding = Preconditions.checkNotNull(builder.getFinding()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getFinding() { + return finding; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static FindingName of(String project, String location, String finding) { + return newBuilder().setProject(project).setLocation(location).setFinding(finding).build(); + } + + public static String format(String project, String location, String finding) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setFinding(finding) + .build() + .toString(); + } + + public static @Nullable FindingName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_FINDING.validatedMatch( + formattedString, "FindingName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("finding")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable FindingName> values) { + List list = new ArrayList<>(values.size()); + for (FindingName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_FINDING.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (finding != null) { + fieldMapBuilder.put("finding", finding); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_FINDING.instantiate( + "project", project, "location", location, "finding", finding); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + FindingName that = ((FindingName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.finding, that.finding); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(finding); + return h; + } + + /** Builder for projects/{project}/locations/{location}/findings/{finding}. */ + public static class Builder { + private String project; + private String location; + private String finding; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getFinding() { + return finding; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setFinding(String finding) { + this.finding = finding; + return this; + } + + private Builder(FindingName findingName) { + this.project = findingName.project; + this.location = findingName.location; + this.finding = findingName.finding; + } + + public FindingName build() { + return new FindingName(this); + } + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FindingOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FindingOrBuilder.java new file mode 100644 index 000000000000..a3893a336f19 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FindingOrBuilder.java @@ -0,0 +1,348 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/finding.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface FindingOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.Finding) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Identifier. Resource name of the Finding.
+   * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Identifier. Resource name of the Finding.
+   * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the Finding.
+   * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + java.lang.String getUid(); + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the Finding.
+   * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + com.google.protobuf.ByteString getUidBytes(); + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
+   * Optional. Severity of the finding.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Severity severity = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for severity. + */ + int getSeverityValue(); + + /** + * + * + *
+   * Optional. Severity of the finding.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Severity severity = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The severity. + */ + com.google.cloud.agentregistry.v1.Severity getSeverity(); + + /** + * + * + *
+   * Optional. Class of the finding.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Finding.FindingClass finding_class = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for findingClass. + */ + int getFindingClassValue(); + + /** + * + * + *
+   * Optional. Class of the finding.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Finding.FindingClass finding_class = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The findingClass. + */ + com.google.cloud.agentregistry.v1.Finding.FindingClass getFindingClass(); + + /** + * + * + *
+   * Optional. File associated with the finding.
+   * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List getFilesList(); + + /** + * + * + *
+   * Optional. File associated with the finding.
+   * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.agentregistry.v1.Finding.File getFiles(int index); + + /** + * + * + *
+   * Optional. File associated with the finding.
+   * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + int getFilesCount(); + + /** + * + * + *
+   * Optional. File associated with the finding.
+   * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List + getFilesOrBuilderList(); + + /** + * + * + *
+   * Optional. File associated with the finding.
+   * 
+ * + * + * repeated .google.cloud.agentregistry.v1.Finding.File files = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.agentregistry.v1.Finding.FileOrBuilder getFilesOrBuilder(int index); + + /** + * + * + *
+   * Optional. Detailed description of the finding.
+   * 
+ * + * string detail = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The detail. + */ + java.lang.String getDetail(); + + /** + * + * + *
+   * Optional. Detailed description of the finding.
+   * 
+ * + * string detail = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for detail. + */ + com.google.protobuf.ByteString getDetailBytes(); + + /** + * + * + *
+   * Optional. The resource that the finding is associated with.
+   * 
+ * + * + * string resource = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. + */ + java.lang.String getResource(); + + /** + * + * + *
+   * Optional. The resource that the finding is associated with.
+   * 
+ * + * + * string resource = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. + */ + com.google.protobuf.ByteString getResourceBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FindingProto.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FindingProto.java new file mode 100644 index 000000000000..df9fcf23e897 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FindingProto.java @@ -0,0 +1,153 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/finding.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public final class FindingProto extends com.google.protobuf.GeneratedFile { + private FindingProto() {} + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "FindingProto"); + } + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_Finding_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_Finding_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_Finding_File_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_Finding_File_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n" + + "+google/cloud/agentregistry/v1/finding." + + "proto\022\035google.cloud.agentregistry.v1\032\037go" + + "ogle/api/field_behavior.proto\032\033google/ap" + + "i/field_info.proto\032\031google/api/resource." + + "proto\032\037google/protobuf/timestamp.proto\"\256\005\n" + + "\007Finding\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\022\031\n" + + "\003uid\030\002 \001(\tB\014\342A\001\003\342\214\317\327\010\002\010\001\0225\n" + + "\013create_time\030\003" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + + "\013update_time\030\004" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022?\n" + + "\010severity\030\006" + + " \001(\0162\'.google.cloud.agentregistry.v1.SeverityB\004\342A\001\001\022P\n\r" + + "finding_class\030\007" + + " \001(\01623.google.cloud.agentregistry.v1.Finding.FindingClassB\004\342A\001\001\022@\n" + + "\005files\030\010" + + " \003(\0132+.google.cloud.agentregistry.v1.Finding.FileB\004\342A\001\001\022\024\n" + + "\006detail\030\n" + + " \001(\tB\004\342A\001\001\022\034\n" + + "\010resource\030\013 \001(\tB\n" + + "\342A\001\001\372A\003\n" + + "\001*\0325\n" + + "\004File\022\022\n" + + "\004path\030\001 \001(\tB\004\342A\001\001\022\031\n" + + "\013line_number\030\002 \001(\003B\004\342A\001\001\"L\n" + + "\014FindingClass\022\035\n" + + "\031FINDING_CLASS_UNSPECIFIED\020\000\022\021\n\r" + + "VULNERABILITY\020\001\022\n\n" + + "\006SECRET\020\003:x\352Au\n" + + "$agentregistry.googleapis.com/Finding\022:projects/{project}/locations/{" + + "location}/findings/{finding}*\010findings2\007finding*u\n" + + "\010Severity\022\030\n" + + "\024SEVERITY_UNSPECIFIED\020\000\022\025\n" + + "\021SEVERITY_CRITICAL\020\001\022\021\n\r" + + "SEVERITY_HIGH\020\002\022\023\n" + + "\017SEVERITY_MEDIUM\020\003\022\020\n" + + "\014SEVERITY_LOW\020\004B\337\001\n" + + "!com.google.cloud.agentregistry.v1B\014FindingProtoP\001ZGcloud.google.com/g" + + "o/agentregistry/apiv1/agentregistrypb;ag" + + "entregistrypb\252\002\035Google.Cloud.AgentRegistry.V1\312\002\035Google\\Cloud\\AgentRegistry\\V1\352\002" + + " Google::Cloud::AgentRegistry::V1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.FieldInfoProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_agentregistry_v1_Finding_descriptor = + getDescriptor().getMessageType(0); + internal_static_google_cloud_agentregistry_v1_Finding_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_Finding_descriptor, + new java.lang.String[] { + "Name", + "Uid", + "CreateTime", + "UpdateTime", + "Severity", + "FindingClass", + "Files", + "Detail", + "Resource", + }); + internal_static_google_cloud_agentregistry_v1_Finding_File_descriptor = + internal_static_google_cloud_agentregistry_v1_Finding_descriptor.getNestedType(0); + internal_static_google_cloud_agentregistry_v1_Finding_File_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_Finding_File_descriptor, + new java.lang.String[] { + "Path", "LineNumber", + }); + descriptor.resolveAllFeaturesImmutable(); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.FieldInfoProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.FieldInfoProto.fieldInfo); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceReference); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Frontmatter.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Frontmatter.java new file mode 100644 index 000000000000..5536ccb84854 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Frontmatter.java @@ -0,0 +1,1532 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Structured metadata attributes extracted from the package's local SKILL.md
+ * frontmatter.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.Frontmatter} + */ +@com.google.protobuf.Generated +public final class Frontmatter extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.Frontmatter) + FrontmatterOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Frontmatter"); + } + + // Use Frontmatter.newBuilder() to construct. + private Frontmatter(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Frontmatter() { + name_ = ""; + description_ = ""; + license_ = ""; + compatibility_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Frontmatter_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 4: + return internalGetMetadata(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Frontmatter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.Frontmatter.class, + com.google.cloud.agentregistry.v1.Frontmatter.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. The name of the skill.
+   * 
+ * + * string name = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The name of the skill.
+   * 
+ * + * string name = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object description_ = ""; + + /** + * + * + *
+   * Required. Functional description.
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Functional description.
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int LICENSE_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private volatile java.lang.Object license_ = ""; + + /** + * + * + *
+   * Optional. License.
+   * 
+ * + * string license = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The license. + */ + @java.lang.Override + public java.lang.String getLicense() { + java.lang.Object ref = license_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + license_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. License.
+   * 
+ * + * string license = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for license. + */ + @java.lang.Override + public com.google.protobuf.ByteString getLicenseBytes() { + java.lang.Object ref = license_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + license_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int COMPATIBILITY_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object compatibility_ = ""; + + /** + * + * + *
+   * Optional. Environmental dependencies or companion services.
+   * 
+ * + * string compatibility = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The compatibility. + */ + @java.lang.Override + public java.lang.String getCompatibility() { + java.lang.Object ref = compatibility_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + compatibility_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Environmental dependencies or companion services.
+   * 
+ * + * string compatibility = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for compatibility. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCompatibilityBytes() { + java.lang.Object ref = compatibility_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + compatibility_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int METADATA_FIELD_NUMBER = 4; + + private static final class MetadataDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Frontmatter_MetadataEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + + @SuppressWarnings("serial") + private com.google.protobuf.MapField metadata_; + + private com.google.protobuf.MapField internalGetMetadata() { + if (metadata_ == null) { + return com.google.protobuf.MapField.emptyMapField(MetadataDefaultEntryHolder.defaultEntry); + } + return metadata_; + } + + public int getMetadataCount() { + return internalGetMetadata().getMap().size(); + } + + /** + * + * + *
+   * Optional. Extensible flattened map mapping custom tags, authors, and
+   * version parameters.
+   * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public boolean containsMetadata(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetMetadata().getMap().containsKey(key); + } + + /** Use {@link #getMetadataMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getMetadata() { + return getMetadataMap(); + } + + /** + * + * + *
+   * Optional. Extensible flattened map mapping custom tags, authors, and
+   * version parameters.
+   * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getMetadataMap() { + return internalGetMetadata().getMap(); + } + + /** + * + * + *
+   * Optional. Extensible flattened map mapping custom tags, authors, and
+   * version parameters.
+   * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public /* nullable */ java.lang.String getMetadataOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetMetadata().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
+   * Optional. Extensible flattened map mapping custom tags, authors, and
+   * version parameters.
+   * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.lang.String getMetadataOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetMetadata().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, description_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(compatibility_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, compatibility_); + } + com.google.protobuf.GeneratedMessage.serializeStringMapTo( + output, internalGetMetadata(), MetadataDefaultEntryHolder.defaultEntry, 4); + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(license_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, license_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, description_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(compatibility_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, compatibility_); + } + for (java.util.Map.Entry entry : + internalGetMetadata().getMap().entrySet()) { + com.google.protobuf.MapEntry metadata__ = + MetadataDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, metadata__); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(license_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(6, license_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.Frontmatter)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.Frontmatter other = + (com.google.cloud.agentregistry.v1.Frontmatter) obj; + + if (!getName().equals(other.getName())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (!getLicense().equals(other.getLicense())) return false; + if (!getCompatibility().equals(other.getCompatibility())) return false; + if (!internalGetMetadata().equals(other.internalGetMetadata())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + hash = (37 * hash) + LICENSE_FIELD_NUMBER; + hash = (53 * hash) + getLicense().hashCode(); + hash = (37 * hash) + COMPATIBILITY_FIELD_NUMBER; + hash = (53 * hash) + getCompatibility().hashCode(); + if (!internalGetMetadata().getMap().isEmpty()) { + hash = (37 * hash) + METADATA_FIELD_NUMBER; + hash = (53 * hash) + internalGetMetadata().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.Frontmatter prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Structured metadata attributes extracted from the package's local SKILL.md
+   * frontmatter.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.Frontmatter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.Frontmatter) + com.google.cloud.agentregistry.v1.FrontmatterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Frontmatter_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 4: + return internalGetMetadata(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( + int number) { + switch (number) { + case 4: + return internalGetMutableMetadata(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Frontmatter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.Frontmatter.class, + com.google.cloud.agentregistry.v1.Frontmatter.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.Frontmatter.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + description_ = ""; + license_ = ""; + compatibility_ = ""; + internalGetMutableMetadata().clear(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Frontmatter_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Frontmatter getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Frontmatter build() { + com.google.cloud.agentregistry.v1.Frontmatter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Frontmatter buildPartial() { + com.google.cloud.agentregistry.v1.Frontmatter result = + new com.google.cloud.agentregistry.v1.Frontmatter(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.Frontmatter result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.description_ = description_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.license_ = license_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.compatibility_ = compatibility_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.metadata_ = internalGetMetadata(); + result.metadata_.makeImmutable(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.Frontmatter) { + return mergeFrom((com.google.cloud.agentregistry.v1.Frontmatter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.Frontmatter other) { + if (other == com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getLicense().isEmpty()) { + license_ = other.license_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getCompatibility().isEmpty()) { + compatibility_ = other.compatibility_; + bitField0_ |= 0x00000008; + onChanged(); + } + internalGetMutableMetadata().mergeFrom(other.internalGetMetadata()); + bitField0_ |= 0x00000010; + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 18: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + compatibility_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 26 + case 34: + { + com.google.protobuf.MapEntry metadata__ = + input.readMessage( + MetadataDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableMetadata() + .getMutableMap() + .put(metadata__.getKey(), metadata__.getValue()); + bitField0_ |= 0x00000010; + break; + } // case 34 + case 42: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 42 + case 50: + { + license_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 50 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. The name of the skill.
+     * 
+ * + * string name = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The name of the skill.
+     * 
+ * + * string name = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The name of the skill.
+     * 
+ * + * string name = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the skill.
+     * 
+ * + * string name = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the skill.
+     * 
+ * + * string name = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + + /** + * + * + *
+     * Required. Functional description.
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Functional description.
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Functional description.
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + description_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Functional description.
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + description_ = getDefaultInstance().getDescription(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Functional description.
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object license_ = ""; + + /** + * + * + *
+     * Optional. License.
+     * 
+ * + * string license = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The license. + */ + public java.lang.String getLicense() { + java.lang.Object ref = license_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + license_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. License.
+     * 
+ * + * string license = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for license. + */ + public com.google.protobuf.ByteString getLicenseBytes() { + java.lang.Object ref = license_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + license_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. License.
+     * 
+ * + * string license = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The license to set. + * @return This builder for chaining. + */ + public Builder setLicense(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + license_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. License.
+     * 
+ * + * string license = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearLicense() { + license_ = getDefaultInstance().getLicense(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. License.
+     * 
+ * + * string license = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for license to set. + * @return This builder for chaining. + */ + public Builder setLicenseBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + license_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object compatibility_ = ""; + + /** + * + * + *
+     * Optional. Environmental dependencies or companion services.
+     * 
+ * + * string compatibility = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The compatibility. + */ + public java.lang.String getCompatibility() { + java.lang.Object ref = compatibility_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + compatibility_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Environmental dependencies or companion services.
+     * 
+ * + * string compatibility = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for compatibility. + */ + public com.google.protobuf.ByteString getCompatibilityBytes() { + java.lang.Object ref = compatibility_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + compatibility_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Environmental dependencies or companion services.
+     * 
+ * + * string compatibility = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The compatibility to set. + * @return This builder for chaining. + */ + public Builder setCompatibility(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + compatibility_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Environmental dependencies or companion services.
+     * 
+ * + * string compatibility = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearCompatibility() { + compatibility_ = getDefaultInstance().getCompatibility(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Environmental dependencies or companion services.
+     * 
+ * + * string compatibility = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for compatibility to set. + * @return This builder for chaining. + */ + public Builder setCompatibilityBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + compatibility_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private com.google.protobuf.MapField metadata_; + + private com.google.protobuf.MapField internalGetMetadata() { + if (metadata_ == null) { + return com.google.protobuf.MapField.emptyMapField(MetadataDefaultEntryHolder.defaultEntry); + } + return metadata_; + } + + private com.google.protobuf.MapField + internalGetMutableMetadata() { + if (metadata_ == null) { + metadata_ = + com.google.protobuf.MapField.newMapField(MetadataDefaultEntryHolder.defaultEntry); + } + if (!metadata_.isMutable()) { + metadata_ = metadata_.copy(); + } + bitField0_ |= 0x00000010; + onChanged(); + return metadata_; + } + + public int getMetadataCount() { + return internalGetMetadata().getMap().size(); + } + + /** + * + * + *
+     * Optional. Extensible flattened map mapping custom tags, authors, and
+     * version parameters.
+     * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public boolean containsMetadata(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetMetadata().getMap().containsKey(key); + } + + /** Use {@link #getMetadataMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getMetadata() { + return getMetadataMap(); + } + + /** + * + * + *
+     * Optional. Extensible flattened map mapping custom tags, authors, and
+     * version parameters.
+     * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.Map getMetadataMap() { + return internalGetMetadata().getMap(); + } + + /** + * + * + *
+     * Optional. Extensible flattened map mapping custom tags, authors, and
+     * version parameters.
+     * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public /* nullable */ java.lang.String getMetadataOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetMetadata().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
+     * Optional. Extensible flattened map mapping custom tags, authors, and
+     * version parameters.
+     * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.lang.String getMetadataOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetMetadata().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearMetadata() { + bitField0_ = (bitField0_ & ~0x00000010); + internalGetMutableMetadata().getMutableMap().clear(); + return this; + } + + /** + * + * + *
+     * Optional. Extensible flattened map mapping custom tags, authors, and
+     * version parameters.
+     * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeMetadata(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableMetadata().getMutableMap().remove(key); + return this; + } + + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableMetadata() { + bitField0_ |= 0x00000010; + return internalGetMutableMetadata().getMutableMap(); + } + + /** + * + * + *
+     * Optional. Extensible flattened map mapping custom tags, authors, and
+     * version parameters.
+     * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder putMetadata(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + internalGetMutableMetadata().getMutableMap().put(key, value); + bitField0_ |= 0x00000010; + return this; + } + + /** + * + * + *
+     * Optional. Extensible flattened map mapping custom tags, authors, and
+     * version parameters.
+     * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder putAllMetadata(java.util.Map values) { + internalGetMutableMetadata().getMutableMap().putAll(values); + bitField0_ |= 0x00000010; + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.Frontmatter) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.Frontmatter) + private static final com.google.cloud.agentregistry.v1.Frontmatter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.Frontmatter(); + } + + public static com.google.cloud.agentregistry.v1.Frontmatter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Frontmatter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Frontmatter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FrontmatterOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FrontmatterOrBuilder.java new file mode 100644 index 000000000000..425398764e8b --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/FrontmatterOrBuilder.java @@ -0,0 +1,200 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface FrontmatterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.Frontmatter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the skill.
+   * 
+ * + * string name = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. The name of the skill.
+   * 
+ * + * string name = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Required. Functional description.
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
+   * Required. Functional description.
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
+   * Optional. License.
+   * 
+ * + * string license = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The license. + */ + java.lang.String getLicense(); + + /** + * + * + *
+   * Optional. License.
+   * 
+ * + * string license = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for license. + */ + com.google.protobuf.ByteString getLicenseBytes(); + + /** + * + * + *
+   * Optional. Environmental dependencies or companion services.
+   * 
+ * + * string compatibility = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The compatibility. + */ + java.lang.String getCompatibility(); + + /** + * + * + *
+   * Optional. Environmental dependencies or companion services.
+   * 
+ * + * string compatibility = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for compatibility. + */ + com.google.protobuf.ByteString getCompatibilityBytes(); + + /** + * + * + *
+   * Optional. Extensible flattened map mapping custom tags, authors, and
+   * version parameters.
+   * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + int getMetadataCount(); + + /** + * + * + *
+   * Optional. Extensible flattened map mapping custom tags, authors, and
+   * version parameters.
+   * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + boolean containsMetadata(java.lang.String key); + + /** Use {@link #getMetadataMap()} instead. */ + @java.lang.Deprecated + java.util.Map getMetadata(); + + /** + * + * + *
+   * Optional. Extensible flattened map mapping custom tags, authors, and
+   * version parameters.
+   * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.util.Map getMetadataMap(); + + /** + * + * + *
+   * Optional. Extensible flattened map mapping custom tags, authors, and
+   * version parameters.
+   * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + /* nullable */ + java.lang.String getMetadataOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue); + + /** + * + * + *
+   * Optional. Extensible flattened map mapping custom tags, authors, and
+   * version parameters.
+   * 
+ * + * map<string, string> metadata = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.lang.String getMetadataOrThrow(java.lang.String key); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GcsSource.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GcsSource.java new file mode 100644 index 000000000000..bcf5090609dd --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GcsSource.java @@ -0,0 +1,710 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Specifications for Cloud Storage objects.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GcsSource} + */ +@com.google.protobuf.Generated +public final class GcsSource extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.GcsSource) + GcsSourceOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GcsSource"); + } + + // Use GcsSource.newBuilder() to construct. + private GcsSource(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GcsSource() { + uri_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_GcsSource_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_GcsSource_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GcsSource.class, + com.google.cloud.agentregistry.v1.GcsSource.Builder.class); + } + + public static final int URI_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object uri_ = ""; + + /** + * + * + *
+   * Required. Cloud Storage object URI.
+   * Format:
+   * `gs://{bucket_name}/{object_name}`
+   * 
+ * + * string uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The uri. + */ + @java.lang.Override + public java.lang.String getUri() { + java.lang.Object ref = uri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uri_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Cloud Storage object URI.
+   * Format:
+   * `gs://{bucket_name}/{object_name}`
+   * 
+ * + * string uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for uri. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUriBytes() { + java.lang.Object ref = uri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int GENERATION_FIELD_NUMBER = 2; + private long generation_ = 0L; + + /** + * + * + *
+   * Optional. Cloud Storage object generation ID. If not specified, the latest
+   * generation is used.
+   * 
+ * + * int64 generation = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The generation. + */ + @java.lang.Override + public long getGeneration() { + return generation_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uri_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, uri_); + } + if (generation_ != 0L) { + output.writeInt64(2, generation_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uri_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, uri_); + } + if (generation_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, generation_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.GcsSource)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.GcsSource other = + (com.google.cloud.agentregistry.v1.GcsSource) obj; + + if (!getUri().equals(other.getUri())) return false; + if (getGeneration() != other.getGeneration()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + URI_FIELD_NUMBER; + hash = (53 * hash) + getUri().hashCode(); + hash = (37 * hash) + GENERATION_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getGeneration()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GcsSource parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.GcsSource prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Specifications for Cloud Storage objects.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GcsSource} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.GcsSource) + com.google.cloud.agentregistry.v1.GcsSourceOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_GcsSource_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_GcsSource_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GcsSource.class, + com.google.cloud.agentregistry.v1.GcsSource.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.GcsSource.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + uri_ = ""; + generation_ = 0L; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_GcsSource_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GcsSource getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.GcsSource.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GcsSource build() { + com.google.cloud.agentregistry.v1.GcsSource result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GcsSource buildPartial() { + com.google.cloud.agentregistry.v1.GcsSource result = + new com.google.cloud.agentregistry.v1.GcsSource(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.GcsSource result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.uri_ = uri_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.generation_ = generation_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.GcsSource) { + return mergeFrom((com.google.cloud.agentregistry.v1.GcsSource) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.GcsSource other) { + if (other == com.google.cloud.agentregistry.v1.GcsSource.getDefaultInstance()) return this; + if (!other.getUri().isEmpty()) { + uri_ = other.uri_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getGeneration() != 0L) { + setGeneration(other.getGeneration()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + uri_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + generation_ = input.readInt64(); + bitField0_ |= 0x00000002; + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object uri_ = ""; + + /** + * + * + *
+     * Required. Cloud Storage object URI.
+     * Format:
+     * `gs://{bucket_name}/{object_name}`
+     * 
+ * + * string uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The uri. + */ + public java.lang.String getUri() { + java.lang.Object ref = uri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Cloud Storage object URI.
+     * Format:
+     * `gs://{bucket_name}/{object_name}`
+     * 
+ * + * string uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for uri. + */ + public com.google.protobuf.ByteString getUriBytes() { + java.lang.Object ref = uri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Cloud Storage object URI.
+     * Format:
+     * `gs://{bucket_name}/{object_name}`
+     * 
+ * + * string uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The uri to set. + * @return This builder for chaining. + */ + public Builder setUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + uri_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Cloud Storage object URI.
+     * Format:
+     * `gs://{bucket_name}/{object_name}`
+     * 
+ * + * string uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearUri() { + uri_ = getDefaultInstance().getUri(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Cloud Storage object URI.
+     * Format:
+     * `gs://{bucket_name}/{object_name}`
+     * 
+ * + * string uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for uri to set. + * @return This builder for chaining. + */ + public Builder setUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + uri_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private long generation_; + + /** + * + * + *
+     * Optional. Cloud Storage object generation ID. If not specified, the latest
+     * generation is used.
+     * 
+ * + * int64 generation = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The generation. + */ + @java.lang.Override + public long getGeneration() { + return generation_; + } + + /** + * + * + *
+     * Optional. Cloud Storage object generation ID. If not specified, the latest
+     * generation is used.
+     * 
+ * + * int64 generation = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The generation to set. + * @return This builder for chaining. + */ + public Builder setGeneration(long value) { + + generation_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Cloud Storage object generation ID. If not specified, the latest
+     * generation is used.
+     * 
+ * + * int64 generation = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearGeneration() { + bitField0_ = (bitField0_ & ~0x00000002); + generation_ = 0L; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.GcsSource) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.GcsSource) + private static final com.google.cloud.agentregistry.v1.GcsSource DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.GcsSource(); + } + + public static com.google.cloud.agentregistry.v1.GcsSource getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GcsSource parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GcsSource getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GcsSourceOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GcsSourceOrBuilder.java new file mode 100644 index 000000000000..40f1e3d28ae0 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GcsSourceOrBuilder.java @@ -0,0 +1,72 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface GcsSourceOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.GcsSource) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Cloud Storage object URI.
+   * Format:
+   * `gs://{bucket_name}/{object_name}`
+   * 
+ * + * string uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The uri. + */ + java.lang.String getUri(); + + /** + * + * + *
+   * Required. Cloud Storage object URI.
+   * Format:
+   * `gs://{bucket_name}/{object_name}`
+   * 
+ * + * string uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for uri. + */ + com.google.protobuf.ByteString getUriBytes(); + + /** + * + * + *
+   * Optional. Cloud Storage object generation ID. If not specified, the latest
+   * generation is used.
+   * 
+ * + * int64 generation = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The generation. + */ + long getGeneration(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationAgentRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationAgentRequest.java new file mode 100644 index 000000000000..1c20641f2bb6 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationAgentRequest.java @@ -0,0 +1,631 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for getting an Agent under an AI Application.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetAiApplicationAgentRequest} + */ +@com.google.protobuf.Generated +public final class GetAiApplicationAgentRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.GetAiApplicationAgentRequest) + GetAiApplicationAgentRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetAiApplicationAgentRequest"); + } + + // Use GetAiApplicationAgentRequest.newBuilder() to construct. + private GetAiApplicationAgentRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetAiApplicationAgentRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationAgentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationAgentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest.class, + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest other = + (com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for getting an Agent under an AI Application.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetAiApplicationAgentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.GetAiApplicationAgentRequest) + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationAgentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationAgentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest.class, + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationAgentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest build() { + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest buildPartial() { + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest result = + new com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest other) { + if (other + == com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.GetAiApplicationAgentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.GetAiApplicationAgentRequest) + private static final com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest(); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetAiApplicationAgentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationAgentRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationAgentRequestOrBuilder.java new file mode 100644 index 000000000000..e967ac5d0e7f --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationAgentRequestOrBuilder.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface GetAiApplicationAgentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.GetAiApplicationAgentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationEndpointRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationEndpointRequest.java new file mode 100644 index 000000000000..e801add71a66 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationEndpointRequest.java @@ -0,0 +1,634 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for getting an Endpoint under an AI Application.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest} + */ +@com.google.protobuf.Generated +public final class GetAiApplicationEndpointRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest) + GetAiApplicationEndpointRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetAiApplicationEndpointRequest"); + } + + // Use GetAiApplicationEndpointRequest.newBuilder() to construct. + private GetAiApplicationEndpointRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetAiApplicationEndpointRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationEndpointRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationEndpointRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest.class, + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest other = + (com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for getting an Endpoint under an AI Application.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest) + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationEndpointRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationEndpointRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest.class, + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest.Builder.class); + } + + // Construct using + // com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationEndpointRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest build() { + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest buildPartial() { + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest result = + new com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest other) { + if (other + == com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest) + private static final com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest(); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetAiApplicationEndpointRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationEndpointRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationEndpointRequestOrBuilder.java new file mode 100644 index 000000000000..585c30f34da8 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationEndpointRequestOrBuilder.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface GetAiApplicationEndpointRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationMcpServerRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationMcpServerRequest.java new file mode 100644 index 000000000000..62c1c545de18 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationMcpServerRequest.java @@ -0,0 +1,637 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for getting an McpServer under an AI Application.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest} + */ +@com.google.protobuf.Generated +public final class GetAiApplicationMcpServerRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest) + GetAiApplicationMcpServerRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetAiApplicationMcpServerRequest"); + } + + // Use GetAiApplicationMcpServerRequest.newBuilder() to construct. + private GetAiApplicationMcpServerRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetAiApplicationMcpServerRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationMcpServerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationMcpServerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest.class, + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest other = + (com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for getting an McpServer under an AI Application.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest) + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationMcpServerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationMcpServerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest.class, + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest.Builder.class); + } + + // Construct using + // com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationMcpServerRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest build() { + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest buildPartial() { + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest result = + new com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest) { + return mergeFrom( + (com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest other) { + if (other + == com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest + .getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Name of the resource.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest) + private static final com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest(); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetAiApplicationMcpServerRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationMcpServerRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationMcpServerRequestOrBuilder.java new file mode 100644 index 000000000000..0b841871a2df --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationMcpServerRequestOrBuilder.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface GetAiApplicationMcpServerRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. Name of the resource.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationRequest.java new file mode 100644 index 000000000000..e9a1f99f36d6 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationRequest.java @@ -0,0 +1,625 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for getting an AI Application.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetAiApplicationRequest} + */ +@com.google.protobuf.Generated +public final class GetAiApplicationRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.GetAiApplicationRequest) + GetAiApplicationRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetAiApplicationRequest"); + } + + // Use GetAiApplicationRequest.newBuilder() to construct. + private GetAiApplicationRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetAiApplicationRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetAiApplicationRequest.class, + com.google.cloud.agentregistry.v1.GetAiApplicationRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. Target AI Application resource name.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Target AI Application resource name.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.GetAiApplicationRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.GetAiApplicationRequest other = + (com.google.cloud.agentregistry.v1.GetAiApplicationRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.GetAiApplicationRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for getting an AI Application.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetAiApplicationRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.GetAiApplicationRequest) + com.google.cloud.agentregistry.v1.GetAiApplicationRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetAiApplicationRequest.class, + com.google.cloud.agentregistry.v1.GetAiApplicationRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.GetAiApplicationRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetAiApplicationRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.GetAiApplicationRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationRequest build() { + com.google.cloud.agentregistry.v1.GetAiApplicationRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationRequest buildPartial() { + com.google.cloud.agentregistry.v1.GetAiApplicationRequest result = + new com.google.cloud.agentregistry.v1.GetAiApplicationRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.GetAiApplicationRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.GetAiApplicationRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.GetAiApplicationRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.GetAiApplicationRequest other) { + if (other == com.google.cloud.agentregistry.v1.GetAiApplicationRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. Target AI Application resource name.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Target AI Application resource name.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Target AI Application resource name.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target AI Application resource name.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target AI Application resource name.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.GetAiApplicationRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.GetAiApplicationRequest) + private static final com.google.cloud.agentregistry.v1.GetAiApplicationRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.GetAiApplicationRequest(); + } + + public static com.google.cloud.agentregistry.v1.GetAiApplicationRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetAiApplicationRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetAiApplicationRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationRequestOrBuilder.java new file mode 100644 index 000000000000..3ccac4c899d0 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetAiApplicationRequestOrBuilder.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface GetAiApplicationRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.GetAiApplicationRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Target AI Application resource name.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. Target AI Application resource name.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetFindingRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetFindingRequest.java new file mode 100644 index 000000000000..73b9e19c9b69 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetFindingRequest.java @@ -0,0 +1,617 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for getting a Finding.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetFindingRequest} + */ +@com.google.protobuf.Generated +public final class GetFindingRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.GetFindingRequest) + GetFindingRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetFindingRequest"); + } + + // Use GetFindingRequest.newBuilder() to construct. + private GetFindingRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetFindingRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetFindingRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetFindingRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetFindingRequest.class, + com.google.cloud.agentregistry.v1.GetFindingRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. The name of the Finding to retrieve.
+   * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The name of the Finding to retrieve.
+   * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.GetFindingRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.GetFindingRequest other = + (com.google.cloud.agentregistry.v1.GetFindingRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.GetFindingRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for getting a Finding.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetFindingRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.GetFindingRequest) + com.google.cloud.agentregistry.v1.GetFindingRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetFindingRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetFindingRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetFindingRequest.class, + com.google.cloud.agentregistry.v1.GetFindingRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.GetFindingRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetFindingRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetFindingRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.GetFindingRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetFindingRequest build() { + com.google.cloud.agentregistry.v1.GetFindingRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetFindingRequest buildPartial() { + com.google.cloud.agentregistry.v1.GetFindingRequest result = + new com.google.cloud.agentregistry.v1.GetFindingRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.GetFindingRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.GetFindingRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.GetFindingRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.GetFindingRequest other) { + if (other == com.google.cloud.agentregistry.v1.GetFindingRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. The name of the Finding to retrieve.
+     * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The name of the Finding to retrieve.
+     * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The name of the Finding to retrieve.
+     * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the Finding to retrieve.
+     * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the Finding to retrieve.
+     * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.GetFindingRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.GetFindingRequest) + private static final com.google.cloud.agentregistry.v1.GetFindingRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.GetFindingRequest(); + } + + public static com.google.cloud.agentregistry.v1.GetFindingRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetFindingRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetFindingRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetFindingRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetFindingRequestOrBuilder.java new file mode 100644 index 000000000000..71eb5f4250f0 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetFindingRequestOrBuilder.java @@ -0,0 +1,60 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface GetFindingRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.GetFindingRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the Finding to retrieve.
+   * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. The name of the Finding to retrieve.
+   * Format: `projects/{project}/locations/{location}/findings/{finding}`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetPublisherRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetPublisherRequest.java new file mode 100644 index 000000000000..67803000b1fc --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetPublisherRequest.java @@ -0,0 +1,618 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Requesting details of a specific Publisher.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetPublisherRequest} + */ +@com.google.protobuf.Generated +public final class GetPublisherRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.GetPublisherRequest) + GetPublisherRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetPublisherRequest"); + } + + // Use GetPublisherRequest.newBuilder() to construct. + private GetPublisherRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetPublisherRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetPublisherRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetPublisherRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetPublisherRequest.class, + com.google.cloud.agentregistry.v1.GetPublisherRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. Target publisher resource name.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Target publisher resource name.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.GetPublisherRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.GetPublisherRequest other = + (com.google.cloud.agentregistry.v1.GetPublisherRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.GetPublisherRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Requesting details of a specific Publisher.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetPublisherRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.GetPublisherRequest) + com.google.cloud.agentregistry.v1.GetPublisherRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetPublisherRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetPublisherRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetPublisherRequest.class, + com.google.cloud.agentregistry.v1.GetPublisherRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.GetPublisherRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetPublisherRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetPublisherRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.GetPublisherRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetPublisherRequest build() { + com.google.cloud.agentregistry.v1.GetPublisherRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetPublisherRequest buildPartial() { + com.google.cloud.agentregistry.v1.GetPublisherRequest result = + new com.google.cloud.agentregistry.v1.GetPublisherRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.GetPublisherRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.GetPublisherRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.GetPublisherRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.GetPublisherRequest other) { + if (other == com.google.cloud.agentregistry.v1.GetPublisherRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. Target publisher resource name.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Target publisher resource name.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Target publisher resource name.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target publisher resource name.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target publisher resource name.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.GetPublisherRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.GetPublisherRequest) + private static final com.google.cloud.agentregistry.v1.GetPublisherRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.GetPublisherRequest(); + } + + public static com.google.cloud.agentregistry.v1.GetPublisherRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetPublisherRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetPublisherRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetPublisherRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetPublisherRequestOrBuilder.java new file mode 100644 index 000000000000..50c10474cc2f --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetPublisherRequestOrBuilder.java @@ -0,0 +1,60 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface GetPublisherRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.GetPublisherRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Target publisher resource name.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. Target publisher resource name.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillEncryptionSpecRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillEncryptionSpecRequest.java new file mode 100644 index 000000000000..e05c1ee51517 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillEncryptionSpecRequest.java @@ -0,0 +1,625 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for requesting a SkillEncryptionSpec.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest} + */ +@com.google.protobuf.Generated +public final class GetSkillEncryptionSpecRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest) + GetSkillEncryptionSpecRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetSkillEncryptionSpecRequest"); + } + + // Use GetSkillEncryptionSpecRequest.newBuilder() to construct. + private GetSkillEncryptionSpecRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetSkillEncryptionSpecRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillEncryptionSpecRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillEncryptionSpecRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest.class, + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. The name of the SkillEncryptionSpec to retrieve.
+   * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The name of the SkillEncryptionSpec to retrieve.
+   * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest other = + (com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for requesting a SkillEncryptionSpec.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest) + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillEncryptionSpecRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillEncryptionSpecRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest.class, + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillEncryptionSpecRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest build() { + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest buildPartial() { + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest result = + new com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest other) { + if (other + == com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. The name of the SkillEncryptionSpec to retrieve.
+     * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The name of the SkillEncryptionSpec to retrieve.
+     * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The name of the SkillEncryptionSpec to retrieve.
+     * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the SkillEncryptionSpec to retrieve.
+     * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the SkillEncryptionSpec to retrieve.
+     * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest) + private static final com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest(); + } + + public static com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetSkillEncryptionSpecRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillEncryptionSpecRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillEncryptionSpecRequestOrBuilder.java new file mode 100644 index 000000000000..0515083097cd --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillEncryptionSpecRequestOrBuilder.java @@ -0,0 +1,60 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface GetSkillEncryptionSpecRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the SkillEncryptionSpec to retrieve.
+   * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. The name of the SkillEncryptionSpec to retrieve.
+   * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRequest.java new file mode 100644 index 000000000000..e21b71424b41 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRequest.java @@ -0,0 +1,610 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message requesting details of a Skill.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetSkillRequest} + */ +@com.google.protobuf.Generated +public final class GetSkillRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.GetSkillRequest) + GetSkillRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetSkillRequest"); + } + + // Use GetSkillRequest.newBuilder() to construct. + private GetSkillRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetSkillRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetSkillRequest.class, + com.google.cloud.agentregistry.v1.GetSkillRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. Target resource container name.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Target resource container name.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.GetSkillRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.GetSkillRequest other = + (com.google.cloud.agentregistry.v1.GetSkillRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.GetSkillRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message requesting details of a Skill.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetSkillRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.GetSkillRequest) + com.google.cloud.agentregistry.v1.GetSkillRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetSkillRequest.class, + com.google.cloud.agentregistry.v1.GetSkillRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.GetSkillRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.GetSkillRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillRequest build() { + com.google.cloud.agentregistry.v1.GetSkillRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillRequest buildPartial() { + com.google.cloud.agentregistry.v1.GetSkillRequest result = + new com.google.cloud.agentregistry.v1.GetSkillRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.GetSkillRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.GetSkillRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.GetSkillRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.GetSkillRequest other) { + if (other == com.google.cloud.agentregistry.v1.GetSkillRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. Target resource container name.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Target resource container name.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Target resource container name.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target resource container name.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target resource container name.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.GetSkillRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.GetSkillRequest) + private static final com.google.cloud.agentregistry.v1.GetSkillRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.GetSkillRequest(); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetSkillRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRequestOrBuilder.java new file mode 100644 index 000000000000..6ba0028895b0 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface GetSkillRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.GetSkillRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Target resource container name.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. Target resource container name.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRevisionRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRevisionRequest.java new file mode 100644 index 000000000000..25ba48d48186 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRevisionRequest.java @@ -0,0 +1,611 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Requesting details of a Revision.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetSkillRevisionRequest} + */ +@com.google.protobuf.Generated +public final class GetSkillRevisionRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.GetSkillRevisionRequest) + GetSkillRevisionRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetSkillRevisionRequest"); + } + + // Use GetSkillRevisionRequest.newBuilder() to construct. + private GetSkillRevisionRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetSkillRevisionRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillRevisionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillRevisionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest.class, + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. Target revision name.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Target revision name.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.GetSkillRevisionRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest other = + (com.google.cloud.agentregistry.v1.GetSkillRevisionRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Requesting details of a Revision.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.GetSkillRevisionRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.GetSkillRevisionRequest) + com.google.cloud.agentregistry.v1.GetSkillRevisionRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillRevisionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillRevisionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest.class, + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.GetSkillRevisionRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_GetSkillRevisionRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillRevisionRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.GetSkillRevisionRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillRevisionRequest build() { + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillRevisionRequest buildPartial() { + com.google.cloud.agentregistry.v1.GetSkillRevisionRequest result = + new com.google.cloud.agentregistry.v1.GetSkillRevisionRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.GetSkillRevisionRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.GetSkillRevisionRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.GetSkillRevisionRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.GetSkillRevisionRequest other) { + if (other == com.google.cloud.agentregistry.v1.GetSkillRevisionRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. Target revision name.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Target revision name.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Target revision name.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target revision name.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Target revision name.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.GetSkillRevisionRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.GetSkillRevisionRequest) + private static final com.google.cloud.agentregistry.v1.GetSkillRevisionRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.GetSkillRevisionRequest(); + } + + public static com.google.cloud.agentregistry.v1.GetSkillRevisionRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetSkillRevisionRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.GetSkillRevisionRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRevisionRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRevisionRequestOrBuilder.java new file mode 100644 index 000000000000..038f52509f3e --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/GetSkillRevisionRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface GetSkillRevisionRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.GetSkillRevisionRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Target revision name.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. Target revision name.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsRequest.java new file mode 100644 index 000000000000..bb9c99502979 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsRequest.java @@ -0,0 +1,922 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for requesting list of Agents under an AI Application.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest} + */ +@com.google.protobuf.Generated +public final class ListAiApplicationAgentsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest) + ListAiApplicationAgentsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAiApplicationAgentsRequest"); + } + + // Use ListAiApplicationAgentsRequest.newBuilder() to construct. + private ListAiApplicationAgentsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAiApplicationAgentsRequest() { + parent_ = ""; + pageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest.class, + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. Parent value (AI Application) for ListAiApplicationAgentsRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Parent value (AI Application) for ListAiApplicationAgentsRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest other = + (com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for requesting list of Agents under an AI Application.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest) + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest.class, + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest build() { + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest buildPartial() { + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest result = + new com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest other) { + if (other + == com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. Parent value (AI Application) for ListAiApplicationAgentsRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for ListAiApplicationAgentsRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for ListAiApplicationAgentsRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for ListAiApplicationAgentsRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for ListAiApplicationAgentsRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest) + private static final com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest(); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAiApplicationAgentsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsRequestOrBuilder.java new file mode 100644 index 000000000000..61e4a22a4bcb --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsRequestOrBuilder.java @@ -0,0 +1,102 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListAiApplicationAgentsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Parent value (AI Application) for ListAiApplicationAgentsRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. Parent value (AI Application) for ListAiApplicationAgentsRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsResponse.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsResponse.java new file mode 100644 index 000000000000..ed6a26cefaec --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsResponse.java @@ -0,0 +1,1120 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for response to listing Agents under an AI Application.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse} + */ +@com.google.protobuf.Generated +public final class ListAiApplicationAgentsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse) + ListAiApplicationAgentsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAiApplicationAgentsResponse"); + } + + // Use ListAiApplicationAgentsResponse.newBuilder() to construct. + private ListAiApplicationAgentsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAiApplicationAgentsResponse() { + agents_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse.class, + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse.Builder.class); + } + + public static final int AGENTS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List agents_; + + /** + * + * + *
+   * The list of Agents.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + @java.lang.Override + public java.util.List getAgentsList() { + return agents_; + } + + /** + * + * + *
+   * The list of Agents.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + @java.lang.Override + public java.util.List + getAgentsOrBuilderList() { + return agents_; + } + + /** + * + * + *
+   * The list of Agents.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + @java.lang.Override + public int getAgentsCount() { + return agents_.size(); + } + + /** + * + * + *
+   * The list of Agents.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Agent getAgents(int index) { + return agents_.get(index); + } + + /** + * + * + *
+   * The list of Agents.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.AgentOrBuilder getAgentsOrBuilder(int index) { + return agents_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < agents_.size(); i++) { + output.writeMessage(1, agents_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < agents_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, agents_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse other = + (com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse) obj; + + if (!getAgentsList().equals(other.getAgentsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getAgentsCount() > 0) { + hash = (37 * hash) + AGENTS_FIELD_NUMBER; + hash = (53 * hash) + getAgentsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for response to listing Agents under an AI Application.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse) + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse.class, + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse.Builder.class); + } + + // Construct using + // com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (agentsBuilder_ == null) { + agents_ = java.util.Collections.emptyList(); + } else { + agents_ = null; + agentsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationAgentsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse build() { + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse buildPartial() { + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse result = + new com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse result) { + if (agentsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + agents_ = java.util.Collections.unmodifiableList(agents_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.agents_ = agents_; + } else { + result.agents_ = agentsBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse other) { + if (other + == com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse.getDefaultInstance()) + return this; + if (agentsBuilder_ == null) { + if (!other.agents_.isEmpty()) { + if (agents_.isEmpty()) { + agents_ = other.agents_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureAgentsIsMutable(); + agents_.addAll(other.agents_); + } + onChanged(); + } + } else { + if (!other.agents_.isEmpty()) { + if (agentsBuilder_.isEmpty()) { + agentsBuilder_.dispose(); + agentsBuilder_ = null; + agents_ = other.agents_; + bitField0_ = (bitField0_ & ~0x00000001); + agentsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetAgentsFieldBuilder() + : null; + } else { + agentsBuilder_.addAllMessages(other.agents_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.agentregistry.v1.Agent m = + input.readMessage( + com.google.cloud.agentregistry.v1.Agent.parser(), extensionRegistry); + if (agentsBuilder_ == null) { + ensureAgentsIsMutable(); + agents_.add(m); + } else { + agentsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List agents_ = + java.util.Collections.emptyList(); + + private void ensureAgentsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + agents_ = new java.util.ArrayList(agents_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Agent, + com.google.cloud.agentregistry.v1.Agent.Builder, + com.google.cloud.agentregistry.v1.AgentOrBuilder> + agentsBuilder_; + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public java.util.List getAgentsList() { + if (agentsBuilder_ == null) { + return java.util.Collections.unmodifiableList(agents_); + } else { + return agentsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public int getAgentsCount() { + if (agentsBuilder_ == null) { + return agents_.size(); + } else { + return agentsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public com.google.cloud.agentregistry.v1.Agent getAgents(int index) { + if (agentsBuilder_ == null) { + return agents_.get(index); + } else { + return agentsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public Builder setAgents(int index, com.google.cloud.agentregistry.v1.Agent value) { + if (agentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAgentsIsMutable(); + agents_.set(index, value); + onChanged(); + } else { + agentsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public Builder setAgents( + int index, com.google.cloud.agentregistry.v1.Agent.Builder builderForValue) { + if (agentsBuilder_ == null) { + ensureAgentsIsMutable(); + agents_.set(index, builderForValue.build()); + onChanged(); + } else { + agentsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public Builder addAgents(com.google.cloud.agentregistry.v1.Agent value) { + if (agentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAgentsIsMutable(); + agents_.add(value); + onChanged(); + } else { + agentsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public Builder addAgents(int index, com.google.cloud.agentregistry.v1.Agent value) { + if (agentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAgentsIsMutable(); + agents_.add(index, value); + onChanged(); + } else { + agentsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public Builder addAgents(com.google.cloud.agentregistry.v1.Agent.Builder builderForValue) { + if (agentsBuilder_ == null) { + ensureAgentsIsMutable(); + agents_.add(builderForValue.build()); + onChanged(); + } else { + agentsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public Builder addAgents( + int index, com.google.cloud.agentregistry.v1.Agent.Builder builderForValue) { + if (agentsBuilder_ == null) { + ensureAgentsIsMutable(); + agents_.add(index, builderForValue.build()); + onChanged(); + } else { + agentsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public Builder addAllAgents( + java.lang.Iterable values) { + if (agentsBuilder_ == null) { + ensureAgentsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, agents_); + onChanged(); + } else { + agentsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public Builder clearAgents() { + if (agentsBuilder_ == null) { + agents_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + agentsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public Builder removeAgents(int index) { + if (agentsBuilder_ == null) { + ensureAgentsIsMutable(); + agents_.remove(index); + onChanged(); + } else { + agentsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public com.google.cloud.agentregistry.v1.Agent.Builder getAgentsBuilder(int index) { + return internalGetAgentsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public com.google.cloud.agentregistry.v1.AgentOrBuilder getAgentsOrBuilder(int index) { + if (agentsBuilder_ == null) { + return agents_.get(index); + } else { + return agentsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public java.util.List + getAgentsOrBuilderList() { + if (agentsBuilder_ != null) { + return agentsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(agents_); + } + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public com.google.cloud.agentregistry.v1.Agent.Builder addAgentsBuilder() { + return internalGetAgentsFieldBuilder() + .addBuilder(com.google.cloud.agentregistry.v1.Agent.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public com.google.cloud.agentregistry.v1.Agent.Builder addAgentsBuilder(int index) { + return internalGetAgentsFieldBuilder() + .addBuilder(index, com.google.cloud.agentregistry.v1.Agent.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of Agents.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + public java.util.List getAgentsBuilderList() { + return internalGetAgentsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Agent, + com.google.cloud.agentregistry.v1.Agent.Builder, + com.google.cloud.agentregistry.v1.AgentOrBuilder> + internalGetAgentsFieldBuilder() { + if (agentsBuilder_ == null) { + agentsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Agent, + com.google.cloud.agentregistry.v1.Agent.Builder, + com.google.cloud.agentregistry.v1.AgentOrBuilder>( + agents_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + agents_ = null; + } + return agentsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse) + private static final com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse(); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAiApplicationAgentsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsResponseOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsResponseOrBuilder.java new file mode 100644 index 000000000000..8985ace6a5c8 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationAgentsResponseOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListAiApplicationAgentsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of Agents.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + java.util.List getAgentsList(); + + /** + * + * + *
+   * The list of Agents.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + com.google.cloud.agentregistry.v1.Agent getAgents(int index); + + /** + * + * + *
+   * The list of Agents.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + int getAgentsCount(); + + /** + * + * + *
+   * The list of Agents.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + java.util.List + getAgentsOrBuilderList(); + + /** + * + * + *
+   * The list of Agents.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Agent agents = 1; + */ + com.google.cloud.agentregistry.v1.AgentOrBuilder getAgentsOrBuilder(int index); + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsRequest.java new file mode 100644 index 000000000000..88f42fb056d6 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsRequest.java @@ -0,0 +1,934 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for requesting list of Endpoints under an AI Application.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest} + */ +@com.google.protobuf.Generated +public final class ListAiApplicationEndpointsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest) + ListAiApplicationEndpointsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAiApplicationEndpointsRequest"); + } + + // Use ListAiApplicationEndpointsRequest.newBuilder() to construct. + private ListAiApplicationEndpointsRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAiApplicationEndpointsRequest() { + parent_ = ""; + pageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest.class, + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. Parent value (AI Application) for
+   * ListAiApplicationEndpointsRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Parent value (AI Application) for
+   * ListAiApplicationEndpointsRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest other = + (com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for requesting list of Endpoints under an AI Application.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest) + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest.class, + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest.Builder.class); + } + + // Construct using + // com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest build() { + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest buildPartial() { + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest result = + new com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest) { + return mergeFrom( + (com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest other) { + if (other + == com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest + .getDefaultInstance()) return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. Parent value (AI Application) for
+     * ListAiApplicationEndpointsRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for
+     * ListAiApplicationEndpointsRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for
+     * ListAiApplicationEndpointsRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for
+     * ListAiApplicationEndpointsRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for
+     * ListAiApplicationEndpointsRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest) + private static final com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest(); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAiApplicationEndpointsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsRequestOrBuilder.java new file mode 100644 index 000000000000..046c65484c1a --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsRequestOrBuilder.java @@ -0,0 +1,104 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListAiApplicationEndpointsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Parent value (AI Application) for
+   * ListAiApplicationEndpointsRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. Parent value (AI Application) for
+   * ListAiApplicationEndpointsRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsResponse.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsResponse.java new file mode 100644 index 000000000000..4deb50c7a637 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsResponse.java @@ -0,0 +1,1126 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for response to listing Endpoints under an AI Application.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse} + */ +@com.google.protobuf.Generated +public final class ListAiApplicationEndpointsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse) + ListAiApplicationEndpointsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAiApplicationEndpointsResponse"); + } + + // Use ListAiApplicationEndpointsResponse.newBuilder() to construct. + private ListAiApplicationEndpointsResponse( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAiApplicationEndpointsResponse() { + endpoints_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse.class, + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse.Builder.class); + } + + public static final int ENDPOINTS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List endpoints_; + + /** + * + * + *
+   * The list of Endpoints.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + @java.lang.Override + public java.util.List getEndpointsList() { + return endpoints_; + } + + /** + * + * + *
+   * The list of Endpoints.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + @java.lang.Override + public java.util.List + getEndpointsOrBuilderList() { + return endpoints_; + } + + /** + * + * + *
+   * The list of Endpoints.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + @java.lang.Override + public int getEndpointsCount() { + return endpoints_.size(); + } + + /** + * + * + *
+   * The list of Endpoints.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Endpoint getEndpoints(int index) { + return endpoints_.get(index); + } + + /** + * + * + *
+   * The list of Endpoints.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.EndpointOrBuilder getEndpointsOrBuilder(int index) { + return endpoints_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < endpoints_.size(); i++) { + output.writeMessage(1, endpoints_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < endpoints_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, endpoints_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse other = + (com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse) obj; + + if (!getEndpointsList().equals(other.getEndpointsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getEndpointsCount() > 0) { + hash = (37 * hash) + ENDPOINTS_FIELD_NUMBER; + hash = (53 * hash) + getEndpointsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for response to listing Endpoints under an AI Application.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse) + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse.class, + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse.Builder.class); + } + + // Construct using + // com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (endpointsBuilder_ == null) { + endpoints_ = java.util.Collections.emptyList(); + } else { + endpoints_ = null; + endpointsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationEndpointsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse build() { + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse buildPartial() { + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse result = + new com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse result) { + if (endpointsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + endpoints_ = java.util.Collections.unmodifiableList(endpoints_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.endpoints_ = endpoints_; + } else { + result.endpoints_ = endpointsBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse) { + return mergeFrom( + (com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse other) { + if (other + == com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse + .getDefaultInstance()) return this; + if (endpointsBuilder_ == null) { + if (!other.endpoints_.isEmpty()) { + if (endpoints_.isEmpty()) { + endpoints_ = other.endpoints_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureEndpointsIsMutable(); + endpoints_.addAll(other.endpoints_); + } + onChanged(); + } + } else { + if (!other.endpoints_.isEmpty()) { + if (endpointsBuilder_.isEmpty()) { + endpointsBuilder_.dispose(); + endpointsBuilder_ = null; + endpoints_ = other.endpoints_; + bitField0_ = (bitField0_ & ~0x00000001); + endpointsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetEndpointsFieldBuilder() + : null; + } else { + endpointsBuilder_.addAllMessages(other.endpoints_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.agentregistry.v1.Endpoint m = + input.readMessage( + com.google.cloud.agentregistry.v1.Endpoint.parser(), extensionRegistry); + if (endpointsBuilder_ == null) { + ensureEndpointsIsMutable(); + endpoints_.add(m); + } else { + endpointsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List endpoints_ = + java.util.Collections.emptyList(); + + private void ensureEndpointsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + endpoints_ = + new java.util.ArrayList(endpoints_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Endpoint, + com.google.cloud.agentregistry.v1.Endpoint.Builder, + com.google.cloud.agentregistry.v1.EndpointOrBuilder> + endpointsBuilder_; + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public java.util.List getEndpointsList() { + if (endpointsBuilder_ == null) { + return java.util.Collections.unmodifiableList(endpoints_); + } else { + return endpointsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public int getEndpointsCount() { + if (endpointsBuilder_ == null) { + return endpoints_.size(); + } else { + return endpointsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public com.google.cloud.agentregistry.v1.Endpoint getEndpoints(int index) { + if (endpointsBuilder_ == null) { + return endpoints_.get(index); + } else { + return endpointsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public Builder setEndpoints(int index, com.google.cloud.agentregistry.v1.Endpoint value) { + if (endpointsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEndpointsIsMutable(); + endpoints_.set(index, value); + onChanged(); + } else { + endpointsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public Builder setEndpoints( + int index, com.google.cloud.agentregistry.v1.Endpoint.Builder builderForValue) { + if (endpointsBuilder_ == null) { + ensureEndpointsIsMutable(); + endpoints_.set(index, builderForValue.build()); + onChanged(); + } else { + endpointsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public Builder addEndpoints(com.google.cloud.agentregistry.v1.Endpoint value) { + if (endpointsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEndpointsIsMutable(); + endpoints_.add(value); + onChanged(); + } else { + endpointsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public Builder addEndpoints(int index, com.google.cloud.agentregistry.v1.Endpoint value) { + if (endpointsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEndpointsIsMutable(); + endpoints_.add(index, value); + onChanged(); + } else { + endpointsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public Builder addEndpoints( + com.google.cloud.agentregistry.v1.Endpoint.Builder builderForValue) { + if (endpointsBuilder_ == null) { + ensureEndpointsIsMutable(); + endpoints_.add(builderForValue.build()); + onChanged(); + } else { + endpointsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public Builder addEndpoints( + int index, com.google.cloud.agentregistry.v1.Endpoint.Builder builderForValue) { + if (endpointsBuilder_ == null) { + ensureEndpointsIsMutable(); + endpoints_.add(index, builderForValue.build()); + onChanged(); + } else { + endpointsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public Builder addAllEndpoints( + java.lang.Iterable values) { + if (endpointsBuilder_ == null) { + ensureEndpointsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, endpoints_); + onChanged(); + } else { + endpointsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public Builder clearEndpoints() { + if (endpointsBuilder_ == null) { + endpoints_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + endpointsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public Builder removeEndpoints(int index) { + if (endpointsBuilder_ == null) { + ensureEndpointsIsMutable(); + endpoints_.remove(index); + onChanged(); + } else { + endpointsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public com.google.cloud.agentregistry.v1.Endpoint.Builder getEndpointsBuilder(int index) { + return internalGetEndpointsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public com.google.cloud.agentregistry.v1.EndpointOrBuilder getEndpointsOrBuilder(int index) { + if (endpointsBuilder_ == null) { + return endpoints_.get(index); + } else { + return endpointsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public java.util.List + getEndpointsOrBuilderList() { + if (endpointsBuilder_ != null) { + return endpointsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(endpoints_); + } + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public com.google.cloud.agentregistry.v1.Endpoint.Builder addEndpointsBuilder() { + return internalGetEndpointsFieldBuilder() + .addBuilder(com.google.cloud.agentregistry.v1.Endpoint.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public com.google.cloud.agentregistry.v1.Endpoint.Builder addEndpointsBuilder(int index) { + return internalGetEndpointsFieldBuilder() + .addBuilder(index, com.google.cloud.agentregistry.v1.Endpoint.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of Endpoints.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + public java.util.List + getEndpointsBuilderList() { + return internalGetEndpointsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Endpoint, + com.google.cloud.agentregistry.v1.Endpoint.Builder, + com.google.cloud.agentregistry.v1.EndpointOrBuilder> + internalGetEndpointsFieldBuilder() { + if (endpointsBuilder_ == null) { + endpointsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Endpoint, + com.google.cloud.agentregistry.v1.Endpoint.Builder, + com.google.cloud.agentregistry.v1.EndpointOrBuilder>( + endpoints_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + endpoints_ = null; + } + return endpointsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse) + private static final com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse(); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAiApplicationEndpointsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsResponseOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsResponseOrBuilder.java new file mode 100644 index 000000000000..feacf05d056e --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationEndpointsResponseOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListAiApplicationEndpointsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of Endpoints.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + java.util.List getEndpointsList(); + + /** + * + * + *
+   * The list of Endpoints.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + com.google.cloud.agentregistry.v1.Endpoint getEndpoints(int index); + + /** + * + * + *
+   * The list of Endpoints.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + int getEndpointsCount(); + + /** + * + * + *
+   * The list of Endpoints.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + java.util.List + getEndpointsOrBuilderList(); + + /** + * + * + *
+   * The list of Endpoints.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Endpoint endpoints = 1; + */ + com.google.cloud.agentregistry.v1.EndpointOrBuilder getEndpointsOrBuilder(int index); + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersRequest.java new file mode 100644 index 000000000000..31b7a283627f --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersRequest.java @@ -0,0 +1,934 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for requesting list of McpServers under an AI Application.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest} + */ +@com.google.protobuf.Generated +public final class ListAiApplicationMcpServersRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest) + ListAiApplicationMcpServersRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAiApplicationMcpServersRequest"); + } + + // Use ListAiApplicationMcpServersRequest.newBuilder() to construct. + private ListAiApplicationMcpServersRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAiApplicationMcpServersRequest() { + parent_ = ""; + pageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest.class, + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. Parent value (AI Application) for
+   * ListAiApplicationMcpServersRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Parent value (AI Application) for
+   * ListAiApplicationMcpServersRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest other = + (com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for requesting list of McpServers under an AI Application.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest) + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest.class, + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest.Builder.class); + } + + // Construct using + // com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest build() { + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest buildPartial() { + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest result = + new com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest) { + return mergeFrom( + (com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest other) { + if (other + == com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest + .getDefaultInstance()) return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. Parent value (AI Application) for
+     * ListAiApplicationMcpServersRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for
+     * ListAiApplicationMcpServersRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for
+     * ListAiApplicationMcpServersRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for
+     * ListAiApplicationMcpServersRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value (AI Application) for
+     * ListAiApplicationMcpServersRequest.
+     * Format:
+     * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest) + private static final com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest(); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAiApplicationMcpServersRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersRequestOrBuilder.java new file mode 100644 index 000000000000..d0d7ed7bba58 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersRequestOrBuilder.java @@ -0,0 +1,104 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListAiApplicationMcpServersRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Parent value (AI Application) for
+   * ListAiApplicationMcpServersRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. Parent value (AI Application) for
+   * ListAiApplicationMcpServersRequest.
+   * Format:
+   * `projects/{project}/locations/{location}/aiApplications/{ai_application}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersResponse.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersResponse.java new file mode 100644 index 000000000000..b2c314817070 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersResponse.java @@ -0,0 +1,1126 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for response to listing McpServers under an AI Application.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse} + */ +@com.google.protobuf.Generated +public final class ListAiApplicationMcpServersResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse) + ListAiApplicationMcpServersResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAiApplicationMcpServersResponse"); + } + + // Use ListAiApplicationMcpServersResponse.newBuilder() to construct. + private ListAiApplicationMcpServersResponse( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAiApplicationMcpServersResponse() { + mcpServers_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse.class, + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse.Builder.class); + } + + public static final int MCP_SERVERS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List mcpServers_; + + /** + * + * + *
+   * The list of McpServers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + @java.lang.Override + public java.util.List getMcpServersList() { + return mcpServers_; + } + + /** + * + * + *
+   * The list of McpServers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + @java.lang.Override + public java.util.List + getMcpServersOrBuilderList() { + return mcpServers_; + } + + /** + * + * + *
+   * The list of McpServers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + @java.lang.Override + public int getMcpServersCount() { + return mcpServers_.size(); + } + + /** + * + * + *
+   * The list of McpServers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.McpServer getMcpServers(int index) { + return mcpServers_.get(index); + } + + /** + * + * + *
+   * The list of McpServers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.McpServerOrBuilder getMcpServersOrBuilder(int index) { + return mcpServers_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < mcpServers_.size(); i++) { + output.writeMessage(1, mcpServers_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < mcpServers_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, mcpServers_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse other = + (com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse) obj; + + if (!getMcpServersList().equals(other.getMcpServersList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getMcpServersCount() > 0) { + hash = (37 * hash) + MCP_SERVERS_FIELD_NUMBER; + hash = (53 * hash) + getMcpServersList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for response to listing McpServers under an AI Application.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse) + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse.class, + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse.Builder.class); + } + + // Construct using + // com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (mcpServersBuilder_ == null) { + mcpServers_ = java.util.Collections.emptyList(); + } else { + mcpServers_ = null; + mcpServersBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationMcpServersResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse build() { + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse buildPartial() { + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse result = + new com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse result) { + if (mcpServersBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + mcpServers_ = java.util.Collections.unmodifiableList(mcpServers_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.mcpServers_ = mcpServers_; + } else { + result.mcpServers_ = mcpServersBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse) { + return mergeFrom( + (com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse other) { + if (other + == com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse + .getDefaultInstance()) return this; + if (mcpServersBuilder_ == null) { + if (!other.mcpServers_.isEmpty()) { + if (mcpServers_.isEmpty()) { + mcpServers_ = other.mcpServers_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureMcpServersIsMutable(); + mcpServers_.addAll(other.mcpServers_); + } + onChanged(); + } + } else { + if (!other.mcpServers_.isEmpty()) { + if (mcpServersBuilder_.isEmpty()) { + mcpServersBuilder_.dispose(); + mcpServersBuilder_ = null; + mcpServers_ = other.mcpServers_; + bitField0_ = (bitField0_ & ~0x00000001); + mcpServersBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetMcpServersFieldBuilder() + : null; + } else { + mcpServersBuilder_.addAllMessages(other.mcpServers_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.agentregistry.v1.McpServer m = + input.readMessage( + com.google.cloud.agentregistry.v1.McpServer.parser(), extensionRegistry); + if (mcpServersBuilder_ == null) { + ensureMcpServersIsMutable(); + mcpServers_.add(m); + } else { + mcpServersBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List mcpServers_ = + java.util.Collections.emptyList(); + + private void ensureMcpServersIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + mcpServers_ = + new java.util.ArrayList(mcpServers_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.McpServer, + com.google.cloud.agentregistry.v1.McpServer.Builder, + com.google.cloud.agentregistry.v1.McpServerOrBuilder> + mcpServersBuilder_; + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public java.util.List getMcpServersList() { + if (mcpServersBuilder_ == null) { + return java.util.Collections.unmodifiableList(mcpServers_); + } else { + return mcpServersBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public int getMcpServersCount() { + if (mcpServersBuilder_ == null) { + return mcpServers_.size(); + } else { + return mcpServersBuilder_.getCount(); + } + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public com.google.cloud.agentregistry.v1.McpServer getMcpServers(int index) { + if (mcpServersBuilder_ == null) { + return mcpServers_.get(index); + } else { + return mcpServersBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public Builder setMcpServers(int index, com.google.cloud.agentregistry.v1.McpServer value) { + if (mcpServersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMcpServersIsMutable(); + mcpServers_.set(index, value); + onChanged(); + } else { + mcpServersBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public Builder setMcpServers( + int index, com.google.cloud.agentregistry.v1.McpServer.Builder builderForValue) { + if (mcpServersBuilder_ == null) { + ensureMcpServersIsMutable(); + mcpServers_.set(index, builderForValue.build()); + onChanged(); + } else { + mcpServersBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public Builder addMcpServers(com.google.cloud.agentregistry.v1.McpServer value) { + if (mcpServersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMcpServersIsMutable(); + mcpServers_.add(value); + onChanged(); + } else { + mcpServersBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public Builder addMcpServers(int index, com.google.cloud.agentregistry.v1.McpServer value) { + if (mcpServersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMcpServersIsMutable(); + mcpServers_.add(index, value); + onChanged(); + } else { + mcpServersBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public Builder addMcpServers( + com.google.cloud.agentregistry.v1.McpServer.Builder builderForValue) { + if (mcpServersBuilder_ == null) { + ensureMcpServersIsMutable(); + mcpServers_.add(builderForValue.build()); + onChanged(); + } else { + mcpServersBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public Builder addMcpServers( + int index, com.google.cloud.agentregistry.v1.McpServer.Builder builderForValue) { + if (mcpServersBuilder_ == null) { + ensureMcpServersIsMutable(); + mcpServers_.add(index, builderForValue.build()); + onChanged(); + } else { + mcpServersBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public Builder addAllMcpServers( + java.lang.Iterable values) { + if (mcpServersBuilder_ == null) { + ensureMcpServersIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, mcpServers_); + onChanged(); + } else { + mcpServersBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public Builder clearMcpServers() { + if (mcpServersBuilder_ == null) { + mcpServers_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + mcpServersBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public Builder removeMcpServers(int index) { + if (mcpServersBuilder_ == null) { + ensureMcpServersIsMutable(); + mcpServers_.remove(index); + onChanged(); + } else { + mcpServersBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public com.google.cloud.agentregistry.v1.McpServer.Builder getMcpServersBuilder(int index) { + return internalGetMcpServersFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public com.google.cloud.agentregistry.v1.McpServerOrBuilder getMcpServersOrBuilder(int index) { + if (mcpServersBuilder_ == null) { + return mcpServers_.get(index); + } else { + return mcpServersBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public java.util.List + getMcpServersOrBuilderList() { + if (mcpServersBuilder_ != null) { + return mcpServersBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(mcpServers_); + } + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public com.google.cloud.agentregistry.v1.McpServer.Builder addMcpServersBuilder() { + return internalGetMcpServersFieldBuilder() + .addBuilder(com.google.cloud.agentregistry.v1.McpServer.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public com.google.cloud.agentregistry.v1.McpServer.Builder addMcpServersBuilder(int index) { + return internalGetMcpServersFieldBuilder() + .addBuilder(index, com.google.cloud.agentregistry.v1.McpServer.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of McpServers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + public java.util.List + getMcpServersBuilderList() { + return internalGetMcpServersFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.McpServer, + com.google.cloud.agentregistry.v1.McpServer.Builder, + com.google.cloud.agentregistry.v1.McpServerOrBuilder> + internalGetMcpServersFieldBuilder() { + if (mcpServersBuilder_ == null) { + mcpServersBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.McpServer, + com.google.cloud.agentregistry.v1.McpServer.Builder, + com.google.cloud.agentregistry.v1.McpServerOrBuilder>( + mcpServers_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + mcpServers_ = null; + } + return mcpServersBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse) + private static final com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse(); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAiApplicationMcpServersResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersResponseOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersResponseOrBuilder.java new file mode 100644 index 000000000000..e4f50f68f5c1 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationMcpServersResponseOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListAiApplicationMcpServersResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of McpServers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + java.util.List getMcpServersList(); + + /** + * + * + *
+   * The list of McpServers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + com.google.cloud.agentregistry.v1.McpServer getMcpServers(int index); + + /** + * + * + *
+   * The list of McpServers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + int getMcpServersCount(); + + /** + * + * + *
+   * The list of McpServers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + java.util.List + getMcpServersOrBuilderList(); + + /** + * + * + *
+   * The list of McpServers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.McpServer mcp_servers = 1; + */ + com.google.cloud.agentregistry.v1.McpServerOrBuilder getMcpServersOrBuilder(int index); + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsRequest.java new file mode 100644 index 000000000000..c82e2cde6c61 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsRequest.java @@ -0,0 +1,1286 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for requesting a list of AiApplications.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationsRequest} + */ +@com.google.protobuf.Generated +public final class ListAiApplicationsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListAiApplicationsRequest) + ListAiApplicationsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAiApplicationsRequest"); + } + + // Use ListAiApplicationsRequest.newBuilder() to construct. + private ListAiApplicationsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAiApplicationsRequest() { + parent_ = ""; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest.class, + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. Parent project and location to query.
+   * Format: `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Parent project and location to query.
+   * Format: `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object filter_ = ""; + + /** + * + * + *
+   * Optional. Filtering results.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Filtering results.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ORDER_BY_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object orderBy_ = ""; + + /** + * + * + *
+   * Optional. Hint for how to order the results.
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + @java.lang.Override + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Hint for how to order the results.
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + @java.lang.Override + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, filter_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, orderBy_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, filter_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, orderBy_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListAiApplicationsRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest other = + (com.google.cloud.agentregistry.v1.ListAiApplicationsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (37 * hash) + ORDER_BY_FIELD_NUMBER; + hash = (53 * hash) + getOrderBy().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for requesting a list of AiApplications.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListAiApplicationsRequest) + com.google.cloud.agentregistry.v1.ListAiApplicationsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest.class, + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ListAiApplicationsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationsRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListAiApplicationsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationsRequest build() { + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationsRequest buildPartial() { + com.google.cloud.agentregistry.v1.ListAiApplicationsRequest result = + new com.google.cloud.agentregistry.v1.ListAiApplicationsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.ListAiApplicationsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.filter_ = filter_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.orderBy_ = orderBy_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListAiApplicationsRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListAiApplicationsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ListAiApplicationsRequest other) { + if (other == com.google.cloud.agentregistry.v1.ListAiApplicationsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (!other.getOrderBy().isEmpty()) { + orderBy_ = other.orderBy_; + bitField0_ |= 0x00000010; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + filter_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + orderBy_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. Parent project and location to query.
+     * Format: `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Parent project and location to query.
+     * Format: `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Parent project and location to query.
+     * Format: `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent project and location to query.
+     * Format: `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent project and location to query.
+     * Format: `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + + /** + * + * + *
+     * Optional. Filtering results.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Filtering results.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Filtering results.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Filtering results.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + filter_ = getDefaultInstance().getFilter(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Filtering results.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private java.lang.Object orderBy_ = ""; + + /** + * + * + *
+     * Optional. Hint for how to order the results.
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Hint for how to order the results.
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Hint for how to order the results.
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderBy(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + orderBy_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Hint for how to order the results.
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearOrderBy() { + orderBy_ = getDefaultInstance().getOrderBy(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Hint for how to order the results.
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + orderBy_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListAiApplicationsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListAiApplicationsRequest) + private static final com.google.cloud.agentregistry.v1.ListAiApplicationsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListAiApplicationsRequest(); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAiApplicationsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsRequestOrBuilder.java new file mode 100644 index 000000000000..1c7cf9bc5e3d --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsRequestOrBuilder.java @@ -0,0 +1,152 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListAiApplicationsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListAiApplicationsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Parent project and location to query.
+   * Format: `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. Parent project and location to query.
+   * Format: `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
+   * Optional. Filtering results.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
+   * Optional. Filtering results.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
+   * Optional. Hint for how to order the results.
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + + /** + * + * + *
+   * Optional. Hint for how to order the results.
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsResponse.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsResponse.java new file mode 100644 index 000000000000..74378d3eea79 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsResponse.java @@ -0,0 +1,1419 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for response to listing AiApplications.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationsResponse} + */ +@com.google.protobuf.Generated +public final class ListAiApplicationsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListAiApplicationsResponse) + ListAiApplicationsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAiApplicationsResponse"); + } + + // Use ListAiApplicationsResponse.newBuilder() to construct. + private ListAiApplicationsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAiApplicationsResponse() { + aiApplications_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse.class, + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse.Builder.class); + } + + public static final int AI_APPLICATIONS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List aiApplications_; + + /** + * + * + *
+   * The list of AiApplications.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + @java.lang.Override + public java.util.List getAiApplicationsList() { + return aiApplications_; + } + + /** + * + * + *
+   * The list of AiApplications.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + @java.lang.Override + public java.util.List + getAiApplicationsOrBuilderList() { + return aiApplications_; + } + + /** + * + * + *
+   * The list of AiApplications.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + @java.lang.Override + public int getAiApplicationsCount() { + return aiApplications_.size(); + } + + /** + * + * + *
+   * The list of AiApplications.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.AiApplication getAiApplications(int index) { + return aiApplications_.get(index); + } + + /** + * + * + *
+   * The list of AiApplications.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.AiApplicationOrBuilder getAiApplicationsOrBuilder( + int index) { + return aiApplications_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UNREACHABLE_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList unreachable_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * Unordered list. Locations that could not be reached.
+   * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_; + } + + /** + * + * + *
+   * Unordered list. Locations that could not be reached.
+   * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + + /** + * + * + *
+   * Unordered list. Locations that could not be reached.
+   * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + + /** + * + * + *
+   * Unordered list. Locations that could not be reached.
+   * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < aiApplications_.size(); i++) { + output.writeMessage(1, aiApplications_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + for (int i = 0; i < unreachable_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, unreachable_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < aiApplications_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, aiApplications_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + { + int dataSize = 0; + for (int i = 0; i < unreachable_.size(); i++) { + dataSize += computeStringSizeNoTag(unreachable_.getRaw(i)); + } + size += dataSize; + size += 1 * getUnreachableList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListAiApplicationsResponse)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse other = + (com.google.cloud.agentregistry.v1.ListAiApplicationsResponse) obj; + + if (!getAiApplicationsList().equals(other.getAiApplicationsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getAiApplicationsCount() > 0) { + hash = (37 * hash) + AI_APPLICATIONS_FIELD_NUMBER; + hash = (53 * hash) + getAiApplicationsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (getUnreachableCount() > 0) { + hash = (37 * hash) + UNREACHABLE_FIELD_NUMBER; + hash = (53 * hash) + getUnreachableList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for response to listing AiApplications.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListAiApplicationsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListAiApplicationsResponse) + com.google.cloud.agentregistry.v1.ListAiApplicationsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse.class, + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ListAiApplicationsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (aiApplicationsBuilder_ == null) { + aiApplications_ = java.util.Collections.emptyList(); + } else { + aiApplications_ = null; + aiApplicationsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListAiApplicationsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationsResponse + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListAiApplicationsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationsResponse build() { + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationsResponse buildPartial() { + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse result = + new com.google.cloud.agentregistry.v1.ListAiApplicationsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse result) { + if (aiApplicationsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + aiApplications_ = java.util.Collections.unmodifiableList(aiApplications_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.aiApplications_ = aiApplications_; + } else { + result.aiApplications_ = aiApplicationsBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.ListAiApplicationsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + unreachable_.makeImmutable(); + result.unreachable_ = unreachable_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListAiApplicationsResponse) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListAiApplicationsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ListAiApplicationsResponse other) { + if (other + == com.google.cloud.agentregistry.v1.ListAiApplicationsResponse.getDefaultInstance()) + return this; + if (aiApplicationsBuilder_ == null) { + if (!other.aiApplications_.isEmpty()) { + if (aiApplications_.isEmpty()) { + aiApplications_ = other.aiApplications_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureAiApplicationsIsMutable(); + aiApplications_.addAll(other.aiApplications_); + } + onChanged(); + } + } else { + if (!other.aiApplications_.isEmpty()) { + if (aiApplicationsBuilder_.isEmpty()) { + aiApplicationsBuilder_.dispose(); + aiApplicationsBuilder_ = null; + aiApplications_ = other.aiApplications_; + bitField0_ = (bitField0_ & ~0x00000001); + aiApplicationsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetAiApplicationsFieldBuilder() + : null; + } else { + aiApplicationsBuilder_.addAllMessages(other.aiApplications_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.unreachable_.isEmpty()) { + if (unreachable_.isEmpty()) { + unreachable_ = other.unreachable_; + bitField0_ |= 0x00000004; + } else { + ensureUnreachableIsMutable(); + unreachable_.addAll(other.unreachable_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.agentregistry.v1.AiApplication m = + input.readMessage( + com.google.cloud.agentregistry.v1.AiApplication.parser(), + extensionRegistry); + if (aiApplicationsBuilder_ == null) { + ensureAiApplicationsIsMutable(); + aiApplications_.add(m); + } else { + aiApplicationsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List aiApplications_ = + java.util.Collections.emptyList(); + + private void ensureAiApplicationsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + aiApplications_ = + new java.util.ArrayList( + aiApplications_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.AiApplication, + com.google.cloud.agentregistry.v1.AiApplication.Builder, + com.google.cloud.agentregistry.v1.AiApplicationOrBuilder> + aiApplicationsBuilder_; + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public java.util.List getAiApplicationsList() { + if (aiApplicationsBuilder_ == null) { + return java.util.Collections.unmodifiableList(aiApplications_); + } else { + return aiApplicationsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public int getAiApplicationsCount() { + if (aiApplicationsBuilder_ == null) { + return aiApplications_.size(); + } else { + return aiApplicationsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public com.google.cloud.agentregistry.v1.AiApplication getAiApplications(int index) { + if (aiApplicationsBuilder_ == null) { + return aiApplications_.get(index); + } else { + return aiApplicationsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public Builder setAiApplications( + int index, com.google.cloud.agentregistry.v1.AiApplication value) { + if (aiApplicationsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAiApplicationsIsMutable(); + aiApplications_.set(index, value); + onChanged(); + } else { + aiApplicationsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public Builder setAiApplications( + int index, com.google.cloud.agentregistry.v1.AiApplication.Builder builderForValue) { + if (aiApplicationsBuilder_ == null) { + ensureAiApplicationsIsMutable(); + aiApplications_.set(index, builderForValue.build()); + onChanged(); + } else { + aiApplicationsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public Builder addAiApplications(com.google.cloud.agentregistry.v1.AiApplication value) { + if (aiApplicationsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAiApplicationsIsMutable(); + aiApplications_.add(value); + onChanged(); + } else { + aiApplicationsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public Builder addAiApplications( + int index, com.google.cloud.agentregistry.v1.AiApplication value) { + if (aiApplicationsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAiApplicationsIsMutable(); + aiApplications_.add(index, value); + onChanged(); + } else { + aiApplicationsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public Builder addAiApplications( + com.google.cloud.agentregistry.v1.AiApplication.Builder builderForValue) { + if (aiApplicationsBuilder_ == null) { + ensureAiApplicationsIsMutable(); + aiApplications_.add(builderForValue.build()); + onChanged(); + } else { + aiApplicationsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public Builder addAiApplications( + int index, com.google.cloud.agentregistry.v1.AiApplication.Builder builderForValue) { + if (aiApplicationsBuilder_ == null) { + ensureAiApplicationsIsMutable(); + aiApplications_.add(index, builderForValue.build()); + onChanged(); + } else { + aiApplicationsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public Builder addAllAiApplications( + java.lang.Iterable values) { + if (aiApplicationsBuilder_ == null) { + ensureAiApplicationsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, aiApplications_); + onChanged(); + } else { + aiApplicationsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public Builder clearAiApplications() { + if (aiApplicationsBuilder_ == null) { + aiApplications_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + aiApplicationsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public Builder removeAiApplications(int index) { + if (aiApplicationsBuilder_ == null) { + ensureAiApplicationsIsMutable(); + aiApplications_.remove(index); + onChanged(); + } else { + aiApplicationsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public com.google.cloud.agentregistry.v1.AiApplication.Builder getAiApplicationsBuilder( + int index) { + return internalGetAiApplicationsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public com.google.cloud.agentregistry.v1.AiApplicationOrBuilder getAiApplicationsOrBuilder( + int index) { + if (aiApplicationsBuilder_ == null) { + return aiApplications_.get(index); + } else { + return aiApplicationsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public java.util.List + getAiApplicationsOrBuilderList() { + if (aiApplicationsBuilder_ != null) { + return aiApplicationsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(aiApplications_); + } + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public com.google.cloud.agentregistry.v1.AiApplication.Builder addAiApplicationsBuilder() { + return internalGetAiApplicationsFieldBuilder() + .addBuilder(com.google.cloud.agentregistry.v1.AiApplication.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public com.google.cloud.agentregistry.v1.AiApplication.Builder addAiApplicationsBuilder( + int index) { + return internalGetAiApplicationsFieldBuilder() + .addBuilder(index, com.google.cloud.agentregistry.v1.AiApplication.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of AiApplications.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + public java.util.List + getAiApplicationsBuilderList() { + return internalGetAiApplicationsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.AiApplication, + com.google.cloud.agentregistry.v1.AiApplication.Builder, + com.google.cloud.agentregistry.v1.AiApplicationOrBuilder> + internalGetAiApplicationsFieldBuilder() { + if (aiApplicationsBuilder_ == null) { + aiApplicationsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.AiApplication, + com.google.cloud.agentregistry.v1.AiApplication.Builder, + com.google.cloud.agentregistry.v1.AiApplicationOrBuilder>( + aiApplications_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + aiApplications_ = null; + } + return aiApplicationsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList unreachable_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureUnreachableIsMutable() { + if (!unreachable_.isModifiable()) { + unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); + } + bitField0_ |= 0x00000004; + } + + /** + * + * + *
+     * Unordered list. Locations that could not be reached.
+     * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + unreachable_.makeImmutable(); + return unreachable_; + } + + /** + * + * + *
+     * Unordered list. Locations that could not be reached.
+     * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + + /** + * + * + *
+     * Unordered list. Locations that could not be reached.
+     * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + + /** + * + * + *
+     * Unordered list. Locations that could not be reached.
+     * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + /** + * + * + *
+     * Unordered list. Locations that could not be reached.
+     * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index to set the value at. + * @param value The unreachable to set. + * @return This builder for chaining. + */ + public Builder setUnreachable(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.set(index, value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Unordered list. Locations that could not be reached.
+     * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param value The unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Unordered list. Locations that could not be reached.
+     * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param values The unreachable to add. + * @return This builder for chaining. + */ + public Builder addAllUnreachable(java.lang.Iterable values) { + ensureUnreachableIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Unordered list. Locations that could not be reached.
+     * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return This builder for chaining. + */ + public Builder clearUnreachable() { + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * Unordered list. Locations that could not be reached.
+     * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param value The bytes of the unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUnreachableIsMutable(); + unreachable_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListAiApplicationsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListAiApplicationsResponse) + private static final com.google.cloud.agentregistry.v1.ListAiApplicationsResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListAiApplicationsResponse(); + } + + public static com.google.cloud.agentregistry.v1.ListAiApplicationsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAiApplicationsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListAiApplicationsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsResponseOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsResponseOrBuilder.java new file mode 100644 index 000000000000..5f7cd72d853a --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListAiApplicationsResponseOrBuilder.java @@ -0,0 +1,164 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListAiApplicationsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListAiApplicationsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of AiApplications.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + java.util.List getAiApplicationsList(); + + /** + * + * + *
+   * The list of AiApplications.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + com.google.cloud.agentregistry.v1.AiApplication getAiApplications(int index); + + /** + * + * + *
+   * The list of AiApplications.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + int getAiApplicationsCount(); + + /** + * + * + *
+   * The list of AiApplications.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + java.util.List + getAiApplicationsOrBuilderList(); + + /** + * + * + *
+   * The list of AiApplications.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.AiApplication ai_applications = 1; + */ + com.google.cloud.agentregistry.v1.AiApplicationOrBuilder getAiApplicationsOrBuilder(int index); + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); + + /** + * + * + *
+   * Unordered list. Locations that could not be reached.
+   * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return A list containing the unreachable. + */ + java.util.List getUnreachableList(); + + /** + * + * + *
+   * Unordered list. Locations that could not be reached.
+   * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return The count of unreachable. + */ + int getUnreachableCount(); + + /** + * + * + *
+   * Unordered list. Locations that could not be reached.
+   * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + java.lang.String getUnreachable(int index); + + /** + * + * + *
+   * Unordered list. Locations that could not be reached.
+   * 
+ * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + com.google.protobuf.ByteString getUnreachableBytes(int index); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsRequest.java new file mode 100644 index 000000000000..9298a1ac907e --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsRequest.java @@ -0,0 +1,1286 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for requesting list of Findings.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListFindingsRequest} + */ +@com.google.protobuf.Generated +public final class ListFindingsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListFindingsRequest) + ListFindingsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListFindingsRequest"); + } + + // Use ListFindingsRequest.newBuilder() to construct. + private ListFindingsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListFindingsRequest() { + parent_ = ""; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListFindingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListFindingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListFindingsRequest.class, + com.google.cloud.agentregistry.v1.ListFindingsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. Parent value for ListFindingsRequest. Format:
+   * `projects/{project}/locations/{location}`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Parent value for ListFindingsRequest. Format:
+   * `projects/{project}/locations/{location}`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object filter_ = ""; + + /** + * + * + *
+   * Optional. Filtering results
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Filtering results
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ORDER_BY_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object orderBy_ = ""; + + /** + * + * + *
+   * Optional. Hint for how to order the results
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + @java.lang.Override + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Hint for how to order the results
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + @java.lang.Override + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, filter_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, orderBy_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, filter_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, orderBy_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListFindingsRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListFindingsRequest other = + (com.google.cloud.agentregistry.v1.ListFindingsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (37 * hash) + ORDER_BY_FIELD_NUMBER; + hash = (53 * hash) + getOrderBy().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListFindingsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for requesting list of Findings.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListFindingsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListFindingsRequest) + com.google.cloud.agentregistry.v1.ListFindingsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListFindingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListFindingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListFindingsRequest.class, + com.google.cloud.agentregistry.v1.ListFindingsRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ListFindingsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListFindingsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListFindingsRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListFindingsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListFindingsRequest build() { + com.google.cloud.agentregistry.v1.ListFindingsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListFindingsRequest buildPartial() { + com.google.cloud.agentregistry.v1.ListFindingsRequest result = + new com.google.cloud.agentregistry.v1.ListFindingsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.ListFindingsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.filter_ = filter_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.orderBy_ = orderBy_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListFindingsRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListFindingsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ListFindingsRequest other) { + if (other == com.google.cloud.agentregistry.v1.ListFindingsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (!other.getOrderBy().isEmpty()) { + orderBy_ = other.orderBy_; + bitField0_ |= 0x00000010; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + filter_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + orderBy_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. Parent value for ListFindingsRequest. Format:
+     * `projects/{project}/locations/{location}`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Parent value for ListFindingsRequest. Format:
+     * `projects/{project}/locations/{location}`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Parent value for ListFindingsRequest. Format:
+     * `projects/{project}/locations/{location}`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value for ListFindingsRequest. Format:
+     * `projects/{project}/locations/{location}`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value for ListFindingsRequest. Format:
+     * `projects/{project}/locations/{location}`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + + /** + * + * + *
+     * Optional. Filtering results
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Filtering results
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Filtering results
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Filtering results
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + filter_ = getDefaultInstance().getFilter(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Filtering results
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private java.lang.Object orderBy_ = ""; + + /** + * + * + *
+     * Optional. Hint for how to order the results
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Hint for how to order the results
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Hint for how to order the results
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderBy(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + orderBy_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Hint for how to order the results
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearOrderBy() { + orderBy_ = getDefaultInstance().getOrderBy(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Hint for how to order the results
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + orderBy_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListFindingsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListFindingsRequest) + private static final com.google.cloud.agentregistry.v1.ListFindingsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListFindingsRequest(); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListFindingsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListFindingsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsRequestOrBuilder.java new file mode 100644 index 000000000000..23fb88da0959 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsRequestOrBuilder.java @@ -0,0 +1,152 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListFindingsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListFindingsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Parent value for ListFindingsRequest. Format:
+   * `projects/{project}/locations/{location}`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. Parent value for ListFindingsRequest. Format:
+   * `projects/{project}/locations/{location}`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
+   * Optional. Filtering results
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
+   * Optional. Filtering results
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
+   * Optional. Hint for how to order the results
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + + /** + * + * + *
+   * Optional. Hint for how to order the results
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsResponse.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsResponse.java new file mode 100644 index 000000000000..97a54cbb1a33 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsResponse.java @@ -0,0 +1,1112 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for response to listing Findings.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListFindingsResponse} + */ +@com.google.protobuf.Generated +public final class ListFindingsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListFindingsResponse) + ListFindingsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListFindingsResponse"); + } + + // Use ListFindingsResponse.newBuilder() to construct. + private ListFindingsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListFindingsResponse() { + findings_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListFindingsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListFindingsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListFindingsResponse.class, + com.google.cloud.agentregistry.v1.ListFindingsResponse.Builder.class); + } + + public static final int FINDINGS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List findings_; + + /** + * + * + *
+   * The list of Findings.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + @java.lang.Override + public java.util.List getFindingsList() { + return findings_; + } + + /** + * + * + *
+   * The list of Findings.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + @java.lang.Override + public java.util.List + getFindingsOrBuilderList() { + return findings_; + } + + /** + * + * + *
+   * The list of Findings.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + @java.lang.Override + public int getFindingsCount() { + return findings_.size(); + } + + /** + * + * + *
+   * The list of Findings.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Finding getFindings(int index) { + return findings_.get(index); + } + + /** + * + * + *
+   * The list of Findings.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.FindingOrBuilder getFindingsOrBuilder(int index) { + return findings_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < findings_.size(); i++) { + output.writeMessage(1, findings_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < findings_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, findings_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListFindingsResponse)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListFindingsResponse other = + (com.google.cloud.agentregistry.v1.ListFindingsResponse) obj; + + if (!getFindingsList().equals(other.getFindingsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getFindingsCount() > 0) { + hash = (37 * hash) + FINDINGS_FIELD_NUMBER; + hash = (53 * hash) + getFindingsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListFindingsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for response to listing Findings.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListFindingsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListFindingsResponse) + com.google.cloud.agentregistry.v1.ListFindingsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListFindingsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListFindingsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListFindingsResponse.class, + com.google.cloud.agentregistry.v1.ListFindingsResponse.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ListFindingsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (findingsBuilder_ == null) { + findings_ = java.util.Collections.emptyList(); + } else { + findings_ = null; + findingsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListFindingsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListFindingsResponse getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListFindingsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListFindingsResponse build() { + com.google.cloud.agentregistry.v1.ListFindingsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListFindingsResponse buildPartial() { + com.google.cloud.agentregistry.v1.ListFindingsResponse result = + new com.google.cloud.agentregistry.v1.ListFindingsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.agentregistry.v1.ListFindingsResponse result) { + if (findingsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + findings_ = java.util.Collections.unmodifiableList(findings_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.findings_ = findings_; + } else { + result.findings_ = findingsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.ListFindingsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListFindingsResponse) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListFindingsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ListFindingsResponse other) { + if (other == com.google.cloud.agentregistry.v1.ListFindingsResponse.getDefaultInstance()) + return this; + if (findingsBuilder_ == null) { + if (!other.findings_.isEmpty()) { + if (findings_.isEmpty()) { + findings_ = other.findings_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureFindingsIsMutable(); + findings_.addAll(other.findings_); + } + onChanged(); + } + } else { + if (!other.findings_.isEmpty()) { + if (findingsBuilder_.isEmpty()) { + findingsBuilder_.dispose(); + findingsBuilder_ = null; + findings_ = other.findings_; + bitField0_ = (bitField0_ & ~0x00000001); + findingsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetFindingsFieldBuilder() + : null; + } else { + findingsBuilder_.addAllMessages(other.findings_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.agentregistry.v1.Finding m = + input.readMessage( + com.google.cloud.agentregistry.v1.Finding.parser(), extensionRegistry); + if (findingsBuilder_ == null) { + ensureFindingsIsMutable(); + findings_.add(m); + } else { + findingsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List findings_ = + java.util.Collections.emptyList(); + + private void ensureFindingsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + findings_ = new java.util.ArrayList(findings_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Finding, + com.google.cloud.agentregistry.v1.Finding.Builder, + com.google.cloud.agentregistry.v1.FindingOrBuilder> + findingsBuilder_; + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public java.util.List getFindingsList() { + if (findingsBuilder_ == null) { + return java.util.Collections.unmodifiableList(findings_); + } else { + return findingsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public int getFindingsCount() { + if (findingsBuilder_ == null) { + return findings_.size(); + } else { + return findingsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public com.google.cloud.agentregistry.v1.Finding getFindings(int index) { + if (findingsBuilder_ == null) { + return findings_.get(index); + } else { + return findingsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public Builder setFindings(int index, com.google.cloud.agentregistry.v1.Finding value) { + if (findingsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFindingsIsMutable(); + findings_.set(index, value); + onChanged(); + } else { + findingsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public Builder setFindings( + int index, com.google.cloud.agentregistry.v1.Finding.Builder builderForValue) { + if (findingsBuilder_ == null) { + ensureFindingsIsMutable(); + findings_.set(index, builderForValue.build()); + onChanged(); + } else { + findingsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public Builder addFindings(com.google.cloud.agentregistry.v1.Finding value) { + if (findingsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFindingsIsMutable(); + findings_.add(value); + onChanged(); + } else { + findingsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public Builder addFindings(int index, com.google.cloud.agentregistry.v1.Finding value) { + if (findingsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFindingsIsMutable(); + findings_.add(index, value); + onChanged(); + } else { + findingsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public Builder addFindings(com.google.cloud.agentregistry.v1.Finding.Builder builderForValue) { + if (findingsBuilder_ == null) { + ensureFindingsIsMutable(); + findings_.add(builderForValue.build()); + onChanged(); + } else { + findingsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public Builder addFindings( + int index, com.google.cloud.agentregistry.v1.Finding.Builder builderForValue) { + if (findingsBuilder_ == null) { + ensureFindingsIsMutable(); + findings_.add(index, builderForValue.build()); + onChanged(); + } else { + findingsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public Builder addAllFindings( + java.lang.Iterable values) { + if (findingsBuilder_ == null) { + ensureFindingsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, findings_); + onChanged(); + } else { + findingsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public Builder clearFindings() { + if (findingsBuilder_ == null) { + findings_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + findingsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public Builder removeFindings(int index) { + if (findingsBuilder_ == null) { + ensureFindingsIsMutable(); + findings_.remove(index); + onChanged(); + } else { + findingsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public com.google.cloud.agentregistry.v1.Finding.Builder getFindingsBuilder(int index) { + return internalGetFindingsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public com.google.cloud.agentregistry.v1.FindingOrBuilder getFindingsOrBuilder(int index) { + if (findingsBuilder_ == null) { + return findings_.get(index); + } else { + return findingsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public java.util.List + getFindingsOrBuilderList() { + if (findingsBuilder_ != null) { + return findingsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(findings_); + } + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public com.google.cloud.agentregistry.v1.Finding.Builder addFindingsBuilder() { + return internalGetFindingsFieldBuilder() + .addBuilder(com.google.cloud.agentregistry.v1.Finding.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public com.google.cloud.agentregistry.v1.Finding.Builder addFindingsBuilder(int index) { + return internalGetFindingsFieldBuilder() + .addBuilder(index, com.google.cloud.agentregistry.v1.Finding.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of Findings.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + public java.util.List + getFindingsBuilderList() { + return internalGetFindingsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Finding, + com.google.cloud.agentregistry.v1.Finding.Builder, + com.google.cloud.agentregistry.v1.FindingOrBuilder> + internalGetFindingsFieldBuilder() { + if (findingsBuilder_ == null) { + findingsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Finding, + com.google.cloud.agentregistry.v1.Finding.Builder, + com.google.cloud.agentregistry.v1.FindingOrBuilder>( + findings_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + findings_ = null; + } + return findingsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * A token identifying a page of results the server should return.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListFindingsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListFindingsResponse) + private static final com.google.cloud.agentregistry.v1.ListFindingsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListFindingsResponse(); + } + + public static com.google.cloud.agentregistry.v1.ListFindingsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListFindingsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListFindingsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsResponseOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsResponseOrBuilder.java new file mode 100644 index 000000000000..6a8548e513dc --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListFindingsResponseOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListFindingsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListFindingsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of Findings.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + java.util.List getFindingsList(); + + /** + * + * + *
+   * The list of Findings.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + com.google.cloud.agentregistry.v1.Finding getFindings(int index); + + /** + * + * + *
+   * The list of Findings.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + int getFindingsCount(); + + /** + * + * + *
+   * The list of Findings.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + java.util.List + getFindingsOrBuilderList(); + + /** + * + * + *
+   * The list of Findings.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Finding findings = 1; + */ + com.google.cloud.agentregistry.v1.FindingOrBuilder getFindingsOrBuilder(int index); + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * A token identifying a page of results the server should return.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersRequest.java new file mode 100644 index 000000000000..e6cd189dcb38 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersRequest.java @@ -0,0 +1,904 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Requesting a list of Publishers.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListPublishersRequest} + */ +@com.google.protobuf.Generated +public final class ListPublishersRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListPublishersRequest) + ListPublishersRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListPublishersRequest"); + } + + // Use ListPublishersRequest.newBuilder() to construct. + private ListPublishersRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListPublishersRequest() { + parent_ = ""; + pageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListPublishersRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListPublishersRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListPublishersRequest.class, + com.google.cloud.agentregistry.v1.ListPublishersRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. Parent location to query.
+   * Format: `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Parent location to query.
+   * Format: `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. Page limit size.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. Page offset token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Page offset token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListPublishersRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListPublishersRequest other = + (com.google.cloud.agentregistry.v1.ListPublishersRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListPublishersRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Requesting a list of Publishers.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListPublishersRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListPublishersRequest) + com.google.cloud.agentregistry.v1.ListPublishersRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListPublishersRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListPublishersRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListPublishersRequest.class, + com.google.cloud.agentregistry.v1.ListPublishersRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ListPublishersRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListPublishersRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListPublishersRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListPublishersRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListPublishersRequest build() { + com.google.cloud.agentregistry.v1.ListPublishersRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListPublishersRequest buildPartial() { + com.google.cloud.agentregistry.v1.ListPublishersRequest result = + new com.google.cloud.agentregistry.v1.ListPublishersRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.ListPublishersRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListPublishersRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListPublishersRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ListPublishersRequest other) { + if (other == com.google.cloud.agentregistry.v1.ListPublishersRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. Parent location to query.
+     * Format: `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Parent location to query.
+     * Format: `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Parent location to query.
+     * Format: `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent location to query.
+     * Format: `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent location to query.
+     * Format: `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. Page limit size.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. Page limit size.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Page limit size.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. Page offset token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Page offset token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Page offset token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Page offset token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Page offset token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListPublishersRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListPublishersRequest) + private static final com.google.cloud.agentregistry.v1.ListPublishersRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListPublishersRequest(); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListPublishersRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListPublishersRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersRequestOrBuilder.java new file mode 100644 index 000000000000..0997c715bcd7 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersRequestOrBuilder.java @@ -0,0 +1,99 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListPublishersRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListPublishersRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Parent location to query.
+   * Format: `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. Parent location to query.
+   * Format: `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. Page limit size.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. Page offset token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. Page offset token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersResponse.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersResponse.java new file mode 100644 index 000000000000..a5a51bec44c3 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersResponse.java @@ -0,0 +1,1114 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Response listing Publishers.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListPublishersResponse} + */ +@com.google.protobuf.Generated +public final class ListPublishersResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListPublishersResponse) + ListPublishersResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListPublishersResponse"); + } + + // Use ListPublishersResponse.newBuilder() to construct. + private ListPublishersResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListPublishersResponse() { + publishers_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListPublishersResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListPublishersResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListPublishersResponse.class, + com.google.cloud.agentregistry.v1.ListPublishersResponse.Builder.class); + } + + public static final int PUBLISHERS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List publishers_; + + /** + * + * + *
+   * The returned list of Publishers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + @java.lang.Override + public java.util.List getPublishersList() { + return publishers_; + } + + /** + * + * + *
+   * The returned list of Publishers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + @java.lang.Override + public java.util.List + getPublishersOrBuilderList() { + return publishers_; + } + + /** + * + * + *
+   * The returned list of Publishers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + @java.lang.Override + public int getPublishersCount() { + return publishers_.size(); + } + + /** + * + * + *
+   * The returned list of Publishers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Publisher getPublishers(int index) { + return publishers_.get(index); + } + + /** + * + * + *
+   * The returned list of Publishers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.PublisherOrBuilder getPublishersOrBuilder(int index) { + return publishers_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * Page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < publishers_.size(); i++) { + output.writeMessage(1, publishers_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < publishers_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, publishers_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListPublishersResponse)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListPublishersResponse other = + (com.google.cloud.agentregistry.v1.ListPublishersResponse) obj; + + if (!getPublishersList().equals(other.getPublishersList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getPublishersCount() > 0) { + hash = (37 * hash) + PUBLISHERS_FIELD_NUMBER; + hash = (53 * hash) + getPublishersList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListPublishersResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Response listing Publishers.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListPublishersResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListPublishersResponse) + com.google.cloud.agentregistry.v1.ListPublishersResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListPublishersResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListPublishersResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListPublishersResponse.class, + com.google.cloud.agentregistry.v1.ListPublishersResponse.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ListPublishersResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (publishersBuilder_ == null) { + publishers_ = java.util.Collections.emptyList(); + } else { + publishers_ = null; + publishersBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListPublishersResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListPublishersResponse getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListPublishersResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListPublishersResponse build() { + com.google.cloud.agentregistry.v1.ListPublishersResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListPublishersResponse buildPartial() { + com.google.cloud.agentregistry.v1.ListPublishersResponse result = + new com.google.cloud.agentregistry.v1.ListPublishersResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.agentregistry.v1.ListPublishersResponse result) { + if (publishersBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + publishers_ = java.util.Collections.unmodifiableList(publishers_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.publishers_ = publishers_; + } else { + result.publishers_ = publishersBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.ListPublishersResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListPublishersResponse) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListPublishersResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ListPublishersResponse other) { + if (other == com.google.cloud.agentregistry.v1.ListPublishersResponse.getDefaultInstance()) + return this; + if (publishersBuilder_ == null) { + if (!other.publishers_.isEmpty()) { + if (publishers_.isEmpty()) { + publishers_ = other.publishers_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensurePublishersIsMutable(); + publishers_.addAll(other.publishers_); + } + onChanged(); + } + } else { + if (!other.publishers_.isEmpty()) { + if (publishersBuilder_.isEmpty()) { + publishersBuilder_.dispose(); + publishersBuilder_ = null; + publishers_ = other.publishers_; + bitField0_ = (bitField0_ & ~0x00000001); + publishersBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetPublishersFieldBuilder() + : null; + } else { + publishersBuilder_.addAllMessages(other.publishers_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.agentregistry.v1.Publisher m = + input.readMessage( + com.google.cloud.agentregistry.v1.Publisher.parser(), extensionRegistry); + if (publishersBuilder_ == null) { + ensurePublishersIsMutable(); + publishers_.add(m); + } else { + publishersBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List publishers_ = + java.util.Collections.emptyList(); + + private void ensurePublishersIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + publishers_ = + new java.util.ArrayList(publishers_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Publisher, + com.google.cloud.agentregistry.v1.Publisher.Builder, + com.google.cloud.agentregistry.v1.PublisherOrBuilder> + publishersBuilder_; + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public java.util.List getPublishersList() { + if (publishersBuilder_ == null) { + return java.util.Collections.unmodifiableList(publishers_); + } else { + return publishersBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public int getPublishersCount() { + if (publishersBuilder_ == null) { + return publishers_.size(); + } else { + return publishersBuilder_.getCount(); + } + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public com.google.cloud.agentregistry.v1.Publisher getPublishers(int index) { + if (publishersBuilder_ == null) { + return publishers_.get(index); + } else { + return publishersBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public Builder setPublishers(int index, com.google.cloud.agentregistry.v1.Publisher value) { + if (publishersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensurePublishersIsMutable(); + publishers_.set(index, value); + onChanged(); + } else { + publishersBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public Builder setPublishers( + int index, com.google.cloud.agentregistry.v1.Publisher.Builder builderForValue) { + if (publishersBuilder_ == null) { + ensurePublishersIsMutable(); + publishers_.set(index, builderForValue.build()); + onChanged(); + } else { + publishersBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public Builder addPublishers(com.google.cloud.agentregistry.v1.Publisher value) { + if (publishersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensurePublishersIsMutable(); + publishers_.add(value); + onChanged(); + } else { + publishersBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public Builder addPublishers(int index, com.google.cloud.agentregistry.v1.Publisher value) { + if (publishersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensurePublishersIsMutable(); + publishers_.add(index, value); + onChanged(); + } else { + publishersBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public Builder addPublishers( + com.google.cloud.agentregistry.v1.Publisher.Builder builderForValue) { + if (publishersBuilder_ == null) { + ensurePublishersIsMutable(); + publishers_.add(builderForValue.build()); + onChanged(); + } else { + publishersBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public Builder addPublishers( + int index, com.google.cloud.agentregistry.v1.Publisher.Builder builderForValue) { + if (publishersBuilder_ == null) { + ensurePublishersIsMutable(); + publishers_.add(index, builderForValue.build()); + onChanged(); + } else { + publishersBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public Builder addAllPublishers( + java.lang.Iterable values) { + if (publishersBuilder_ == null) { + ensurePublishersIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, publishers_); + onChanged(); + } else { + publishersBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public Builder clearPublishers() { + if (publishersBuilder_ == null) { + publishers_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + publishersBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public Builder removePublishers(int index) { + if (publishersBuilder_ == null) { + ensurePublishersIsMutable(); + publishers_.remove(index); + onChanged(); + } else { + publishersBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public com.google.cloud.agentregistry.v1.Publisher.Builder getPublishersBuilder(int index) { + return internalGetPublishersFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public com.google.cloud.agentregistry.v1.PublisherOrBuilder getPublishersOrBuilder(int index) { + if (publishersBuilder_ == null) { + return publishers_.get(index); + } else { + return publishersBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public java.util.List + getPublishersOrBuilderList() { + if (publishersBuilder_ != null) { + return publishersBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(publishers_); + } + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public com.google.cloud.agentregistry.v1.Publisher.Builder addPublishersBuilder() { + return internalGetPublishersFieldBuilder() + .addBuilder(com.google.cloud.agentregistry.v1.Publisher.getDefaultInstance()); + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public com.google.cloud.agentregistry.v1.Publisher.Builder addPublishersBuilder(int index) { + return internalGetPublishersFieldBuilder() + .addBuilder(index, com.google.cloud.agentregistry.v1.Publisher.getDefaultInstance()); + } + + /** + * + * + *
+     * The returned list of Publishers.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + public java.util.List + getPublishersBuilderList() { + return internalGetPublishersFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Publisher, + com.google.cloud.agentregistry.v1.Publisher.Builder, + com.google.cloud.agentregistry.v1.PublisherOrBuilder> + internalGetPublishersFieldBuilder() { + if (publishersBuilder_ == null) { + publishersBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Publisher, + com.google.cloud.agentregistry.v1.Publisher.Builder, + com.google.cloud.agentregistry.v1.PublisherOrBuilder>( + publishers_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + publishers_ = null; + } + return publishersBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * Page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListPublishersResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListPublishersResponse) + private static final com.google.cloud.agentregistry.v1.ListPublishersResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListPublishersResponse(); + } + + public static com.google.cloud.agentregistry.v1.ListPublishersResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListPublishersResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListPublishersResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersResponseOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersResponseOrBuilder.java new file mode 100644 index 000000000000..15250ddef57a --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListPublishersResponseOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListPublishersResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListPublishersResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The returned list of Publishers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + java.util.List getPublishersList(); + + /** + * + * + *
+   * The returned list of Publishers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + com.google.cloud.agentregistry.v1.Publisher getPublishers(int index); + + /** + * + * + *
+   * The returned list of Publishers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + int getPublishersCount(); + + /** + * + * + *
+   * The returned list of Publishers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + java.util.List + getPublishersOrBuilderList(); + + /** + * + * + *
+   * The returned list of Publishers.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Publisher publishers = 1; + */ + com.google.cloud.agentregistry.v1.PublisherOrBuilder getPublishersOrBuilder(int index); + + /** + * + * + *
+   * Page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * Page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsRequest.java new file mode 100644 index 000000000000..74d94853ec45 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsRequest.java @@ -0,0 +1,897 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Requesting a list of Revisions under a Skill.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListSkillRevisionsRequest} + */ +@com.google.protobuf.Generated +public final class ListSkillRevisionsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListSkillRevisionsRequest) + ListSkillRevisionsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListSkillRevisionsRequest"); + } + + // Use ListSkillRevisionsRequest.newBuilder() to construct. + private ListSkillRevisionsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListSkillRevisionsRequest() { + parent_ = ""; + pageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest.class, + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. Parent logical container name to query.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Parent logical container name to query.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. Page limit size.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. Page offset token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Page offset token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest other = + (com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Requesting a list of Revisions under a Skill.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListSkillRevisionsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListSkillRevisionsRequest) + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest.class, + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest build() { + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest buildPartial() { + com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest result = + new com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest other) { + if (other == com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. Parent logical container name to query.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Parent logical container name to query.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Parent logical container name to query.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent logical container name to query.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent logical container name to query.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. Page limit size.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. Page limit size.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Page limit size.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. Page offset token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Page offset token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Page offset token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Page offset token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Page offset token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListSkillRevisionsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListSkillRevisionsRequest) + private static final com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest(); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListSkillRevisionsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsRequestOrBuilder.java new file mode 100644 index 000000000000..b717c044dd0c --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsRequestOrBuilder.java @@ -0,0 +1,97 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListSkillRevisionsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListSkillRevisionsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Parent logical container name to query.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. Parent logical container name to query.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. Page limit size.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. Page offset token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. Page offset token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsResponse.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsResponse.java new file mode 100644 index 000000000000..c64c0d2bc7f4 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsResponse.java @@ -0,0 +1,1129 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Response listing Revisions.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListSkillRevisionsResponse} + */ +@com.google.protobuf.Generated +public final class ListSkillRevisionsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListSkillRevisionsResponse) + ListSkillRevisionsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListSkillRevisionsResponse"); + } + + // Use ListSkillRevisionsResponse.newBuilder() to construct. + private ListSkillRevisionsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListSkillRevisionsResponse() { + skillRevisions_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse.class, + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse.Builder.class); + } + + public static final int SKILL_REVISIONS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List skillRevisions_; + + /** + * + * + *
+   * Returned version snapshot list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + @java.lang.Override + public java.util.List getSkillRevisionsList() { + return skillRevisions_; + } + + /** + * + * + *
+   * Returned version snapshot list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + @java.lang.Override + public java.util.List + getSkillRevisionsOrBuilderList() { + return skillRevisions_; + } + + /** + * + * + *
+   * Returned version snapshot list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + @java.lang.Override + public int getSkillRevisionsCount() { + return skillRevisions_.size(); + } + + /** + * + * + *
+   * Returned version snapshot list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision getSkillRevisions(int index) { + return skillRevisions_.get(index); + } + + /** + * + * + *
+   * Returned version snapshot list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder getSkillRevisionsOrBuilder( + int index) { + return skillRevisions_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * Page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < skillRevisions_.size(); i++) { + output.writeMessage(1, skillRevisions_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < skillRevisions_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, skillRevisions_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse other = + (com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse) obj; + + if (!getSkillRevisionsList().equals(other.getSkillRevisionsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getSkillRevisionsCount() > 0) { + hash = (37 * hash) + SKILL_REVISIONS_FIELD_NUMBER; + hash = (53 * hash) + getSkillRevisionsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Response listing Revisions.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListSkillRevisionsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListSkillRevisionsResponse) + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse.class, + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (skillRevisionsBuilder_ == null) { + skillRevisions_ = java.util.Collections.emptyList(); + } else { + skillRevisions_ = null; + skillRevisionsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillRevisionsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse build() { + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse buildPartial() { + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse result = + new com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse result) { + if (skillRevisionsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + skillRevisions_ = java.util.Collections.unmodifiableList(skillRevisions_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.skillRevisions_ = skillRevisions_; + } else { + result.skillRevisions_ = skillRevisionsBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse other) { + if (other + == com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse.getDefaultInstance()) + return this; + if (skillRevisionsBuilder_ == null) { + if (!other.skillRevisions_.isEmpty()) { + if (skillRevisions_.isEmpty()) { + skillRevisions_ = other.skillRevisions_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureSkillRevisionsIsMutable(); + skillRevisions_.addAll(other.skillRevisions_); + } + onChanged(); + } + } else { + if (!other.skillRevisions_.isEmpty()) { + if (skillRevisionsBuilder_.isEmpty()) { + skillRevisionsBuilder_.dispose(); + skillRevisionsBuilder_ = null; + skillRevisions_ = other.skillRevisions_; + bitField0_ = (bitField0_ & ~0x00000001); + skillRevisionsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetSkillRevisionsFieldBuilder() + : null; + } else { + skillRevisionsBuilder_.addAllMessages(other.skillRevisions_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.agentregistry.v1.SkillRevision m = + input.readMessage( + com.google.cloud.agentregistry.v1.SkillRevision.parser(), + extensionRegistry); + if (skillRevisionsBuilder_ == null) { + ensureSkillRevisionsIsMutable(); + skillRevisions_.add(m); + } else { + skillRevisionsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List skillRevisions_ = + java.util.Collections.emptyList(); + + private void ensureSkillRevisionsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + skillRevisions_ = + new java.util.ArrayList( + skillRevisions_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision, + com.google.cloud.agentregistry.v1.SkillRevision.Builder, + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder> + skillRevisionsBuilder_; + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public java.util.List getSkillRevisionsList() { + if (skillRevisionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(skillRevisions_); + } else { + return skillRevisionsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public int getSkillRevisionsCount() { + if (skillRevisionsBuilder_ == null) { + return skillRevisions_.size(); + } else { + return skillRevisionsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public com.google.cloud.agentregistry.v1.SkillRevision getSkillRevisions(int index) { + if (skillRevisionsBuilder_ == null) { + return skillRevisions_.get(index); + } else { + return skillRevisionsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public Builder setSkillRevisions( + int index, com.google.cloud.agentregistry.v1.SkillRevision value) { + if (skillRevisionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSkillRevisionsIsMutable(); + skillRevisions_.set(index, value); + onChanged(); + } else { + skillRevisionsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public Builder setSkillRevisions( + int index, com.google.cloud.agentregistry.v1.SkillRevision.Builder builderForValue) { + if (skillRevisionsBuilder_ == null) { + ensureSkillRevisionsIsMutable(); + skillRevisions_.set(index, builderForValue.build()); + onChanged(); + } else { + skillRevisionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public Builder addSkillRevisions(com.google.cloud.agentregistry.v1.SkillRevision value) { + if (skillRevisionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSkillRevisionsIsMutable(); + skillRevisions_.add(value); + onChanged(); + } else { + skillRevisionsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public Builder addSkillRevisions( + int index, com.google.cloud.agentregistry.v1.SkillRevision value) { + if (skillRevisionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSkillRevisionsIsMutable(); + skillRevisions_.add(index, value); + onChanged(); + } else { + skillRevisionsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public Builder addSkillRevisions( + com.google.cloud.agentregistry.v1.SkillRevision.Builder builderForValue) { + if (skillRevisionsBuilder_ == null) { + ensureSkillRevisionsIsMutable(); + skillRevisions_.add(builderForValue.build()); + onChanged(); + } else { + skillRevisionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public Builder addSkillRevisions( + int index, com.google.cloud.agentregistry.v1.SkillRevision.Builder builderForValue) { + if (skillRevisionsBuilder_ == null) { + ensureSkillRevisionsIsMutable(); + skillRevisions_.add(index, builderForValue.build()); + onChanged(); + } else { + skillRevisionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public Builder addAllSkillRevisions( + java.lang.Iterable values) { + if (skillRevisionsBuilder_ == null) { + ensureSkillRevisionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, skillRevisions_); + onChanged(); + } else { + skillRevisionsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public Builder clearSkillRevisions() { + if (skillRevisionsBuilder_ == null) { + skillRevisions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + skillRevisionsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public Builder removeSkillRevisions(int index) { + if (skillRevisionsBuilder_ == null) { + ensureSkillRevisionsIsMutable(); + skillRevisions_.remove(index); + onChanged(); + } else { + skillRevisionsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public com.google.cloud.agentregistry.v1.SkillRevision.Builder getSkillRevisionsBuilder( + int index) { + return internalGetSkillRevisionsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder getSkillRevisionsOrBuilder( + int index) { + if (skillRevisionsBuilder_ == null) { + return skillRevisions_.get(index); + } else { + return skillRevisionsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public java.util.List + getSkillRevisionsOrBuilderList() { + if (skillRevisionsBuilder_ != null) { + return skillRevisionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(skillRevisions_); + } + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public com.google.cloud.agentregistry.v1.SkillRevision.Builder addSkillRevisionsBuilder() { + return internalGetSkillRevisionsFieldBuilder() + .addBuilder(com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance()); + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public com.google.cloud.agentregistry.v1.SkillRevision.Builder addSkillRevisionsBuilder( + int index) { + return internalGetSkillRevisionsFieldBuilder() + .addBuilder(index, com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance()); + } + + /** + * + * + *
+     * Returned version snapshot list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + public java.util.List + getSkillRevisionsBuilderList() { + return internalGetSkillRevisionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision, + com.google.cloud.agentregistry.v1.SkillRevision.Builder, + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder> + internalGetSkillRevisionsFieldBuilder() { + if (skillRevisionsBuilder_ == null) { + skillRevisionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision, + com.google.cloud.agentregistry.v1.SkillRevision.Builder, + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder>( + skillRevisions_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + skillRevisions_ = null; + } + return skillRevisionsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * Page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListSkillRevisionsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListSkillRevisionsResponse) + private static final com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse(); + } + + public static com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListSkillRevisionsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsResponseOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsResponseOrBuilder.java new file mode 100644 index 000000000000..a38a89a337ab --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillRevisionsResponseOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListSkillRevisionsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListSkillRevisionsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Returned version snapshot list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + java.util.List getSkillRevisionsList(); + + /** + * + * + *
+   * Returned version snapshot list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + com.google.cloud.agentregistry.v1.SkillRevision getSkillRevisions(int index); + + /** + * + * + *
+   * Returned version snapshot list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + int getSkillRevisionsCount(); + + /** + * + * + *
+   * Returned version snapshot list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + java.util.List + getSkillRevisionsOrBuilderList(); + + /** + * + * + *
+   * Returned version snapshot list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.SkillRevision skill_revisions = 1; + */ + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder getSkillRevisionsOrBuilder(int index); + + /** + * + * + *
+   * Page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * Page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsRequest.java new file mode 100644 index 000000000000..06a03d758538 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsRequest.java @@ -0,0 +1,1397 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Requesting a list of Skills inside a location.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListSkillsRequest} + */ +@com.google.protobuf.Generated +public final class ListSkillsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListSkillsRequest) + ListSkillsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListSkillsRequest"); + } + + // Use ListSkillsRequest.newBuilder() to construct. + private ListSkillsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListSkillsRequest() { + parent_ = ""; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListSkillsRequest.class, + com.google.cloud.agentregistry.v1.ListSkillsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. Parent value for ListSkillsRequest
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Parent value for ListSkillsRequest
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object filter_ = ""; + + /** + * + * + *
+   * Optional. Use this field to specify filter criteria on list results.
+   * Filter expressions can be used to restrict results based upon filterable
+   * fields, where equality operators can be used. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * | Field        | `=` | `<`, `>` |
+   * |--------------|-----|----------|
+   * | state        | Yes | No       |
+   * | targetState  | Yes | No       |
+   * | createTime   | Yes | Yes      |
+   * | updateTime   | Yes | Yes      |
+   *
+   * Examples:
+   *
+   * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Use this field to specify filter criteria on list results.
+   * Filter expressions can be used to restrict results based upon filterable
+   * fields, where equality operators can be used. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * | Field        | `=` | `<`, `>` |
+   * |--------------|-----|----------|
+   * | state        | Yes | No       |
+   * | targetState  | Yes | No       |
+   * | createTime   | Yes | Yes      |
+   * | updateTime   | Yes | Yes      |
+   *
+   * Examples:
+   *
+   * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ORDER_BY_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object orderBy_ = ""; + + /** + * + * + *
+   * Optional. Hint for how to order the results
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + @java.lang.Override + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Hint for how to order the results
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + @java.lang.Override + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, filter_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, orderBy_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, filter_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, orderBy_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListSkillsRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListSkillsRequest other = + (com.google.cloud.agentregistry.v1.ListSkillsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (37 * hash) + ORDER_BY_FIELD_NUMBER; + hash = (53 * hash) + getOrderBy().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.ListSkillsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Requesting a list of Skills inside a location.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListSkillsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListSkillsRequest) + com.google.cloud.agentregistry.v1.ListSkillsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListSkillsRequest.class, + com.google.cloud.agentregistry.v1.ListSkillsRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ListSkillsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillsRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListSkillsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillsRequest build() { + com.google.cloud.agentregistry.v1.ListSkillsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillsRequest buildPartial() { + com.google.cloud.agentregistry.v1.ListSkillsRequest result = + new com.google.cloud.agentregistry.v1.ListSkillsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.ListSkillsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.filter_ = filter_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.orderBy_ = orderBy_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListSkillsRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListSkillsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ListSkillsRequest other) { + if (other == com.google.cloud.agentregistry.v1.ListSkillsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (!other.getOrderBy().isEmpty()) { + orderBy_ = other.orderBy_; + bitField0_ |= 0x00000010; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + filter_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + orderBy_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. Parent value for ListSkillsRequest
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Parent value for ListSkillsRequest
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Parent value for ListSkillsRequest
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value for ListSkillsRequest
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value for ListSkillsRequest
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Requested page size. Server may return fewer items than
+     * requested. If unspecified, server will pick an appropriate default.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A token identifying a page of results the server should return.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + + /** + * + * + *
+     * Optional. Use this field to specify filter criteria on list results.
+     * Filter expressions can be used to restrict results based upon filterable
+     * fields, where equality operators can be used. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * | Field        | `=` | `<`, `>` |
+     * |--------------|-----|----------|
+     * | state        | Yes | No       |
+     * | targetState  | Yes | No       |
+     * | createTime   | Yes | Yes      |
+     * | updateTime   | Yes | Yes      |
+     *
+     * Examples:
+     *
+     * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Use this field to specify filter criteria on list results.
+     * Filter expressions can be used to restrict results based upon filterable
+     * fields, where equality operators can be used. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * | Field        | `=` | `<`, `>` |
+     * |--------------|-----|----------|
+     * | state        | Yes | No       |
+     * | targetState  | Yes | No       |
+     * | createTime   | Yes | Yes      |
+     * | updateTime   | Yes | Yes      |
+     *
+     * Examples:
+     *
+     * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Use this field to specify filter criteria on list results.
+     * Filter expressions can be used to restrict results based upon filterable
+     * fields, where equality operators can be used. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * | Field        | `=` | `<`, `>` |
+     * |--------------|-----|----------|
+     * | state        | Yes | No       |
+     * | targetState  | Yes | No       |
+     * | createTime   | Yes | Yes      |
+     * | updateTime   | Yes | Yes      |
+     *
+     * Examples:
+     *
+     * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Use this field to specify filter criteria on list results.
+     * Filter expressions can be used to restrict results based upon filterable
+     * fields, where equality operators can be used. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * | Field        | `=` | `<`, `>` |
+     * |--------------|-----|----------|
+     * | state        | Yes | No       |
+     * | targetState  | Yes | No       |
+     * | createTime   | Yes | Yes      |
+     * | updateTime   | Yes | Yes      |
+     *
+     * Examples:
+     *
+     * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + filter_ = getDefaultInstance().getFilter(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Use this field to specify filter criteria on list results.
+     * Filter expressions can be used to restrict results based upon filterable
+     * fields, where equality operators can be used. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * | Field        | `=` | `<`, `>` |
+     * |--------------|-----|----------|
+     * | state        | Yes | No       |
+     * | targetState  | Yes | No       |
+     * | createTime   | Yes | Yes      |
+     * | updateTime   | Yes | Yes      |
+     *
+     * Examples:
+     *
+     * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private java.lang.Object orderBy_ = ""; + + /** + * + * + *
+     * Optional. Hint for how to order the results
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Hint for how to order the results
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Hint for how to order the results
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderBy(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + orderBy_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Hint for how to order the results
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearOrderBy() { + orderBy_ = getDefaultInstance().getOrderBy(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Hint for how to order the results
+     * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + orderBy_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListSkillsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListSkillsRequest) + private static final com.google.cloud.agentregistry.v1.ListSkillsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListSkillsRequest(); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListSkillsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsRequestOrBuilder.java new file mode 100644 index 000000000000..d5565ff2e432 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsRequestOrBuilder.java @@ -0,0 +1,184 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListSkillsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListSkillsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Parent value for ListSkillsRequest
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. Parent value for ListSkillsRequest
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. Requested page size. Server may return fewer items than
+   * requested. If unspecified, server will pick an appropriate default.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. A token identifying a page of results the server should return.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
+   * Optional. Use this field to specify filter criteria on list results.
+   * Filter expressions can be used to restrict results based upon filterable
+   * fields, where equality operators can be used. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * | Field        | `=` | `<`, `>` |
+   * |--------------|-----|----------|
+   * | state        | Yes | No       |
+   * | targetState  | Yes | No       |
+   * | createTime   | Yes | Yes      |
+   * | updateTime   | Yes | Yes      |
+   *
+   * Examples:
+   *
+   * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
+   * Optional. Use this field to specify filter criteria on list results.
+   * Filter expressions can be used to restrict results based upon filterable
+   * fields, where equality operators can be used. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * | Field        | `=` | `<`, `>` |
+   * |--------------|-----|----------|
+   * | state        | Yes | No       |
+   * | targetState  | Yes | No       |
+   * | createTime   | Yes | Yes      |
+   * | updateTime   | Yes | Yes      |
+   *
+   * Examples:
+   *
+   * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
+   * Optional. Hint for how to order the results
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + + /** + * + * + *
+   * Optional. Hint for how to order the results
+   * 
+ * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsResponse.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsResponse.java new file mode 100644 index 000000000000..2d4a22ee7e8b --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsResponse.java @@ -0,0 +1,1400 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Response structure listing logical Skills.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListSkillsResponse} + */ +@com.google.protobuf.Generated +public final class ListSkillsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ListSkillsResponse) + ListSkillsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListSkillsResponse"); + } + + // Use ListSkillsResponse.newBuilder() to construct. + private ListSkillsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListSkillsResponse() { + skills_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListSkillsResponse.class, + com.google.cloud.agentregistry.v1.ListSkillsResponse.Builder.class); + } + + public static final int SKILLS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List skills_; + + /** + * + * + *
+   * Returned container list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + @java.lang.Override + public java.util.List getSkillsList() { + return skills_; + } + + /** + * + * + *
+   * Returned container list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + @java.lang.Override + public java.util.List + getSkillsOrBuilderList() { + return skills_; + } + + /** + * + * + *
+   * Returned container list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + @java.lang.Override + public int getSkillsCount() { + return skills_.size(); + } + + /** + * + * + *
+   * Returned container list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill getSkills(int index) { + return skills_.get(index); + } + + /** + * + * + *
+   * Returned container list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillsOrBuilder(int index) { + return skills_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * Page continuation continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Page continuation continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UNREACHABLE_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList unreachable_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * Unreachable locations or failures.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_; + } + + /** + * + * + *
+   * Unreachable locations or failures.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + + /** + * + * + *
+   * Unreachable locations or failures.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + + /** + * + * + *
+   * Unreachable locations or failures.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < skills_.size(); i++) { + output.writeMessage(1, skills_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + for (int i = 0; i < unreachable_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, unreachable_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < skills_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, skills_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + { + int dataSize = 0; + for (int i = 0; i < unreachable_.size(); i++) { + dataSize += computeStringSizeNoTag(unreachable_.getRaw(i)); + } + size += dataSize; + size += 1 * getUnreachableList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ListSkillsResponse)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ListSkillsResponse other = + (com.google.cloud.agentregistry.v1.ListSkillsResponse) obj; + + if (!getSkillsList().equals(other.getSkillsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getSkillsCount() > 0) { + hash = (37 * hash) + SKILLS_FIELD_NUMBER; + hash = (53 * hash) + getSkillsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (getUnreachableCount() > 0) { + hash = (37 * hash) + UNREACHABLE_FIELD_NUMBER; + hash = (53 * hash) + getUnreachableList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.ListSkillsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Response structure listing logical Skills.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ListSkillsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ListSkillsResponse) + com.google.cloud.agentregistry.v1.ListSkillsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ListSkillsResponse.class, + com.google.cloud.agentregistry.v1.ListSkillsResponse.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ListSkillsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (skillsBuilder_ == null) { + skills_ = java.util.Collections.emptyList(); + } else { + skills_ = null; + skillsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_ListSkillsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillsResponse getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ListSkillsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillsResponse build() { + com.google.cloud.agentregistry.v1.ListSkillsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillsResponse buildPartial() { + com.google.cloud.agentregistry.v1.ListSkillsResponse result = + new com.google.cloud.agentregistry.v1.ListSkillsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.agentregistry.v1.ListSkillsResponse result) { + if (skillsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + skills_ = java.util.Collections.unmodifiableList(skills_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.skills_ = skills_; + } else { + result.skills_ = skillsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.ListSkillsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + unreachable_.makeImmutable(); + result.unreachable_ = unreachable_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ListSkillsResponse) { + return mergeFrom((com.google.cloud.agentregistry.v1.ListSkillsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ListSkillsResponse other) { + if (other == com.google.cloud.agentregistry.v1.ListSkillsResponse.getDefaultInstance()) + return this; + if (skillsBuilder_ == null) { + if (!other.skills_.isEmpty()) { + if (skills_.isEmpty()) { + skills_ = other.skills_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureSkillsIsMutable(); + skills_.addAll(other.skills_); + } + onChanged(); + } + } else { + if (!other.skills_.isEmpty()) { + if (skillsBuilder_.isEmpty()) { + skillsBuilder_.dispose(); + skillsBuilder_ = null; + skills_ = other.skills_; + bitField0_ = (bitField0_ & ~0x00000001); + skillsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetSkillsFieldBuilder() + : null; + } else { + skillsBuilder_.addAllMessages(other.skills_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.unreachable_.isEmpty()) { + if (unreachable_.isEmpty()) { + unreachable_ = other.unreachable_; + bitField0_ |= 0x00000004; + } else { + ensureUnreachableIsMutable(); + unreachable_.addAll(other.unreachable_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.agentregistry.v1.Skill m = + input.readMessage( + com.google.cloud.agentregistry.v1.Skill.parser(), extensionRegistry); + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + skills_.add(m); + } else { + skillsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List skills_ = + java.util.Collections.emptyList(); + + private void ensureSkillsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + skills_ = new java.util.ArrayList(skills_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder> + skillsBuilder_; + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public java.util.List getSkillsList() { + if (skillsBuilder_ == null) { + return java.util.Collections.unmodifiableList(skills_); + } else { + return skillsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public int getSkillsCount() { + if (skillsBuilder_ == null) { + return skills_.size(); + } else { + return skillsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public com.google.cloud.agentregistry.v1.Skill getSkills(int index) { + if (skillsBuilder_ == null) { + return skills_.get(index); + } else { + return skillsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder setSkills(int index, com.google.cloud.agentregistry.v1.Skill value) { + if (skillsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSkillsIsMutable(); + skills_.set(index, value); + onChanged(); + } else { + skillsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder setSkills( + int index, com.google.cloud.agentregistry.v1.Skill.Builder builderForValue) { + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + skills_.set(index, builderForValue.build()); + onChanged(); + } else { + skillsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder addSkills(com.google.cloud.agentregistry.v1.Skill value) { + if (skillsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSkillsIsMutable(); + skills_.add(value); + onChanged(); + } else { + skillsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder addSkills(int index, com.google.cloud.agentregistry.v1.Skill value) { + if (skillsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSkillsIsMutable(); + skills_.add(index, value); + onChanged(); + } else { + skillsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder addSkills(com.google.cloud.agentregistry.v1.Skill.Builder builderForValue) { + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + skills_.add(builderForValue.build()); + onChanged(); + } else { + skillsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder addSkills( + int index, com.google.cloud.agentregistry.v1.Skill.Builder builderForValue) { + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + skills_.add(index, builderForValue.build()); + onChanged(); + } else { + skillsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder addAllSkills( + java.lang.Iterable values) { + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, skills_); + onChanged(); + } else { + skillsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder clearSkills() { + if (skillsBuilder_ == null) { + skills_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + skillsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder removeSkills(int index) { + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + skills_.remove(index); + onChanged(); + } else { + skillsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public com.google.cloud.agentregistry.v1.Skill.Builder getSkillsBuilder(int index) { + return internalGetSkillsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillsOrBuilder(int index) { + if (skillsBuilder_ == null) { + return skills_.get(index); + } else { + return skillsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public java.util.List + getSkillsOrBuilderList() { + if (skillsBuilder_ != null) { + return skillsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(skills_); + } + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public com.google.cloud.agentregistry.v1.Skill.Builder addSkillsBuilder() { + return internalGetSkillsFieldBuilder() + .addBuilder(com.google.cloud.agentregistry.v1.Skill.getDefaultInstance()); + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public com.google.cloud.agentregistry.v1.Skill.Builder addSkillsBuilder(int index) { + return internalGetSkillsFieldBuilder() + .addBuilder(index, com.google.cloud.agentregistry.v1.Skill.getDefaultInstance()); + } + + /** + * + * + *
+     * Returned container list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public java.util.List getSkillsBuilderList() { + return internalGetSkillsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder> + internalGetSkillsFieldBuilder() { + if (skillsBuilder_ == null) { + skillsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder>( + skills_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + skills_ = null; + } + return skillsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * Page continuation continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Page continuation continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Page continuation continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Page continuation continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Page continuation continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList unreachable_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureUnreachableIsMutable() { + if (!unreachable_.isModifiable()) { + unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); + } + bitField0_ |= 0x00000004; + } + + /** + * + * + *
+     * Unreachable locations or failures.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + unreachable_.makeImmutable(); + return unreachable_; + } + + /** + * + * + *
+     * Unreachable locations or failures.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + + /** + * + * + *
+     * Unreachable locations or failures.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + + /** + * + * + *
+     * Unreachable locations or failures.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + /** + * + * + *
+     * Unreachable locations or failures.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index to set the value at. + * @param value The unreachable to set. + * @return This builder for chaining. + */ + public Builder setUnreachable(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.set(index, value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Unreachable locations or failures.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param value The unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Unreachable locations or failures.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param values The unreachable to add. + * @return This builder for chaining. + */ + public Builder addAllUnreachable(java.lang.Iterable values) { + ensureUnreachableIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Unreachable locations or failures.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return This builder for chaining. + */ + public Builder clearUnreachable() { + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * Unreachable locations or failures.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param value The bytes of the unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUnreachableIsMutable(); + unreachable_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ListSkillsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ListSkillsResponse) + private static final com.google.cloud.agentregistry.v1.ListSkillsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ListSkillsResponse(); + } + + public static com.google.cloud.agentregistry.v1.ListSkillsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListSkillsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ListSkillsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsResponseOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsResponseOrBuilder.java new file mode 100644 index 000000000000..7318ed02d8dc --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ListSkillsResponseOrBuilder.java @@ -0,0 +1,164 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ListSkillsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ListSkillsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Returned container list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + java.util.List getSkillsList(); + + /** + * + * + *
+   * Returned container list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + com.google.cloud.agentregistry.v1.Skill getSkills(int index); + + /** + * + * + *
+   * Returned container list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + int getSkillsCount(); + + /** + * + * + *
+   * Returned container list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + java.util.List + getSkillsOrBuilderList(); + + /** + * + * + *
+   * Returned container list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillsOrBuilder(int index); + + /** + * + * + *
+   * Page continuation continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * Page continuation continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); + + /** + * + * + *
+   * Unreachable locations or failures.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + java.util.List getUnreachableList(); + + /** + * + * + *
+   * Unreachable locations or failures.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + int getUnreachableCount(); + + /** + * + * + *
+   * Unreachable locations or failures.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + java.lang.String getUnreachable(int index); + + /** + * + * + *
+   * Unreachable locations or failures.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + com.google.protobuf.ByteString getUnreachableBytes(int index); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServer.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServer.java index 61875d000a35..36ac93227a9e 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServer.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServer.java @@ -186,6 +186,52 @@ public interface ToolOrBuilder * */ com.google.cloud.agentregistry.v1.McpServer.Tool.AnnotationsOrBuilder getAnnotationsOrBuilder(); + + /** + * + * + *
+     * Output only. Protocol-level tool metadata conforming to MCP _meta
+     * specification. Output only.
+     * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the meta field is set. + */ + boolean hasMeta(); + + /** + * + * + *
+     * Output only. Protocol-level tool metadata conforming to MCP _meta
+     * specification. Output only.
+     * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The meta. + */ + com.google.protobuf.Struct getMeta(); + + /** + * + * + *
+     * Output only. Protocol-level tool metadata conforming to MCP _meta
+     * specification. Output only.
+     * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.StructOrBuilder getMetaOrBuilder(); } /** @@ -1514,6 +1560,64 @@ public com.google.cloud.agentregistry.v1.McpServer.Tool.Annotations getAnnotatio : annotations_; } + public static final int META_FIELD_NUMBER = 4; + private com.google.protobuf.Struct meta_; + + /** + * + * + *
+     * Output only. Protocol-level tool metadata conforming to MCP _meta
+     * specification. Output only.
+     * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the meta field is set. + */ + @java.lang.Override + public boolean hasMeta() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * Output only. Protocol-level tool metadata conforming to MCP _meta
+     * specification. Output only.
+     * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The meta. + */ + @java.lang.Override + public com.google.protobuf.Struct getMeta() { + return meta_ == null ? com.google.protobuf.Struct.getDefaultInstance() : meta_; + } + + /** + * + * + *
+     * Output only. Protocol-level tool metadata conforming to MCP _meta
+     * specification. Output only.
+     * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.StructOrBuilder getMetaOrBuilder() { + return meta_ == null ? com.google.protobuf.Struct.getDefaultInstance() : meta_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -1537,6 +1641,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(3, getAnnotations()); } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(4, getMeta()); + } getUnknownFields().writeTo(output); } @@ -1555,6 +1662,9 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getAnnotations()); } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getMeta()); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1577,6 +1687,10 @@ public boolean equals(final java.lang.Object obj) { if (hasAnnotations()) { if (!getAnnotations().equals(other.getAnnotations())) return false; } + if (hasMeta() != other.hasMeta()) return false; + if (hasMeta()) { + if (!getMeta().equals(other.getMeta())) return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1596,6 +1710,10 @@ public int hashCode() { hash = (37 * hash) + ANNOTATIONS_FIELD_NUMBER; hash = (53 * hash) + getAnnotations().hashCode(); } + if (hasMeta()) { + hash = (37 * hash) + META_FIELD_NUMBER; + hash = (53 * hash) + getMeta().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1738,6 +1856,7 @@ private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { internalGetAnnotationsFieldBuilder(); + internalGetMetaFieldBuilder(); } } @@ -1752,6 +1871,11 @@ public Builder clear() { annotationsBuilder_.dispose(); annotationsBuilder_ = null; } + meta_ = null; + if (metaBuilder_ != null) { + metaBuilder_.dispose(); + metaBuilder_ = null; + } return this; } @@ -1800,6 +1924,10 @@ private void buildPartial0(com.google.cloud.agentregistry.v1.McpServer.Tool resu annotationsBuilder_ == null ? annotations_ : annotationsBuilder_.build(); to_bitField0_ |= 0x00000001; } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.meta_ = metaBuilder_ == null ? meta_ : metaBuilder_.build(); + to_bitField0_ |= 0x00000002; + } result.bitField0_ |= to_bitField0_; } @@ -1829,6 +1957,9 @@ public Builder mergeFrom(com.google.cloud.agentregistry.v1.McpServer.Tool other) if (other.hasAnnotations()) { mergeAnnotations(other.getAnnotations()); } + if (other.hasMeta()) { + mergeMeta(other.getMeta()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1874,6 +2005,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000004; break; } // case 26 + case 34: + { + input.readMessage(internalGetMetaFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 34 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -2334,6 +2471,223 @@ public Builder clearAnnotations() { return annotationsBuilder_; } + private com.google.protobuf.Struct meta_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Struct, + com.google.protobuf.Struct.Builder, + com.google.protobuf.StructOrBuilder> + metaBuilder_; + + /** + * + * + *
+       * Output only. Protocol-level tool metadata conforming to MCP _meta
+       * specification. Output only.
+       * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the meta field is set. + */ + public boolean hasMeta() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+       * Output only. Protocol-level tool metadata conforming to MCP _meta
+       * specification. Output only.
+       * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The meta. + */ + public com.google.protobuf.Struct getMeta() { + if (metaBuilder_ == null) { + return meta_ == null ? com.google.protobuf.Struct.getDefaultInstance() : meta_; + } else { + return metaBuilder_.getMessage(); + } + } + + /** + * + * + *
+       * Output only. Protocol-level tool metadata conforming to MCP _meta
+       * specification. Output only.
+       * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setMeta(com.google.protobuf.Struct value) { + if (metaBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + meta_ = value; + } else { + metaBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. Protocol-level tool metadata conforming to MCP _meta
+       * specification. Output only.
+       * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setMeta(com.google.protobuf.Struct.Builder builderForValue) { + if (metaBuilder_ == null) { + meta_ = builderForValue.build(); + } else { + metaBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. Protocol-level tool metadata conforming to MCP _meta
+       * specification. Output only.
+       * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeMeta(com.google.protobuf.Struct value) { + if (metaBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && meta_ != null + && meta_ != com.google.protobuf.Struct.getDefaultInstance()) { + getMetaBuilder().mergeFrom(value); + } else { + meta_ = value; + } + } else { + metaBuilder_.mergeFrom(value); + } + if (meta_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
+       * Output only. Protocol-level tool metadata conforming to MCP _meta
+       * specification. Output only.
+       * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearMeta() { + bitField0_ = (bitField0_ & ~0x00000008); + meta_ = null; + if (metaBuilder_ != null) { + metaBuilder_.dispose(); + metaBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. Protocol-level tool metadata conforming to MCP _meta
+       * specification. Output only.
+       * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Struct.Builder getMetaBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetMetaFieldBuilder().getBuilder(); + } + + /** + * + * + *
+       * Output only. Protocol-level tool metadata conforming to MCP _meta
+       * specification. Output only.
+       * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.StructOrBuilder getMetaOrBuilder() { + if (metaBuilder_ != null) { + return metaBuilder_.getMessageOrBuilder(); + } else { + return meta_ == null ? com.google.protobuf.Struct.getDefaultInstance() : meta_; + } + } + + /** + * + * + *
+       * Output only. Protocol-level tool metadata conforming to MCP _meta
+       * specification. Output only.
+       * 
+ * + * + * .google.protobuf.Struct meta = 4 [json_name = "_meta", (.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Struct, + com.google.protobuf.Struct.Builder, + com.google.protobuf.StructOrBuilder> + internalGetMetaFieldBuilder() { + if (metaBuilder_ == null) { + metaBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Struct, + com.google.protobuf.Struct.Builder, + com.google.protobuf.StructOrBuilder>( + getMeta(), getParentForChildren(), isClean()); + meta_ = null; + } + return metaBuilder_; + } + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.McpServer.Tool) } diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServerName.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServerName.java index 8b9225e92f06..3db0b33bf1f7 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServerName.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServerName.java @@ -17,6 +17,7 @@ package com.google.cloud.agentregistry.v1; import com.google.api.pathtemplate.PathTemplate; +import com.google.api.pathtemplate.ValidationException; import com.google.api.resourcenames.ResourceName; import com.google.common.base.Preconditions; import com.google.common.collect.ImmutableMap; @@ -35,22 +36,39 @@ public class McpServerName implements ResourceName { private static final PathTemplate PROJECT_LOCATION_MCP_SERVER = PathTemplate.createWithoutUrlEncoding( "projects/{project}/locations/{location}/mcpServers/{mcp_server}"); + private static final PathTemplate PROJECT_LOCATION_AI_APPLICATION_MCP_SERVER = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}"); private volatile Map fieldValuesMap; + private PathTemplate pathTemplate; + private String fixedValue; private final String project; private final String location; private final String mcpServer; + private final String aiApplication; @Deprecated protected McpServerName() { project = null; location = null; mcpServer = null; + aiApplication = null; } private McpServerName(Builder builder) { project = Preconditions.checkNotNull(builder.getProject()); location = Preconditions.checkNotNull(builder.getLocation()); mcpServer = Preconditions.checkNotNull(builder.getMcpServer()); + aiApplication = null; + pathTemplate = PROJECT_LOCATION_MCP_SERVER; + } + + private McpServerName(ProjectLocationAiApplicationMcpServerBuilder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + aiApplication = Preconditions.checkNotNull(builder.getAiApplication()); + mcpServer = Preconditions.checkNotNull(builder.getMcpServer()); + pathTemplate = PROJECT_LOCATION_AI_APPLICATION_MCP_SERVER; } public String getProject() { @@ -65,10 +83,23 @@ public String getMcpServer() { return mcpServer; } + public String getAiApplication() { + return aiApplication; + } + public static Builder newBuilder() { return new Builder(); } + public static Builder newProjectLocationMcpServerBuilder() { + return new Builder(); + } + + public static ProjectLocationAiApplicationMcpServerBuilder + newProjectLocationAiApplicationMcpServerBuilder() { + return new ProjectLocationAiApplicationMcpServerBuilder(); + } + public Builder toBuilder() { return new Builder(this); } @@ -77,6 +108,21 @@ public static McpServerName of(String project, String location, String mcpServer return newBuilder().setProject(project).setLocation(location).setMcpServer(mcpServer).build(); } + public static McpServerName ofProjectLocationMcpServerName( + String project, String location, String mcpServer) { + return newBuilder().setProject(project).setLocation(location).setMcpServer(mcpServer).build(); + } + + public static McpServerName ofProjectLocationAiApplicationMcpServerName( + String project, String location, String aiApplication, String mcpServer) { + return newProjectLocationAiApplicationMcpServerBuilder() + .setProject(project) + .setLocation(location) + .setAiApplication(aiApplication) + .setMcpServer(mcpServer) + .build(); + } + public static String format(String project, String location, String mcpServer) { return newBuilder() .setProject(project) @@ -86,14 +132,45 @@ public static String format(String project, String location, String mcpServer) { .toString(); } + public static String formatProjectLocationMcpServerName( + String project, String location, String mcpServer) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setMcpServer(mcpServer) + .build() + .toString(); + } + + public static String formatProjectLocationAiApplicationMcpServerName( + String project, String location, String aiApplication, String mcpServer) { + return newProjectLocationAiApplicationMcpServerBuilder() + .setProject(project) + .setLocation(location) + .setAiApplication(aiApplication) + .setMcpServer(mcpServer) + .build() + .toString(); + } + public static @Nullable McpServerName parse(String formattedString) { if (formattedString.isEmpty()) { return null; } - Map matchMap = - PROJECT_LOCATION_MCP_SERVER.validatedMatch( - formattedString, "McpServerName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("mcp_server")); + if (PROJECT_LOCATION_MCP_SERVER.matches(formattedString)) { + Map matchMap = PROJECT_LOCATION_MCP_SERVER.match(formattedString); + return ofProjectLocationMcpServerName( + matchMap.get("project"), matchMap.get("location"), matchMap.get("mcp_server")); + } else if (PROJECT_LOCATION_AI_APPLICATION_MCP_SERVER.matches(formattedString)) { + Map matchMap = + PROJECT_LOCATION_AI_APPLICATION_MCP_SERVER.match(formattedString); + return ofProjectLocationAiApplicationMcpServerName( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("ai_application"), + matchMap.get("mcp_server")); + } + throw new ValidationException("McpServerName.parse: formattedString not in valid format"); } public static List parseList(List formattedStrings) { @@ -117,7 +194,8 @@ public static List toStringList(List<@Nullable McpServerName> values) { } public static boolean isParsableFrom(String formattedString) { - return PROJECT_LOCATION_MCP_SERVER.matches(formattedString); + return PROJECT_LOCATION_MCP_SERVER.matches(formattedString) + || PROJECT_LOCATION_AI_APPLICATION_MCP_SERVER.matches(formattedString); } @Override @@ -135,6 +213,9 @@ public Map getFieldValuesMap() { if (mcpServer != null) { fieldMapBuilder.put("mcp_server", mcpServer); } + if (aiApplication != null) { + fieldMapBuilder.put("ai_application", aiApplication); + } fieldValuesMap = fieldMapBuilder.build(); } } @@ -148,8 +229,7 @@ public String getFieldValue(String fieldName) { @Override public String toString() { - return PROJECT_LOCATION_MCP_SERVER.instantiate( - "project", project, "location", location, "mcp_server", mcpServer); + return fixedValue != null ? fixedValue : pathTemplate.instantiate(getFieldValuesMap()); } @Override @@ -161,7 +241,8 @@ public boolean equals(@Nullable Object o) { McpServerName that = ((McpServerName) o); return Objects.equals(this.project, that.project) && Objects.equals(this.location, that.location) - && Objects.equals(this.mcpServer, that.mcpServer); + && Objects.equals(this.mcpServer, that.mcpServer) + && Objects.equals(this.aiApplication, that.aiApplication); } return false; } @@ -170,11 +251,15 @@ public boolean equals(@Nullable Object o) { public int hashCode() { int h = 1; h *= 1000003; + h ^= Objects.hashCode(fixedValue); + h *= 1000003; h ^= Objects.hashCode(project); h *= 1000003; h ^= Objects.hashCode(location); h *= 1000003; h ^= Objects.hashCode(mcpServer); + h *= 1000003; + h ^= Objects.hashCode(aiApplication); return h; } @@ -214,6 +299,10 @@ public Builder setMcpServer(String mcpServer) { } private Builder(McpServerName mcpServerName) { + Preconditions.checkArgument( + Objects.equals(mcpServerName.pathTemplate, PROJECT_LOCATION_MCP_SERVER), + "toBuilder is only supported when McpServerName has the pattern of" + + " projects/{project}/locations/{location}/mcpServers/{mcp_server}"); this.project = mcpServerName.project; this.location = mcpServerName.location; this.mcpServer = mcpServerName.mcpServer; @@ -223,4 +312,57 @@ public McpServerName build() { return new McpServerName(this); } } + + /** + * Builder for + * projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}. + */ + public static class ProjectLocationAiApplicationMcpServerBuilder { + private String project; + private String location; + private String aiApplication; + private String mcpServer; + + protected ProjectLocationAiApplicationMcpServerBuilder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAiApplication() { + return aiApplication; + } + + public String getMcpServer() { + return mcpServer; + } + + public ProjectLocationAiApplicationMcpServerBuilder setProject(String project) { + this.project = project; + return this; + } + + public ProjectLocationAiApplicationMcpServerBuilder setLocation(String location) { + this.location = location; + return this; + } + + public ProjectLocationAiApplicationMcpServerBuilder setAiApplication(String aiApplication) { + this.aiApplication = aiApplication; + return this; + } + + public ProjectLocationAiApplicationMcpServerBuilder setMcpServer(String mcpServer) { + this.mcpServer = mcpServer; + return this; + } + + public McpServerName build() { + return new McpServerName(this); + } + } } diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServerProto.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServerProto.java index 565f43aceefe..60be2fd96ec9 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServerProto.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/McpServerProto.java @@ -71,7 +71,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\037google/api/field_behavior.proto\032\031google" + "/api/resource.proto\032.google/cloud/agentr" + "egistry/v1/properties.proto\032\034google/prot" - + "obuf/struct.proto\032\037google/protobuf/timestamp.proto\"\277\007\n" + + "obuf/struct.proto\032\037google/protobuf/timestamp.proto\"\324\010\n" + "\tMcpServer\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\033\n\r" + "mcp_server_id\030\t \001(\tB\004\342A\001\003\022\032\n" @@ -86,12 +86,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013update_time\030\007" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022R\n\n" + "attributes\030\010 \003(\01328.goo" - + "gle.cloud.agentregistry.v1.McpServer.AttributesEntryB\004\342A\001\003\032\254\002\n" + + "gle.cloud.agentregistry.v1.McpServer.AttributesEntryB\004\342A\001\003\032\340\002\n" + "\004Tool\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\003\022\031\n" + "\013description\030\002 \001(\tB\004\342A\001\003\022T\n" + "\013annotations\030\003 \001(\01329.google.cloud.agentregi" - + "stry.v1.McpServer.Tool.AnnotationsB\004\342A\001\003\032\236\001\n" + + "stry.v1.McpServer.Tool.AnnotationsB\004\342A\001\003\0222\n" + + "\004meta\030\004" + + " \001(\0132\027.google.protobuf.StructB\004\342A\001\003R\005_meta\032\236\001\n" + "\013Annotations\022\023\n" + "\005title\030\001 \001(\tB\004\342A\001\003\022\036\n" + "\020destructive_hint\030\002 \001(\010B\004\342A\001\003\022\035\n" @@ -101,14 +103,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017AttributesEntry\022\013\n" + "\003key\030\001 \001(\t\022&\n" + "\005value\030\002" - + " \001(\0132\027.google.protobuf.Struct:\0028\001:\204\001\352A\200\001\n" - + "&agentregistry.googleapis.com/McpSe" - + "rver\022?projects/{project}/locations/{location}/mcpServers/{mcp_server}*\n" + + " \001(\0132\027.google.protobuf.Struct:\0028\001:\345\001\352A\341\001\n" + + "&agentregistry.googleapis.com/McpServer\022?projects/{project}/loc" + + "ations/{location}/mcpServers/{mcp_server}\022_projects/{project}/locations/{locatio" + + "n}/aiApplications/{ai_application}/mcpServers/{mcp_server}*\n" + "mcpServers2\tmcpServerB\341\001\n" - + "!com.google.cloud.agentregistry.v1B\016McpServerProtoP\001ZGcloud.goog" - + "le.com/go/agentregistry/apiv1/agentregis" - + "trypb;agentregistrypb\252\002\035Google.Cloud.Age" - + "ntRegistry.V1\312\002\035Google\\Cloud\\AgentRegistry\\V1\352\002" + + "!com.google.cloud.agentregistry.v1B\016McpServerProtoP\001ZGcloud.google.com/go/a" + + "gentregistry/apiv1/agentregistrypb;agent" + + "registrypb\252\002\035Google.Cloud.AgentRegistry.V1\312\002\035Google\\Cloud\\AgentRegistry\\V1\352\002" + " Google::Cloud::AgentRegistry::V1b\006proto3" }; descriptor = @@ -143,7 +145,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_agentregistry_v1_McpServer_Tool_descriptor, new java.lang.String[] { - "Name", "Description", "Annotations", + "Name", "Description", "Annotations", "Meta", }); internal_static_google_cloud_agentregistry_v1_McpServer_Tool_Annotations_descriptor = internal_static_google_cloud_agentregistry_v1_McpServer_Tool_descriptor.getNestedType(0); diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/PropertiesProto.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/PropertiesProto.java index 5446602621f3..f7e68bd949f0 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/PropertiesProto.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/PropertiesProto.java @@ -55,25 +55,26 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { java.lang.String[] descriptorData = { "\n.google/cloud/agentregistry/v1/properti" + "es.proto\022\035google.cloud.agentregistry.v1\032" - + "\037google/api/field_behavior.proto\"\323\001\n\tInt" - + "erface\022\021\n\003url\030\001 \001(\tB\004\342A\001\002\022X\n\020protocol_bi" - + "nding\030\002 \001(\01628.google.cloud.agentregistry" - + ".v1.Interface.ProtocolBindingB\004\342A\001\002\"Y\n\017P" - + "rotocolBinding\022 \n\034PROTOCOL_BINDING_UNSPE" - + "CIFIED\020\000\022\013\n\007JSONRPC\020\001\022\010\n\004GRPC\020\002\022\r\n\tHTTP_" - + "JSON\020\003B\342\001\n!com.google.cloud.agentregistr" - + "y.v1B\017PropertiesProtoP\001ZGcloud.google.co" - + "m/go/agentregistry/apiv1/agentregistrypb" - + ";agentregistrypb\252\002\035Google.Cloud.AgentReg" - + "istry.V1\312\002\035Google\\Cloud\\AgentRegistry\\V1" - + "\352\002 Google::Cloud::AgentRegistry::V1b\006pro" - + "to3" + + "\037google/api/field_behavior.proto\032\031google" + + "/api/resource.proto\"\323\001\n\tInterface\022\021\n\003url" + + "\030\001 \001(\tB\004\342A\001\002\022X\n\020protocol_binding\030\002 \001(\01628" + + ".google.cloud.agentregistry.v1.Interface" + + ".ProtocolBindingB\004\342A\001\002\"Y\n\017ProtocolBindin" + + "g\022 \n\034PROTOCOL_BINDING_UNSPECIFIED\020\000\022\013\n\007J" + + "SONRPC\020\001\022\010\n\004GRPC\020\002\022\r\n\tHTTP_JSON\020\003B\342\001\n!co" + + "m.google.cloud.agentregistry.v1B\017Propert" + + "iesProtoP\001ZGcloud.google.com/go/agentreg" + + "istry/apiv1/agentregistrypb;agentregistr" + + "ypb\252\002\035Google.Cloud.AgentRegistry.V1\312\002\035Go" + + "ogle\\Cloud\\AgentRegistry\\V1\352\002 Google::Cl" + + "oud::AgentRegistry::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( descriptorData, new com.google.protobuf.Descriptors.FileDescriptor[] { com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), }); internal_static_google_cloud_agentregistry_v1_Interface_descriptor = getDescriptor().getMessageType(0); @@ -85,6 +86,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { }); descriptor.resolveAllFeaturesImmutable(); com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); com.google.protobuf.ExtensionRegistry registry = com.google.protobuf.ExtensionRegistry.newInstance(); registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Publisher.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Publisher.java new file mode 100644 index 000000000000..d92ca4a27734 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Publisher.java @@ -0,0 +1,1753 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Represents a verified Publisher of Skills.
+ * Prepopulated publishers include `publishers/cloud.google.com` and
+ * `publishers/workspace.google.com`.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.Publisher} + */ +@com.google.protobuf.Generated +public final class Publisher extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.Publisher) + PublisherOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Publisher"); + } + + // Use Publisher.newBuilder() to construct. + private Publisher(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Publisher() { + name_ = ""; + verifiedPrefix_ = ""; + displayName_ = ""; + publisherTier_ = 0; + documentationUri_ = ""; + supportUri_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Publisher_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Publisher_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.Publisher.class, + com.google.cloud.agentregistry.v1.Publisher.Builder.class); + } + + /** + * + * + *
+   * Curation tier representing the publisher's level of verification.
+   * 
+ * + * Protobuf enum {@code google.cloud.agentregistry.v1.Publisher.PublisherTier} + */ + public enum PublisherTier implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default value. Unspecified.
+     * 
+ * + * PUBLISHER_TIER_UNSPECIFIED = 0; + */ + PUBLISHER_TIER_UNSPECIFIED(0), + /** + * + * + *
+     * First-party Google-curated and verified global publishers.
+     * 
+ * + * FIRST_PARTY = 1; + */ + FIRST_PARTY(1), + /** + * + * + *
+     * Third-party verified enterprise partner publishers.
+     * 
+ * + * THIRD_PARTY = 2; + */ + THIRD_PARTY(2), + /** + * + * + *
+     * Private publishers within the developer's workspace/project.
+     * 
+ * + * PRIVATE = 3; + */ + PRIVATE(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "PublisherTier"); + } + + /** + * + * + *
+     * Default value. Unspecified.
+     * 
+ * + * PUBLISHER_TIER_UNSPECIFIED = 0; + */ + public static final int PUBLISHER_TIER_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * First-party Google-curated and verified global publishers.
+     * 
+ * + * FIRST_PARTY = 1; + */ + public static final int FIRST_PARTY_VALUE = 1; + + /** + * + * + *
+     * Third-party verified enterprise partner publishers.
+     * 
+ * + * THIRD_PARTY = 2; + */ + public static final int THIRD_PARTY_VALUE = 2; + + /** + * + * + *
+     * Private publishers within the developer's workspace/project.
+     * 
+ * + * PRIVATE = 3; + */ + public static final int PRIVATE_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static PublisherTier valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static PublisherTier forNumber(int value) { + switch (value) { + case 0: + return PUBLISHER_TIER_UNSPECIFIED; + case 1: + return FIRST_PARTY; + case 2: + return THIRD_PARTY; + case 3: + return PRIVATE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public PublisherTier findValueByNumber(int number) { + return PublisherTier.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.Publisher.getDescriptor().getEnumTypes().get(0); + } + + private static final PublisherTier[] VALUES = values(); + + public static PublisherTier valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private PublisherTier(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.agentregistry.v1.Publisher.PublisherTier) + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Identifier. Resource name of the publisher.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Identifier. Resource name of the publisher.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VERIFIED_PREFIX_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object verifiedPrefix_ = ""; + + /** + * + * + *
+   * Required. The verified prefix (e.g. "snowflake-", "google-") associated
+   * with this publisher. The system uses this prefix to enforce name-squatting
+   * rules during Skill registration. Must be globally unique across all
+   * publishers.
+   * 
+ * + * string verified_prefix = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The verifiedPrefix. + */ + @java.lang.Override + public java.lang.String getVerifiedPrefix() { + java.lang.Object ref = verifiedPrefix_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + verifiedPrefix_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The verified prefix (e.g. "snowflake-", "google-") associated
+   * with this publisher. The system uses this prefix to enforce name-squatting
+   * rules during Skill registration. Must be globally unique across all
+   * publishers.
+   * 
+ * + * string verified_prefix = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for verifiedPrefix. + */ + @java.lang.Override + public com.google.protobuf.ByteString getVerifiedPrefixBytes() { + java.lang.Object ref = verifiedPrefix_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + verifiedPrefix_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object displayName_ = ""; + + /** + * + * + *
+   * Optional. Human readable display name of the publisher.
+   * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Human readable display name of the publisher.
+   * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PUBLISHER_TIER_FIELD_NUMBER = 4; + private int publisherTier_ = 0; + + /** + * + * + *
+   * Output only. The curation tier of the publisher.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Publisher.PublisherTier publisher_tier = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for publisherTier. + */ + @java.lang.Override + public int getPublisherTierValue() { + return publisherTier_; + } + + /** + * + * + *
+   * Output only. The curation tier of the publisher.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Publisher.PublisherTier publisher_tier = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The publisherTier. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Publisher.PublisherTier getPublisherTier() { + com.google.cloud.agentregistry.v1.Publisher.PublisherTier result = + com.google.cloud.agentregistry.v1.Publisher.PublisherTier.forNumber(publisherTier_); + return result == null + ? com.google.cloud.agentregistry.v1.Publisher.PublisherTier.UNRECOGNIZED + : result; + } + + public static final int DOCUMENTATION_URI_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object documentationUri_ = ""; + + /** + * + * + *
+   * Optional. URI pointing to official publisher documentation.
+   * 
+ * + * string documentation_uri = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentationUri. + */ + @java.lang.Override + public java.lang.String getDocumentationUri() { + java.lang.Object ref = documentationUri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + documentationUri_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. URI pointing to official publisher documentation.
+   * 
+ * + * string documentation_uri = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for documentationUri. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDocumentationUriBytes() { + java.lang.Object ref = documentationUri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + documentationUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SUPPORT_URI_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private volatile java.lang.Object supportUri_ = ""; + + /** + * + * + *
+   * Optional. URI pointing to the support portal or email.
+   * 
+ * + * string support_uri = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The supportUri. + */ + @java.lang.Override + public java.lang.String getSupportUri() { + java.lang.Object ref = supportUri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + supportUri_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. URI pointing to the support portal or email.
+   * 
+ * + * string support_uri = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for supportUri. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSupportUriBytes() { + java.lang.Object ref = supportUri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + supportUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(verifiedPrefix_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, verifiedPrefix_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, displayName_); + } + if (publisherTier_ + != com.google.cloud.agentregistry.v1.Publisher.PublisherTier.PUBLISHER_TIER_UNSPECIFIED + .getNumber()) { + output.writeEnum(4, publisherTier_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(documentationUri_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, documentationUri_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(supportUri_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, supportUri_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(verifiedPrefix_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, verifiedPrefix_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, displayName_); + } + if (publisherTier_ + != com.google.cloud.agentregistry.v1.Publisher.PublisherTier.PUBLISHER_TIER_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, publisherTier_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(documentationUri_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, documentationUri_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(supportUri_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(6, supportUri_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.Publisher)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.Publisher other = + (com.google.cloud.agentregistry.v1.Publisher) obj; + + if (!getName().equals(other.getName())) return false; + if (!getVerifiedPrefix().equals(other.getVerifiedPrefix())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (publisherTier_ != other.publisherTier_) return false; + if (!getDocumentationUri().equals(other.getDocumentationUri())) return false; + if (!getSupportUri().equals(other.getSupportUri())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + VERIFIED_PREFIX_FIELD_NUMBER; + hash = (53 * hash) + getVerifiedPrefix().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + hash = (37 * hash) + PUBLISHER_TIER_FIELD_NUMBER; + hash = (53 * hash) + publisherTier_; + hash = (37 * hash) + DOCUMENTATION_URI_FIELD_NUMBER; + hash = (53 * hash) + getDocumentationUri().hashCode(); + hash = (37 * hash) + SUPPORT_URI_FIELD_NUMBER; + hash = (53 * hash) + getSupportUri().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.Publisher parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Publisher parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Publisher parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Publisher parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Publisher parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Publisher parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Publisher parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Publisher parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Publisher parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Publisher parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Publisher parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Publisher parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.Publisher prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Represents a verified Publisher of Skills.
+   * Prepopulated publishers include `publishers/cloud.google.com` and
+   * `publishers/workspace.google.com`.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.Publisher} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.Publisher) + com.google.cloud.agentregistry.v1.PublisherOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Publisher_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Publisher_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.Publisher.class, + com.google.cloud.agentregistry.v1.Publisher.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.Publisher.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + verifiedPrefix_ = ""; + displayName_ = ""; + publisherTier_ = 0; + documentationUri_ = ""; + supportUri_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Publisher_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Publisher getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.Publisher.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Publisher build() { + com.google.cloud.agentregistry.v1.Publisher result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Publisher buildPartial() { + com.google.cloud.agentregistry.v1.Publisher result = + new com.google.cloud.agentregistry.v1.Publisher(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.Publisher result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.verifiedPrefix_ = verifiedPrefix_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.displayName_ = displayName_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.publisherTier_ = publisherTier_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.documentationUri_ = documentationUri_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.supportUri_ = supportUri_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.Publisher) { + return mergeFrom((com.google.cloud.agentregistry.v1.Publisher) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.Publisher other) { + if (other == com.google.cloud.agentregistry.v1.Publisher.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getVerifiedPrefix().isEmpty()) { + verifiedPrefix_ = other.verifiedPrefix_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.publisherTier_ != 0) { + setPublisherTierValue(other.getPublisherTierValue()); + } + if (!other.getDocumentationUri().isEmpty()) { + documentationUri_ = other.documentationUri_; + bitField0_ |= 0x00000010; + onChanged(); + } + if (!other.getSupportUri().isEmpty()) { + supportUri_ = other.supportUri_; + bitField0_ |= 0x00000020; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + verifiedPrefix_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 32: + { + publisherTier_ = input.readEnum(); + bitField0_ |= 0x00000008; + break; + } // case 32 + case 42: + { + documentationUri_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + supportUri_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000020; + break; + } // case 50 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Identifier. Resource name of the publisher.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the publisher.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the publisher.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the publisher.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the publisher.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object verifiedPrefix_ = ""; + + /** + * + * + *
+     * Required. The verified prefix (e.g. "snowflake-", "google-") associated
+     * with this publisher. The system uses this prefix to enforce name-squatting
+     * rules during Skill registration. Must be globally unique across all
+     * publishers.
+     * 
+ * + * string verified_prefix = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The verifiedPrefix. + */ + public java.lang.String getVerifiedPrefix() { + java.lang.Object ref = verifiedPrefix_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + verifiedPrefix_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The verified prefix (e.g. "snowflake-", "google-") associated
+     * with this publisher. The system uses this prefix to enforce name-squatting
+     * rules during Skill registration. Must be globally unique across all
+     * publishers.
+     * 
+ * + * string verified_prefix = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for verifiedPrefix. + */ + public com.google.protobuf.ByteString getVerifiedPrefixBytes() { + java.lang.Object ref = verifiedPrefix_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + verifiedPrefix_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The verified prefix (e.g. "snowflake-", "google-") associated
+     * with this publisher. The system uses this prefix to enforce name-squatting
+     * rules during Skill registration. Must be globally unique across all
+     * publishers.
+     * 
+ * + * string verified_prefix = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The verifiedPrefix to set. + * @return This builder for chaining. + */ + public Builder setVerifiedPrefix(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + verifiedPrefix_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The verified prefix (e.g. "snowflake-", "google-") associated
+     * with this publisher. The system uses this prefix to enforce name-squatting
+     * rules during Skill registration. Must be globally unique across all
+     * publishers.
+     * 
+ * + * string verified_prefix = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearVerifiedPrefix() { + verifiedPrefix_ = getDefaultInstance().getVerifiedPrefix(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The verified prefix (e.g. "snowflake-", "google-") associated
+     * with this publisher. The system uses this prefix to enforce name-squatting
+     * rules during Skill registration. Must be globally unique across all
+     * publishers.
+     * 
+ * + * string verified_prefix = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for verifiedPrefix to set. + * @return This builder for chaining. + */ + public Builder setVerifiedPrefixBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + verifiedPrefix_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + + /** + * + * + *
+     * Optional. Human readable display name of the publisher.
+     * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Human readable display name of the publisher.
+     * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Human readable display name of the publisher.
+     * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + displayName_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Human readable display name of the publisher.
+     * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + displayName_ = getDefaultInstance().getDisplayName(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Human readable display name of the publisher.
+     * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + displayName_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private int publisherTier_ = 0; + + /** + * + * + *
+     * Output only. The curation tier of the publisher.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Publisher.PublisherTier publisher_tier = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for publisherTier. + */ + @java.lang.Override + public int getPublisherTierValue() { + return publisherTier_; + } + + /** + * + * + *
+     * Output only. The curation tier of the publisher.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Publisher.PublisherTier publisher_tier = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for publisherTier to set. + * @return This builder for chaining. + */ + public Builder setPublisherTierValue(int value) { + publisherTier_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The curation tier of the publisher.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Publisher.PublisherTier publisher_tier = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The publisherTier. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Publisher.PublisherTier getPublisherTier() { + com.google.cloud.agentregistry.v1.Publisher.PublisherTier result = + com.google.cloud.agentregistry.v1.Publisher.PublisherTier.forNumber(publisherTier_); + return result == null + ? com.google.cloud.agentregistry.v1.Publisher.PublisherTier.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Output only. The curation tier of the publisher.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Publisher.PublisherTier publisher_tier = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The publisherTier to set. + * @return This builder for chaining. + */ + public Builder setPublisherTier( + com.google.cloud.agentregistry.v1.Publisher.PublisherTier value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000008; + publisherTier_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The curation tier of the publisher.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Publisher.PublisherTier publisher_tier = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearPublisherTier() { + bitField0_ = (bitField0_ & ~0x00000008); + publisherTier_ = 0; + onChanged(); + return this; + } + + private java.lang.Object documentationUri_ = ""; + + /** + * + * + *
+     * Optional. URI pointing to official publisher documentation.
+     * 
+ * + * string documentation_uri = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentationUri. + */ + public java.lang.String getDocumentationUri() { + java.lang.Object ref = documentationUri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + documentationUri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. URI pointing to official publisher documentation.
+     * 
+ * + * string documentation_uri = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for documentationUri. + */ + public com.google.protobuf.ByteString getDocumentationUriBytes() { + java.lang.Object ref = documentationUri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + documentationUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. URI pointing to official publisher documentation.
+     * 
+ * + * string documentation_uri = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The documentationUri to set. + * @return This builder for chaining. + */ + public Builder setDocumentationUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + documentationUri_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. URI pointing to official publisher documentation.
+     * 
+ * + * string documentation_uri = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDocumentationUri() { + documentationUri_ = getDefaultInstance().getDocumentationUri(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. URI pointing to official publisher documentation.
+     * 
+ * + * string documentation_uri = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for documentationUri to set. + * @return This builder for chaining. + */ + public Builder setDocumentationUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + documentationUri_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private java.lang.Object supportUri_ = ""; + + /** + * + * + *
+     * Optional. URI pointing to the support portal or email.
+     * 
+ * + * string support_uri = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The supportUri. + */ + public java.lang.String getSupportUri() { + java.lang.Object ref = supportUri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + supportUri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. URI pointing to the support portal or email.
+     * 
+ * + * string support_uri = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for supportUri. + */ + public com.google.protobuf.ByteString getSupportUriBytes() { + java.lang.Object ref = supportUri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + supportUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. URI pointing to the support portal or email.
+     * 
+ * + * string support_uri = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The supportUri to set. + * @return This builder for chaining. + */ + public Builder setSupportUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + supportUri_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. URI pointing to the support portal or email.
+     * 
+ * + * string support_uri = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearSupportUri() { + supportUri_ = getDefaultInstance().getSupportUri(); + bitField0_ = (bitField0_ & ~0x00000020); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. URI pointing to the support portal or email.
+     * 
+ * + * string support_uri = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for supportUri to set. + * @return This builder for chaining. + */ + public Builder setSupportUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + supportUri_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.Publisher) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.Publisher) + private static final com.google.cloud.agentregistry.v1.Publisher DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.Publisher(); + } + + public static com.google.cloud.agentregistry.v1.Publisher getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Publisher parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Publisher getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/PublisherName.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/PublisherName.java new file mode 100644 index 000000000000..efab795b8d9f --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/PublisherName.java @@ -0,0 +1,226 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class PublisherName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_PUBLISHER = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/publishers/{publisher}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String publisher; + + @Deprecated + protected PublisherName() { + project = null; + location = null; + publisher = null; + } + + private PublisherName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + publisher = Preconditions.checkNotNull(builder.getPublisher()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getPublisher() { + return publisher; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static PublisherName of(String project, String location, String publisher) { + return newBuilder().setProject(project).setLocation(location).setPublisher(publisher).build(); + } + + public static String format(String project, String location, String publisher) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setPublisher(publisher) + .build() + .toString(); + } + + public static @Nullable PublisherName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_PUBLISHER.validatedMatch( + formattedString, "PublisherName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("publisher")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable PublisherName> values) { + List list = new ArrayList<>(values.size()); + for (PublisherName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_PUBLISHER.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (publisher != null) { + fieldMapBuilder.put("publisher", publisher); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_PUBLISHER.instantiate( + "project", project, "location", location, "publisher", publisher); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + PublisherName that = ((PublisherName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.publisher, that.publisher); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(publisher); + return h; + } + + /** Builder for projects/{project}/locations/{location}/publishers/{publisher}. */ + public static class Builder { + private String project; + private String location; + private String publisher; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getPublisher() { + return publisher; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setPublisher(String publisher) { + this.publisher = publisher; + return this; + } + + private Builder(PublisherName publisherName) { + this.project = publisherName.project; + this.location = publisherName.location; + this.publisher = publisherName.publisher; + } + + public PublisherName build() { + return new PublisherName(this); + } + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/PublisherOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/PublisherOrBuilder.java new file mode 100644 index 000000000000..e348ba60403a --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/PublisherOrBuilder.java @@ -0,0 +1,196 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface PublisherOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.Publisher) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Identifier. Resource name of the publisher.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Identifier. Resource name of the publisher.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Required. The verified prefix (e.g. "snowflake-", "google-") associated
+   * with this publisher. The system uses this prefix to enforce name-squatting
+   * rules during Skill registration. Must be globally unique across all
+   * publishers.
+   * 
+ * + * string verified_prefix = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The verifiedPrefix. + */ + java.lang.String getVerifiedPrefix(); + + /** + * + * + *
+   * Required. The verified prefix (e.g. "snowflake-", "google-") associated
+   * with this publisher. The system uses this prefix to enforce name-squatting
+   * rules during Skill registration. Must be globally unique across all
+   * publishers.
+   * 
+ * + * string verified_prefix = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for verifiedPrefix. + */ + com.google.protobuf.ByteString getVerifiedPrefixBytes(); + + /** + * + * + *
+   * Optional. Human readable display name of the publisher.
+   * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
+   * Optional. Human readable display name of the publisher.
+   * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
+   * Output only. The curation tier of the publisher.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Publisher.PublisherTier publisher_tier = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for publisherTier. + */ + int getPublisherTierValue(); + + /** + * + * + *
+   * Output only. The curation tier of the publisher.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Publisher.PublisherTier publisher_tier = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The publisherTier. + */ + com.google.cloud.agentregistry.v1.Publisher.PublisherTier getPublisherTier(); + + /** + * + * + *
+   * Optional. URI pointing to official publisher documentation.
+   * 
+ * + * string documentation_uri = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentationUri. + */ + java.lang.String getDocumentationUri(); + + /** + * + * + *
+   * Optional. URI pointing to official publisher documentation.
+   * 
+ * + * string documentation_uri = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for documentationUri. + */ + com.google.protobuf.ByteString getDocumentationUriBytes(); + + /** + * + * + *
+   * Optional. URI pointing to the support portal or email.
+   * 
+ * + * string support_uri = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The supportUri. + */ + java.lang.String getSupportUri(); + + /** + * + * + *
+   * Optional. URI pointing to the support portal or email.
+   * 
+ * + * string support_uri = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for supportUri. + */ + com.google.protobuf.ByteString getSupportUriBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ScanningConfig.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ScanningConfig.java new file mode 100644 index 000000000000..0c3cca500eb7 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ScanningConfig.java @@ -0,0 +1,778 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Configuration for scanning of the skill.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ScanningConfig} + */ +@com.google.protobuf.Generated +public final class ScanningConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.ScanningConfig) + ScanningConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ScanningConfig"); + } + + // Use ScanningConfig.newBuilder() to construct. + private ScanningConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ScanningConfig() { + policy_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_ScanningConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_ScanningConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ScanningConfig.class, + com.google.cloud.agentregistry.v1.ScanningConfig.Builder.class); + } + + /** + * + * + *
+   * Defines the policy for security scanning.
+   *
+   * This enum is not frozen; new values may be added in the future.
+   * 
+ * + * Protobuf enum {@code google.cloud.agentregistry.v1.ScanningConfig.Policy} + */ + public enum Policy implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default value. Inherits system default (ENABLED_BLOCKING).
+     * 
+ * + * POLICY_UNSPECIFIED = 0; + */ + POLICY_UNSPECIFIED(0), + /** + * + * + *
+     * Bypasses scanning.
+     * 
+ * + * DISABLED = 1; + */ + DISABLED(1), + /** + * + * + *
+     * Scans the skill package and blocks download if security or safety issues
+     * are found.
+     * 
+ * + * ENABLED_BLOCKING = 2; + */ + ENABLED_BLOCKING(2), + /** + * + * + *
+     * Scans the skill package in audit mode without blocking downloads.
+     * 
+ * + * ENABLED_NONBLOCKING = 3; + */ + ENABLED_NONBLOCKING(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Policy"); + } + + /** + * + * + *
+     * Default value. Inherits system default (ENABLED_BLOCKING).
+     * 
+ * + * POLICY_UNSPECIFIED = 0; + */ + public static final int POLICY_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * Bypasses scanning.
+     * 
+ * + * DISABLED = 1; + */ + public static final int DISABLED_VALUE = 1; + + /** + * + * + *
+     * Scans the skill package and blocks download if security or safety issues
+     * are found.
+     * 
+ * + * ENABLED_BLOCKING = 2; + */ + public static final int ENABLED_BLOCKING_VALUE = 2; + + /** + * + * + *
+     * Scans the skill package in audit mode without blocking downloads.
+     * 
+ * + * ENABLED_NONBLOCKING = 3; + */ + public static final int ENABLED_NONBLOCKING_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Policy valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static Policy forNumber(int value) { + switch (value) { + case 0: + return POLICY_UNSPECIFIED; + case 1: + return DISABLED; + case 2: + return ENABLED_BLOCKING; + case 3: + return ENABLED_NONBLOCKING; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Policy findValueByNumber(int number) { + return Policy.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.ScanningConfig.getDescriptor().getEnumTypes().get(0); + } + + private static final Policy[] VALUES = values(); + + public static Policy valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Policy(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.agentregistry.v1.ScanningConfig.Policy) + } + + public static final int POLICY_FIELD_NUMBER = 1; + private int policy_ = 0; + + /** + * + * + *
+   * Optional. The security scanning policy.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig.Policy policy = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for policy. + */ + @java.lang.Override + public int getPolicyValue() { + return policy_; + } + + /** + * + * + *
+   * Optional. The security scanning policy.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig.Policy policy = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The policy. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.ScanningConfig.Policy getPolicy() { + com.google.cloud.agentregistry.v1.ScanningConfig.Policy result = + com.google.cloud.agentregistry.v1.ScanningConfig.Policy.forNumber(policy_); + return result == null + ? com.google.cloud.agentregistry.v1.ScanningConfig.Policy.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (policy_ + != com.google.cloud.agentregistry.v1.ScanningConfig.Policy.POLICY_UNSPECIFIED.getNumber()) { + output.writeEnum(1, policy_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (policy_ + != com.google.cloud.agentregistry.v1.ScanningConfig.Policy.POLICY_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, policy_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.ScanningConfig)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.ScanningConfig other = + (com.google.cloud.agentregistry.v1.ScanningConfig) obj; + + if (policy_ != other.policy_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + POLICY_FIELD_NUMBER; + hash = (53 * hash) + policy_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.ScanningConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Configuration for scanning of the skill.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.ScanningConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.ScanningConfig) + com.google.cloud.agentregistry.v1.ScanningConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_ScanningConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_ScanningConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.ScanningConfig.class, + com.google.cloud.agentregistry.v1.ScanningConfig.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.ScanningConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + policy_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_ScanningConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ScanningConfig getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.ScanningConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ScanningConfig build() { + com.google.cloud.agentregistry.v1.ScanningConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ScanningConfig buildPartial() { + com.google.cloud.agentregistry.v1.ScanningConfig result = + new com.google.cloud.agentregistry.v1.ScanningConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.ScanningConfig result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.policy_ = policy_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.ScanningConfig) { + return mergeFrom((com.google.cloud.agentregistry.v1.ScanningConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.ScanningConfig other) { + if (other == com.google.cloud.agentregistry.v1.ScanningConfig.getDefaultInstance()) + return this; + if (other.policy_ != 0) { + setPolicyValue(other.getPolicyValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + policy_ = input.readEnum(); + bitField0_ |= 0x00000001; + break; + } // case 8 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int policy_ = 0; + + /** + * + * + *
+     * Optional. The security scanning policy.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig.Policy policy = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for policy. + */ + @java.lang.Override + public int getPolicyValue() { + return policy_; + } + + /** + * + * + *
+     * Optional. The security scanning policy.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig.Policy policy = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for policy to set. + * @return This builder for chaining. + */ + public Builder setPolicyValue(int value) { + policy_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The security scanning policy.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig.Policy policy = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The policy. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.ScanningConfig.Policy getPolicy() { + com.google.cloud.agentregistry.v1.ScanningConfig.Policy result = + com.google.cloud.agentregistry.v1.ScanningConfig.Policy.forNumber(policy_); + return result == null + ? com.google.cloud.agentregistry.v1.ScanningConfig.Policy.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Optional. The security scanning policy.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig.Policy policy = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The policy to set. + * @return This builder for chaining. + */ + public Builder setPolicy(com.google.cloud.agentregistry.v1.ScanningConfig.Policy value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + policy_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The security scanning policy.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig.Policy policy = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearPolicy() { + bitField0_ = (bitField0_ & ~0x00000001); + policy_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.ScanningConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.ScanningConfig) + private static final com.google.cloud.agentregistry.v1.ScanningConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.ScanningConfig(); + } + + public static com.google.cloud.agentregistry.v1.ScanningConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ScanningConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.ScanningConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ScanningConfigOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ScanningConfigOrBuilder.java new file mode 100644 index 000000000000..c64b4d67fd71 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ScanningConfigOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface ScanningConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.ScanningConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Optional. The security scanning policy.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig.Policy policy = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for policy. + */ + int getPolicyValue(); + + /** + * + * + *
+   * Optional. The security scanning policy.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig.Policy policy = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The policy. + */ + com.google.cloud.agentregistry.v1.ScanningConfig.Policy getPolicy(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchAgentsRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchAgentsRequest.java index 78ce75d66e73..b87eff310bb0 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchAgentsRequest.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchAgentsRequest.java @@ -168,7 +168,7 @@ public com.google.protobuf.ByteString getParentBytes() { * * Examples: * - * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:reasoningEngines:1234"` + * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:aiplatform:reasoningEngines:1234"` * to find the agent with the specified agent ID. * * `name:important` to find agents whose name contains `important` as a * word. @@ -228,7 +228,7 @@ public java.lang.String getSearchString() { * * Examples: * - * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:reasoningEngines:1234"` + * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:aiplatform:reasoningEngines:1234"` * to find the agent with the specified agent ID. * * `name:important` to find agents whose name contains `important` as a * word. @@ -879,7 +879,7 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) { * * Examples: * - * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:reasoningEngines:1234"` + * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:aiplatform:reasoningEngines:1234"` * to find the agent with the specified agent ID. * * `name:important` to find agents whose name contains `important` as a * word. @@ -938,7 +938,7 @@ public java.lang.String getSearchString() { * * Examples: * - * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:reasoningEngines:1234"` + * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:aiplatform:reasoningEngines:1234"` * to find the agent with the specified agent ID. * * `name:important` to find agents whose name contains `important` as a * word. @@ -997,7 +997,7 @@ public com.google.protobuf.ByteString getSearchStringBytes() { * * Examples: * - * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:reasoningEngines:1234"` + * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:aiplatform:reasoningEngines:1234"` * to find the agent with the specified agent ID. * * `name:important` to find agents whose name contains `important` as a * word. @@ -1055,7 +1055,7 @@ public Builder setSearchString(java.lang.String value) { * * Examples: * - * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:reasoningEngines:1234"` + * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:aiplatform:reasoningEngines:1234"` * to find the agent with the specified agent ID. * * `name:important` to find agents whose name contains `important` as a * word. @@ -1109,7 +1109,7 @@ public Builder clearSearchString() { * * Examples: * - * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:reasoningEngines:1234"` + * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:aiplatform:reasoningEngines:1234"` * to find the agent with the specified agent ID. * * `name:important` to find agents whose name contains `important` as a * word. diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchAgentsRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchAgentsRequestOrBuilder.java index e74129d77e5f..04b530d06a1c 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchAgentsRequestOrBuilder.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchAgentsRequestOrBuilder.java @@ -90,7 +90,7 @@ public interface SearchAgentsRequestOrBuilder * * Examples: * - * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:reasoningEngines:1234"` + * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:aiplatform:reasoningEngines:1234"` * to find the agent with the specified agent ID. * * `name:important` to find agents whose name contains `important` as a * word. @@ -139,7 +139,7 @@ public interface SearchAgentsRequestOrBuilder * * Examples: * - * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:reasoningEngines:1234"` + * * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:aiplatform:reasoningEngines:1234"` * to find the agent with the specified agent ID. * * `name:important` to find agents whose name contains `important` as a * word. diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsRequest.java new file mode 100644 index 000000000000..fd21f32ec10f --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsRequest.java @@ -0,0 +1,1826 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Requesting a deep search of Skills.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.SearchSkillsRequest} + */ +@com.google.protobuf.Generated +public final class SearchSkillsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.SearchSkillsRequest) + SearchSkillsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SearchSkillsRequest"); + } + + // Use SearchSkillsRequest.newBuilder() to construct. + private SearchSkillsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private SearchSkillsRequest() { + parent_ = ""; + searchType_ = 0; + searchString_ = ""; + filter_ = ""; + pageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_SearchSkillsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_SearchSkillsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.SearchSkillsRequest.class, + com.google.cloud.agentregistry.v1.SearchSkillsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. Parent value for SearchSkillsRequest. Format:
+   * `projects/{project}/locations/{location}`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. Parent value for SearchSkillsRequest. Format:
+   * `projects/{project}/locations/{location}`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SEARCH_TYPE_FIELD_NUMBER = 6; + private int searchType_ = 0; + + /** + * + * + *
+   * Optional. The type of search.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SearchType search_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for searchType. + */ + @java.lang.Override + public int getSearchTypeValue() { + return searchType_; + } + + /** + * + * + *
+   * Optional. The type of search.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SearchType search_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The searchType. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SearchType getSearchType() { + com.google.cloud.agentregistry.v1.SearchType result = + com.google.cloud.agentregistry.v1.SearchType.forNumber(searchType_); + return result == null ? com.google.cloud.agentregistry.v1.SearchType.UNRECOGNIZED : result; + } + + public static final int SEARCH_STRING_FIELD_NUMBER = 7; + + @SuppressWarnings("serial") + private volatile java.lang.Object searchString_ = ""; + + /** + * + * + *
+   * Optional. Search criteria used to select the Skills to return. If no search
+   * criteria is specified then all accessible Skills will be returned.
+   *
+   * Search expressions can be used to restrict results based upon searchable
+   * fields, where the operators can be used along with the suffix wildcard
+   * symbol `*`. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `:`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * Searchable fields:
+   *
+   * | Field                     | `=` | `:` | `*` | Keyword Search |
+   * |---------------------------|-----|-----|-----|----------------|
+   * | skillId                   | Yes | Yes | Yes | Included       |
+   * | name                      | No  | Yes | Yes | Included       |
+   * | displayName               | No  | Yes | Yes | Included       |
+   * | description               | No  | Yes | No  | Included       |
+   * | frontmatter.name          | No  | Yes | No  | Included       |
+   * | frontmatter.description   | No  | Yes | No  | Included       |
+   * | frontmatter.compatibility | No  | Yes | No  | Included       |
+   * | frontmatter.license       | No  | Yes | No  | Included       |
+   *
+   * Examples:
+   *
+   * * `skillId="urn:skill:projects-1234:locations:global:private-important-skill"`
+   * to find the skill with the specified skill ID.
+   * * `name:important` to find skills whose name contains `important` as a
+   * word.
+   * * `displayName:works*` to find skills whose display name contains words
+   * that start with `works`.
+   * 
+ * + * string search_string = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The searchString. + */ + @java.lang.Override + public java.lang.String getSearchString() { + java.lang.Object ref = searchString_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + searchString_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Search criteria used to select the Skills to return. If no search
+   * criteria is specified then all accessible Skills will be returned.
+   *
+   * Search expressions can be used to restrict results based upon searchable
+   * fields, where the operators can be used along with the suffix wildcard
+   * symbol `*`. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `:`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * Searchable fields:
+   *
+   * | Field                     | `=` | `:` | `*` | Keyword Search |
+   * |---------------------------|-----|-----|-----|----------------|
+   * | skillId                   | Yes | Yes | Yes | Included       |
+   * | name                      | No  | Yes | Yes | Included       |
+   * | displayName               | No  | Yes | Yes | Included       |
+   * | description               | No  | Yes | No  | Included       |
+   * | frontmatter.name          | No  | Yes | No  | Included       |
+   * | frontmatter.description   | No  | Yes | No  | Included       |
+   * | frontmatter.compatibility | No  | Yes | No  | Included       |
+   * | frontmatter.license       | No  | Yes | No  | Included       |
+   *
+   * Examples:
+   *
+   * * `skillId="urn:skill:projects-1234:locations:global:private-important-skill"`
+   * to find the skill with the specified skill ID.
+   * * `name:important` to find skills whose name contains `important` as a
+   * word.
+   * * `displayName:works*` to find skills whose display name contains words
+   * that start with `works`.
+   * 
+ * + * string search_string = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for searchString. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSearchStringBytes() { + java.lang.Object ref = searchString_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + searchString_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object filter_ = ""; + + /** + * + * + *
+   * Optional. Use this field to specify additional filter criteria on search
+   * results. Filter expressions can be used to restrict results based upon
+   * filterable fields, where equality operators can be used. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * | Field        | `=` | `<`, `>` |
+   * |--------------|-----|----------|
+   * | state        | Yes | No       |
+   * | targetState  | Yes | No       |
+   * | createTime   | Yes | Yes      |
+   * | updateTime   | Yes | Yes      |
+   *
+   * Examples:
+   *
+   * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+   * 
+ * + * string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Use this field to specify additional filter criteria on search
+   * results. Filter expressions can be used to restrict results based upon
+   * filterable fields, where equality operators can be used. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * | Field        | `=` | `<`, `>` |
+   * |--------------|-----|----------|
+   * | state        | Yes | No       |
+   * | targetState  | Yes | No       |
+   * | createTime   | Yes | Yes      |
+   * | updateTime   | Yes | Yes      |
+   *
+   * Examples:
+   *
+   * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+   * 
+ * + * string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 3; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. The maximum number of search results to return per page. The page
+   * size is capped at `100`, even if a larger value is specified. A negative
+   * value will result in an `INVALID_ARGUMENT` error. If unspecified or set to
+   * `0`, a default value of `20` will be used. The server may return fewer
+   * results than requested.
+   * 
+ * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. If present, retrieve the next batch of results from the preceding
+   * call to this method. `page_token` must be the value of `next_page_token`
+   * from the previous response. The values of all other method parameters, must
+   * be identical to those in the previous call.
+   * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. If present, retrieve the next batch of results from the preceding
+   * call to this method. `page_token` must be the value of `next_page_token`
+   * from the previous response. The values of all other method parameters, must
+   * be identical to those in the previous call.
+   * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(3, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, filter_); + } + if (searchType_ + != com.google.cloud.agentregistry.v1.SearchType.SEARCH_TYPE_UNSPECIFIED.getNumber()) { + output.writeEnum(6, searchType_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(searchString_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 7, searchString_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, filter_); + } + if (searchType_ + != com.google.cloud.agentregistry.v1.SearchType.SEARCH_TYPE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(6, searchType_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(searchString_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(7, searchString_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.SearchSkillsRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.SearchSkillsRequest other = + (com.google.cloud.agentregistry.v1.SearchSkillsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (searchType_ != other.searchType_) return false; + if (!getSearchString().equals(other.getSearchString())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + SEARCH_TYPE_FIELD_NUMBER; + hash = (53 * hash) + searchType_; + hash = (37 * hash) + SEARCH_STRING_FIELD_NUMBER; + hash = (53 * hash) + getSearchString().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.SearchSkillsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Requesting a deep search of Skills.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.SearchSkillsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.SearchSkillsRequest) + com.google.cloud.agentregistry.v1.SearchSkillsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_SearchSkillsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_SearchSkillsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.SearchSkillsRequest.class, + com.google.cloud.agentregistry.v1.SearchSkillsRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.SearchSkillsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + searchType_ = 0; + searchString_ = ""; + filter_ = ""; + pageSize_ = 0; + pageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_SearchSkillsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SearchSkillsRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.SearchSkillsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SearchSkillsRequest build() { + com.google.cloud.agentregistry.v1.SearchSkillsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SearchSkillsRequest buildPartial() { + com.google.cloud.agentregistry.v1.SearchSkillsRequest result = + new com.google.cloud.agentregistry.v1.SearchSkillsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.SearchSkillsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.searchType_ = searchType_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.searchString_ = searchString_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.filter_ = filter_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.pageToken_ = pageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.SearchSkillsRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.SearchSkillsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.SearchSkillsRequest other) { + if (other == com.google.cloud.agentregistry.v1.SearchSkillsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.searchType_ != 0) { + setSearchTypeValue(other.getSearchTypeValue()); + } + if (!other.getSearchString().isEmpty()) { + searchString_ = other.searchString_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000020; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 24: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000010; + break; + } // case 24 + case 34: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000020; + break; + } // case 34 + case 42: + { + filter_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 42 + case 48: + { + searchType_ = input.readEnum(); + bitField0_ |= 0x00000002; + break; + } // case 48 + case 58: + { + searchString_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 58 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. Parent value for SearchSkillsRequest. Format:
+     * `projects/{project}/locations/{location}`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. Parent value for SearchSkillsRequest. Format:
+     * `projects/{project}/locations/{location}`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. Parent value for SearchSkillsRequest. Format:
+     * `projects/{project}/locations/{location}`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value for SearchSkillsRequest. Format:
+     * `projects/{project}/locations/{location}`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Parent value for SearchSkillsRequest. Format:
+     * `projects/{project}/locations/{location}`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int searchType_ = 0; + + /** + * + * + *
+     * Optional. The type of search.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SearchType search_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for searchType. + */ + @java.lang.Override + public int getSearchTypeValue() { + return searchType_; + } + + /** + * + * + *
+     * Optional. The type of search.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SearchType search_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for searchType to set. + * @return This builder for chaining. + */ + public Builder setSearchTypeValue(int value) { + searchType_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The type of search.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SearchType search_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The searchType. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SearchType getSearchType() { + com.google.cloud.agentregistry.v1.SearchType result = + com.google.cloud.agentregistry.v1.SearchType.forNumber(searchType_); + return result == null ? com.google.cloud.agentregistry.v1.SearchType.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * Optional. The type of search.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SearchType search_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The searchType to set. + * @return This builder for chaining. + */ + public Builder setSearchType(com.google.cloud.agentregistry.v1.SearchType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000002; + searchType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The type of search.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SearchType search_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearSearchType() { + bitField0_ = (bitField0_ & ~0x00000002); + searchType_ = 0; + onChanged(); + return this; + } + + private java.lang.Object searchString_ = ""; + + /** + * + * + *
+     * Optional. Search criteria used to select the Skills to return. If no search
+     * criteria is specified then all accessible Skills will be returned.
+     *
+     * Search expressions can be used to restrict results based upon searchable
+     * fields, where the operators can be used along with the suffix wildcard
+     * symbol `*`. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `:`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * Searchable fields:
+     *
+     * | Field                     | `=` | `:` | `*` | Keyword Search |
+     * |---------------------------|-----|-----|-----|----------------|
+     * | skillId                   | Yes | Yes | Yes | Included       |
+     * | name                      | No  | Yes | Yes | Included       |
+     * | displayName               | No  | Yes | Yes | Included       |
+     * | description               | No  | Yes | No  | Included       |
+     * | frontmatter.name          | No  | Yes | No  | Included       |
+     * | frontmatter.description   | No  | Yes | No  | Included       |
+     * | frontmatter.compatibility | No  | Yes | No  | Included       |
+     * | frontmatter.license       | No  | Yes | No  | Included       |
+     *
+     * Examples:
+     *
+     * * `skillId="urn:skill:projects-1234:locations:global:private-important-skill"`
+     * to find the skill with the specified skill ID.
+     * * `name:important` to find skills whose name contains `important` as a
+     * word.
+     * * `displayName:works*` to find skills whose display name contains words
+     * that start with `works`.
+     * 
+ * + * string search_string = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The searchString. + */ + public java.lang.String getSearchString() { + java.lang.Object ref = searchString_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + searchString_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Search criteria used to select the Skills to return. If no search
+     * criteria is specified then all accessible Skills will be returned.
+     *
+     * Search expressions can be used to restrict results based upon searchable
+     * fields, where the operators can be used along with the suffix wildcard
+     * symbol `*`. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `:`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * Searchable fields:
+     *
+     * | Field                     | `=` | `:` | `*` | Keyword Search |
+     * |---------------------------|-----|-----|-----|----------------|
+     * | skillId                   | Yes | Yes | Yes | Included       |
+     * | name                      | No  | Yes | Yes | Included       |
+     * | displayName               | No  | Yes | Yes | Included       |
+     * | description               | No  | Yes | No  | Included       |
+     * | frontmatter.name          | No  | Yes | No  | Included       |
+     * | frontmatter.description   | No  | Yes | No  | Included       |
+     * | frontmatter.compatibility | No  | Yes | No  | Included       |
+     * | frontmatter.license       | No  | Yes | No  | Included       |
+     *
+     * Examples:
+     *
+     * * `skillId="urn:skill:projects-1234:locations:global:private-important-skill"`
+     * to find the skill with the specified skill ID.
+     * * `name:important` to find skills whose name contains `important` as a
+     * word.
+     * * `displayName:works*` to find skills whose display name contains words
+     * that start with `works`.
+     * 
+ * + * string search_string = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for searchString. + */ + public com.google.protobuf.ByteString getSearchStringBytes() { + java.lang.Object ref = searchString_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + searchString_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Search criteria used to select the Skills to return. If no search
+     * criteria is specified then all accessible Skills will be returned.
+     *
+     * Search expressions can be used to restrict results based upon searchable
+     * fields, where the operators can be used along with the suffix wildcard
+     * symbol `*`. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `:`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * Searchable fields:
+     *
+     * | Field                     | `=` | `:` | `*` | Keyword Search |
+     * |---------------------------|-----|-----|-----|----------------|
+     * | skillId                   | Yes | Yes | Yes | Included       |
+     * | name                      | No  | Yes | Yes | Included       |
+     * | displayName               | No  | Yes | Yes | Included       |
+     * | description               | No  | Yes | No  | Included       |
+     * | frontmatter.name          | No  | Yes | No  | Included       |
+     * | frontmatter.description   | No  | Yes | No  | Included       |
+     * | frontmatter.compatibility | No  | Yes | No  | Included       |
+     * | frontmatter.license       | No  | Yes | No  | Included       |
+     *
+     * Examples:
+     *
+     * * `skillId="urn:skill:projects-1234:locations:global:private-important-skill"`
+     * to find the skill with the specified skill ID.
+     * * `name:important` to find skills whose name contains `important` as a
+     * word.
+     * * `displayName:works*` to find skills whose display name contains words
+     * that start with `works`.
+     * 
+ * + * string search_string = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The searchString to set. + * @return This builder for chaining. + */ + public Builder setSearchString(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + searchString_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Search criteria used to select the Skills to return. If no search
+     * criteria is specified then all accessible Skills will be returned.
+     *
+     * Search expressions can be used to restrict results based upon searchable
+     * fields, where the operators can be used along with the suffix wildcard
+     * symbol `*`. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `:`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * Searchable fields:
+     *
+     * | Field                     | `=` | `:` | `*` | Keyword Search |
+     * |---------------------------|-----|-----|-----|----------------|
+     * | skillId                   | Yes | Yes | Yes | Included       |
+     * | name                      | No  | Yes | Yes | Included       |
+     * | displayName               | No  | Yes | Yes | Included       |
+     * | description               | No  | Yes | No  | Included       |
+     * | frontmatter.name          | No  | Yes | No  | Included       |
+     * | frontmatter.description   | No  | Yes | No  | Included       |
+     * | frontmatter.compatibility | No  | Yes | No  | Included       |
+     * | frontmatter.license       | No  | Yes | No  | Included       |
+     *
+     * Examples:
+     *
+     * * `skillId="urn:skill:projects-1234:locations:global:private-important-skill"`
+     * to find the skill with the specified skill ID.
+     * * `name:important` to find skills whose name contains `important` as a
+     * word.
+     * * `displayName:works*` to find skills whose display name contains words
+     * that start with `works`.
+     * 
+ * + * string search_string = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearSearchString() { + searchString_ = getDefaultInstance().getSearchString(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Search criteria used to select the Skills to return. If no search
+     * criteria is specified then all accessible Skills will be returned.
+     *
+     * Search expressions can be used to restrict results based upon searchable
+     * fields, where the operators can be used along with the suffix wildcard
+     * symbol `*`. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `:`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * Searchable fields:
+     *
+     * | Field                     | `=` | `:` | `*` | Keyword Search |
+     * |---------------------------|-----|-----|-----|----------------|
+     * | skillId                   | Yes | Yes | Yes | Included       |
+     * | name                      | No  | Yes | Yes | Included       |
+     * | displayName               | No  | Yes | Yes | Included       |
+     * | description               | No  | Yes | No  | Included       |
+     * | frontmatter.name          | No  | Yes | No  | Included       |
+     * | frontmatter.description   | No  | Yes | No  | Included       |
+     * | frontmatter.compatibility | No  | Yes | No  | Included       |
+     * | frontmatter.license       | No  | Yes | No  | Included       |
+     *
+     * Examples:
+     *
+     * * `skillId="urn:skill:projects-1234:locations:global:private-important-skill"`
+     * to find the skill with the specified skill ID.
+     * * `name:important` to find skills whose name contains `important` as a
+     * word.
+     * * `displayName:works*` to find skills whose display name contains words
+     * that start with `works`.
+     * 
+ * + * string search_string = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for searchString to set. + * @return This builder for chaining. + */ + public Builder setSearchStringBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + searchString_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + + /** + * + * + *
+     * Optional. Use this field to specify additional filter criteria on search
+     * results. Filter expressions can be used to restrict results based upon
+     * filterable fields, where equality operators can be used. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * | Field        | `=` | `<`, `>` |
+     * |--------------|-----|----------|
+     * | state        | Yes | No       |
+     * | targetState  | Yes | No       |
+     * | createTime   | Yes | Yes      |
+     * | updateTime   | Yes | Yes      |
+     *
+     * Examples:
+     *
+     * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+     * 
+ * + * string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Use this field to specify additional filter criteria on search
+     * results. Filter expressions can be used to restrict results based upon
+     * filterable fields, where equality operators can be used. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * | Field        | `=` | `<`, `>` |
+     * |--------------|-----|----------|
+     * | state        | Yes | No       |
+     * | targetState  | Yes | No       |
+     * | createTime   | Yes | Yes      |
+     * | updateTime   | Yes | Yes      |
+     *
+     * Examples:
+     *
+     * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+     * 
+ * + * string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Use this field to specify additional filter criteria on search
+     * results. Filter expressions can be used to restrict results based upon
+     * filterable fields, where equality operators can be used. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * | Field        | `=` | `<`, `>` |
+     * |--------------|-----|----------|
+     * | state        | Yes | No       |
+     * | targetState  | Yes | No       |
+     * | createTime   | Yes | Yes      |
+     * | updateTime   | Yes | Yes      |
+     *
+     * Examples:
+     *
+     * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+     * 
+ * + * string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Use this field to specify additional filter criteria on search
+     * results. Filter expressions can be used to restrict results based upon
+     * filterable fields, where equality operators can be used. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * | Field        | `=` | `<`, `>` |
+     * |--------------|-----|----------|
+     * | state        | Yes | No       |
+     * | targetState  | Yes | No       |
+     * | createTime   | Yes | Yes      |
+     * | updateTime   | Yes | Yes      |
+     *
+     * Examples:
+     *
+     * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+     * 
+ * + * string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + filter_ = getDefaultInstance().getFilter(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Use this field to specify additional filter criteria on search
+     * results. Filter expressions can be used to restrict results based upon
+     * filterable fields, where equality operators can be used. See
+     * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+     * for more details.
+     *
+     * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+     *
+     * | Field        | `=` | `<`, `>` |
+     * |--------------|-----|----------|
+     * | state        | Yes | No       |
+     * | targetState  | Yes | No       |
+     * | createTime   | Yes | Yes      |
+     * | updateTime   | Yes | Yes      |
+     *
+     * Examples:
+     *
+     * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+     * 
+ * + * string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. The maximum number of search results to return per page. The page
+     * size is capped at `100`, even if a larger value is specified. A negative
+     * value will result in an `INVALID_ARGUMENT` error. If unspecified or set to
+     * `0`, a default value of `20` will be used. The server may return fewer
+     * results than requested.
+     * 
+ * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. The maximum number of search results to return per page. The page
+     * size is capped at `100`, even if a larger value is specified. A negative
+     * value will result in an `INVALID_ARGUMENT` error. If unspecified or set to
+     * `0`, a default value of `20` will be used. The server may return fewer
+     * results than requested.
+     * 
+ * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The maximum number of search results to return per page. The page
+     * size is capped at `100`, even if a larger value is specified. A negative
+     * value will result in an `INVALID_ARGUMENT` error. If unspecified or set to
+     * `0`, a default value of `20` will be used. The server may return fewer
+     * results than requested.
+     * 
+ * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000010); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. If present, retrieve the next batch of results from the preceding
+     * call to this method. `page_token` must be the value of `next_page_token`
+     * from the previous response. The values of all other method parameters, must
+     * be identical to those in the previous call.
+     * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. If present, retrieve the next batch of results from the preceding
+     * call to this method. `page_token` must be the value of `next_page_token`
+     * from the previous response. The values of all other method parameters, must
+     * be identical to those in the previous call.
+     * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. If present, retrieve the next batch of results from the preceding
+     * call to this method. `page_token` must be the value of `next_page_token`
+     * from the previous response. The values of all other method parameters, must
+     * be identical to those in the previous call.
+     * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. If present, retrieve the next batch of results from the preceding
+     * call to this method. `page_token` must be the value of `next_page_token`
+     * from the previous response. The values of all other method parameters, must
+     * be identical to those in the previous call.
+     * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000020); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. If present, retrieve the next batch of results from the preceding
+     * call to this method. `page_token` must be the value of `next_page_token`
+     * from the previous response. The values of all other method parameters, must
+     * be identical to those in the previous call.
+     * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.SearchSkillsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.SearchSkillsRequest) + private static final com.google.cloud.agentregistry.v1.SearchSkillsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.SearchSkillsRequest(); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SearchSkillsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SearchSkillsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsRequestOrBuilder.java new file mode 100644 index 000000000000..829d0e9e01f3 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsRequestOrBuilder.java @@ -0,0 +1,287 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface SearchSkillsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.SearchSkillsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Parent value for SearchSkillsRequest. Format:
+   * `projects/{project}/locations/{location}`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. Parent value for SearchSkillsRequest. Format:
+   * `projects/{project}/locations/{location}`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. The type of search.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SearchType search_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for searchType. + */ + int getSearchTypeValue(); + + /** + * + * + *
+   * Optional. The type of search.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SearchType search_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The searchType. + */ + com.google.cloud.agentregistry.v1.SearchType getSearchType(); + + /** + * + * + *
+   * Optional. Search criteria used to select the Skills to return. If no search
+   * criteria is specified then all accessible Skills will be returned.
+   *
+   * Search expressions can be used to restrict results based upon searchable
+   * fields, where the operators can be used along with the suffix wildcard
+   * symbol `*`. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `:`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * Searchable fields:
+   *
+   * | Field                     | `=` | `:` | `*` | Keyword Search |
+   * |---------------------------|-----|-----|-----|----------------|
+   * | skillId                   | Yes | Yes | Yes | Included       |
+   * | name                      | No  | Yes | Yes | Included       |
+   * | displayName               | No  | Yes | Yes | Included       |
+   * | description               | No  | Yes | No  | Included       |
+   * | frontmatter.name          | No  | Yes | No  | Included       |
+   * | frontmatter.description   | No  | Yes | No  | Included       |
+   * | frontmatter.compatibility | No  | Yes | No  | Included       |
+   * | frontmatter.license       | No  | Yes | No  | Included       |
+   *
+   * Examples:
+   *
+   * * `skillId="urn:skill:projects-1234:locations:global:private-important-skill"`
+   * to find the skill with the specified skill ID.
+   * * `name:important` to find skills whose name contains `important` as a
+   * word.
+   * * `displayName:works*` to find skills whose display name contains words
+   * that start with `works`.
+   * 
+ * + * string search_string = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The searchString. + */ + java.lang.String getSearchString(); + + /** + * + * + *
+   * Optional. Search criteria used to select the Skills to return. If no search
+   * criteria is specified then all accessible Skills will be returned.
+   *
+   * Search expressions can be used to restrict results based upon searchable
+   * fields, where the operators can be used along with the suffix wildcard
+   * symbol `*`. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `:`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * Searchable fields:
+   *
+   * | Field                     | `=` | `:` | `*` | Keyword Search |
+   * |---------------------------|-----|-----|-----|----------------|
+   * | skillId                   | Yes | Yes | Yes | Included       |
+   * | name                      | No  | Yes | Yes | Included       |
+   * | displayName               | No  | Yes | Yes | Included       |
+   * | description               | No  | Yes | No  | Included       |
+   * | frontmatter.name          | No  | Yes | No  | Included       |
+   * | frontmatter.description   | No  | Yes | No  | Included       |
+   * | frontmatter.compatibility | No  | Yes | No  | Included       |
+   * | frontmatter.license       | No  | Yes | No  | Included       |
+   *
+   * Examples:
+   *
+   * * `skillId="urn:skill:projects-1234:locations:global:private-important-skill"`
+   * to find the skill with the specified skill ID.
+   * * `name:important` to find skills whose name contains `important` as a
+   * word.
+   * * `displayName:works*` to find skills whose display name contains words
+   * that start with `works`.
+   * 
+ * + * string search_string = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for searchString. + */ + com.google.protobuf.ByteString getSearchStringBytes(); + + /** + * + * + *
+   * Optional. Use this field to specify additional filter criteria on search
+   * results. Filter expressions can be used to restrict results based upon
+   * filterable fields, where equality operators can be used. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * | Field        | `=` | `<`, `>` |
+   * |--------------|-----|----------|
+   * | state        | Yes | No       |
+   * | targetState  | Yes | No       |
+   * | createTime   | Yes | Yes      |
+   * | updateTime   | Yes | Yes      |
+   *
+   * Examples:
+   *
+   * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+   * 
+ * + * string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
+   * Optional. Use this field to specify additional filter criteria on search
+   * results. Filter expressions can be used to restrict results based upon
+   * filterable fields, where equality operators can be used. See
+   * [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools)
+   * for more details.
+   *
+   * Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`.
+   *
+   * | Field        | `=` | `<`, `>` |
+   * |--------------|-----|----------|
+   * | state        | Yes | No       |
+   * | targetState  | Yes | No       |
+   * | createTime   | Yes | Yes      |
+   * | updateTime   | Yes | Yes      |
+   *
+   * Examples:
+   *
+   * * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state.
+   * 
+ * + * string filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
+   * Optional. The maximum number of search results to return per page. The page
+   * size is capped at `100`, even if a larger value is specified. A negative
+   * value will result in an `INVALID_ARGUMENT` error. If unspecified or set to
+   * `0`, a default value of `20` will be used. The server may return fewer
+   * results than requested.
+   * 
+ * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. If present, retrieve the next batch of results from the preceding
+   * call to this method. `page_token` must be the value of `next_page_token`
+   * from the previous response. The values of all other method parameters, must
+   * be identical to those in the previous call.
+   * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. If present, retrieve the next batch of results from the preceding
+   * call to this method. `page_token` must be the value of `next_page_token`
+   * from the previous response. The values of all other method parameters, must
+   * be identical to those in the previous call.
+   * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsResponse.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsResponse.java new file mode 100644 index 000000000000..6349906e9857 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsResponse.java @@ -0,0 +1,1111 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Response listing searched Skills.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.SearchSkillsResponse} + */ +@com.google.protobuf.Generated +public final class SearchSkillsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.SearchSkillsResponse) + SearchSkillsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SearchSkillsResponse"); + } + + // Use SearchSkillsResponse.newBuilder() to construct. + private SearchSkillsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private SearchSkillsResponse() { + skills_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_SearchSkillsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_SearchSkillsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.SearchSkillsResponse.class, + com.google.cloud.agentregistry.v1.SearchSkillsResponse.Builder.class); + } + + public static final int SKILLS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List skills_; + + /** + * + * + *
+   * Matched Skills list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + @java.lang.Override + public java.util.List getSkillsList() { + return skills_; + } + + /** + * + * + *
+   * Matched Skills list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + @java.lang.Override + public java.util.List + getSkillsOrBuilderList() { + return skills_; + } + + /** + * + * + *
+   * Matched Skills list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + @java.lang.Override + public int getSkillsCount() { + return skills_.size(); + } + + /** + * + * + *
+   * Matched Skills list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill getSkills(int index) { + return skills_.get(index); + } + + /** + * + * + *
+   * Matched Skills list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillsOrBuilder(int index) { + return skills_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * Query page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Query page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < skills_.size(); i++) { + output.writeMessage(1, skills_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < skills_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, skills_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.SearchSkillsResponse)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.SearchSkillsResponse other = + (com.google.cloud.agentregistry.v1.SearchSkillsResponse) obj; + + if (!getSkillsList().equals(other.getSkillsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getSkillsCount() > 0) { + hash = (37 * hash) + SKILLS_FIELD_NUMBER; + hash = (53 * hash) + getSkillsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.SearchSkillsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Response listing searched Skills.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.SearchSkillsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.SearchSkillsResponse) + com.google.cloud.agentregistry.v1.SearchSkillsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_SearchSkillsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_SearchSkillsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.SearchSkillsResponse.class, + com.google.cloud.agentregistry.v1.SearchSkillsResponse.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.SearchSkillsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (skillsBuilder_ == null) { + skills_ = java.util.Collections.emptyList(); + } else { + skills_ = null; + skillsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_SearchSkillsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SearchSkillsResponse getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.SearchSkillsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SearchSkillsResponse build() { + com.google.cloud.agentregistry.v1.SearchSkillsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SearchSkillsResponse buildPartial() { + com.google.cloud.agentregistry.v1.SearchSkillsResponse result = + new com.google.cloud.agentregistry.v1.SearchSkillsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.agentregistry.v1.SearchSkillsResponse result) { + if (skillsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + skills_ = java.util.Collections.unmodifiableList(skills_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.skills_ = skills_; + } else { + result.skills_ = skillsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.SearchSkillsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.SearchSkillsResponse) { + return mergeFrom((com.google.cloud.agentregistry.v1.SearchSkillsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.SearchSkillsResponse other) { + if (other == com.google.cloud.agentregistry.v1.SearchSkillsResponse.getDefaultInstance()) + return this; + if (skillsBuilder_ == null) { + if (!other.skills_.isEmpty()) { + if (skills_.isEmpty()) { + skills_ = other.skills_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureSkillsIsMutable(); + skills_.addAll(other.skills_); + } + onChanged(); + } + } else { + if (!other.skills_.isEmpty()) { + if (skillsBuilder_.isEmpty()) { + skillsBuilder_.dispose(); + skillsBuilder_ = null; + skills_ = other.skills_; + bitField0_ = (bitField0_ & ~0x00000001); + skillsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetSkillsFieldBuilder() + : null; + } else { + skillsBuilder_.addAllMessages(other.skills_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.agentregistry.v1.Skill m = + input.readMessage( + com.google.cloud.agentregistry.v1.Skill.parser(), extensionRegistry); + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + skills_.add(m); + } else { + skillsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List skills_ = + java.util.Collections.emptyList(); + + private void ensureSkillsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + skills_ = new java.util.ArrayList(skills_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder> + skillsBuilder_; + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public java.util.List getSkillsList() { + if (skillsBuilder_ == null) { + return java.util.Collections.unmodifiableList(skills_); + } else { + return skillsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public int getSkillsCount() { + if (skillsBuilder_ == null) { + return skills_.size(); + } else { + return skillsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public com.google.cloud.agentregistry.v1.Skill getSkills(int index) { + if (skillsBuilder_ == null) { + return skills_.get(index); + } else { + return skillsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder setSkills(int index, com.google.cloud.agentregistry.v1.Skill value) { + if (skillsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSkillsIsMutable(); + skills_.set(index, value); + onChanged(); + } else { + skillsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder setSkills( + int index, com.google.cloud.agentregistry.v1.Skill.Builder builderForValue) { + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + skills_.set(index, builderForValue.build()); + onChanged(); + } else { + skillsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder addSkills(com.google.cloud.agentregistry.v1.Skill value) { + if (skillsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSkillsIsMutable(); + skills_.add(value); + onChanged(); + } else { + skillsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder addSkills(int index, com.google.cloud.agentregistry.v1.Skill value) { + if (skillsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSkillsIsMutable(); + skills_.add(index, value); + onChanged(); + } else { + skillsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder addSkills(com.google.cloud.agentregistry.v1.Skill.Builder builderForValue) { + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + skills_.add(builderForValue.build()); + onChanged(); + } else { + skillsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder addSkills( + int index, com.google.cloud.agentregistry.v1.Skill.Builder builderForValue) { + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + skills_.add(index, builderForValue.build()); + onChanged(); + } else { + skillsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder addAllSkills( + java.lang.Iterable values) { + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, skills_); + onChanged(); + } else { + skillsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder clearSkills() { + if (skillsBuilder_ == null) { + skills_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + skillsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public Builder removeSkills(int index) { + if (skillsBuilder_ == null) { + ensureSkillsIsMutable(); + skills_.remove(index); + onChanged(); + } else { + skillsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public com.google.cloud.agentregistry.v1.Skill.Builder getSkillsBuilder(int index) { + return internalGetSkillsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillsOrBuilder(int index) { + if (skillsBuilder_ == null) { + return skills_.get(index); + } else { + return skillsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public java.util.List + getSkillsOrBuilderList() { + if (skillsBuilder_ != null) { + return skillsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(skills_); + } + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public com.google.cloud.agentregistry.v1.Skill.Builder addSkillsBuilder() { + return internalGetSkillsFieldBuilder() + .addBuilder(com.google.cloud.agentregistry.v1.Skill.getDefaultInstance()); + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public com.google.cloud.agentregistry.v1.Skill.Builder addSkillsBuilder(int index) { + return internalGetSkillsFieldBuilder() + .addBuilder(index, com.google.cloud.agentregistry.v1.Skill.getDefaultInstance()); + } + + /** + * + * + *
+     * Matched Skills list.
+     * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + public java.util.List getSkillsBuilderList() { + return internalGetSkillsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder> + internalGetSkillsFieldBuilder() { + if (skillsBuilder_ == null) { + skillsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder>( + skills_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + skills_ = null; + } + return skillsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * Query page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Query page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Query page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Query page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Query page offset continuation token.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.SearchSkillsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.SearchSkillsResponse) + private static final com.google.cloud.agentregistry.v1.SearchSkillsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.SearchSkillsResponse(); + } + + public static com.google.cloud.agentregistry.v1.SearchSkillsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SearchSkillsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SearchSkillsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsResponseOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsResponseOrBuilder.java new file mode 100644 index 000000000000..2b9c6de766ec --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchSkillsResponseOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface SearchSkillsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.SearchSkillsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Matched Skills list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + java.util.List getSkillsList(); + + /** + * + * + *
+   * Matched Skills list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + com.google.cloud.agentregistry.v1.Skill getSkills(int index); + + /** + * + * + *
+   * Matched Skills list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + int getSkillsCount(); + + /** + * + * + *
+   * Matched Skills list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + java.util.List + getSkillsOrBuilderList(); + + /** + * + * + *
+   * Matched Skills list.
+   * 
+ * + * repeated .google.cloud.agentregistry.v1.Skill skills = 1; + */ + com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillsOrBuilder(int index); + + /** + * + * + *
+   * Query page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * Query page offset continuation token.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchType.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchType.java new file mode 100644 index 000000000000..f105253fcccc --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SearchType.java @@ -0,0 +1,194 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * The type of search to perform. Additional search types may be supported in
+ * the future.
+ * 
+ * + * Protobuf enum {@code google.cloud.agentregistry.v1.SearchType} + */ +@com.google.protobuf.Generated +public enum SearchType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * Invalid search type.
+   * 
+ * + * SEARCH_TYPE_UNSPECIFIED = 0; + */ + SEARCH_TYPE_UNSPECIFIED(0), + /** + * + * + *
+   * Search for a keyword across all searchable fields.
+   * 
+ * + * KEYWORD = 1; + */ + KEYWORD(1), + /** + * + * + *
+   * Search based on the meaning and intent of a natural language query.
+   * 
+ * + * SEMANTIC = 2; + */ + SEMANTIC(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SearchType"); + } + + /** + * + * + *
+   * Invalid search type.
+   * 
+ * + * SEARCH_TYPE_UNSPECIFIED = 0; + */ + public static final int SEARCH_TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+   * Search for a keyword across all searchable fields.
+   * 
+ * + * KEYWORD = 1; + */ + public static final int KEYWORD_VALUE = 1; + + /** + * + * + *
+   * Search based on the meaning and intent of a natural language query.
+   * 
+ * + * SEMANTIC = 2; + */ + public static final int SEMANTIC_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static SearchType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static SearchType forNumber(int value) { + switch (value) { + case 0: + return SEARCH_TYPE_UNSPECIFIED; + case 1: + return KEYWORD; + case 2: + return SEMANTIC; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public SearchType findValueByNumber(int number) { + return SearchType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final SearchType[] VALUES = values(); + + public static SearchType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private SearchType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.agentregistry.v1.SearchType) +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Service.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Service.java index f35c7b22cb73..3bf7929d0f57 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Service.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Service.java @@ -83,11 +83,11 @@ public interface AgentSpecOrBuilder * * *
-     * Required. The type of the agent spec content.
+     * Required. Immutable. The type of the agent spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The enum numeric value on the wire for type. @@ -98,11 +98,11 @@ public interface AgentSpecOrBuilder * * *
-     * Required. The type of the agent spec content.
+     * Required. Immutable. The type of the agent spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The type. @@ -383,11 +383,11 @@ private Type(int value) { * * *
-     * Required. The type of the agent spec content.
+     * Required. Immutable. The type of the agent spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The enum numeric value on the wire for type. @@ -401,11 +401,11 @@ public int getTypeValue() { * * *
-     * Required. The type of the agent spec content.
+     * Required. Immutable. The type of the agent spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The type. @@ -837,11 +837,11 @@ public Builder mergeFrom( * * *
-       * Required. The type of the agent spec content.
+       * Required. Immutable. The type of the agent spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The enum numeric value on the wire for type. @@ -855,11 +855,11 @@ public int getTypeValue() { * * *
-       * Required. The type of the agent spec content.
+       * Required. Immutable. The type of the agent spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @param value The enum numeric value on the wire for type to set. @@ -876,11 +876,11 @@ public Builder setTypeValue(int value) { * * *
-       * Required. The type of the agent spec content.
+       * Required. Immutable. The type of the agent spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The type. @@ -898,11 +898,11 @@ public com.google.cloud.agentregistry.v1.Service.AgentSpec.Type getType() { * * *
-       * Required. The type of the agent spec content.
+       * Required. Immutable. The type of the agent spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @param value The type to set. @@ -922,11 +922,11 @@ public Builder setType(com.google.cloud.agentregistry.v1.Service.AgentSpec.Type * * *
-       * Required. The type of the agent spec content.
+       * Required. Immutable. The type of the agent spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.AgentSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return This builder for chaining. @@ -1207,11 +1207,11 @@ public interface McpServerSpecOrBuilder * * *
-     * Required. The type of the MCP Server spec content.
+     * Required. Immutable. The type of the MCP Server spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The enum numeric value on the wire for type. @@ -1222,11 +1222,11 @@ public interface McpServerSpecOrBuilder * * *
-     * Required. The type of the MCP Server spec content.
+     * Required. Immutable. The type of the MCP Server spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The type. @@ -1330,7 +1330,8 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
-     * The type of the MCP Server spec.
+     * The type of the MCP Server spec. Additional values may be added in the
+     * future.
      * 
* * Protobuf enum {@code google.cloud.agentregistry.v1.Service.McpServerSpec.Type} @@ -1507,11 +1508,11 @@ private Type(int value) { * * *
-     * Required. The type of the MCP Server spec content.
+     * Required. Immutable. The type of the MCP Server spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The enum numeric value on the wire for type. @@ -1525,11 +1526,11 @@ public int getTypeValue() { * * *
-     * Required. The type of the MCP Server spec content.
+     * Required. Immutable. The type of the MCP Server spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The type. @@ -1961,11 +1962,11 @@ public Builder mergeFrom( * * *
-       * Required. The type of the MCP Server spec content.
+       * Required. Immutable. The type of the MCP Server spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The enum numeric value on the wire for type. @@ -1979,11 +1980,11 @@ public int getTypeValue() { * * *
-       * Required. The type of the MCP Server spec content.
+       * Required. Immutable. The type of the MCP Server spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @param value The enum numeric value on the wire for type to set. @@ -2000,11 +2001,11 @@ public Builder setTypeValue(int value) { * * *
-       * Required. The type of the MCP Server spec content.
+       * Required. Immutable. The type of the MCP Server spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The type. @@ -2022,11 +2023,11 @@ public com.google.cloud.agentregistry.v1.Service.McpServerSpec.Type getType() { * * *
-       * Required. The type of the MCP Server spec content.
+       * Required. Immutable. The type of the MCP Server spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @param value The type to set. @@ -2046,11 +2047,11 @@ public Builder setType(com.google.cloud.agentregistry.v1.Service.McpServerSpec.T * * *
-       * Required. The type of the MCP Server spec content.
+       * Required. Immutable. The type of the MCP Server spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.McpServerSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return This builder for chaining. @@ -2331,11 +2332,11 @@ public interface EndpointSpecOrBuilder * * *
-     * Required. The type of the endpoint spec content.
+     * Required. Immutable. The type of the endpoint spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The enum numeric value on the wire for type. @@ -2346,11 +2347,11 @@ public interface EndpointSpecOrBuilder * * *
-     * Required. The type of the endpoint spec content.
+     * Required. Immutable. The type of the endpoint spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The type. @@ -2451,7 +2452,8 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
-     * The type of the endpoint spec.
+     * The type of the endpoint spec. Additional values may be added in the
+     * future.
      * 
* * Protobuf enum {@code google.cloud.agentregistry.v1.Service.EndpointSpec.Type} @@ -2603,11 +2605,11 @@ private Type(int value) { * * *
-     * Required. The type of the endpoint spec content.
+     * Required. Immutable. The type of the endpoint spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The enum numeric value on the wire for type. @@ -2621,11 +2623,11 @@ public int getTypeValue() { * * *
-     * Required. The type of the endpoint spec content.
+     * Required. Immutable. The type of the endpoint spec content.
      * 
* * - * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The type. @@ -3054,11 +3056,11 @@ public Builder mergeFrom( * * *
-       * Required. The type of the endpoint spec content.
+       * Required. Immutable. The type of the endpoint spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The enum numeric value on the wire for type. @@ -3072,11 +3074,11 @@ public int getTypeValue() { * * *
-       * Required. The type of the endpoint spec content.
+       * Required. Immutable. The type of the endpoint spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @param value The enum numeric value on the wire for type to set. @@ -3093,11 +3095,11 @@ public Builder setTypeValue(int value) { * * *
-       * Required. The type of the endpoint spec content.
+       * Required. Immutable. The type of the endpoint spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return The type. @@ -3115,11 +3117,11 @@ public com.google.cloud.agentregistry.v1.Service.EndpointSpec.Type getType() { * * *
-       * Required. The type of the endpoint spec content.
+       * Required. Immutable. The type of the endpoint spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @param value The type to set. @@ -3139,11 +3141,11 @@ public Builder setType(com.google.cloud.agentregistry.v1.Service.EndpointSpec.Ty * * *
-       * Required. The type of the endpoint spec content.
+       * Required. Immutable. The type of the endpoint spec content.
        * 
* * - * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.agentregistry.v1.Service.EndpointSpec.Type type = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; * * * @return This builder for chaining. diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ServiceProto.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ServiceProto.java index 11b5a5a22249..a45803d500ec 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ServiceProto.java +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/ServiceProto.java @@ -71,7 +71,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ogle/api/field_behavior.proto\032\031google/ap" + "i/resource.proto\032.google/cloud/agentregi" + "stry/v1/properties.proto\032\034google/protobu" - + "f/struct.proto\032\037google/protobuf/timestamp.proto\"\357\t\n" + + "f/struct.proto\032\037google/protobuf/timestamp.proto\"\362\t\n" + "\007Service\022L\n\n" + "agent_spec\030\005 \001(\0132" + "0.google.cloud.agentregistry.v1.Service.AgentSpecB\004\342A\001\001H\000\022U\n" @@ -89,36 +89,36 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013create_time\030\010" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\t" - + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\032\305\001\n" - + "\tAgentSpec\022I\n" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\032\306\001\n" + + "\tAgentSpec\022J\n" + "\004type\030\001 \001(\01625.google.cloud.ag" - + "entregistry.v1.Service.AgentSpec.TypeB\004\342A\001\002\022.\n" + + "entregistry.v1.Service.AgentSpec.TypeB\005\342A\002\002\005\022.\n" + "\007content\030\002 \001(\0132\027.google.protobuf.StructB\004\342A\001\001\"=\n" + "\004Type\022\024\n" + "\020TYPE_UNSPECIFIED\020\000\022\013\n" + "\007NO_SPEC\020\001\022\022\n" - + "\016A2A_AGENT_CARD\020\002\032\310\001\n\r" - + "McpServerSpec\022M\n" - + "\004type\030\001 \001(\01629.google.clou" - + "d.agentregistry.v1.Service.McpServerSpec.TypeB\004\342A\001\002\022.\n" + + "\016A2A_AGENT_CARD\020\002\032\311\001\n\r" + + "McpServerSpec\022N\n" + + "\004type\030\001 \001(\01629.google.clo" + + "ud.agentregistry.v1.Service.McpServerSpec.TypeB\005\342A\002\002\005\022.\n" + "\007content\030\002 \001(\0132\027.google.protobuf.StructB\004\342A\001\001\"8\n" + "\004Type\022\024\n" + "\020TYPE_UNSPECIFIED\020\000\022\013\n" + "\007NO_SPEC\020\001\022\r\n" - + "\tTOOL_SPEC\020\002\032\267\001\n" - + "\014EndpointSpec\022L\n" - + "\004type\030\001 \001(\01628.google.cl" - + "oud.agentregistry.v1.Service.EndpointSpec.TypeB\004\342A\001\002\022.\n" + + "\tTOOL_SPEC\020\002\032\270\001\n" + + "\014EndpointSpec\022M\n" + + "\004type\030\001 \001(\01628.google." + + "cloud.agentregistry.v1.Service.EndpointSpec.TypeB\005\342A\002\002\005\022.\n" + "\007content\030\002 \001(\0132\027.google.protobuf.StructB\004\342A\001\001\")\n" + "\004Type\022\024\n" + "\020TYPE_UNSPECIFIED\020\000\022\013\n" + "\007NO_SPEC\020\001:x\352Au\n" - + "$agentregistry.googleapis.com/Service\022:projects/{pr" - + "oject}/locations/{location}/services/{service}*\010services2\007serviceB\006\n" + + "$agentregistry.googleapis.com/Service\022:projects/" + + "{project}/locations/{location}/services/{service}*\010services2\007serviceB\006\n" + "\004specB\337\001\n" - + "!com.google.cloud.agentregistry.v1B\014Service" - + "ProtoP\001ZGcloud.google.com/go/agentregistry/apiv1/agentregistrypb;agentregistrypb" - + "\252\002\035Google.Cloud.AgentRegistry.V1\312\002\035Google\\Cloud\\AgentRegistry\\V1\352\002" + + "!com.google.cloud.agentregistry.v1B\014ServiceProtoP\001ZGcloud.google.com/go/agentreg" + + "istry/apiv1/agentregistrypb;agentregistr" + + "ypb\252\002\035Google.Cloud.AgentRegistry.V1\312\002\035Google\\Cloud\\AgentRegistry\\V1\352\002" + " Google::Cloud::AgentRegistry::V1b\006proto3" }; descriptor = diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Severity.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Severity.java new file mode 100644 index 000000000000..f359f950e58a --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Severity.java @@ -0,0 +1,239 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/finding.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * The severity of the finding.
+ * 
+ * + * Protobuf enum {@code google.cloud.agentregistry.v1.Severity} + */ +@com.google.protobuf.Generated +public enum Severity implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * This value is used for findings when a source doesn't write a severity
+   * value.
+   * 
+ * + * SEVERITY_UNSPECIFIED = 0; + */ + SEVERITY_UNSPECIFIED(0), + /** + * + * + *
+   * Critical severity.
+   * 
+ * + * SEVERITY_CRITICAL = 1; + */ + SEVERITY_CRITICAL(1), + /** + * + * + *
+   * High severity.
+   * 
+ * + * SEVERITY_HIGH = 2; + */ + SEVERITY_HIGH(2), + /** + * + * + *
+   * Medium severity.
+   * 
+ * + * SEVERITY_MEDIUM = 3; + */ + SEVERITY_MEDIUM(3), + /** + * + * + *
+   * Low severity.
+   * 
+ * + * SEVERITY_LOW = 4; + */ + SEVERITY_LOW(4), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Severity"); + } + + /** + * + * + *
+   * This value is used for findings when a source doesn't write a severity
+   * value.
+   * 
+ * + * SEVERITY_UNSPECIFIED = 0; + */ + public static final int SEVERITY_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+   * Critical severity.
+   * 
+ * + * SEVERITY_CRITICAL = 1; + */ + public static final int SEVERITY_CRITICAL_VALUE = 1; + + /** + * + * + *
+   * High severity.
+   * 
+ * + * SEVERITY_HIGH = 2; + */ + public static final int SEVERITY_HIGH_VALUE = 2; + + /** + * + * + *
+   * Medium severity.
+   * 
+ * + * SEVERITY_MEDIUM = 3; + */ + public static final int SEVERITY_MEDIUM_VALUE = 3; + + /** + * + * + *
+   * Low severity.
+   * 
+ * + * SEVERITY_LOW = 4; + */ + public static final int SEVERITY_LOW_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Severity valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static Severity forNumber(int value) { + switch (value) { + case 0: + return SEVERITY_UNSPECIFIED; + case 1: + return SEVERITY_CRITICAL; + case 2: + return SEVERITY_HIGH; + case 3: + return SEVERITY_MEDIUM; + case 4: + return SEVERITY_LOW; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Severity findValueByNumber(int number) { + return Severity.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.FindingProto.getDescriptor().getEnumTypes().get(0); + } + + private static final Severity[] VALUES = values(); + + public static Severity valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Severity(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.agentregistry.v1.Severity) +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Skill.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Skill.java new file mode 100644 index 000000000000..04bf681cd383 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/Skill.java @@ -0,0 +1,4654 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Represents an Executable Agent Skill or a Composite Tool Suite (Bundle).
+ * Sibling resource with Agent and McpServer under agentregistry.googleapis.com.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.Skill} + */ +@com.google.protobuf.Generated +public final class Skill extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.Skill) + SkillOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Skill"); + } + + // Use Skill.newBuilder() to construct. + private Skill(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Skill() { + name_ = ""; + uid_ = ""; + displayName_ = ""; + description_ = ""; + type_ = 0; + state_ = 0; + targetState_ = 0; + defaultRevision_ = ""; + skillId_ = ""; + publisher_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Skill_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Skill_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.Skill.class, + com.google.cloud.agentregistry.v1.Skill.Builder.class); + } + + /** + * + * + *
+   * The structural type of the Skill.
+   * 
+ * + * Protobuf enum {@code google.cloud.agentregistry.v1.Skill.Type} + */ + public enum Type implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * TYPE_UNSPECIFIED = 0; + */ + TYPE_UNSPECIFIED(0), + /** + * + * + *
+     * A standard, leaf executable skill containing natural language and code.
+     * 
+ * + * SIMPLE = 1; + */ + SIMPLE(1), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Type"); + } + + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * TYPE_UNSPECIFIED = 0; + */ + public static final int TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * A standard, leaf executable skill containing natural language and code.
+     * 
+ * + * SIMPLE = 1; + */ + public static final int SIMPLE_VALUE = 1; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Type valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static Type forNumber(int value) { + switch (value) { + case 0: + return TYPE_UNSPECIFIED; + case 1: + return SIMPLE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Type findValueByNumber(int number) { + return Type.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.Skill.getDescriptor().getEnumTypes().get(0); + } + + private static final Type[] VALUES = values(); + + public static Type valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Type(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.agentregistry.v1.Skill.Type) + } + + /** + * + * + *
+   * System-managed state.
+   * 
+ * + * Protobuf enum {@code google.cloud.agentregistry.v1.Skill.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
+     * The skill is being created. It is not served.
+     * 
+ * + * STATE_CREATING = 1; + */ + STATE_CREATING(1), + /** + * + * + *
+     * The skill is in draft, or lacks a valid payload. It is not served.
+     * 
+ * + * STATE_DRAFT = 2; + */ + STATE_DRAFT(2), + /** + * + * + *
+     * The skill is active and is served.
+     * 
+ * + * STATE_ACTIVE = 3; + */ + STATE_ACTIVE(3), + /** + * + * + *
+     * The skill is disabled and is not served.
+     * 
+ * + * STATE_DISABLED = 4; + */ + STATE_DISABLED(4), + /** + * + * + *
+     * The skill is deprecated. It is served, but emits warnings.
+     * 
+ * + * STATE_DEPRECATED = 5; + */ + STATE_DEPRECATED(5), + /** + * + * + *
+     * The skill is decommissioned and is not served.
+     * 
+ * + * STATE_DECOMMISSIONED = 6; + */ + STATE_DECOMMISSIONED(6), + /** + * + * + *
+     * The skill is being deleted. It is not served.
+     * 
+ * + * STATE_DELETING = 7; + */ + STATE_DELETING(7), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "State"); + } + + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The skill is being created. It is not served.
+     * 
+ * + * STATE_CREATING = 1; + */ + public static final int STATE_CREATING_VALUE = 1; + + /** + * + * + *
+     * The skill is in draft, or lacks a valid payload. It is not served.
+     * 
+ * + * STATE_DRAFT = 2; + */ + public static final int STATE_DRAFT_VALUE = 2; + + /** + * + * + *
+     * The skill is active and is served.
+     * 
+ * + * STATE_ACTIVE = 3; + */ + public static final int STATE_ACTIVE_VALUE = 3; + + /** + * + * + *
+     * The skill is disabled and is not served.
+     * 
+ * + * STATE_DISABLED = 4; + */ + public static final int STATE_DISABLED_VALUE = 4; + + /** + * + * + *
+     * The skill is deprecated. It is served, but emits warnings.
+     * 
+ * + * STATE_DEPRECATED = 5; + */ + public static final int STATE_DEPRECATED_VALUE = 5; + + /** + * + * + *
+     * The skill is decommissioned and is not served.
+     * 
+ * + * STATE_DECOMMISSIONED = 6; + */ + public static final int STATE_DECOMMISSIONED_VALUE = 6; + + /** + * + * + *
+     * The skill is being deleted. It is not served.
+     * 
+ * + * STATE_DELETING = 7; + */ + public static final int STATE_DELETING_VALUE = 7; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return STATE_CREATING; + case 2: + return STATE_DRAFT; + case 3: + return STATE_ACTIVE; + case 4: + return STATE_DISABLED; + case 5: + return STATE_DEPRECATED; + case 6: + return STATE_DECOMMISSIONED; + case 7: + return STATE_DELETING; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public State findValueByNumber(int number) { + return State.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.Skill.getDescriptor().getEnumTypes().get(1); + } + + private static final State[] VALUES = values(); + + public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private State(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.agentregistry.v1.Skill.State) + } + + /** + * + * + *
+   * User-configurable target state.
+   * 
+ * + * Protobuf enum {@code google.cloud.agentregistry.v1.Skill.TargetState} + */ + public enum TargetState implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * TARGET_STATE_UNSPECIFIED = 0; + */ + TARGET_STATE_UNSPECIFIED(0), + /** + * + * + *
+     * The skill is in draft and cannot be served.
+     * 
+ * + * TARGET_STATE_DRAFT = 1; + */ + TARGET_STATE_DRAFT(1), + /** + * + * + *
+     * The skill is active and can be served.
+     * 
+ * + * TARGET_STATE_ACTIVE = 2; + */ + TARGET_STATE_ACTIVE(2), + /** + * + * + *
+     * The skill is disabled and cannot be served.
+     * 
+ * + * TARGET_STATE_DISABLED = 3; + */ + TARGET_STATE_DISABLED(3), + /** + * + * + *
+     * The skill is deprecated. It can still be served, but emits warnings.
+     * 
+ * + * TARGET_STATE_DEPRECATED = 4; + */ + TARGET_STATE_DEPRECATED(4), + /** + * + * + *
+     * The skill is decommissioned and cannot be served.
+     * 
+ * + * TARGET_STATE_DECOMMISSIONED = 5; + */ + TARGET_STATE_DECOMMISSIONED(5), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "TargetState"); + } + + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * TARGET_STATE_UNSPECIFIED = 0; + */ + public static final int TARGET_STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The skill is in draft and cannot be served.
+     * 
+ * + * TARGET_STATE_DRAFT = 1; + */ + public static final int TARGET_STATE_DRAFT_VALUE = 1; + + /** + * + * + *
+     * The skill is active and can be served.
+     * 
+ * + * TARGET_STATE_ACTIVE = 2; + */ + public static final int TARGET_STATE_ACTIVE_VALUE = 2; + + /** + * + * + *
+     * The skill is disabled and cannot be served.
+     * 
+ * + * TARGET_STATE_DISABLED = 3; + */ + public static final int TARGET_STATE_DISABLED_VALUE = 3; + + /** + * + * + *
+     * The skill is deprecated. It can still be served, but emits warnings.
+     * 
+ * + * TARGET_STATE_DEPRECATED = 4; + */ + public static final int TARGET_STATE_DEPRECATED_VALUE = 4; + + /** + * + * + *
+     * The skill is decommissioned and cannot be served.
+     * 
+ * + * TARGET_STATE_DECOMMISSIONED = 5; + */ + public static final int TARGET_STATE_DECOMMISSIONED_VALUE = 5; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static TargetState valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static TargetState forNumber(int value) { + switch (value) { + case 0: + return TARGET_STATE_UNSPECIFIED; + case 1: + return TARGET_STATE_DRAFT; + case 2: + return TARGET_STATE_ACTIVE; + case 3: + return TARGET_STATE_DISABLED; + case 4: + return TARGET_STATE_DEPRECATED; + case 5: + return TARGET_STATE_DECOMMISSIONED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public TargetState findValueByNumber(int number) { + return TargetState.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.Skill.getDescriptor().getEnumTypes().get(2); + } + + private static final TargetState[] VALUES = values(); + + public static TargetState valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private TargetState(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.agentregistry.v1.Skill.TargetState) + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Identifier. Resource name of the Skill.
+   * Format: `projects/{project}/locations/{location}/skills/{skill}`
+   * The `{skill}` segment acts as the resource ID. If the skill is associated
+   * with a Publisher, this segment typically uses a hyphenated namespace prefix
+   * corresponding to the publisher (e.g., `google-workspace-create-docs`).
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Identifier. Resource name of the Skill.
+   * Format: `projects/{project}/locations/{location}/skills/{skill}`
+   * The `{skill}` segment acts as the resource ID. If the skill is associated
+   * with a Publisher, this segment typically uses a hyphenated namespace prefix
+   * corresponding to the publisher (e.g., `google-workspace-create-docs`).
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object uid_ = ""; + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the logical
+   * container.
+   * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + @java.lang.Override + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the logical
+   * container.
+   * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object displayName_ = ""; + + /** + * + * + *
+   * Optional. Human-readable display name of the skill.
+   * Maximum length is 128 characters.
+   * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Human-readable display name of the skill.
+   * Maximum length is 128 characters.
+   * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object description_ = ""; + + /** + * + * + *
+   * Optional. Brief summary describing the capabilities of the skill.
+   * Maximum length is 2048 characters.
+   * 
+ * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Brief summary describing the capabilities of the skill.
+   * Maximum length is 2048 characters.
+   * 
+ * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TYPE_FIELD_NUMBER = 5; + private int type_ = 0; + + /** + * + * + *
+   * Required. Structural deployment type (SIMPLE leaf vs COMPOSITE bundle).
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.Type type = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + + /** + * + * + *
+   * Required. Structural deployment type (SIMPLE leaf vs COMPOSITE bundle).
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.Type type = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The type. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill.Type getType() { + com.google.cloud.agentregistry.v1.Skill.Type result = + com.google.cloud.agentregistry.v1.Skill.Type.forNumber(type_); + return result == null ? com.google.cloud.agentregistry.v1.Skill.Type.UNRECOGNIZED : result; + } + + public static final int STATE_FIELD_NUMBER = 6; + private int state_ = 0; + + /** + * + * + *
+   * Output only. The system-managed state of the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
+   * Output only. The system-managed state of the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill.State getState() { + com.google.cloud.agentregistry.v1.Skill.State result = + com.google.cloud.agentregistry.v1.Skill.State.forNumber(state_); + return result == null ? com.google.cloud.agentregistry.v1.Skill.State.UNRECOGNIZED : result; + } + + public static final int TARGET_STATE_FIELD_NUMBER = 7; + private int targetState_ = 0; + + /** + * + * + *
+   * Required. User-managed target state of the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.TargetState target_state = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for targetState. + */ + @java.lang.Override + public int getTargetStateValue() { + return targetState_; + } + + /** + * + * + *
+   * Required. User-managed target state of the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.TargetState target_state = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The targetState. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill.TargetState getTargetState() { + com.google.cloud.agentregistry.v1.Skill.TargetState result = + com.google.cloud.agentregistry.v1.Skill.TargetState.forNumber(targetState_); + return result == null + ? com.google.cloud.agentregistry.v1.Skill.TargetState.UNRECOGNIZED + : result; + } + + public static final int DEFAULT_REVISION_FIELD_NUMBER = 8; + + @SuppressWarnings("serial") + private volatile java.lang.Object defaultRevision_ = ""; + + /** + * + * + *
+   * Optional. The full resource name of the revision currently served by
+   * default (floating track).
+   * Format:
+   * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+   * 
+ * + * + * string default_revision = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The defaultRevision. + */ + @java.lang.Override + public java.lang.String getDefaultRevision() { + java.lang.Object ref = defaultRevision_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + defaultRevision_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. The full resource name of the revision currently served by
+   * default (floating track).
+   * Format:
+   * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+   * 
+ * + * + * string default_revision = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for defaultRevision. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDefaultRevisionBytes() { + java.lang.Object ref = defaultRevision_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + defaultRevision_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FRONTMATTER_FIELD_NUMBER = 9; + private com.google.cloud.agentregistry.v1.Frontmatter frontmatter_; + + /** + * + * + *
+   * Output only. Lightweight frontmatter metadata attributes copied from the
+   * default revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the frontmatter field is set. + */ + @java.lang.Override + public boolean hasFrontmatter() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Output only. Lightweight frontmatter metadata attributes copied from the
+   * default revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The frontmatter. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Frontmatter getFrontmatter() { + return frontmatter_ == null + ? com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance() + : frontmatter_; + } + + /** + * + * + *
+   * Output only. Lightweight frontmatter metadata attributes copied from the
+   * default revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.FrontmatterOrBuilder getFrontmatterOrBuilder() { + return frontmatter_ == null + ? com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance() + : frontmatter_; + } + + public static final int SKILL_ID_FIELD_NUMBER = 17; + + @SuppressWarnings("serial") + private volatile java.lang.Object skillId_ = ""; + + /** + * + * + *
+   * Output only. A stable, globally unique logical identifier for the skill.
+   * It is securely constructed by the backend by combining the associated
+   * `publisher`'s verified namespace and the skill's resource ID to enforce
+   * strict ownership. For example, the prefix `google-` is reserved exclusively
+   * for first-party Google publishers to prevent namespace squatting.
+   * Example: `urn:skill:google-workspace:create-docs`
+   * 
+ * + * string skill_id = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The skillId. + */ + @java.lang.Override + public java.lang.String getSkillId() { + java.lang.Object ref = skillId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + skillId_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. A stable, globally unique logical identifier for the skill.
+   * It is securely constructed by the backend by combining the associated
+   * `publisher`'s verified namespace and the skill's resource ID to enforce
+   * strict ownership. For example, the prefix `google-` is reserved exclusively
+   * for first-party Google publishers to prevent namespace squatting.
+   * Example: `urn:skill:google-workspace:create-docs`
+   * 
+ * + * string skill_id = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for skillId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSkillIdBytes() { + java.lang.Object ref = skillId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + skillId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 11; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 12; + private com.google.protobuf.Timestamp updateTime_; + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + public static final int PUBLISHER_FIELD_NUMBER = 15; + + @SuppressWarnings("serial") + private volatile java.lang.Object publisher_ = ""; + + /** + * + * + *
+   * Optional. The publisher resource associated with this skill.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * The publisher dictates the allowed namespace prefixes for the skill's name
+   * and logical `skill_id` (e.g., Publisher `google` authorizes the `google-*`
+   * prefix).
+   * 
+ * + * + * string publisher = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The publisher. + */ + @java.lang.Override + public java.lang.String getPublisher() { + java.lang.Object ref = publisher_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + publisher_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. The publisher resource associated with this skill.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * The publisher dictates the allowed namespace prefixes for the skill's name
+   * and logical `skill_id` (e.g., Publisher `google` authorizes the `google-*`
+   * prefix).
+   * 
+ * + * + * string publisher = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for publisher. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPublisherBytes() { + java.lang.Object ref = publisher_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + publisher_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int INITIAL_REVISION_FIELD_NUMBER = 14; + private com.google.cloud.agentregistry.v1.SkillRevision initialRevision_; + + /** + * + * + *
+   * Optional. Input only. Optional nested initial revision payload to support
+   * standard one-shot creation. The server processes this field on input during
+   * creation but must never return it in responses.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + * + * @return Whether the initialRevision field is set. + */ + @java.lang.Override + public boolean hasInitialRevision() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+   * Optional. Input only. Optional nested initial revision payload to support
+   * standard one-shot creation. The server processes this field on input during
+   * creation but must never return it in responses.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + * + * @return The initialRevision. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision getInitialRevision() { + return initialRevision_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance() + : initialRevision_; + } + + /** + * + * + *
+   * Optional. Input only. Optional nested initial revision payload to support
+   * standard one-shot creation. The server processes this field on input during
+   * creation but must never return it in responses.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder getInitialRevisionOrBuilder() { + return initialRevision_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance() + : initialRevision_; + } + + public static final int SCANNING_CONFIG_FIELD_NUMBER = 20; + private com.google.cloud.agentregistry.v1.ScanningConfig scanningConfig_; + + /** + * + * + *
+   * Optional. Optional. Scanning configuration for the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the scanningConfig field is set. + */ + @java.lang.Override + public boolean hasScanningConfig() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
+   * Optional. Optional. Scanning configuration for the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The scanningConfig. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.ScanningConfig getScanningConfig() { + return scanningConfig_ == null + ? com.google.cloud.agentregistry.v1.ScanningConfig.getDefaultInstance() + : scanningConfig_; + } + + /** + * + * + *
+   * Optional. Optional. Scanning configuration for the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.ScanningConfigOrBuilder getScanningConfigOrBuilder() { + return scanningConfig_ == null + ? com.google.cloud.agentregistry.v1.ScanningConfig.getDefaultInstance() + : scanningConfig_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uid_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, uid_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, displayName_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, description_); + } + if (type_ != com.google.cloud.agentregistry.v1.Skill.Type.TYPE_UNSPECIFIED.getNumber()) { + output.writeEnum(5, type_); + } + if (state_ != com.google.cloud.agentregistry.v1.Skill.State.STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(6, state_); + } + if (targetState_ + != com.google.cloud.agentregistry.v1.Skill.TargetState.TARGET_STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(7, targetState_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(defaultRevision_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 8, defaultRevision_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(9, getFrontmatter()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(11, getCreateTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(12, getUpdateTime()); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeMessage(14, getInitialRevision()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(publisher_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 15, publisher_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(skillId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 17, skillId_); + } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeMessage(20, getScanningConfig()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uid_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, uid_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, displayName_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, description_); + } + if (type_ != com.google.cloud.agentregistry.v1.Skill.Type.TYPE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, type_); + } + if (state_ != com.google.cloud.agentregistry.v1.Skill.State.STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(6, state_); + } + if (targetState_ + != com.google.cloud.agentregistry.v1.Skill.TargetState.TARGET_STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, targetState_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(defaultRevision_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(8, defaultRevision_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, getFrontmatter()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(11, getCreateTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(12, getUpdateTime()); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(14, getInitialRevision()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(publisher_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(15, publisher_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(skillId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(17, skillId_); + } + if (((bitField0_ & 0x00000010) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(20, getScanningConfig()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.Skill)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.Skill other = (com.google.cloud.agentregistry.v1.Skill) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUid().equals(other.getUid())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (type_ != other.type_) return false; + if (state_ != other.state_) return false; + if (targetState_ != other.targetState_) return false; + if (!getDefaultRevision().equals(other.getDefaultRevision())) return false; + if (hasFrontmatter() != other.hasFrontmatter()) return false; + if (hasFrontmatter()) { + if (!getFrontmatter().equals(other.getFrontmatter())) return false; + } + if (!getSkillId().equals(other.getSkillId())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!getPublisher().equals(other.getPublisher())) return false; + if (hasInitialRevision() != other.hasInitialRevision()) return false; + if (hasInitialRevision()) { + if (!getInitialRevision().equals(other.getInitialRevision())) return false; + } + if (hasScanningConfig() != other.hasScanningConfig()) return false; + if (hasScanningConfig()) { + if (!getScanningConfig().equals(other.getScanningConfig())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + UID_FIELD_NUMBER; + hash = (53 * hash) + getUid().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + hash = (37 * hash) + TYPE_FIELD_NUMBER; + hash = (53 * hash) + type_; + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + hash = (37 * hash) + TARGET_STATE_FIELD_NUMBER; + hash = (53 * hash) + targetState_; + hash = (37 * hash) + DEFAULT_REVISION_FIELD_NUMBER; + hash = (53 * hash) + getDefaultRevision().hashCode(); + if (hasFrontmatter()) { + hash = (37 * hash) + FRONTMATTER_FIELD_NUMBER; + hash = (53 * hash) + getFrontmatter().hashCode(); + } + hash = (37 * hash) + SKILL_ID_FIELD_NUMBER; + hash = (53 * hash) + getSkillId().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + hash = (37 * hash) + PUBLISHER_FIELD_NUMBER; + hash = (53 * hash) + getPublisher().hashCode(); + if (hasInitialRevision()) { + hash = (37 * hash) + INITIAL_REVISION_FIELD_NUMBER; + hash = (53 * hash) + getInitialRevision().hashCode(); + } + if (hasScanningConfig()) { + hash = (37 * hash) + SCANNING_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getScanningConfig().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.Skill parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Skill parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Skill parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Skill parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Skill parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.Skill parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Skill parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Skill parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Skill parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Skill parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.Skill parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.Skill parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.Skill prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Represents an Executable Agent Skill or a Composite Tool Suite (Bundle).
+   * Sibling resource with Agent and McpServer under agentregistry.googleapis.com.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.Skill} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.Skill) + com.google.cloud.agentregistry.v1.SkillOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Skill_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Skill_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.Skill.class, + com.google.cloud.agentregistry.v1.Skill.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.Skill.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetFrontmatterFieldBuilder(); + internalGetCreateTimeFieldBuilder(); + internalGetUpdateTimeFieldBuilder(); + internalGetInitialRevisionFieldBuilder(); + internalGetScanningConfigFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + uid_ = ""; + displayName_ = ""; + description_ = ""; + type_ = 0; + state_ = 0; + targetState_ = 0; + defaultRevision_ = ""; + frontmatter_ = null; + if (frontmatterBuilder_ != null) { + frontmatterBuilder_.dispose(); + frontmatterBuilder_ = null; + } + skillId_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + publisher_ = ""; + initialRevision_ = null; + if (initialRevisionBuilder_ != null) { + initialRevisionBuilder_.dispose(); + initialRevisionBuilder_ = null; + } + scanningConfig_ = null; + if (scanningConfigBuilder_ != null) { + scanningConfigBuilder_.dispose(); + scanningConfigBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_Skill_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.Skill.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill build() { + com.google.cloud.agentregistry.v1.Skill result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill buildPartial() { + com.google.cloud.agentregistry.v1.Skill result = + new com.google.cloud.agentregistry.v1.Skill(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.Skill result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.uid_ = uid_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.displayName_ = displayName_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.description_ = description_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.type_ = type_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.state_ = state_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.targetState_ = targetState_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.defaultRevision_ = defaultRevision_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000100) != 0)) { + result.frontmatter_ = + frontmatterBuilder_ == null ? frontmatter_ : frontmatterBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.skillId_ = skillId_; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000800) != 0)) { + result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00001000) != 0)) { + result.publisher_ = publisher_; + } + if (((from_bitField0_ & 0x00002000) != 0)) { + result.initialRevision_ = + initialRevisionBuilder_ == null ? initialRevision_ : initialRevisionBuilder_.build(); + to_bitField0_ |= 0x00000008; + } + if (((from_bitField0_ & 0x00004000) != 0)) { + result.scanningConfig_ = + scanningConfigBuilder_ == null ? scanningConfig_ : scanningConfigBuilder_.build(); + to_bitField0_ |= 0x00000010; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.Skill) { + return mergeFrom((com.google.cloud.agentregistry.v1.Skill) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.Skill other) { + if (other == com.google.cloud.agentregistry.v1.Skill.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getUid().isEmpty()) { + uid_ = other.uid_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (other.type_ != 0) { + setTypeValue(other.getTypeValue()); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (other.targetState_ != 0) { + setTargetStateValue(other.getTargetStateValue()); + } + if (!other.getDefaultRevision().isEmpty()) { + defaultRevision_ = other.defaultRevision_; + bitField0_ |= 0x00000080; + onChanged(); + } + if (other.hasFrontmatter()) { + mergeFrontmatter(other.getFrontmatter()); + } + if (!other.getSkillId().isEmpty()) { + skillId_ = other.skillId_; + bitField0_ |= 0x00000200; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (!other.getPublisher().isEmpty()) { + publisher_ = other.publisher_; + bitField0_ |= 0x00001000; + onChanged(); + } + if (other.hasInitialRevision()) { + mergeInitialRevision(other.getInitialRevision()); + } + if (other.hasScanningConfig()) { + mergeScanningConfig(other.getScanningConfig()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + uid_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 40: + { + type_ = input.readEnum(); + bitField0_ |= 0x00000010; + break; + } // case 40 + case 48: + { + state_ = input.readEnum(); + bitField0_ |= 0x00000020; + break; + } // case 48 + case 56: + { + targetState_ = input.readEnum(); + bitField0_ |= 0x00000040; + break; + } // case 56 + case 66: + { + defaultRevision_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000080; + break; + } // case 66 + case 74: + { + input.readMessage( + internalGetFrontmatterFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000100; + break; + } // case 74 + case 90: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000400; + break; + } // case 90 + case 98: + { + input.readMessage( + internalGetUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000800; + break; + } // case 98 + case 114: + { + input.readMessage( + internalGetInitialRevisionFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00002000; + break; + } // case 114 + case 122: + { + publisher_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00001000; + break; + } // case 122 + case 138: + { + skillId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000200; + break; + } // case 138 + case 162: + { + input.readMessage( + internalGetScanningConfigFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00004000; + break; + } // case 162 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Identifier. Resource name of the Skill.
+     * Format: `projects/{project}/locations/{location}/skills/{skill}`
+     * The `{skill}` segment acts as the resource ID. If the skill is associated
+     * with a Publisher, this segment typically uses a hyphenated namespace prefix
+     * corresponding to the publisher (e.g., `google-workspace-create-docs`).
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the Skill.
+     * Format: `projects/{project}/locations/{location}/skills/{skill}`
+     * The `{skill}` segment acts as the resource ID. If the skill is associated
+     * with a Publisher, this segment typically uses a hyphenated namespace prefix
+     * corresponding to the publisher (e.g., `google-workspace-create-docs`).
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the Skill.
+     * Format: `projects/{project}/locations/{location}/skills/{skill}`
+     * The `{skill}` segment acts as the resource ID. If the skill is associated
+     * with a Publisher, this segment typically uses a hyphenated namespace prefix
+     * corresponding to the publisher (e.g., `google-workspace-create-docs`).
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the Skill.
+     * Format: `projects/{project}/locations/{location}/skills/{skill}`
+     * The `{skill}` segment acts as the resource ID. If the skill is associated
+     * with a Publisher, this segment typically uses a hyphenated namespace prefix
+     * corresponding to the publisher (e.g., `google-workspace-create-docs`).
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the Skill.
+     * Format: `projects/{project}/locations/{location}/skills/{skill}`
+     * The `{skill}` segment acts as the resource ID. If the skill is associated
+     * with a Publisher, this segment typically uses a hyphenated namespace prefix
+     * corresponding to the publisher (e.g., `google-workspace-create-docs`).
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object uid_ = ""; + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the logical
+     * container.
+     * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the logical
+     * container.
+     * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the logical
+     * container.
+     * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @param value The uid to set. + * @return This builder for chaining. + */ + public Builder setUid(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + uid_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the logical
+     * container.
+     * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearUid() { + uid_ = getDefaultInstance().getUid(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the logical
+     * container.
+     * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for uid to set. + * @return This builder for chaining. + */ + public Builder setUidBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + uid_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + + /** + * + * + *
+     * Optional. Human-readable display name of the skill.
+     * Maximum length is 128 characters.
+     * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Human-readable display name of the skill.
+     * Maximum length is 128 characters.
+     * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Human-readable display name of the skill.
+     * Maximum length is 128 characters.
+     * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + displayName_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Human-readable display name of the skill.
+     * Maximum length is 128 characters.
+     * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + displayName_ = getDefaultInstance().getDisplayName(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Human-readable display name of the skill.
+     * Maximum length is 128 characters.
+     * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + displayName_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + + /** + * + * + *
+     * Optional. Brief summary describing the capabilities of the skill.
+     * Maximum length is 2048 characters.
+     * 
+ * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Brief summary describing the capabilities of the skill.
+     * Maximum length is 2048 characters.
+     * 
+ * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Brief summary describing the capabilities of the skill.
+     * Maximum length is 2048 characters.
+     * 
+ * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + description_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Brief summary describing the capabilities of the skill.
+     * Maximum length is 2048 characters.
+     * 
+ * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + description_ = getDefaultInstance().getDescription(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Brief summary describing the capabilities of the skill.
+     * Maximum length is 2048 characters.
+     * 
+ * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private int type_ = 0; + + /** + * + * + *
+     * Required. Structural deployment type (SIMPLE leaf vs COMPOSITE bundle).
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.Type type = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + + /** + * + * + *
+     * Required. Structural deployment type (SIMPLE leaf vs COMPOSITE bundle).
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.Type type = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The enum numeric value on the wire for type to set. + * @return This builder for chaining. + */ + public Builder setTypeValue(int value) { + type_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Structural deployment type (SIMPLE leaf vs COMPOSITE bundle).
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.Type type = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The type. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill.Type getType() { + com.google.cloud.agentregistry.v1.Skill.Type result = + com.google.cloud.agentregistry.v1.Skill.Type.forNumber(type_); + return result == null ? com.google.cloud.agentregistry.v1.Skill.Type.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * Required. Structural deployment type (SIMPLE leaf vs COMPOSITE bundle).
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.Type type = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The type to set. + * @return This builder for chaining. + */ + public Builder setType(com.google.cloud.agentregistry.v1.Skill.Type value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000010; + type_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Structural deployment type (SIMPLE leaf vs COMPOSITE bundle).
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.Type type = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearType() { + bitField0_ = (bitField0_ & ~0x00000010); + type_ = 0; + onChanged(); + return this; + } + + private int state_ = 0; + + /** + * + * + *
+     * Output only. The system-managed state of the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
+     * Output only. The system-managed state of the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The system-managed state of the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill.State getState() { + com.google.cloud.agentregistry.v1.Skill.State result = + com.google.cloud.agentregistry.v1.Skill.State.forNumber(state_); + return result == null ? com.google.cloud.agentregistry.v1.Skill.State.UNRECOGNIZED : result; + } + + /** + * + * + *
+     * Output only. The system-managed state of the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.agentregistry.v1.Skill.State value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000020; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The system-managed state of the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000020); + state_ = 0; + onChanged(); + return this; + } + + private int targetState_ = 0; + + /** + * + * + *
+     * Required. User-managed target state of the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.TargetState target_state = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for targetState. + */ + @java.lang.Override + public int getTargetStateValue() { + return targetState_; + } + + /** + * + * + *
+     * Required. User-managed target state of the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.TargetState target_state = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The enum numeric value on the wire for targetState to set. + * @return This builder for chaining. + */ + public Builder setTargetStateValue(int value) { + targetState_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. User-managed target state of the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.TargetState target_state = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The targetState. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill.TargetState getTargetState() { + com.google.cloud.agentregistry.v1.Skill.TargetState result = + com.google.cloud.agentregistry.v1.Skill.TargetState.forNumber(targetState_); + return result == null + ? com.google.cloud.agentregistry.v1.Skill.TargetState.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Required. User-managed target state of the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.TargetState target_state = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The targetState to set. + * @return This builder for chaining. + */ + public Builder setTargetState(com.google.cloud.agentregistry.v1.Skill.TargetState value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000040; + targetState_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. User-managed target state of the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.TargetState target_state = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearTargetState() { + bitField0_ = (bitField0_ & ~0x00000040); + targetState_ = 0; + onChanged(); + return this; + } + + private java.lang.Object defaultRevision_ = ""; + + /** + * + * + *
+     * Optional. The full resource name of the revision currently served by
+     * default (floating track).
+     * Format:
+     * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+     * 
+ * + * + * string default_revision = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The defaultRevision. + */ + public java.lang.String getDefaultRevision() { + java.lang.Object ref = defaultRevision_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + defaultRevision_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. The full resource name of the revision currently served by
+     * default (floating track).
+     * Format:
+     * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+     * 
+ * + * + * string default_revision = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for defaultRevision. + */ + public com.google.protobuf.ByteString getDefaultRevisionBytes() { + java.lang.Object ref = defaultRevision_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + defaultRevision_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. The full resource name of the revision currently served by
+     * default (floating track).
+     * Format:
+     * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+     * 
+ * + * + * string default_revision = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The defaultRevision to set. + * @return This builder for chaining. + */ + public Builder setDefaultRevision(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + defaultRevision_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The full resource name of the revision currently served by
+     * default (floating track).
+     * Format:
+     * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+     * 
+ * + * + * string default_revision = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearDefaultRevision() { + defaultRevision_ = getDefaultInstance().getDefaultRevision(); + bitField0_ = (bitField0_ & ~0x00000080); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The full resource name of the revision currently served by
+     * default (floating track).
+     * Format:
+     * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+     * 
+ * + * + * string default_revision = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for defaultRevision to set. + * @return This builder for chaining. + */ + public Builder setDefaultRevisionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + defaultRevision_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + private com.google.cloud.agentregistry.v1.Frontmatter frontmatter_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Frontmatter, + com.google.cloud.agentregistry.v1.Frontmatter.Builder, + com.google.cloud.agentregistry.v1.FrontmatterOrBuilder> + frontmatterBuilder_; + + /** + * + * + *
+     * Output only. Lightweight frontmatter metadata attributes copied from the
+     * default revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the frontmatter field is set. + */ + public boolean hasFrontmatter() { + return ((bitField0_ & 0x00000100) != 0); + } + + /** + * + * + *
+     * Output only. Lightweight frontmatter metadata attributes copied from the
+     * default revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The frontmatter. + */ + public com.google.cloud.agentregistry.v1.Frontmatter getFrontmatter() { + if (frontmatterBuilder_ == null) { + return frontmatter_ == null + ? com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance() + : frontmatter_; + } else { + return frontmatterBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Lightweight frontmatter metadata attributes copied from the
+     * default revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setFrontmatter(com.google.cloud.agentregistry.v1.Frontmatter value) { + if (frontmatterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + frontmatter_ = value; + } else { + frontmatterBuilder_.setMessage(value); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Lightweight frontmatter metadata attributes copied from the
+     * default revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setFrontmatter( + com.google.cloud.agentregistry.v1.Frontmatter.Builder builderForValue) { + if (frontmatterBuilder_ == null) { + frontmatter_ = builderForValue.build(); + } else { + frontmatterBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Lightweight frontmatter metadata attributes copied from the
+     * default revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeFrontmatter(com.google.cloud.agentregistry.v1.Frontmatter value) { + if (frontmatterBuilder_ == null) { + if (((bitField0_ & 0x00000100) != 0) + && frontmatter_ != null + && frontmatter_ != com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance()) { + getFrontmatterBuilder().mergeFrom(value); + } else { + frontmatter_ = value; + } + } else { + frontmatterBuilder_.mergeFrom(value); + } + if (frontmatter_ != null) { + bitField0_ |= 0x00000100; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Lightweight frontmatter metadata attributes copied from the
+     * default revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearFrontmatter() { + bitField0_ = (bitField0_ & ~0x00000100); + frontmatter_ = null; + if (frontmatterBuilder_ != null) { + frontmatterBuilder_.dispose(); + frontmatterBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Lightweight frontmatter metadata attributes copied from the
+     * default revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.agentregistry.v1.Frontmatter.Builder getFrontmatterBuilder() { + bitField0_ |= 0x00000100; + onChanged(); + return internalGetFrontmatterFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Lightweight frontmatter metadata attributes copied from the
+     * default revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.agentregistry.v1.FrontmatterOrBuilder getFrontmatterOrBuilder() { + if (frontmatterBuilder_ != null) { + return frontmatterBuilder_.getMessageOrBuilder(); + } else { + return frontmatter_ == null + ? com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance() + : frontmatter_; + } + } + + /** + * + * + *
+     * Output only. Lightweight frontmatter metadata attributes copied from the
+     * default revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Frontmatter, + com.google.cloud.agentregistry.v1.Frontmatter.Builder, + com.google.cloud.agentregistry.v1.FrontmatterOrBuilder> + internalGetFrontmatterFieldBuilder() { + if (frontmatterBuilder_ == null) { + frontmatterBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Frontmatter, + com.google.cloud.agentregistry.v1.Frontmatter.Builder, + com.google.cloud.agentregistry.v1.FrontmatterOrBuilder>( + getFrontmatter(), getParentForChildren(), isClean()); + frontmatter_ = null; + } + return frontmatterBuilder_; + } + + private java.lang.Object skillId_ = ""; + + /** + * + * + *
+     * Output only. A stable, globally unique logical identifier for the skill.
+     * It is securely constructed by the backend by combining the associated
+     * `publisher`'s verified namespace and the skill's resource ID to enforce
+     * strict ownership. For example, the prefix `google-` is reserved exclusively
+     * for first-party Google publishers to prevent namespace squatting.
+     * Example: `urn:skill:google-workspace:create-docs`
+     * 
+ * + * string skill_id = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The skillId. + */ + public java.lang.String getSkillId() { + java.lang.Object ref = skillId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + skillId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. A stable, globally unique logical identifier for the skill.
+     * It is securely constructed by the backend by combining the associated
+     * `publisher`'s verified namespace and the skill's resource ID to enforce
+     * strict ownership. For example, the prefix `google-` is reserved exclusively
+     * for first-party Google publishers to prevent namespace squatting.
+     * Example: `urn:skill:google-workspace:create-docs`
+     * 
+ * + * string skill_id = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for skillId. + */ + public com.google.protobuf.ByteString getSkillIdBytes() { + java.lang.Object ref = skillId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + skillId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. A stable, globally unique logical identifier for the skill.
+     * It is securely constructed by the backend by combining the associated
+     * `publisher`'s verified namespace and the skill's resource ID to enforce
+     * strict ownership. For example, the prefix `google-` is reserved exclusively
+     * for first-party Google publishers to prevent namespace squatting.
+     * Example: `urn:skill:google-workspace:create-docs`
+     * 
+ * + * string skill_id = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The skillId to set. + * @return This builder for chaining. + */ + public Builder setSkillId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + skillId_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. A stable, globally unique logical identifier for the skill.
+     * It is securely constructed by the backend by combining the associated
+     * `publisher`'s verified namespace and the skill's resource ID to enforce
+     * strict ownership. For example, the prefix `google-` is reserved exclusively
+     * for first-party Google publishers to prevent namespace squatting.
+     * Example: `urn:skill:google-workspace:create-docs`
+     * 
+ * + * string skill_id = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearSkillId() { + skillId_ = getDefaultInstance().getSkillId(); + bitField0_ = (bitField0_ & ~0x00000200); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. A stable, globally unique logical identifier for the skill.
+     * It is securely constructed by the backend by combining the associated
+     * `publisher`'s verified namespace and the skill's resource ID to enforce
+     * strict ownership. For example, the prefix `google-` is reserved exclusively
+     * for first-party Google publishers to prevent namespace squatting.
+     * Example: `urn:skill:google-workspace:create-docs`
+     * 
+ * + * string skill_id = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for skillId to set. + * @return This builder for chaining. + */ + public Builder setSkillIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + skillId_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000400) != 0); + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000400) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000400; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000400); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000400; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
+     * Output only. Create time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000800) != 0); + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + } else { + updateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000800) != 0) + && updateTime_ != null + && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getUpdateTimeBuilder().mergeFrom(value); + } else { + updateTime_ = value; + } + } else { + updateTimeBuilder_.mergeFrom(value); + } + if (updateTime_ != null) { + bitField0_ |= 0x00000800; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000800); + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + bitField0_ |= 0x00000800; + onChanged(); + return internalGetUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + + /** + * + * + *
+     * Output only. Update time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private java.lang.Object publisher_ = ""; + + /** + * + * + *
+     * Optional. The publisher resource associated with this skill.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * The publisher dictates the allowed namespace prefixes for the skill's name
+     * and logical `skill_id` (e.g., Publisher `google` authorizes the `google-*`
+     * prefix).
+     * 
+ * + * + * string publisher = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The publisher. + */ + public java.lang.String getPublisher() { + java.lang.Object ref = publisher_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + publisher_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. The publisher resource associated with this skill.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * The publisher dictates the allowed namespace prefixes for the skill's name
+     * and logical `skill_id` (e.g., Publisher `google` authorizes the `google-*`
+     * prefix).
+     * 
+ * + * + * string publisher = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for publisher. + */ + public com.google.protobuf.ByteString getPublisherBytes() { + java.lang.Object ref = publisher_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + publisher_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. The publisher resource associated with this skill.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * The publisher dictates the allowed namespace prefixes for the skill's name
+     * and logical `skill_id` (e.g., Publisher `google` authorizes the `google-*`
+     * prefix).
+     * 
+ * + * + * string publisher = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The publisher to set. + * @return This builder for chaining. + */ + public Builder setPublisher(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + publisher_ = value; + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The publisher resource associated with this skill.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * The publisher dictates the allowed namespace prefixes for the skill's name
+     * and logical `skill_id` (e.g., Publisher `google` authorizes the `google-*`
+     * prefix).
+     * 
+ * + * + * string publisher = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearPublisher() { + publisher_ = getDefaultInstance().getPublisher(); + bitField0_ = (bitField0_ & ~0x00001000); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The publisher resource associated with this skill.
+     * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+     * The publisher dictates the allowed namespace prefixes for the skill's name
+     * and logical `skill_id` (e.g., Publisher `google` authorizes the `google-*`
+     * prefix).
+     * 
+ * + * + * string publisher = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for publisher to set. + * @return This builder for chaining. + */ + public Builder setPublisherBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + publisher_ = value; + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + private com.google.cloud.agentregistry.v1.SkillRevision initialRevision_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision, + com.google.cloud.agentregistry.v1.SkillRevision.Builder, + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder> + initialRevisionBuilder_; + + /** + * + * + *
+     * Optional. Input only. Optional nested initial revision payload to support
+     * standard one-shot creation. The server processes this field on input during
+     * creation but must never return it in responses.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + * + * @return Whether the initialRevision field is set. + */ + public boolean hasInitialRevision() { + return ((bitField0_ & 0x00002000) != 0); + } + + /** + * + * + *
+     * Optional. Input only. Optional nested initial revision payload to support
+     * standard one-shot creation. The server processes this field on input during
+     * creation but must never return it in responses.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + * + * @return The initialRevision. + */ + public com.google.cloud.agentregistry.v1.SkillRevision getInitialRevision() { + if (initialRevisionBuilder_ == null) { + return initialRevision_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance() + : initialRevision_; + } else { + return initialRevisionBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Optional. Input only. Optional nested initial revision payload to support
+     * standard one-shot creation. The server processes this field on input during
+     * creation but must never return it in responses.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + */ + public Builder setInitialRevision(com.google.cloud.agentregistry.v1.SkillRevision value) { + if (initialRevisionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + initialRevision_ = value; + } else { + initialRevisionBuilder_.setMessage(value); + } + bitField0_ |= 0x00002000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Input only. Optional nested initial revision payload to support
+     * standard one-shot creation. The server processes this field on input during
+     * creation but must never return it in responses.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + */ + public Builder setInitialRevision( + com.google.cloud.agentregistry.v1.SkillRevision.Builder builderForValue) { + if (initialRevisionBuilder_ == null) { + initialRevision_ = builderForValue.build(); + } else { + initialRevisionBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00002000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Input only. Optional nested initial revision payload to support
+     * standard one-shot creation. The server processes this field on input during
+     * creation but must never return it in responses.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + */ + public Builder mergeInitialRevision(com.google.cloud.agentregistry.v1.SkillRevision value) { + if (initialRevisionBuilder_ == null) { + if (((bitField0_ & 0x00002000) != 0) + && initialRevision_ != null + && initialRevision_ + != com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance()) { + getInitialRevisionBuilder().mergeFrom(value); + } else { + initialRevision_ = value; + } + } else { + initialRevisionBuilder_.mergeFrom(value); + } + if (initialRevision_ != null) { + bitField0_ |= 0x00002000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Optional. Input only. Optional nested initial revision payload to support
+     * standard one-shot creation. The server processes this field on input during
+     * creation but must never return it in responses.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + */ + public Builder clearInitialRevision() { + bitField0_ = (bitField0_ & ~0x00002000); + initialRevision_ = null; + if (initialRevisionBuilder_ != null) { + initialRevisionBuilder_.dispose(); + initialRevisionBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Input only. Optional nested initial revision payload to support
+     * standard one-shot creation. The server processes this field on input during
+     * creation but must never return it in responses.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + */ + public com.google.cloud.agentregistry.v1.SkillRevision.Builder getInitialRevisionBuilder() { + bitField0_ |= 0x00002000; + onChanged(); + return internalGetInitialRevisionFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Optional. Input only. Optional nested initial revision payload to support
+     * standard one-shot creation. The server processes this field on input during
+     * creation but must never return it in responses.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + */ + public com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder getInitialRevisionOrBuilder() { + if (initialRevisionBuilder_ != null) { + return initialRevisionBuilder_.getMessageOrBuilder(); + } else { + return initialRevision_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance() + : initialRevision_; + } + } + + /** + * + * + *
+     * Optional. Input only. Optional nested initial revision payload to support
+     * standard one-shot creation. The server processes this field on input during
+     * creation but must never return it in responses.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision, + com.google.cloud.agentregistry.v1.SkillRevision.Builder, + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder> + internalGetInitialRevisionFieldBuilder() { + if (initialRevisionBuilder_ == null) { + initialRevisionBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision, + com.google.cloud.agentregistry.v1.SkillRevision.Builder, + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder>( + getInitialRevision(), getParentForChildren(), isClean()); + initialRevision_ = null; + } + return initialRevisionBuilder_; + } + + private com.google.cloud.agentregistry.v1.ScanningConfig scanningConfig_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.ScanningConfig, + com.google.cloud.agentregistry.v1.ScanningConfig.Builder, + com.google.cloud.agentregistry.v1.ScanningConfigOrBuilder> + scanningConfigBuilder_; + + /** + * + * + *
+     * Optional. Optional. Scanning configuration for the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the scanningConfig field is set. + */ + public boolean hasScanningConfig() { + return ((bitField0_ & 0x00004000) != 0); + } + + /** + * + * + *
+     * Optional. Optional. Scanning configuration for the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The scanningConfig. + */ + public com.google.cloud.agentregistry.v1.ScanningConfig getScanningConfig() { + if (scanningConfigBuilder_ == null) { + return scanningConfig_ == null + ? com.google.cloud.agentregistry.v1.ScanningConfig.getDefaultInstance() + : scanningConfig_; + } else { + return scanningConfigBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Optional. Optional. Scanning configuration for the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setScanningConfig(com.google.cloud.agentregistry.v1.ScanningConfig value) { + if (scanningConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + scanningConfig_ = value; + } else { + scanningConfigBuilder_.setMessage(value); + } + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Optional. Scanning configuration for the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setScanningConfig( + com.google.cloud.agentregistry.v1.ScanningConfig.Builder builderForValue) { + if (scanningConfigBuilder_ == null) { + scanningConfig_ = builderForValue.build(); + } else { + scanningConfigBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Optional. Scanning configuration for the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeScanningConfig(com.google.cloud.agentregistry.v1.ScanningConfig value) { + if (scanningConfigBuilder_ == null) { + if (((bitField0_ & 0x00004000) != 0) + && scanningConfig_ != null + && scanningConfig_ + != com.google.cloud.agentregistry.v1.ScanningConfig.getDefaultInstance()) { + getScanningConfigBuilder().mergeFrom(value); + } else { + scanningConfig_ = value; + } + } else { + scanningConfigBuilder_.mergeFrom(value); + } + if (scanningConfig_ != null) { + bitField0_ |= 0x00004000; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Optional. Optional. Scanning configuration for the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearScanningConfig() { + bitField0_ = (bitField0_ & ~0x00004000); + scanningConfig_ = null; + if (scanningConfigBuilder_ != null) { + scanningConfigBuilder_.dispose(); + scanningConfigBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Optional. Scanning configuration for the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.agentregistry.v1.ScanningConfig.Builder getScanningConfigBuilder() { + bitField0_ |= 0x00004000; + onChanged(); + return internalGetScanningConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Optional. Optional. Scanning configuration for the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.agentregistry.v1.ScanningConfigOrBuilder getScanningConfigOrBuilder() { + if (scanningConfigBuilder_ != null) { + return scanningConfigBuilder_.getMessageOrBuilder(); + } else { + return scanningConfig_ == null + ? com.google.cloud.agentregistry.v1.ScanningConfig.getDefaultInstance() + : scanningConfig_; + } + } + + /** + * + * + *
+     * Optional. Optional. Scanning configuration for the skill.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.ScanningConfig, + com.google.cloud.agentregistry.v1.ScanningConfig.Builder, + com.google.cloud.agentregistry.v1.ScanningConfigOrBuilder> + internalGetScanningConfigFieldBuilder() { + if (scanningConfigBuilder_ == null) { + scanningConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.ScanningConfig, + com.google.cloud.agentregistry.v1.ScanningConfig.Builder, + com.google.cloud.agentregistry.v1.ScanningConfigOrBuilder>( + getScanningConfig(), getParentForChildren(), isClean()); + scanningConfig_ = null; + } + return scanningConfigBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.Skill) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.Skill) + private static final com.google.cloud.agentregistry.v1.Skill DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.Skill(); + } + + public static com.google.cloud.agentregistry.v1.Skill getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Skill parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpec.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpec.java new file mode 100644 index 000000000000..ef86da018def --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpec.java @@ -0,0 +1,1466 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill_encryption_spec.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Once the SkillEncryptionSpec is configured, new Skill payloads are protected
+ * using the provided customer-managed encryption key instead of a
+ * Google-managed encryption key.
+ *
+ * SkillEncryptionSpec cannot be set if any Skills have already been created
+ * in the project and location.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.SkillEncryptionSpec} + */ +@com.google.protobuf.Generated +public final class SkillEncryptionSpec extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.SkillEncryptionSpec) + SkillEncryptionSpecOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SkillEncryptionSpec"); + } + + // Use SkillEncryptionSpec.newBuilder() to construct. + private SkillEncryptionSpec(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private SkillEncryptionSpec() { + name_ = ""; + cryptoKeyName_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillEncryptionSpecProto + .internal_static_google_cloud_agentregistry_v1_SkillEncryptionSpec_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillEncryptionSpecProto + .internal_static_google_cloud_agentregistry_v1_SkillEncryptionSpec_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.SkillEncryptionSpec.class, + com.google.cloud.agentregistry.v1.SkillEncryptionSpec.Builder.class); + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Identifier. Resource name of the SkillEncryptionSpec.
+   * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Identifier. Resource name of the SkillEncryptionSpec.
+   * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CRYPTO_KEY_NAME_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object cryptoKeyName_ = ""; + + /** + * + * + *
+   * Required. The Cloud KMS CryptoKey resource name used to protect Skill
+   * payloads in this project and location.
+   * This field can be set or updated only when no Skills exist in the target
+   * project and location. Once any Skill exists in the location, updating this
+   * field is rejected with `FAILED_PRECONDITION`.
+   * Format:
+   * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey}`
+   * 
+ * + * + * string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The cryptoKeyName. + */ + @java.lang.Override + public java.lang.String getCryptoKeyName() { + java.lang.Object ref = cryptoKeyName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + cryptoKeyName_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The Cloud KMS CryptoKey resource name used to protect Skill
+   * payloads in this project and location.
+   * This field can be set or updated only when no Skills exist in the target
+   * project and location. Once any Skill exists in the location, updating this
+   * field is rejected with `FAILED_PRECONDITION`.
+   * Format:
+   * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey}`
+   * 
+ * + * + * string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for cryptoKeyName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCryptoKeyNameBytes() { + java.lang.Object ref = cryptoKeyName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + cryptoKeyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 3; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
+   * Output only. Creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Output only. Creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
+   * Output only. Creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 4; + private com.google.protobuf.Timestamp updateTime_; + + /** + * + * + *
+   * Output only. Most recent update timestamp.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Output only. Most recent update timestamp.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + /** + * + * + *
+   * Output only. Most recent update timestamp.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(cryptoKeyName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, cryptoKeyName_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(4, getUpdateTime()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(cryptoKeyName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, cryptoKeyName_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getUpdateTime()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.SkillEncryptionSpec)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.SkillEncryptionSpec other = + (com.google.cloud.agentregistry.v1.SkillEncryptionSpec) obj; + + if (!getName().equals(other.getName())) return false; + if (!getCryptoKeyName().equals(other.getCryptoKeyName())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + CRYPTO_KEY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getCryptoKeyName().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.SkillEncryptionSpec prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Once the SkillEncryptionSpec is configured, new Skill payloads are protected
+   * using the provided customer-managed encryption key instead of a
+   * Google-managed encryption key.
+   *
+   * SkillEncryptionSpec cannot be set if any Skills have already been created
+   * in the project and location.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.SkillEncryptionSpec} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.SkillEncryptionSpec) + com.google.cloud.agentregistry.v1.SkillEncryptionSpecOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillEncryptionSpecProto + .internal_static_google_cloud_agentregistry_v1_SkillEncryptionSpec_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillEncryptionSpecProto + .internal_static_google_cloud_agentregistry_v1_SkillEncryptionSpec_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.SkillEncryptionSpec.class, + com.google.cloud.agentregistry.v1.SkillEncryptionSpec.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.SkillEncryptionSpec.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetCreateTimeFieldBuilder(); + internalGetUpdateTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + cryptoKeyName_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.SkillEncryptionSpecProto + .internal_static_google_cloud_agentregistry_v1_SkillEncryptionSpec_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillEncryptionSpec getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.SkillEncryptionSpec.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillEncryptionSpec build() { + com.google.cloud.agentregistry.v1.SkillEncryptionSpec result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillEncryptionSpec buildPartial() { + com.google.cloud.agentregistry.v1.SkillEncryptionSpec result = + new com.google.cloud.agentregistry.v1.SkillEncryptionSpec(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.SkillEncryptionSpec result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.cryptoKeyName_ = cryptoKeyName_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.SkillEncryptionSpec) { + return mergeFrom((com.google.cloud.agentregistry.v1.SkillEncryptionSpec) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.SkillEncryptionSpec other) { + if (other == com.google.cloud.agentregistry.v1.SkillEncryptionSpec.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getCryptoKeyName().isEmpty()) { + cryptoKeyName_ = other.cryptoKeyName_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + cryptoKeyName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Identifier. Resource name of the SkillEncryptionSpec.
+     * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the SkillEncryptionSpec.
+     * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the SkillEncryptionSpec.
+     * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the SkillEncryptionSpec.
+     * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the SkillEncryptionSpec.
+     * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object cryptoKeyName_ = ""; + + /** + * + * + *
+     * Required. The Cloud KMS CryptoKey resource name used to protect Skill
+     * payloads in this project and location.
+     * This field can be set or updated only when no Skills exist in the target
+     * project and location. Once any Skill exists in the location, updating this
+     * field is rejected with `FAILED_PRECONDITION`.
+     * Format:
+     * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey}`
+     * 
+ * + * + * string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The cryptoKeyName. + */ + public java.lang.String getCryptoKeyName() { + java.lang.Object ref = cryptoKeyName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + cryptoKeyName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The Cloud KMS CryptoKey resource name used to protect Skill
+     * payloads in this project and location.
+     * This field can be set or updated only when no Skills exist in the target
+     * project and location. Once any Skill exists in the location, updating this
+     * field is rejected with `FAILED_PRECONDITION`.
+     * Format:
+     * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey}`
+     * 
+ * + * + * string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for cryptoKeyName. + */ + public com.google.protobuf.ByteString getCryptoKeyNameBytes() { + java.lang.Object ref = cryptoKeyName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + cryptoKeyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The Cloud KMS CryptoKey resource name used to protect Skill
+     * payloads in this project and location.
+     * This field can be set or updated only when no Skills exist in the target
+     * project and location. Once any Skill exists in the location, updating this
+     * field is rejected with `FAILED_PRECONDITION`.
+     * Format:
+     * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey}`
+     * 
+ * + * + * string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The cryptoKeyName to set. + * @return This builder for chaining. + */ + public Builder setCryptoKeyName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + cryptoKeyName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The Cloud KMS CryptoKey resource name used to protect Skill
+     * payloads in this project and location.
+     * This field can be set or updated only when no Skills exist in the target
+     * project and location. Once any Skill exists in the location, updating this
+     * field is rejected with `FAILED_PRECONDITION`.
+     * Format:
+     * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey}`
+     * 
+ * + * + * string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearCryptoKeyName() { + cryptoKeyName_ = getDefaultInstance().getCryptoKeyName(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The Cloud KMS CryptoKey resource name used to protect Skill
+     * payloads in this project and location.
+     * This field can be set or updated only when no Skills exist in the target
+     * project and location. Once any Skill exists in the location, updating this
+     * field is rejected with `FAILED_PRECONDITION`.
+     * Format:
+     * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey}`
+     * 
+ * + * + * string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for cryptoKeyName to set. + * @return This builder for chaining. + */ + public Builder setCryptoKeyNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + cryptoKeyName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
+     * Output only. Creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+     * Output only. Creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000004); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
+     * Output only. Creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
+     * Output only. Most recent update timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
+     * Output only. Most recent update timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Most recent update timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + } else { + updateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Most recent update timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Most recent update timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && updateTime_ != null + && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getUpdateTimeBuilder().mergeFrom(value); + } else { + updateTime_ = value; + } + } else { + updateTimeBuilder_.mergeFrom(value); + } + if (updateTime_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Most recent update timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000008); + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Most recent update timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Most recent update timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + + /** + * + * + *
+     * Output only. Most recent update timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.SkillEncryptionSpec) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.SkillEncryptionSpec) + private static final com.google.cloud.agentregistry.v1.SkillEncryptionSpec DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.SkillEncryptionSpec(); + } + + public static com.google.cloud.agentregistry.v1.SkillEncryptionSpec getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SkillEncryptionSpec parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillEncryptionSpec getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpecName.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpecName.java new file mode 100644 index 000000000000..f06d734291ad --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpecName.java @@ -0,0 +1,196 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class SkillEncryptionSpecName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/skillEncryptionSpec"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + + @Deprecated + protected SkillEncryptionSpecName() { + project = null; + location = null; + } + + private SkillEncryptionSpecName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static SkillEncryptionSpecName of(String project, String location) { + return newBuilder().setProject(project).setLocation(location).build(); + } + + public static String format(String project, String location) { + return newBuilder().setProject(project).setLocation(location).build().toString(); + } + + public static @Nullable SkillEncryptionSpecName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION.validatedMatch( + formattedString, "SkillEncryptionSpecName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable SkillEncryptionSpecName> values) { + List list = new ArrayList<>(values.size()); + for (SkillEncryptionSpecName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION.instantiate("project", project, "location", location); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + SkillEncryptionSpecName that = ((SkillEncryptionSpecName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + return h; + } + + /** Builder for projects/{project}/locations/{location}/skillEncryptionSpec. */ + public static class Builder { + private String project; + private String location; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + private Builder(SkillEncryptionSpecName skillEncryptionSpecName) { + this.project = skillEncryptionSpecName.project; + this.location = skillEncryptionSpecName.location; + } + + public SkillEncryptionSpecName build() { + return new SkillEncryptionSpecName(this); + } + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpecOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpecOrBuilder.java new file mode 100644 index 000000000000..85e090053847 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpecOrBuilder.java @@ -0,0 +1,178 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill_encryption_spec.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface SkillEncryptionSpecOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.SkillEncryptionSpec) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Identifier. Resource name of the SkillEncryptionSpec.
+   * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Identifier. Resource name of the SkillEncryptionSpec.
+   * Format: `projects/{project}/locations/{location}/skillEncryptionSpec`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Required. The Cloud KMS CryptoKey resource name used to protect Skill
+   * payloads in this project and location.
+   * This field can be set or updated only when no Skills exist in the target
+   * project and location. Once any Skill exists in the location, updating this
+   * field is rejected with `FAILED_PRECONDITION`.
+   * Format:
+   * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey}`
+   * 
+ * + * + * string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The cryptoKeyName. + */ + java.lang.String getCryptoKeyName(); + + /** + * + * + *
+   * Required. The Cloud KMS CryptoKey resource name used to protect Skill
+   * payloads in this project and location.
+   * This field can be set or updated only when no Skills exist in the target
+   * project and location. Once any Skill exists in the location, updating this
+   * field is rejected with `FAILED_PRECONDITION`.
+   * Format:
+   * `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey}`
+   * 
+ * + * + * string crypto_key_name = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for cryptoKeyName. + */ + com.google.protobuf.ByteString getCryptoKeyNameBytes(); + + /** + * + * + *
+   * Output only. Creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
+   * Output only. Creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
+   * Output only. Creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. Most recent update timestamp.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + + /** + * + * + *
+   * Output only. Most recent update timestamp.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + + /** + * + * + *
+   * Output only. Most recent update timestamp.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpecProto.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpecProto.java new file mode 100644 index 000000000000..f6333b99d3e1 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillEncryptionSpecProto.java @@ -0,0 +1,112 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill_encryption_spec.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public final class SkillEncryptionSpecProto extends com.google.protobuf.GeneratedFile { + private SkillEncryptionSpecProto() {} + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SkillEncryptionSpecProto"); + } + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_SkillEncryptionSpec_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_SkillEncryptionSpec_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n9google/cloud/agentregistry/v1/skill_en" + + "cryption_spec.proto\022\035google.cloud.agentr" + + "egistry.v1\032\037google/api/field_behavior.pr" + + "oto\032\031google/api/resource.proto\032\037google/p" + + "rotobuf/timestamp.proto\"\375\002\n\023SkillEncrypt" + + "ionSpec\022\022\n\004name\030\001 \001(\tB\004\342A\001\010\022C\n\017crypto_ke" + + "y_name\030\002 \001(\tB*\342A\001\002\372A#\n!cloudkms.googleap" + + "is.com/CryptoKey\0225\n\013create_time\030\003 \001(\0132\032." + + "google.protobuf.TimestampB\004\342A\001\003\0225\n\013updat" + + "e_time\030\004 \001(\0132\032.google.protobuf.Timestamp" + + "B\004\342A\001\003:\236\001\352A\232\001\n0agentregistry.googleapis." + + "com/SkillEncryptionSpec\022;projects/{proje" + + "ct}/locations/{location}/skillEncryption" + + "Spec*\024skillEncryptionSpecs2\023skillEncrypt" + + "ionSpecB\346\002\n!com.google.cloud.agentregist" + + "ry.v1B\030SkillEncryptionSpecProtoP\001ZGcloud" + + ".google.com/go/agentregistry/apiv1/agent" + + "registrypb;agentregistrypb\252\002\035Google.Clou" + + "d.AgentRegistry.V1\312\002\035Google\\Cloud\\AgentR" + + "egistry\\V1\352\002 Google::Cloud::AgentRegistr" + + "y::V1\352Ax\n!cloudkms.googleapis.com/Crypto" + + "Key\022Sprojects/{project}/locations/{locat" + + "ion}/keyRings/{key_ring}/cryptoKeys/{cry" + + "pto_key}b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_agentregistry_v1_SkillEncryptionSpec_descriptor = + getDescriptor().getMessageType(0); + internal_static_google_cloud_agentregistry_v1_SkillEncryptionSpec_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_SkillEncryptionSpec_descriptor, + new java.lang.String[] { + "Name", "CryptoKeyName", "CreateTime", "UpdateTime", + }); + descriptor.resolveAllFeaturesImmutable(); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceDefinition); + registry.add(com.google.api.ResourceProto.resourceReference); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillName.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillName.java new file mode 100644 index 000000000000..fc13c52425f7 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillName.java @@ -0,0 +1,226 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class SkillName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_SKILL = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/skills/{skill}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String skill; + + @Deprecated + protected SkillName() { + project = null; + location = null; + skill = null; + } + + private SkillName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + skill = Preconditions.checkNotNull(builder.getSkill()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getSkill() { + return skill; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static SkillName of(String project, String location, String skill) { + return newBuilder().setProject(project).setLocation(location).setSkill(skill).build(); + } + + public static String format(String project, String location, String skill) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setSkill(skill) + .build() + .toString(); + } + + public static @Nullable SkillName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_SKILL.validatedMatch( + formattedString, "SkillName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("skill")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable SkillName> values) { + List list = new ArrayList<>(values.size()); + for (SkillName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_SKILL.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (skill != null) { + fieldMapBuilder.put("skill", skill); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_SKILL.instantiate( + "project", project, "location", location, "skill", skill); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + SkillName that = ((SkillName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.skill, that.skill); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(skill); + return h; + } + + /** Builder for projects/{project}/locations/{location}/skills/{skill}. */ + public static class Builder { + private String project; + private String location; + private String skill; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getSkill() { + return skill; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setSkill(String skill) { + this.skill = skill; + return this; + } + + private Builder(SkillName skillName) { + this.project = skillName.project; + this.location = skillName.location; + this.skill = skillName.skill; + } + + public SkillName build() { + return new SkillName(this); + } + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillOrBuilder.java new file mode 100644 index 000000000000..970bff945aac --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillOrBuilder.java @@ -0,0 +1,568 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface SkillOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.Skill) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Identifier. Resource name of the Skill.
+   * Format: `projects/{project}/locations/{location}/skills/{skill}`
+   * The `{skill}` segment acts as the resource ID. If the skill is associated
+   * with a Publisher, this segment typically uses a hyphenated namespace prefix
+   * corresponding to the publisher (e.g., `google-workspace-create-docs`).
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Identifier. Resource name of the Skill.
+   * Format: `projects/{project}/locations/{location}/skills/{skill}`
+   * The `{skill}` segment acts as the resource ID. If the skill is associated
+   * with a Publisher, this segment typically uses a hyphenated namespace prefix
+   * corresponding to the publisher (e.g., `google-workspace-create-docs`).
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the logical
+   * container.
+   * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + java.lang.String getUid(); + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the logical
+   * container.
+   * 
+ * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + com.google.protobuf.ByteString getUidBytes(); + + /** + * + * + *
+   * Optional. Human-readable display name of the skill.
+   * Maximum length is 128 characters.
+   * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
+   * Optional. Human-readable display name of the skill.
+   * Maximum length is 128 characters.
+   * 
+ * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
+   * Optional. Brief summary describing the capabilities of the skill.
+   * Maximum length is 2048 characters.
+   * 
+ * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
+   * Optional. Brief summary describing the capabilities of the skill.
+   * Maximum length is 2048 characters.
+   * 
+ * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
+   * Required. Structural deployment type (SIMPLE leaf vs COMPOSITE bundle).
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.Type type = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for type. + */ + int getTypeValue(); + + /** + * + * + *
+   * Required. Structural deployment type (SIMPLE leaf vs COMPOSITE bundle).
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.Type type = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The type. + */ + com.google.cloud.agentregistry.v1.Skill.Type getType(); + + /** + * + * + *
+   * Output only. The system-managed state of the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
+   * Output only. The system-managed state of the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.agentregistry.v1.Skill.State getState(); + + /** + * + * + *
+   * Required. User-managed target state of the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.TargetState target_state = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for targetState. + */ + int getTargetStateValue(); + + /** + * + * + *
+   * Required. User-managed target state of the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Skill.TargetState target_state = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The targetState. + */ + com.google.cloud.agentregistry.v1.Skill.TargetState getTargetState(); + + /** + * + * + *
+   * Optional. The full resource name of the revision currently served by
+   * default (floating track).
+   * Format:
+   * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+   * 
+ * + * + * string default_revision = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The defaultRevision. + */ + java.lang.String getDefaultRevision(); + + /** + * + * + *
+   * Optional. The full resource name of the revision currently served by
+   * default (floating track).
+   * Format:
+   * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+   * 
+ * + * + * string default_revision = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for defaultRevision. + */ + com.google.protobuf.ByteString getDefaultRevisionBytes(); + + /** + * + * + *
+   * Output only. Lightweight frontmatter metadata attributes copied from the
+   * default revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the frontmatter field is set. + */ + boolean hasFrontmatter(); + + /** + * + * + *
+   * Output only. Lightweight frontmatter metadata attributes copied from the
+   * default revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The frontmatter. + */ + com.google.cloud.agentregistry.v1.Frontmatter getFrontmatter(); + + /** + * + * + *
+   * Output only. Lightweight frontmatter metadata attributes copied from the
+   * default revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.agentregistry.v1.FrontmatterOrBuilder getFrontmatterOrBuilder(); + + /** + * + * + *
+   * Output only. A stable, globally unique logical identifier for the skill.
+   * It is securely constructed by the backend by combining the associated
+   * `publisher`'s verified namespace and the skill's resource ID to enforce
+   * strict ownership. For example, the prefix `google-` is reserved exclusively
+   * for first-party Google publishers to prevent namespace squatting.
+   * Example: `urn:skill:google-workspace:create-docs`
+   * 
+ * + * string skill_id = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The skillId. + */ + java.lang.String getSkillId(); + + /** + * + * + *
+   * Output only. A stable, globally unique logical identifier for the skill.
+   * It is securely constructed by the backend by combining the associated
+   * `publisher`'s verified namespace and the skill's resource ID to enforce
+   * strict ownership. For example, the prefix `google-` is reserved exclusively
+   * for first-party Google publishers to prevent namespace squatting.
+   * Example: `urn:skill:google-workspace:create-docs`
+   * 
+ * + * string skill_id = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for skillId. + */ + com.google.protobuf.ByteString getSkillIdBytes(); + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
+   * Output only. Create time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + + /** + * + * + *
+   * Output only. Update time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
+   * Optional. The publisher resource associated with this skill.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * The publisher dictates the allowed namespace prefixes for the skill's name
+   * and logical `skill_id` (e.g., Publisher `google` authorizes the `google-*`
+   * prefix).
+   * 
+ * + * + * string publisher = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The publisher. + */ + java.lang.String getPublisher(); + + /** + * + * + *
+   * Optional. The publisher resource associated with this skill.
+   * Format: `projects/{project}/locations/{location}/publishers/{publisher}`
+   * The publisher dictates the allowed namespace prefixes for the skill's name
+   * and logical `skill_id` (e.g., Publisher `google` authorizes the `google-*`
+   * prefix).
+   * 
+ * + * + * string publisher = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for publisher. + */ + com.google.protobuf.ByteString getPublisherBytes(); + + /** + * + * + *
+   * Optional. Input only. Optional nested initial revision payload to support
+   * standard one-shot creation. The server processes this field on input during
+   * creation but must never return it in responses.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + * + * @return Whether the initialRevision field is set. + */ + boolean hasInitialRevision(); + + /** + * + * + *
+   * Optional. Input only. Optional nested initial revision payload to support
+   * standard one-shot creation. The server processes this field on input during
+   * creation but must never return it in responses.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + * + * @return The initialRevision. + */ + com.google.cloud.agentregistry.v1.SkillRevision getInitialRevision(); + + /** + * + * + *
+   * Optional. Input only. Optional nested initial revision payload to support
+   * standard one-shot creation. The server processes this field on input during
+   * creation but must never return it in responses.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision initial_revision = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = INPUT_ONLY]; + * + */ + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder getInitialRevisionOrBuilder(); + + /** + * + * + *
+   * Optional. Optional. Scanning configuration for the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the scanningConfig field is set. + */ + boolean hasScanningConfig(); + + /** + * + * + *
+   * Optional. Optional. Scanning configuration for the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The scanningConfig. + */ + com.google.cloud.agentregistry.v1.ScanningConfig getScanningConfig(); + + /** + * + * + *
+   * Optional. Optional. Scanning configuration for the skill.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ScanningConfig scanning_config = 20 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.agentregistry.v1.ScanningConfigOrBuilder getScanningConfigOrBuilder(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillProto.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillProto.java new file mode 100644 index 000000000000..0b070f08a272 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillProto.java @@ -0,0 +1,353 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public final class SkillProto extends com.google.protobuf.GeneratedFile { + private SkillProto() {} + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SkillProto"); + } + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_Skill_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_Skill_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ScanningConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ScanningConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_Frontmatter_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_Frontmatter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_Frontmatter_MetadataEntry_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_Frontmatter_MetadataEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_ArchiveUploadSource_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_ArchiveUploadSource_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_SkillRevision_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_SkillRevision_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_SkillRevision_ScanResult_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_SkillRevision_ScanResult_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_GcsSource_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_GcsSource_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_agentregistry_v1_Publisher_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_agentregistry_v1_Publisher_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n" + + ")google/cloud/agentregistry/v1/skill.pr" + + "oto\022\035google.cloud.agentregistry.v1\032\037goog" + + "le/api/field_behavior.proto\032\033google/api/" + + "field_info.proto\032\031google/api/resource.proto\032\037google/protobuf/timestamp.proto\"\272\n\n" + + "\005Skill\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\022\031\n" + + "\003uid\030\002 \001(\tB\014\342A\001\003\342\214\317\327\010\002\010\001\022\032\n" + + "\014display_name\030\003 \001(\tB\004\342A\001\001\022\031\n" + + "\013description\030\004 \001(\tB\004\342A\001\001\022=\n" + + "\004type\030\005 \001" + + "(\0162).google.cloud.agentregistry.v1.Skill.TypeB\004\342A\001\002\022?\n" + + "\005state\030\006" + + " \001(\0162*.google.cloud.agentregistry.v1.Skill.StateB\004\342A\001\003\022L\n" + + "\014target_state\030\007" + + " \001(\01620.google.cloud.agentregistry.v1.Skill.TargetStateB\004\342A\001\002\022M\n" + + "\020default_revision\030\010 \001(\tB3\342A\001\001\372A,\n" + + "*agentregistry.googleapis.com/SkillRevision\022E\n" + + "\013frontmatter\030\t" + + " \001(\0132*.google.cloud.agentregistry.v1.FrontmatterB\004\342A\001\003\022\026\n" + + "\010skill_id\030\021 \001(\tB\004\342A\001\003\0225\n" + + "\013create_time\030\013" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + + "\013update_time\030\014" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022B\n" + + "\tpublisher\030\017 \001(\tB/\342A\001\001\372A(\n" + + "&agentregistry.googleapis.com/Publisher\022M\n" + + "\020initial_revision\030\016" + + " \001(\0132,.google.cloud.agentregistry.v1.SkillRevisionB\005\342A\002\001\004\022L\n" + + "\017scanning_config\030\024" + + " \001(\0132-.google.cloud.agentregistry.v1.ScanningConfigB\004\342A\001\001\"(\n" + + "\004Type\022\024\n" + + "\020TYPE_UNSPECIFIED\020\000\022\n\n" + + "\006SIMPLE\020\001\"\255\001\n" + + "\005State\022\025\n" + + "\021STATE_UNSPECIFIED\020\000\022\022\n" + + "\016STATE_CREATING\020\001\022\017\n" + + "\013STATE_DRAFT\020\002\022\020\n" + + "\014STATE_ACTIVE\020\003\022\022\n" + + "\016STATE_DISABLED\020\004\022\024\n" + + "\020STATE_DEPRECATED\020\005\022\030\n" + + "\024STATE_DECOMMISSIONED\020\006\022\022\n" + + "\016STATE_DELETING\020\007\"\265\001\n" + + "\013TargetState\022\034\n" + + "\030TARGET_STATE_UNSPECIFIED\020\000\022\026\n" + + "\022TARGET_STATE_DRAFT\020\001\022\027\n" + + "\023TARGET_STATE_ACTIVE\020\002\022\031\n" + + "\025TARGET_STATE_DISABLED\020\003\022\033\n" + + "\027TARGET_STATE_DEPRECATED\020\004\022\037\n" + + "\033TARGET_STATE_DECOMMISSIONED\020\005:n\352Ak\n" + + "\"agentregistry.googleapis.com/Skill\0226projects/{pr" + + "oject}/locations/{location}/skills/{skill}*\006skills2\005skill\"\273\001\n" + + "\016ScanningConfig\022J\n" + + "\006policy\030\001" + + " \001(\01624.google.cloud.agentregistry.v1.ScanningConfig.PolicyB\004\342A\001\001\"]\n" + + "\006Policy\022\026\n" + + "\022POLICY_UNSPECIFIED\020\000\022\014\n" + + "\010DISABLED\020\001\022\024\n" + + "\020ENABLED_BLOCKING\020\002\022\027\n" + + "\023ENABLED_NONBLOCKING\020\003\"\363\001\n" + + "\013Frontmatter\022\022\n" + + "\004name\030\005 \001(\tB\004\342A\001\002\022\031\n" + + "\013description\030\002 \001(\tB\004\342A\001\002\022\025\n" + + "\007license\030\006 \001(\tB\004\342A\001\001\022\033\n\r" + + "compatibility\030\003 \001(\tB\004\342A\001\001\022P\n" + + "\010metadata\030\004 \003(\01328.google.cloud.agen" + + "tregistry.v1.Frontmatter.MetadataEntryB\004\342A\001\001\032/\n\r" + + "MetadataEntry\022\013\n" + + "\003key\030\001 \001(\t\022\r\n" + + "\005value\030\002 \001(\t:\0028\001\"5\n" + + "\023ArchiveUploadSource\022\036\n" + + "\017archive_content\030\001 \001(\014B\005\342A\002\002\004\"\244\t\n\r" + + "SkillRevision\022E\n\n" + + "gcs_source\030\t" + + " \001(\0132(.google.cloud.agentregistry.v1.GcsSourceB\005\342A\002\005\001H\000\022Z\n" + + "\025archive_upload_source\030\014 \001(\01322.google.cl" + + "oud.agentregistry.v1.ArchiveUploadSourceB\005\342A\002\005\001H\000\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\022G\n" + + "\005state\030\002" + + " \001(\01622.google.cloud.agentregistry.v1.SkillRevision.StateB\004\342A\001\003\022\031\n" + + "\013sha256_hash\030\003 \001(\tB\004\342A\001\003\022E\n" + + "\013frontmatter\030\004 \001(\0132*.google." + + "cloud.agentregistry.v1.FrontmatterB\004\342A\001\003\0225\n" + + "\013create_time\030\006" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022\030\n\n" + + "size_bytes\030\013 \001(\003B\004\342A\001\003\022\031\n" + + "\003uid\030\016 \001(\tB\014\342A\001\003\342\214\317\327\010\002\010\001\022R\n" + + "\013scan_result\030\017" + + " \001(\01327.google.cloud.agentregistry.v1.SkillRevision.ScanResultB\004\342A\001\003\032\363\002\n\n" + + "ScanResult\022[\n\n" + + "scan_state\030\001 \001(\0162A.google.clo" + + "ud.agentregistry.v1.SkillRevision.ScanResult.ScanStateB\004\342A\001\003\0223\n" + + "\tscan_time\030\002" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022\033\n\r" + + "error_message\030\003 \001(\tB\004\342A\001\003\022?\n" + + "\010findings\030\004 \003(\tB-\342A\001\003\372A&\n" + + "$agentregistry.googleapis.com/Finding\"u\n" + + "\tScanState\022\032\n" + + "\026SCAN_STATE_UNSPECIFIED\020\000\022\n\n" + + "\006FAILED\020\001\022\026\n" + + "\022UNSUPPORTED_FORMAT\020\002\022\r\n" + + "\tSUCCEEDED\020\003\022\014\n" + + "\010DISABLED\020\004\022\013\n" + + "\007RUNNING\020\005\"R\n" + + "\005State\022\025\n" + + "\021STATE_UNSPECIFIED\020\000\022\014\n" + + "\010CREATING\020\001\022\n\n" + + "\006ACTIVE\020\002\022\n\n" + + "\006FAILED\020\003\022\014\n" + + "\010DELETING\020\004:\234\001\352A\230\001\n" + + "*agentregistry.googleapis.com/SkillRevision\022Kprojects/{project" + + "}/locations/{location}/skills/{skill}/revisions/{revision}*\016skillRevisions2\r" + + "skillRevisionB\010\n" + + "\006source\"8\n" + + "\tGcsSource\022\021\n" + + "\003uri\030\001 \001(\tB\004\342A\001\002\022\030\n\n" + + "generation\030\002 \001(\003B\004\342A\001\001\"\321\003\n" + + "\tPublisher\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\022\035\n" + + "\017verified_prefix\030\002 \001(\tB\004\342A\001\002\022\032\n" + + "\014display_name\030\003 \001(\tB\004\342A\001\001\022T\n" + + "\016publisher_tier\030\004 \001(\01626.goo" + + "gle.cloud.agentregistry.v1.Publisher.PublisherTierB\004\342A\001\003\022\037\n" + + "\021documentation_uri\030\005 \001(\tB\004\342A\001\001\022\031\n" + + "\013support_uri\030\006 \001(\tB\004\342A\001\001\"^\n\r" + + "PublisherTier\022\036\n" + + "\032PUBLISHER_TIER_UNSPECIFIED\020\000\022\017\n" + + "\013FIRST_PARTY\020\001\022\017\n" + + "\013THIRD_PARTY\020\002\022\013\n" + + "\007PRIVATE\020\003:\202\001\352A\177\n" + + "&agentregistry.googleapis.com/Publisher\022>projects/{project}/l" + + "ocations/{location}/publishers/{publisher}*\n" + + "publishers2\tpublisherB\335\001\n" + + "!com.google.cloud.agentregistry.v1B\n" + + "SkillProtoP\001ZGcloud.google.com/go/agentregistry/apiv1/a" + + "gentregistrypb;agentregistrypb\252\002\035Google." + + "Cloud.AgentRegistry.V1\312\002\035Google\\Cloud\\AgentRegistry\\V1\352\002" + + " Google::Cloud::AgentRegistry::V1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.FieldInfoProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_agentregistry_v1_Skill_descriptor = + getDescriptor().getMessageType(0); + internal_static_google_cloud_agentregistry_v1_Skill_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_Skill_descriptor, + new java.lang.String[] { + "Name", + "Uid", + "DisplayName", + "Description", + "Type", + "State", + "TargetState", + "DefaultRevision", + "Frontmatter", + "SkillId", + "CreateTime", + "UpdateTime", + "Publisher", + "InitialRevision", + "ScanningConfig", + }); + internal_static_google_cloud_agentregistry_v1_ScanningConfig_descriptor = + getDescriptor().getMessageType(1); + internal_static_google_cloud_agentregistry_v1_ScanningConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ScanningConfig_descriptor, + new java.lang.String[] { + "Policy", + }); + internal_static_google_cloud_agentregistry_v1_Frontmatter_descriptor = + getDescriptor().getMessageType(2); + internal_static_google_cloud_agentregistry_v1_Frontmatter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_Frontmatter_descriptor, + new java.lang.String[] { + "Name", "Description", "License", "Compatibility", "Metadata", + }); + internal_static_google_cloud_agentregistry_v1_Frontmatter_MetadataEntry_descriptor = + internal_static_google_cloud_agentregistry_v1_Frontmatter_descriptor.getNestedType(0); + internal_static_google_cloud_agentregistry_v1_Frontmatter_MetadataEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_Frontmatter_MetadataEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_agentregistry_v1_ArchiveUploadSource_descriptor = + getDescriptor().getMessageType(3); + internal_static_google_cloud_agentregistry_v1_ArchiveUploadSource_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_ArchiveUploadSource_descriptor, + new java.lang.String[] { + "ArchiveContent", + }); + internal_static_google_cloud_agentregistry_v1_SkillRevision_descriptor = + getDescriptor().getMessageType(4); + internal_static_google_cloud_agentregistry_v1_SkillRevision_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_SkillRevision_descriptor, + new java.lang.String[] { + "GcsSource", + "ArchiveUploadSource", + "Name", + "State", + "Sha256Hash", + "Frontmatter", + "CreateTime", + "SizeBytes", + "Uid", + "ScanResult", + "Source", + }); + internal_static_google_cloud_agentregistry_v1_SkillRevision_ScanResult_descriptor = + internal_static_google_cloud_agentregistry_v1_SkillRevision_descriptor.getNestedType(0); + internal_static_google_cloud_agentregistry_v1_SkillRevision_ScanResult_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_SkillRevision_ScanResult_descriptor, + new java.lang.String[] { + "ScanState", "ScanTime", "ErrorMessage", "Findings", + }); + internal_static_google_cloud_agentregistry_v1_GcsSource_descriptor = + getDescriptor().getMessageType(5); + internal_static_google_cloud_agentregistry_v1_GcsSource_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_GcsSource_descriptor, + new java.lang.String[] { + "Uri", "Generation", + }); + internal_static_google_cloud_agentregistry_v1_Publisher_descriptor = + getDescriptor().getMessageType(6); + internal_static_google_cloud_agentregistry_v1_Publisher_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_agentregistry_v1_Publisher_descriptor, + new java.lang.String[] { + "Name", + "VerifiedPrefix", + "DisplayName", + "PublisherTier", + "DocumentationUri", + "SupportUri", + }); + descriptor.resolveAllFeaturesImmutable(); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.FieldInfoProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.FieldInfoProto.fieldInfo); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceReference); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillRevision.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillRevision.java new file mode 100644 index 000000000000..e11850ae2ad3 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillRevision.java @@ -0,0 +1,4966 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Represents an immutable, versioned snapshot of a Skill package.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.SkillRevision} + */ +@com.google.protobuf.Generated +public final class SkillRevision extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.SkillRevision) + SkillRevisionOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SkillRevision"); + } + + // Use SkillRevision.newBuilder() to construct. + private SkillRevision(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private SkillRevision() { + name_ = ""; + state_ = 0; + sha256Hash_ = ""; + uid_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_SkillRevision_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_SkillRevision_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.SkillRevision.class, + com.google.cloud.agentregistry.v1.SkillRevision.Builder.class); + } + + /** + * + * + *
+   * System-managed computed state.
+   * 
+ * + * Protobuf enum {@code google.cloud.agentregistry.v1.SkillRevision.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
+     * The revision is being created.
+     * 
+ * + * CREATING = 1; + */ + CREATING(1), + /** + * + * + *
+     * The revision is active.
+     * 
+ * + * ACTIVE = 2; + */ + ACTIVE(2), + /** + * + * + *
+     * The revision failed to compile or ingest.
+     * 
+ * + * FAILED = 3; + */ + FAILED(3), + /** + * + * + *
+     * The revision is being deleted.
+     * 
+ * + * DELETING = 4; + */ + DELETING(4), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "State"); + } + + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The revision is being created.
+     * 
+ * + * CREATING = 1; + */ + public static final int CREATING_VALUE = 1; + + /** + * + * + *
+     * The revision is active.
+     * 
+ * + * ACTIVE = 2; + */ + public static final int ACTIVE_VALUE = 2; + + /** + * + * + *
+     * The revision failed to compile or ingest.
+     * 
+ * + * FAILED = 3; + */ + public static final int FAILED_VALUE = 3; + + /** + * + * + *
+     * The revision is being deleted.
+     * 
+ * + * DELETING = 4; + */ + public static final int DELETING_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return CREATING; + case 2: + return ACTIVE; + case 3: + return FAILED; + case 4: + return DELETING; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public State findValueByNumber(int number) { + return State.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillRevision.getDescriptor().getEnumTypes().get(0); + } + + private static final State[] VALUES = values(); + + public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private State(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.agentregistry.v1.SkillRevision.State) + } + + public interface ScanResultOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.SkillRevision.ScanResult) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Output only. The state of the vulnerability check.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState scan_state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for scanState. + */ + int getScanStateValue(); + + /** + * + * + *
+     * Output only. The state of the vulnerability check.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState scan_state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The scanState. + */ + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState getScanState(); + + /** + * + * + *
+     * Output only. The time when the scan was completed.
+     * 
+ * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the scanTime field is set. + */ + boolean hasScanTime(); + + /** + * + * + *
+     * Output only. The time when the scan was completed.
+     * 
+ * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The scanTime. + */ + com.google.protobuf.Timestamp getScanTime(); + + /** + * + * + *
+     * Output only. The time when the scan was completed.
+     * 
+ * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getScanTimeOrBuilder(); + + /** + * + * + *
+     * Output only. The error message if the scan failed.
+     * 
+ * + * string error_message = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The errorMessage. + */ + java.lang.String getErrorMessage(); + + /** + * + * + *
+     * Output only. The error message if the scan failed.
+     * 
+ * + * string error_message = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for errorMessage. + */ + com.google.protobuf.ByteString getErrorMessageBytes(); + + /** + * + * + *
+     * Output only. The finding resource names for the skill revision.
+     * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the findings. + */ + java.util.List getFindingsList(); + + /** + * + * + *
+     * Output only. The finding resource names for the skill revision.
+     * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The count of findings. + */ + int getFindingsCount(); + + /** + * + * + *
+     * Output only. The finding resource names for the skill revision.
+     * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The findings at the given index. + */ + java.lang.String getFindings(int index); + + /** + * + * + *
+     * Output only. The finding resource names for the skill revision.
+     * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the findings at the given index. + */ + com.google.protobuf.ByteString getFindingsBytes(int index); + } + + /** + * + * + *
+   * Scan result of the skill revision.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.SkillRevision.ScanResult} + */ + public static final class ScanResult extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.SkillRevision.ScanResult) + ScanResultOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ScanResult"); + } + + // Use ScanResult.newBuilder() to construct. + private ScanResult(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ScanResult() { + scanState_ = 0; + errorMessage_ = ""; + findings_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_SkillRevision_ScanResult_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_SkillRevision_ScanResult_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.class, + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.Builder.class); + } + + /** + * + * + *
+     * Represents the lifecycle state of the vulnerability scan.
+     * 
+ * + * Protobuf enum {@code google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState} + */ + public enum ScanState implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Should not be used.
+       * 
+ * + * SCAN_STATE_UNSPECIFIED = 0; + */ + SCAN_STATE_UNSPECIFIED(0), + /** + * + * + *
+       * The underlying scanning system failed to execute the scan.
+       * 
+ * + * FAILED = 1; + */ + FAILED(1), + /** + * + * + *
+       * The uploaded artifact format is unsupported by the scanning system.
+       * 
+ * + * UNSUPPORTED_FORMAT = 2; + */ + UNSUPPORTED_FORMAT(2), + /** + * + * + *
+       * The scan has completed successfully.
+       * 
+ * + * SUCCEEDED = 3; + */ + SUCCEEDED(3), + /** + * + * + *
+       * The scan was disabled.
+       * 
+ * + * DISABLED = 4; + */ + DISABLED(4), + /** + * + * + *
+       * The scan is running.
+       * 
+ * + * RUNNING = 5; + */ + RUNNING(5), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ScanState"); + } + + /** + * + * + *
+       * Should not be used.
+       * 
+ * + * SCAN_STATE_UNSPECIFIED = 0; + */ + public static final int SCAN_STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+       * The underlying scanning system failed to execute the scan.
+       * 
+ * + * FAILED = 1; + */ + public static final int FAILED_VALUE = 1; + + /** + * + * + *
+       * The uploaded artifact format is unsupported by the scanning system.
+       * 
+ * + * UNSUPPORTED_FORMAT = 2; + */ + public static final int UNSUPPORTED_FORMAT_VALUE = 2; + + /** + * + * + *
+       * The scan has completed successfully.
+       * 
+ * + * SUCCEEDED = 3; + */ + public static final int SUCCEEDED_VALUE = 3; + + /** + * + * + *
+       * The scan was disabled.
+       * 
+ * + * DISABLED = 4; + */ + public static final int DISABLED_VALUE = 4; + + /** + * + * + *
+       * The scan is running.
+       * 
+ * + * RUNNING = 5; + */ + public static final int RUNNING_VALUE = 5; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ScanState valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static ScanState forNumber(int value) { + switch (value) { + case 0: + return SCAN_STATE_UNSPECIFIED; + case 1: + return FAILED; + case 2: + return UNSUPPORTED_FORMAT; + case 3: + return SUCCEEDED; + case 4: + return DISABLED; + case 5: + return RUNNING; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public ScanState findValueByNumber(int number) { + return ScanState.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final ScanState[] VALUES = values(); + + public static ScanState valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private ScanState(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState) + } + + private int bitField0_; + public static final int SCAN_STATE_FIELD_NUMBER = 1; + private int scanState_ = 0; + + /** + * + * + *
+     * Output only. The state of the vulnerability check.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState scan_state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for scanState. + */ + @java.lang.Override + public int getScanStateValue() { + return scanState_; + } + + /** + * + * + *
+     * Output only. The state of the vulnerability check.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState scan_state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The scanState. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState getScanState() { + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState result = + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState.forNumber( + scanState_); + return result == null + ? com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState.UNRECOGNIZED + : result; + } + + public static final int SCAN_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp scanTime_; + + /** + * + * + *
+     * Output only. The time when the scan was completed.
+     * 
+ * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the scanTime field is set. + */ + @java.lang.Override + public boolean hasScanTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+     * Output only. The time when the scan was completed.
+     * 
+ * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The scanTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getScanTime() { + return scanTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : scanTime_; + } + + /** + * + * + *
+     * Output only. The time when the scan was completed.
+     * 
+ * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getScanTimeOrBuilder() { + return scanTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : scanTime_; + } + + public static final int ERROR_MESSAGE_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object errorMessage_ = ""; + + /** + * + * + *
+     * Output only. The error message if the scan failed.
+     * 
+ * + * string error_message = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The errorMessage. + */ + @java.lang.Override + public java.lang.String getErrorMessage() { + java.lang.Object ref = errorMessage_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + errorMessage_ = s; + return s; + } + } + + /** + * + * + *
+     * Output only. The error message if the scan failed.
+     * 
+ * + * string error_message = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for errorMessage. + */ + @java.lang.Override + public com.google.protobuf.ByteString getErrorMessageBytes() { + java.lang.Object ref = errorMessage_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + errorMessage_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FINDINGS_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList findings_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+     * Output only. The finding resource names for the skill revision.
+     * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the findings. + */ + public com.google.protobuf.ProtocolStringList getFindingsList() { + return findings_; + } + + /** + * + * + *
+     * Output only. The finding resource names for the skill revision.
+     * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The count of findings. + */ + public int getFindingsCount() { + return findings_.size(); + } + + /** + * + * + *
+     * Output only. The finding resource names for the skill revision.
+     * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The findings at the given index. + */ + public java.lang.String getFindings(int index) { + return findings_.get(index); + } + + /** + * + * + *
+     * Output only. The finding resource names for the skill revision.
+     * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the findings at the given index. + */ + public com.google.protobuf.ByteString getFindingsBytes(int index) { + return findings_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (scanState_ + != com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState + .SCAN_STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, scanState_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getScanTime()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(errorMessage_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, errorMessage_); + } + for (int i = 0; i < findings_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, findings_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (scanState_ + != com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState + .SCAN_STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, scanState_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getScanTime()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(errorMessage_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, errorMessage_); + } + { + int dataSize = 0; + for (int i = 0; i < findings_.size(); i++) { + dataSize += computeStringSizeNoTag(findings_.getRaw(i)); + } + size += dataSize; + size += 1 * getFindingsList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.SkillRevision.ScanResult)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult other = + (com.google.cloud.agentregistry.v1.SkillRevision.ScanResult) obj; + + if (scanState_ != other.scanState_) return false; + if (hasScanTime() != other.hasScanTime()) return false; + if (hasScanTime()) { + if (!getScanTime().equals(other.getScanTime())) return false; + } + if (!getErrorMessage().equals(other.getErrorMessage())) return false; + if (!getFindingsList().equals(other.getFindingsList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + SCAN_STATE_FIELD_NUMBER; + hash = (53 * hash) + scanState_; + if (hasScanTime()) { + hash = (37 * hash) + SCAN_TIME_FIELD_NUMBER; + hash = (53 * hash) + getScanTime().hashCode(); + } + hash = (37 * hash) + ERROR_MESSAGE_FIELD_NUMBER; + hash = (53 * hash) + getErrorMessage().hashCode(); + if (getFindingsCount() > 0) { + hash = (37 * hash) + FINDINGS_FIELD_NUMBER; + hash = (53 * hash) + getFindingsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+     * Scan result of the skill revision.
+     * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.SkillRevision.ScanResult} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.SkillRevision.ScanResult) + com.google.cloud.agentregistry.v1.SkillRevision.ScanResultOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_SkillRevision_ScanResult_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_SkillRevision_ScanResult_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.class, + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetScanTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + scanState_ = 0; + scanTime_ = null; + if (scanTimeBuilder_ != null) { + scanTimeBuilder_.dispose(); + scanTimeBuilder_ = null; + } + errorMessage_ = ""; + findings_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_SkillRevision_ScanResult_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision.ScanResult + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision.ScanResult build() { + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision.ScanResult buildPartial() { + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult result = + new com.google.cloud.agentregistry.v1.SkillRevision.ScanResult(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.scanState_ = scanState_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.scanTime_ = scanTimeBuilder_ == null ? scanTime_ : scanTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.errorMessage_ = errorMessage_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + findings_.makeImmutable(); + result.findings_ = findings_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.SkillRevision.ScanResult) { + return mergeFrom((com.google.cloud.agentregistry.v1.SkillRevision.ScanResult) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.SkillRevision.ScanResult other) { + if (other + == com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.getDefaultInstance()) + return this; + if (other.scanState_ != 0) { + setScanStateValue(other.getScanStateValue()); + } + if (other.hasScanTime()) { + mergeScanTime(other.getScanTime()); + } + if (!other.getErrorMessage().isEmpty()) { + errorMessage_ = other.errorMessage_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.findings_.isEmpty()) { + if (findings_.isEmpty()) { + findings_ = other.findings_; + bitField0_ |= 0x00000008; + } else { + ensureFindingsIsMutable(); + findings_.addAll(other.findings_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + scanState_ = input.readEnum(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 18: + { + input.readMessage( + internalGetScanTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + errorMessage_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureFindingsIsMutable(); + findings_.add(s); + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int scanState_ = 0; + + /** + * + * + *
+       * Output only. The state of the vulnerability check.
+       * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState scan_state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for scanState. + */ + @java.lang.Override + public int getScanStateValue() { + return scanState_; + } + + /** + * + * + *
+       * Output only. The state of the vulnerability check.
+       * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState scan_state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for scanState to set. + * @return This builder for chaining. + */ + public Builder setScanStateValue(int value) { + scanState_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The state of the vulnerability check.
+       * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState scan_state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The scanState. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState getScanState() { + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState result = + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState.forNumber( + scanState_); + return result == null + ? com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState.UNRECOGNIZED + : result; + } + + /** + * + * + *
+       * Output only. The state of the vulnerability check.
+       * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState scan_state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The scanState to set. + * @return This builder for chaining. + */ + public Builder setScanState( + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + scanState_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The state of the vulnerability check.
+       * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult.ScanState scan_state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearScanState() { + bitField0_ = (bitField0_ & ~0x00000001); + scanState_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp scanTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + scanTimeBuilder_; + + /** + * + * + *
+       * Output only. The time when the scan was completed.
+       * 
+ * + * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the scanTime field is set. + */ + public boolean hasScanTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+       * Output only. The time when the scan was completed.
+       * 
+ * + * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The scanTime. + */ + public com.google.protobuf.Timestamp getScanTime() { + if (scanTimeBuilder_ == null) { + return scanTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : scanTime_; + } else { + return scanTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+       * Output only. The time when the scan was completed.
+       * 
+ * + * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setScanTime(com.google.protobuf.Timestamp value) { + if (scanTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + scanTime_ = value; + } else { + scanTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The time when the scan was completed.
+       * 
+ * + * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setScanTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (scanTimeBuilder_ == null) { + scanTime_ = builderForValue.build(); + } else { + scanTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The time when the scan was completed.
+       * 
+ * + * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeScanTime(com.google.protobuf.Timestamp value) { + if (scanTimeBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && scanTime_ != null + && scanTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getScanTimeBuilder().mergeFrom(value); + } else { + scanTime_ = value; + } + } else { + scanTimeBuilder_.mergeFrom(value); + } + if (scanTime_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+       * Output only. The time when the scan was completed.
+       * 
+ * + * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearScanTime() { + bitField0_ = (bitField0_ & ~0x00000002); + scanTime_ = null; + if (scanTimeBuilder_ != null) { + scanTimeBuilder_.dispose(); + scanTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The time when the scan was completed.
+       * 
+ * + * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getScanTimeBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetScanTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+       * Output only. The time when the scan was completed.
+       * 
+ * + * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getScanTimeOrBuilder() { + if (scanTimeBuilder_ != null) { + return scanTimeBuilder_.getMessageOrBuilder(); + } else { + return scanTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : scanTime_; + } + } + + /** + * + * + *
+       * Output only. The time when the scan was completed.
+       * 
+ * + * + * .google.protobuf.Timestamp scan_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetScanTimeFieldBuilder() { + if (scanTimeBuilder_ == null) { + scanTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getScanTime(), getParentForChildren(), isClean()); + scanTime_ = null; + } + return scanTimeBuilder_; + } + + private java.lang.Object errorMessage_ = ""; + + /** + * + * + *
+       * Output only. The error message if the scan failed.
+       * 
+ * + * string error_message = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The errorMessage. + */ + public java.lang.String getErrorMessage() { + java.lang.Object ref = errorMessage_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + errorMessage_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * Output only. The error message if the scan failed.
+       * 
+ * + * string error_message = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for errorMessage. + */ + public com.google.protobuf.ByteString getErrorMessageBytes() { + java.lang.Object ref = errorMessage_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + errorMessage_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * Output only. The error message if the scan failed.
+       * 
+ * + * string error_message = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The errorMessage to set. + * @return This builder for chaining. + */ + public Builder setErrorMessage(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + errorMessage_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The error message if the scan failed.
+       * 
+ * + * string error_message = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearErrorMessage() { + errorMessage_ = getDefaultInstance().getErrorMessage(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The error message if the scan failed.
+       * 
+ * + * string error_message = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for errorMessage to set. + * @return This builder for chaining. + */ + public Builder setErrorMessageBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + errorMessage_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList findings_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureFindingsIsMutable() { + if (!findings_.isModifiable()) { + findings_ = new com.google.protobuf.LazyStringArrayList(findings_); + } + bitField0_ |= 0x00000008; + } + + /** + * + * + *
+       * Output only. The finding resource names for the skill revision.
+       * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the findings. + */ + public com.google.protobuf.ProtocolStringList getFindingsList() { + findings_.makeImmutable(); + return findings_; + } + + /** + * + * + *
+       * Output only. The finding resource names for the skill revision.
+       * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The count of findings. + */ + public int getFindingsCount() { + return findings_.size(); + } + + /** + * + * + *
+       * Output only. The finding resource names for the skill revision.
+       * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The findings at the given index. + */ + public java.lang.String getFindings(int index) { + return findings_.get(index); + } + + /** + * + * + *
+       * Output only. The finding resource names for the skill revision.
+       * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the findings at the given index. + */ + public com.google.protobuf.ByteString getFindingsBytes(int index) { + return findings_.getByteString(index); + } + + /** + * + * + *
+       * Output only. The finding resource names for the skill revision.
+       * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index to set the value at. + * @param value The findings to set. + * @return This builder for chaining. + */ + public Builder setFindings(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureFindingsIsMutable(); + findings_.set(index, value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The finding resource names for the skill revision.
+       * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The findings to add. + * @return This builder for chaining. + */ + public Builder addFindings(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureFindingsIsMutable(); + findings_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The finding resource names for the skill revision.
+       * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param values The findings to add. + * @return This builder for chaining. + */ + public Builder addAllFindings(java.lang.Iterable values) { + ensureFindingsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, findings_); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The finding resource names for the skill revision.
+       * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearFindings() { + findings_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + ; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The finding resource names for the skill revision.
+       * 
+ * + * + * repeated string findings = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes of the findings to add. + * @return This builder for chaining. + */ + public Builder addFindingsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureFindingsIsMutable(); + findings_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.SkillRevision.ScanResult) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.SkillRevision.ScanResult) + private static final com.google.cloud.agentregistry.v1.SkillRevision.ScanResult + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.SkillRevision.ScanResult(); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision.ScanResult getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ScanResult parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision.ScanResult getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + private int sourceCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object source_; + + public enum SourceCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + GCS_SOURCE(9), + ARCHIVE_UPLOAD_SOURCE(12), + SOURCE_NOT_SET(0); + private final int value; + + private SourceCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static SourceCase valueOf(int value) { + return forNumber(value); + } + + public static SourceCase forNumber(int value) { + switch (value) { + case 9: + return GCS_SOURCE; + case 12: + return ARCHIVE_UPLOAD_SOURCE; + case 0: + return SOURCE_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public SourceCase getSourceCase() { + return SourceCase.forNumber(sourceCase_); + } + + public static final int GCS_SOURCE_FIELD_NUMBER = 9; + + /** + * + * + *
+   * Optional. Immutable. Cloud Storage object generation URI.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the gcsSource field is set. + */ + @java.lang.Override + public boolean hasGcsSource() { + return sourceCase_ == 9; + } + + /** + * + * + *
+   * Optional. Immutable. Cloud Storage object generation URI.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The gcsSource. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.GcsSource getGcsSource() { + if (sourceCase_ == 9) { + return (com.google.cloud.agentregistry.v1.GcsSource) source_; + } + return com.google.cloud.agentregistry.v1.GcsSource.getDefaultInstance(); + } + + /** + * + * + *
+   * Optional. Immutable. Cloud Storage object generation URI.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.GcsSourceOrBuilder getGcsSourceOrBuilder() { + if (sourceCase_ == 9) { + return (com.google.cloud.agentregistry.v1.GcsSource) source_; + } + return com.google.cloud.agentregistry.v1.GcsSource.getDefaultInstance(); + } + + public static final int ARCHIVE_UPLOAD_SOURCE_FIELD_NUMBER = 12; + + /** + * + * + *
+   * Optional. Immutable. Direct write-only raw archive upload source.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the archiveUploadSource field is set. + */ + @java.lang.Override + public boolean hasArchiveUploadSource() { + return sourceCase_ == 12; + } + + /** + * + * + *
+   * Optional. Immutable. Direct write-only raw archive upload source.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The archiveUploadSource. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.ArchiveUploadSource getArchiveUploadSource() { + if (sourceCase_ == 12) { + return (com.google.cloud.agentregistry.v1.ArchiveUploadSource) source_; + } + return com.google.cloud.agentregistry.v1.ArchiveUploadSource.getDefaultInstance(); + } + + /** + * + * + *
+   * Optional. Immutable. Direct write-only raw archive upload source.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.ArchiveUploadSourceOrBuilder + getArchiveUploadSourceOrBuilder() { + if (sourceCase_ == 12) { + return (com.google.cloud.agentregistry.v1.ArchiveUploadSource) source_; + } + return com.google.cloud.agentregistry.v1.ArchiveUploadSource.getDefaultInstance(); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Identifier. Resource name of the SkillRevision.
+   * Format:
+   * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Identifier. Resource name of the SkillRevision.
+   * Format:
+   * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STATE_FIELD_NUMBER = 2; + private int state_ = 0; + + /** + * + * + *
+   * Output only. The system-managed lifecycle state of this revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
+   * Output only. The system-managed lifecycle state of this revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision.State getState() { + com.google.cloud.agentregistry.v1.SkillRevision.State result = + com.google.cloud.agentregistry.v1.SkillRevision.State.forNumber(state_); + return result == null + ? com.google.cloud.agentregistry.v1.SkillRevision.State.UNRECOGNIZED + : result; + } + + public static final int SHA256_HASH_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object sha256Hash_ = ""; + + /** + * + * + *
+   * Output only. Cryptographic SHA-256 integrity and deduplication digest of
+   * the payload zip.
+   * 
+ * + * string sha256_hash = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sha256Hash. + */ + @java.lang.Override + public java.lang.String getSha256Hash() { + java.lang.Object ref = sha256Hash_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sha256Hash_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. Cryptographic SHA-256 integrity and deduplication digest of
+   * the payload zip.
+   * 
+ * + * string sha256_hash = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for sha256Hash. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSha256HashBytes() { + java.lang.Object ref = sha256Hash_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sha256Hash_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FRONTMATTER_FIELD_NUMBER = 4; + private com.google.cloud.agentregistry.v1.Frontmatter frontmatter_; + + /** + * + * + *
+   * Output only. Extracted YAML frontmatter configuration snapshot.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the frontmatter field is set. + */ + @java.lang.Override + public boolean hasFrontmatter() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Output only. Extracted YAML frontmatter configuration snapshot.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The frontmatter. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Frontmatter getFrontmatter() { + return frontmatter_ == null + ? com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance() + : frontmatter_; + } + + /** + * + * + *
+   * Output only. Extracted YAML frontmatter configuration snapshot.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.FrontmatterOrBuilder getFrontmatterOrBuilder() { + return frontmatter_ == null + ? com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance() + : frontmatter_; + } + + public static final int CREATE_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
+   * Output only. Revision creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Output only. Revision creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
+   * Output only. Revision creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int SIZE_BYTES_FIELD_NUMBER = 11; + private long sizeBytes_ = 0L; + + /** + * + * + *
+   * Output only. Size of the compiled zip payload in bytes (assists client
+   * download progress).
+   * 
+ * + * int64 size_bytes = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sizeBytes. + */ + @java.lang.Override + public long getSizeBytes() { + return sizeBytes_; + } + + public static final int UID_FIELD_NUMBER = 14; + + @SuppressWarnings("serial") + private volatile java.lang.Object uid_ = ""; + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the skill revision.
+   * 
+ * + * + * string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + @java.lang.Override + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the skill revision.
+   * 
+ * + * + * string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SCAN_RESULT_FIELD_NUMBER = 15; + private com.google.cloud.agentregistry.v1.SkillRevision.ScanResult scanResult_; + + /** + * + * + *
+   * Output only. Scan result of the skill revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the scanResult field is set. + */ + @java.lang.Override + public boolean hasScanResult() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+   * Output only. Scan result of the skill revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The scanResult. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision.ScanResult getScanResult() { + return scanResult_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.getDefaultInstance() + : scanResult_; + } + + /** + * + * + *
+   * Output only. Scan result of the skill revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision.ScanResultOrBuilder + getScanResultOrBuilder() { + return scanResult_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.getDefaultInstance() + : scanResult_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (state_ + != com.google.cloud.agentregistry.v1.SkillRevision.State.STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(2, state_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sha256Hash_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, sha256Hash_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(4, getFrontmatter()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(6, getCreateTime()); + } + if (sourceCase_ == 9) { + output.writeMessage(9, (com.google.cloud.agentregistry.v1.GcsSource) source_); + } + if (sizeBytes_ != 0L) { + output.writeInt64(11, sizeBytes_); + } + if (sourceCase_ == 12) { + output.writeMessage(12, (com.google.cloud.agentregistry.v1.ArchiveUploadSource) source_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uid_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 14, uid_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(15, getScanResult()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (state_ + != com.google.cloud.agentregistry.v1.SkillRevision.State.STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, state_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sha256Hash_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, sha256Hash_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getFrontmatter()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getCreateTime()); + } + if (sourceCase_ == 9) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 9, (com.google.cloud.agentregistry.v1.GcsSource) source_); + } + if (sizeBytes_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(11, sizeBytes_); + } + if (sourceCase_ == 12) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 12, (com.google.cloud.agentregistry.v1.ArchiveUploadSource) source_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uid_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(14, uid_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(15, getScanResult()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.SkillRevision)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.SkillRevision other = + (com.google.cloud.agentregistry.v1.SkillRevision) obj; + + if (!getName().equals(other.getName())) return false; + if (state_ != other.state_) return false; + if (!getSha256Hash().equals(other.getSha256Hash())) return false; + if (hasFrontmatter() != other.hasFrontmatter()) return false; + if (hasFrontmatter()) { + if (!getFrontmatter().equals(other.getFrontmatter())) return false; + } + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (getSizeBytes() != other.getSizeBytes()) return false; + if (!getUid().equals(other.getUid())) return false; + if (hasScanResult() != other.hasScanResult()) return false; + if (hasScanResult()) { + if (!getScanResult().equals(other.getScanResult())) return false; + } + if (!getSourceCase().equals(other.getSourceCase())) return false; + switch (sourceCase_) { + case 9: + if (!getGcsSource().equals(other.getGcsSource())) return false; + break; + case 12: + if (!getArchiveUploadSource().equals(other.getArchiveUploadSource())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + hash = (37 * hash) + SHA256_HASH_FIELD_NUMBER; + hash = (53 * hash) + getSha256Hash().hashCode(); + if (hasFrontmatter()) { + hash = (37 * hash) + FRONTMATTER_FIELD_NUMBER; + hash = (53 * hash) + getFrontmatter().hashCode(); + } + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + hash = (37 * hash) + SIZE_BYTES_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getSizeBytes()); + hash = (37 * hash) + UID_FIELD_NUMBER; + hash = (53 * hash) + getUid().hashCode(); + if (hasScanResult()) { + hash = (37 * hash) + SCAN_RESULT_FIELD_NUMBER; + hash = (53 * hash) + getScanResult().hashCode(); + } + switch (sourceCase_) { + case 9: + hash = (37 * hash) + GCS_SOURCE_FIELD_NUMBER; + hash = (53 * hash) + getGcsSource().hashCode(); + break; + case 12: + hash = (37 * hash) + ARCHIVE_UPLOAD_SOURCE_FIELD_NUMBER; + hash = (53 * hash) + getArchiveUploadSource().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.SkillRevision prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Represents an immutable, versioned snapshot of a Skill package.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.SkillRevision} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.SkillRevision) + com.google.cloud.agentregistry.v1.SkillRevisionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_SkillRevision_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_SkillRevision_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.SkillRevision.class, + com.google.cloud.agentregistry.v1.SkillRevision.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.SkillRevision.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetFrontmatterFieldBuilder(); + internalGetCreateTimeFieldBuilder(); + internalGetScanResultFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (gcsSourceBuilder_ != null) { + gcsSourceBuilder_.clear(); + } + if (archiveUploadSourceBuilder_ != null) { + archiveUploadSourceBuilder_.clear(); + } + name_ = ""; + state_ = 0; + sha256Hash_ = ""; + frontmatter_ = null; + if (frontmatterBuilder_ != null) { + frontmatterBuilder_.dispose(); + frontmatterBuilder_ = null; + } + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + sizeBytes_ = 0L; + uid_ = ""; + scanResult_ = null; + if (scanResultBuilder_ != null) { + scanResultBuilder_.dispose(); + scanResultBuilder_ = null; + } + sourceCase_ = 0; + source_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.SkillProto + .internal_static_google_cloud_agentregistry_v1_SkillRevision_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision build() { + com.google.cloud.agentregistry.v1.SkillRevision result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision buildPartial() { + com.google.cloud.agentregistry.v1.SkillRevision result = + new com.google.cloud.agentregistry.v1.SkillRevision(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.SkillRevision result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.state_ = state_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.sha256Hash_ = sha256Hash_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000020) != 0)) { + result.frontmatter_ = + frontmatterBuilder_ == null ? frontmatter_ : frontmatterBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.sizeBytes_ = sizeBytes_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.uid_ = uid_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.scanResult_ = scanResultBuilder_ == null ? scanResult_ : scanResultBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + result.bitField0_ |= to_bitField0_; + } + + private void buildPartialOneofs(com.google.cloud.agentregistry.v1.SkillRevision result) { + result.sourceCase_ = sourceCase_; + result.source_ = this.source_; + if (sourceCase_ == 9 && gcsSourceBuilder_ != null) { + result.source_ = gcsSourceBuilder_.build(); + } + if (sourceCase_ == 12 && archiveUploadSourceBuilder_ != null) { + result.source_ = archiveUploadSourceBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.SkillRevision) { + return mergeFrom((com.google.cloud.agentregistry.v1.SkillRevision) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.SkillRevision other) { + if (other == com.google.cloud.agentregistry.v1.SkillRevision.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (!other.getSha256Hash().isEmpty()) { + sha256Hash_ = other.sha256Hash_; + bitField0_ |= 0x00000010; + onChanged(); + } + if (other.hasFrontmatter()) { + mergeFrontmatter(other.getFrontmatter()); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.getSizeBytes() != 0L) { + setSizeBytes(other.getSizeBytes()); + } + if (!other.getUid().isEmpty()) { + uid_ = other.uid_; + bitField0_ |= 0x00000100; + onChanged(); + } + if (other.hasScanResult()) { + mergeScanResult(other.getScanResult()); + } + switch (other.getSourceCase()) { + case GCS_SOURCE: + { + mergeGcsSource(other.getGcsSource()); + break; + } + case ARCHIVE_UPLOAD_SOURCE: + { + mergeArchiveUploadSource(other.getArchiveUploadSource()); + break; + } + case SOURCE_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 10 + case 16: + { + state_ = input.readEnum(); + bitField0_ |= 0x00000008; + break; + } // case 16 + case 26: + { + sha256Hash_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetFrontmatterFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 34 + case 50: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000040; + break; + } // case 50 + case 74: + { + input.readMessage( + internalGetGcsSourceFieldBuilder().getBuilder(), extensionRegistry); + sourceCase_ = 9; + break; + } // case 74 + case 88: + { + sizeBytes_ = input.readInt64(); + bitField0_ |= 0x00000080; + break; + } // case 88 + case 98: + { + input.readMessage( + internalGetArchiveUploadSourceFieldBuilder().getBuilder(), extensionRegistry); + sourceCase_ = 12; + break; + } // case 98 + case 114: + { + uid_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000100; + break; + } // case 114 + case 122: + { + input.readMessage( + internalGetScanResultFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000200; + break; + } // case 122 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int sourceCase_ = 0; + private java.lang.Object source_; + + public SourceCase getSourceCase() { + return SourceCase.forNumber(sourceCase_); + } + + public Builder clearSource() { + sourceCase_ = 0; + source_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.GcsSource, + com.google.cloud.agentregistry.v1.GcsSource.Builder, + com.google.cloud.agentregistry.v1.GcsSourceOrBuilder> + gcsSourceBuilder_; + + /** + * + * + *
+     * Optional. Immutable. Cloud Storage object generation URI.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the gcsSource field is set. + */ + @java.lang.Override + public boolean hasGcsSource() { + return sourceCase_ == 9; + } + + /** + * + * + *
+     * Optional. Immutable. Cloud Storage object generation URI.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The gcsSource. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.GcsSource getGcsSource() { + if (gcsSourceBuilder_ == null) { + if (sourceCase_ == 9) { + return (com.google.cloud.agentregistry.v1.GcsSource) source_; + } + return com.google.cloud.agentregistry.v1.GcsSource.getDefaultInstance(); + } else { + if (sourceCase_ == 9) { + return gcsSourceBuilder_.getMessage(); + } + return com.google.cloud.agentregistry.v1.GcsSource.getDefaultInstance(); + } + } + + /** + * + * + *
+     * Optional. Immutable. Cloud Storage object generation URI.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setGcsSource(com.google.cloud.agentregistry.v1.GcsSource value) { + if (gcsSourceBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + source_ = value; + onChanged(); + } else { + gcsSourceBuilder_.setMessage(value); + } + sourceCase_ = 9; + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Cloud Storage object generation URI.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setGcsSource( + com.google.cloud.agentregistry.v1.GcsSource.Builder builderForValue) { + if (gcsSourceBuilder_ == null) { + source_ = builderForValue.build(); + onChanged(); + } else { + gcsSourceBuilder_.setMessage(builderForValue.build()); + } + sourceCase_ = 9; + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Cloud Storage object generation URI.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeGcsSource(com.google.cloud.agentregistry.v1.GcsSource value) { + if (gcsSourceBuilder_ == null) { + if (sourceCase_ == 9 + && source_ != com.google.cloud.agentregistry.v1.GcsSource.getDefaultInstance()) { + source_ = + com.google.cloud.agentregistry.v1.GcsSource.newBuilder( + (com.google.cloud.agentregistry.v1.GcsSource) source_) + .mergeFrom(value) + .buildPartial(); + } else { + source_ = value; + } + onChanged(); + } else { + if (sourceCase_ == 9) { + gcsSourceBuilder_.mergeFrom(value); + } else { + gcsSourceBuilder_.setMessage(value); + } + } + sourceCase_ = 9; + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Cloud Storage object generation URI.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearGcsSource() { + if (gcsSourceBuilder_ == null) { + if (sourceCase_ == 9) { + sourceCase_ = 0; + source_ = null; + onChanged(); + } + } else { + if (sourceCase_ == 9) { + sourceCase_ = 0; + source_ = null; + } + gcsSourceBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Cloud Storage object generation URI.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.agentregistry.v1.GcsSource.Builder getGcsSourceBuilder() { + return internalGetGcsSourceFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Optional. Immutable. Cloud Storage object generation URI.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.GcsSourceOrBuilder getGcsSourceOrBuilder() { + if ((sourceCase_ == 9) && (gcsSourceBuilder_ != null)) { + return gcsSourceBuilder_.getMessageOrBuilder(); + } else { + if (sourceCase_ == 9) { + return (com.google.cloud.agentregistry.v1.GcsSource) source_; + } + return com.google.cloud.agentregistry.v1.GcsSource.getDefaultInstance(); + } + } + + /** + * + * + *
+     * Optional. Immutable. Cloud Storage object generation URI.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.GcsSource, + com.google.cloud.agentregistry.v1.GcsSource.Builder, + com.google.cloud.agentregistry.v1.GcsSourceOrBuilder> + internalGetGcsSourceFieldBuilder() { + if (gcsSourceBuilder_ == null) { + if (!(sourceCase_ == 9)) { + source_ = com.google.cloud.agentregistry.v1.GcsSource.getDefaultInstance(); + } + gcsSourceBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.GcsSource, + com.google.cloud.agentregistry.v1.GcsSource.Builder, + com.google.cloud.agentregistry.v1.GcsSourceOrBuilder>( + (com.google.cloud.agentregistry.v1.GcsSource) source_, + getParentForChildren(), + isClean()); + source_ = null; + } + sourceCase_ = 9; + onChanged(); + return gcsSourceBuilder_; + } + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.ArchiveUploadSource, + com.google.cloud.agentregistry.v1.ArchiveUploadSource.Builder, + com.google.cloud.agentregistry.v1.ArchiveUploadSourceOrBuilder> + archiveUploadSourceBuilder_; + + /** + * + * + *
+     * Optional. Immutable. Direct write-only raw archive upload source.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the archiveUploadSource field is set. + */ + @java.lang.Override + public boolean hasArchiveUploadSource() { + return sourceCase_ == 12; + } + + /** + * + * + *
+     * Optional. Immutable. Direct write-only raw archive upload source.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The archiveUploadSource. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.ArchiveUploadSource getArchiveUploadSource() { + if (archiveUploadSourceBuilder_ == null) { + if (sourceCase_ == 12) { + return (com.google.cloud.agentregistry.v1.ArchiveUploadSource) source_; + } + return com.google.cloud.agentregistry.v1.ArchiveUploadSource.getDefaultInstance(); + } else { + if (sourceCase_ == 12) { + return archiveUploadSourceBuilder_.getMessage(); + } + return com.google.cloud.agentregistry.v1.ArchiveUploadSource.getDefaultInstance(); + } + } + + /** + * + * + *
+     * Optional. Immutable. Direct write-only raw archive upload source.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setArchiveUploadSource( + com.google.cloud.agentregistry.v1.ArchiveUploadSource value) { + if (archiveUploadSourceBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + source_ = value; + onChanged(); + } else { + archiveUploadSourceBuilder_.setMessage(value); + } + sourceCase_ = 12; + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Direct write-only raw archive upload source.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setArchiveUploadSource( + com.google.cloud.agentregistry.v1.ArchiveUploadSource.Builder builderForValue) { + if (archiveUploadSourceBuilder_ == null) { + source_ = builderForValue.build(); + onChanged(); + } else { + archiveUploadSourceBuilder_.setMessage(builderForValue.build()); + } + sourceCase_ = 12; + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Direct write-only raw archive upload source.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeArchiveUploadSource( + com.google.cloud.agentregistry.v1.ArchiveUploadSource value) { + if (archiveUploadSourceBuilder_ == null) { + if (sourceCase_ == 12 + && source_ + != com.google.cloud.agentregistry.v1.ArchiveUploadSource.getDefaultInstance()) { + source_ = + com.google.cloud.agentregistry.v1.ArchiveUploadSource.newBuilder( + (com.google.cloud.agentregistry.v1.ArchiveUploadSource) source_) + .mergeFrom(value) + .buildPartial(); + } else { + source_ = value; + } + onChanged(); + } else { + if (sourceCase_ == 12) { + archiveUploadSourceBuilder_.mergeFrom(value); + } else { + archiveUploadSourceBuilder_.setMessage(value); + } + } + sourceCase_ = 12; + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Direct write-only raw archive upload source.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearArchiveUploadSource() { + if (archiveUploadSourceBuilder_ == null) { + if (sourceCase_ == 12) { + sourceCase_ = 0; + source_ = null; + onChanged(); + } + } else { + if (sourceCase_ == 12) { + sourceCase_ = 0; + source_ = null; + } + archiveUploadSourceBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Direct write-only raw archive upload source.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.agentregistry.v1.ArchiveUploadSource.Builder + getArchiveUploadSourceBuilder() { + return internalGetArchiveUploadSourceFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Optional. Immutable. Direct write-only raw archive upload source.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.ArchiveUploadSourceOrBuilder + getArchiveUploadSourceOrBuilder() { + if ((sourceCase_ == 12) && (archiveUploadSourceBuilder_ != null)) { + return archiveUploadSourceBuilder_.getMessageOrBuilder(); + } else { + if (sourceCase_ == 12) { + return (com.google.cloud.agentregistry.v1.ArchiveUploadSource) source_; + } + return com.google.cloud.agentregistry.v1.ArchiveUploadSource.getDefaultInstance(); + } + } + + /** + * + * + *
+     * Optional. Immutable. Direct write-only raw archive upload source.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.ArchiveUploadSource, + com.google.cloud.agentregistry.v1.ArchiveUploadSource.Builder, + com.google.cloud.agentregistry.v1.ArchiveUploadSourceOrBuilder> + internalGetArchiveUploadSourceFieldBuilder() { + if (archiveUploadSourceBuilder_ == null) { + if (!(sourceCase_ == 12)) { + source_ = com.google.cloud.agentregistry.v1.ArchiveUploadSource.getDefaultInstance(); + } + archiveUploadSourceBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.ArchiveUploadSource, + com.google.cloud.agentregistry.v1.ArchiveUploadSource.Builder, + com.google.cloud.agentregistry.v1.ArchiveUploadSourceOrBuilder>( + (com.google.cloud.agentregistry.v1.ArchiveUploadSource) source_, + getParentForChildren(), + isClean()); + source_ = null; + } + sourceCase_ = 12; + onChanged(); + return archiveUploadSourceBuilder_; + } + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Identifier. Resource name of the SkillRevision.
+     * Format:
+     * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the SkillRevision.
+     * Format:
+     * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Identifier. Resource name of the SkillRevision.
+     * Format:
+     * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the SkillRevision.
+     * Format:
+     * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. Resource name of the SkillRevision.
+     * Format:
+     * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private int state_ = 0; + + /** + * + * + *
+     * Output only. The system-managed lifecycle state of this revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
+     * Output only. The system-managed lifecycle state of this revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The system-managed lifecycle state of this revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision.State getState() { + com.google.cloud.agentregistry.v1.SkillRevision.State result = + com.google.cloud.agentregistry.v1.SkillRevision.State.forNumber(state_); + return result == null + ? com.google.cloud.agentregistry.v1.SkillRevision.State.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Output only. The system-managed lifecycle state of this revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.agentregistry.v1.SkillRevision.State value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000008; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The system-managed lifecycle state of this revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000008); + state_ = 0; + onChanged(); + return this; + } + + private java.lang.Object sha256Hash_ = ""; + + /** + * + * + *
+     * Output only. Cryptographic SHA-256 integrity and deduplication digest of
+     * the payload zip.
+     * 
+ * + * string sha256_hash = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sha256Hash. + */ + public java.lang.String getSha256Hash() { + java.lang.Object ref = sha256Hash_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sha256Hash_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. Cryptographic SHA-256 integrity and deduplication digest of
+     * the payload zip.
+     * 
+ * + * string sha256_hash = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for sha256Hash. + */ + public com.google.protobuf.ByteString getSha256HashBytes() { + java.lang.Object ref = sha256Hash_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sha256Hash_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. Cryptographic SHA-256 integrity and deduplication digest of
+     * the payload zip.
+     * 
+ * + * string sha256_hash = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The sha256Hash to set. + * @return This builder for chaining. + */ + public Builder setSha256Hash(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sha256Hash_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Cryptographic SHA-256 integrity and deduplication digest of
+     * the payload zip.
+     * 
+ * + * string sha256_hash = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearSha256Hash() { + sha256Hash_ = getDefaultInstance().getSha256Hash(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Cryptographic SHA-256 integrity and deduplication digest of
+     * the payload zip.
+     * 
+ * + * string sha256_hash = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for sha256Hash to set. + * @return This builder for chaining. + */ + public Builder setSha256HashBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sha256Hash_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private com.google.cloud.agentregistry.v1.Frontmatter frontmatter_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Frontmatter, + com.google.cloud.agentregistry.v1.Frontmatter.Builder, + com.google.cloud.agentregistry.v1.FrontmatterOrBuilder> + frontmatterBuilder_; + + /** + * + * + *
+     * Output only. Extracted YAML frontmatter configuration snapshot.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the frontmatter field is set. + */ + public boolean hasFrontmatter() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
+     * Output only. Extracted YAML frontmatter configuration snapshot.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The frontmatter. + */ + public com.google.cloud.agentregistry.v1.Frontmatter getFrontmatter() { + if (frontmatterBuilder_ == null) { + return frontmatter_ == null + ? com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance() + : frontmatter_; + } else { + return frontmatterBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Extracted YAML frontmatter configuration snapshot.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setFrontmatter(com.google.cloud.agentregistry.v1.Frontmatter value) { + if (frontmatterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + frontmatter_ = value; + } else { + frontmatterBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Extracted YAML frontmatter configuration snapshot.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setFrontmatter( + com.google.cloud.agentregistry.v1.Frontmatter.Builder builderForValue) { + if (frontmatterBuilder_ == null) { + frontmatter_ = builderForValue.build(); + } else { + frontmatterBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Extracted YAML frontmatter configuration snapshot.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeFrontmatter(com.google.cloud.agentregistry.v1.Frontmatter value) { + if (frontmatterBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && frontmatter_ != null + && frontmatter_ != com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance()) { + getFrontmatterBuilder().mergeFrom(value); + } else { + frontmatter_ = value; + } + } else { + frontmatterBuilder_.mergeFrom(value); + } + if (frontmatter_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Extracted YAML frontmatter configuration snapshot.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearFrontmatter() { + bitField0_ = (bitField0_ & ~0x00000020); + frontmatter_ = null; + if (frontmatterBuilder_ != null) { + frontmatterBuilder_.dispose(); + frontmatterBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Extracted YAML frontmatter configuration snapshot.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.agentregistry.v1.Frontmatter.Builder getFrontmatterBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetFrontmatterFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Extracted YAML frontmatter configuration snapshot.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.agentregistry.v1.FrontmatterOrBuilder getFrontmatterOrBuilder() { + if (frontmatterBuilder_ != null) { + return frontmatterBuilder_.getMessageOrBuilder(); + } else { + return frontmatter_ == null + ? com.google.cloud.agentregistry.v1.Frontmatter.getDefaultInstance() + : frontmatter_; + } + } + + /** + * + * + *
+     * Output only. Extracted YAML frontmatter configuration snapshot.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Frontmatter, + com.google.cloud.agentregistry.v1.Frontmatter.Builder, + com.google.cloud.agentregistry.v1.FrontmatterOrBuilder> + internalGetFrontmatterFieldBuilder() { + if (frontmatterBuilder_ == null) { + frontmatterBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Frontmatter, + com.google.cloud.agentregistry.v1.Frontmatter.Builder, + com.google.cloud.agentregistry.v1.FrontmatterOrBuilder>( + getFrontmatter(), getParentForChildren(), isClean()); + frontmatter_ = null; + } + return frontmatterBuilder_; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
+     * Output only. Revision creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
+     * Output only. Revision creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Revision creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Revision creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Revision creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000040) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000040; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Revision creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000040); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Revision creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000040; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Revision creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
+     * Output only. Revision creation timestamp.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private long sizeBytes_; + + /** + * + * + *
+     * Output only. Size of the compiled zip payload in bytes (assists client
+     * download progress).
+     * 
+ * + * int64 size_bytes = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sizeBytes. + */ + @java.lang.Override + public long getSizeBytes() { + return sizeBytes_; + } + + /** + * + * + *
+     * Output only. Size of the compiled zip payload in bytes (assists client
+     * download progress).
+     * 
+ * + * int64 size_bytes = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The sizeBytes to set. + * @return This builder for chaining. + */ + public Builder setSizeBytes(long value) { + + sizeBytes_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Size of the compiled zip payload in bytes (assists client
+     * download progress).
+     * 
+ * + * int64 size_bytes = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearSizeBytes() { + bitField0_ = (bitField0_ & ~0x00000080); + sizeBytes_ = 0L; + onChanged(); + return this; + } + + private java.lang.Object uid_ = ""; + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the skill revision.
+     * 
+ * + * + * string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the skill revision.
+     * 
+ * + * + * string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the skill revision.
+     * 
+ * + * + * string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @param value The uid to set. + * @return This builder for chaining. + */ + public Builder setUid(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + uid_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the skill revision.
+     * 
+ * + * + * string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearUid() { + uid_ = getDefaultInstance().getUid(); + bitField0_ = (bitField0_ & ~0x00000100); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Universally unique identifier (UUID4) for the skill revision.
+     * 
+ * + * + * string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for uid to set. + * @return This builder for chaining. + */ + public Builder setUidBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + uid_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + private com.google.cloud.agentregistry.v1.SkillRevision.ScanResult scanResult_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult, + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.Builder, + com.google.cloud.agentregistry.v1.SkillRevision.ScanResultOrBuilder> + scanResultBuilder_; + + /** + * + * + *
+     * Output only. Scan result of the skill revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the scanResult field is set. + */ + public boolean hasScanResult() { + return ((bitField0_ & 0x00000200) != 0); + } + + /** + * + * + *
+     * Output only. Scan result of the skill revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The scanResult. + */ + public com.google.cloud.agentregistry.v1.SkillRevision.ScanResult getScanResult() { + if (scanResultBuilder_ == null) { + return scanResult_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.getDefaultInstance() + : scanResult_; + } else { + return scanResultBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Scan result of the skill revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setScanResult(com.google.cloud.agentregistry.v1.SkillRevision.ScanResult value) { + if (scanResultBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + scanResult_ = value; + } else { + scanResultBuilder_.setMessage(value); + } + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Scan result of the skill revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setScanResult( + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.Builder builderForValue) { + if (scanResultBuilder_ == null) { + scanResult_ = builderForValue.build(); + } else { + scanResultBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Scan result of the skill revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeScanResult( + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult value) { + if (scanResultBuilder_ == null) { + if (((bitField0_ & 0x00000200) != 0) + && scanResult_ != null + && scanResult_ + != com.google.cloud.agentregistry.v1.SkillRevision.ScanResult + .getDefaultInstance()) { + getScanResultBuilder().mergeFrom(value); + } else { + scanResult_ = value; + } + } else { + scanResultBuilder_.mergeFrom(value); + } + if (scanResult_ != null) { + bitField0_ |= 0x00000200; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Scan result of the skill revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearScanResult() { + bitField0_ = (bitField0_ & ~0x00000200); + scanResult_ = null; + if (scanResultBuilder_ != null) { + scanResultBuilder_.dispose(); + scanResultBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Scan result of the skill revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.Builder + getScanResultBuilder() { + bitField0_ |= 0x00000200; + onChanged(); + return internalGetScanResultFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Scan result of the skill revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.agentregistry.v1.SkillRevision.ScanResultOrBuilder + getScanResultOrBuilder() { + if (scanResultBuilder_ != null) { + return scanResultBuilder_.getMessageOrBuilder(); + } else { + return scanResult_ == null + ? com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.getDefaultInstance() + : scanResult_; + } + } + + /** + * + * + *
+     * Output only. Scan result of the skill revision.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult, + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.Builder, + com.google.cloud.agentregistry.v1.SkillRevision.ScanResultOrBuilder> + internalGetScanResultFieldBuilder() { + if (scanResultBuilder_ == null) { + scanResultBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult, + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult.Builder, + com.google.cloud.agentregistry.v1.SkillRevision.ScanResultOrBuilder>( + getScanResult(), getParentForChildren(), isClean()); + scanResult_ = null; + } + return scanResultBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.SkillRevision) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.SkillRevision) + private static final com.google.cloud.agentregistry.v1.SkillRevision DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.SkillRevision(); + } + + public static com.google.cloud.agentregistry.v1.SkillRevision getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SkillRevision parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillRevision getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillRevisionName.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillRevisionName.java new file mode 100644 index 000000000000..c5bde155c3c5 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillRevisionName.java @@ -0,0 +1,261 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class SkillRevisionName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_SKILL_REVISION = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String skill; + private final String revision; + + @Deprecated + protected SkillRevisionName() { + project = null; + location = null; + skill = null; + revision = null; + } + + private SkillRevisionName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + skill = Preconditions.checkNotNull(builder.getSkill()); + revision = Preconditions.checkNotNull(builder.getRevision()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getSkill() { + return skill; + } + + public String getRevision() { + return revision; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static SkillRevisionName of( + String project, String location, String skill, String revision) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setSkill(skill) + .setRevision(revision) + .build(); + } + + public static String format(String project, String location, String skill, String revision) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setSkill(skill) + .setRevision(revision) + .build() + .toString(); + } + + public static @Nullable SkillRevisionName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_SKILL_REVISION.validatedMatch( + formattedString, "SkillRevisionName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("skill"), + matchMap.get("revision")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable SkillRevisionName> values) { + List list = new ArrayList<>(values.size()); + for (SkillRevisionName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_SKILL_REVISION.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (skill != null) { + fieldMapBuilder.put("skill", skill); + } + if (revision != null) { + fieldMapBuilder.put("revision", revision); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_SKILL_REVISION.instantiate( + "project", project, "location", location, "skill", skill, "revision", revision); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + SkillRevisionName that = ((SkillRevisionName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.skill, that.skill) + && Objects.equals(this.revision, that.revision); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(skill); + h *= 1000003; + h ^= Objects.hashCode(revision); + return h; + } + + /** Builder for projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}. */ + public static class Builder { + private String project; + private String location; + private String skill; + private String revision; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getSkill() { + return skill; + } + + public String getRevision() { + return revision; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setSkill(String skill) { + this.skill = skill; + return this; + } + + public Builder setRevision(String revision) { + this.revision = revision; + return this; + } + + private Builder(SkillRevisionName skillRevisionName) { + this.project = skillRevisionName.project; + this.location = skillRevisionName.location; + this.skill = skillRevisionName.skill; + this.revision = skillRevisionName.revision; + } + + public SkillRevisionName build() { + return new SkillRevisionName(this); + } + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillRevisionOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillRevisionOrBuilder.java new file mode 100644 index 000000000000..c6bc5a6a31be --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/SkillRevisionOrBuilder.java @@ -0,0 +1,374 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/skill.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface SkillRevisionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.SkillRevision) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Optional. Immutable. Cloud Storage object generation URI.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the gcsSource field is set. + */ + boolean hasGcsSource(); + + /** + * + * + *
+   * Optional. Immutable. Cloud Storage object generation URI.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The gcsSource. + */ + com.google.cloud.agentregistry.v1.GcsSource getGcsSource(); + + /** + * + * + *
+   * Optional. Immutable. Cloud Storage object generation URI.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.GcsSource gcs_source = 9 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.agentregistry.v1.GcsSourceOrBuilder getGcsSourceOrBuilder(); + + /** + * + * + *
+   * Optional. Immutable. Direct write-only raw archive upload source.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the archiveUploadSource field is set. + */ + boolean hasArchiveUploadSource(); + + /** + * + * + *
+   * Optional. Immutable. Direct write-only raw archive upload source.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The archiveUploadSource. + */ + com.google.cloud.agentregistry.v1.ArchiveUploadSource getArchiveUploadSource(); + + /** + * + * + *
+   * Optional. Immutable. Direct write-only raw archive upload source.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.ArchiveUploadSource archive_upload_source = 12 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.agentregistry.v1.ArchiveUploadSourceOrBuilder getArchiveUploadSourceOrBuilder(); + + /** + * + * + *
+   * Identifier. Resource name of the SkillRevision.
+   * Format:
+   * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Identifier. Resource name of the SkillRevision.
+   * Format:
+   * `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Output only. The system-managed lifecycle state of this revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
+   * Output only. The system-managed lifecycle state of this revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.agentregistry.v1.SkillRevision.State getState(); + + /** + * + * + *
+   * Output only. Cryptographic SHA-256 integrity and deduplication digest of
+   * the payload zip.
+   * 
+ * + * string sha256_hash = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sha256Hash. + */ + java.lang.String getSha256Hash(); + + /** + * + * + *
+   * Output only. Cryptographic SHA-256 integrity and deduplication digest of
+   * the payload zip.
+   * 
+ * + * string sha256_hash = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for sha256Hash. + */ + com.google.protobuf.ByteString getSha256HashBytes(); + + /** + * + * + *
+   * Output only. Extracted YAML frontmatter configuration snapshot.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the frontmatter field is set. + */ + boolean hasFrontmatter(); + + /** + * + * + *
+   * Output only. Extracted YAML frontmatter configuration snapshot.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The frontmatter. + */ + com.google.cloud.agentregistry.v1.Frontmatter getFrontmatter(); + + /** + * + * + *
+   * Output only. Extracted YAML frontmatter configuration snapshot.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.Frontmatter frontmatter = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.agentregistry.v1.FrontmatterOrBuilder getFrontmatterOrBuilder(); + + /** + * + * + *
+   * Output only. Revision creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
+   * Output only. Revision creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
+   * Output only. Revision creation timestamp.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. Size of the compiled zip payload in bytes (assists client
+   * download progress).
+   * 
+ * + * int64 size_bytes = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sizeBytes. + */ + long getSizeBytes(); + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the skill revision.
+   * 
+ * + * + * string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + java.lang.String getUid(); + + /** + * + * + *
+   * Output only. Universally unique identifier (UUID4) for the skill revision.
+   * 
+ * + * + * string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + com.google.protobuf.ByteString getUidBytes(); + + /** + * + * + *
+   * Output only. Scan result of the skill revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the scanResult field is set. + */ + boolean hasScanResult(); + + /** + * + * + *
+   * Output only. Scan result of the skill revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The scanResult. + */ + com.google.cloud.agentregistry.v1.SkillRevision.ScanResult getScanResult(); + + /** + * + * + *
+   * Output only. Scan result of the skill revision.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillRevision.ScanResult scan_result = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.agentregistry.v1.SkillRevision.ScanResultOrBuilder getScanResultOrBuilder(); + + com.google.cloud.agentregistry.v1.SkillRevision.SourceCase getSourceCase(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillEncryptionSpecRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillEncryptionSpecRequest.java new file mode 100644 index 000000000000..b61e388d53f9 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillEncryptionSpecRequest.java @@ -0,0 +1,1094 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message for updating a SkillEncryptionSpec.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest} + */ +@com.google.protobuf.Generated +public final class UpdateSkillEncryptionSpecRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest) + UpdateSkillEncryptionSpecRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "UpdateSkillEncryptionSpecRequest"); + } + + // Use UpdateSkillEncryptionSpecRequest.newBuilder() to construct. + private UpdateSkillEncryptionSpecRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private UpdateSkillEncryptionSpecRequest() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_UpdateSkillEncryptionSpecRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_UpdateSkillEncryptionSpecRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest.class, + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest.Builder.class); + } + + private int bitField0_; + public static final int SKILL_ENCRYPTION_SPEC_FIELD_NUMBER = 1; + private com.google.cloud.agentregistry.v1.SkillEncryptionSpec skillEncryptionSpec_; + + /** + * + * + *
+   * Required. The SkillEncryptionSpec to update.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skillEncryptionSpec field is set. + */ + @java.lang.Override + public boolean hasSkillEncryptionSpec() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Required. The SkillEncryptionSpec to update.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skillEncryptionSpec. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillEncryptionSpec getSkillEncryptionSpec() { + return skillEncryptionSpec_ == null + ? com.google.cloud.agentregistry.v1.SkillEncryptionSpec.getDefaultInstance() + : skillEncryptionSpec_; + } + + /** + * + * + *
+   * Required. The SkillEncryptionSpec to update.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillEncryptionSpecOrBuilder + getSkillEncryptionSpecOrBuilder() { + return skillEncryptionSpec_ == null + ? com.google.cloud.agentregistry.v1.SkillEncryptionSpec.getDefaultInstance() + : skillEncryptionSpec_; + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + + /** + * + * + *
+   * Optional. Field mask is used to specify the fields to be overwritten in the
+   * SkillEncryptionSpec resource by the update.
+   * The fields specified in the update_mask are relative to the resource, not
+   * the full request. A field will be overwritten if it is in the mask. If the
+   * user does not provide a mask then all fields present in the request will be
+   * overwritten.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Optional. Field mask is used to specify the fields to be overwritten in the
+   * SkillEncryptionSpec resource by the update.
+   * The fields specified in the update_mask are relative to the resource, not
+   * the full request. A field will be overwritten if it is in the mask. If the
+   * user does not provide a mask then all fields present in the request will be
+   * overwritten.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + /** + * + * + *
+   * Optional. Field mask is used to specify the fields to be overwritten in the
+   * SkillEncryptionSpec resource by the update.
+   * The fields specified in the update_mask are relative to the resource, not
+   * the full request. A field will be overwritten if it is in the mask. If the
+   * user does not provide a mask then all fields present in the request will be
+   * overwritten.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getSkillEncryptionSpec()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getUpdateMask()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getSkillEncryptionSpec()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest other = + (com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest) obj; + + if (hasSkillEncryptionSpec() != other.hasSkillEncryptionSpec()) return false; + if (hasSkillEncryptionSpec()) { + if (!getSkillEncryptionSpec().equals(other.getSkillEncryptionSpec())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasSkillEncryptionSpec()) { + hash = (37 * hash) + SKILL_ENCRYPTION_SPEC_FIELD_NUMBER; + hash = (53 * hash) + getSkillEncryptionSpec().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message for updating a SkillEncryptionSpec.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest) + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_UpdateSkillEncryptionSpecRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_UpdateSkillEncryptionSpecRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest.class, + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest.Builder.class); + } + + // Construct using + // com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetSkillEncryptionSpecFieldBuilder(); + internalGetUpdateMaskFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + skillEncryptionSpec_ = null; + if (skillEncryptionSpecBuilder_ != null) { + skillEncryptionSpecBuilder_.dispose(); + skillEncryptionSpecBuilder_ = null; + } + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_UpdateSkillEncryptionSpecRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest + getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest build() { + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest buildPartial() { + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest result = + new com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.skillEncryptionSpec_ = + skillEncryptionSpecBuilder_ == null + ? skillEncryptionSpec_ + : skillEncryptionSpecBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.updateMask_ = updateMaskBuilder_ == null ? updateMask_ : updateMaskBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest) { + return mergeFrom( + (com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest other) { + if (other + == com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest + .getDefaultInstance()) return this; + if (other.hasSkillEncryptionSpec()) { + mergeSkillEncryptionSpec(other.getSkillEncryptionSpec()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetSkillEncryptionSpecFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.agentregistry.v1.SkillEncryptionSpec skillEncryptionSpec_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillEncryptionSpec, + com.google.cloud.agentregistry.v1.SkillEncryptionSpec.Builder, + com.google.cloud.agentregistry.v1.SkillEncryptionSpecOrBuilder> + skillEncryptionSpecBuilder_; + + /** + * + * + *
+     * Required. The SkillEncryptionSpec to update.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skillEncryptionSpec field is set. + */ + public boolean hasSkillEncryptionSpec() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+     * Required. The SkillEncryptionSpec to update.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skillEncryptionSpec. + */ + public com.google.cloud.agentregistry.v1.SkillEncryptionSpec getSkillEncryptionSpec() { + if (skillEncryptionSpecBuilder_ == null) { + return skillEncryptionSpec_ == null + ? com.google.cloud.agentregistry.v1.SkillEncryptionSpec.getDefaultInstance() + : skillEncryptionSpec_; + } else { + return skillEncryptionSpecBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Required. The SkillEncryptionSpec to update.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.SkillEncryptionSpec value) { + if (skillEncryptionSpecBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + skillEncryptionSpec_ = value; + } else { + skillEncryptionSpecBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The SkillEncryptionSpec to update.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.SkillEncryptionSpec.Builder builderForValue) { + if (skillEncryptionSpecBuilder_ == null) { + skillEncryptionSpec_ = builderForValue.build(); + } else { + skillEncryptionSpecBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The SkillEncryptionSpec to update.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeSkillEncryptionSpec( + com.google.cloud.agentregistry.v1.SkillEncryptionSpec value) { + if (skillEncryptionSpecBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && skillEncryptionSpec_ != null + && skillEncryptionSpec_ + != com.google.cloud.agentregistry.v1.SkillEncryptionSpec.getDefaultInstance()) { + getSkillEncryptionSpecBuilder().mergeFrom(value); + } else { + skillEncryptionSpec_ = value; + } + } else { + skillEncryptionSpecBuilder_.mergeFrom(value); + } + if (skillEncryptionSpec_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Required. The SkillEncryptionSpec to update.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearSkillEncryptionSpec() { + bitField0_ = (bitField0_ & ~0x00000001); + skillEncryptionSpec_ = null; + if (skillEncryptionSpecBuilder_ != null) { + skillEncryptionSpecBuilder_.dispose(); + skillEncryptionSpecBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The SkillEncryptionSpec to update.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.agentregistry.v1.SkillEncryptionSpec.Builder + getSkillEncryptionSpecBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetSkillEncryptionSpecFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Required. The SkillEncryptionSpec to update.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.agentregistry.v1.SkillEncryptionSpecOrBuilder + getSkillEncryptionSpecOrBuilder() { + if (skillEncryptionSpecBuilder_ != null) { + return skillEncryptionSpecBuilder_.getMessageOrBuilder(); + } else { + return skillEncryptionSpec_ == null + ? com.google.cloud.agentregistry.v1.SkillEncryptionSpec.getDefaultInstance() + : skillEncryptionSpec_; + } + } + + /** + * + * + *
+     * Required. The SkillEncryptionSpec to update.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillEncryptionSpec, + com.google.cloud.agentregistry.v1.SkillEncryptionSpec.Builder, + com.google.cloud.agentregistry.v1.SkillEncryptionSpecOrBuilder> + internalGetSkillEncryptionSpecFieldBuilder() { + if (skillEncryptionSpecBuilder_ == null) { + skillEncryptionSpecBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.SkillEncryptionSpec, + com.google.cloud.agentregistry.v1.SkillEncryptionSpec.Builder, + com.google.cloud.agentregistry.v1.SkillEncryptionSpecOrBuilder>( + getSkillEncryptionSpec(), getParentForChildren(), isClean()); + skillEncryptionSpec_ = null; + } + return skillEncryptionSpecBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + + /** + * + * + *
+     * Optional. Field mask is used to specify the fields to be overwritten in the
+     * SkillEncryptionSpec resource by the update.
+     * The fields specified in the update_mask are relative to the resource, not
+     * the full request. A field will be overwritten if it is in the mask. If the
+     * user does not provide a mask then all fields present in the request will be
+     * overwritten.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * Optional. Field mask is used to specify the fields to be overwritten in the
+     * SkillEncryptionSpec resource by the update.
+     * The fields specified in the update_mask are relative to the resource, not
+     * the full request. A field will be overwritten if it is in the mask. If the
+     * user does not provide a mask then all fields present in the request will be
+     * overwritten.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Optional. Field mask is used to specify the fields to be overwritten in the
+     * SkillEncryptionSpec resource by the update.
+     * The fields specified in the update_mask are relative to the resource, not
+     * the full request. A field will be overwritten if it is in the mask. If the
+     * user does not provide a mask then all fields present in the request will be
+     * overwritten.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + } else { + updateMaskBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Field mask is used to specify the fields to be overwritten in the
+     * SkillEncryptionSpec resource by the update.
+     * The fields specified in the update_mask are relative to the resource, not
+     * the full request. A field will be overwritten if it is in the mask. If the
+     * user does not provide a mask then all fields present in the request will be
+     * overwritten.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Field mask is used to specify the fields to be overwritten in the
+     * SkillEncryptionSpec resource by the update.
+     * The fields specified in the update_mask are relative to the resource, not
+     * the full request. A field will be overwritten if it is in the mask. If the
+     * user does not provide a mask then all fields present in the request will be
+     * overwritten.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && updateMask_ != null + && updateMask_ != com.google.protobuf.FieldMask.getDefaultInstance()) { + getUpdateMaskBuilder().mergeFrom(value); + } else { + updateMask_ = value; + } + } else { + updateMaskBuilder_.mergeFrom(value); + } + if (updateMask_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Optional. Field mask is used to specify the fields to be overwritten in the
+     * SkillEncryptionSpec resource by the update.
+     * The fields specified in the update_mask are relative to the resource, not
+     * the full request. A field will be overwritten if it is in the mask. If the
+     * user does not provide a mask then all fields present in the request will be
+     * overwritten.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearUpdateMask() { + bitField0_ = (bitField0_ & ~0x00000002); + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Field mask is used to specify the fields to be overwritten in the
+     * SkillEncryptionSpec resource by the update.
+     * The fields specified in the update_mask are relative to the resource, not
+     * the full request. A field will be overwritten if it is in the mask. If the
+     * user does not provide a mask then all fields present in the request will be
+     * overwritten.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetUpdateMaskFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Optional. Field mask is used to specify the fields to be overwritten in the
+     * SkillEncryptionSpec resource by the update.
+     * The fields specified in the update_mask are relative to the resource, not
+     * the full request. A field will be overwritten if it is in the mask. If the
+     * user does not provide a mask then all fields present in the request will be
+     * overwritten.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + + /** + * + * + *
+     * Optional. Field mask is used to specify the fields to be overwritten in the
+     * SkillEncryptionSpec resource by the update.
+     * The fields specified in the update_mask are relative to the resource, not
+     * the full request. A field will be overwritten if it is in the mask. If the
+     * user does not provide a mask then all fields present in the request will be
+     * overwritten.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + internalGetUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest) + private static final com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest(); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateSkillEncryptionSpecRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillEncryptionSpecRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillEncryptionSpecRequestOrBuilder.java new file mode 100644 index 000000000000..f67342b0ce74 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillEncryptionSpecRequestOrBuilder.java @@ -0,0 +1,126 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface UpdateSkillEncryptionSpecRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The SkillEncryptionSpec to update.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skillEncryptionSpec field is set. + */ + boolean hasSkillEncryptionSpec(); + + /** + * + * + *
+   * Required. The SkillEncryptionSpec to update.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skillEncryptionSpec. + */ + com.google.cloud.agentregistry.v1.SkillEncryptionSpec getSkillEncryptionSpec(); + + /** + * + * + *
+   * Required. The SkillEncryptionSpec to update.
+   * 
+ * + * + * .google.cloud.agentregistry.v1.SkillEncryptionSpec skill_encryption_spec = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.agentregistry.v1.SkillEncryptionSpecOrBuilder getSkillEncryptionSpecOrBuilder(); + + /** + * + * + *
+   * Optional. Field mask is used to specify the fields to be overwritten in the
+   * SkillEncryptionSpec resource by the update.
+   * The fields specified in the update_mask are relative to the resource, not
+   * the full request. A field will be overwritten if it is in the mask. If the
+   * user does not provide a mask then all fields present in the request will be
+   * overwritten.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + + /** + * + * + *
+   * Optional. Field mask is used to specify the fields to be overwritten in the
+   * SkillEncryptionSpec resource by the update.
+   * The fields specified in the update_mask are relative to the resource, not
+   * the full request. A field will be overwritten if it is in the mask. If the
+   * user does not provide a mask then all fields present in the request will be
+   * overwritten.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + + /** + * + * + *
+   * Optional. Field mask is used to specify the fields to be overwritten in the
+   * SkillEncryptionSpec resource by the update.
+   * The fields specified in the update_mask are relative to the resource, not
+   * the full request. A field will be overwritten if it is in the mask. If the
+   * user does not provide a mask then all fields present in the request will be
+   * overwritten.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillRequest.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillRequest.java new file mode 100644 index 000000000000..45045d796b95 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillRequest.java @@ -0,0 +1,1207 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +/** + * + * + *
+ * Message requesting a metadata update of a Skill.
+ * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.UpdateSkillRequest} + */ +@com.google.protobuf.Generated +public final class UpdateSkillRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.agentregistry.v1.UpdateSkillRequest) + UpdateSkillRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "UpdateSkillRequest"); + } + + // Use UpdateSkillRequest.newBuilder() to construct. + private UpdateSkillRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private UpdateSkillRequest() { + requestId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_UpdateSkillRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_UpdateSkillRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.UpdateSkillRequest.class, + com.google.cloud.agentregistry.v1.UpdateSkillRequest.Builder.class); + } + + private int bitField0_; + public static final int SKILL_FIELD_NUMBER = 1; + private com.google.cloud.agentregistry.v1.Skill skill_; + + /** + * + * + *
+   * Required. Mutable Skill container config fields to write.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skill field is set. + */ + @java.lang.Override + public boolean hasSkill() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Required. Mutable Skill container config fields to write.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skill. + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.Skill getSkill() { + return skill_ == null ? com.google.cloud.agentregistry.v1.Skill.getDefaultInstance() : skill_; + } + + /** + * + * + *
+   * Required. Mutable Skill container config fields to write.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillOrBuilder() { + return skill_ == null ? com.google.cloud.agentregistry.v1.Skill.getDefaultInstance() : skill_; + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + + /** + * + * + *
+   * Optional. Standard update target mask mapping relative fields.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Optional. Standard update target mask mapping relative fields.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + /** + * + * + *
+   * Optional. Standard update target mask mapping relative fields.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + public static final int REQUEST_ID_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object requestId_ = ""; + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + @java.lang.Override + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getSkill()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getUpdateMask()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, requestId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getSkill()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, requestId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.agentregistry.v1.UpdateSkillRequest)) { + return super.equals(obj); + } + com.google.cloud.agentregistry.v1.UpdateSkillRequest other = + (com.google.cloud.agentregistry.v1.UpdateSkillRequest) obj; + + if (hasSkill() != other.hasSkill()) return false; + if (hasSkill()) { + if (!getSkill().equals(other.getSkill())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (!getRequestId().equals(other.getRequestId())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasSkill()) { + hash = (37 * hash) + SKILL_FIELD_NUMBER; + hash = (53 * hash) + getSkill().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; + hash = (53 * hash) + getRequestId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.agentregistry.v1.UpdateSkillRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Message requesting a metadata update of a Skill.
+   * 
+ * + * Protobuf type {@code google.cloud.agentregistry.v1.UpdateSkillRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.agentregistry.v1.UpdateSkillRequest) + com.google.cloud.agentregistry.v1.UpdateSkillRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_UpdateSkillRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_UpdateSkillRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.agentregistry.v1.UpdateSkillRequest.class, + com.google.cloud.agentregistry.v1.UpdateSkillRequest.Builder.class); + } + + // Construct using com.google.cloud.agentregistry.v1.UpdateSkillRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetSkillFieldBuilder(); + internalGetUpdateMaskFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + skill_ = null; + if (skillBuilder_ != null) { + skillBuilder_.dispose(); + skillBuilder_ = null; + } + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + requestId_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.agentregistry.v1.AgentRegistryServiceProto + .internal_static_google_cloud_agentregistry_v1_UpdateSkillRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.UpdateSkillRequest getDefaultInstanceForType() { + return com.google.cloud.agentregistry.v1.UpdateSkillRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.UpdateSkillRequest build() { + com.google.cloud.agentregistry.v1.UpdateSkillRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.UpdateSkillRequest buildPartial() { + com.google.cloud.agentregistry.v1.UpdateSkillRequest result = + new com.google.cloud.agentregistry.v1.UpdateSkillRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.agentregistry.v1.UpdateSkillRequest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.skill_ = skillBuilder_ == null ? skill_ : skillBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.updateMask_ = updateMaskBuilder_ == null ? updateMask_ : updateMaskBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.requestId_ = requestId_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.agentregistry.v1.UpdateSkillRequest) { + return mergeFrom((com.google.cloud.agentregistry.v1.UpdateSkillRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.agentregistry.v1.UpdateSkillRequest other) { + if (other == com.google.cloud.agentregistry.v1.UpdateSkillRequest.getDefaultInstance()) + return this; + if (other.hasSkill()) { + mergeSkill(other.getSkill()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + if (!other.getRequestId().isEmpty()) { + requestId_ = other.requestId_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(internalGetSkillFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + requestId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.agentregistry.v1.Skill skill_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder> + skillBuilder_; + + /** + * + * + *
+     * Required. Mutable Skill container config fields to write.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skill field is set. + */ + public boolean hasSkill() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+     * Required. Mutable Skill container config fields to write.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skill. + */ + public com.google.cloud.agentregistry.v1.Skill getSkill() { + if (skillBuilder_ == null) { + return skill_ == null + ? com.google.cloud.agentregistry.v1.Skill.getDefaultInstance() + : skill_; + } else { + return skillBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Required. Mutable Skill container config fields to write.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSkill(com.google.cloud.agentregistry.v1.Skill value) { + if (skillBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + skill_ = value; + } else { + skillBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Mutable Skill container config fields to write.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSkill(com.google.cloud.agentregistry.v1.Skill.Builder builderForValue) { + if (skillBuilder_ == null) { + skill_ = builderForValue.build(); + } else { + skillBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Mutable Skill container config fields to write.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeSkill(com.google.cloud.agentregistry.v1.Skill value) { + if (skillBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && skill_ != null + && skill_ != com.google.cloud.agentregistry.v1.Skill.getDefaultInstance()) { + getSkillBuilder().mergeFrom(value); + } else { + skill_ = value; + } + } else { + skillBuilder_.mergeFrom(value); + } + if (skill_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Required. Mutable Skill container config fields to write.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearSkill() { + bitField0_ = (bitField0_ & ~0x00000001); + skill_ = null; + if (skillBuilder_ != null) { + skillBuilder_.dispose(); + skillBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Mutable Skill container config fields to write.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.agentregistry.v1.Skill.Builder getSkillBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetSkillFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Required. Mutable Skill container config fields to write.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillOrBuilder() { + if (skillBuilder_ != null) { + return skillBuilder_.getMessageOrBuilder(); + } else { + return skill_ == null + ? com.google.cloud.agentregistry.v1.Skill.getDefaultInstance() + : skill_; + } + } + + /** + * + * + *
+     * Required. Mutable Skill container config fields to write.
+     * 
+ * + * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder> + internalGetSkillFieldBuilder() { + if (skillBuilder_ == null) { + skillBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.agentregistry.v1.Skill, + com.google.cloud.agentregistry.v1.Skill.Builder, + com.google.cloud.agentregistry.v1.SkillOrBuilder>( + getSkill(), getParentForChildren(), isClean()); + skill_ = null; + } + return skillBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + + /** + * + * + *
+     * Optional. Standard update target mask mapping relative fields.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * Optional. Standard update target mask mapping relative fields.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Optional. Standard update target mask mapping relative fields.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + } else { + updateMaskBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Standard update target mask mapping relative fields.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Standard update target mask mapping relative fields.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && updateMask_ != null + && updateMask_ != com.google.protobuf.FieldMask.getDefaultInstance()) { + getUpdateMaskBuilder().mergeFrom(value); + } else { + updateMask_ = value; + } + } else { + updateMaskBuilder_.mergeFrom(value); + } + if (updateMask_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Optional. Standard update target mask mapping relative fields.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearUpdateMask() { + bitField0_ = (bitField0_ & ~0x00000002); + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Standard update target mask mapping relative fields.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetUpdateMaskFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Optional. Standard update target mask mapping relative fields.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + + /** + * + * + *
+     * Optional. Standard update target mask mapping relative fields.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + internalGetUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + private java.lang.Object requestId_ = ""; + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + requestId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearRequestId() { + requestId_ = getDefaultInstance().getRequestId(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Signed UUID request idempotency token.
+     * 
+ * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + requestId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.agentregistry.v1.UpdateSkillRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.agentregistry.v1.UpdateSkillRequest) + private static final com.google.cloud.agentregistry.v1.UpdateSkillRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.agentregistry.v1.UpdateSkillRequest(); + } + + public static com.google.cloud.agentregistry.v1.UpdateSkillRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateSkillRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.agentregistry.v1.UpdateSkillRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillRequestOrBuilder.java b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillRequestOrBuilder.java new file mode 100644 index 000000000000..a00eb2c95d05 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/java/com/google/cloud/agentregistry/v1/UpdateSkillRequestOrBuilder.java @@ -0,0 +1,138 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/agentregistry/v1/agentregistry_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.agentregistry.v1; + +@com.google.protobuf.Generated +public interface UpdateSkillRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.agentregistry.v1.UpdateSkillRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Mutable Skill container config fields to write.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the skill field is set. + */ + boolean hasSkill(); + + /** + * + * + *
+   * Required. Mutable Skill container config fields to write.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The skill. + */ + com.google.cloud.agentregistry.v1.Skill getSkill(); + + /** + * + * + *
+   * Required. Mutable Skill container config fields to write.
+   * 
+ * + * .google.cloud.agentregistry.v1.Skill skill = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.agentregistry.v1.SkillOrBuilder getSkillOrBuilder(); + + /** + * + * + *
+   * Optional. Standard update target mask mapping relative fields.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + + /** + * + * + *
+   * Optional. Standard update target mask mapping relative fields.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + + /** + * + * + *
+   * Optional. Standard update target mask mapping relative fields.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + java.lang.String getRequestId(); + + /** + * + * + *
+   * Optional. Signed UUID request idempotency token.
+   * 
+ * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + com.google.protobuf.ByteString getRequestIdBytes(); +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/agent.proto b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/agent.proto index c5c3081f4562..1a52cd18b48f 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/agent.proto +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/agent.proto @@ -37,6 +37,7 @@ message Agent { option (google.api.resource) = { type: "agentregistry.googleapis.com/Agent" pattern: "projects/{project}/locations/{location}/agents/{agent}" + pattern: "projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}" plural: "agents" singular: "agent" }; diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/agentregistry_service.proto b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/agentregistry_service.proto index e78849890b7d..229e8cc6ece2 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/agentregistry_service.proto +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/agentregistry_service.proto @@ -22,10 +22,14 @@ import "google/api/field_behavior.proto"; import "google/api/field_info.proto"; import "google/api/resource.proto"; import "google/cloud/agentregistry/v1/agent.proto"; +import "google/cloud/agentregistry/v1/ai_application.proto"; import "google/cloud/agentregistry/v1/binding.proto"; import "google/cloud/agentregistry/v1/endpoint.proto"; +import "google/cloud/agentregistry/v1/finding.proto"; import "google/cloud/agentregistry/v1/mcp_server.proto"; import "google/cloud/agentregistry/v1/service.proto"; +import "google/cloud/agentregistry/v1/skill.proto"; +import "google/cloud/agentregistry/v1/skill_encryption_spec.proto"; import "google/longrunning/operations.proto"; import "google/protobuf/empty.proto"; import "google/protobuf/field_mask.proto"; @@ -39,7 +43,7 @@ option java_package = "com.google.cloud.agentregistry.v1"; option php_namespace = "Google\\Cloud\\AgentRegistry\\V1"; option ruby_package = "Google::Cloud::AgentRegistry::V1"; -// Service for managing Agents, Endpoints, McpServers, Services, and Bindings. +// Service for managing Agent Registry resources. service AgentRegistry { option (google.api.default_host) = "agentregistry.googleapis.com"; option (google.api.oauth_scopes) = @@ -237,6 +241,270 @@ service AgentRegistry { }; option (google.api.method_signature) = "parent"; } + + // ========================================================================= + // # Skills Collection APIs + // + // Creates a Skill resource container, optionally publishing the initial + // SkillRevision inline in a single, atomic CRUD roundtrip. + rpc CreateSkill(CreateSkillRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*}/skills" + body: "skill" + }; + option (google.api.method_signature) = "parent,skill,skill_id"; + option (google.longrunning.operation_info) = { + response_type: "Skill" + metadata_type: "OperationMetadata" + }; + } + + // Fetches the active configuration and metadata of a Skill. + rpc GetSkill(GetSkillRequest) returns (Skill) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/skills/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Updates Skill metadata or overrides active pointers/state using REST + // standard PATCH. + rpc UpdateSkill(UpdateSkillRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + patch: "/v1/{skill.name=projects/*/locations/*/skills/*}" + body: "skill" + }; + option (google.api.method_signature) = "skill,update_mask"; + option (google.longrunning.operation_info) = { + response_type: "Skill" + metadata_type: "OperationMetadata" + }; + } + + // Deletes a Skill container along with all its revisions. + rpc DeleteSkill(DeleteSkillRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/skills/*}" + }; + option (google.api.method_signature) = "name"; + option (google.longrunning.operation_info) = { + response_type: "google.protobuf.Empty" + metadata_type: "OperationMetadata" + }; + } + + // Lists logical Skills available in a project. + rpc ListSkills(ListSkillsRequest) returns (ListSkillsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/skills" + }; + option (google.api.method_signature) = "parent"; + } + + // Custom deep-search method to filter by frontmatter or query SKILL.md text + // blobs. + rpc SearchSkills(SearchSkillsRequest) returns (SearchSkillsResponse) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*}/skills:search" + body: "*" + additional_bindings { + get: "/v1/{parent=projects/*/locations/*}/skills:search" + } + }; + } + + // Creates a new immutable revision and triggers validation pipelines. + rpc CreateSkillRevision(CreateSkillRevisionRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*/skills/*}/revisions" + body: "skill_revision" + }; + option (google.api.method_signature) = + "parent,skill_revision,skill_revision_id"; + option (google.longrunning.operation_info) = { + response_type: "SkillRevision" + metadata_type: "OperationMetadata" + }; + } + + // Gets details of a single immutable Revision. + rpc GetSkillRevision(GetSkillRevisionRequest) returns (SkillRevision) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/skills/*/revisions/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Deletes a specific revision (restricted to admins to purge accidentally + // committed secrets). + rpc DeleteSkillRevision(DeleteSkillRevisionRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/skills/*/revisions/*}" + }; + option (google.api.method_signature) = "name"; + option (google.longrunning.operation_info) = { + response_type: "google.protobuf.Empty" + metadata_type: "OperationMetadata" + }; + } + + // Lists all revisions belonging to a parent Skill. + rpc ListSkillRevisions(ListSkillRevisionsRequest) + returns (ListSkillRevisionsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*/skills/*}/revisions" + }; + option (google.api.method_signature) = "parent"; + } + + // Fetches details of a specific Publisher. + rpc GetPublisher(GetPublisherRequest) returns (Publisher) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/publishers/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Lists all Publishers in a location. + rpc ListPublishers(ListPublishersRequest) returns (ListPublishersResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/publishers" + }; + option (google.api.method_signature) = "parent"; + } + + // Gets details of a single AI Application. + rpc GetAiApplication(GetAiApplicationRequest) returns (AiApplication) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/aiApplications/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Lists AI Applications in a given project and location. + rpc ListAiApplications(ListAiApplicationsRequest) + returns (ListAiApplicationsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/aiApplications" + }; + option (google.api.method_signature) = "parent"; + } + + // Gets details of a single Agent under an AI Application. + rpc GetAiApplicationAgent(GetAiApplicationAgentRequest) returns (Agent) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/aiApplications/*/agents/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Lists Agents under an AI Application. + rpc ListAiApplicationAgents(ListAiApplicationAgentsRequest) + returns (ListAiApplicationAgentsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*/aiApplications/*}/agents" + }; + option (google.api.method_signature) = "parent"; + } + + // Gets details of a single McpServer under an AI Application. + rpc GetAiApplicationMcpServer(GetAiApplicationMcpServerRequest) + returns (McpServer) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/aiApplications/*/mcpServers/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Lists McpServers under an AI Application. + rpc ListAiApplicationMcpServers(ListAiApplicationMcpServersRequest) + returns (ListAiApplicationMcpServersResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*/aiApplications/*}/mcpServers" + }; + option (google.api.method_signature) = "parent"; + } + + // Gets details of a single Finding. + rpc GetFinding(GetFindingRequest) returns (Finding) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/findings/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Lists Findings in a given project and location. + rpc ListFindings(ListFindingsRequest) returns (ListFindingsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/findings" + }; + option (google.api.method_signature) = "parent"; + } + + // Gets details of a single Endpoint under an AI Application. + rpc GetAiApplicationEndpoint(GetAiApplicationEndpointRequest) + returns (Endpoint) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/aiApplications/*/endpoints/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Lists Endpoints under an AI Application. + rpc ListAiApplicationEndpoints(ListAiApplicationEndpointsRequest) + returns (ListAiApplicationEndpointsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*/aiApplications/*}/endpoints" + }; + option (google.api.method_signature) = "parent"; + } + + // ========================================================================= + // # Skill Encryption Spec Service Methods + // + // Gets the customer-managed encryption key (CMEK) configuration for Skills in + // a specific project and location. + rpc GetSkillEncryptionSpec(GetSkillEncryptionSpecRequest) + returns (SkillEncryptionSpec) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/skillEncryptionSpec}" + }; + option (google.api.method_signature) = "name"; + } + + // Updates the customer-managed encryption key (CMEK) configuration for Skills + // in a specific project and location. + // + // This method is only allowed when no Skills exist in the target project and + // location. If any Skill already exists in the location, the request fails + // with `FAILED_PRECONDITION`. + rpc UpdateSkillEncryptionSpec(UpdateSkillEncryptionSpecRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + patch: "/v1/{skill_encryption_spec.name=projects/*/locations/*/skillEncryptionSpec}" + body: "skill_encryption_spec" + }; + option (google.api.method_signature) = "skill_encryption_spec,update_mask"; + option (google.longrunning.operation_info) = { + response_type: "SkillEncryptionSpec" + metadata_type: "OperationMetadata" + }; + } +} + +// The type of search to perform. Additional search types may be supported in +// the future. +enum SearchType { + // Invalid search type. + SEARCH_TYPE_UNSPECIFIED = 0; + + // Search for a keyword across all searchable fields. + KEYWORD = 1; + + // Search based on the meaning and intent of a natural language query. + SEMANTIC = 2; } // Message for requesting list of Agents @@ -245,7 +513,7 @@ message ListAgentsRequest { string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { - child_type: "agentregistry.googleapis.com/Agent" + type: "locations.googleapis.com/Location" } ]; @@ -279,7 +547,7 @@ message SearchAgentsRequest { string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { - child_type: "agentregistry.googleapis.com/Agent" + type: "locations.googleapis.com/Location" } ]; @@ -311,7 +579,7 @@ message SearchAgentsRequest { // // Examples: // - // * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:reasoningEngines:1234"` + // * `agentId="urn:agent:projects-123:projects:123:locations:us-central1:aiplatform:reasoningEngines:1234"` // to find the agent with the specified agent ID. // * `name:important` to find agents whose name contains `important` as a // word. @@ -358,6 +626,48 @@ message GetAgentRequest { ]; } +// Message for getting an Agent under an AI Application. +message GetAiApplicationAgentRequest { + // Required. Name of the resource. + // Format: + // `projects/{project}/locations/{location}/aiApplications/{ai_application}/agents/{agent}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/Agent" + } + ]; +} + +// Message for requesting list of Agents under an AI Application. +message ListAiApplicationAgentsRequest { + // Required. Parent value (AI Application) for ListAiApplicationAgentsRequest. + // Format: + // `projects/{project}/locations/{location}/aiApplications/{ai_application}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/AiApplication" + } + ]; + + // Optional. Requested page size. Server may return fewer items than + // requested. If unspecified, server will pick an appropriate default. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A token identifying a page of results the server should return. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// Message for response to listing Agents under an AI Application. +message ListAiApplicationAgentsResponse { + // The list of Agents. + repeated Agent agents = 1; + + // A token identifying a page of results the server should return. + string next_page_token = 2; +} + // Message for requesting list of Endpoints message ListEndpointsRequest { // Required. The project and location to list endpoints in. @@ -365,7 +675,7 @@ message ListEndpointsRequest { string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { - child_type: "agentregistry.googleapis.com/Endpoint" + type: "locations.googleapis.com/Location" } ]; @@ -417,6 +727,49 @@ message GetEndpointRequest { ]; } +// Message for getting an Endpoint under an AI Application. +message GetAiApplicationEndpointRequest { + // Required. Name of the resource. + // Format: + // `projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/Endpoint" + } + ]; +} + +// Message for requesting list of Endpoints under an AI Application. +message ListAiApplicationEndpointsRequest { + // Required. Parent value (AI Application) for + // ListAiApplicationEndpointsRequest. + // Format: + // `projects/{project}/locations/{location}/aiApplications/{ai_application}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/AiApplication" + } + ]; + + // Optional. Requested page size. Server may return fewer items than + // requested. If unspecified, server will pick an appropriate default. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A token identifying a page of results the server should return. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// Message for response to listing Endpoints under an AI Application. +message ListAiApplicationEndpointsResponse { + // The list of Endpoints. + repeated Endpoint endpoints = 1; + + // A token identifying a page of results the server should return. + string next_page_token = 2; +} + // Message for requesting list of McpServers message ListMcpServersRequest { // Required. Parent value for ListMcpServersRequest. Format: @@ -424,7 +777,7 @@ message ListMcpServersRequest { string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { - child_type: "agentregistry.googleapis.com/McpServer" + type: "locations.googleapis.com/Location" } ]; @@ -458,7 +811,7 @@ message SearchMcpServersRequest { string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { - child_type: "agentregistry.googleapis.com/McpServer" + type: "locations.googleapis.com/Location" } ]; @@ -534,6 +887,49 @@ message GetMcpServerRequest { ]; } +// Message for getting an McpServer under an AI Application. +message GetAiApplicationMcpServerRequest { + // Required. Name of the resource. + // Format: + // `projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/McpServer" + } + ]; +} + +// Message for requesting list of McpServers under an AI Application. +message ListAiApplicationMcpServersRequest { + // Required. Parent value (AI Application) for + // ListAiApplicationMcpServersRequest. + // Format: + // `projects/{project}/locations/{location}/aiApplications/{ai_application}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/AiApplication" + } + ]; + + // Optional. Requested page size. Server may return fewer items than + // requested. If unspecified, server will pick an appropriate default. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A token identifying a page of results the server should return. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// Message for response to listing McpServers under an AI Application. +message ListAiApplicationMcpServersResponse { + // The list of McpServers. + repeated McpServer mcp_servers = 1; + + // A token identifying a page of results the server should return. + string next_page_token = 2; +} + // Message for requesting list of Services message ListServicesRequest { // Required. The project and location to list services in. @@ -932,3 +1328,467 @@ message DeleteBindingRequest { (google.api.field_behavior) = OPTIONAL ]; } + +// ========================================================================= +// # Skills Messages +// +// Message requesting creation of a logical Skill container. +message CreateSkillRequest { + // Required. The project and location location to bootstrap. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "agentregistry.googleapis.com/Skill" + } + ]; + + // Required. Custom, user-defined unique container identifier. + // Must be unique within the parent project and location. + // This value should be 4-64 characters, and valid characters + // are `/[a-z][0-9]-/`. + string skill_id = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. Skill container body config. + Skill skill = 3 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Signed UUID request idempotency token. + string request_id = 4 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OPTIONAL + ]; +} + +// Message requesting details of a Skill. +message GetSkillRequest { + // Required. Target resource container name. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/Skill" + } + ]; +} + +// Message requesting a metadata update of a Skill. +message UpdateSkillRequest { + // Required. Mutable Skill container config fields to write. + Skill skill = 1 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Standard update target mask mapping relative fields. + google.protobuf.FieldMask update_mask = 2 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Signed UUID request idempotency token. + string request_id = 3 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OPTIONAL + ]; +} + +// Message requesting deletion of a Skill. +message DeleteSkillRequest { + // Required. Target Skill container name to remove. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/Skill" + } + ]; + + // Optional. Signed UUID request idempotency token. + string request_id = 2 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OPTIONAL + ]; + + // Optional. If set to true, any child SkillRevisions under this Skill will + // also be deleted. Otherwise, the request will only succeed if the Skill has + // no child SkillRevisions. + bool force = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// Requesting a list of Skills inside a location. +message ListSkillsRequest { + // Required. Parent value for ListSkillsRequest + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "agentregistry.googleapis.com/Skill" + } + ]; + + // Optional. Requested page size. Server may return fewer items than + // requested. If unspecified, server will pick an appropriate default. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A token identifying a page of results the server should return. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Use this field to specify filter criteria on list results. + // Filter expressions can be used to restrict results based upon filterable + // fields, where equality operators can be used. See + // [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools) + // for more details. + // + // Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`. + // + // | Field | `=` | `<`, `>` | + // |--------------|-----|----------| + // | state | Yes | No | + // | targetState | Yes | No | + // | createTime | Yes | Yes | + // | updateTime | Yes | Yes | + // + // Examples: + // + // * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state. + string filter = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Hint for how to order the results + string order_by = 5 [(google.api.field_behavior) = OPTIONAL]; +} + +// Response structure listing logical Skills. +message ListSkillsResponse { + // Returned container list. + repeated Skill skills = 1; + + // Page continuation continuation token. + string next_page_token = 2; + + // Unreachable locations or failures. + repeated string unreachable = 3; +} + +// Requesting a deep search of Skills. +message SearchSkillsRequest { + // Required. Parent value for SearchSkillsRequest. Format: + // `projects/{project}/locations/{location}`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "agentregistry.googleapis.com/Skill" + } + ]; + + // Optional. The type of search. + SearchType search_type = 6 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Search criteria used to select the Skills to return. If no search + // criteria is specified then all accessible Skills will be returned. + // + // Search expressions can be used to restrict results based upon searchable + // fields, where the operators can be used along with the suffix wildcard + // symbol `*`. See + // [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools) + // for more details. + // + // Allowed operators: `=`, `:`, `NOT`, `AND`, `OR`, and `()`. + // + // Searchable fields: + // + // | Field | `=` | `:` | `*` | Keyword Search | + // |---------------------------|-----|-----|-----|----------------| + // | skillId | Yes | Yes | Yes | Included | + // | name | No | Yes | Yes | Included | + // | displayName | No | Yes | Yes | Included | + // | description | No | Yes | No | Included | + // | frontmatter.name | No | Yes | No | Included | + // | frontmatter.description | No | Yes | No | Included | + // | frontmatter.compatibility | No | Yes | No | Included | + // | frontmatter.license | No | Yes | No | Included | + // + // Examples: + // + // * `skillId="urn:skill:projects-1234:locations:global:private-important-skill"` + // to find the skill with the specified skill ID. + // * `name:important` to find skills whose name contains `important` as a + // word. + // * `displayName:works*` to find skills whose display name contains words + // that start with `works`. + string search_string = 7 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Use this field to specify additional filter criteria on search + // results. Filter expressions can be used to restrict results based upon + // filterable fields, where equality operators can be used. See + // [instructions](https://docs.cloud.google.com/agent-registry/search-agents-and-tools) + // for more details. + // + // Allowed operators: `=`, `<`, `>`, `NOT`, `AND`, `OR`, and `()`. + // + // | Field | `=` | `<`, `>` | + // |--------------|-----|----------| + // | state | Yes | No | + // | targetState | Yes | No | + // | createTime | Yes | Yes | + // | updateTime | Yes | Yes | + // + // Examples: + // + // * `state=ACTIVE` to restrict results to skills in the `ACTIVE` state. + string filter = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The maximum number of search results to return per page. The page + // size is capped at `100`, even if a larger value is specified. A negative + // value will result in an `INVALID_ARGUMENT` error. If unspecified or set to + // `0`, a default value of `20` will be used. The server may return fewer + // results than requested. + int32 page_size = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. If present, retrieve the next batch of results from the preceding + // call to this method. `page_token` must be the value of `next_page_token` + // from the previous response. The values of all other method parameters, must + // be identical to those in the previous call. + string page_token = 4 [(google.api.field_behavior) = OPTIONAL]; +} + +// Response listing searched Skills. +message SearchSkillsResponse { + // Matched Skills list. + repeated Skill skills = 1; + + // Query page offset continuation token. + string next_page_token = 2; +} + +// Requesting creation of a new SkillRevision snapshot. +message CreateSkillRevisionRequest { + // Required. Parent logical container name. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/Skill" + } + ]; + + // Required. Immutable SkillRevision snapshot definition schema. + SkillRevision skill_revision = 2 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Custom, user-defined unique revision identifier. + // Format: 4-63 characters, matching regex `^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$` + string skill_revision_id = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Signed UUID request idempotency token. + string request_id = 4 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OPTIONAL + ]; +} + +// Requesting details of a Revision. +message GetSkillRevisionRequest { + // Required. Target revision name. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/SkillRevision" + } + ]; +} + +// Requesting deletion of a specific Revision. +message DeleteSkillRevisionRequest { + // Required. Target revision name to remove. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/SkillRevision" + } + ]; + + // Optional. Signed UUID request idempotency token. + string request_id = 2 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OPTIONAL + ]; +} + +// Requesting a list of Revisions under a Skill. +message ListSkillRevisionsRequest { + // Required. Parent logical container name to query. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/Skill" + } + ]; + + // Optional. Page limit size. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Page offset token. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// Response listing Revisions. +message ListSkillRevisionsResponse { + // Returned version snapshot list. + repeated SkillRevision skill_revisions = 1; + + // Page offset continuation token. + string next_page_token = 2; +} + +// Requesting details of a specific Publisher. +message GetPublisherRequest { + // Required. Target publisher resource name. + // Format: `projects/{project}/locations/{location}/publishers/{publisher}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/Publisher" + } + ]; +} + +// Requesting a list of Publishers. +message ListPublishersRequest { + // Required. Parent location to query. + // Format: `projects/{project}/locations/{location}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "agentregistry.googleapis.com/Publisher" + } + ]; + + // Optional. Page limit size. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Page offset token. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// Response listing Publishers. +message ListPublishersResponse { + // The returned list of Publishers. + repeated Publisher publishers = 1; + + // Page offset continuation token. + string next_page_token = 2; +} + +// Message for getting an AI Application. +message GetAiApplicationRequest { + // Required. Target AI Application resource name. + // Format: + // `projects/{project}/locations/{location}/aiApplications/{ai_application}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/AiApplication" + } + ]; +} + +// Message for requesting a list of AiApplications. +message ListAiApplicationsRequest { + // Required. Parent project and location to query. + // Format: `projects/{project}/locations/{location}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "agentregistry.googleapis.com/AiApplication" + } + ]; + + // Optional. Requested page size. Server may return fewer items than + // requested. If unspecified, server will pick an appropriate default. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A token identifying a page of results the server should return. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Filtering results. + string filter = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Hint for how to order the results. + string order_by = 5 [(google.api.field_behavior) = OPTIONAL]; +} + +// Message for response to listing AiApplications. +message ListAiApplicationsResponse { + // The list of AiApplications. + repeated AiApplication ai_applications = 1; + + // A token identifying a page of results the server should return. + string next_page_token = 2; + + // Unordered list. Locations that could not be reached. + repeated string unreachable = 3 + [(google.api.field_behavior) = UNORDERED_LIST]; +} + +// Message for requesting list of Findings. +message ListFindingsRequest { + // Required. Parent value for ListFindingsRequest. Format: + // `projects/{project}/locations/{location}`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "agentregistry.googleapis.com/Finding" + } + ]; + + // Optional. Requested page size. Server may return fewer items than + // requested. If unspecified, server will pick an appropriate default. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A token identifying a page of results the server should return. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Filtering results + string filter = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Hint for how to order the results + string order_by = 5 [(google.api.field_behavior) = OPTIONAL]; +} + +// Message for response to listing Findings. +message ListFindingsResponse { + // The list of Findings. + repeated Finding findings = 1; + + // A token identifying a page of results the server should return. + string next_page_token = 2; +} + +// Message for getting a Finding. +message GetFindingRequest { + // Required. The name of the Finding to retrieve. + // Format: `projects/{project}/locations/{location}/findings/{finding}`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/Finding" + } + ]; +} + +// Message for requesting a SkillEncryptionSpec. +message GetSkillEncryptionSpecRequest { + // Required. The name of the SkillEncryptionSpec to retrieve. + // Format: `projects/{project}/locations/{location}/skillEncryptionSpec`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/SkillEncryptionSpec" + } + ]; +} + +// Message for updating a SkillEncryptionSpec. +message UpdateSkillEncryptionSpecRequest { + // Required. The SkillEncryptionSpec to update. + SkillEncryptionSpec skill_encryption_spec = 1 + [(google.api.field_behavior) = REQUIRED]; + + // Optional. Field mask is used to specify the fields to be overwritten in the + // SkillEncryptionSpec resource by the update. + // The fields specified in the update_mask are relative to the resource, not + // the full request. A field will be overwritten if it is in the mask. If the + // user does not provide a mask then all fields present in the request will be + // overwritten. + google.protobuf.FieldMask update_mask = 2 + [(google.api.field_behavior) = OPTIONAL]; +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/ai_application.proto b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/ai_application.proto new file mode 100644 index 000000000000..4a4ff2a06b30 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/ai_application.proto @@ -0,0 +1,94 @@ +// Copyright 2026 Google LLC +// +// 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. + +syntax = "proto3"; + +package google.cloud.agentregistry.v1; + +import "google/api/field_behavior.proto"; +import "google/api/field_info.proto"; +import "google/api/resource.proto"; +import "google/cloud/apphub/v1/application.proto"; +import "google/cloud/apphub/v1/attributes.proto"; +import "google/protobuf/timestamp.proto"; + +option csharp_namespace = "Google.Cloud.AgentRegistry.V1"; +option go_package = "cloud.google.com/go/agentregistry/apiv1/agentregistrypb;agentregistrypb"; +option java_multiple_files = true; +option java_outer_classname = "AiApplicationProto"; +option java_package = "com.google.cloud.agentregistry.v1"; +option php_namespace = "Google\\Cloud\\AgentRegistry\\V1"; +option ruby_package = "Google::Cloud::AgentRegistry::V1"; + +// Represents an AI Application. +message AiApplication { + option (google.api.resource) = { + type: "agentregistry.googleapis.com/AiApplication" + pattern: "projects/{project}/locations/{location}/aiApplications/{ai_application}" + plural: "aiApplications" + singular: "aiApplication" + }; + + // The lifecycle states of an AI Application. + enum State { + // Default value. This value is unused. + STATE_UNSPECIFIED = 0; + + // The resource is being provisioned or created. + CREATING = 1; + + // The resource is active and ready for use. + ACTIVE = 2; + + // The resource is in the process of being deleted. + DELETING = 3; + } + + // Identifier. Resource name of the AI Application. + // Format: + // `projects/{project}/locations/{location}/aiApplications/{ai_application}` + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Optional. User-defined name for the AI Application. + string display_name = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. User-defined description of the AI Application. + string description = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. Universally unique identifier (UUID4) for the AI Application. + string uid = 4 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OUTPUT_ONLY + ]; + + // Output only. Creation time. + google.protobuf.Timestamp create_time = 5 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Last update time. + google.protobuf.Timestamp update_time = 6 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The current state of the AI Application. + State state = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Consumer provided attributes. + google.cloud.apphub.v1.Attributes attributes = 8 + [(google.api.field_behavior) = OPTIONAL]; + + // Output only. Properties of an underlying cloud resource that can comprise + // an AI Application. + google.cloud.apphub.v1.ApplicationProperties application_properties = 9 + [(google.api.field_behavior) = OUTPUT_ONLY]; +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/endpoint.proto b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/endpoint.proto index 29978c2197e4..cad22a7d91da 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/endpoint.proto +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/endpoint.proto @@ -35,6 +35,7 @@ message Endpoint { option (google.api.resource) = { type: "agentregistry.googleapis.com/Endpoint" pattern: "projects/{project}/locations/{location}/endpoints/{endpoint}" + pattern: "projects/{project}/locations/{location}/aiApplications/{ai_application}/endpoints/{endpoint}" plural: "endpoints" singular: "endpoint" }; diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/finding.proto b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/finding.proto new file mode 100644 index 000000000000..94a04911e9bd --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/finding.proto @@ -0,0 +1,120 @@ +// Copyright 2026 Google LLC +// +// 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. + +syntax = "proto3"; + +package google.cloud.agentregistry.v1; + +import "google/api/field_behavior.proto"; +import "google/api/field_info.proto"; +import "google/api/resource.proto"; +import "google/protobuf/timestamp.proto"; + +option csharp_namespace = "Google.Cloud.AgentRegistry.V1"; +option go_package = "cloud.google.com/go/agentregistry/apiv1/agentregistrypb;agentregistrypb"; +option java_multiple_files = true; +option java_outer_classname = "FindingProto"; +option java_package = "com.google.cloud.agentregistry.v1"; +option php_namespace = "Google\\Cloud\\AgentRegistry\\V1"; +option ruby_package = "Google::Cloud::AgentRegistry::V1"; + +// The severity of the finding. +enum Severity { + // This value is used for findings when a source doesn't write a severity + // value. + SEVERITY_UNSPECIFIED = 0; + + // Critical severity. + SEVERITY_CRITICAL = 1; + + // High severity. + SEVERITY_HIGH = 2; + + // Medium severity. + SEVERITY_MEDIUM = 3; + + // Low severity. + SEVERITY_LOW = 4; +} + +// Represents a security Finding. +message Finding { + option (google.api.resource) = { + type: "agentregistry.googleapis.com/Finding" + pattern: "projects/{project}/locations/{location}/findings/{finding}" + plural: "findings" + singular: "finding" + }; + + // File location of the finding. + message File { + // Optional. Relative path of the file containing the finding. + string path = 1 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Line number (1-based), or 0 if whole File / unknown. + int64 line_number = 2 [(google.api.field_behavior) = OPTIONAL]; + } + + // Represents what kind of Finding it is. + // For more information on finding classes, see + // https://cloud.google.com/security-command-center/docs/concepts-vulnerabilities-findings#classes. + enum FindingClass { + // Unspecified finding class. + FINDING_CLASS_UNSPECIFIED = 0; + + // Describes a potential weakness in software that increases risk to + // Confidentiality & Integrity & Availability. + VULNERABILITY = 1; + + // Describes a potential security risk due to plaintext credentials, + // keys, or tokens being exposed in an asset or workload. + SECRET = 3; + } + + // Identifier. Resource name of the Finding. + // Format: `projects/{project}/locations/{location}/findings/{finding}`. + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Output only. Universally unique identifier (UUID4) for the Finding. + string uid = 2 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OUTPUT_ONLY + ]; + + // Output only. Create time. + google.protobuf.Timestamp create_time = 3 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Update time. + google.protobuf.Timestamp update_time = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Severity of the finding. + Severity severity = 6 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Class of the finding. + FindingClass finding_class = 7 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. File associated with the finding. + repeated File files = 8 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Detailed description of the finding. + string detail = 10 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The resource that the finding is associated with. + string resource = 11 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.resource_reference) = { type: "*" } + ]; +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/mcp_server.proto b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/mcp_server.proto index dfea8e01504d..e624cd2beab6 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/mcp_server.proto +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/mcp_server.proto @@ -35,6 +35,7 @@ message McpServer { option (google.api.resource) = { type: "agentregistry.googleapis.com/McpServer" pattern: "projects/{project}/locations/{location}/mcpServers/{mcp_server}" + pattern: "projects/{project}/locations/{location}/aiApplications/{ai_application}/mcpServers/{mcp_server}" plural: "mcpServers" singular: "mcpServer" }; @@ -78,6 +79,11 @@ message McpServer { // Output only. Annotations associated with the tool. Annotations annotations = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Protocol-level tool metadata conforming to MCP _meta + // specification. Output only. + google.protobuf.Struct meta = 4 + [json_name = "_meta", (google.api.field_behavior) = OUTPUT_ONLY]; } // Identifier. The resource name of the MCP Server. diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/properties.proto b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/properties.proto index 86a0f1c10467..ed53907dce8a 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/properties.proto +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/properties.proto @@ -17,6 +17,7 @@ syntax = "proto3"; package google.cloud.agentregistry.v1; import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; option csharp_namespace = "Google.Cloud.AgentRegistry.V1"; option go_package = "cloud.google.com/go/agentregistry/apiv1/agentregistrypb;agentregistrypb"; diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/service.proto b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/service.proto index 174bd716cda9..5a8c3ceead5b 100644 --- a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/service.proto +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/service.proto @@ -54,8 +54,11 @@ message Service { A2A_AGENT_CARD = 2; } - // Required. The type of the agent spec content. - Type type = 1 [(google.api.field_behavior) = REQUIRED]; + // Required. Immutable. The type of the agent spec content. + Type type = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.field_behavior) = IMMUTABLE + ]; // Optional. The content of the Agent spec in the JSON format. // This payload is validated against the schema for the specified type. @@ -65,7 +68,8 @@ message Service { // The spec of the MCP Server. message McpServerSpec { - // The type of the MCP Server spec. + // The type of the MCP Server spec. Additional values may be added in the + // future. enum Type { // Unspecified type. TYPE_UNSPECIFIED = 0; @@ -78,8 +82,11 @@ message Service { TOOL_SPEC = 2; } - // Required. The type of the MCP Server spec content. - Type type = 1 [(google.api.field_behavior) = REQUIRED]; + // Required. Immutable. The type of the MCP Server spec content. + Type type = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.field_behavior) = IMMUTABLE + ]; // Optional. The content of the MCP Server spec. // This payload is validated against the schema for the specified type. @@ -89,7 +96,8 @@ message Service { // The spec of the endpoint. message EndpointSpec { - // The type of the endpoint spec. + // The type of the endpoint spec. Additional values may be added in the + // future. enum Type { // Unspecified type. TYPE_UNSPECIFIED = 0; @@ -98,8 +106,11 @@ message Service { NO_SPEC = 1; } - // Required. The type of the endpoint spec content. - Type type = 1 [(google.api.field_behavior) = REQUIRED]; + // Required. Immutable. The type of the endpoint spec content. + Type type = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.field_behavior) = IMMUTABLE + ]; // Optional. The content of the endpoint spec. // Reserved for future use. diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/skill.proto b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/skill.proto new file mode 100644 index 000000000000..0b87890716aa --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/skill.proto @@ -0,0 +1,426 @@ +// Copyright 2026 Google LLC +// +// 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. + +syntax = "proto3"; + +package google.cloud.agentregistry.v1; + +import "google/api/field_behavior.proto"; +import "google/api/field_info.proto"; +import "google/api/resource.proto"; +import "google/protobuf/timestamp.proto"; + +option csharp_namespace = "Google.Cloud.AgentRegistry.V1"; +option go_package = "cloud.google.com/go/agentregistry/apiv1/agentregistrypb;agentregistrypb"; +option java_multiple_files = true; +option java_outer_classname = "SkillProto"; +option java_package = "com.google.cloud.agentregistry.v1"; +option php_namespace = "Google\\Cloud\\AgentRegistry\\V1"; +option ruby_package = "Google::Cloud::AgentRegistry::V1"; + +// Represents an Executable Agent Skill or a Composite Tool Suite (Bundle). +// Sibling resource with Agent and McpServer under agentregistry.googleapis.com. +message Skill { + option (google.api.resource) = { + type: "agentregistry.googleapis.com/Skill" + pattern: "projects/{project}/locations/{location}/skills/{skill}" + plural: "skills" + singular: "skill" + }; + + // The structural type of the Skill. + enum Type { + // Default value. This value is unused. + TYPE_UNSPECIFIED = 0; + + // A standard, leaf executable skill containing natural language and code. + SIMPLE = 1; + } + + // System-managed state. + enum State { + // Default value. This value is unused. + STATE_UNSPECIFIED = 0; + + // The skill is being created. It is not served. + STATE_CREATING = 1; + + // The skill is in draft, or lacks a valid payload. It is not served. + STATE_DRAFT = 2; + + // The skill is active and is served. + STATE_ACTIVE = 3; + + // The skill is disabled and is not served. + STATE_DISABLED = 4; + + // The skill is deprecated. It is served, but emits warnings. + STATE_DEPRECATED = 5; + + // The skill is decommissioned and is not served. + STATE_DECOMMISSIONED = 6; + + // The skill is being deleted. It is not served. + STATE_DELETING = 7; + } + + // User-configurable target state. + enum TargetState { + // Default value. This value is unused. + TARGET_STATE_UNSPECIFIED = 0; + + // The skill is in draft and cannot be served. + TARGET_STATE_DRAFT = 1; + + // The skill is active and can be served. + TARGET_STATE_ACTIVE = 2; + + // The skill is disabled and cannot be served. + TARGET_STATE_DISABLED = 3; + + // The skill is deprecated. It can still be served, but emits warnings. + TARGET_STATE_DEPRECATED = 4; + + // The skill is decommissioned and cannot be served. + TARGET_STATE_DECOMMISSIONED = 5; + } + + // Identifier. Resource name of the Skill. + // Format: `projects/{project}/locations/{location}/skills/{skill}` + // The `{skill}` segment acts as the resource ID. If the skill is associated + // with a Publisher, this segment typically uses a hyphenated namespace prefix + // corresponding to the publisher (e.g., `google-workspace-create-docs`). + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Output only. Universally unique identifier (UUID4) for the logical + // container. + string uid = 2 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OUTPUT_ONLY + ]; + + // Optional. Human-readable display name of the skill. + // Maximum length is 128 characters. + string display_name = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Brief summary describing the capabilities of the skill. + // Maximum length is 2048 characters. + string description = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Required. Structural deployment type (SIMPLE leaf vs COMPOSITE bundle). + Type type = 5 [(google.api.field_behavior) = REQUIRED]; + + // Output only. The system-managed state of the skill. + State state = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Required. User-managed target state of the skill. + TargetState target_state = 7 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The full resource name of the revision currently served by + // default (floating track). + // Format: + // `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}` + string default_revision = 8 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/SkillRevision" + } + ]; + + // Output only. Lightweight frontmatter metadata attributes copied from the + // default revision. + Frontmatter frontmatter = 9 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. A stable, globally unique logical identifier for the skill. + // It is securely constructed by the backend by combining the associated + // `publisher`'s verified namespace and the skill's resource ID to enforce + // strict ownership. For example, the prefix `google-` is reserved exclusively + // for first-party Google publishers to prevent namespace squatting. + // Example: `urn:skill:google-workspace:create-docs` + string skill_id = 17 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Create time. + google.protobuf.Timestamp create_time = 11 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Update time. + google.protobuf.Timestamp update_time = 12 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. The publisher resource associated with this skill. + // Format: `projects/{project}/locations/{location}/publishers/{publisher}` + // The publisher dictates the allowed namespace prefixes for the skill's name + // and logical `skill_id` (e.g., Publisher `google` authorizes the `google-*` + // prefix). + string publisher = 15 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/Publisher" + } + ]; + + // Optional. Input only. Optional nested initial revision payload to support + // standard one-shot creation. The server processes this field on input during + // creation but must never return it in responses. + SkillRevision initial_revision = 14 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.field_behavior) = INPUT_ONLY + ]; + + // Optional. Optional. Scanning configuration for the skill. + ScanningConfig scanning_config = 20 [(google.api.field_behavior) = OPTIONAL]; +} + +// Configuration for scanning of the skill. +message ScanningConfig { + // Defines the policy for security scanning. + // + // This enum is not frozen; new values may be added in the future. + enum Policy { + // Default value. Inherits system default (ENABLED_BLOCKING). + POLICY_UNSPECIFIED = 0; + + // Bypasses scanning. + DISABLED = 1; + + // Scans the skill package and blocks download if security or safety issues + // are found. + ENABLED_BLOCKING = 2; + + // Scans the skill package in audit mode without blocking downloads. + ENABLED_NONBLOCKING = 3; + } + + // Optional. The security scanning policy. + Policy policy = 1 [(google.api.field_behavior) = OPTIONAL]; +} + +// Structured metadata attributes extracted from the package's local SKILL.md +// frontmatter. +message Frontmatter { + // Required. The name of the skill. + string name = 5 [(google.api.field_behavior) = REQUIRED]; + + // Required. Functional description. + string description = 2 [(google.api.field_behavior) = REQUIRED]; + + // Optional. License. + string license = 6 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Environmental dependencies or companion services. + string compatibility = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Extensible flattened map mapping custom tags, authors, and + // version parameters. + map metadata = 4 [(google.api.field_behavior) = OPTIONAL]; +} + +// Direct write-only raw archive payload upload. +message ArchiveUploadSource { + // Required. Input only. Write-only raw ZIP/TAR archive payload bytes + // containing the skill package. + bytes archive_content = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.field_behavior) = INPUT_ONLY + ]; +} + +// Represents an immutable, versioned snapshot of a Skill package. +message SkillRevision { + option (google.api.resource) = { + type: "agentregistry.googleapis.com/SkillRevision" + pattern: "projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}" + plural: "skillRevisions" + singular: "skillRevision" + }; + + // Scan result of the skill revision. + message ScanResult { + // Represents the lifecycle state of the vulnerability scan. + enum ScanState { + // Should not be used. + SCAN_STATE_UNSPECIFIED = 0; + + // The underlying scanning system failed to execute the scan. + FAILED = 1; + + // The uploaded artifact format is unsupported by the scanning system. + UNSUPPORTED_FORMAT = 2; + + // The scan has completed successfully. + SUCCEEDED = 3; + + // The scan was disabled. + DISABLED = 4; + + // The scan is running. + RUNNING = 5; + } + + // Output only. The state of the vulnerability check. + ScanState scan_state = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The time when the scan was completed. + google.protobuf.Timestamp scan_time = 2 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The error message if the scan failed. + string error_message = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The finding resource names for the skill revision. + repeated string findings = 4 [ + (google.api.field_behavior) = OUTPUT_ONLY, + (google.api.resource_reference) = { + type: "agentregistry.googleapis.com/Finding" + } + ]; + } + + // System-managed computed state. + enum State { + // Default value. This value is unused. + STATE_UNSPECIFIED = 0; + + // The revision is being created. + CREATING = 1; + + // The revision is active. + ACTIVE = 2; + + // The revision failed to compile or ingest. + FAILED = 3; + + // The revision is being deleted. + DELETING = 4; + } + + // Output only. The storage location pointer. + // In standard listing, the raw zip bytes are completely excluded. + // They are streamed separately via a dedicated GetSkillRevision request with + // `?alt=media`. + // The physical source pointing to the executable payload. + // Exactly one source must be provided during creation; otherwise, the + // server will return an `INVALID_ARGUMENT` error. + // + // Size constraints: + // - Maximum compressed ZIP size: 500 KB + // - Maximum total uncompressed size: 10 MB + // - Maximum individual uncompressed file size: 1 MB + oneof source { + // Optional. Immutable. Cloud Storage object generation URI. + GcsSource gcs_source = 9 [ + (google.api.field_behavior) = IMMUTABLE, + (google.api.field_behavior) = OPTIONAL + ]; + + // Optional. Immutable. Direct write-only raw archive upload source. + ArchiveUploadSource archive_upload_source = 12 [ + (google.api.field_behavior) = IMMUTABLE, + (google.api.field_behavior) = OPTIONAL + ]; + } + + // Identifier. Resource name of the SkillRevision. + // Format: + // `projects/{project}/locations/{location}/skills/{skill}/revisions/{revision}` + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Output only. The system-managed lifecycle state of this revision. + State state = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Cryptographic SHA-256 integrity and deduplication digest of + // the payload zip. + string sha256_hash = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Extracted YAML frontmatter configuration snapshot. + Frontmatter frontmatter = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Revision creation timestamp. + google.protobuf.Timestamp create_time = 6 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Size of the compiled zip payload in bytes (assists client + // download progress). + int64 size_bytes = 11 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Universally unique identifier (UUID4) for the skill revision. + string uid = 14 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OUTPUT_ONLY + ]; + + // Output only. Scan result of the skill revision. + ScanResult scan_result = 15 [(google.api.field_behavior) = OUTPUT_ONLY]; +} + +// Specifications for Cloud Storage objects. +message GcsSource { + // Required. Cloud Storage object URI. + // Format: + // `gs://{bucket_name}/{object_name}` + string uri = 1 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Cloud Storage object generation ID. If not specified, the latest + // generation is used. + int64 generation = 2 [(google.api.field_behavior) = OPTIONAL]; +} + +// Represents a verified Publisher of Skills. +// Prepopulated publishers include `publishers/cloud.google.com` and +// `publishers/workspace.google.com`. +message Publisher { + option (google.api.resource) = { + type: "agentregistry.googleapis.com/Publisher" + pattern: "projects/{project}/locations/{location}/publishers/{publisher}" + plural: "publishers" + singular: "publisher" + }; + + // Curation tier representing the publisher's level of verification. + enum PublisherTier { + // Default value. Unspecified. + PUBLISHER_TIER_UNSPECIFIED = 0; + + // First-party Google-curated and verified global publishers. + FIRST_PARTY = 1; + + // Third-party verified enterprise partner publishers. + THIRD_PARTY = 2; + + // Private publishers within the developer's workspace/project. + PRIVATE = 3; + } + + // Identifier. Resource name of the publisher. + // Format: `projects/{project}/locations/{location}/publishers/{publisher}` + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Required. The verified prefix (e.g. "snowflake-", "google-") associated + // with this publisher. The system uses this prefix to enforce name-squatting + // rules during Skill registration. Must be globally unique across all + // publishers. + string verified_prefix = 2 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Human readable display name of the publisher. + string display_name = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The curation tier of the publisher. + PublisherTier publisher_tier = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. URI pointing to official publisher documentation. + string documentation_uri = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. URI pointing to the support portal or email. + string support_uri = 6 [(google.api.field_behavior) = OPTIONAL]; +} diff --git a/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/skill_encryption_spec.proto b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/skill_encryption_spec.proto new file mode 100644 index 000000000000..0685d1f945f6 --- /dev/null +++ b/java-agentregistry/proto-google-cloud-agentregistry-v1/src/main/proto/google/cloud/agentregistry/v1/skill_encryption_spec.proto @@ -0,0 +1,74 @@ +// Copyright 2026 Google LLC +// +// 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. + +syntax = "proto3"; + +package google.cloud.agentregistry.v1; + +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/protobuf/timestamp.proto"; + +option csharp_namespace = "Google.Cloud.AgentRegistry.V1"; +option go_package = "cloud.google.com/go/agentregistry/apiv1/agentregistrypb;agentregistrypb"; +option java_multiple_files = true; +option java_outer_classname = "SkillEncryptionSpecProto"; +option java_package = "com.google.cloud.agentregistry.v1"; +option php_namespace = "Google\\Cloud\\AgentRegistry\\V1"; +option ruby_package = "Google::Cloud::AgentRegistry::V1"; +option (google.api.resource_definition) = { + type: "cloudkms.googleapis.com/CryptoKey" + pattern: "projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}" +}; + +// Once the SkillEncryptionSpec is configured, new Skill payloads are protected +// using the provided customer-managed encryption key instead of a +// Google-managed encryption key. +// +// SkillEncryptionSpec cannot be set if any Skills have already been created +// in the project and location. +message SkillEncryptionSpec { + option (google.api.resource) = { + type: "agentregistry.googleapis.com/SkillEncryptionSpec" + pattern: "projects/{project}/locations/{location}/skillEncryptionSpec" + plural: "skillEncryptionSpecs" + singular: "skillEncryptionSpec" + }; + + // Identifier. Resource name of the SkillEncryptionSpec. + // Format: `projects/{project}/locations/{location}/skillEncryptionSpec` + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Required. The Cloud KMS CryptoKey resource name used to protect Skill + // payloads in this project and location. + // This field can be set or updated only when no Skills exist in the target + // project and location. Once any Skill exists in the location, updating this + // field is rejected with `FAILED_PRECONDITION`. + // Format: + // `projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey}` + string crypto_key_name = 2 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "cloudkms.googleapis.com/CryptoKey" + } + ]; + + // Output only. Creation timestamp. + google.protobuf.Timestamp create_time = 3 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Most recent update timestamp. + google.protobuf.Timestamp update_time = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; +} diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/AsyncCreateSkill.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/AsyncCreateSkill.java new file mode 100644 index 000000000000..4af445ccae8d --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/AsyncCreateSkill.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_CreateSkill_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.CreateSkillRequest; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.longrunning.Operation; + +public class AsyncCreateSkill { + + public static void main(String[] args) throws Exception { + asyncCreateSkill(); + } + + public static void asyncCreateSkill() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + CreateSkillRequest request = + CreateSkillRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setSkillId("skillId2147320652") + .setSkill(Skill.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + ApiFuture future = agentRegistryClient.createSkillCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_CreateSkill_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/AsyncCreateSkillLRO.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/AsyncCreateSkillLRO.java new file mode 100644 index 000000000000..605b5e96b79e --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/AsyncCreateSkillLRO.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_CreateSkill_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.CreateSkillRequest; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.OperationMetadata; +import com.google.cloud.agentregistry.v1.Skill; + +public class AsyncCreateSkillLRO { + + public static void main(String[] args) throws Exception { + asyncCreateSkillLRO(); + } + + public static void asyncCreateSkillLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + CreateSkillRequest request = + CreateSkillRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setSkillId("skillId2147320652") + .setSkill(Skill.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + OperationFuture future = + agentRegistryClient.createSkillOperationCallable().futureCall(request); + // Do something. + Skill response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_CreateSkill_LRO_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/SyncCreateSkill.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/SyncCreateSkill.java new file mode 100644 index 000000000000..7f9d35116ffe --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/SyncCreateSkill.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_CreateSkill_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.CreateSkillRequest; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Skill; + +public class SyncCreateSkill { + + public static void main(String[] args) throws Exception { + syncCreateSkill(); + } + + public static void syncCreateSkill() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + CreateSkillRequest request = + CreateSkillRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setSkillId("skillId2147320652") + .setSkill(Skill.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + Skill response = agentRegistryClient.createSkillAsync(request).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_CreateSkill_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/SyncCreateSkillLocationnameSkillString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/SyncCreateSkillLocationnameSkillString.java new file mode 100644 index 000000000000..f1da6653d316 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/SyncCreateSkillLocationnameSkillString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_CreateSkill_LocationnameSkillString_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Skill; + +public class SyncCreateSkillLocationnameSkillString { + + public static void main(String[] args) throws Exception { + syncCreateSkillLocationnameSkillString(); + } + + public static void syncCreateSkillLocationnameSkillString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Skill skill = Skill.newBuilder().build(); + String skillId = "skillId2147320652"; + Skill response = agentRegistryClient.createSkillAsync(parent, skill, skillId).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_CreateSkill_LocationnameSkillString_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/SyncCreateSkillStringSkillString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/SyncCreateSkillStringSkillString.java new file mode 100644 index 000000000000..e792fcd4c49b --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskill/SyncCreateSkillStringSkillString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_CreateSkill_StringSkillString_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Skill; + +public class SyncCreateSkillStringSkillString { + + public static void main(String[] args) throws Exception { + syncCreateSkillStringSkillString(); + } + + public static void syncCreateSkillStringSkillString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + Skill skill = Skill.newBuilder().build(); + String skillId = "skillId2147320652"; + Skill response = agentRegistryClient.createSkillAsync(parent, skill, skillId).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_CreateSkill_StringSkillString_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/AsyncCreateSkillRevision.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/AsyncCreateSkillRevision.java new file mode 100644 index 000000000000..c7b5f8692940 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/AsyncCreateSkillRevision.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_CreateSkillRevision_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.cloud.agentregistry.v1.SkillRevision; +import com.google.longrunning.Operation; + +public class AsyncCreateSkillRevision { + + public static void main(String[] args) throws Exception { + asyncCreateSkillRevision(); + } + + public static void asyncCreateSkillRevision() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + CreateSkillRevisionRequest request = + CreateSkillRevisionRequest.newBuilder() + .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setSkillRevision(SkillRevision.newBuilder().build()) + .setSkillRevisionId("skillRevisionId-983110777") + .setRequestId("requestId693933066") + .build(); + ApiFuture future = + agentRegistryClient.createSkillRevisionCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_CreateSkillRevision_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/AsyncCreateSkillRevisionLRO.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/AsyncCreateSkillRevisionLRO.java new file mode 100644 index 000000000000..40d0bf059d2d --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/AsyncCreateSkillRevisionLRO.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_CreateSkillRevision_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest; +import com.google.cloud.agentregistry.v1.OperationMetadata; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.cloud.agentregistry.v1.SkillRevision; + +public class AsyncCreateSkillRevisionLRO { + + public static void main(String[] args) throws Exception { + asyncCreateSkillRevisionLRO(); + } + + public static void asyncCreateSkillRevisionLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + CreateSkillRevisionRequest request = + CreateSkillRevisionRequest.newBuilder() + .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setSkillRevision(SkillRevision.newBuilder().build()) + .setSkillRevisionId("skillRevisionId-983110777") + .setRequestId("requestId693933066") + .build(); + OperationFuture future = + agentRegistryClient.createSkillRevisionOperationCallable().futureCall(request); + // Do something. + SkillRevision response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_CreateSkillRevision_LRO_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/SyncCreateSkillRevision.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/SyncCreateSkillRevision.java new file mode 100644 index 000000000000..38d17548e72e --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/SyncCreateSkillRevision.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_CreateSkillRevision_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.CreateSkillRevisionRequest; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.cloud.agentregistry.v1.SkillRevision; + +public class SyncCreateSkillRevision { + + public static void main(String[] args) throws Exception { + syncCreateSkillRevision(); + } + + public static void syncCreateSkillRevision() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + CreateSkillRevisionRequest request = + CreateSkillRevisionRequest.newBuilder() + .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setSkillRevision(SkillRevision.newBuilder().build()) + .setSkillRevisionId("skillRevisionId-983110777") + .setRequestId("requestId693933066") + .build(); + SkillRevision response = agentRegistryClient.createSkillRevisionAsync(request).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_CreateSkillRevision_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/SyncCreateSkillRevisionSkillnameSkillrevisionString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/SyncCreateSkillRevisionSkillnameSkillrevisionString.java new file mode 100644 index 000000000000..41bcb03cc93a --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/SyncCreateSkillRevisionSkillnameSkillrevisionString.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_CreateSkillRevision_SkillnameSkillrevisionString_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.cloud.agentregistry.v1.SkillRevision; + +public class SyncCreateSkillRevisionSkillnameSkillrevisionString { + + public static void main(String[] args) throws Exception { + syncCreateSkillRevisionSkillnameSkillrevisionString(); + } + + public static void syncCreateSkillRevisionSkillnameSkillrevisionString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + SkillRevision skillRevision = SkillRevision.newBuilder().build(); + String skillRevisionId = "skillRevisionId-983110777"; + SkillRevision response = + agentRegistryClient + .createSkillRevisionAsync(parent, skillRevision, skillRevisionId) + .get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_CreateSkillRevision_SkillnameSkillrevisionString_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/SyncCreateSkillRevisionStringSkillrevisionString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/SyncCreateSkillRevisionStringSkillrevisionString.java new file mode 100644 index 000000000000..db249543ef82 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/createskillrevision/SyncCreateSkillRevisionStringSkillrevisionString.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_CreateSkillRevision_StringSkillrevisionString_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.cloud.agentregistry.v1.SkillRevision; + +public class SyncCreateSkillRevisionStringSkillrevisionString { + + public static void main(String[] args) throws Exception { + syncCreateSkillRevisionStringSkillrevisionString(); + } + + public static void syncCreateSkillRevisionStringSkillrevisionString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString(); + SkillRevision skillRevision = SkillRevision.newBuilder().build(); + String skillRevisionId = "skillRevisionId-983110777"; + SkillRevision response = + agentRegistryClient + .createSkillRevisionAsync(parent, skillRevision, skillRevisionId) + .get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_CreateSkillRevision_StringSkillrevisionString_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/AsyncDeleteSkill.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/AsyncDeleteSkill.java new file mode 100644 index 000000000000..c0afe2665862 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/AsyncDeleteSkill.java @@ -0,0 +1,51 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_DeleteSkill_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.DeleteSkillRequest; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.longrunning.Operation; + +public class AsyncDeleteSkill { + + public static void main(String[] args) throws Exception { + asyncDeleteSkill(); + } + + public static void asyncDeleteSkill() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + DeleteSkillRequest request = + DeleteSkillRequest.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setRequestId("requestId693933066") + .setForce(true) + .build(); + ApiFuture future = agentRegistryClient.deleteSkillCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_DeleteSkill_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/AsyncDeleteSkillLRO.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/AsyncDeleteSkillLRO.java new file mode 100644 index 000000000000..bb2e3d6567c2 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/AsyncDeleteSkillLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_DeleteSkill_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.DeleteSkillRequest; +import com.google.cloud.agentregistry.v1.OperationMetadata; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.protobuf.Empty; + +public class AsyncDeleteSkillLRO { + + public static void main(String[] args) throws Exception { + asyncDeleteSkillLRO(); + } + + public static void asyncDeleteSkillLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + DeleteSkillRequest request = + DeleteSkillRequest.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setRequestId("requestId693933066") + .setForce(true) + .build(); + OperationFuture future = + agentRegistryClient.deleteSkillOperationCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_DeleteSkill_LRO_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/SyncDeleteSkill.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/SyncDeleteSkill.java new file mode 100644 index 000000000000..dbd027403aae --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/SyncDeleteSkill.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_DeleteSkill_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.DeleteSkillRequest; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.protobuf.Empty; + +public class SyncDeleteSkill { + + public static void main(String[] args) throws Exception { + syncDeleteSkill(); + } + + public static void syncDeleteSkill() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + DeleteSkillRequest request = + DeleteSkillRequest.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setRequestId("requestId693933066") + .setForce(true) + .build(); + agentRegistryClient.deleteSkillAsync(request).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_DeleteSkill_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/SyncDeleteSkillSkillname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/SyncDeleteSkillSkillname.java new file mode 100644 index 000000000000..38332a9b8e72 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/SyncDeleteSkillSkillname.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_DeleteSkill_Skillname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.protobuf.Empty; + +public class SyncDeleteSkillSkillname { + + public static void main(String[] args) throws Exception { + syncDeleteSkillSkillname(); + } + + public static void syncDeleteSkillSkillname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + agentRegistryClient.deleteSkillAsync(name).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_DeleteSkill_Skillname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/SyncDeleteSkillString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/SyncDeleteSkillString.java new file mode 100644 index 000000000000..bf224c63c6a5 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskill/SyncDeleteSkillString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_DeleteSkill_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.protobuf.Empty; + +public class SyncDeleteSkillString { + + public static void main(String[] args) throws Exception { + syncDeleteSkillString(); + } + + public static void syncDeleteSkillString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString(); + agentRegistryClient.deleteSkillAsync(name).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_DeleteSkill_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/AsyncDeleteSkillRevision.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/AsyncDeleteSkillRevision.java new file mode 100644 index 000000000000..6c8645d8c85f --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/AsyncDeleteSkillRevision.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_DeleteSkillRevision_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest; +import com.google.cloud.agentregistry.v1.SkillRevisionName; +import com.google.longrunning.Operation; + +public class AsyncDeleteSkillRevision { + + public static void main(String[] args) throws Exception { + asyncDeleteSkillRevision(); + } + + public static void asyncDeleteSkillRevision() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + DeleteSkillRevisionRequest request = + DeleteSkillRevisionRequest.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]") + .toString()) + .setRequestId("requestId693933066") + .build(); + ApiFuture future = + agentRegistryClient.deleteSkillRevisionCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_DeleteSkillRevision_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/AsyncDeleteSkillRevisionLRO.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/AsyncDeleteSkillRevisionLRO.java new file mode 100644 index 000000000000..40edbd192f7c --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/AsyncDeleteSkillRevisionLRO.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_DeleteSkillRevision_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest; +import com.google.cloud.agentregistry.v1.OperationMetadata; +import com.google.cloud.agentregistry.v1.SkillRevisionName; +import com.google.protobuf.Empty; + +public class AsyncDeleteSkillRevisionLRO { + + public static void main(String[] args) throws Exception { + asyncDeleteSkillRevisionLRO(); + } + + public static void asyncDeleteSkillRevisionLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + DeleteSkillRevisionRequest request = + DeleteSkillRevisionRequest.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]") + .toString()) + .setRequestId("requestId693933066") + .build(); + OperationFuture future = + agentRegistryClient.deleteSkillRevisionOperationCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_DeleteSkillRevision_LRO_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/SyncDeleteSkillRevision.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/SyncDeleteSkillRevision.java new file mode 100644 index 000000000000..08cc6f168cfc --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/SyncDeleteSkillRevision.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_DeleteSkillRevision_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.DeleteSkillRevisionRequest; +import com.google.cloud.agentregistry.v1.SkillRevisionName; +import com.google.protobuf.Empty; + +public class SyncDeleteSkillRevision { + + public static void main(String[] args) throws Exception { + syncDeleteSkillRevision(); + } + + public static void syncDeleteSkillRevision() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + DeleteSkillRevisionRequest request = + DeleteSkillRevisionRequest.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]") + .toString()) + .setRequestId("requestId693933066") + .build(); + agentRegistryClient.deleteSkillRevisionAsync(request).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_DeleteSkillRevision_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/SyncDeleteSkillRevisionSkillrevisionname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/SyncDeleteSkillRevisionSkillrevisionname.java new file mode 100644 index 000000000000..e3bd2c8cb5c5 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/SyncDeleteSkillRevisionSkillrevisionname.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_DeleteSkillRevision_Skillrevisionname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillRevisionName; +import com.google.protobuf.Empty; + +public class SyncDeleteSkillRevisionSkillrevisionname { + + public static void main(String[] args) throws Exception { + syncDeleteSkillRevisionSkillrevisionname(); + } + + public static void syncDeleteSkillRevisionSkillrevisionname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + SkillRevisionName name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]"); + agentRegistryClient.deleteSkillRevisionAsync(name).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_DeleteSkillRevision_Skillrevisionname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/SyncDeleteSkillRevisionString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/SyncDeleteSkillRevisionString.java new file mode 100644 index 000000000000..42bb09b30cab --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/deleteskillrevision/SyncDeleteSkillRevisionString.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_DeleteSkillRevision_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillRevisionName; +import com.google.protobuf.Empty; + +public class SyncDeleteSkillRevisionString { + + public static void main(String[] args) throws Exception { + syncDeleteSkillRevisionString(); + } + + public static void syncDeleteSkillRevisionString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString(); + agentRegistryClient.deleteSkillRevisionAsync(name).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_DeleteSkillRevision_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/AsyncGetAgent.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/AsyncGetAgent.java index 88caa0037e99..21ebbf28bc1d 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/AsyncGetAgent.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/AsyncGetAgent.java @@ -38,7 +38,9 @@ public static void asyncGetAgent() throws Exception { try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { GetAgentRequest request = GetAgentRequest.newBuilder() - .setName(AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]").toString()) + .setName( + AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]") + .toString()) .build(); ApiFuture future = agentRegistryClient.getAgentCallable().futureCall(request); // Do something. diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgent.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgent.java index 267631db37e2..030aec92dc27 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgent.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgent.java @@ -37,7 +37,9 @@ public static void syncGetAgent() throws Exception { try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { GetAgentRequest request = GetAgentRequest.newBuilder() - .setName(AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]").toString()) + .setName( + AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]") + .toString()) .build(); Agent response = agentRegistryClient.getAgent(request); } diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgentAgentname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgentAgentname.java index dba3768b48b3..b36427a9db6f 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgentAgentname.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgentAgentname.java @@ -34,7 +34,7 @@ public static void syncGetAgentAgentname() throws Exception { // - It may require specifying regional endpoints when creating the service client as shown in // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - AgentName name = AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]"); + AgentName name = AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]"); Agent response = agentRegistryClient.getAgent(name); } } diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgentString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgentString.java index 902097b3f001..1e70af54ab57 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgentString.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getagent/SyncGetAgentString.java @@ -34,7 +34,8 @@ public static void syncGetAgentString() throws Exception { // - It may require specifying regional endpoints when creating the service client as shown in // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - String name = AgentName.of("[PROJECT]", "[LOCATION]", "[AGENT]").toString(); + String name = + AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]").toString(); Agent response = agentRegistryClient.getAgent(name); } } diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/AsyncGetAiApplication.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/AsyncGetAiApplication.java new file mode 100644 index 000000000000..dc5c2da795d9 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/AsyncGetAiApplication.java @@ -0,0 +1,51 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplication_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplication; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.GetAiApplicationRequest; + +public class AsyncGetAiApplication { + + public static void main(String[] args) throws Exception { + asyncGetAiApplication(); + } + + public static void asyncGetAiApplication() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetAiApplicationRequest request = + GetAiApplicationRequest.newBuilder() + .setName( + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .build(); + ApiFuture future = + agentRegistryClient.getAiApplicationCallable().futureCall(request); + // Do something. + AiApplication response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplication_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/SyncGetAiApplication.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/SyncGetAiApplication.java new file mode 100644 index 000000000000..74ff38a80249 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/SyncGetAiApplication.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplication_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplication; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.GetAiApplicationRequest; + +public class SyncGetAiApplication { + + public static void main(String[] args) throws Exception { + syncGetAiApplication(); + } + + public static void syncGetAiApplication() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetAiApplicationRequest request = + GetAiApplicationRequest.newBuilder() + .setName( + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .build(); + AiApplication response = agentRegistryClient.getAiApplication(request); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplication_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/SyncGetAiApplicationAiapplicationname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/SyncGetAiApplicationAiapplicationname.java new file mode 100644 index 000000000000..fa30114b7bbc --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/SyncGetAiApplicationAiapplicationname.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplication_Aiapplicationname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplication; +import com.google.cloud.agentregistry.v1.AiApplicationName; + +public class SyncGetAiApplicationAiapplicationname { + + public static void main(String[] args) throws Exception { + syncGetAiApplicationAiapplicationname(); + } + + public static void syncGetAiApplicationAiapplicationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + AiApplicationName name = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + AiApplication response = agentRegistryClient.getAiApplication(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplication_Aiapplicationname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/SyncGetAiApplicationString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/SyncGetAiApplicationString.java new file mode 100644 index 000000000000..079a80577b73 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplication/SyncGetAiApplicationString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplication_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplication; +import com.google.cloud.agentregistry.v1.AiApplicationName; + +public class SyncGetAiApplicationString { + + public static void main(String[] args) throws Exception { + syncGetAiApplicationString(); + } + + public static void syncGetAiApplicationString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String name = AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString(); + AiApplication response = agentRegistryClient.getAiApplication(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplication_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/AsyncGetAiApplicationAgent.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/AsyncGetAiApplicationAgent.java new file mode 100644 index 000000000000..2e73ef112290 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/AsyncGetAiApplicationAgent.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationAgent_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AgentName; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest; + +public class AsyncGetAiApplicationAgent { + + public static void main(String[] args) throws Exception { + asyncGetAiApplicationAgent(); + } + + public static void asyncGetAiApplicationAgent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetAiApplicationAgentRequest request = + GetAiApplicationAgentRequest.newBuilder() + .setName( + AgentName.ofProjectLocationAiApplicationAgentName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]") + .toString()) + .build(); + ApiFuture future = + agentRegistryClient.getAiApplicationAgentCallable().futureCall(request); + // Do something. + Agent response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationAgent_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/SyncGetAiApplicationAgent.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/SyncGetAiApplicationAgent.java new file mode 100644 index 000000000000..1bde3cf92fda --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/SyncGetAiApplicationAgent.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationAgent_sync] +import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AgentName; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetAiApplicationAgentRequest; + +public class SyncGetAiApplicationAgent { + + public static void main(String[] args) throws Exception { + syncGetAiApplicationAgent(); + } + + public static void syncGetAiApplicationAgent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetAiApplicationAgentRequest request = + GetAiApplicationAgentRequest.newBuilder() + .setName( + AgentName.ofProjectLocationAiApplicationAgentName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]") + .toString()) + .build(); + Agent response = agentRegistryClient.getAiApplicationAgent(request); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationAgent_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/SyncGetAiApplicationAgentAgentname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/SyncGetAiApplicationAgentAgentname.java new file mode 100644 index 000000000000..0b633d5a57e3 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/SyncGetAiApplicationAgentAgentname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationAgent_Agentname_sync] +import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AgentName; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; + +public class SyncGetAiApplicationAgentAgentname { + + public static void main(String[] args) throws Exception { + syncGetAiApplicationAgentAgentname(); + } + + public static void syncGetAiApplicationAgentAgentname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + AgentName name = + AgentName.ofProjectLocationAiApplicationAgentName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[AGENT]"); + Agent response = agentRegistryClient.getAiApplicationAgent(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationAgent_Agentname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/SyncGetAiApplicationAgentString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/SyncGetAiApplicationAgentString.java new file mode 100644 index 000000000000..fa9910600d08 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationagent/SyncGetAiApplicationAgentString.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationAgent_String_sync] +import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AgentName; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; + +public class SyncGetAiApplicationAgentString { + + public static void main(String[] args) throws Exception { + syncGetAiApplicationAgentString(); + } + + public static void syncGetAiApplicationAgentString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String name = + AgentName.ofProjectLocationAgentName("[PROJECT]", "[LOCATION]", "[AGENT]").toString(); + Agent response = agentRegistryClient.getAiApplicationAgent(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationAgent_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/AsyncGetAiApplicationEndpoint.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/AsyncGetAiApplicationEndpoint.java new file mode 100644 index 000000000000..4be0335f408a --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/AsyncGetAiApplicationEndpoint.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationEndpoint_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Endpoint; +import com.google.cloud.agentregistry.v1.EndpointName; +import com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest; + +public class AsyncGetAiApplicationEndpoint { + + public static void main(String[] args) throws Exception { + asyncGetAiApplicationEndpoint(); + } + + public static void asyncGetAiApplicationEndpoint() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetAiApplicationEndpointRequest request = + GetAiApplicationEndpointRequest.newBuilder() + .setName( + EndpointName.ofProjectLocationAiApplicationEndpointName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]") + .toString()) + .build(); + ApiFuture future = + agentRegistryClient.getAiApplicationEndpointCallable().futureCall(request); + // Do something. + Endpoint response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationEndpoint_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/SyncGetAiApplicationEndpoint.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/SyncGetAiApplicationEndpoint.java new file mode 100644 index 000000000000..95f810eabf74 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/SyncGetAiApplicationEndpoint.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationEndpoint_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Endpoint; +import com.google.cloud.agentregistry.v1.EndpointName; +import com.google.cloud.agentregistry.v1.GetAiApplicationEndpointRequest; + +public class SyncGetAiApplicationEndpoint { + + public static void main(String[] args) throws Exception { + syncGetAiApplicationEndpoint(); + } + + public static void syncGetAiApplicationEndpoint() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetAiApplicationEndpointRequest request = + GetAiApplicationEndpointRequest.newBuilder() + .setName( + EndpointName.ofProjectLocationAiApplicationEndpointName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]") + .toString()) + .build(); + Endpoint response = agentRegistryClient.getAiApplicationEndpoint(request); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationEndpoint_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/SyncGetAiApplicationEndpointEndpointname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/SyncGetAiApplicationEndpointEndpointname.java new file mode 100644 index 000000000000..1bac4c8db347 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/SyncGetAiApplicationEndpointEndpointname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationEndpoint_Endpointname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Endpoint; +import com.google.cloud.agentregistry.v1.EndpointName; + +public class SyncGetAiApplicationEndpointEndpointname { + + public static void main(String[] args) throws Exception { + syncGetAiApplicationEndpointEndpointname(); + } + + public static void syncGetAiApplicationEndpointEndpointname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + EndpointName name = + EndpointName.ofProjectLocationAiApplicationEndpointName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[ENDPOINT]"); + Endpoint response = agentRegistryClient.getAiApplicationEndpoint(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationEndpoint_Endpointname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/SyncGetAiApplicationEndpointString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/SyncGetAiApplicationEndpointString.java new file mode 100644 index 000000000000..a212df83ad7e --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationendpoint/SyncGetAiApplicationEndpointString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationEndpoint_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Endpoint; +import com.google.cloud.agentregistry.v1.EndpointName; + +public class SyncGetAiApplicationEndpointString { + + public static void main(String[] args) throws Exception { + syncGetAiApplicationEndpointString(); + } + + public static void syncGetAiApplicationEndpointString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String name = + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString(); + Endpoint response = agentRegistryClient.getAiApplicationEndpoint(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationEndpoint_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/AsyncGetAiApplicationMcpServer.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/AsyncGetAiApplicationMcpServer.java new file mode 100644 index 000000000000..7fc96b97384c --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/AsyncGetAiApplicationMcpServer.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationMcpServer_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest; +import com.google.cloud.agentregistry.v1.McpServer; +import com.google.cloud.agentregistry.v1.McpServerName; + +public class AsyncGetAiApplicationMcpServer { + + public static void main(String[] args) throws Exception { + asyncGetAiApplicationMcpServer(); + } + + public static void asyncGetAiApplicationMcpServer() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetAiApplicationMcpServerRequest request = + GetAiApplicationMcpServerRequest.newBuilder() + .setName( + McpServerName.ofProjectLocationAiApplicationMcpServerName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]") + .toString()) + .build(); + ApiFuture future = + agentRegistryClient.getAiApplicationMcpServerCallable().futureCall(request); + // Do something. + McpServer response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationMcpServer_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/SyncGetAiApplicationMcpServer.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/SyncGetAiApplicationMcpServer.java new file mode 100644 index 000000000000..b201e0dbe52d --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/SyncGetAiApplicationMcpServer.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationMcpServer_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetAiApplicationMcpServerRequest; +import com.google.cloud.agentregistry.v1.McpServer; +import com.google.cloud.agentregistry.v1.McpServerName; + +public class SyncGetAiApplicationMcpServer { + + public static void main(String[] args) throws Exception { + syncGetAiApplicationMcpServer(); + } + + public static void syncGetAiApplicationMcpServer() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetAiApplicationMcpServerRequest request = + GetAiApplicationMcpServerRequest.newBuilder() + .setName( + McpServerName.ofProjectLocationAiApplicationMcpServerName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]") + .toString()) + .build(); + McpServer response = agentRegistryClient.getAiApplicationMcpServer(request); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationMcpServer_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/SyncGetAiApplicationMcpServerMcpservername.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/SyncGetAiApplicationMcpServerMcpservername.java new file mode 100644 index 000000000000..9f14ccb99adb --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/SyncGetAiApplicationMcpServerMcpservername.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationMcpServer_Mcpservername_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.McpServer; +import com.google.cloud.agentregistry.v1.McpServerName; + +public class SyncGetAiApplicationMcpServerMcpservername { + + public static void main(String[] args) throws Exception { + syncGetAiApplicationMcpServerMcpservername(); + } + + public static void syncGetAiApplicationMcpServerMcpservername() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + McpServerName name = + McpServerName.ofProjectLocationAiApplicationMcpServerName( + "[PROJECT]", "[LOCATION]", "[AI_APPLICATION]", "[MCP_SERVER]"); + McpServer response = agentRegistryClient.getAiApplicationMcpServer(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationMcpServer_Mcpservername_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/SyncGetAiApplicationMcpServerString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/SyncGetAiApplicationMcpServerString.java new file mode 100644 index 000000000000..f28bf108100d --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getaiapplicationmcpserver/SyncGetAiApplicationMcpServerString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetAiApplicationMcpServer_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.McpServer; +import com.google.cloud.agentregistry.v1.McpServerName; + +public class SyncGetAiApplicationMcpServerString { + + public static void main(String[] args) throws Exception { + syncGetAiApplicationMcpServerString(); + } + + public static void syncGetAiApplicationMcpServerString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String name = + McpServerName.ofProjectLocationMcpServerName("[PROJECT]", "[LOCATION]", "[MCP_SERVER]") + .toString(); + McpServer response = agentRegistryClient.getAiApplicationMcpServer(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetAiApplicationMcpServer_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/AsyncGetEndpoint.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/AsyncGetEndpoint.java index b1cf8ea3e343..9d956f8548eb 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/AsyncGetEndpoint.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/AsyncGetEndpoint.java @@ -38,7 +38,10 @@ public static void asyncGetEndpoint() throws Exception { try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { GetEndpointRequest request = GetEndpointRequest.newBuilder() - .setName(EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]").toString()) + .setName( + EndpointName.ofProjectLocationEndpointName( + "[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) .build(); ApiFuture future = agentRegistryClient.getEndpointCallable().futureCall(request); // Do something. diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpoint.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpoint.java index 79d634d3bb16..a7879df8ff25 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpoint.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpoint.java @@ -37,7 +37,10 @@ public static void syncGetEndpoint() throws Exception { try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { GetEndpointRequest request = GetEndpointRequest.newBuilder() - .setName(EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]").toString()) + .setName( + EndpointName.ofProjectLocationEndpointName( + "[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) .build(); Endpoint response = agentRegistryClient.getEndpoint(request); } diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpointEndpointname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpointEndpointname.java index f4f4cbc4f314..1ab2b1254b9e 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpointEndpointname.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpointEndpointname.java @@ -34,7 +34,8 @@ public static void syncGetEndpointEndpointname() throws Exception { // - It may require specifying regional endpoints when creating the service client as shown in // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - EndpointName name = EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]"); + EndpointName name = + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]"); Endpoint response = agentRegistryClient.getEndpoint(name); } } diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpointString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpointString.java index a777c22d70a4..9570c4be105b 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpointString.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getendpoint/SyncGetEndpointString.java @@ -34,7 +34,9 @@ public static void syncGetEndpointString() throws Exception { // - It may require specifying regional endpoints when creating the service client as shown in // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - String name = EndpointName.of("[PROJECT]", "[LOCATION]", "[ENDPOINT]").toString(); + String name = + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString(); Endpoint response = agentRegistryClient.getEndpoint(name); } } diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/AsyncGetFinding.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/AsyncGetFinding.java new file mode 100644 index 000000000000..e5ad9e4695d4 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/AsyncGetFinding.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetFinding_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Finding; +import com.google.cloud.agentregistry.v1.FindingName; +import com.google.cloud.agentregistry.v1.GetFindingRequest; + +public class AsyncGetFinding { + + public static void main(String[] args) throws Exception { + asyncGetFinding(); + } + + public static void asyncGetFinding() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetFindingRequest request = + GetFindingRequest.newBuilder() + .setName(FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]").toString()) + .build(); + ApiFuture future = agentRegistryClient.getFindingCallable().futureCall(request); + // Do something. + Finding response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetFinding_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/SyncGetFinding.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/SyncGetFinding.java new file mode 100644 index 000000000000..98ade82f2b99 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/SyncGetFinding.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetFinding_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Finding; +import com.google.cloud.agentregistry.v1.FindingName; +import com.google.cloud.agentregistry.v1.GetFindingRequest; + +public class SyncGetFinding { + + public static void main(String[] args) throws Exception { + syncGetFinding(); + } + + public static void syncGetFinding() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetFindingRequest request = + GetFindingRequest.newBuilder() + .setName(FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]").toString()) + .build(); + Finding response = agentRegistryClient.getFinding(request); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetFinding_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/SyncGetFindingFindingname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/SyncGetFindingFindingname.java new file mode 100644 index 000000000000..9902a9b28e0a --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/SyncGetFindingFindingname.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetFinding_Findingname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Finding; +import com.google.cloud.agentregistry.v1.FindingName; + +public class SyncGetFindingFindingname { + + public static void main(String[] args) throws Exception { + syncGetFindingFindingname(); + } + + public static void syncGetFindingFindingname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + FindingName name = FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]"); + Finding response = agentRegistryClient.getFinding(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetFinding_Findingname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/SyncGetFindingString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/SyncGetFindingString.java new file mode 100644 index 000000000000..9ba1a54e43e7 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getfinding/SyncGetFindingString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetFinding_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Finding; +import com.google.cloud.agentregistry.v1.FindingName; + +public class SyncGetFindingString { + + public static void main(String[] args) throws Exception { + syncGetFindingString(); + } + + public static void syncGetFindingString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String name = FindingName.of("[PROJECT]", "[LOCATION]", "[FINDING]").toString(); + Finding response = agentRegistryClient.getFinding(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetFinding_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/AsyncGetMcpServer.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/AsyncGetMcpServer.java index b5ab91038c25..06012e0bd8ed 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/AsyncGetMcpServer.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/AsyncGetMcpServer.java @@ -38,7 +38,10 @@ public static void asyncGetMcpServer() throws Exception { try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { GetMcpServerRequest request = GetMcpServerRequest.newBuilder() - .setName(McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]").toString()) + .setName( + McpServerName.ofProjectLocationMcpServerName( + "[PROJECT]", "[LOCATION]", "[MCP_SERVER]") + .toString()) .build(); ApiFuture future = agentRegistryClient.getMcpServerCallable().futureCall(request); // Do something. diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServer.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServer.java index d897c88ec4a1..90f15dbd19d0 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServer.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServer.java @@ -37,7 +37,10 @@ public static void syncGetMcpServer() throws Exception { try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { GetMcpServerRequest request = GetMcpServerRequest.newBuilder() - .setName(McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]").toString()) + .setName( + McpServerName.ofProjectLocationMcpServerName( + "[PROJECT]", "[LOCATION]", "[MCP_SERVER]") + .toString()) .build(); McpServer response = agentRegistryClient.getMcpServer(request); } diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServerMcpservername.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServerMcpservername.java index e46db4b0edcf..d0181ecf359b 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServerMcpservername.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServerMcpservername.java @@ -34,7 +34,8 @@ public static void syncGetMcpServerMcpservername() throws Exception { // - It may require specifying regional endpoints when creating the service client as shown in // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - McpServerName name = McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]"); + McpServerName name = + McpServerName.ofProjectLocationMcpServerName("[PROJECT]", "[LOCATION]", "[MCP_SERVER]"); McpServer response = agentRegistryClient.getMcpServer(name); } } diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServerString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServerString.java index 6d127a111720..8f2411e2886e 100644 --- a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServerString.java +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getmcpserver/SyncGetMcpServerString.java @@ -34,7 +34,9 @@ public static void syncGetMcpServerString() throws Exception { // - It may require specifying regional endpoints when creating the service client as shown in // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { - String name = McpServerName.of("[PROJECT]", "[LOCATION]", "[MCP_SERVER]").toString(); + String name = + McpServerName.ofProjectLocationMcpServerName("[PROJECT]", "[LOCATION]", "[MCP_SERVER]") + .toString(); McpServer response = agentRegistryClient.getMcpServer(name); } } diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/AsyncGetPublisher.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/AsyncGetPublisher.java new file mode 100644 index 000000000000..91f5d7b86668 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/AsyncGetPublisher.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetPublisher_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetPublisherRequest; +import com.google.cloud.agentregistry.v1.Publisher; +import com.google.cloud.agentregistry.v1.PublisherName; + +public class AsyncGetPublisher { + + public static void main(String[] args) throws Exception { + asyncGetPublisher(); + } + + public static void asyncGetPublisher() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetPublisherRequest request = + GetPublisherRequest.newBuilder() + .setName(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .build(); + ApiFuture future = agentRegistryClient.getPublisherCallable().futureCall(request); + // Do something. + Publisher response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetPublisher_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/SyncGetPublisher.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/SyncGetPublisher.java new file mode 100644 index 000000000000..e674faaa0d98 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/SyncGetPublisher.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetPublisher_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetPublisherRequest; +import com.google.cloud.agentregistry.v1.Publisher; +import com.google.cloud.agentregistry.v1.PublisherName; + +public class SyncGetPublisher { + + public static void main(String[] args) throws Exception { + syncGetPublisher(); + } + + public static void syncGetPublisher() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetPublisherRequest request = + GetPublisherRequest.newBuilder() + .setName(PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString()) + .build(); + Publisher response = agentRegistryClient.getPublisher(request); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetPublisher_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/SyncGetPublisherPublishername.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/SyncGetPublisherPublishername.java new file mode 100644 index 000000000000..f1900a2790aa --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/SyncGetPublisherPublishername.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetPublisher_Publishername_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Publisher; +import com.google.cloud.agentregistry.v1.PublisherName; + +public class SyncGetPublisherPublishername { + + public static void main(String[] args) throws Exception { + syncGetPublisherPublishername(); + } + + public static void syncGetPublisherPublishername() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + PublisherName name = PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]"); + Publisher response = agentRegistryClient.getPublisher(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetPublisher_Publishername_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/SyncGetPublisherString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/SyncGetPublisherString.java new file mode 100644 index 000000000000..6a3dfb21c11d --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getpublisher/SyncGetPublisherString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetPublisher_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Publisher; +import com.google.cloud.agentregistry.v1.PublisherName; + +public class SyncGetPublisherString { + + public static void main(String[] args) throws Exception { + syncGetPublisherString(); + } + + public static void syncGetPublisherString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String name = PublisherName.of("[PROJECT]", "[LOCATION]", "[PUBLISHER]").toString(); + Publisher response = agentRegistryClient.getPublisher(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetPublisher_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/AsyncGetSkill.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/AsyncGetSkill.java new file mode 100644 index 000000000000..0cf948471d37 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/AsyncGetSkill.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkill_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetSkillRequest; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.cloud.agentregistry.v1.SkillName; + +public class AsyncGetSkill { + + public static void main(String[] args) throws Exception { + asyncGetSkill(); + } + + public static void asyncGetSkill() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetSkillRequest request = + GetSkillRequest.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .build(); + ApiFuture future = agentRegistryClient.getSkillCallable().futureCall(request); + // Do something. + Skill response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkill_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/SyncGetSkill.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/SyncGetSkill.java new file mode 100644 index 000000000000..479562bacee1 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/SyncGetSkill.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkill_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetSkillRequest; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.cloud.agentregistry.v1.SkillName; + +public class SyncGetSkill { + + public static void main(String[] args) throws Exception { + syncGetSkill(); + } + + public static void syncGetSkill() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetSkillRequest request = + GetSkillRequest.newBuilder() + .setName(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .build(); + Skill response = agentRegistryClient.getSkill(request); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkill_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/SyncGetSkillSkillname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/SyncGetSkillSkillname.java new file mode 100644 index 000000000000..f76655622860 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/SyncGetSkillSkillname.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkill_Skillname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.cloud.agentregistry.v1.SkillName; + +public class SyncGetSkillSkillname { + + public static void main(String[] args) throws Exception { + syncGetSkillSkillname(); + } + + public static void syncGetSkillSkillname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + SkillName name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + Skill response = agentRegistryClient.getSkill(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkill_Skillname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/SyncGetSkillString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/SyncGetSkillString.java new file mode 100644 index 000000000000..2ebe05b7a54b --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskill/SyncGetSkillString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkill_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.cloud.agentregistry.v1.SkillName; + +public class SyncGetSkillString { + + public static void main(String[] args) throws Exception { + syncGetSkillString(); + } + + public static void syncGetSkillString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String name = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString(); + Skill response = agentRegistryClient.getSkill(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkill_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/AsyncGetSkillEncryptionSpec.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/AsyncGetSkillEncryptionSpec.java new file mode 100644 index 000000000000..3e50180ba9fb --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/AsyncGetSkillEncryptionSpec.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkillEncryptionSpec_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpecName; + +public class AsyncGetSkillEncryptionSpec { + + public static void main(String[] args) throws Exception { + asyncGetSkillEncryptionSpec(); + } + + public static void asyncGetSkillEncryptionSpec() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetSkillEncryptionSpecRequest request = + GetSkillEncryptionSpecRequest.newBuilder() + .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) + .build(); + ApiFuture future = + agentRegistryClient.getSkillEncryptionSpecCallable().futureCall(request); + // Do something. + SkillEncryptionSpec response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkillEncryptionSpec_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/SyncGetSkillEncryptionSpec.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/SyncGetSkillEncryptionSpec.java new file mode 100644 index 000000000000..62cd7db0c1ae --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/SyncGetSkillEncryptionSpec.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkillEncryptionSpec_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetSkillEncryptionSpecRequest; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpecName; + +public class SyncGetSkillEncryptionSpec { + + public static void main(String[] args) throws Exception { + syncGetSkillEncryptionSpec(); + } + + public static void syncGetSkillEncryptionSpec() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetSkillEncryptionSpecRequest request = + GetSkillEncryptionSpecRequest.newBuilder() + .setName(SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString()) + .build(); + SkillEncryptionSpec response = agentRegistryClient.getSkillEncryptionSpec(request); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkillEncryptionSpec_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/SyncGetSkillEncryptionSpecSkillencryptionspecname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/SyncGetSkillEncryptionSpecSkillencryptionspecname.java new file mode 100644 index 000000000000..3fc4372df4f9 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/SyncGetSkillEncryptionSpecSkillencryptionspecname.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkillEncryptionSpec_Skillencryptionspecname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpecName; + +public class SyncGetSkillEncryptionSpecSkillencryptionspecname { + + public static void main(String[] args) throws Exception { + syncGetSkillEncryptionSpecSkillencryptionspecname(); + } + + public static void syncGetSkillEncryptionSpecSkillencryptionspecname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + SkillEncryptionSpecName name = SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]"); + SkillEncryptionSpec response = agentRegistryClient.getSkillEncryptionSpec(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkillEncryptionSpec_Skillencryptionspecname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/SyncGetSkillEncryptionSpecString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/SyncGetSkillEncryptionSpecString.java new file mode 100644 index 000000000000..76699fde88a2 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillencryptionspec/SyncGetSkillEncryptionSpecString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkillEncryptionSpec_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpecName; + +public class SyncGetSkillEncryptionSpecString { + + public static void main(String[] args) throws Exception { + syncGetSkillEncryptionSpecString(); + } + + public static void syncGetSkillEncryptionSpecString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String name = SkillEncryptionSpecName.of("[PROJECT]", "[LOCATION]").toString(); + SkillEncryptionSpec response = agentRegistryClient.getSkillEncryptionSpec(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkillEncryptionSpec_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/AsyncGetSkillRevision.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/AsyncGetSkillRevision.java new file mode 100644 index 000000000000..968475947cf3 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/AsyncGetSkillRevision.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkillRevision_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetSkillRevisionRequest; +import com.google.cloud.agentregistry.v1.SkillRevision; +import com.google.cloud.agentregistry.v1.SkillRevisionName; + +public class AsyncGetSkillRevision { + + public static void main(String[] args) throws Exception { + asyncGetSkillRevision(); + } + + public static void asyncGetSkillRevision() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetSkillRevisionRequest request = + GetSkillRevisionRequest.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]") + .toString()) + .build(); + ApiFuture future = + agentRegistryClient.getSkillRevisionCallable().futureCall(request); + // Do something. + SkillRevision response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkillRevision_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/SyncGetSkillRevision.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/SyncGetSkillRevision.java new file mode 100644 index 000000000000..d6b5d17cba9a --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/SyncGetSkillRevision.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkillRevision_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.GetSkillRevisionRequest; +import com.google.cloud.agentregistry.v1.SkillRevision; +import com.google.cloud.agentregistry.v1.SkillRevisionName; + +public class SyncGetSkillRevision { + + public static void main(String[] args) throws Exception { + syncGetSkillRevision(); + } + + public static void syncGetSkillRevision() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + GetSkillRevisionRequest request = + GetSkillRevisionRequest.newBuilder() + .setName( + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]") + .toString()) + .build(); + SkillRevision response = agentRegistryClient.getSkillRevision(request); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkillRevision_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/SyncGetSkillRevisionSkillrevisionname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/SyncGetSkillRevisionSkillrevisionname.java new file mode 100644 index 000000000000..436b89d9f2fb --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/SyncGetSkillRevisionSkillrevisionname.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkillRevision_Skillrevisionname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillRevision; +import com.google.cloud.agentregistry.v1.SkillRevisionName; + +public class SyncGetSkillRevisionSkillrevisionname { + + public static void main(String[] args) throws Exception { + syncGetSkillRevisionSkillrevisionname(); + } + + public static void syncGetSkillRevisionSkillrevisionname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + SkillRevisionName name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]"); + SkillRevision response = agentRegistryClient.getSkillRevision(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkillRevision_Skillrevisionname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/SyncGetSkillRevisionString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/SyncGetSkillRevisionString.java new file mode 100644 index 000000000000..0cf979bd5a40 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/getskillrevision/SyncGetSkillRevisionString.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_GetSkillRevision_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillRevision; +import com.google.cloud.agentregistry.v1.SkillRevisionName; + +public class SyncGetSkillRevisionString { + + public static void main(String[] args) throws Exception { + syncGetSkillRevisionString(); + } + + public static void syncGetSkillRevisionString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String name = + SkillRevisionName.of("[PROJECT]", "[LOCATION]", "[SKILL]", "[REVISION]").toString(); + SkillRevision response = agentRegistryClient.getSkillRevision(name); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_GetSkillRevision_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/AsyncListAiApplicationAgents.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/AsyncListAiApplicationAgents.java new file mode 100644 index 000000000000..70e3f2e52284 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/AsyncListAiApplicationAgents.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationAgents_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest; + +public class AsyncListAiApplicationAgents { + + public static void main(String[] args) throws Exception { + asyncListAiApplicationAgents(); + } + + public static void asyncListAiApplicationAgents() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationAgentsRequest request = + ListAiApplicationAgentsRequest.newBuilder() + .setParent( + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + agentRegistryClient.listAiApplicationAgentsPagedCallable().futureCall(request); + // Do something. + for (Agent element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationAgents_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/AsyncListAiApplicationAgentsPaged.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/AsyncListAiApplicationAgentsPaged.java new file mode 100644 index 000000000000..3da8b5c3d3e7 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/AsyncListAiApplicationAgentsPaged.java @@ -0,0 +1,63 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationAgents_Paged_async] +import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsResponse; +import com.google.common.base.Strings; + +public class AsyncListAiApplicationAgentsPaged { + + public static void main(String[] args) throws Exception { + asyncListAiApplicationAgentsPaged(); + } + + public static void asyncListAiApplicationAgentsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationAgentsRequest request = + ListAiApplicationAgentsRequest.newBuilder() + .setParent( + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListAiApplicationAgentsResponse response = + agentRegistryClient.listAiApplicationAgentsCallable().call(request); + for (Agent element : response.getAgentsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationAgents_Paged_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/SyncListAiApplicationAgents.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/SyncListAiApplicationAgents.java new file mode 100644 index 000000000000..8658858f35d5 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/SyncListAiApplicationAgents.java @@ -0,0 +1,51 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationAgents_sync] +import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.ListAiApplicationAgentsRequest; + +public class SyncListAiApplicationAgents { + + public static void main(String[] args) throws Exception { + syncListAiApplicationAgents(); + } + + public static void syncListAiApplicationAgents() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationAgentsRequest request = + ListAiApplicationAgentsRequest.newBuilder() + .setParent( + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (Agent element : agentRegistryClient.listAiApplicationAgents(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationAgents_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/SyncListAiApplicationAgentsAiapplicationname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/SyncListAiApplicationAgentsAiapplicationname.java new file mode 100644 index 000000000000..c0a708ea09cc --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/SyncListAiApplicationAgentsAiapplicationname.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationAgents_Aiapplicationname_sync] +import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; + +public class SyncListAiApplicationAgentsAiapplicationname { + + public static void main(String[] args) throws Exception { + syncListAiApplicationAgentsAiapplicationname(); + } + + public static void syncListAiApplicationAgentsAiapplicationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + AiApplicationName parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + for (Agent element : agentRegistryClient.listAiApplicationAgents(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationAgents_Aiapplicationname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/SyncListAiApplicationAgentsString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/SyncListAiApplicationAgentsString.java new file mode 100644 index 000000000000..51c61ff30d48 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationagents/SyncListAiApplicationAgentsString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationAgents_String_sync] +import com.google.cloud.agentregistry.v1.Agent; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; + +public class SyncListAiApplicationAgentsString { + + public static void main(String[] args) throws Exception { + syncListAiApplicationAgentsString(); + } + + public static void syncListAiApplicationAgentsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString(); + for (Agent element : agentRegistryClient.listAiApplicationAgents(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationAgents_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/AsyncListAiApplicationEndpoints.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/AsyncListAiApplicationEndpoints.java new file mode 100644 index 000000000000..27f4ca43fc02 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/AsyncListAiApplicationEndpoints.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationEndpoints_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.Endpoint; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest; + +public class AsyncListAiApplicationEndpoints { + + public static void main(String[] args) throws Exception { + asyncListAiApplicationEndpoints(); + } + + public static void asyncListAiApplicationEndpoints() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationEndpointsRequest request = + ListAiApplicationEndpointsRequest.newBuilder() + .setParent( + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + agentRegistryClient.listAiApplicationEndpointsPagedCallable().futureCall(request); + // Do something. + for (Endpoint element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationEndpoints_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/AsyncListAiApplicationEndpointsPaged.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/AsyncListAiApplicationEndpointsPaged.java new file mode 100644 index 000000000000..ed044b6fbf78 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/AsyncListAiApplicationEndpointsPaged.java @@ -0,0 +1,63 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationEndpoints_Paged_async] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.Endpoint; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsResponse; +import com.google.common.base.Strings; + +public class AsyncListAiApplicationEndpointsPaged { + + public static void main(String[] args) throws Exception { + asyncListAiApplicationEndpointsPaged(); + } + + public static void asyncListAiApplicationEndpointsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationEndpointsRequest request = + ListAiApplicationEndpointsRequest.newBuilder() + .setParent( + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListAiApplicationEndpointsResponse response = + agentRegistryClient.listAiApplicationEndpointsCallable().call(request); + for (Endpoint element : response.getEndpointsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationEndpoints_Paged_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/SyncListAiApplicationEndpoints.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/SyncListAiApplicationEndpoints.java new file mode 100644 index 000000000000..28bcccb9f2b7 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/SyncListAiApplicationEndpoints.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationEndpoints_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.Endpoint; +import com.google.cloud.agentregistry.v1.ListAiApplicationEndpointsRequest; + +public class SyncListAiApplicationEndpoints { + + public static void main(String[] args) throws Exception { + syncListAiApplicationEndpoints(); + } + + public static void syncListAiApplicationEndpoints() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationEndpointsRequest request = + ListAiApplicationEndpointsRequest.newBuilder() + .setParent( + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (Endpoint element : + agentRegistryClient.listAiApplicationEndpoints(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationEndpoints_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/SyncListAiApplicationEndpointsAiapplicationname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/SyncListAiApplicationEndpointsAiapplicationname.java new file mode 100644 index 000000000000..ea23899d9ffb --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/SyncListAiApplicationEndpointsAiapplicationname.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationEndpoints_Aiapplicationname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.Endpoint; + +public class SyncListAiApplicationEndpointsAiapplicationname { + + public static void main(String[] args) throws Exception { + syncListAiApplicationEndpointsAiapplicationname(); + } + + public static void syncListAiApplicationEndpointsAiapplicationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + AiApplicationName parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + for (Endpoint element : agentRegistryClient.listAiApplicationEndpoints(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationEndpoints_Aiapplicationname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/SyncListAiApplicationEndpointsString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/SyncListAiApplicationEndpointsString.java new file mode 100644 index 000000000000..287928cb348b --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationendpoints/SyncListAiApplicationEndpointsString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationEndpoints_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.Endpoint; + +public class SyncListAiApplicationEndpointsString { + + public static void main(String[] args) throws Exception { + syncListAiApplicationEndpointsString(); + } + + public static void syncListAiApplicationEndpointsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString(); + for (Endpoint element : agentRegistryClient.listAiApplicationEndpoints(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationEndpoints_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/AsyncListAiApplicationMcpServers.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/AsyncListAiApplicationMcpServers.java new file mode 100644 index 000000000000..d1b4f7135753 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/AsyncListAiApplicationMcpServers.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationMcpServers_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest; +import com.google.cloud.agentregistry.v1.McpServer; + +public class AsyncListAiApplicationMcpServers { + + public static void main(String[] args) throws Exception { + asyncListAiApplicationMcpServers(); + } + + public static void asyncListAiApplicationMcpServers() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationMcpServersRequest request = + ListAiApplicationMcpServersRequest.newBuilder() + .setParent( + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + agentRegistryClient.listAiApplicationMcpServersPagedCallable().futureCall(request); + // Do something. + for (McpServer element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationMcpServers_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/AsyncListAiApplicationMcpServersPaged.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/AsyncListAiApplicationMcpServersPaged.java new file mode 100644 index 000000000000..def08f0f5180 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/AsyncListAiApplicationMcpServersPaged.java @@ -0,0 +1,63 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationMcpServers_Paged_async] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersResponse; +import com.google.cloud.agentregistry.v1.McpServer; +import com.google.common.base.Strings; + +public class AsyncListAiApplicationMcpServersPaged { + + public static void main(String[] args) throws Exception { + asyncListAiApplicationMcpServersPaged(); + } + + public static void asyncListAiApplicationMcpServersPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationMcpServersRequest request = + ListAiApplicationMcpServersRequest.newBuilder() + .setParent( + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListAiApplicationMcpServersResponse response = + agentRegistryClient.listAiApplicationMcpServersCallable().call(request); + for (McpServer element : response.getMcpServersList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationMcpServers_Paged_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/SyncListAiApplicationMcpServers.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/SyncListAiApplicationMcpServers.java new file mode 100644 index 000000000000..2589cc0530a9 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/SyncListAiApplicationMcpServers.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationMcpServers_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.ListAiApplicationMcpServersRequest; +import com.google.cloud.agentregistry.v1.McpServer; + +public class SyncListAiApplicationMcpServers { + + public static void main(String[] args) throws Exception { + syncListAiApplicationMcpServers(); + } + + public static void syncListAiApplicationMcpServers() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationMcpServersRequest request = + ListAiApplicationMcpServersRequest.newBuilder() + .setParent( + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (McpServer element : + agentRegistryClient.listAiApplicationMcpServers(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationMcpServers_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/SyncListAiApplicationMcpServersAiapplicationname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/SyncListAiApplicationMcpServersAiapplicationname.java new file mode 100644 index 000000000000..ba94e522ffb7 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/SyncListAiApplicationMcpServersAiapplicationname.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationMcpServers_Aiapplicationname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.McpServer; + +public class SyncListAiApplicationMcpServersAiapplicationname { + + public static void main(String[] args) throws Exception { + syncListAiApplicationMcpServersAiapplicationname(); + } + + public static void syncListAiApplicationMcpServersAiapplicationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + AiApplicationName parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]"); + for (McpServer element : + agentRegistryClient.listAiApplicationMcpServers(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationMcpServers_Aiapplicationname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/SyncListAiApplicationMcpServersString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/SyncListAiApplicationMcpServersString.java new file mode 100644 index 000000000000..59b16c06460e --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplicationmcpservers/SyncListAiApplicationMcpServersString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplicationMcpServers_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplicationName; +import com.google.cloud.agentregistry.v1.McpServer; + +public class SyncListAiApplicationMcpServersString { + + public static void main(String[] args) throws Exception { + syncListAiApplicationMcpServersString(); + } + + public static void syncListAiApplicationMcpServersString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String parent = + AiApplicationName.of("[PROJECT]", "[LOCATION]", "[AI_APPLICATION]").toString(); + for (McpServer element : + agentRegistryClient.listAiApplicationMcpServers(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplicationMcpServers_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/AsyncListAiApplications.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/AsyncListAiApplications.java new file mode 100644 index 000000000000..0e01df6a6ab7 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/AsyncListAiApplications.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplications_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplication; +import com.google.cloud.agentregistry.v1.ListAiApplicationsRequest; +import com.google.cloud.agentregistry.v1.LocationName; + +public class AsyncListAiApplications { + + public static void main(String[] args) throws Exception { + asyncListAiApplications(); + } + + public static void asyncListAiApplications() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationsRequest request = + ListAiApplicationsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + ApiFuture future = + agentRegistryClient.listAiApplicationsPagedCallable().futureCall(request); + // Do something. + for (AiApplication element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplications_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/AsyncListAiApplicationsPaged.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/AsyncListAiApplicationsPaged.java new file mode 100644 index 000000000000..cff376d805bb --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/AsyncListAiApplicationsPaged.java @@ -0,0 +1,64 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplications_Paged_async] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplication; +import com.google.cloud.agentregistry.v1.ListAiApplicationsRequest; +import com.google.cloud.agentregistry.v1.ListAiApplicationsResponse; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.common.base.Strings; + +public class AsyncListAiApplicationsPaged { + + public static void main(String[] args) throws Exception { + asyncListAiApplicationsPaged(); + } + + public static void asyncListAiApplicationsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationsRequest request = + ListAiApplicationsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + while (true) { + ListAiApplicationsResponse response = + agentRegistryClient.listAiApplicationsCallable().call(request); + for (AiApplication element : response.getAiApplicationsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplications_Paged_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/SyncListAiApplications.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/SyncListAiApplications.java new file mode 100644 index 000000000000..d49bb65d353e --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/SyncListAiApplications.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplications_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplication; +import com.google.cloud.agentregistry.v1.ListAiApplicationsRequest; +import com.google.cloud.agentregistry.v1.LocationName; + +public class SyncListAiApplications { + + public static void main(String[] args) throws Exception { + syncListAiApplications(); + } + + public static void syncListAiApplications() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListAiApplicationsRequest request = + ListAiApplicationsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + for (AiApplication element : agentRegistryClient.listAiApplications(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplications_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/SyncListAiApplicationsLocationname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/SyncListAiApplicationsLocationname.java new file mode 100644 index 000000000000..f8e567cbbaf4 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/SyncListAiApplicationsLocationname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplications_Locationname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplication; +import com.google.cloud.agentregistry.v1.LocationName; + +public class SyncListAiApplicationsLocationname { + + public static void main(String[] args) throws Exception { + syncListAiApplicationsLocationname(); + } + + public static void syncListAiApplicationsLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (AiApplication element : agentRegistryClient.listAiApplications(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplications_Locationname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/SyncListAiApplicationsString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/SyncListAiApplicationsString.java new file mode 100644 index 000000000000..974dbd0e0a75 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listaiapplications/SyncListAiApplicationsString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListAiApplications_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.AiApplication; +import com.google.cloud.agentregistry.v1.LocationName; + +public class SyncListAiApplicationsString { + + public static void main(String[] args) throws Exception { + syncListAiApplicationsString(); + } + + public static void syncListAiApplicationsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (AiApplication element : agentRegistryClient.listAiApplications(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListAiApplications_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/AsyncListFindings.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/AsyncListFindings.java new file mode 100644 index 000000000000..9e22dcfc46bd --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/AsyncListFindings.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListFindings_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Finding; +import com.google.cloud.agentregistry.v1.ListFindingsRequest; +import com.google.cloud.agentregistry.v1.LocationName; + +public class AsyncListFindings { + + public static void main(String[] args) throws Exception { + asyncListFindings(); + } + + public static void asyncListFindings() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListFindingsRequest request = + ListFindingsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + ApiFuture future = + agentRegistryClient.listFindingsPagedCallable().futureCall(request); + // Do something. + for (Finding element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListFindings_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/AsyncListFindingsPaged.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/AsyncListFindingsPaged.java new file mode 100644 index 000000000000..8a2e8a496ef7 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/AsyncListFindingsPaged.java @@ -0,0 +1,63 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListFindings_Paged_async] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Finding; +import com.google.cloud.agentregistry.v1.ListFindingsRequest; +import com.google.cloud.agentregistry.v1.ListFindingsResponse; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.common.base.Strings; + +public class AsyncListFindingsPaged { + + public static void main(String[] args) throws Exception { + asyncListFindingsPaged(); + } + + public static void asyncListFindingsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListFindingsRequest request = + ListFindingsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + while (true) { + ListFindingsResponse response = agentRegistryClient.listFindingsCallable().call(request); + for (Finding element : response.getFindingsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListFindings_Paged_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/SyncListFindings.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/SyncListFindings.java new file mode 100644 index 000000000000..5670803da42d --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/SyncListFindings.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListFindings_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Finding; +import com.google.cloud.agentregistry.v1.ListFindingsRequest; +import com.google.cloud.agentregistry.v1.LocationName; + +public class SyncListFindings { + + public static void main(String[] args) throws Exception { + syncListFindings(); + } + + public static void syncListFindings() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListFindingsRequest request = + ListFindingsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + for (Finding element : agentRegistryClient.listFindings(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListFindings_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/SyncListFindingsLocationname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/SyncListFindingsLocationname.java new file mode 100644 index 000000000000..c957d6819e21 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/SyncListFindingsLocationname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListFindings_Locationname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Finding; +import com.google.cloud.agentregistry.v1.LocationName; + +public class SyncListFindingsLocationname { + + public static void main(String[] args) throws Exception { + syncListFindingsLocationname(); + } + + public static void syncListFindingsLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (Finding element : agentRegistryClient.listFindings(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListFindings_Locationname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/SyncListFindingsString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/SyncListFindingsString.java new file mode 100644 index 000000000000..8e185ad812ff --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listfindings/SyncListFindingsString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListFindings_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Finding; +import com.google.cloud.agentregistry.v1.LocationName; + +public class SyncListFindingsString { + + public static void main(String[] args) throws Exception { + syncListFindingsString(); + } + + public static void syncListFindingsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (Finding element : agentRegistryClient.listFindings(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListFindings_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/AsyncListPublishers.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/AsyncListPublishers.java new file mode 100644 index 000000000000..8132d0fed2d5 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/AsyncListPublishers.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListPublishers_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.ListPublishersRequest; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Publisher; + +public class AsyncListPublishers { + + public static void main(String[] args) throws Exception { + asyncListPublishers(); + } + + public static void asyncListPublishers() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListPublishersRequest request = + ListPublishersRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + agentRegistryClient.listPublishersPagedCallable().futureCall(request); + // Do something. + for (Publisher element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListPublishers_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/AsyncListPublishersPaged.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/AsyncListPublishersPaged.java new file mode 100644 index 000000000000..dbed96d370e0 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/AsyncListPublishersPaged.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListPublishers_Paged_async] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.ListPublishersRequest; +import com.google.cloud.agentregistry.v1.ListPublishersResponse; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Publisher; +import com.google.common.base.Strings; + +public class AsyncListPublishersPaged { + + public static void main(String[] args) throws Exception { + asyncListPublishersPaged(); + } + + public static void asyncListPublishersPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListPublishersRequest request = + ListPublishersRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListPublishersResponse response = + agentRegistryClient.listPublishersCallable().call(request); + for (Publisher element : response.getPublishersList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListPublishers_Paged_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/SyncListPublishers.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/SyncListPublishers.java new file mode 100644 index 000000000000..bc8c930bc569 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/SyncListPublishers.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListPublishers_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.ListPublishersRequest; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Publisher; + +public class SyncListPublishers { + + public static void main(String[] args) throws Exception { + syncListPublishers(); + } + + public static void syncListPublishers() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListPublishersRequest request = + ListPublishersRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (Publisher element : agentRegistryClient.listPublishers(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListPublishers_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/SyncListPublishersLocationname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/SyncListPublishersLocationname.java new file mode 100644 index 000000000000..4c53327af038 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/SyncListPublishersLocationname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListPublishers_Locationname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Publisher; + +public class SyncListPublishersLocationname { + + public static void main(String[] args) throws Exception { + syncListPublishersLocationname(); + } + + public static void syncListPublishersLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (Publisher element : agentRegistryClient.listPublishers(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListPublishers_Locationname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/SyncListPublishersString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/SyncListPublishersString.java new file mode 100644 index 000000000000..5e2e2a3c91e5 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listpublishers/SyncListPublishersString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListPublishers_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Publisher; + +public class SyncListPublishersString { + + public static void main(String[] args) throws Exception { + syncListPublishersString(); + } + + public static void syncListPublishersString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (Publisher element : agentRegistryClient.listPublishers(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListPublishers_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/AsyncListSkillRevisions.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/AsyncListSkillRevisions.java new file mode 100644 index 000000000000..43eeb8e800ca --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/AsyncListSkillRevisions.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListSkillRevisions_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.cloud.agentregistry.v1.SkillRevision; + +public class AsyncListSkillRevisions { + + public static void main(String[] args) throws Exception { + asyncListSkillRevisions(); + } + + public static void asyncListSkillRevisions() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListSkillRevisionsRequest request = + ListSkillRevisionsRequest.newBuilder() + .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + agentRegistryClient.listSkillRevisionsPagedCallable().futureCall(request); + // Do something. + for (SkillRevision element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListSkillRevisions_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/AsyncListSkillRevisionsPaged.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/AsyncListSkillRevisionsPaged.java new file mode 100644 index 000000000000..e8d91b371538 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/AsyncListSkillRevisionsPaged.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListSkillRevisions_Paged_async] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsResponse; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.cloud.agentregistry.v1.SkillRevision; +import com.google.common.base.Strings; + +public class AsyncListSkillRevisionsPaged { + + public static void main(String[] args) throws Exception { + asyncListSkillRevisionsPaged(); + } + + public static void asyncListSkillRevisionsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListSkillRevisionsRequest request = + ListSkillRevisionsRequest.newBuilder() + .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListSkillRevisionsResponse response = + agentRegistryClient.listSkillRevisionsCallable().call(request); + for (SkillRevision element : response.getSkillRevisionsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListSkillRevisions_Paged_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/SyncListSkillRevisions.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/SyncListSkillRevisions.java new file mode 100644 index 000000000000..106e154fd6da --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/SyncListSkillRevisions.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListSkillRevisions_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.ListSkillRevisionsRequest; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.cloud.agentregistry.v1.SkillRevision; + +public class SyncListSkillRevisions { + + public static void main(String[] args) throws Exception { + syncListSkillRevisions(); + } + + public static void syncListSkillRevisions() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListSkillRevisionsRequest request = + ListSkillRevisionsRequest.newBuilder() + .setParent(SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (SkillRevision element : agentRegistryClient.listSkillRevisions(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListSkillRevisions_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/SyncListSkillRevisionsSkillname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/SyncListSkillRevisionsSkillname.java new file mode 100644 index 000000000000..54328bdc8cc9 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/SyncListSkillRevisionsSkillname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListSkillRevisions_Skillname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.cloud.agentregistry.v1.SkillRevision; + +public class SyncListSkillRevisionsSkillname { + + public static void main(String[] args) throws Exception { + syncListSkillRevisionsSkillname(); + } + + public static void syncListSkillRevisionsSkillname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + SkillName parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]"); + for (SkillRevision element : agentRegistryClient.listSkillRevisions(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListSkillRevisions_Skillname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/SyncListSkillRevisionsString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/SyncListSkillRevisionsString.java new file mode 100644 index 000000000000..924cb0c800aa --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskillrevisions/SyncListSkillRevisionsString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListSkillRevisions_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillName; +import com.google.cloud.agentregistry.v1.SkillRevision; + +public class SyncListSkillRevisionsString { + + public static void main(String[] args) throws Exception { + syncListSkillRevisionsString(); + } + + public static void syncListSkillRevisionsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String parent = SkillName.of("[PROJECT]", "[LOCATION]", "[SKILL]").toString(); + for (SkillRevision element : agentRegistryClient.listSkillRevisions(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListSkillRevisions_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/AsyncListSkills.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/AsyncListSkills.java new file mode 100644 index 000000000000..7c8dc72074ef --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/AsyncListSkills.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListSkills_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.ListSkillsRequest; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Skill; + +public class AsyncListSkills { + + public static void main(String[] args) throws Exception { + asyncListSkills(); + } + + public static void asyncListSkills() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListSkillsRequest request = + ListSkillsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + ApiFuture future = agentRegistryClient.listSkillsPagedCallable().futureCall(request); + // Do something. + for (Skill element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListSkills_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/AsyncListSkillsPaged.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/AsyncListSkillsPaged.java new file mode 100644 index 000000000000..f675c7d86ebb --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/AsyncListSkillsPaged.java @@ -0,0 +1,63 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListSkills_Paged_async] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.ListSkillsRequest; +import com.google.cloud.agentregistry.v1.ListSkillsResponse; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.common.base.Strings; + +public class AsyncListSkillsPaged { + + public static void main(String[] args) throws Exception { + asyncListSkillsPaged(); + } + + public static void asyncListSkillsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListSkillsRequest request = + ListSkillsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + while (true) { + ListSkillsResponse response = agentRegistryClient.listSkillsCallable().call(request); + for (Skill element : response.getSkillsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListSkills_Paged_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/SyncListSkills.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/SyncListSkills.java new file mode 100644 index 000000000000..6cba2c49b406 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/SyncListSkills.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListSkills_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.ListSkillsRequest; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Skill; + +public class SyncListSkills { + + public static void main(String[] args) throws Exception { + syncListSkills(); + } + + public static void syncListSkills() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + ListSkillsRequest request = + ListSkillsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + for (Skill element : agentRegistryClient.listSkills(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListSkills_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/SyncListSkillsLocationname.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/SyncListSkillsLocationname.java new file mode 100644 index 000000000000..739bde6cd9ab --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/SyncListSkillsLocationname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListSkills_Locationname_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Skill; + +public class SyncListSkillsLocationname { + + public static void main(String[] args) throws Exception { + syncListSkillsLocationname(); + } + + public static void syncListSkillsLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (Skill element : agentRegistryClient.listSkills(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListSkills_Locationname_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/SyncListSkillsString.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/SyncListSkillsString.java new file mode 100644 index 000000000000..22744f3362e0 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/listskills/SyncListSkillsString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_ListSkills_String_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.Skill; + +public class SyncListSkillsString { + + public static void main(String[] args) throws Exception { + syncListSkillsString(); + } + + public static void syncListSkillsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (Skill element : agentRegistryClient.listSkills(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_ListSkills_String_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/searchskills/AsyncSearchSkills.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/searchskills/AsyncSearchSkills.java new file mode 100644 index 000000000000..b5ad34ec37b1 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/searchskills/AsyncSearchSkills.java @@ -0,0 +1,57 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_SearchSkills_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.SearchSkillsRequest; +import com.google.cloud.agentregistry.v1.SearchType; +import com.google.cloud.agentregistry.v1.Skill; + +public class AsyncSearchSkills { + + public static void main(String[] args) throws Exception { + asyncSearchSkills(); + } + + public static void asyncSearchSkills() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + SearchSkillsRequest request = + SearchSkillsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setSearchType(SearchType.forNumber(0)) + .setSearchString("searchString120312793") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = agentRegistryClient.searchSkillsPagedCallable().futureCall(request); + // Do something. + for (Skill element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_SearchSkills_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/searchskills/AsyncSearchSkillsPaged.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/searchskills/AsyncSearchSkillsPaged.java new file mode 100644 index 000000000000..a21169b4427e --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/searchskills/AsyncSearchSkillsPaged.java @@ -0,0 +1,65 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_SearchSkills_Paged_async] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.SearchSkillsRequest; +import com.google.cloud.agentregistry.v1.SearchSkillsResponse; +import com.google.cloud.agentregistry.v1.SearchType; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.common.base.Strings; + +public class AsyncSearchSkillsPaged { + + public static void main(String[] args) throws Exception { + asyncSearchSkillsPaged(); + } + + public static void asyncSearchSkillsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + SearchSkillsRequest request = + SearchSkillsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setSearchType(SearchType.forNumber(0)) + .setSearchString("searchString120312793") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + SearchSkillsResponse response = agentRegistryClient.searchSkillsCallable().call(request); + for (Skill element : response.getSkillsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_SearchSkills_Paged_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/searchskills/SyncSearchSkills.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/searchskills/SyncSearchSkills.java new file mode 100644 index 000000000000..bcfd54dd01bd --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/searchskills/SyncSearchSkills.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_SearchSkills_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.LocationName; +import com.google.cloud.agentregistry.v1.SearchSkillsRequest; +import com.google.cloud.agentregistry.v1.SearchType; +import com.google.cloud.agentregistry.v1.Skill; + +public class SyncSearchSkills { + + public static void main(String[] args) throws Exception { + syncSearchSkills(); + } + + public static void syncSearchSkills() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + SearchSkillsRequest request = + SearchSkillsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setSearchType(SearchType.forNumber(0)) + .setSearchString("searchString120312793") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (Skill element : agentRegistryClient.searchSkills(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_SearchSkills_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/AsyncUpdateSkill.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/AsyncUpdateSkill.java new file mode 100644 index 000000000000..f9a614290185 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/AsyncUpdateSkill.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_UpdateSkill_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.cloud.agentregistry.v1.UpdateSkillRequest; +import com.google.longrunning.Operation; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateSkill { + + public static void main(String[] args) throws Exception { + asyncUpdateSkill(); + } + + public static void asyncUpdateSkill() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + UpdateSkillRequest request = + UpdateSkillRequest.newBuilder() + .setSkill(Skill.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + ApiFuture future = agentRegistryClient.updateSkillCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_UpdateSkill_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/AsyncUpdateSkillLRO.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/AsyncUpdateSkillLRO.java new file mode 100644 index 000000000000..76ce988f1fdd --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/AsyncUpdateSkillLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_UpdateSkill_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.OperationMetadata; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.cloud.agentregistry.v1.UpdateSkillRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateSkillLRO { + + public static void main(String[] args) throws Exception { + asyncUpdateSkillLRO(); + } + + public static void asyncUpdateSkillLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + UpdateSkillRequest request = + UpdateSkillRequest.newBuilder() + .setSkill(Skill.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + OperationFuture future = + agentRegistryClient.updateSkillOperationCallable().futureCall(request); + // Do something. + Skill response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_UpdateSkill_LRO_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/SyncUpdateSkill.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/SyncUpdateSkill.java new file mode 100644 index 000000000000..60cdf568accd --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/SyncUpdateSkill.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_UpdateSkill_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.cloud.agentregistry.v1.UpdateSkillRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateSkill { + + public static void main(String[] args) throws Exception { + syncUpdateSkill(); + } + + public static void syncUpdateSkill() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + UpdateSkillRequest request = + UpdateSkillRequest.newBuilder() + .setSkill(Skill.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + Skill response = agentRegistryClient.updateSkillAsync(request).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_UpdateSkill_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/SyncUpdateSkillSkillFieldmask.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/SyncUpdateSkillSkillFieldmask.java new file mode 100644 index 000000000000..977073cb6c61 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskill/SyncUpdateSkillSkillFieldmask.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_UpdateSkill_SkillFieldmask_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.Skill; +import com.google.protobuf.FieldMask; + +public class SyncUpdateSkillSkillFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateSkillSkillFieldmask(); + } + + public static void syncUpdateSkillSkillFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + Skill skill = Skill.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + Skill response = agentRegistryClient.updateSkillAsync(skill, updateMask).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_UpdateSkill_SkillFieldmask_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/AsyncUpdateSkillEncryptionSpec.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/AsyncUpdateSkillEncryptionSpec.java new file mode 100644 index 000000000000..57a618124705 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/AsyncUpdateSkillEncryptionSpec.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_UpdateSkillEncryptionSpec_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest; +import com.google.longrunning.Operation; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateSkillEncryptionSpec { + + public static void main(String[] args) throws Exception { + asyncUpdateSkillEncryptionSpec(); + } + + public static void asyncUpdateSkillEncryptionSpec() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + UpdateSkillEncryptionSpecRequest request = + UpdateSkillEncryptionSpecRequest.newBuilder() + .setSkillEncryptionSpec(SkillEncryptionSpec.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ApiFuture future = + agentRegistryClient.updateSkillEncryptionSpecCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_UpdateSkillEncryptionSpec_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/AsyncUpdateSkillEncryptionSpecLRO.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/AsyncUpdateSkillEncryptionSpecLRO.java new file mode 100644 index 000000000000..97255e793aa3 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/AsyncUpdateSkillEncryptionSpecLRO.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_UpdateSkillEncryptionSpec_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.OperationMetadata; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateSkillEncryptionSpecLRO { + + public static void main(String[] args) throws Exception { + asyncUpdateSkillEncryptionSpecLRO(); + } + + public static void asyncUpdateSkillEncryptionSpecLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + UpdateSkillEncryptionSpecRequest request = + UpdateSkillEncryptionSpecRequest.newBuilder() + .setSkillEncryptionSpec(SkillEncryptionSpec.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + OperationFuture future = + agentRegistryClient.updateSkillEncryptionSpecOperationCallable().futureCall(request); + // Do something. + SkillEncryptionSpec response = future.get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_UpdateSkillEncryptionSpec_LRO_async] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/SyncUpdateSkillEncryptionSpec.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/SyncUpdateSkillEncryptionSpec.java new file mode 100644 index 000000000000..2c21070341c0 --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/SyncUpdateSkillEncryptionSpec.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_UpdateSkillEncryptionSpec_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.cloud.agentregistry.v1.UpdateSkillEncryptionSpecRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateSkillEncryptionSpec { + + public static void main(String[] args) throws Exception { + syncUpdateSkillEncryptionSpec(); + } + + public static void syncUpdateSkillEncryptionSpec() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + UpdateSkillEncryptionSpecRequest request = + UpdateSkillEncryptionSpecRequest.newBuilder() + .setSkillEncryptionSpec(SkillEncryptionSpec.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + SkillEncryptionSpec response = + agentRegistryClient.updateSkillEncryptionSpecAsync(request).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_UpdateSkillEncryptionSpec_sync] diff --git a/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/SyncUpdateSkillEncryptionSpecSkillencryptionspecFieldmask.java b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/SyncUpdateSkillEncryptionSpecSkillencryptionspecFieldmask.java new file mode 100644 index 000000000000..ede7857ef1af --- /dev/null +++ b/java-agentregistry/samples/snippets/generated/com/google/cloud/agentregistry/v1/agentregistry/updateskillencryptionspec/SyncUpdateSkillEncryptionSpecSkillencryptionspecFieldmask.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.agentregistry.v1.samples; + +// [START agentregistry_v1_generated_AgentRegistry_UpdateSkillEncryptionSpec_SkillencryptionspecFieldmask_sync] +import com.google.cloud.agentregistry.v1.AgentRegistryClient; +import com.google.cloud.agentregistry.v1.SkillEncryptionSpec; +import com.google.protobuf.FieldMask; + +public class SyncUpdateSkillEncryptionSpecSkillencryptionspecFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateSkillEncryptionSpecSkillencryptionspecFieldmask(); + } + + public static void syncUpdateSkillEncryptionSpecSkillencryptionspecFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentRegistryClient agentRegistryClient = AgentRegistryClient.create()) { + SkillEncryptionSpec skillEncryptionSpec = SkillEncryptionSpec.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + SkillEncryptionSpec response = + agentRegistryClient.updateSkillEncryptionSpecAsync(skillEncryptionSpec, updateMask).get(); + } + } +} +// [END agentregistry_v1_generated_AgentRegistry_UpdateSkillEncryptionSpec_SkillencryptionspecFieldmask_sync] diff --git a/java-aiplatform/README.md b/java-aiplatform/README.md index a893f2756832..60157c5ee6cc 100644 --- a/java-aiplatform/README.md +++ b/java-aiplatform/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-aiplatform - 3.103.0 + 3.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-aiplatform' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-aiplatform:3.103.0' +implementation 'com.google.cloud:google-cloud-aiplatform:3.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-aiplatform" % "3.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-aiplatform" % "3.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-aiplatform/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-aiplatform.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-aiplatform/3.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-aiplatform/3.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceClient.java b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceClient.java new file mode 100644 index 000000000000..71e7a485bd38 --- /dev/null +++ b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceClient.java @@ -0,0 +1,3906 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1; + +import com.google.api.core.ApiFuture; +import com.google.api.core.ApiFutures; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.longrunning.OperationFuture; +import com.google.api.gax.paging.AbstractFixedSizeCollection; +import com.google.api.gax.paging.AbstractPage; +import com.google.api.gax.paging.AbstractPagedListResponse; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.aiplatform.v1.stub.AgentAnomalyDetectionServiceStub; +import com.google.cloud.aiplatform.v1.stub.AgentAnomalyDetectionServiceStubSettings; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.util.concurrent.MoreExecutors; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.longrunning.OperationsClient; +import com.google.protobuf.Empty; +import java.io.IOException; +import java.util.List; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Service Description: A service for managing Agent Anomaly Detection for monitored agents. + * + *

This class provides the ability to make remote calls to the backing service through method + * calls that map to API methods. Sample code to get started: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+ *     AgentAnomalyDetectionServiceClient.create()) {
+ *   AgentAnomalyDetectionScopeName name =
+ *       AgentAnomalyDetectionScopeName.of(
+ *           "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]");
+ *   AgentAnomalyDetectionScope response =
+ *       agentAnomalyDetectionServiceClient.getAgentAnomalyDetectionScope(name);
+ * }
+ * }
+ * + *

Note: close() needs to be called on the AgentAnomalyDetectionServiceClient object to clean up + * resources such as threads. In the example above, try-with-resources is used, which automatically + * calls close(). + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Methods
MethodDescriptionMethod Variants

GetAgentAnomalyDetectionScope

Gets the details of a specific AgentAnomalyDetectionScope.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • getAgentAnomalyDetectionScope(GetAgentAnomalyDetectionScopeRequest request) + *

+ *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ *
    + *
  • getAgentAnomalyDetectionScope(AgentAnomalyDetectionScopeName name) + *

  • getAgentAnomalyDetectionScope(String name) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • getAgentAnomalyDetectionScopeCallable() + *

+ *

GetMonitoredAgent

Gets the details of a specific MonitoredAgent.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • getMonitoredAgent(GetMonitoredAgentRequest request) + *

+ *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ *
    + *
  • getMonitoredAgent(MonitoredAgentName name) + *

  • getMonitoredAgent(String name) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • getMonitoredAgentCallable() + *

+ *

ListMonitoredAgents

Lists MonitoredAgents in a specific Location.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • listMonitoredAgents(ListMonitoredAgentsRequest request) + *

+ *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ *
    + *
  • listMonitoredAgents(LocationName parent) + *

  • listMonitoredAgents(String parent) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • listMonitoredAgentsPagedCallable() + *

  • listMonitoredAgentsCallable() + *

+ *

EnableMonitoredAgent

Enables a specific MonitoredAgent.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • enableMonitoredAgentAsync(EnableMonitoredAgentRequest request) + *

+ *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ *
    + *
  • enableMonitoredAgentAsync(MonitoredAgentName name) + *

  • enableMonitoredAgentAsync(String name) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • enableMonitoredAgentOperationCallable() + *

  • enableMonitoredAgentCallable() + *

+ *

DisableMonitoredAgent

Disables a specific MonitoredAgent.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • disableMonitoredAgentAsync(DisableMonitoredAgentRequest request) + *

+ *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ *
    + *
  • disableMonitoredAgentAsync(MonitoredAgentName name) + *

  • disableMonitoredAgentAsync(String name) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • disableMonitoredAgentOperationCallable() + *

  • disableMonitoredAgentCallable() + *

+ *

DeleteAgentAnomalyDetectionScope

Deletes a specific AgentAnomalyDetectionScope.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • deleteAgentAnomalyDetectionScopeAsync(DeleteAgentAnomalyDetectionScopeRequest request) + *

+ *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ *
    + *
  • deleteAgentAnomalyDetectionScopeAsync(AgentAnomalyDetectionScopeName name) + *

  • deleteAgentAnomalyDetectionScopeAsync(String name) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • deleteAgentAnomalyDetectionScopeOperationCallable() + *

  • deleteAgentAnomalyDetectionScopeCallable() + *

+ *

CreateAgentAnomalyDetectionScope

Creates a new AgentAnomalyDetectionScope.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • createAgentAnomalyDetectionScopeAsync(CreateAgentAnomalyDetectionScopeRequest request) + *

+ *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ *
    + *
  • createAgentAnomalyDetectionScopeAsync(LocationName parent, AgentAnomalyDetectionScope agentAnomalyDetectionScope, String agentAnomalyDetectionScopeId) + *

  • createAgentAnomalyDetectionScopeAsync(String parent, AgentAnomalyDetectionScope agentAnomalyDetectionScope, String agentAnomalyDetectionScopeId) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • createAgentAnomalyDetectionScopeOperationCallable() + *

  • createAgentAnomalyDetectionScopeCallable() + *

+ *

ListAgentAnomalyDetectionScopes

Lists AgentAnomalyDetectionScopes in a Location.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • listAgentAnomalyDetectionScopes(ListAgentAnomalyDetectionScopesRequest request) + *

+ *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ *
    + *
  • listAgentAnomalyDetectionScopes(LocationName parent) + *

  • listAgentAnomalyDetectionScopes(String parent) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • listAgentAnomalyDetectionScopesPagedCallable() + *

  • listAgentAnomalyDetectionScopesCallable() + *

+ *

ListAnalyzedSessions

Lists AnalyzedSessions in a MonitoredAgent.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • listAnalyzedSessions(ListAnalyzedSessionsRequest request) + *

+ *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ *
    + *
  • listAnalyzedSessions(MonitoredAgentName parent) + *

  • listAnalyzedSessions(String parent) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • listAnalyzedSessionsPagedCallable() + *

  • listAnalyzedSessionsCallable() + *

+ *

GetAnalyzedSession

Gets the details of a specific AnalyzedSession.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • getAnalyzedSession(GetAnalyzedSessionRequest request) + *

+ *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ *
    + *
  • getAnalyzedSession(AnalyzedSessionName name) + *

  • getAnalyzedSession(String name) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • getAnalyzedSessionCallable() + *

+ *

ListAnalyzedInvocations

Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • listAnalyzedInvocations(ListAnalyzedInvocationsRequest request) + *

+ *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ *
    + *
  • listAnalyzedInvocations(AnalyzedSessionName parent) + *

  • listAnalyzedInvocations(String parent) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • listAnalyzedInvocationsPagedCallable() + *

  • listAnalyzedInvocationsCallable() + *

+ *

GetAnalyzedInvocation

Gets the details of a specific AnalyzedInvocation.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • getAnalyzedInvocation(GetAnalyzedInvocationRequest request) + *

+ *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ *
    + *
  • getAnalyzedInvocation(AnalyzedInvocationName name) + *

  • getAnalyzedInvocation(String name) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • getAnalyzedInvocationCallable() + *

+ *

AggregateAnalyzedSessions

Aggregates AnalyzedSessions across MonitoredAgents. + *

To aggregate across all MonitoredAgents in a location, use the following format for the parent field: `projects/{project}/locations/{location}/monitoredAgents/-`

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • aggregateAnalyzedSessions(AggregateAnalyzedSessionsRequest request) + *

+ *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ *
    + *
  • aggregateAnalyzedSessions(MonitoredAgentName parent) + *

  • aggregateAnalyzedSessions(String parent) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • aggregateAnalyzedSessionsPagedCallable() + *

  • aggregateAnalyzedSessionsCallable() + *

+ *

ClearTrainingData

Clears (purges) the trained model artifacts derived from a MonitoredAgent's data. The purged model is rebuilt by the next scheduled training run. + *

To clear every MonitoredAgent in a location's scope, use the `-` wildcard agent segment for the name field: `projects/{project}/locations/{location}/monitoredAgents/-` + *

This is the on-demand data-deletion path for customers who have deleted the underlying logs / observability data a model was trained on. It deletes only the derived model artifacts (it does NOT delete the scope or stop monitoring). To stop monitoring an agent entirely, disable it via DisableMonitoredAgent.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • clearTrainingDataAsync(ClearTrainingDataRequest request) + *

+ *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ *
    + *
  • clearTrainingDataAsync(MonitoredAgentName name) + *

  • clearTrainingDataAsync(String name) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • clearTrainingDataOperationCallable() + *

  • clearTrainingDataCallable() + *

+ *

ListLocations

Lists information about the supported locations for this service.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • listLocations(ListLocationsRequest request) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • listLocationsPagedCallable() + *

  • listLocationsCallable() + *

+ *

GetLocation

Gets information about a location.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • getLocation(GetLocationRequest request) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • getLocationCallable() + *

+ *

SetIamPolicy

Sets the access control policy on the specified resource. Replacesany existing policy. + *

Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`errors.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • setIamPolicy(SetIamPolicyRequest request) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • setIamPolicyCallable() + *

+ *

GetIamPolicy

Gets the access control policy for a resource. Returns an empty policyif the resource exists and does not have a policy set.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • getIamPolicy(GetIamPolicyRequest request) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • getIamPolicyCallable() + *

+ *

TestIamPermissions

Returns permissions that a caller has on the specified resource. If theresource does not exist, this will return an empty set ofpermissions, not a `NOT_FOUND` error. + *

Note: This operation is designed to be used for buildingpermission-aware UIs and command-line tools, not for authorizationchecking. This operation may "fail open" without warning.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • testIamPermissions(TestIamPermissionsRequest request) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • testIamPermissionsCallable() + *

+ *
+ * + *

See the individual methods for example code. + * + *

Many parameters require resource names to be formatted in a particular way. To assist with + * these names, this class includes a format method for each type of name, and additionally a parse + * method to extract the individual identifiers contained within names that are returned. + * + *

This class can be customized by passing in a custom instance of + * AgentAnomalyDetectionServiceSettings to create(). For example: + * + *

To customize credentials: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * AgentAnomalyDetectionServiceSettings agentAnomalyDetectionServiceSettings =
+ *     AgentAnomalyDetectionServiceSettings.newBuilder()
+ *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ *         .build();
+ * AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+ *     AgentAnomalyDetectionServiceClient.create(agentAnomalyDetectionServiceSettings);
+ * }
+ * + *

To customize the endpoint: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * AgentAnomalyDetectionServiceSettings agentAnomalyDetectionServiceSettings =
+ *     AgentAnomalyDetectionServiceSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+ *     AgentAnomalyDetectionServiceClient.create(agentAnomalyDetectionServiceSettings);
+ * }
+ * + *

Please refer to the GitHub repository's samples for more quickstart code snippets. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class AgentAnomalyDetectionServiceClient implements BackgroundResource { + private final @Nullable AgentAnomalyDetectionServiceSettings settings; + private final AgentAnomalyDetectionServiceStub stub; + private final OperationsClient operationsClient; + + /** Constructs an instance of AgentAnomalyDetectionServiceClient with default settings. */ + public static final AgentAnomalyDetectionServiceClient create() throws IOException { + return create(AgentAnomalyDetectionServiceSettings.newBuilder().build()); + } + + /** + * Constructs an instance of AgentAnomalyDetectionServiceClient, using the given settings. The + * channels are created based on the settings passed in, or defaults for any settings that are not + * set. + */ + public static final AgentAnomalyDetectionServiceClient create( + AgentAnomalyDetectionServiceSettings settings) throws IOException { + return new AgentAnomalyDetectionServiceClient(settings); + } + + /** + * Constructs an instance of AgentAnomalyDetectionServiceClient, using the given stub for making + * calls. This is for advanced usage - prefer using create(AgentAnomalyDetectionServiceSettings). + */ + public static final AgentAnomalyDetectionServiceClient create( + AgentAnomalyDetectionServiceStub stub) { + return new AgentAnomalyDetectionServiceClient(stub); + } + + /** + * Constructs an instance of AgentAnomalyDetectionServiceClient, using the given settings. This is + * protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected AgentAnomalyDetectionServiceClient(AgentAnomalyDetectionServiceSettings settings) + throws IOException { + this.settings = settings; + this.stub = + ((AgentAnomalyDetectionServiceStubSettings) settings.getStubSettings()).createStub(); + this.operationsClient = OperationsClient.create(this.stub.getOperationsStub()); + } + + protected AgentAnomalyDetectionServiceClient(AgentAnomalyDetectionServiceStub stub) { + this.settings = null; + this.stub = stub; + this.operationsClient = OperationsClient.create(this.stub.getOperationsStub()); + } + + public final @Nullable AgentAnomalyDetectionServiceSettings getSettings() { + return settings; + } + + public AgentAnomalyDetectionServiceStub getStub() { + return stub; + } + + /** + * Returns the OperationsClient that can be used to query the status of a long-running operation + * returned by another API method call. + */ + public final OperationsClient getOperationsClient() { + return operationsClient; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   AgentAnomalyDetectionScopeName name =
+   *       AgentAnomalyDetectionScopeName.of(
+   *           "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]");
+   *   AgentAnomalyDetectionScope response =
+   *       agentAnomalyDetectionServiceClient.getAgentAnomalyDetectionScope(name);
+   * }
+   * }
+ * + * @param name Required. The name of the AgentAnomalyDetectionScope resource. Format: + * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AgentAnomalyDetectionScope getAgentAnomalyDetectionScope( + @Nullable AgentAnomalyDetectionScopeName name) { + GetAgentAnomalyDetectionScopeRequest request = + GetAgentAnomalyDetectionScopeRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getAgentAnomalyDetectionScope(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String name =
+   *       AgentAnomalyDetectionScopeName.of(
+   *               "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]")
+   *           .toString();
+   *   AgentAnomalyDetectionScope response =
+   *       agentAnomalyDetectionServiceClient.getAgentAnomalyDetectionScope(name);
+   * }
+   * }
+ * + * @param name Required. The name of the AgentAnomalyDetectionScope resource. Format: + * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AgentAnomalyDetectionScope getAgentAnomalyDetectionScope(String name) { + GetAgentAnomalyDetectionScopeRequest request = + GetAgentAnomalyDetectionScopeRequest.newBuilder().setName(name).build(); + return getAgentAnomalyDetectionScope(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetAgentAnomalyDetectionScopeRequest request =
+   *       GetAgentAnomalyDetectionScopeRequest.newBuilder()
+   *           .setName(
+   *               AgentAnomalyDetectionScopeName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]")
+   *                   .toString())
+   *           .build();
+   *   AgentAnomalyDetectionScope response =
+   *       agentAnomalyDetectionServiceClient.getAgentAnomalyDetectionScope(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AgentAnomalyDetectionScope getAgentAnomalyDetectionScope( + GetAgentAnomalyDetectionScopeRequest request) { + return getAgentAnomalyDetectionScopeCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetAgentAnomalyDetectionScopeRequest request =
+   *       GetAgentAnomalyDetectionScopeRequest.newBuilder()
+   *           .setName(
+   *               AgentAnomalyDetectionScopeName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]")
+   *                   .toString())
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient
+   *           .getAgentAnomalyDetectionScopeCallable()
+   *           .futureCall(request);
+   *   // Do something.
+   *   AgentAnomalyDetectionScope response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + getAgentAnomalyDetectionScopeCallable() { + return stub.getAgentAnomalyDetectionScopeCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   MonitoredAgentName name =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]");
+   *   MonitoredAgent response = agentAnomalyDetectionServiceClient.getMonitoredAgent(name);
+   * }
+   * }
+ * + * @param name Required. The name of the MonitoredAgent resource. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final MonitoredAgent getMonitoredAgent(@Nullable MonitoredAgentName name) { + GetMonitoredAgentRequest request = + GetMonitoredAgentRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getMonitoredAgent(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String name =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString();
+   *   MonitoredAgent response = agentAnomalyDetectionServiceClient.getMonitoredAgent(name);
+   * }
+   * }
+ * + * @param name Required. The name of the MonitoredAgent resource. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final MonitoredAgent getMonitoredAgent(String name) { + GetMonitoredAgentRequest request = GetMonitoredAgentRequest.newBuilder().setName(name).build(); + return getMonitoredAgent(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetMonitoredAgentRequest request =
+   *       GetMonitoredAgentRequest.newBuilder()
+   *           .setName(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .build();
+   *   MonitoredAgent response = agentAnomalyDetectionServiceClient.getMonitoredAgent(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final MonitoredAgent getMonitoredAgent(GetMonitoredAgentRequest request) { + return getMonitoredAgentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetMonitoredAgentRequest request =
+   *       GetMonitoredAgentRequest.newBuilder()
+   *           .setName(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.getMonitoredAgentCallable().futureCall(request);
+   *   // Do something.
+   *   MonitoredAgent response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getMonitoredAgentCallable() { + return stub.getMonitoredAgentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists MonitoredAgents in a specific Location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (MonitoredAgent element :
+   *       agentAnomalyDetectionServiceClient.listMonitoredAgents(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The resource name of the Location to list the MonitoredAgents from. + * Format: `projects/{project}/locations/{location}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListMonitoredAgentsPagedResponse listMonitoredAgents(@Nullable LocationName parent) { + ListMonitoredAgentsRequest request = + ListMonitoredAgentsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listMonitoredAgents(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists MonitoredAgents in a specific Location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (MonitoredAgent element :
+   *       agentAnomalyDetectionServiceClient.listMonitoredAgents(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The resource name of the Location to list the MonitoredAgents from. + * Format: `projects/{project}/locations/{location}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListMonitoredAgentsPagedResponse listMonitoredAgents(String parent) { + ListMonitoredAgentsRequest request = + ListMonitoredAgentsRequest.newBuilder().setParent(parent).build(); + return listMonitoredAgents(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists MonitoredAgents in a specific Location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListMonitoredAgentsRequest request =
+   *       ListMonitoredAgentsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   for (MonitoredAgent element :
+   *       agentAnomalyDetectionServiceClient.listMonitoredAgents(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListMonitoredAgentsPagedResponse listMonitoredAgents( + ListMonitoredAgentsRequest request) { + return listMonitoredAgentsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists MonitoredAgents in a specific Location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListMonitoredAgentsRequest request =
+   *       ListMonitoredAgentsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.listMonitoredAgentsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (MonitoredAgent element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listMonitoredAgentsPagedCallable() { + return stub.listMonitoredAgentsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists MonitoredAgents in a specific Location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListMonitoredAgentsRequest request =
+   *       ListMonitoredAgentsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   while (true) {
+   *     ListMonitoredAgentsResponse response =
+   *         agentAnomalyDetectionServiceClient.listMonitoredAgentsCallable().call(request);
+   *     for (MonitoredAgent element : response.getMonitoredAgentsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listMonitoredAgentsCallable() { + return stub.listMonitoredAgentsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Enables a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   MonitoredAgentName name =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]");
+   *   MonitoredAgent response =
+   *       agentAnomalyDetectionServiceClient.enableMonitoredAgentAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the MonitoredAgent resource to be enabled. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + enableMonitoredAgentAsync(@Nullable MonitoredAgentName name) { + EnableMonitoredAgentRequest request = + EnableMonitoredAgentRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return enableMonitoredAgentAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Enables a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String name =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString();
+   *   MonitoredAgent response =
+   *       agentAnomalyDetectionServiceClient.enableMonitoredAgentAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the MonitoredAgent resource to be enabled. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + enableMonitoredAgentAsync(String name) { + EnableMonitoredAgentRequest request = + EnableMonitoredAgentRequest.newBuilder().setName(name).build(); + return enableMonitoredAgentAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Enables a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   EnableMonitoredAgentRequest request =
+   *       EnableMonitoredAgentRequest.newBuilder()
+   *           .setName(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .build();
+   *   MonitoredAgent response =
+   *       agentAnomalyDetectionServiceClient.enableMonitoredAgentAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + enableMonitoredAgentAsync(EnableMonitoredAgentRequest request) { + return enableMonitoredAgentOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Enables a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   EnableMonitoredAgentRequest request =
+   *       EnableMonitoredAgentRequest.newBuilder()
+   *           .setName(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .build();
+   *   OperationFuture future =
+   *       agentAnomalyDetectionServiceClient
+   *           .enableMonitoredAgentOperationCallable()
+   *           .futureCall(request);
+   *   // Do something.
+   *   MonitoredAgent response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable< + EnableMonitoredAgentRequest, MonitoredAgent, EnableMonitoredAgentOperationMetadata> + enableMonitoredAgentOperationCallable() { + return stub.enableMonitoredAgentOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Enables a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   EnableMonitoredAgentRequest request =
+   *       EnableMonitoredAgentRequest.newBuilder()
+   *           .setName(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.enableMonitoredAgentCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + enableMonitoredAgentCallable() { + return stub.enableMonitoredAgentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Disables a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   MonitoredAgentName name =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]");
+   *   MonitoredAgent response =
+   *       agentAnomalyDetectionServiceClient.disableMonitoredAgentAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the MonitoredAgent resource to be disabled. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + disableMonitoredAgentAsync(@Nullable MonitoredAgentName name) { + DisableMonitoredAgentRequest request = + DisableMonitoredAgentRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return disableMonitoredAgentAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Disables a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String name =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString();
+   *   MonitoredAgent response =
+   *       agentAnomalyDetectionServiceClient.disableMonitoredAgentAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the MonitoredAgent resource to be disabled. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + disableMonitoredAgentAsync(String name) { + DisableMonitoredAgentRequest request = + DisableMonitoredAgentRequest.newBuilder().setName(name).build(); + return disableMonitoredAgentAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Disables a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   DisableMonitoredAgentRequest request =
+   *       DisableMonitoredAgentRequest.newBuilder()
+   *           .setName(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .build();
+   *   MonitoredAgent response =
+   *       agentAnomalyDetectionServiceClient.disableMonitoredAgentAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + disableMonitoredAgentAsync(DisableMonitoredAgentRequest request) { + return disableMonitoredAgentOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Disables a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   DisableMonitoredAgentRequest request =
+   *       DisableMonitoredAgentRequest.newBuilder()
+   *           .setName(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .build();
+   *   OperationFuture future =
+   *       agentAnomalyDetectionServiceClient
+   *           .disableMonitoredAgentOperationCallable()
+   *           .futureCall(request);
+   *   // Do something.
+   *   MonitoredAgent response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable< + DisableMonitoredAgentRequest, MonitoredAgent, DisableMonitoredAgentOperationMetadata> + disableMonitoredAgentOperationCallable() { + return stub.disableMonitoredAgentOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Disables a specific MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   DisableMonitoredAgentRequest request =
+   *       DisableMonitoredAgentRequest.newBuilder()
+   *           .setName(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.disableMonitoredAgentCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + disableMonitoredAgentCallable() { + return stub.disableMonitoredAgentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a specific AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   AgentAnomalyDetectionScopeName name =
+   *       AgentAnomalyDetectionScopeName.of(
+   *           "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]");
+   *   agentAnomalyDetectionServiceClient.deleteAgentAnomalyDetectionScopeAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the AgentAnomalyDetectionScope resource to be deleted. + * Format: + * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + deleteAgentAnomalyDetectionScopeAsync(@Nullable AgentAnomalyDetectionScopeName name) { + DeleteAgentAnomalyDetectionScopeRequest request = + DeleteAgentAnomalyDetectionScopeRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return deleteAgentAnomalyDetectionScopeAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a specific AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String name =
+   *       AgentAnomalyDetectionScopeName.of(
+   *               "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]")
+   *           .toString();
+   *   agentAnomalyDetectionServiceClient.deleteAgentAnomalyDetectionScopeAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the AgentAnomalyDetectionScope resource to be deleted. + * Format: + * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + deleteAgentAnomalyDetectionScopeAsync(String name) { + DeleteAgentAnomalyDetectionScopeRequest request = + DeleteAgentAnomalyDetectionScopeRequest.newBuilder().setName(name).build(); + return deleteAgentAnomalyDetectionScopeAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a specific AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   DeleteAgentAnomalyDetectionScopeRequest request =
+   *       DeleteAgentAnomalyDetectionScopeRequest.newBuilder()
+   *           .setName(
+   *               AgentAnomalyDetectionScopeName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]")
+   *                   .toString())
+   *           .build();
+   *   agentAnomalyDetectionServiceClient.deleteAgentAnomalyDetectionScopeAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + deleteAgentAnomalyDetectionScopeAsync(DeleteAgentAnomalyDetectionScopeRequest request) { + return deleteAgentAnomalyDetectionScopeOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a specific AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   DeleteAgentAnomalyDetectionScopeRequest request =
+   *       DeleteAgentAnomalyDetectionScopeRequest.newBuilder()
+   *           .setName(
+   *               AgentAnomalyDetectionScopeName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]")
+   *                   .toString())
+   *           .build();
+   *   OperationFuture future =
+   *       agentAnomalyDetectionServiceClient
+   *           .deleteAgentAnomalyDetectionScopeOperationCallable()
+   *           .futureCall(request);
+   *   // Do something.
+   *   future.get();
+   * }
+   * }
+ */ + public final OperationCallable< + DeleteAgentAnomalyDetectionScopeRequest, + Empty, + DeleteAgentAnomalyDetectionScopeOperationMetadata> + deleteAgentAnomalyDetectionScopeOperationCallable() { + return stub.deleteAgentAnomalyDetectionScopeOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a specific AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   DeleteAgentAnomalyDetectionScopeRequest request =
+   *       DeleteAgentAnomalyDetectionScopeRequest.newBuilder()
+   *           .setName(
+   *               AgentAnomalyDetectionScopeName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]")
+   *                   .toString())
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient
+   *           .deleteAgentAnomalyDetectionScopeCallable()
+   *           .futureCall(request);
+   *   // Do something.
+   *   future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + deleteAgentAnomalyDetectionScopeCallable() { + return stub.deleteAgentAnomalyDetectionScopeCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   AgentAnomalyDetectionScope agentAnomalyDetectionScope =
+   *       AgentAnomalyDetectionScope.newBuilder().build();
+   *   String agentAnomalyDetectionScopeId = "agentAnomalyDetectionScopeId-218530648";
+   *   AgentAnomalyDetectionScope response =
+   *       agentAnomalyDetectionServiceClient
+   *           .createAgentAnomalyDetectionScopeAsync(
+   *               parent, agentAnomalyDetectionScope, agentAnomalyDetectionScopeId)
+   *           .get();
+   * }
+   * }
+ * + * @param parent Required. The resource name of the Location to create the + * AgentAnomalyDetectionScope in. Format: `projects/{project}/locations/{location}` + * @param agentAnomalyDetectionScope Required. The AgentAnomalyDetectionScope to create. + * @param agentAnomalyDetectionScopeId Required. The ID to use for the AgentAnomalyDetectionScope, + * which will become the final component of the AgentAnomalyDetectionScope's resource name. + *

This value should be 1-63 characters, and valid characters are + * /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture< + AgentAnomalyDetectionScope, CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeAsync( + @Nullable LocationName parent, + AgentAnomalyDetectionScope agentAnomalyDetectionScope, + String agentAnomalyDetectionScopeId) { + CreateAgentAnomalyDetectionScopeRequest request = + CreateAgentAnomalyDetectionScopeRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setAgentAnomalyDetectionScope(agentAnomalyDetectionScope) + .setAgentAnomalyDetectionScopeId(agentAnomalyDetectionScopeId) + .build(); + return createAgentAnomalyDetectionScopeAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   AgentAnomalyDetectionScope agentAnomalyDetectionScope =
+   *       AgentAnomalyDetectionScope.newBuilder().build();
+   *   String agentAnomalyDetectionScopeId = "agentAnomalyDetectionScopeId-218530648";
+   *   AgentAnomalyDetectionScope response =
+   *       agentAnomalyDetectionServiceClient
+   *           .createAgentAnomalyDetectionScopeAsync(
+   *               parent, agentAnomalyDetectionScope, agentAnomalyDetectionScopeId)
+   *           .get();
+   * }
+   * }
+ * + * @param parent Required. The resource name of the Location to create the + * AgentAnomalyDetectionScope in. Format: `projects/{project}/locations/{location}` + * @param agentAnomalyDetectionScope Required. The AgentAnomalyDetectionScope to create. + * @param agentAnomalyDetectionScopeId Required. The ID to use for the AgentAnomalyDetectionScope, + * which will become the final component of the AgentAnomalyDetectionScope's resource name. + *

This value should be 1-63 characters, and valid characters are + * /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture< + AgentAnomalyDetectionScope, CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeAsync( + String parent, + AgentAnomalyDetectionScope agentAnomalyDetectionScope, + String agentAnomalyDetectionScopeId) { + CreateAgentAnomalyDetectionScopeRequest request = + CreateAgentAnomalyDetectionScopeRequest.newBuilder() + .setParent(parent) + .setAgentAnomalyDetectionScope(agentAnomalyDetectionScope) + .setAgentAnomalyDetectionScopeId(agentAnomalyDetectionScopeId) + .build(); + return createAgentAnomalyDetectionScopeAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   CreateAgentAnomalyDetectionScopeRequest request =
+   *       CreateAgentAnomalyDetectionScopeRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setAgentAnomalyDetectionScope(AgentAnomalyDetectionScope.newBuilder().build())
+   *           .setAgentAnomalyDetectionScopeId("agentAnomalyDetectionScopeId-218530648")
+   *           .build();
+   *   AgentAnomalyDetectionScope response =
+   *       agentAnomalyDetectionServiceClient.createAgentAnomalyDetectionScopeAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture< + AgentAnomalyDetectionScope, CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeAsync(CreateAgentAnomalyDetectionScopeRequest request) { + return createAgentAnomalyDetectionScopeOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   CreateAgentAnomalyDetectionScopeRequest request =
+   *       CreateAgentAnomalyDetectionScopeRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setAgentAnomalyDetectionScope(AgentAnomalyDetectionScope.newBuilder().build())
+   *           .setAgentAnomalyDetectionScopeId("agentAnomalyDetectionScopeId-218530648")
+   *           .build();
+   *   OperationFuture
+   *       future =
+   *           agentAnomalyDetectionServiceClient
+   *               .createAgentAnomalyDetectionScopeOperationCallable()
+   *               .futureCall(request);
+   *   // Do something.
+   *   AgentAnomalyDetectionScope response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable< + CreateAgentAnomalyDetectionScopeRequest, + AgentAnomalyDetectionScope, + CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeOperationCallable() { + return stub.createAgentAnomalyDetectionScopeOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new AgentAnomalyDetectionScope. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   CreateAgentAnomalyDetectionScopeRequest request =
+   *       CreateAgentAnomalyDetectionScopeRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setAgentAnomalyDetectionScope(AgentAnomalyDetectionScope.newBuilder().build())
+   *           .setAgentAnomalyDetectionScopeId("agentAnomalyDetectionScopeId-218530648")
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient
+   *           .createAgentAnomalyDetectionScopeCallable()
+   *           .futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + createAgentAnomalyDetectionScopeCallable() { + return stub.createAgentAnomalyDetectionScopeCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AgentAnomalyDetectionScopes in a Location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (AgentAnomalyDetectionScope element :
+   *       agentAnomalyDetectionServiceClient.listAgentAnomalyDetectionScopes(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The resource name of the Location to list the + * AgentAnomalyDetectionScopes from. Format: `projects/{project}/locations/{location}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAgentAnomalyDetectionScopesPagedResponse listAgentAnomalyDetectionScopes( + @Nullable LocationName parent) { + ListAgentAnomalyDetectionScopesRequest request = + ListAgentAnomalyDetectionScopesRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listAgentAnomalyDetectionScopes(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AgentAnomalyDetectionScopes in a Location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (AgentAnomalyDetectionScope element :
+   *       agentAnomalyDetectionServiceClient.listAgentAnomalyDetectionScopes(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The resource name of the Location to list the + * AgentAnomalyDetectionScopes from. Format: `projects/{project}/locations/{location}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAgentAnomalyDetectionScopesPagedResponse listAgentAnomalyDetectionScopes( + String parent) { + ListAgentAnomalyDetectionScopesRequest request = + ListAgentAnomalyDetectionScopesRequest.newBuilder().setParent(parent).build(); + return listAgentAnomalyDetectionScopes(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AgentAnomalyDetectionScopes in a Location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListAgentAnomalyDetectionScopesRequest request =
+   *       ListAgentAnomalyDetectionScopesRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (AgentAnomalyDetectionScope element :
+   *       agentAnomalyDetectionServiceClient
+   *           .listAgentAnomalyDetectionScopes(request)
+   *           .iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAgentAnomalyDetectionScopesPagedResponse listAgentAnomalyDetectionScopes( + ListAgentAnomalyDetectionScopesRequest request) { + return listAgentAnomalyDetectionScopesPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AgentAnomalyDetectionScopes in a Location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListAgentAnomalyDetectionScopesRequest request =
+   *       ListAgentAnomalyDetectionScopesRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient
+   *           .listAgentAnomalyDetectionScopesPagedCallable()
+   *           .futureCall(request);
+   *   // Do something.
+   *   for (AgentAnomalyDetectionScope element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable< + ListAgentAnomalyDetectionScopesRequest, ListAgentAnomalyDetectionScopesPagedResponse> + listAgentAnomalyDetectionScopesPagedCallable() { + return stub.listAgentAnomalyDetectionScopesPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AgentAnomalyDetectionScopes in a Location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListAgentAnomalyDetectionScopesRequest request =
+   *       ListAgentAnomalyDetectionScopesRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     ListAgentAnomalyDetectionScopesResponse response =
+   *         agentAnomalyDetectionServiceClient
+   *             .listAgentAnomalyDetectionScopesCallable()
+   *             .call(request);
+   *     for (AgentAnomalyDetectionScope element : response.getAgentAnomalyDetectionScopesList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable< + ListAgentAnomalyDetectionScopesRequest, ListAgentAnomalyDetectionScopesResponse> + listAgentAnomalyDetectionScopesCallable() { + return stub.listAgentAnomalyDetectionScopesCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AnalyzedSessions in a MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   MonitoredAgentName parent =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]");
+   *   for (AnalyzedSession element :
+   *       agentAnomalyDetectionServiceClient.listAnalyzedSessions(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent MonitoredAgent resource. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAnalyzedSessionsPagedResponse listAnalyzedSessions( + @Nullable MonitoredAgentName parent) { + ListAnalyzedSessionsRequest request = + ListAnalyzedSessionsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listAnalyzedSessions(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AnalyzedSessions in a MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String parent =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString();
+   *   for (AnalyzedSession element :
+   *       agentAnomalyDetectionServiceClient.listAnalyzedSessions(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent MonitoredAgent resource. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAnalyzedSessionsPagedResponse listAnalyzedSessions(String parent) { + ListAnalyzedSessionsRequest request = + ListAnalyzedSessionsRequest.newBuilder().setParent(parent).build(); + return listAnalyzedSessions(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AnalyzedSessions in a MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListAnalyzedSessionsRequest request =
+   *       ListAnalyzedSessionsRequest.newBuilder()
+   *           .setParent(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setView(AnalyzedSessionView.forNumber(0))
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   for (AnalyzedSession element :
+   *       agentAnomalyDetectionServiceClient.listAnalyzedSessions(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAnalyzedSessionsPagedResponse listAnalyzedSessions( + ListAnalyzedSessionsRequest request) { + return listAnalyzedSessionsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AnalyzedSessions in a MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListAnalyzedSessionsRequest request =
+   *       ListAnalyzedSessionsRequest.newBuilder()
+   *           .setParent(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setView(AnalyzedSessionView.forNumber(0))
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient
+   *           .listAnalyzedSessionsPagedCallable()
+   *           .futureCall(request);
+   *   // Do something.
+   *   for (AnalyzedSession element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listAnalyzedSessionsPagedCallable() { + return stub.listAnalyzedSessionsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AnalyzedSessions in a MonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListAnalyzedSessionsRequest request =
+   *       ListAnalyzedSessionsRequest.newBuilder()
+   *           .setParent(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setView(AnalyzedSessionView.forNumber(0))
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   while (true) {
+   *     ListAnalyzedSessionsResponse response =
+   *         agentAnomalyDetectionServiceClient.listAnalyzedSessionsCallable().call(request);
+   *     for (AnalyzedSession element : response.getAnalyzedSessionsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listAnalyzedSessionsCallable() { + return stub.listAnalyzedSessionsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AnalyzedSession. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   AnalyzedSessionName name =
+   *       AnalyzedSessionName.of(
+   *           "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]");
+   *   AnalyzedSession response = agentAnomalyDetectionServiceClient.getAnalyzedSession(name);
+   * }
+   * }
+ * + * @param name Required. The name of the AnalyzedSession resource. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AnalyzedSession getAnalyzedSession(@Nullable AnalyzedSessionName name) { + GetAnalyzedSessionRequest request = + GetAnalyzedSessionRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getAnalyzedSession(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AnalyzedSession. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String name =
+   *       AnalyzedSessionName.of(
+   *               "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]")
+   *           .toString();
+   *   AnalyzedSession response = agentAnomalyDetectionServiceClient.getAnalyzedSession(name);
+   * }
+   * }
+ * + * @param name Required. The name of the AnalyzedSession resource. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AnalyzedSession getAnalyzedSession(String name) { + GetAnalyzedSessionRequest request = + GetAnalyzedSessionRequest.newBuilder().setName(name).build(); + return getAnalyzedSession(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AnalyzedSession. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetAnalyzedSessionRequest request =
+   *       GetAnalyzedSessionRequest.newBuilder()
+   *           .setName(
+   *               AnalyzedSessionName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]")
+   *                   .toString())
+   *           .setView(AnalyzedSessionView.forNumber(0))
+   *           .build();
+   *   AnalyzedSession response = agentAnomalyDetectionServiceClient.getAnalyzedSession(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AnalyzedSession getAnalyzedSession(GetAnalyzedSessionRequest request) { + return getAnalyzedSessionCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AnalyzedSession. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetAnalyzedSessionRequest request =
+   *       GetAnalyzedSessionRequest.newBuilder()
+   *           .setName(
+   *               AnalyzedSessionName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]")
+   *                   .toString())
+   *           .setView(AnalyzedSessionView.forNumber(0))
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.getAnalyzedSessionCallable().futureCall(request);
+   *   // Do something.
+   *   AnalyzedSession response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + getAnalyzedSessionCallable() { + return stub.getAnalyzedSessionCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   AnalyzedSessionName parent =
+   *       AnalyzedSessionName.of(
+   *           "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]");
+   *   for (AnalyzedInvocation element :
+   *       agentAnomalyDetectionServiceClient.listAnalyzedInvocations(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent AnalyzedSession resource. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAnalyzedInvocationsPagedResponse listAnalyzedInvocations( + @Nullable AnalyzedSessionName parent) { + ListAnalyzedInvocationsRequest request = + ListAnalyzedInvocationsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listAnalyzedInvocations(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String parent =
+   *       AnalyzedSessionName.of(
+   *               "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]")
+   *           .toString();
+   *   for (AnalyzedInvocation element :
+   *       agentAnomalyDetectionServiceClient.listAnalyzedInvocations(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent AnalyzedSession resource. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAnalyzedInvocationsPagedResponse listAnalyzedInvocations(String parent) { + ListAnalyzedInvocationsRequest request = + ListAnalyzedInvocationsRequest.newBuilder().setParent(parent).build(); + return listAnalyzedInvocations(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListAnalyzedInvocationsRequest request =
+   *       ListAnalyzedInvocationsRequest.newBuilder()
+   *           .setParent(
+   *               AnalyzedSessionName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]")
+   *                   .toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (AnalyzedInvocation element :
+   *       agentAnomalyDetectionServiceClient.listAnalyzedInvocations(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAnalyzedInvocationsPagedResponse listAnalyzedInvocations( + ListAnalyzedInvocationsRequest request) { + return listAnalyzedInvocationsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListAnalyzedInvocationsRequest request =
+   *       ListAnalyzedInvocationsRequest.newBuilder()
+   *           .setParent(
+   *               AnalyzedSessionName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]")
+   *                   .toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient
+   *           .listAnalyzedInvocationsPagedCallable()
+   *           .futureCall(request);
+   *   // Do something.
+   *   for (AnalyzedInvocation element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listAnalyzedInvocationsPagedCallable() { + return stub.listAnalyzedInvocationsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListAnalyzedInvocationsRequest request =
+   *       ListAnalyzedInvocationsRequest.newBuilder()
+   *           .setParent(
+   *               AnalyzedSessionName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]")
+   *                   .toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     ListAnalyzedInvocationsResponse response =
+   *         agentAnomalyDetectionServiceClient.listAnalyzedInvocationsCallable().call(request);
+   *     for (AnalyzedInvocation element : response.getAnalyzedInvocationsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listAnalyzedInvocationsCallable() { + return stub.listAnalyzedInvocationsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AnalyzedInvocation. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   AnalyzedInvocationName name =
+   *       AnalyzedInvocationName.of(
+   *           "[PROJECT]",
+   *           "[LOCATION]",
+   *           "[MONITORED_AGENT]",
+   *           "[ANALYZED_SESSION]",
+   *           "[ANALYZED_INVOCATION]");
+   *   AnalyzedInvocation response = agentAnomalyDetectionServiceClient.getAnalyzedInvocation(name);
+   * }
+   * }
+ * + * @param name Required. The name of the AnalyzedInvocation resource. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AnalyzedInvocation getAnalyzedInvocation(@Nullable AnalyzedInvocationName name) { + GetAnalyzedInvocationRequest request = + GetAnalyzedInvocationRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getAnalyzedInvocation(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AnalyzedInvocation. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String name =
+   *       AnalyzedInvocationName.of(
+   *               "[PROJECT]",
+   *               "[LOCATION]",
+   *               "[MONITORED_AGENT]",
+   *               "[ANALYZED_SESSION]",
+   *               "[ANALYZED_INVOCATION]")
+   *           .toString();
+   *   AnalyzedInvocation response = agentAnomalyDetectionServiceClient.getAnalyzedInvocation(name);
+   * }
+   * }
+ * + * @param name Required. The name of the AnalyzedInvocation resource. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AnalyzedInvocation getAnalyzedInvocation(String name) { + GetAnalyzedInvocationRequest request = + GetAnalyzedInvocationRequest.newBuilder().setName(name).build(); + return getAnalyzedInvocation(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AnalyzedInvocation. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetAnalyzedInvocationRequest request =
+   *       GetAnalyzedInvocationRequest.newBuilder()
+   *           .setName(
+   *               AnalyzedInvocationName.of(
+   *                       "[PROJECT]",
+   *                       "[LOCATION]",
+   *                       "[MONITORED_AGENT]",
+   *                       "[ANALYZED_SESSION]",
+   *                       "[ANALYZED_INVOCATION]")
+   *                   .toString())
+   *           .build();
+   *   AnalyzedInvocation response =
+   *       agentAnomalyDetectionServiceClient.getAnalyzedInvocation(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AnalyzedInvocation getAnalyzedInvocation(GetAnalyzedInvocationRequest request) { + return getAnalyzedInvocationCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the details of a specific AnalyzedInvocation. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetAnalyzedInvocationRequest request =
+   *       GetAnalyzedInvocationRequest.newBuilder()
+   *           .setName(
+   *               AnalyzedInvocationName.of(
+   *                       "[PROJECT]",
+   *                       "[LOCATION]",
+   *                       "[MONITORED_AGENT]",
+   *                       "[ANALYZED_SESSION]",
+   *                       "[ANALYZED_INVOCATION]")
+   *                   .toString())
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.getAnalyzedInvocationCallable().futureCall(request);
+   *   // Do something.
+   *   AnalyzedInvocation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + getAnalyzedInvocationCallable() { + return stub.getAnalyzedInvocationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Aggregates AnalyzedSessions across MonitoredAgents. + * + *

To aggregate across all MonitoredAgents in a location, use the following format for the + * parent field: `projects/{project}/locations/{location}/monitoredAgents/-` + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   MonitoredAgentName parent =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]");
+   *   for (AggregateAnalyzedSessionsResponse.AgentAggregate element :
+   *       agentAnomalyDetectionServiceClient.aggregateAnalyzedSessions(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent MonitoredAgent resource. Use the `-` wildcard for the + * monitored_agent segment to aggregate across multiple agents in the location. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AggregateAnalyzedSessionsPagedResponse aggregateAnalyzedSessions( + @Nullable MonitoredAgentName parent) { + AggregateAnalyzedSessionsRequest request = + AggregateAnalyzedSessionsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return aggregateAnalyzedSessions(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Aggregates AnalyzedSessions across MonitoredAgents. + * + *

To aggregate across all MonitoredAgents in a location, use the following format for the + * parent field: `projects/{project}/locations/{location}/monitoredAgents/-` + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String parent =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString();
+   *   for (AggregateAnalyzedSessionsResponse.AgentAggregate element :
+   *       agentAnomalyDetectionServiceClient.aggregateAnalyzedSessions(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent MonitoredAgent resource. Use the `-` wildcard for the + * monitored_agent segment to aggregate across multiple agents in the location. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AggregateAnalyzedSessionsPagedResponse aggregateAnalyzedSessions(String parent) { + AggregateAnalyzedSessionsRequest request = + AggregateAnalyzedSessionsRequest.newBuilder().setParent(parent).build(); + return aggregateAnalyzedSessions(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Aggregates AnalyzedSessions across MonitoredAgents. + * + *

To aggregate across all MonitoredAgents in a location, use the following format for the + * parent field: `projects/{project}/locations/{location}/monitoredAgents/-` + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   AggregateAnalyzedSessionsRequest request =
+   *       AggregateAnalyzedSessionsRequest.newBuilder()
+   *           .setParent(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (AggregateAnalyzedSessionsResponse.AgentAggregate element :
+   *       agentAnomalyDetectionServiceClient.aggregateAnalyzedSessions(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final AggregateAnalyzedSessionsPagedResponse aggregateAnalyzedSessions( + AggregateAnalyzedSessionsRequest request) { + return aggregateAnalyzedSessionsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Aggregates AnalyzedSessions across MonitoredAgents. + * + *

To aggregate across all MonitoredAgents in a location, use the following format for the + * parent field: `projects/{project}/locations/{location}/monitoredAgents/-` + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   AggregateAnalyzedSessionsRequest request =
+   *       AggregateAnalyzedSessionsRequest.newBuilder()
+   *           .setParent(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient
+   *           .aggregateAnalyzedSessionsPagedCallable()
+   *           .futureCall(request);
+   *   // Do something.
+   *   for (AggregateAnalyzedSessionsResponse.AgentAggregate element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable< + AggregateAnalyzedSessionsRequest, AggregateAnalyzedSessionsPagedResponse> + aggregateAnalyzedSessionsPagedCallable() { + return stub.aggregateAnalyzedSessionsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Aggregates AnalyzedSessions across MonitoredAgents. + * + *

To aggregate across all MonitoredAgents in a location, use the following format for the + * parent field: `projects/{project}/locations/{location}/monitoredAgents/-` + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   AggregateAnalyzedSessionsRequest request =
+   *       AggregateAnalyzedSessionsRequest.newBuilder()
+   *           .setParent(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     AggregateAnalyzedSessionsResponse response =
+   *         agentAnomalyDetectionServiceClient.aggregateAnalyzedSessionsCallable().call(request);
+   *     for (AggregateAnalyzedSessionsResponse.AgentAggregate element :
+   *         response.getAgentAggregatesList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + aggregateAnalyzedSessionsCallable() { + return stub.aggregateAnalyzedSessionsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Clears (purges) the trained model artifacts derived from a MonitoredAgent's data. The purged + * model is rebuilt by the next scheduled training run. + * + *

To clear every MonitoredAgent in a location's scope, use the `-` wildcard agent segment for + * the name field: `projects/{project}/locations/{location}/monitoredAgents/-` + * + *

This is the on-demand data-deletion path for customers who have deleted the underlying logs + * / observability data a model was trained on. It deletes only the derived model artifacts (it + * does NOT delete the scope or stop monitoring). To stop monitoring an agent entirely, disable it + * via DisableMonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   MonitoredAgentName name =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]");
+   *   ClearTrainingDataResponse response =
+   *       agentAnomalyDetectionServiceClient.clearTrainingDataAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The MonitoredAgent whose trained model artifacts to purge. Use the `-` + * wildcard agent segment to purge every MonitoredAgent in the scope. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + clearTrainingDataAsync(@Nullable MonitoredAgentName name) { + ClearTrainingDataRequest request = + ClearTrainingDataRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return clearTrainingDataAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Clears (purges) the trained model artifacts derived from a MonitoredAgent's data. The purged + * model is rebuilt by the next scheduled training run. + * + *

To clear every MonitoredAgent in a location's scope, use the `-` wildcard agent segment for + * the name field: `projects/{project}/locations/{location}/monitoredAgents/-` + * + *

This is the on-demand data-deletion path for customers who have deleted the underlying logs + * / observability data a model was trained on. It deletes only the derived model artifacts (it + * does NOT delete the scope or stop monitoring). To stop monitoring an agent entirely, disable it + * via DisableMonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   String name =
+   *       MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString();
+   *   ClearTrainingDataResponse response =
+   *       agentAnomalyDetectionServiceClient.clearTrainingDataAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The MonitoredAgent whose trained model artifacts to purge. Use the `-` + * wildcard agent segment to purge every MonitoredAgent in the scope. Format: + * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + clearTrainingDataAsync(String name) { + ClearTrainingDataRequest request = ClearTrainingDataRequest.newBuilder().setName(name).build(); + return clearTrainingDataAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Clears (purges) the trained model artifacts derived from a MonitoredAgent's data. The purged + * model is rebuilt by the next scheduled training run. + * + *

To clear every MonitoredAgent in a location's scope, use the `-` wildcard agent segment for + * the name field: `projects/{project}/locations/{location}/monitoredAgents/-` + * + *

This is the on-demand data-deletion path for customers who have deleted the underlying logs + * / observability data a model was trained on. It deletes only the derived model artifacts (it + * does NOT delete the scope or stop monitoring). To stop monitoring an agent entirely, disable it + * via DisableMonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ClearTrainingDataRequest request =
+   *       ClearTrainingDataRequest.newBuilder()
+   *           .setName(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .build();
+   *   ClearTrainingDataResponse response =
+   *       agentAnomalyDetectionServiceClient.clearTrainingDataAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + clearTrainingDataAsync(ClearTrainingDataRequest request) { + return clearTrainingDataOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Clears (purges) the trained model artifacts derived from a MonitoredAgent's data. The purged + * model is rebuilt by the next scheduled training run. + * + *

To clear every MonitoredAgent in a location's scope, use the `-` wildcard agent segment for + * the name field: `projects/{project}/locations/{location}/monitoredAgents/-` + * + *

This is the on-demand data-deletion path for customers who have deleted the underlying logs + * / observability data a model was trained on. It deletes only the derived model artifacts (it + * does NOT delete the scope or stop monitoring). To stop monitoring an agent entirely, disable it + * via DisableMonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ClearTrainingDataRequest request =
+   *       ClearTrainingDataRequest.newBuilder()
+   *           .setName(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .build();
+   *   OperationFuture future =
+   *       agentAnomalyDetectionServiceClient
+   *           .clearTrainingDataOperationCallable()
+   *           .futureCall(request);
+   *   // Do something.
+   *   ClearTrainingDataResponse response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable< + ClearTrainingDataRequest, ClearTrainingDataResponse, ClearTrainingDataOperationMetadata> + clearTrainingDataOperationCallable() { + return stub.clearTrainingDataOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Clears (purges) the trained model artifacts derived from a MonitoredAgent's data. The purged + * model is rebuilt by the next scheduled training run. + * + *

To clear every MonitoredAgent in a location's scope, use the `-` wildcard agent segment for + * the name field: `projects/{project}/locations/{location}/monitoredAgents/-` + * + *

This is the on-demand data-deletion path for customers who have deleted the underlying logs + * / observability data a model was trained on. It deletes only the derived model artifacts (it + * does NOT delete the scope or stop monitoring). To stop monitoring an agent entirely, disable it + * via DisableMonitoredAgent. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ClearTrainingDataRequest request =
+   *       ClearTrainingDataRequest.newBuilder()
+   *           .setName(
+   *               MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString())
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.clearTrainingDataCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable clearTrainingDataCallable() { + return stub.clearTrainingDataCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (Location element :
+   *       agentAnomalyDetectionServiceClient.listLocations(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListLocationsPagedResponse listLocations(ListLocationsRequest request) { + return listLocationsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.listLocationsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Location element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listLocationsPagedCallable() { + return stub.listLocationsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     ListLocationsResponse response =
+   *         agentAnomalyDetectionServiceClient.listLocationsCallable().call(request);
+   *     for (Location element : response.getLocationsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listLocationsCallable() { + return stub.listLocationsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets information about a location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
+   *   Location response = agentAnomalyDetectionServiceClient.getLocation(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Location getLocation(GetLocationRequest request) { + return getLocationCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets information about a location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.getLocationCallable().futureCall(request);
+   *   // Do something.
+   *   Location response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getLocationCallable() { + return stub.getLocationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Sets the access control policy on the specified resource. Replacesany existing policy. + * + *

Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`errors. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   SetIamPolicyRequest request =
+   *       SetIamPolicyRequest.newBuilder()
+   *           .setResource(
+   *               EndpointName.ofProjectLocationEndpointName(
+   *                       "[PROJECT]", "[LOCATION]", "[ENDPOINT]")
+   *                   .toString())
+   *           .setPolicy(Policy.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   Policy response = agentAnomalyDetectionServiceClient.setIamPolicy(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Policy setIamPolicy(SetIamPolicyRequest request) { + return setIamPolicyCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Sets the access control policy on the specified resource. Replacesany existing policy. + * + *

Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`errors. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   SetIamPolicyRequest request =
+   *       SetIamPolicyRequest.newBuilder()
+   *           .setResource(
+   *               EndpointName.ofProjectLocationEndpointName(
+   *                       "[PROJECT]", "[LOCATION]", "[ENDPOINT]")
+   *                   .toString())
+   *           .setPolicy(Policy.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.setIamPolicyCallable().futureCall(request);
+   *   // Do something.
+   *   Policy response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable setIamPolicyCallable() { + return stub.setIamPolicyCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the access control policy for a resource. Returns an empty policyif the resource exists + * and does not have a policy set. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetIamPolicyRequest request =
+   *       GetIamPolicyRequest.newBuilder()
+   *           .setResource(
+   *               EndpointName.ofProjectLocationEndpointName(
+   *                       "[PROJECT]", "[LOCATION]", "[ENDPOINT]")
+   *                   .toString())
+   *           .setOptions(GetPolicyOptions.newBuilder().build())
+   *           .build();
+   *   Policy response = agentAnomalyDetectionServiceClient.getIamPolicy(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Policy getIamPolicy(GetIamPolicyRequest request) { + return getIamPolicyCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the access control policy for a resource. Returns an empty policyif the resource exists + * and does not have a policy set. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   GetIamPolicyRequest request =
+   *       GetIamPolicyRequest.newBuilder()
+   *           .setResource(
+   *               EndpointName.ofProjectLocationEndpointName(
+   *                       "[PROJECT]", "[LOCATION]", "[ENDPOINT]")
+   *                   .toString())
+   *           .setOptions(GetPolicyOptions.newBuilder().build())
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.getIamPolicyCallable().futureCall(request);
+   *   // Do something.
+   *   Policy response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getIamPolicyCallable() { + return stub.getIamPolicyCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns permissions that a caller has on the specified resource. If theresource does not exist, + * this will return an empty set ofpermissions, not a `NOT_FOUND` error. + * + *

Note: This operation is designed to be used for buildingpermission-aware UIs and + * command-line tools, not for authorizationchecking. This operation may "fail open" without + * warning. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   TestIamPermissionsRequest request =
+   *       TestIamPermissionsRequest.newBuilder()
+   *           .setResource(
+   *               EndpointName.ofProjectLocationEndpointName(
+   *                       "[PROJECT]", "[LOCATION]", "[ENDPOINT]")
+   *                   .toString())
+   *           .addAllPermissions(new ArrayList())
+   *           .build();
+   *   TestIamPermissionsResponse response =
+   *       agentAnomalyDetectionServiceClient.testIamPermissions(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsRequest request) { + return testIamPermissionsCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns permissions that a caller has on the specified resource. If theresource does not exist, + * this will return an empty set ofpermissions, not a `NOT_FOUND` error. + * + *

Note: This operation is designed to be used for buildingpermission-aware UIs and + * command-line tools, not for authorizationchecking. This operation may "fail open" without + * warning. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+   *     AgentAnomalyDetectionServiceClient.create()) {
+   *   TestIamPermissionsRequest request =
+   *       TestIamPermissionsRequest.newBuilder()
+   *           .setResource(
+   *               EndpointName.ofProjectLocationEndpointName(
+   *                       "[PROJECT]", "[LOCATION]", "[ENDPOINT]")
+   *                   .toString())
+   *           .addAllPermissions(new ArrayList())
+   *           .build();
+   *   ApiFuture future =
+   *       agentAnomalyDetectionServiceClient.testIamPermissionsCallable().futureCall(request);
+   *   // Do something.
+   *   TestIamPermissionsResponse response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + testIamPermissionsCallable() { + return stub.testIamPermissionsCallable(); + } + + @Override + public final void close() { + stub.close(); + } + + @Override + public void shutdown() { + stub.shutdown(); + } + + @Override + public boolean isShutdown() { + return stub.isShutdown(); + } + + @Override + public boolean isTerminated() { + return stub.isTerminated(); + } + + @Override + public void shutdownNow() { + stub.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return stub.awaitTermination(duration, unit); + } + + public static class ListMonitoredAgentsPagedResponse + extends AbstractPagedListResponse< + ListMonitoredAgentsRequest, + ListMonitoredAgentsResponse, + MonitoredAgent, + ListMonitoredAgentsPage, + ListMonitoredAgentsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListMonitoredAgentsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListMonitoredAgentsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListMonitoredAgentsPagedResponse(ListMonitoredAgentsPage page) { + super(page, ListMonitoredAgentsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListMonitoredAgentsPage + extends AbstractPage< + ListMonitoredAgentsRequest, + ListMonitoredAgentsResponse, + MonitoredAgent, + ListMonitoredAgentsPage> { + + private ListMonitoredAgentsPage( + @Nullable + PageContext + context, + @Nullable ListMonitoredAgentsResponse response) { + super(context, response); + } + + private static ListMonitoredAgentsPage createEmptyPage() { + return new ListMonitoredAgentsPage(null, null); + } + + @Override + protected ListMonitoredAgentsPage createPage( + @Nullable + PageContext + context, + @Nullable ListMonitoredAgentsResponse response) { + return new ListMonitoredAgentsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable + PageContext + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListMonitoredAgentsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListMonitoredAgentsRequest, + ListMonitoredAgentsResponse, + MonitoredAgent, + ListMonitoredAgentsPage, + ListMonitoredAgentsFixedSizeCollection> { + + private ListMonitoredAgentsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListMonitoredAgentsFixedSizeCollection createEmptyCollection() { + return new ListMonitoredAgentsFixedSizeCollection(null, 0); + } + + @Override + protected ListMonitoredAgentsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListMonitoredAgentsFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListAgentAnomalyDetectionScopesPagedResponse + extends AbstractPagedListResponse< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + AgentAnomalyDetectionScope, + ListAgentAnomalyDetectionScopesPage, + ListAgentAnomalyDetectionScopesFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + AgentAnomalyDetectionScope> + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListAgentAnomalyDetectionScopesPage.createEmptyPage() + .createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListAgentAnomalyDetectionScopesPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListAgentAnomalyDetectionScopesPagedResponse(ListAgentAnomalyDetectionScopesPage page) { + super(page, ListAgentAnomalyDetectionScopesFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListAgentAnomalyDetectionScopesPage + extends AbstractPage< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + AgentAnomalyDetectionScope, + ListAgentAnomalyDetectionScopesPage> { + + private ListAgentAnomalyDetectionScopesPage( + @Nullable + PageContext< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + AgentAnomalyDetectionScope> + context, + @Nullable ListAgentAnomalyDetectionScopesResponse response) { + super(context, response); + } + + private static ListAgentAnomalyDetectionScopesPage createEmptyPage() { + return new ListAgentAnomalyDetectionScopesPage(null, null); + } + + @Override + protected ListAgentAnomalyDetectionScopesPage createPage( + @Nullable + PageContext< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + AgentAnomalyDetectionScope> + context, + @Nullable ListAgentAnomalyDetectionScopesResponse response) { + return new ListAgentAnomalyDetectionScopesPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable + PageContext< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + AgentAnomalyDetectionScope> + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListAgentAnomalyDetectionScopesFixedSizeCollection + extends AbstractFixedSizeCollection< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + AgentAnomalyDetectionScope, + ListAgentAnomalyDetectionScopesPage, + ListAgentAnomalyDetectionScopesFixedSizeCollection> { + + private ListAgentAnomalyDetectionScopesFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListAgentAnomalyDetectionScopesFixedSizeCollection createEmptyCollection() { + return new ListAgentAnomalyDetectionScopesFixedSizeCollection(null, 0); + } + + @Override + protected ListAgentAnomalyDetectionScopesFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListAgentAnomalyDetectionScopesFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListAnalyzedSessionsPagedResponse + extends AbstractPagedListResponse< + ListAnalyzedSessionsRequest, + ListAnalyzedSessionsResponse, + AnalyzedSession, + ListAnalyzedSessionsPage, + ListAnalyzedSessionsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListAnalyzedSessionsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListAnalyzedSessionsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListAnalyzedSessionsPagedResponse(ListAnalyzedSessionsPage page) { + super(page, ListAnalyzedSessionsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListAnalyzedSessionsPage + extends AbstractPage< + ListAnalyzedSessionsRequest, + ListAnalyzedSessionsResponse, + AnalyzedSession, + ListAnalyzedSessionsPage> { + + private ListAnalyzedSessionsPage( + @Nullable + PageContext + context, + @Nullable ListAnalyzedSessionsResponse response) { + super(context, response); + } + + private static ListAnalyzedSessionsPage createEmptyPage() { + return new ListAnalyzedSessionsPage(null, null); + } + + @Override + protected ListAnalyzedSessionsPage createPage( + @Nullable + PageContext + context, + @Nullable ListAnalyzedSessionsResponse response) { + return new ListAnalyzedSessionsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable + PageContext + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListAnalyzedSessionsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListAnalyzedSessionsRequest, + ListAnalyzedSessionsResponse, + AnalyzedSession, + ListAnalyzedSessionsPage, + ListAnalyzedSessionsFixedSizeCollection> { + + private ListAnalyzedSessionsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListAnalyzedSessionsFixedSizeCollection createEmptyCollection() { + return new ListAnalyzedSessionsFixedSizeCollection(null, 0); + } + + @Override + protected ListAnalyzedSessionsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListAnalyzedSessionsFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListAnalyzedInvocationsPagedResponse + extends AbstractPagedListResponse< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + AnalyzedInvocation, + ListAnalyzedInvocationsPage, + ListAnalyzedInvocationsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext< + ListAnalyzedInvocationsRequest, ListAnalyzedInvocationsResponse, AnalyzedInvocation> + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListAnalyzedInvocationsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListAnalyzedInvocationsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListAnalyzedInvocationsPagedResponse(ListAnalyzedInvocationsPage page) { + super(page, ListAnalyzedInvocationsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListAnalyzedInvocationsPage + extends AbstractPage< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + AnalyzedInvocation, + ListAnalyzedInvocationsPage> { + + private ListAnalyzedInvocationsPage( + @Nullable + PageContext< + ListAnalyzedInvocationsRequest, ListAnalyzedInvocationsResponse, AnalyzedInvocation> + context, + @Nullable ListAnalyzedInvocationsResponse response) { + super(context, response); + } + + private static ListAnalyzedInvocationsPage createEmptyPage() { + return new ListAnalyzedInvocationsPage(null, null); + } + + @Override + protected ListAnalyzedInvocationsPage createPage( + @Nullable + PageContext< + ListAnalyzedInvocationsRequest, ListAnalyzedInvocationsResponse, AnalyzedInvocation> + context, + @Nullable ListAnalyzedInvocationsResponse response) { + return new ListAnalyzedInvocationsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable + PageContext< + ListAnalyzedInvocationsRequest, ListAnalyzedInvocationsResponse, AnalyzedInvocation> + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListAnalyzedInvocationsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + AnalyzedInvocation, + ListAnalyzedInvocationsPage, + ListAnalyzedInvocationsFixedSizeCollection> { + + private ListAnalyzedInvocationsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListAnalyzedInvocationsFixedSizeCollection createEmptyCollection() { + return new ListAnalyzedInvocationsFixedSizeCollection(null, 0); + } + + @Override + protected ListAnalyzedInvocationsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListAnalyzedInvocationsFixedSizeCollection(pages, collectionSize); + } + } + + public static class AggregateAnalyzedSessionsPagedResponse + extends AbstractPagedListResponse< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsResponse.AgentAggregate, + AggregateAnalyzedSessionsPage, + AggregateAnalyzedSessionsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsResponse.AgentAggregate> + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + AggregateAnalyzedSessionsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new AggregateAnalyzedSessionsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private AggregateAnalyzedSessionsPagedResponse(AggregateAnalyzedSessionsPage page) { + super(page, AggregateAnalyzedSessionsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class AggregateAnalyzedSessionsPage + extends AbstractPage< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsResponse.AgentAggregate, + AggregateAnalyzedSessionsPage> { + + private AggregateAnalyzedSessionsPage( + @Nullable + PageContext< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsResponse.AgentAggregate> + context, + @Nullable AggregateAnalyzedSessionsResponse response) { + super(context, response); + } + + private static AggregateAnalyzedSessionsPage createEmptyPage() { + return new AggregateAnalyzedSessionsPage(null, null); + } + + @Override + protected AggregateAnalyzedSessionsPage createPage( + @Nullable + PageContext< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsResponse.AgentAggregate> + context, + @Nullable AggregateAnalyzedSessionsResponse response) { + return new AggregateAnalyzedSessionsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable + PageContext< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsResponse.AgentAggregate> + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class AggregateAnalyzedSessionsFixedSizeCollection + extends AbstractFixedSizeCollection< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsResponse.AgentAggregate, + AggregateAnalyzedSessionsPage, + AggregateAnalyzedSessionsFixedSizeCollection> { + + private AggregateAnalyzedSessionsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static AggregateAnalyzedSessionsFixedSizeCollection createEmptyCollection() { + return new AggregateAnalyzedSessionsFixedSizeCollection(null, 0); + } + + @Override + protected AggregateAnalyzedSessionsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new AggregateAnalyzedSessionsFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListLocationsPagedResponse + extends AbstractPagedListResponse< + ListLocationsRequest, + ListLocationsResponse, + Location, + ListLocationsPage, + ListLocationsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListLocationsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListLocationsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListLocationsPagedResponse(ListLocationsPage page) { + super(page, ListLocationsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListLocationsPage + extends AbstractPage< + ListLocationsRequest, ListLocationsResponse, Location, ListLocationsPage> { + + private ListLocationsPage( + @Nullable PageContext context, + @Nullable ListLocationsResponse response) { + super(context, response); + } + + private static ListLocationsPage createEmptyPage() { + return new ListLocationsPage(null, null); + } + + @Override + protected ListLocationsPage createPage( + @Nullable PageContext context, + @Nullable ListLocationsResponse response) { + return new ListLocationsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListLocationsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListLocationsRequest, + ListLocationsResponse, + Location, + ListLocationsPage, + ListLocationsFixedSizeCollection> { + + private ListLocationsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListLocationsFixedSizeCollection createEmptyCollection() { + return new ListLocationsFixedSizeCollection(null, 0); + } + + @Override + protected ListLocationsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListLocationsFixedSizeCollection(pages, collectionSize); + } + } +} diff --git a/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceSettings.java b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceSettings.java new file mode 100644 index 000000000000..f56e97207c49 --- /dev/null +++ b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceSettings.java @@ -0,0 +1,586 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1; + +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.AggregateAnalyzedSessionsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAgentAnomalyDetectionScopesPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAnalyzedInvocationsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAnalyzedSessionsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListLocationsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListMonitoredAgentsPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientSettings; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.cloud.aiplatform.v1.stub.AgentAnomalyDetectionServiceStubSettings; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.protobuf.Empty; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link AgentAnomalyDetectionServiceClient}. + * + *

The default instance has everything set to sensible defaults: + * + *

    + *
  • The default service address (aiplatform.googleapis.com) and default port (443) are used. + *
  • Credentials are acquired automatically through Application Default Credentials. + *
  • Retries are configured for idempotent methods but not for non-idempotent methods. + *
+ * + *

The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. + * + *

For example, to set the + * [RetrySettings](https://cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.retrying.RetrySettings) + * of getAgentAnomalyDetectionScope: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * AgentAnomalyDetectionServiceSettings.Builder agentAnomalyDetectionServiceSettingsBuilder =
+ *     AgentAnomalyDetectionServiceSettings.newBuilder();
+ * agentAnomalyDetectionServiceSettingsBuilder
+ *     .getAgentAnomalyDetectionScopeSettings()
+ *     .setRetrySettings(
+ *         agentAnomalyDetectionServiceSettingsBuilder
+ *             .getAgentAnomalyDetectionScopeSettings()
+ *             .getRetrySettings()
+ *             .toBuilder()
+ *             .setInitialRetryDelayDuration(Duration.ofSeconds(1))
+ *             .setInitialRpcTimeoutDuration(Duration.ofSeconds(5))
+ *             .setMaxAttempts(5)
+ *             .setMaxRetryDelayDuration(Duration.ofSeconds(30))
+ *             .setMaxRpcTimeoutDuration(Duration.ofSeconds(60))
+ *             .setRetryDelayMultiplier(1.3)
+ *             .setRpcTimeoutMultiplier(1.5)
+ *             .setTotalTimeoutDuration(Duration.ofSeconds(300))
+ *             .build());
+ * AgentAnomalyDetectionServiceSettings agentAnomalyDetectionServiceSettings =
+ *     agentAnomalyDetectionServiceSettingsBuilder.build();
+ * }
+ * + * Please refer to the [Client Side Retry + * Guide](https://docs.cloud.google.com/java/docs/client-retries) for additional support in setting + * retries. + * + *

To configure the RetrySettings of a Long Running Operation method, create an + * OperationTimedPollAlgorithm object and update the RPC's polling algorithm. For example, to + * configure the RetrySettings for enableMonitoredAgent: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * AgentAnomalyDetectionServiceSettings.Builder agentAnomalyDetectionServiceSettingsBuilder =
+ *     AgentAnomalyDetectionServiceSettings.newBuilder();
+ * TimedRetryAlgorithm timedRetryAlgorithm =
+ *     OperationalTimedPollAlgorithm.create(
+ *         RetrySettings.newBuilder()
+ *             .setInitialRetryDelayDuration(Duration.ofMillis(500))
+ *             .setRetryDelayMultiplier(1.5)
+ *             .setMaxRetryDelayDuration(Duration.ofMillis(5000))
+ *             .setTotalTimeoutDuration(Duration.ofHours(24))
+ *             .build());
+ * agentAnomalyDetectionServiceSettingsBuilder
+ *     .createClusterOperationSettings()
+ *     .setPollingAlgorithm(timedRetryAlgorithm)
+ *     .build();
+ * }
+ */ +@NullMarked +@Generated("by gapic-generator-java") +public class AgentAnomalyDetectionServiceSettings + extends ClientSettings { + + /** Returns the object with the settings used for calls to getAgentAnomalyDetectionScope. */ + public UnaryCallSettings + getAgentAnomalyDetectionScopeSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .getAgentAnomalyDetectionScopeSettings(); + } + + /** Returns the object with the settings used for calls to getMonitoredAgent. */ + public UnaryCallSettings getMonitoredAgentSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .getMonitoredAgentSettings(); + } + + /** Returns the object with the settings used for calls to listMonitoredAgents. */ + public PagedCallSettings< + ListMonitoredAgentsRequest, ListMonitoredAgentsResponse, ListMonitoredAgentsPagedResponse> + listMonitoredAgentsSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .listMonitoredAgentsSettings(); + } + + /** Returns the object with the settings used for calls to enableMonitoredAgent. */ + public UnaryCallSettings enableMonitoredAgentSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .enableMonitoredAgentSettings(); + } + + /** Returns the object with the settings used for calls to enableMonitoredAgent. */ + public OperationCallSettings< + EnableMonitoredAgentRequest, MonitoredAgent, EnableMonitoredAgentOperationMetadata> + enableMonitoredAgentOperationSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .enableMonitoredAgentOperationSettings(); + } + + /** Returns the object with the settings used for calls to disableMonitoredAgent. */ + public UnaryCallSettings + disableMonitoredAgentSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .disableMonitoredAgentSettings(); + } + + /** Returns the object with the settings used for calls to disableMonitoredAgent. */ + public OperationCallSettings< + DisableMonitoredAgentRequest, MonitoredAgent, DisableMonitoredAgentOperationMetadata> + disableMonitoredAgentOperationSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .disableMonitoredAgentOperationSettings(); + } + + /** Returns the object with the settings used for calls to deleteAgentAnomalyDetectionScope. */ + public UnaryCallSettings + deleteAgentAnomalyDetectionScopeSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .deleteAgentAnomalyDetectionScopeSettings(); + } + + /** Returns the object with the settings used for calls to deleteAgentAnomalyDetectionScope. */ + public OperationCallSettings< + DeleteAgentAnomalyDetectionScopeRequest, + Empty, + DeleteAgentAnomalyDetectionScopeOperationMetadata> + deleteAgentAnomalyDetectionScopeOperationSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .deleteAgentAnomalyDetectionScopeOperationSettings(); + } + + /** Returns the object with the settings used for calls to createAgentAnomalyDetectionScope. */ + public UnaryCallSettings + createAgentAnomalyDetectionScopeSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .createAgentAnomalyDetectionScopeSettings(); + } + + /** Returns the object with the settings used for calls to createAgentAnomalyDetectionScope. */ + public OperationCallSettings< + CreateAgentAnomalyDetectionScopeRequest, + AgentAnomalyDetectionScope, + CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeOperationSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .createAgentAnomalyDetectionScopeOperationSettings(); + } + + /** Returns the object with the settings used for calls to listAgentAnomalyDetectionScopes. */ + public PagedCallSettings< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + ListAgentAnomalyDetectionScopesPagedResponse> + listAgentAnomalyDetectionScopesSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .listAgentAnomalyDetectionScopesSettings(); + } + + /** Returns the object with the settings used for calls to listAnalyzedSessions. */ + public PagedCallSettings< + ListAnalyzedSessionsRequest, + ListAnalyzedSessionsResponse, + ListAnalyzedSessionsPagedResponse> + listAnalyzedSessionsSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .listAnalyzedSessionsSettings(); + } + + /** Returns the object with the settings used for calls to getAnalyzedSession. */ + public UnaryCallSettings + getAnalyzedSessionSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .getAnalyzedSessionSettings(); + } + + /** Returns the object with the settings used for calls to listAnalyzedInvocations. */ + public PagedCallSettings< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + ListAnalyzedInvocationsPagedResponse> + listAnalyzedInvocationsSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .listAnalyzedInvocationsSettings(); + } + + /** Returns the object with the settings used for calls to getAnalyzedInvocation. */ + public UnaryCallSettings + getAnalyzedInvocationSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .getAnalyzedInvocationSettings(); + } + + /** Returns the object with the settings used for calls to aggregateAnalyzedSessions. */ + public PagedCallSettings< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsPagedResponse> + aggregateAnalyzedSessionsSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .aggregateAnalyzedSessionsSettings(); + } + + /** Returns the object with the settings used for calls to clearTrainingData. */ + public UnaryCallSettings clearTrainingDataSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .clearTrainingDataSettings(); + } + + /** Returns the object with the settings used for calls to clearTrainingData. */ + public OperationCallSettings< + ClearTrainingDataRequest, ClearTrainingDataResponse, ClearTrainingDataOperationMetadata> + clearTrainingDataOperationSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .clearTrainingDataOperationSettings(); + } + + /** Returns the object with the settings used for calls to listLocations. */ + public PagedCallSettings + listLocationsSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()).listLocationsSettings(); + } + + /** Returns the object with the settings used for calls to getLocation. */ + public UnaryCallSettings getLocationSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()).getLocationSettings(); + } + + /** Returns the object with the settings used for calls to setIamPolicy. */ + public UnaryCallSettings setIamPolicySettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()).setIamPolicySettings(); + } + + /** Returns the object with the settings used for calls to getIamPolicy. */ + public UnaryCallSettings getIamPolicySettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()).getIamPolicySettings(); + } + + /** Returns the object with the settings used for calls to testIamPermissions. */ + public UnaryCallSettings + testIamPermissionsSettings() { + return ((AgentAnomalyDetectionServiceStubSettings) getStubSettings()) + .testIamPermissionsSettings(); + } + + public static final AgentAnomalyDetectionServiceSettings create( + AgentAnomalyDetectionServiceStubSettings stub) throws IOException { + return new AgentAnomalyDetectionServiceSettings.Builder(stub.toBuilder()).build(); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return AgentAnomalyDetectionServiceStubSettings.defaultExecutorProviderBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return AgentAnomalyDetectionServiceStubSettings.getDefaultEndpoint(); + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return AgentAnomalyDetectionServiceStubSettings.getDefaultServiceScopes(); + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return AgentAnomalyDetectionServiceStubSettings.defaultCredentialsProviderBuilder(); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return AgentAnomalyDetectionServiceStubSettings.defaultGrpcTransportProviderBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return AgentAnomalyDetectionServiceStubSettings.defaultTransportChannelProvider(); + } + + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return AgentAnomalyDetectionServiceStubSettings.defaultApiClientHeaderProviderBuilder(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(@Nullable ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected AgentAnomalyDetectionServiceSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + } + + /** Builder for AgentAnomalyDetectionServiceSettings. */ + public static class Builder + extends ClientSettings.Builder { + + protected Builder() throws IOException { + this(((ClientContext) null)); + } + + protected Builder(@Nullable ClientContext clientContext) { + super(AgentAnomalyDetectionServiceStubSettings.newBuilder(clientContext)); + } + + protected Builder(AgentAnomalyDetectionServiceSettings settings) { + super(settings.getStubSettings().toBuilder()); + } + + protected Builder(AgentAnomalyDetectionServiceStubSettings.Builder stubSettings) { + super(stubSettings); + } + + private static Builder createDefault() { + return new Builder(AgentAnomalyDetectionServiceStubSettings.newBuilder()); + } + + public AgentAnomalyDetectionServiceStubSettings.Builder getStubSettingsBuilder() { + return ((AgentAnomalyDetectionServiceStubSettings.Builder) getStubSettings()); + } + + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) { + super.applyToAllUnaryMethods( + getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); + return this; + } + + /** Returns the builder for the settings used for calls to getAgentAnomalyDetectionScope. */ + public UnaryCallSettings.Builder< + GetAgentAnomalyDetectionScopeRequest, AgentAnomalyDetectionScope> + getAgentAnomalyDetectionScopeSettings() { + return getStubSettingsBuilder().getAgentAnomalyDetectionScopeSettings(); + } + + /** Returns the builder for the settings used for calls to getMonitoredAgent. */ + public UnaryCallSettings.Builder + getMonitoredAgentSettings() { + return getStubSettingsBuilder().getMonitoredAgentSettings(); + } + + /** Returns the builder for the settings used for calls to listMonitoredAgents. */ + public PagedCallSettings.Builder< + ListMonitoredAgentsRequest, + ListMonitoredAgentsResponse, + ListMonitoredAgentsPagedResponse> + listMonitoredAgentsSettings() { + return getStubSettingsBuilder().listMonitoredAgentsSettings(); + } + + /** Returns the builder for the settings used for calls to enableMonitoredAgent. */ + public UnaryCallSettings.Builder + enableMonitoredAgentSettings() { + return getStubSettingsBuilder().enableMonitoredAgentSettings(); + } + + /** Returns the builder for the settings used for calls to enableMonitoredAgent. */ + public OperationCallSettings.Builder< + EnableMonitoredAgentRequest, MonitoredAgent, EnableMonitoredAgentOperationMetadata> + enableMonitoredAgentOperationSettings() { + return getStubSettingsBuilder().enableMonitoredAgentOperationSettings(); + } + + /** Returns the builder for the settings used for calls to disableMonitoredAgent. */ + public UnaryCallSettings.Builder + disableMonitoredAgentSettings() { + return getStubSettingsBuilder().disableMonitoredAgentSettings(); + } + + /** Returns the builder for the settings used for calls to disableMonitoredAgent. */ + public OperationCallSettings.Builder< + DisableMonitoredAgentRequest, MonitoredAgent, DisableMonitoredAgentOperationMetadata> + disableMonitoredAgentOperationSettings() { + return getStubSettingsBuilder().disableMonitoredAgentOperationSettings(); + } + + /** Returns the builder for the settings used for calls to deleteAgentAnomalyDetectionScope. */ + public UnaryCallSettings.Builder + deleteAgentAnomalyDetectionScopeSettings() { + return getStubSettingsBuilder().deleteAgentAnomalyDetectionScopeSettings(); + } + + /** Returns the builder for the settings used for calls to deleteAgentAnomalyDetectionScope. */ + public OperationCallSettings.Builder< + DeleteAgentAnomalyDetectionScopeRequest, + Empty, + DeleteAgentAnomalyDetectionScopeOperationMetadata> + deleteAgentAnomalyDetectionScopeOperationSettings() { + return getStubSettingsBuilder().deleteAgentAnomalyDetectionScopeOperationSettings(); + } + + /** Returns the builder for the settings used for calls to createAgentAnomalyDetectionScope. */ + public UnaryCallSettings.Builder + createAgentAnomalyDetectionScopeSettings() { + return getStubSettingsBuilder().createAgentAnomalyDetectionScopeSettings(); + } + + /** Returns the builder for the settings used for calls to createAgentAnomalyDetectionScope. */ + public OperationCallSettings.Builder< + CreateAgentAnomalyDetectionScopeRequest, + AgentAnomalyDetectionScope, + CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeOperationSettings() { + return getStubSettingsBuilder().createAgentAnomalyDetectionScopeOperationSettings(); + } + + /** Returns the builder for the settings used for calls to listAgentAnomalyDetectionScopes. */ + public PagedCallSettings.Builder< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + ListAgentAnomalyDetectionScopesPagedResponse> + listAgentAnomalyDetectionScopesSettings() { + return getStubSettingsBuilder().listAgentAnomalyDetectionScopesSettings(); + } + + /** Returns the builder for the settings used for calls to listAnalyzedSessions. */ + public PagedCallSettings.Builder< + ListAnalyzedSessionsRequest, + ListAnalyzedSessionsResponse, + ListAnalyzedSessionsPagedResponse> + listAnalyzedSessionsSettings() { + return getStubSettingsBuilder().listAnalyzedSessionsSettings(); + } + + /** Returns the builder for the settings used for calls to getAnalyzedSession. */ + public UnaryCallSettings.Builder + getAnalyzedSessionSettings() { + return getStubSettingsBuilder().getAnalyzedSessionSettings(); + } + + /** Returns the builder for the settings used for calls to listAnalyzedInvocations. */ + public PagedCallSettings.Builder< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + ListAnalyzedInvocationsPagedResponse> + listAnalyzedInvocationsSettings() { + return getStubSettingsBuilder().listAnalyzedInvocationsSettings(); + } + + /** Returns the builder for the settings used for calls to getAnalyzedInvocation. */ + public UnaryCallSettings.Builder + getAnalyzedInvocationSettings() { + return getStubSettingsBuilder().getAnalyzedInvocationSettings(); + } + + /** Returns the builder for the settings used for calls to aggregateAnalyzedSessions. */ + public PagedCallSettings.Builder< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsPagedResponse> + aggregateAnalyzedSessionsSettings() { + return getStubSettingsBuilder().aggregateAnalyzedSessionsSettings(); + } + + /** Returns the builder for the settings used for calls to clearTrainingData. */ + public UnaryCallSettings.Builder + clearTrainingDataSettings() { + return getStubSettingsBuilder().clearTrainingDataSettings(); + } + + /** Returns the builder for the settings used for calls to clearTrainingData. */ + public OperationCallSettings.Builder< + ClearTrainingDataRequest, ClearTrainingDataResponse, ClearTrainingDataOperationMetadata> + clearTrainingDataOperationSettings() { + return getStubSettingsBuilder().clearTrainingDataOperationSettings(); + } + + /** Returns the builder for the settings used for calls to listLocations. */ + public PagedCallSettings.Builder< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings() { + return getStubSettingsBuilder().listLocationsSettings(); + } + + /** Returns the builder for the settings used for calls to getLocation. */ + public UnaryCallSettings.Builder getLocationSettings() { + return getStubSettingsBuilder().getLocationSettings(); + } + + /** Returns the builder for the settings used for calls to setIamPolicy. */ + public UnaryCallSettings.Builder setIamPolicySettings() { + return getStubSettingsBuilder().setIamPolicySettings(); + } + + /** Returns the builder for the settings used for calls to getIamPolicy. */ + public UnaryCallSettings.Builder getIamPolicySettings() { + return getStubSettingsBuilder().getIamPolicySettings(); + } + + /** Returns the builder for the settings used for calls to testIamPermissions. */ + public UnaryCallSettings.Builder + testIamPermissionsSettings() { + return getStubSettingsBuilder().testIamPermissionsSettings(); + } + + @Override + public AgentAnomalyDetectionServiceSettings build() throws IOException { + return new AgentAnomalyDetectionServiceSettings(this); + } + } +} diff --git a/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/gapic_metadata.json b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/gapic_metadata.json index 8217c36771ea..a0e01eef80d1 100644 --- a/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/gapic_metadata.json +++ b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/gapic_metadata.json @@ -5,6 +5,72 @@ "protoPackage": "google.cloud.aiplatform.v1", "libraryPackage": "com.google.cloud.aiplatform.v1", "services": { + "AgentAnomalyDetectionService": { + "clients": { + "grpc": { + "libraryClient": "AgentAnomalyDetectionServiceClient", + "rpcs": { + "AggregateAnalyzedSessions": { + "methods": ["aggregateAnalyzedSessions", "aggregateAnalyzedSessions", "aggregateAnalyzedSessions", "aggregateAnalyzedSessionsPagedCallable", "aggregateAnalyzedSessionsCallable"] + }, + "ClearTrainingData": { + "methods": ["clearTrainingDataAsync", "clearTrainingDataAsync", "clearTrainingDataAsync", "clearTrainingDataOperationCallable", "clearTrainingDataCallable"] + }, + "CreateAgentAnomalyDetectionScope": { + "methods": ["createAgentAnomalyDetectionScopeAsync", "createAgentAnomalyDetectionScopeAsync", "createAgentAnomalyDetectionScopeAsync", "createAgentAnomalyDetectionScopeOperationCallable", "createAgentAnomalyDetectionScopeCallable"] + }, + "DeleteAgentAnomalyDetectionScope": { + "methods": ["deleteAgentAnomalyDetectionScopeAsync", "deleteAgentAnomalyDetectionScopeAsync", "deleteAgentAnomalyDetectionScopeAsync", "deleteAgentAnomalyDetectionScopeOperationCallable", "deleteAgentAnomalyDetectionScopeCallable"] + }, + "DisableMonitoredAgent": { + "methods": ["disableMonitoredAgentAsync", "disableMonitoredAgentAsync", "disableMonitoredAgentAsync", "disableMonitoredAgentOperationCallable", "disableMonitoredAgentCallable"] + }, + "EnableMonitoredAgent": { + "methods": ["enableMonitoredAgentAsync", "enableMonitoredAgentAsync", "enableMonitoredAgentAsync", "enableMonitoredAgentOperationCallable", "enableMonitoredAgentCallable"] + }, + "GetAgentAnomalyDetectionScope": { + "methods": ["getAgentAnomalyDetectionScope", "getAgentAnomalyDetectionScope", "getAgentAnomalyDetectionScope", "getAgentAnomalyDetectionScopeCallable"] + }, + "GetAnalyzedInvocation": { + "methods": ["getAnalyzedInvocation", "getAnalyzedInvocation", "getAnalyzedInvocation", "getAnalyzedInvocationCallable"] + }, + "GetAnalyzedSession": { + "methods": ["getAnalyzedSession", "getAnalyzedSession", "getAnalyzedSession", "getAnalyzedSessionCallable"] + }, + "GetIamPolicy": { + "methods": ["getIamPolicy", "getIamPolicyCallable"] + }, + "GetLocation": { + "methods": ["getLocation", "getLocationCallable"] + }, + "GetMonitoredAgent": { + "methods": ["getMonitoredAgent", "getMonitoredAgent", "getMonitoredAgent", "getMonitoredAgentCallable"] + }, + "ListAgentAnomalyDetectionScopes": { + "methods": ["listAgentAnomalyDetectionScopes", "listAgentAnomalyDetectionScopes", "listAgentAnomalyDetectionScopes", "listAgentAnomalyDetectionScopesPagedCallable", "listAgentAnomalyDetectionScopesCallable"] + }, + "ListAnalyzedInvocations": { + "methods": ["listAnalyzedInvocations", "listAnalyzedInvocations", "listAnalyzedInvocations", "listAnalyzedInvocationsPagedCallable", "listAnalyzedInvocationsCallable"] + }, + "ListAnalyzedSessions": { + "methods": ["listAnalyzedSessions", "listAnalyzedSessions", "listAnalyzedSessions", "listAnalyzedSessionsPagedCallable", "listAnalyzedSessionsCallable"] + }, + "ListLocations": { + "methods": ["listLocations", "listLocationsPagedCallable", "listLocationsCallable"] + }, + "ListMonitoredAgents": { + "methods": ["listMonitoredAgents", "listMonitoredAgents", "listMonitoredAgents", "listMonitoredAgentsPagedCallable", "listMonitoredAgentsCallable"] + }, + "SetIamPolicy": { + "methods": ["setIamPolicy", "setIamPolicyCallable"] + }, + "TestIamPermissions": { + "methods": ["testIamPermissions", "testIamPermissionsCallable"] + } + } + } + } + }, "DataFoundryService": { "clients": { "grpc": { diff --git a/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/package-info.java b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/package-info.java index b0a311800021..d01cd1a2240b 100644 --- a/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/package-info.java +++ b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/package-info.java @@ -19,6 +19,28 @@ * *

The interfaces provided are listed below, along with usage samples. * + *

======================= AgentAnomalyDetectionServiceClient ======================= + * + *

Service Description: A service for managing Agent Anomaly Detection for monitored agents. + * + *

Sample for AgentAnomalyDetectionServiceClient: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient =
+ *     AgentAnomalyDetectionServiceClient.create()) {
+ *   AgentAnomalyDetectionScopeName name =
+ *       AgentAnomalyDetectionScopeName.of(
+ *           "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]");
+ *   AgentAnomalyDetectionScope response =
+ *       agentAnomalyDetectionServiceClient.getAgentAnomalyDetectionScope(name);
+ * }
+ * }
+ * *

======================= DataFoundryServiceClient ======================= * *

Service Description: Service for generating and preparing datasets for Gen AI evaluation. diff --git a/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/AgentAnomalyDetectionServiceStub.java b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/AgentAnomalyDetectionServiceStub.java new file mode 100644 index 000000000000..10004dc66e80 --- /dev/null +++ b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/AgentAnomalyDetectionServiceStub.java @@ -0,0 +1,254 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.stub; + +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.AggregateAnalyzedSessionsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAgentAnomalyDetectionScopesPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAnalyzedInvocationsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAnalyzedSessionsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListLocationsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListMonitoredAgentsPagedResponse; + +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata; +import com.google.cloud.aiplatform.v1.ClearTrainingDataRequest; +import com.google.cloud.aiplatform.v1.ClearTrainingDataResponse; +import com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata; +import com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata; +import com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata; +import com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata; +import com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest; +import com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest; +import com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest; +import com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse; +import com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest; +import com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse; +import com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest; +import com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.OperationsStub; +import com.google.protobuf.Empty; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Base stub class for the AgentAnomalyDetectionService service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@NullMarked +@Generated("by gapic-generator-java") +public abstract class AgentAnomalyDetectionServiceStub implements BackgroundResource { + + public @Nullable OperationsStub getOperationsStub() { + throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); + } + + public UnaryCallable + getAgentAnomalyDetectionScopeCallable() { + throw new UnsupportedOperationException( + "Not implemented: getAgentAnomalyDetectionScopeCallable()"); + } + + public UnaryCallable getMonitoredAgentCallable() { + throw new UnsupportedOperationException("Not implemented: getMonitoredAgentCallable()"); + } + + public UnaryCallable + listMonitoredAgentsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listMonitoredAgentsPagedCallable()"); + } + + public UnaryCallable + listMonitoredAgentsCallable() { + throw new UnsupportedOperationException("Not implemented: listMonitoredAgentsCallable()"); + } + + public OperationCallable< + EnableMonitoredAgentRequest, MonitoredAgent, EnableMonitoredAgentOperationMetadata> + enableMonitoredAgentOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: enableMonitoredAgentOperationCallable()"); + } + + public UnaryCallable enableMonitoredAgentCallable() { + throw new UnsupportedOperationException("Not implemented: enableMonitoredAgentCallable()"); + } + + public OperationCallable< + DisableMonitoredAgentRequest, MonitoredAgent, DisableMonitoredAgentOperationMetadata> + disableMonitoredAgentOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: disableMonitoredAgentOperationCallable()"); + } + + public UnaryCallable disableMonitoredAgentCallable() { + throw new UnsupportedOperationException("Not implemented: disableMonitoredAgentCallable()"); + } + + public OperationCallable< + DeleteAgentAnomalyDetectionScopeRequest, + Empty, + DeleteAgentAnomalyDetectionScopeOperationMetadata> + deleteAgentAnomalyDetectionScopeOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: deleteAgentAnomalyDetectionScopeOperationCallable()"); + } + + public UnaryCallable + deleteAgentAnomalyDetectionScopeCallable() { + throw new UnsupportedOperationException( + "Not implemented: deleteAgentAnomalyDetectionScopeCallable()"); + } + + public OperationCallable< + CreateAgentAnomalyDetectionScopeRequest, + AgentAnomalyDetectionScope, + CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: createAgentAnomalyDetectionScopeOperationCallable()"); + } + + public UnaryCallable + createAgentAnomalyDetectionScopeCallable() { + throw new UnsupportedOperationException( + "Not implemented: createAgentAnomalyDetectionScopeCallable()"); + } + + public UnaryCallable< + ListAgentAnomalyDetectionScopesRequest, ListAgentAnomalyDetectionScopesPagedResponse> + listAgentAnomalyDetectionScopesPagedCallable() { + throw new UnsupportedOperationException( + "Not implemented: listAgentAnomalyDetectionScopesPagedCallable()"); + } + + public UnaryCallable< + ListAgentAnomalyDetectionScopesRequest, ListAgentAnomalyDetectionScopesResponse> + listAgentAnomalyDetectionScopesCallable() { + throw new UnsupportedOperationException( + "Not implemented: listAgentAnomalyDetectionScopesCallable()"); + } + + public UnaryCallable + listAnalyzedSessionsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listAnalyzedSessionsPagedCallable()"); + } + + public UnaryCallable + listAnalyzedSessionsCallable() { + throw new UnsupportedOperationException("Not implemented: listAnalyzedSessionsCallable()"); + } + + public UnaryCallable getAnalyzedSessionCallable() { + throw new UnsupportedOperationException("Not implemented: getAnalyzedSessionCallable()"); + } + + public UnaryCallable + listAnalyzedInvocationsPagedCallable() { + throw new UnsupportedOperationException( + "Not implemented: listAnalyzedInvocationsPagedCallable()"); + } + + public UnaryCallable + listAnalyzedInvocationsCallable() { + throw new UnsupportedOperationException("Not implemented: listAnalyzedInvocationsCallable()"); + } + + public UnaryCallable + getAnalyzedInvocationCallable() { + throw new UnsupportedOperationException("Not implemented: getAnalyzedInvocationCallable()"); + } + + public UnaryCallable + aggregateAnalyzedSessionsPagedCallable() { + throw new UnsupportedOperationException( + "Not implemented: aggregateAnalyzedSessionsPagedCallable()"); + } + + public UnaryCallable + aggregateAnalyzedSessionsCallable() { + throw new UnsupportedOperationException("Not implemented: aggregateAnalyzedSessionsCallable()"); + } + + public OperationCallable< + ClearTrainingDataRequest, ClearTrainingDataResponse, ClearTrainingDataOperationMetadata> + clearTrainingDataOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: clearTrainingDataOperationCallable()"); + } + + public UnaryCallable clearTrainingDataCallable() { + throw new UnsupportedOperationException("Not implemented: clearTrainingDataCallable()"); + } + + public UnaryCallable + listLocationsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listLocationsPagedCallable()"); + } + + public UnaryCallable listLocationsCallable() { + throw new UnsupportedOperationException("Not implemented: listLocationsCallable()"); + } + + public UnaryCallable getLocationCallable() { + throw new UnsupportedOperationException("Not implemented: getLocationCallable()"); + } + + public UnaryCallable setIamPolicyCallable() { + throw new UnsupportedOperationException("Not implemented: setIamPolicyCallable()"); + } + + public UnaryCallable getIamPolicyCallable() { + throw new UnsupportedOperationException("Not implemented: getIamPolicyCallable()"); + } + + public UnaryCallable + testIamPermissionsCallable() { + throw new UnsupportedOperationException("Not implemented: testIamPermissionsCallable()"); + } + + @Override + public abstract void close(); +} diff --git a/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/AgentAnomalyDetectionServiceStubSettings.java b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/AgentAnomalyDetectionServiceStubSettings.java new file mode 100644 index 000000000000..11d7416e91ed --- /dev/null +++ b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/AgentAnomalyDetectionServiceStubSettings.java @@ -0,0 +1,1584 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.stub; + +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.AggregateAnalyzedSessionsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAgentAnomalyDetectionScopesPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAnalyzedInvocationsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAnalyzedSessionsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListLocationsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListMonitoredAgentsPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.ApiFuture; +import com.google.api.core.ObsoleteApi; +import com.google.api.gax.core.GaxProperties; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.GrpcTransportChannel; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.grpc.ProtoOperationTransformers; +import com.google.api.gax.longrunning.OperationSnapshot; +import com.google.api.gax.longrunning.OperationTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.rpc.ApiCallContext; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.LibraryMetadata; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.PagedListDescriptor; +import com.google.api.gax.rpc.PagedListResponseFactory; +import com.google.api.gax.rpc.StatusCode; +import com.google.api.gax.rpc.StubSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata; +import com.google.cloud.aiplatform.v1.ClearTrainingDataRequest; +import com.google.cloud.aiplatform.v1.ClearTrainingDataResponse; +import com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata; +import com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata; +import com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata; +import com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata; +import com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest; +import com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest; +import com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest; +import com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse; +import com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest; +import com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse; +import com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest; +import com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.collect.ImmutableList; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableSet; +import com.google.common.collect.Lists; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.protobuf.Empty; +import java.io.IOException; +import java.time.Duration; +import java.util.List; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link AgentAnomalyDetectionServiceStub}. + * + *

The default instance has everything set to sensible defaults: + * + *

    + *
  • The default service address (aiplatform.googleapis.com) and default port (443) are used. + *
  • Credentials are acquired automatically through Application Default Credentials. + *
  • Retries are configured for idempotent methods but not for non-idempotent methods. + *
+ * + *

The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. + * + *

For example, to set the + * [RetrySettings](https://cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.retrying.RetrySettings) + * of getAgentAnomalyDetectionScope: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * AgentAnomalyDetectionServiceStubSettings.Builder agentAnomalyDetectionServiceSettingsBuilder =
+ *     AgentAnomalyDetectionServiceStubSettings.newBuilder();
+ * agentAnomalyDetectionServiceSettingsBuilder
+ *     .getAgentAnomalyDetectionScopeSettings()
+ *     .setRetrySettings(
+ *         agentAnomalyDetectionServiceSettingsBuilder
+ *             .getAgentAnomalyDetectionScopeSettings()
+ *             .getRetrySettings()
+ *             .toBuilder()
+ *             .setInitialRetryDelayDuration(Duration.ofSeconds(1))
+ *             .setInitialRpcTimeoutDuration(Duration.ofSeconds(5))
+ *             .setMaxAttempts(5)
+ *             .setMaxRetryDelayDuration(Duration.ofSeconds(30))
+ *             .setMaxRpcTimeoutDuration(Duration.ofSeconds(60))
+ *             .setRetryDelayMultiplier(1.3)
+ *             .setRpcTimeoutMultiplier(1.5)
+ *             .setTotalTimeoutDuration(Duration.ofSeconds(300))
+ *             .build());
+ * AgentAnomalyDetectionServiceStubSettings agentAnomalyDetectionServiceSettings =
+ *     agentAnomalyDetectionServiceSettingsBuilder.build();
+ * }
+ * + * Please refer to the [Client Side Retry + * Guide](https://docs.cloud.google.com/java/docs/client-retries) for additional support in setting + * retries. + * + *

To configure the RetrySettings of a Long Running Operation method, create an + * OperationTimedPollAlgorithm object and update the RPC's polling algorithm. For example, to + * configure the RetrySettings for enableMonitoredAgent: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * AgentAnomalyDetectionServiceStubSettings.Builder agentAnomalyDetectionServiceSettingsBuilder =
+ *     AgentAnomalyDetectionServiceStubSettings.newBuilder();
+ * TimedRetryAlgorithm timedRetryAlgorithm =
+ *     OperationalTimedPollAlgorithm.create(
+ *         RetrySettings.newBuilder()
+ *             .setInitialRetryDelayDuration(Duration.ofMillis(500))
+ *             .setRetryDelayMultiplier(1.5)
+ *             .setMaxRetryDelayDuration(Duration.ofMillis(5000))
+ *             .setTotalTimeoutDuration(Duration.ofHours(24))
+ *             .build());
+ * agentAnomalyDetectionServiceSettingsBuilder
+ *     .createClusterOperationSettings()
+ *     .setPollingAlgorithm(timedRetryAlgorithm)
+ *     .build();
+ * }
+ */ +@NullMarked +@Generated("by gapic-generator-java") +@SuppressWarnings("CanonicalDuration") +public class AgentAnomalyDetectionServiceStubSettings + extends StubSettings { + /** The default scopes of the service. */ + private static final ImmutableList DEFAULT_SERVICE_SCOPES = + ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + + private final UnaryCallSettings + getAgentAnomalyDetectionScopeSettings; + private final UnaryCallSettings + getMonitoredAgentSettings; + private final PagedCallSettings< + ListMonitoredAgentsRequest, ListMonitoredAgentsResponse, ListMonitoredAgentsPagedResponse> + listMonitoredAgentsSettings; + private final UnaryCallSettings + enableMonitoredAgentSettings; + private final OperationCallSettings< + EnableMonitoredAgentRequest, MonitoredAgent, EnableMonitoredAgentOperationMetadata> + enableMonitoredAgentOperationSettings; + private final UnaryCallSettings + disableMonitoredAgentSettings; + private final OperationCallSettings< + DisableMonitoredAgentRequest, MonitoredAgent, DisableMonitoredAgentOperationMetadata> + disableMonitoredAgentOperationSettings; + private final UnaryCallSettings + deleteAgentAnomalyDetectionScopeSettings; + private final OperationCallSettings< + DeleteAgentAnomalyDetectionScopeRequest, + Empty, + DeleteAgentAnomalyDetectionScopeOperationMetadata> + deleteAgentAnomalyDetectionScopeOperationSettings; + private final UnaryCallSettings + createAgentAnomalyDetectionScopeSettings; + private final OperationCallSettings< + CreateAgentAnomalyDetectionScopeRequest, + AgentAnomalyDetectionScope, + CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeOperationSettings; + private final PagedCallSettings< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + ListAgentAnomalyDetectionScopesPagedResponse> + listAgentAnomalyDetectionScopesSettings; + private final PagedCallSettings< + ListAnalyzedSessionsRequest, + ListAnalyzedSessionsResponse, + ListAnalyzedSessionsPagedResponse> + listAnalyzedSessionsSettings; + private final UnaryCallSettings + getAnalyzedSessionSettings; + private final PagedCallSettings< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + ListAnalyzedInvocationsPagedResponse> + listAnalyzedInvocationsSettings; + private final UnaryCallSettings + getAnalyzedInvocationSettings; + private final PagedCallSettings< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsPagedResponse> + aggregateAnalyzedSessionsSettings; + private final UnaryCallSettings clearTrainingDataSettings; + private final OperationCallSettings< + ClearTrainingDataRequest, ClearTrainingDataResponse, ClearTrainingDataOperationMetadata> + clearTrainingDataOperationSettings; + private final PagedCallSettings< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings; + private final UnaryCallSettings getLocationSettings; + private final UnaryCallSettings setIamPolicySettings; + private final UnaryCallSettings getIamPolicySettings; + private final UnaryCallSettings + testIamPermissionsSettings; + + private static final PagedListDescriptor< + ListMonitoredAgentsRequest, ListMonitoredAgentsResponse, MonitoredAgent> + LIST_MONITORED_AGENTS_PAGE_STR_DESC = + new PagedListDescriptor< + ListMonitoredAgentsRequest, ListMonitoredAgentsResponse, MonitoredAgent>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListMonitoredAgentsRequest injectToken( + ListMonitoredAgentsRequest payload, String token) { + return ListMonitoredAgentsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListMonitoredAgentsRequest injectPageSize( + ListMonitoredAgentsRequest payload, int pageSize) { + return ListMonitoredAgentsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListMonitoredAgentsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListMonitoredAgentsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListMonitoredAgentsResponse payload) { + return payload.getMonitoredAgentsList(); + } + }; + + private static final PagedListDescriptor< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + AgentAnomalyDetectionScope> + LIST_AGENT_ANOMALY_DETECTION_SCOPES_PAGE_STR_DESC = + new PagedListDescriptor< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + AgentAnomalyDetectionScope>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListAgentAnomalyDetectionScopesRequest injectToken( + ListAgentAnomalyDetectionScopesRequest payload, String token) { + return ListAgentAnomalyDetectionScopesRequest.newBuilder(payload) + .setPageToken(token) + .build(); + } + + @Override + public ListAgentAnomalyDetectionScopesRequest injectPageSize( + ListAgentAnomalyDetectionScopesRequest payload, int pageSize) { + return ListAgentAnomalyDetectionScopesRequest.newBuilder(payload) + .setPageSize(pageSize) + .build(); + } + + @Override + public Integer extractPageSize(ListAgentAnomalyDetectionScopesRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListAgentAnomalyDetectionScopesResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources( + ListAgentAnomalyDetectionScopesResponse payload) { + return payload.getAgentAnomalyDetectionScopesList(); + } + }; + + private static final PagedListDescriptor< + ListAnalyzedSessionsRequest, ListAnalyzedSessionsResponse, AnalyzedSession> + LIST_ANALYZED_SESSIONS_PAGE_STR_DESC = + new PagedListDescriptor< + ListAnalyzedSessionsRequest, ListAnalyzedSessionsResponse, AnalyzedSession>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListAnalyzedSessionsRequest injectToken( + ListAnalyzedSessionsRequest payload, String token) { + return ListAnalyzedSessionsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListAnalyzedSessionsRequest injectPageSize( + ListAnalyzedSessionsRequest payload, int pageSize) { + return ListAnalyzedSessionsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListAnalyzedSessionsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListAnalyzedSessionsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources( + ListAnalyzedSessionsResponse payload) { + return payload.getAnalyzedSessionsList(); + } + }; + + private static final PagedListDescriptor< + ListAnalyzedInvocationsRequest, ListAnalyzedInvocationsResponse, AnalyzedInvocation> + LIST_ANALYZED_INVOCATIONS_PAGE_STR_DESC = + new PagedListDescriptor< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + AnalyzedInvocation>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListAnalyzedInvocationsRequest injectToken( + ListAnalyzedInvocationsRequest payload, String token) { + return ListAnalyzedInvocationsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListAnalyzedInvocationsRequest injectPageSize( + ListAnalyzedInvocationsRequest payload, int pageSize) { + return ListAnalyzedInvocationsRequest.newBuilder(payload) + .setPageSize(pageSize) + .build(); + } + + @Override + public Integer extractPageSize(ListAnalyzedInvocationsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListAnalyzedInvocationsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources( + ListAnalyzedInvocationsResponse payload) { + return payload.getAnalyzedInvocationsList(); + } + }; + + private static final PagedListDescriptor< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsResponse.AgentAggregate> + AGGREGATE_ANALYZED_SESSIONS_PAGE_STR_DESC = + new PagedListDescriptor< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsResponse.AgentAggregate>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public AggregateAnalyzedSessionsRequest injectToken( + AggregateAnalyzedSessionsRequest payload, String token) { + return AggregateAnalyzedSessionsRequest.newBuilder(payload) + .setPageToken(token) + .build(); + } + + @Override + public AggregateAnalyzedSessionsRequest injectPageSize( + AggregateAnalyzedSessionsRequest payload, int pageSize) { + return AggregateAnalyzedSessionsRequest.newBuilder(payload) + .setPageSize(pageSize) + .build(); + } + + @Override + public Integer extractPageSize(AggregateAnalyzedSessionsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(AggregateAnalyzedSessionsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources( + AggregateAnalyzedSessionsResponse payload) { + return payload.getAgentAggregatesList(); + } + }; + + private static final PagedListDescriptor + LIST_LOCATIONS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListLocationsRequest injectToken(ListLocationsRequest payload, String token) { + return ListLocationsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListLocationsRequest injectPageSize(ListLocationsRequest payload, int pageSize) { + return ListLocationsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListLocationsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListLocationsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListLocationsResponse payload) { + return payload.getLocationsList(); + } + }; + + private static final PagedListResponseFactory< + ListMonitoredAgentsRequest, ListMonitoredAgentsResponse, ListMonitoredAgentsPagedResponse> + LIST_MONITORED_AGENTS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListMonitoredAgentsRequest, + ListMonitoredAgentsResponse, + ListMonitoredAgentsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListMonitoredAgentsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext + pageContext = + PageContext.create( + callable, LIST_MONITORED_AGENTS_PAGE_STR_DESC, request, context); + return ListMonitoredAgentsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + ListAgentAnomalyDetectionScopesPagedResponse> + LIST_AGENT_ANOMALY_DETECTION_SCOPES_PAGE_STR_FACT = + new PagedListResponseFactory< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + ListAgentAnomalyDetectionScopesPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse> + callable, + ListAgentAnomalyDetectionScopesRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + AgentAnomalyDetectionScope> + pageContext = + PageContext.create( + callable, + LIST_AGENT_ANOMALY_DETECTION_SCOPES_PAGE_STR_DESC, + request, + context); + return ListAgentAnomalyDetectionScopesPagedResponse.createAsync( + pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListAnalyzedSessionsRequest, + ListAnalyzedSessionsResponse, + ListAnalyzedSessionsPagedResponse> + LIST_ANALYZED_SESSIONS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListAnalyzedSessionsRequest, + ListAnalyzedSessionsResponse, + ListAnalyzedSessionsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListAnalyzedSessionsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext< + ListAnalyzedSessionsRequest, ListAnalyzedSessionsResponse, AnalyzedSession> + pageContext = + PageContext.create( + callable, LIST_ANALYZED_SESSIONS_PAGE_STR_DESC, request, context); + return ListAnalyzedSessionsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + ListAnalyzedInvocationsPagedResponse> + LIST_ANALYZED_INVOCATIONS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + ListAnalyzedInvocationsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable + callable, + ListAnalyzedInvocationsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + AnalyzedInvocation> + pageContext = + PageContext.create( + callable, LIST_ANALYZED_INVOCATIONS_PAGE_STR_DESC, request, context); + return ListAnalyzedInvocationsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsPagedResponse> + AGGREGATE_ANALYZED_SESSIONS_PAGE_STR_FACT = + new PagedListResponseFactory< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable + callable, + AggregateAnalyzedSessionsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsResponse.AgentAggregate> + pageContext = + PageContext.create( + callable, AGGREGATE_ANALYZED_SESSIONS_PAGE_STR_DESC, request, context); + return AggregateAnalyzedSessionsPagedResponse.createAsync( + pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + LIST_LOCATIONS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListLocationsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_LOCATIONS_PAGE_STR_DESC, request, context); + return ListLocationsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + /** Returns the object with the settings used for calls to getAgentAnomalyDetectionScope. */ + public UnaryCallSettings + getAgentAnomalyDetectionScopeSettings() { + return getAgentAnomalyDetectionScopeSettings; + } + + /** Returns the object with the settings used for calls to getMonitoredAgent. */ + public UnaryCallSettings getMonitoredAgentSettings() { + return getMonitoredAgentSettings; + } + + /** Returns the object with the settings used for calls to listMonitoredAgents. */ + public PagedCallSettings< + ListMonitoredAgentsRequest, ListMonitoredAgentsResponse, ListMonitoredAgentsPagedResponse> + listMonitoredAgentsSettings() { + return listMonitoredAgentsSettings; + } + + /** Returns the object with the settings used for calls to enableMonitoredAgent. */ + public UnaryCallSettings enableMonitoredAgentSettings() { + return enableMonitoredAgentSettings; + } + + /** Returns the object with the settings used for calls to enableMonitoredAgent. */ + public OperationCallSettings< + EnableMonitoredAgentRequest, MonitoredAgent, EnableMonitoredAgentOperationMetadata> + enableMonitoredAgentOperationSettings() { + return enableMonitoredAgentOperationSettings; + } + + /** Returns the object with the settings used for calls to disableMonitoredAgent. */ + public UnaryCallSettings + disableMonitoredAgentSettings() { + return disableMonitoredAgentSettings; + } + + /** Returns the object with the settings used for calls to disableMonitoredAgent. */ + public OperationCallSettings< + DisableMonitoredAgentRequest, MonitoredAgent, DisableMonitoredAgentOperationMetadata> + disableMonitoredAgentOperationSettings() { + return disableMonitoredAgentOperationSettings; + } + + /** Returns the object with the settings used for calls to deleteAgentAnomalyDetectionScope. */ + public UnaryCallSettings + deleteAgentAnomalyDetectionScopeSettings() { + return deleteAgentAnomalyDetectionScopeSettings; + } + + /** Returns the object with the settings used for calls to deleteAgentAnomalyDetectionScope. */ + public OperationCallSettings< + DeleteAgentAnomalyDetectionScopeRequest, + Empty, + DeleteAgentAnomalyDetectionScopeOperationMetadata> + deleteAgentAnomalyDetectionScopeOperationSettings() { + return deleteAgentAnomalyDetectionScopeOperationSettings; + } + + /** Returns the object with the settings used for calls to createAgentAnomalyDetectionScope. */ + public UnaryCallSettings + createAgentAnomalyDetectionScopeSettings() { + return createAgentAnomalyDetectionScopeSettings; + } + + /** Returns the object with the settings used for calls to createAgentAnomalyDetectionScope. */ + public OperationCallSettings< + CreateAgentAnomalyDetectionScopeRequest, + AgentAnomalyDetectionScope, + CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeOperationSettings() { + return createAgentAnomalyDetectionScopeOperationSettings; + } + + /** Returns the object with the settings used for calls to listAgentAnomalyDetectionScopes. */ + public PagedCallSettings< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + ListAgentAnomalyDetectionScopesPagedResponse> + listAgentAnomalyDetectionScopesSettings() { + return listAgentAnomalyDetectionScopesSettings; + } + + /** Returns the object with the settings used for calls to listAnalyzedSessions. */ + public PagedCallSettings< + ListAnalyzedSessionsRequest, + ListAnalyzedSessionsResponse, + ListAnalyzedSessionsPagedResponse> + listAnalyzedSessionsSettings() { + return listAnalyzedSessionsSettings; + } + + /** Returns the object with the settings used for calls to getAnalyzedSession. */ + public UnaryCallSettings + getAnalyzedSessionSettings() { + return getAnalyzedSessionSettings; + } + + /** Returns the object with the settings used for calls to listAnalyzedInvocations. */ + public PagedCallSettings< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + ListAnalyzedInvocationsPagedResponse> + listAnalyzedInvocationsSettings() { + return listAnalyzedInvocationsSettings; + } + + /** Returns the object with the settings used for calls to getAnalyzedInvocation. */ + public UnaryCallSettings + getAnalyzedInvocationSettings() { + return getAnalyzedInvocationSettings; + } + + /** Returns the object with the settings used for calls to aggregateAnalyzedSessions. */ + public PagedCallSettings< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsPagedResponse> + aggregateAnalyzedSessionsSettings() { + return aggregateAnalyzedSessionsSettings; + } + + /** Returns the object with the settings used for calls to clearTrainingData. */ + public UnaryCallSettings clearTrainingDataSettings() { + return clearTrainingDataSettings; + } + + /** Returns the object with the settings used for calls to clearTrainingData. */ + public OperationCallSettings< + ClearTrainingDataRequest, ClearTrainingDataResponse, ClearTrainingDataOperationMetadata> + clearTrainingDataOperationSettings() { + return clearTrainingDataOperationSettings; + } + + /** Returns the object with the settings used for calls to listLocations. */ + public PagedCallSettings + listLocationsSettings() { + return listLocationsSettings; + } + + /** Returns the object with the settings used for calls to getLocation. */ + public UnaryCallSettings getLocationSettings() { + return getLocationSettings; + } + + /** Returns the object with the settings used for calls to setIamPolicy. */ + public UnaryCallSettings setIamPolicySettings() { + return setIamPolicySettings; + } + + /** Returns the object with the settings used for calls to getIamPolicy. */ + public UnaryCallSettings getIamPolicySettings() { + return getIamPolicySettings; + } + + /** Returns the object with the settings used for calls to testIamPermissions. */ + public UnaryCallSettings + testIamPermissionsSettings() { + return testIamPermissionsSettings; + } + + public AgentAnomalyDetectionServiceStub createStub() throws IOException { + if (getTransportChannelProvider() + .getTransportName() + .equals(GrpcTransportChannel.getGrpcTransportName())) { + return GrpcAgentAnomalyDetectionServiceStub.create(this); + } + throw new UnsupportedOperationException( + String.format( + "Transport not supported: %s", getTransportChannelProvider().getTransportName())); + } + + /** Returns the default service name. */ + @Override + public String getServiceName() { + return "aiplatform"; + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return InstantiatingExecutorProvider.newBuilder(); + } + + /** Returns the default service endpoint. */ + @ObsoleteApi("Use getEndpoint() instead") + public static String getDefaultEndpoint() { + return "aiplatform.googleapis.com:443"; + } + + /** Returns the default mTLS service endpoint. */ + public static String getDefaultMtlsEndpoint() { + return "aiplatform.mtls.googleapis.com:443"; + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return DEFAULT_SERVICE_SCOPES; + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return GoogleCredentialsProvider.newBuilder() + .setScopesToApply(DEFAULT_SERVICE_SCOPES) + .setUseJwtAccessWithScope(true); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return InstantiatingGrpcChannelProvider.newBuilder() + .setMaxInboundMessageSize(Integer.MAX_VALUE); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return defaultGrpcTransportProviderBuilder().build(); + } + + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken( + "gapic", + GaxProperties.getLibraryVersion(AgentAnomalyDetectionServiceStubSettings.class)) + .setTransportToken( + GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(@Nullable ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected AgentAnomalyDetectionServiceStubSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + + getAgentAnomalyDetectionScopeSettings = + settingsBuilder.getAgentAnomalyDetectionScopeSettings().build(); + getMonitoredAgentSettings = settingsBuilder.getMonitoredAgentSettings().build(); + listMonitoredAgentsSettings = settingsBuilder.listMonitoredAgentsSettings().build(); + enableMonitoredAgentSettings = settingsBuilder.enableMonitoredAgentSettings().build(); + enableMonitoredAgentOperationSettings = + settingsBuilder.enableMonitoredAgentOperationSettings().build(); + disableMonitoredAgentSettings = settingsBuilder.disableMonitoredAgentSettings().build(); + disableMonitoredAgentOperationSettings = + settingsBuilder.disableMonitoredAgentOperationSettings().build(); + deleteAgentAnomalyDetectionScopeSettings = + settingsBuilder.deleteAgentAnomalyDetectionScopeSettings().build(); + deleteAgentAnomalyDetectionScopeOperationSettings = + settingsBuilder.deleteAgentAnomalyDetectionScopeOperationSettings().build(); + createAgentAnomalyDetectionScopeSettings = + settingsBuilder.createAgentAnomalyDetectionScopeSettings().build(); + createAgentAnomalyDetectionScopeOperationSettings = + settingsBuilder.createAgentAnomalyDetectionScopeOperationSettings().build(); + listAgentAnomalyDetectionScopesSettings = + settingsBuilder.listAgentAnomalyDetectionScopesSettings().build(); + listAnalyzedSessionsSettings = settingsBuilder.listAnalyzedSessionsSettings().build(); + getAnalyzedSessionSettings = settingsBuilder.getAnalyzedSessionSettings().build(); + listAnalyzedInvocationsSettings = settingsBuilder.listAnalyzedInvocationsSettings().build(); + getAnalyzedInvocationSettings = settingsBuilder.getAnalyzedInvocationSettings().build(); + aggregateAnalyzedSessionsSettings = settingsBuilder.aggregateAnalyzedSessionsSettings().build(); + clearTrainingDataSettings = settingsBuilder.clearTrainingDataSettings().build(); + clearTrainingDataOperationSettings = + settingsBuilder.clearTrainingDataOperationSettings().build(); + listLocationsSettings = settingsBuilder.listLocationsSettings().build(); + getLocationSettings = settingsBuilder.getLocationSettings().build(); + setIamPolicySettings = settingsBuilder.setIamPolicySettings().build(); + getIamPolicySettings = settingsBuilder.getIamPolicySettings().build(); + testIamPermissionsSettings = settingsBuilder.testIamPermissionsSettings().build(); + } + + @Override + protected LibraryMetadata getLibraryMetadata() { + return LibraryMetadata.newBuilder() + .setArtifactName("com.google.cloud:google-cloud-aiplatform") + .setRepository("googleapis/google-cloud-java") + .setVersion(Version.VERSION) + .build(); + } + + /** Builder for AgentAnomalyDetectionServiceStubSettings. */ + public static class Builder + extends StubSettings.Builder { + private final ImmutableList> unaryMethodSettingsBuilders; + private final UnaryCallSettings.Builder< + GetAgentAnomalyDetectionScopeRequest, AgentAnomalyDetectionScope> + getAgentAnomalyDetectionScopeSettings; + private final UnaryCallSettings.Builder + getMonitoredAgentSettings; + private final PagedCallSettings.Builder< + ListMonitoredAgentsRequest, + ListMonitoredAgentsResponse, + ListMonitoredAgentsPagedResponse> + listMonitoredAgentsSettings; + private final UnaryCallSettings.Builder + enableMonitoredAgentSettings; + private final OperationCallSettings.Builder< + EnableMonitoredAgentRequest, MonitoredAgent, EnableMonitoredAgentOperationMetadata> + enableMonitoredAgentOperationSettings; + private final UnaryCallSettings.Builder + disableMonitoredAgentSettings; + private final OperationCallSettings.Builder< + DisableMonitoredAgentRequest, MonitoredAgent, DisableMonitoredAgentOperationMetadata> + disableMonitoredAgentOperationSettings; + private final UnaryCallSettings.Builder + deleteAgentAnomalyDetectionScopeSettings; + private final OperationCallSettings.Builder< + DeleteAgentAnomalyDetectionScopeRequest, + Empty, + DeleteAgentAnomalyDetectionScopeOperationMetadata> + deleteAgentAnomalyDetectionScopeOperationSettings; + private final UnaryCallSettings.Builder + createAgentAnomalyDetectionScopeSettings; + private final OperationCallSettings.Builder< + CreateAgentAnomalyDetectionScopeRequest, + AgentAnomalyDetectionScope, + CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeOperationSettings; + private final PagedCallSettings.Builder< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + ListAgentAnomalyDetectionScopesPagedResponse> + listAgentAnomalyDetectionScopesSettings; + private final PagedCallSettings.Builder< + ListAnalyzedSessionsRequest, + ListAnalyzedSessionsResponse, + ListAnalyzedSessionsPagedResponse> + listAnalyzedSessionsSettings; + private final UnaryCallSettings.Builder + getAnalyzedSessionSettings; + private final PagedCallSettings.Builder< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + ListAnalyzedInvocationsPagedResponse> + listAnalyzedInvocationsSettings; + private final UnaryCallSettings.Builder + getAnalyzedInvocationSettings; + private final PagedCallSettings.Builder< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsPagedResponse> + aggregateAnalyzedSessionsSettings; + private final UnaryCallSettings.Builder + clearTrainingDataSettings; + private final OperationCallSettings.Builder< + ClearTrainingDataRequest, ClearTrainingDataResponse, ClearTrainingDataOperationMetadata> + clearTrainingDataOperationSettings; + private final PagedCallSettings.Builder< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings; + private final UnaryCallSettings.Builder getLocationSettings; + private final UnaryCallSettings.Builder setIamPolicySettings; + private final UnaryCallSettings.Builder getIamPolicySettings; + private final UnaryCallSettings.Builder + testIamPermissionsSettings; + private static final ImmutableMap> + RETRYABLE_CODE_DEFINITIONS; + + static { + ImmutableMap.Builder> definitions = + ImmutableMap.builder(); + definitions.put("no_retry_codes", ImmutableSet.copyOf(Lists.newArrayList())); + RETRYABLE_CODE_DEFINITIONS = definitions.build(); + } + + private static final ImmutableMap RETRY_PARAM_DEFINITIONS; + + static { + ImmutableMap.Builder definitions = ImmutableMap.builder(); + RetrySettings settings = null; + settings = RetrySettings.newBuilder().setRpcTimeoutMultiplier(1.0).build(); + definitions.put("no_retry_params", settings); + RETRY_PARAM_DEFINITIONS = definitions.build(); + } + + protected Builder() { + this(((ClientContext) null)); + } + + protected Builder(@Nullable ClientContext clientContext) { + super(clientContext); + + getAgentAnomalyDetectionScopeSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + getMonitoredAgentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listMonitoredAgentsSettings = + PagedCallSettings.newBuilder(LIST_MONITORED_AGENTS_PAGE_STR_FACT); + enableMonitoredAgentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + enableMonitoredAgentOperationSettings = OperationCallSettings.newBuilder(); + disableMonitoredAgentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + disableMonitoredAgentOperationSettings = OperationCallSettings.newBuilder(); + deleteAgentAnomalyDetectionScopeSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteAgentAnomalyDetectionScopeOperationSettings = OperationCallSettings.newBuilder(); + createAgentAnomalyDetectionScopeSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createAgentAnomalyDetectionScopeOperationSettings = OperationCallSettings.newBuilder(); + listAgentAnomalyDetectionScopesSettings = + PagedCallSettings.newBuilder(LIST_AGENT_ANOMALY_DETECTION_SCOPES_PAGE_STR_FACT); + listAnalyzedSessionsSettings = + PagedCallSettings.newBuilder(LIST_ANALYZED_SESSIONS_PAGE_STR_FACT); + getAnalyzedSessionSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listAnalyzedInvocationsSettings = + PagedCallSettings.newBuilder(LIST_ANALYZED_INVOCATIONS_PAGE_STR_FACT); + getAnalyzedInvocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + aggregateAnalyzedSessionsSettings = + PagedCallSettings.newBuilder(AGGREGATE_ANALYZED_SESSIONS_PAGE_STR_FACT); + clearTrainingDataSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + clearTrainingDataOperationSettings = OperationCallSettings.newBuilder(); + listLocationsSettings = PagedCallSettings.newBuilder(LIST_LOCATIONS_PAGE_STR_FACT); + getLocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + setIamPolicySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + getIamPolicySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + testIamPermissionsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + getAgentAnomalyDetectionScopeSettings, + getMonitoredAgentSettings, + listMonitoredAgentsSettings, + enableMonitoredAgentSettings, + disableMonitoredAgentSettings, + deleteAgentAnomalyDetectionScopeSettings, + createAgentAnomalyDetectionScopeSettings, + listAgentAnomalyDetectionScopesSettings, + listAnalyzedSessionsSettings, + getAnalyzedSessionSettings, + listAnalyzedInvocationsSettings, + getAnalyzedInvocationSettings, + aggregateAnalyzedSessionsSettings, + clearTrainingDataSettings, + listLocationsSettings, + getLocationSettings, + setIamPolicySettings, + getIamPolicySettings, + testIamPermissionsSettings); + initDefaults(this); + } + + protected Builder(AgentAnomalyDetectionServiceStubSettings settings) { + super(settings); + + getAgentAnomalyDetectionScopeSettings = + settings.getAgentAnomalyDetectionScopeSettings.toBuilder(); + getMonitoredAgentSettings = settings.getMonitoredAgentSettings.toBuilder(); + listMonitoredAgentsSettings = settings.listMonitoredAgentsSettings.toBuilder(); + enableMonitoredAgentSettings = settings.enableMonitoredAgentSettings.toBuilder(); + enableMonitoredAgentOperationSettings = + settings.enableMonitoredAgentOperationSettings.toBuilder(); + disableMonitoredAgentSettings = settings.disableMonitoredAgentSettings.toBuilder(); + disableMonitoredAgentOperationSettings = + settings.disableMonitoredAgentOperationSettings.toBuilder(); + deleteAgentAnomalyDetectionScopeSettings = + settings.deleteAgentAnomalyDetectionScopeSettings.toBuilder(); + deleteAgentAnomalyDetectionScopeOperationSettings = + settings.deleteAgentAnomalyDetectionScopeOperationSettings.toBuilder(); + createAgentAnomalyDetectionScopeSettings = + settings.createAgentAnomalyDetectionScopeSettings.toBuilder(); + createAgentAnomalyDetectionScopeOperationSettings = + settings.createAgentAnomalyDetectionScopeOperationSettings.toBuilder(); + listAgentAnomalyDetectionScopesSettings = + settings.listAgentAnomalyDetectionScopesSettings.toBuilder(); + listAnalyzedSessionsSettings = settings.listAnalyzedSessionsSettings.toBuilder(); + getAnalyzedSessionSettings = settings.getAnalyzedSessionSettings.toBuilder(); + listAnalyzedInvocationsSettings = settings.listAnalyzedInvocationsSettings.toBuilder(); + getAnalyzedInvocationSettings = settings.getAnalyzedInvocationSettings.toBuilder(); + aggregateAnalyzedSessionsSettings = settings.aggregateAnalyzedSessionsSettings.toBuilder(); + clearTrainingDataSettings = settings.clearTrainingDataSettings.toBuilder(); + clearTrainingDataOperationSettings = settings.clearTrainingDataOperationSettings.toBuilder(); + listLocationsSettings = settings.listLocationsSettings.toBuilder(); + getLocationSettings = settings.getLocationSettings.toBuilder(); + setIamPolicySettings = settings.setIamPolicySettings.toBuilder(); + getIamPolicySettings = settings.getIamPolicySettings.toBuilder(); + testIamPermissionsSettings = settings.testIamPermissionsSettings.toBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + getAgentAnomalyDetectionScopeSettings, + getMonitoredAgentSettings, + listMonitoredAgentsSettings, + enableMonitoredAgentSettings, + disableMonitoredAgentSettings, + deleteAgentAnomalyDetectionScopeSettings, + createAgentAnomalyDetectionScopeSettings, + listAgentAnomalyDetectionScopesSettings, + listAnalyzedSessionsSettings, + getAnalyzedSessionSettings, + listAnalyzedInvocationsSettings, + getAnalyzedInvocationSettings, + aggregateAnalyzedSessionsSettings, + clearTrainingDataSettings, + listLocationsSettings, + getLocationSettings, + setIamPolicySettings, + getIamPolicySettings, + testIamPermissionsSettings); + } + + private static Builder createDefault() { + Builder builder = new Builder(((ClientContext) null)); + + builder.setTransportChannelProvider(defaultTransportChannelProvider()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); + builder.setMtlsEndpoint(getDefaultMtlsEndpoint()); + builder.setSwitchToMtlsEndpointAllowed(true); + + return initDefaults(builder); + } + + private static Builder initDefaults(Builder builder) { + builder + .getAgentAnomalyDetectionScopeSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getMonitoredAgentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listMonitoredAgentsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .enableMonitoredAgentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .disableMonitoredAgentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .deleteAgentAnomalyDetectionScopeSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .createAgentAnomalyDetectionScopeSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listAgentAnomalyDetectionScopesSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listAnalyzedSessionsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getAnalyzedSessionSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listAnalyzedInvocationsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getAnalyzedInvocationSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .aggregateAnalyzedSessionsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .clearTrainingDataSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listLocationsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getLocationSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .setIamPolicySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getIamPolicySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .testIamPermissionsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .enableMonitoredAgentOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(MonitoredAgent.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create( + EnableMonitoredAgentOperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .disableMonitoredAgentOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(MonitoredAgent.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create( + DisableMonitoredAgentOperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .deleteAgentAnomalyDetectionScopeOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + . + newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Empty.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create( + DeleteAgentAnomalyDetectionScopeOperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .createAgentAnomalyDetectionScopeOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + . + newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create( + AgentAnomalyDetectionScope.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create( + CreateAgentAnomalyDetectionScopeOperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .clearTrainingDataOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create( + ClearTrainingDataResponse.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create( + ClearTrainingDataOperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + return builder; + } + + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) { + super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); + return this; + } + + public ImmutableList> unaryMethodSettingsBuilders() { + return unaryMethodSettingsBuilders; + } + + /** Returns the builder for the settings used for calls to getAgentAnomalyDetectionScope. */ + public UnaryCallSettings.Builder< + GetAgentAnomalyDetectionScopeRequest, AgentAnomalyDetectionScope> + getAgentAnomalyDetectionScopeSettings() { + return getAgentAnomalyDetectionScopeSettings; + } + + /** Returns the builder for the settings used for calls to getMonitoredAgent. */ + public UnaryCallSettings.Builder + getMonitoredAgentSettings() { + return getMonitoredAgentSettings; + } + + /** Returns the builder for the settings used for calls to listMonitoredAgents. */ + public PagedCallSettings.Builder< + ListMonitoredAgentsRequest, + ListMonitoredAgentsResponse, + ListMonitoredAgentsPagedResponse> + listMonitoredAgentsSettings() { + return listMonitoredAgentsSettings; + } + + /** Returns the builder for the settings used for calls to enableMonitoredAgent. */ + public UnaryCallSettings.Builder + enableMonitoredAgentSettings() { + return enableMonitoredAgentSettings; + } + + /** Returns the builder for the settings used for calls to enableMonitoredAgent. */ + public OperationCallSettings.Builder< + EnableMonitoredAgentRequest, MonitoredAgent, EnableMonitoredAgentOperationMetadata> + enableMonitoredAgentOperationSettings() { + return enableMonitoredAgentOperationSettings; + } + + /** Returns the builder for the settings used for calls to disableMonitoredAgent. */ + public UnaryCallSettings.Builder + disableMonitoredAgentSettings() { + return disableMonitoredAgentSettings; + } + + /** Returns the builder for the settings used for calls to disableMonitoredAgent. */ + public OperationCallSettings.Builder< + DisableMonitoredAgentRequest, MonitoredAgent, DisableMonitoredAgentOperationMetadata> + disableMonitoredAgentOperationSettings() { + return disableMonitoredAgentOperationSettings; + } + + /** Returns the builder for the settings used for calls to deleteAgentAnomalyDetectionScope. */ + public UnaryCallSettings.Builder + deleteAgentAnomalyDetectionScopeSettings() { + return deleteAgentAnomalyDetectionScopeSettings; + } + + /** Returns the builder for the settings used for calls to deleteAgentAnomalyDetectionScope. */ + public OperationCallSettings.Builder< + DeleteAgentAnomalyDetectionScopeRequest, + Empty, + DeleteAgentAnomalyDetectionScopeOperationMetadata> + deleteAgentAnomalyDetectionScopeOperationSettings() { + return deleteAgentAnomalyDetectionScopeOperationSettings; + } + + /** Returns the builder for the settings used for calls to createAgentAnomalyDetectionScope. */ + public UnaryCallSettings.Builder + createAgentAnomalyDetectionScopeSettings() { + return createAgentAnomalyDetectionScopeSettings; + } + + /** Returns the builder for the settings used for calls to createAgentAnomalyDetectionScope. */ + public OperationCallSettings.Builder< + CreateAgentAnomalyDetectionScopeRequest, + AgentAnomalyDetectionScope, + CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeOperationSettings() { + return createAgentAnomalyDetectionScopeOperationSettings; + } + + /** Returns the builder for the settings used for calls to listAgentAnomalyDetectionScopes. */ + public PagedCallSettings.Builder< + ListAgentAnomalyDetectionScopesRequest, + ListAgentAnomalyDetectionScopesResponse, + ListAgentAnomalyDetectionScopesPagedResponse> + listAgentAnomalyDetectionScopesSettings() { + return listAgentAnomalyDetectionScopesSettings; + } + + /** Returns the builder for the settings used for calls to listAnalyzedSessions. */ + public PagedCallSettings.Builder< + ListAnalyzedSessionsRequest, + ListAnalyzedSessionsResponse, + ListAnalyzedSessionsPagedResponse> + listAnalyzedSessionsSettings() { + return listAnalyzedSessionsSettings; + } + + /** Returns the builder for the settings used for calls to getAnalyzedSession. */ + public UnaryCallSettings.Builder + getAnalyzedSessionSettings() { + return getAnalyzedSessionSettings; + } + + /** Returns the builder for the settings used for calls to listAnalyzedInvocations. */ + public PagedCallSettings.Builder< + ListAnalyzedInvocationsRequest, + ListAnalyzedInvocationsResponse, + ListAnalyzedInvocationsPagedResponse> + listAnalyzedInvocationsSettings() { + return listAnalyzedInvocationsSettings; + } + + /** Returns the builder for the settings used for calls to getAnalyzedInvocation. */ + public UnaryCallSettings.Builder + getAnalyzedInvocationSettings() { + return getAnalyzedInvocationSettings; + } + + /** Returns the builder for the settings used for calls to aggregateAnalyzedSessions. */ + public PagedCallSettings.Builder< + AggregateAnalyzedSessionsRequest, + AggregateAnalyzedSessionsResponse, + AggregateAnalyzedSessionsPagedResponse> + aggregateAnalyzedSessionsSettings() { + return aggregateAnalyzedSessionsSettings; + } + + /** Returns the builder for the settings used for calls to clearTrainingData. */ + public UnaryCallSettings.Builder + clearTrainingDataSettings() { + return clearTrainingDataSettings; + } + + /** Returns the builder for the settings used for calls to clearTrainingData. */ + public OperationCallSettings.Builder< + ClearTrainingDataRequest, ClearTrainingDataResponse, ClearTrainingDataOperationMetadata> + clearTrainingDataOperationSettings() { + return clearTrainingDataOperationSettings; + } + + /** Returns the builder for the settings used for calls to listLocations. */ + public PagedCallSettings.Builder< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings() { + return listLocationsSettings; + } + + /** Returns the builder for the settings used for calls to getLocation. */ + public UnaryCallSettings.Builder getLocationSettings() { + return getLocationSettings; + } + + /** Returns the builder for the settings used for calls to setIamPolicy. */ + public UnaryCallSettings.Builder setIamPolicySettings() { + return setIamPolicySettings; + } + + /** Returns the builder for the settings used for calls to getIamPolicy. */ + public UnaryCallSettings.Builder getIamPolicySettings() { + return getIamPolicySettings; + } + + /** Returns the builder for the settings used for calls to testIamPermissions. */ + public UnaryCallSettings.Builder + testIamPermissionsSettings() { + return testIamPermissionsSettings; + } + + @Override + public AgentAnomalyDetectionServiceStubSettings build() throws IOException { + return new AgentAnomalyDetectionServiceStubSettings(this); + } + } +} diff --git a/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/GrpcAgentAnomalyDetectionServiceCallableFactory.java b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/GrpcAgentAnomalyDetectionServiceCallableFactory.java new file mode 100644 index 000000000000..0dd8b198a478 --- /dev/null +++ b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/GrpcAgentAnomalyDetectionServiceCallableFactory.java @@ -0,0 +1,115 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.stub; + +import com.google.api.gax.grpc.GrpcCallSettings; +import com.google.api.gax.grpc.GrpcCallableFactory; +import com.google.api.gax.grpc.GrpcStubCallableFactory; +import com.google.api.gax.rpc.BatchingCallSettings; +import com.google.api.gax.rpc.BidiStreamingCallable; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientStreamingCallable; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallable; +import com.google.api.gax.rpc.StreamingCallSettings; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.OperationsStub; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC callable factory implementation for the AgentAnomalyDetectionService service API. + * + *

This class is for advanced usage. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class GrpcAgentAnomalyDetectionServiceCallableFactory implements GrpcStubCallableFactory { + + @Override + public UnaryCallable createUnaryCallable( + GrpcCallSettings grpcCallSettings, + UnaryCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createUnaryCallable(grpcCallSettings, callSettings, clientContext); + } + + @Override + public + UnaryCallable createPagedCallable( + GrpcCallSettings grpcCallSettings, + PagedCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createPagedCallable(grpcCallSettings, callSettings, clientContext); + } + + @Override + public UnaryCallable createBatchingCallable( + GrpcCallSettings grpcCallSettings, + BatchingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createBatchingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + OperationCallable createOperationCallable( + GrpcCallSettings grpcCallSettings, + OperationCallSettings callSettings, + ClientContext clientContext, + OperationsStub operationsStub) { + return GrpcCallableFactory.createOperationCallable( + grpcCallSettings, callSettings, clientContext, operationsStub); + } + + @Override + public + BidiStreamingCallable createBidiStreamingCallable( + GrpcCallSettings grpcCallSettings, + StreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createBidiStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + ServerStreamingCallable createServerStreamingCallable( + GrpcCallSettings grpcCallSettings, + ServerStreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createServerStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + ClientStreamingCallable createClientStreamingCallable( + GrpcCallSettings grpcCallSettings, + StreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createClientStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } +} diff --git a/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/GrpcAgentAnomalyDetectionServiceStub.java b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/GrpcAgentAnomalyDetectionServiceStub.java new file mode 100644 index 000000000000..881769a9085b --- /dev/null +++ b/java-aiplatform/google-cloud-aiplatform/src/main/java/com/google/cloud/aiplatform/v1/stub/GrpcAgentAnomalyDetectionServiceStub.java @@ -0,0 +1,1039 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.stub; + +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.AggregateAnalyzedSessionsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAgentAnomalyDetectionScopesPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAnalyzedInvocationsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAnalyzedSessionsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListLocationsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListMonitoredAgentsPagedResponse; + +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.core.BackgroundResourceAggregation; +import com.google.api.gax.grpc.GrpcCallSettings; +import com.google.api.gax.grpc.GrpcStubCallableFactory; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.RequestParamsBuilder; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata; +import com.google.cloud.aiplatform.v1.ClearTrainingDataRequest; +import com.google.cloud.aiplatform.v1.ClearTrainingDataResponse; +import com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata; +import com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata; +import com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata; +import com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata; +import com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest; +import com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest; +import com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest; +import com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse; +import com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest; +import com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse; +import com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest; +import com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.GrpcOperationsStub; +import com.google.protobuf.Empty; +import io.grpc.MethodDescriptor; +import io.grpc.protobuf.ProtoUtils; +import java.io.IOException; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC stub implementation for the AgentAnomalyDetectionService service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class GrpcAgentAnomalyDetectionServiceStub extends AgentAnomalyDetectionServiceStub { + private static final MethodDescriptor< + GetAgentAnomalyDetectionScopeRequest, AgentAnomalyDetectionScope> + getAgentAnomalyDetectionScopeMethodDescriptor = + MethodDescriptor + .newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/GetAgentAnomalyDetectionScope") + .setRequestMarshaller( + ProtoUtils.marshaller(GetAgentAnomalyDetectionScopeRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(AgentAnomalyDetectionScope.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getMonitoredAgentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/GetMonitoredAgent") + .setRequestMarshaller( + ProtoUtils.marshaller(GetMonitoredAgentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(MonitoredAgent.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + listMonitoredAgentsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/ListMonitoredAgents") + .setRequestMarshaller( + ProtoUtils.marshaller(ListMonitoredAgentsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListMonitoredAgentsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + enableMonitoredAgentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/EnableMonitoredAgent") + .setRequestMarshaller( + ProtoUtils.marshaller(EnableMonitoredAgentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + disableMonitoredAgentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/DisableMonitoredAgent") + .setRequestMarshaller( + ProtoUtils.marshaller(DisableMonitoredAgentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + deleteAgentAnomalyDetectionScopeMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/DeleteAgentAnomalyDetectionScope") + .setRequestMarshaller( + ProtoUtils.marshaller( + DeleteAgentAnomalyDetectionScopeRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + createAgentAnomalyDetectionScopeMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/CreateAgentAnomalyDetectionScope") + .setRequestMarshaller( + ProtoUtils.marshaller( + CreateAgentAnomalyDetectionScopeRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor< + ListAgentAnomalyDetectionScopesRequest, ListAgentAnomalyDetectionScopesResponse> + listAgentAnomalyDetectionScopesMethodDescriptor = + MethodDescriptor + . + newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/ListAgentAnomalyDetectionScopes") + .setRequestMarshaller( + ProtoUtils.marshaller( + ListAgentAnomalyDetectionScopesRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller( + ListAgentAnomalyDetectionScopesResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + listAnalyzedSessionsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/ListAnalyzedSessions") + .setRequestMarshaller( + ProtoUtils.marshaller(ListAnalyzedSessionsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListAnalyzedSessionsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getAnalyzedSessionMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/GetAnalyzedSession") + .setRequestMarshaller( + ProtoUtils.marshaller(GetAnalyzedSessionRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(AnalyzedSession.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor< + ListAnalyzedInvocationsRequest, ListAnalyzedInvocationsResponse> + listAnalyzedInvocationsMethodDescriptor = + MethodDescriptor + .newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/ListAnalyzedInvocations") + .setRequestMarshaller( + ProtoUtils.marshaller(ListAnalyzedInvocationsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListAnalyzedInvocationsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getAnalyzedInvocationMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/GetAnalyzedInvocation") + .setRequestMarshaller( + ProtoUtils.marshaller(GetAnalyzedInvocationRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(AnalyzedInvocation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor< + AggregateAnalyzedSessionsRequest, AggregateAnalyzedSessionsResponse> + aggregateAnalyzedSessionsMethodDescriptor = + MethodDescriptor + .newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/AggregateAnalyzedSessions") + .setRequestMarshaller( + ProtoUtils.marshaller(AggregateAnalyzedSessionsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(AggregateAnalyzedSessionsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + clearTrainingDataMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService/ClearTrainingData") + .setRequestMarshaller( + ProtoUtils.marshaller(ClearTrainingDataRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + listLocationsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.location.Locations/ListLocations") + .setRequestMarshaller( + ProtoUtils.marshaller(ListLocationsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListLocationsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor getLocationMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.location.Locations/GetLocation") + .setRequestMarshaller(ProtoUtils.marshaller(GetLocationRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Location.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor setIamPolicyMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.iam.v1.IAMPolicy/SetIamPolicy") + .setRequestMarshaller(ProtoUtils.marshaller(SetIamPolicyRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Policy.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor getIamPolicyMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.iam.v1.IAMPolicy/GetIamPolicy") + .setRequestMarshaller(ProtoUtils.marshaller(GetIamPolicyRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Policy.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + testIamPermissionsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.iam.v1.IAMPolicy/TestIamPermissions") + .setRequestMarshaller( + ProtoUtils.marshaller(TestIamPermissionsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(TestIamPermissionsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private final UnaryCallable + getAgentAnomalyDetectionScopeCallable; + private final UnaryCallable getMonitoredAgentCallable; + private final UnaryCallable + listMonitoredAgentsCallable; + private final UnaryCallable + listMonitoredAgentsPagedCallable; + private final UnaryCallable enableMonitoredAgentCallable; + private final OperationCallable< + EnableMonitoredAgentRequest, MonitoredAgent, EnableMonitoredAgentOperationMetadata> + enableMonitoredAgentOperationCallable; + private final UnaryCallable + disableMonitoredAgentCallable; + private final OperationCallable< + DisableMonitoredAgentRequest, MonitoredAgent, DisableMonitoredAgentOperationMetadata> + disableMonitoredAgentOperationCallable; + private final UnaryCallable + deleteAgentAnomalyDetectionScopeCallable; + private final OperationCallable< + DeleteAgentAnomalyDetectionScopeRequest, + Empty, + DeleteAgentAnomalyDetectionScopeOperationMetadata> + deleteAgentAnomalyDetectionScopeOperationCallable; + private final UnaryCallable + createAgentAnomalyDetectionScopeCallable; + private final OperationCallable< + CreateAgentAnomalyDetectionScopeRequest, + AgentAnomalyDetectionScope, + CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeOperationCallable; + private final UnaryCallable< + ListAgentAnomalyDetectionScopesRequest, ListAgentAnomalyDetectionScopesResponse> + listAgentAnomalyDetectionScopesCallable; + private final UnaryCallable< + ListAgentAnomalyDetectionScopesRequest, ListAgentAnomalyDetectionScopesPagedResponse> + listAgentAnomalyDetectionScopesPagedCallable; + private final UnaryCallable + listAnalyzedSessionsCallable; + private final UnaryCallable + listAnalyzedSessionsPagedCallable; + private final UnaryCallable + getAnalyzedSessionCallable; + private final UnaryCallable + listAnalyzedInvocationsCallable; + private final UnaryCallable + listAnalyzedInvocationsPagedCallable; + private final UnaryCallable + getAnalyzedInvocationCallable; + private final UnaryCallable + aggregateAnalyzedSessionsCallable; + private final UnaryCallable< + AggregateAnalyzedSessionsRequest, AggregateAnalyzedSessionsPagedResponse> + aggregateAnalyzedSessionsPagedCallable; + private final UnaryCallable clearTrainingDataCallable; + private final OperationCallable< + ClearTrainingDataRequest, ClearTrainingDataResponse, ClearTrainingDataOperationMetadata> + clearTrainingDataOperationCallable; + private final UnaryCallable listLocationsCallable; + private final UnaryCallable + listLocationsPagedCallable; + private final UnaryCallable getLocationCallable; + private final UnaryCallable setIamPolicyCallable; + private final UnaryCallable getIamPolicyCallable; + private final UnaryCallable + testIamPermissionsCallable; + + private final BackgroundResource backgroundResources; + private final GrpcOperationsStub operationsStub; + private final GrpcStubCallableFactory callableFactory; + + public static final GrpcAgentAnomalyDetectionServiceStub create( + AgentAnomalyDetectionServiceStubSettings settings) throws IOException { + return new GrpcAgentAnomalyDetectionServiceStub(settings, ClientContext.create(settings)); + } + + public static final GrpcAgentAnomalyDetectionServiceStub create(ClientContext clientContext) + throws IOException { + return new GrpcAgentAnomalyDetectionServiceStub( + AgentAnomalyDetectionServiceStubSettings.newBuilder().build(), clientContext); + } + + public static final GrpcAgentAnomalyDetectionServiceStub create( + ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { + return new GrpcAgentAnomalyDetectionServiceStub( + AgentAnomalyDetectionServiceStubSettings.newBuilder().build(), + clientContext, + callableFactory); + } + + /** + * Constructs an instance of GrpcAgentAnomalyDetectionServiceStub, using the given settings. This + * is protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected GrpcAgentAnomalyDetectionServiceStub( + AgentAnomalyDetectionServiceStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new GrpcAgentAnomalyDetectionServiceCallableFactory()); + } + + /** + * Constructs an instance of GrpcAgentAnomalyDetectionServiceStub, using the given settings. This + * is protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected GrpcAgentAnomalyDetectionServiceStub( + AgentAnomalyDetectionServiceStubSettings settings, + ClientContext clientContext, + GrpcStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); + + GrpcCallSettings + getAgentAnomalyDetectionScopeTransportSettings = + GrpcCallSettings + .newBuilder() + .setMethodDescriptor(getAgentAnomalyDetectionScopeMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings getMonitoredAgentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getMonitoredAgentMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + listMonitoredAgentsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listMonitoredAgentsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings enableMonitoredAgentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(enableMonitoredAgentMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + disableMonitoredAgentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(disableMonitoredAgentMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + deleteAgentAnomalyDetectionScopeTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteAgentAnomalyDetectionScopeMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + createAgentAnomalyDetectionScopeTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createAgentAnomalyDetectionScopeMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings< + ListAgentAnomalyDetectionScopesRequest, ListAgentAnomalyDetectionScopesResponse> + listAgentAnomalyDetectionScopesTransportSettings = + GrpcCallSettings + . + newBuilder() + .setMethodDescriptor(listAgentAnomalyDetectionScopesMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings + listAnalyzedSessionsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listAnalyzedSessionsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings + getAnalyzedSessionTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getAnalyzedSessionMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + listAnalyzedInvocationsTransportSettings = + GrpcCallSettings + .newBuilder() + .setMethodDescriptor(listAnalyzedInvocationsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings + getAnalyzedInvocationTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getAnalyzedInvocationMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + aggregateAnalyzedSessionsTransportSettings = + GrpcCallSettings + .newBuilder() + .setMethodDescriptor(aggregateAnalyzedSessionsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings clearTrainingDataTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(clearTrainingDataMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings listLocationsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listLocationsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings getLocationTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getLocationMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings setIamPolicyTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(setIamPolicyMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("resource", String.valueOf(request.getResource())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getResource()) + .build(); + GrpcCallSettings getIamPolicyTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getIamPolicyMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("resource", String.valueOf(request.getResource())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getResource()) + .build(); + GrpcCallSettings + testIamPermissionsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(testIamPermissionsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("resource", String.valueOf(request.getResource())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getResource()) + .build(); + + this.getAgentAnomalyDetectionScopeCallable = + callableFactory.createUnaryCallable( + getAgentAnomalyDetectionScopeTransportSettings, + settings.getAgentAnomalyDetectionScopeSettings(), + clientContext); + this.getMonitoredAgentCallable = + callableFactory.createUnaryCallable( + getMonitoredAgentTransportSettings, + settings.getMonitoredAgentSettings(), + clientContext); + this.listMonitoredAgentsCallable = + callableFactory.createUnaryCallable( + listMonitoredAgentsTransportSettings, + settings.listMonitoredAgentsSettings(), + clientContext); + this.listMonitoredAgentsPagedCallable = + callableFactory.createPagedCallable( + listMonitoredAgentsTransportSettings, + settings.listMonitoredAgentsSettings(), + clientContext); + this.enableMonitoredAgentCallable = + callableFactory.createUnaryCallable( + enableMonitoredAgentTransportSettings, + settings.enableMonitoredAgentSettings(), + clientContext); + this.enableMonitoredAgentOperationCallable = + callableFactory.createOperationCallable( + enableMonitoredAgentTransportSettings, + settings.enableMonitoredAgentOperationSettings(), + clientContext, + operationsStub); + this.disableMonitoredAgentCallable = + callableFactory.createUnaryCallable( + disableMonitoredAgentTransportSettings, + settings.disableMonitoredAgentSettings(), + clientContext); + this.disableMonitoredAgentOperationCallable = + callableFactory.createOperationCallable( + disableMonitoredAgentTransportSettings, + settings.disableMonitoredAgentOperationSettings(), + clientContext, + operationsStub); + this.deleteAgentAnomalyDetectionScopeCallable = + callableFactory.createUnaryCallable( + deleteAgentAnomalyDetectionScopeTransportSettings, + settings.deleteAgentAnomalyDetectionScopeSettings(), + clientContext); + this.deleteAgentAnomalyDetectionScopeOperationCallable = + callableFactory.createOperationCallable( + deleteAgentAnomalyDetectionScopeTransportSettings, + settings.deleteAgentAnomalyDetectionScopeOperationSettings(), + clientContext, + operationsStub); + this.createAgentAnomalyDetectionScopeCallable = + callableFactory.createUnaryCallable( + createAgentAnomalyDetectionScopeTransportSettings, + settings.createAgentAnomalyDetectionScopeSettings(), + clientContext); + this.createAgentAnomalyDetectionScopeOperationCallable = + callableFactory.createOperationCallable( + createAgentAnomalyDetectionScopeTransportSettings, + settings.createAgentAnomalyDetectionScopeOperationSettings(), + clientContext, + operationsStub); + this.listAgentAnomalyDetectionScopesCallable = + callableFactory.createUnaryCallable( + listAgentAnomalyDetectionScopesTransportSettings, + settings.listAgentAnomalyDetectionScopesSettings(), + clientContext); + this.listAgentAnomalyDetectionScopesPagedCallable = + callableFactory.createPagedCallable( + listAgentAnomalyDetectionScopesTransportSettings, + settings.listAgentAnomalyDetectionScopesSettings(), + clientContext); + this.listAnalyzedSessionsCallable = + callableFactory.createUnaryCallable( + listAnalyzedSessionsTransportSettings, + settings.listAnalyzedSessionsSettings(), + clientContext); + this.listAnalyzedSessionsPagedCallable = + callableFactory.createPagedCallable( + listAnalyzedSessionsTransportSettings, + settings.listAnalyzedSessionsSettings(), + clientContext); + this.getAnalyzedSessionCallable = + callableFactory.createUnaryCallable( + getAnalyzedSessionTransportSettings, + settings.getAnalyzedSessionSettings(), + clientContext); + this.listAnalyzedInvocationsCallable = + callableFactory.createUnaryCallable( + listAnalyzedInvocationsTransportSettings, + settings.listAnalyzedInvocationsSettings(), + clientContext); + this.listAnalyzedInvocationsPagedCallable = + callableFactory.createPagedCallable( + listAnalyzedInvocationsTransportSettings, + settings.listAnalyzedInvocationsSettings(), + clientContext); + this.getAnalyzedInvocationCallable = + callableFactory.createUnaryCallable( + getAnalyzedInvocationTransportSettings, + settings.getAnalyzedInvocationSettings(), + clientContext); + this.aggregateAnalyzedSessionsCallable = + callableFactory.createUnaryCallable( + aggregateAnalyzedSessionsTransportSettings, + settings.aggregateAnalyzedSessionsSettings(), + clientContext); + this.aggregateAnalyzedSessionsPagedCallable = + callableFactory.createPagedCallable( + aggregateAnalyzedSessionsTransportSettings, + settings.aggregateAnalyzedSessionsSettings(), + clientContext); + this.clearTrainingDataCallable = + callableFactory.createUnaryCallable( + clearTrainingDataTransportSettings, + settings.clearTrainingDataSettings(), + clientContext); + this.clearTrainingDataOperationCallable = + callableFactory.createOperationCallable( + clearTrainingDataTransportSettings, + settings.clearTrainingDataOperationSettings(), + clientContext, + operationsStub); + this.listLocationsCallable = + callableFactory.createUnaryCallable( + listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); + this.listLocationsPagedCallable = + callableFactory.createPagedCallable( + listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); + this.getLocationCallable = + callableFactory.createUnaryCallable( + getLocationTransportSettings, settings.getLocationSettings(), clientContext); + this.setIamPolicyCallable = + callableFactory.createUnaryCallable( + setIamPolicyTransportSettings, settings.setIamPolicySettings(), clientContext); + this.getIamPolicyCallable = + callableFactory.createUnaryCallable( + getIamPolicyTransportSettings, settings.getIamPolicySettings(), clientContext); + this.testIamPermissionsCallable = + callableFactory.createUnaryCallable( + testIamPermissionsTransportSettings, + settings.testIamPermissionsSettings(), + clientContext); + + this.backgroundResources = + new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + public GrpcOperationsStub getOperationsStub() { + return operationsStub; + } + + @Override + public UnaryCallable + getAgentAnomalyDetectionScopeCallable() { + return getAgentAnomalyDetectionScopeCallable; + } + + @Override + public UnaryCallable getMonitoredAgentCallable() { + return getMonitoredAgentCallable; + } + + @Override + public UnaryCallable + listMonitoredAgentsCallable() { + return listMonitoredAgentsCallable; + } + + @Override + public UnaryCallable + listMonitoredAgentsPagedCallable() { + return listMonitoredAgentsPagedCallable; + } + + @Override + public UnaryCallable enableMonitoredAgentCallable() { + return enableMonitoredAgentCallable; + } + + @Override + public OperationCallable< + EnableMonitoredAgentRequest, MonitoredAgent, EnableMonitoredAgentOperationMetadata> + enableMonitoredAgentOperationCallable() { + return enableMonitoredAgentOperationCallable; + } + + @Override + public UnaryCallable disableMonitoredAgentCallable() { + return disableMonitoredAgentCallable; + } + + @Override + public OperationCallable< + DisableMonitoredAgentRequest, MonitoredAgent, DisableMonitoredAgentOperationMetadata> + disableMonitoredAgentOperationCallable() { + return disableMonitoredAgentOperationCallable; + } + + @Override + public UnaryCallable + deleteAgentAnomalyDetectionScopeCallable() { + return deleteAgentAnomalyDetectionScopeCallable; + } + + @Override + public OperationCallable< + DeleteAgentAnomalyDetectionScopeRequest, + Empty, + DeleteAgentAnomalyDetectionScopeOperationMetadata> + deleteAgentAnomalyDetectionScopeOperationCallable() { + return deleteAgentAnomalyDetectionScopeOperationCallable; + } + + @Override + public UnaryCallable + createAgentAnomalyDetectionScopeCallable() { + return createAgentAnomalyDetectionScopeCallable; + } + + @Override + public OperationCallable< + CreateAgentAnomalyDetectionScopeRequest, + AgentAnomalyDetectionScope, + CreateAgentAnomalyDetectionScopeOperationMetadata> + createAgentAnomalyDetectionScopeOperationCallable() { + return createAgentAnomalyDetectionScopeOperationCallable; + } + + @Override + public UnaryCallable< + ListAgentAnomalyDetectionScopesRequest, ListAgentAnomalyDetectionScopesResponse> + listAgentAnomalyDetectionScopesCallable() { + return listAgentAnomalyDetectionScopesCallable; + } + + @Override + public UnaryCallable< + ListAgentAnomalyDetectionScopesRequest, ListAgentAnomalyDetectionScopesPagedResponse> + listAgentAnomalyDetectionScopesPagedCallable() { + return listAgentAnomalyDetectionScopesPagedCallable; + } + + @Override + public UnaryCallable + listAnalyzedSessionsCallable() { + return listAnalyzedSessionsCallable; + } + + @Override + public UnaryCallable + listAnalyzedSessionsPagedCallable() { + return listAnalyzedSessionsPagedCallable; + } + + @Override + public UnaryCallable getAnalyzedSessionCallable() { + return getAnalyzedSessionCallable; + } + + @Override + public UnaryCallable + listAnalyzedInvocationsCallable() { + return listAnalyzedInvocationsCallable; + } + + @Override + public UnaryCallable + listAnalyzedInvocationsPagedCallable() { + return listAnalyzedInvocationsPagedCallable; + } + + @Override + public UnaryCallable + getAnalyzedInvocationCallable() { + return getAnalyzedInvocationCallable; + } + + @Override + public UnaryCallable + aggregateAnalyzedSessionsCallable() { + return aggregateAnalyzedSessionsCallable; + } + + @Override + public UnaryCallable + aggregateAnalyzedSessionsPagedCallable() { + return aggregateAnalyzedSessionsPagedCallable; + } + + @Override + public UnaryCallable clearTrainingDataCallable() { + return clearTrainingDataCallable; + } + + @Override + public OperationCallable< + ClearTrainingDataRequest, ClearTrainingDataResponse, ClearTrainingDataOperationMetadata> + clearTrainingDataOperationCallable() { + return clearTrainingDataOperationCallable; + } + + @Override + public UnaryCallable listLocationsCallable() { + return listLocationsCallable; + } + + @Override + public UnaryCallable + listLocationsPagedCallable() { + return listLocationsPagedCallable; + } + + @Override + public UnaryCallable getLocationCallable() { + return getLocationCallable; + } + + @Override + public UnaryCallable setIamPolicyCallable() { + return setIamPolicyCallable; + } + + @Override + public UnaryCallable getIamPolicyCallable() { + return getIamPolicyCallable; + } + + @Override + public UnaryCallable + testIamPermissionsCallable() { + return testIamPermissionsCallable; + } + + @Override + public final void close() { + try { + backgroundResources.close(); + } catch (RuntimeException e) { + throw e; + } catch (Exception e) { + throw new IllegalStateException("Failed to close resource", e); + } + } + + @Override + public void shutdown() { + backgroundResources.shutdown(); + } + + @Override + public boolean isShutdown() { + return backgroundResources.isShutdown(); + } + + @Override + public boolean isTerminated() { + return backgroundResources.isTerminated(); + } + + @Override + public void shutdownNow() { + backgroundResources.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return backgroundResources.awaitTermination(duration, unit); + } +} diff --git a/java-aiplatform/google-cloud-aiplatform/src/main/resources/META-INF/native-image/com.google.cloud.aiplatform.v1/reflect-config.json b/java-aiplatform/google-cloud-aiplatform/src/main/resources/META-INF/native-image/com.google.cloud.aiplatform.v1/reflect-config.json index 7a9cf28c510c..9c7c755b719b 100644 --- a/java-aiplatform/google-cloud-aiplatform/src/main/resources/META-INF/native-image/com.google.cloud.aiplatform.v1/reflect-config.json +++ b/java-aiplatform/google-cloud-aiplatform/src/main/resources/META-INF/native-image/com.google.cloud.aiplatform.v1/reflect-config.json @@ -647,6 +647,123 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope$State", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AgentResource", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AgentResource$AgentFramework", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AgentResource$AgentType", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AgentResource$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse$AgentAggregate", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse$AgentAggregate$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.AggregationOutput", "queryAllDeclaredConstructors": true, @@ -683,6 +800,87 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.AnalyzedInvocation", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AnalyzedInvocation$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AnalyzedInvocation$InvocationState", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AnalyzedSession", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AnalyzedSession$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AnalyzedSession$SessionState", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AnalyzedSession$SeveritySummary", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AnalyzedSession$SeveritySummary$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.AnalyzedSessionView", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.Annotation", "queryAllDeclaredConstructors": true, @@ -854,6 +1052,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.Assessment", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.Assessment$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.Assessment$DetectorFinding", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.Assessment$DetectorFinding$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.AssignNotebookRuntimeOperationMetadata", "queryAllDeclaredConstructors": true, @@ -2285,6 +2519,60 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ClearTrainingDataRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ClearTrainingDataRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ClearTrainingDataResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ClearTrainingDataResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.ClientConnectionConfig", "queryAllDeclaredConstructors": true, @@ -2879,6 +3167,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.CreateArtifactRequest", "queryAllDeclaredConstructors": true, @@ -4229,6 +4553,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.DeleteArtifactRequest", "queryAllDeclaredConstructors": true, @@ -5669,6 +6029,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.DiskSpec", "queryAllDeclaredConstructors": true, @@ -5742,7 +6138,43 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.aiplatform.v1.DynamicRetrievalConfig$Mode", + "name": "com.google.cloud.aiplatform.v1.DynamicRetrievalConfig$Mode", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.EmbedContentRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.EmbedContentRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.EmbedContentRequest$EmbedContentConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.EmbedContentRequest$EmbedContentConfig$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -5751,7 +6183,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.aiplatform.v1.EmbedContentRequest", + "name": "com.google.cloud.aiplatform.v1.EmbedContentRequest$EmbeddingTaskType", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -5760,7 +6192,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.aiplatform.v1.EmbedContentRequest$Builder", + "name": "com.google.cloud.aiplatform.v1.EmbedContentResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -5769,7 +6201,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.aiplatform.v1.EmbedContentRequest$EmbedContentConfig", + "name": "com.google.cloud.aiplatform.v1.EmbedContentResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -5778,7 +6210,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.aiplatform.v1.EmbedContentRequest$EmbedContentConfig$Builder", + "name": "com.google.cloud.aiplatform.v1.EmbedContentResponse$Embedding", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -5787,7 +6219,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.aiplatform.v1.EmbedContentRequest$EmbeddingTaskType", + "name": "com.google.cloud.aiplatform.v1.EmbedContentResponse$Embedding$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -5796,7 +6228,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.aiplatform.v1.EmbedContentResponse", + "name": "com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -5805,7 +6237,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.aiplatform.v1.EmbedContentResponse$Builder", + "name": "com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -5814,7 +6246,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.aiplatform.v1.EmbedContentResponse$Embedding", + "name": "com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -5823,7 +6255,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.aiplatform.v1.EmbedContentResponse$Embedding$Builder", + "name": "com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -8927,6 +9359,60 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.GetAnnotationSpecRequest", "queryAllDeclaredConstructors": true, @@ -9431,6 +9917,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.GetNasJobRequest", "queryAllDeclaredConstructors": true, @@ -10835,6 +11339,132 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse$ViewSummary", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse$ViewSummary$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.ListAnnotationsRequest", "queryAllDeclaredConstructors": true, @@ -11987,6 +12617,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.ListNasJobsRequest", "queryAllDeclaredConstructors": true, @@ -14147,6 +14813,33 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.MonitoredAgent", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.MonitoredAgent$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.aiplatform.v1.MonitoredAgent$EnablementState", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.MultiSpeakerVoiceConfig", "queryAllDeclaredConstructors": true, @@ -19448,6 +20141,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.aiplatform.v1.Severity", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.aiplatform.v1.SharePointSources", "queryAllDeclaredConstructors": true, diff --git a/java-aiplatform/google-cloud-aiplatform/src/test/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceClientTest.java b/java-aiplatform/google-cloud-aiplatform/src/test/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceClientTest.java new file mode 100644 index 000000000000..86bb805a541a --- /dev/null +++ b/java-aiplatform/google-cloud-aiplatform/src/test/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceClientTest.java @@ -0,0 +1,1781 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1; + +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.AggregateAnalyzedSessionsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAgentAnomalyDetectionScopesPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAnalyzedInvocationsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListAnalyzedSessionsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListLocationsPagedResponse; +import static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient.ListMonitoredAgentsPagedResponse; + +import com.google.api.gax.core.NoCredentialsProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.testing.LocalChannelProvider; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.api.gax.grpc.testing.MockServiceHelper; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.InvalidArgumentException; +import com.google.api.gax.rpc.StatusCode; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.collect.Lists; +import com.google.iam.v1.AuditConfig; +import com.google.iam.v1.Binding; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.GetPolicyOptions; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.protobuf.AbstractMessage; +import com.google.protobuf.Any; +import com.google.protobuf.ByteString; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import com.google.protobuf.Timestamp; +import io.grpc.StatusRuntimeException; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.UUID; +import java.util.concurrent.ExecutionException; +import javax.annotation.Generated; +import org.junit.After; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; + +@Generated("by gapic-generator-java") +public class AgentAnomalyDetectionServiceClientTest { + private static MockAgentAnomalyDetectionService mockAgentAnomalyDetectionService; + private static MockIAMPolicy mockIAMPolicy; + private static MockLocations mockLocations; + private static MockServiceHelper mockServiceHelper; + private LocalChannelProvider channelProvider; + private AgentAnomalyDetectionServiceClient client; + + @BeforeClass + public static void startStaticServer() { + mockAgentAnomalyDetectionService = new MockAgentAnomalyDetectionService(); + mockLocations = new MockLocations(); + mockIAMPolicy = new MockIAMPolicy(); + mockServiceHelper = + new MockServiceHelper( + UUID.randomUUID().toString(), + Arrays.asList( + mockAgentAnomalyDetectionService, mockLocations, mockIAMPolicy)); + mockServiceHelper.start(); + } + + @AfterClass + public static void stopServer() { + mockServiceHelper.stop(); + } + + @Before + public void setUp() throws IOException { + mockServiceHelper.reset(); + channelProvider = mockServiceHelper.createChannelProvider(); + AgentAnomalyDetectionServiceSettings settings = + AgentAnomalyDetectionServiceSettings.newBuilder() + .setTransportChannelProvider(channelProvider) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = AgentAnomalyDetectionServiceClient.create(settings); + } + + @After + public void tearDown() throws Exception { + client.close(); + } + + @Test + public void getAgentAnomalyDetectionScopeTest() throws Exception { + AgentAnomalyDetectionScope expectedResponse = + AgentAnomalyDetectionScope.newBuilder() + .setName( + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]") + .toString()) + .setDisplayName("displayName1714148973") + .addAllLogBuckets(new ArrayList()) + .addAllObservabilityBuckets(new ArrayList()) + .setAutoEnroll(true) + .setEncryptionSpec(EncryptionSpec.newBuilder().build()) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + AgentAnomalyDetectionScopeName name = + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]"); + + AgentAnomalyDetectionScope actualResponse = client.getAgentAnomalyDetectionScope(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAgentAnomalyDetectionScopeRequest actualRequest = + ((GetAgentAnomalyDetectionScopeRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAgentAnomalyDetectionScopeExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + AgentAnomalyDetectionScopeName name = + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]"); + client.getAgentAnomalyDetectionScope(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAgentAnomalyDetectionScopeTest2() throws Exception { + AgentAnomalyDetectionScope expectedResponse = + AgentAnomalyDetectionScope.newBuilder() + .setName( + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]") + .toString()) + .setDisplayName("displayName1714148973") + .addAllLogBuckets(new ArrayList()) + .addAllObservabilityBuckets(new ArrayList()) + .setAutoEnroll(true) + .setEncryptionSpec(EncryptionSpec.newBuilder().build()) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + String name = "name3373707"; + + AgentAnomalyDetectionScope actualResponse = client.getAgentAnomalyDetectionScope(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAgentAnomalyDetectionScopeRequest actualRequest = + ((GetAgentAnomalyDetectionScopeRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAgentAnomalyDetectionScopeExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String name = "name3373707"; + client.getAgentAnomalyDetectionScope(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getMonitoredAgentTest() throws Exception { + MonitoredAgent expectedResponse = + MonitoredAgent.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setDisplayName("displayName1714148973") + .setAgentResource(AgentResource.newBuilder().build()) + .setStatusMessage("statusMessage-958704715") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + MonitoredAgentName name = MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + + MonitoredAgent actualResponse = client.getMonitoredAgent(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetMonitoredAgentRequest actualRequest = ((GetMonitoredAgentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getMonitoredAgentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + MonitoredAgentName name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + client.getMonitoredAgent(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getMonitoredAgentTest2() throws Exception { + MonitoredAgent expectedResponse = + MonitoredAgent.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setDisplayName("displayName1714148973") + .setAgentResource(AgentResource.newBuilder().build()) + .setStatusMessage("statusMessage-958704715") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + String name = "name3373707"; + + MonitoredAgent actualResponse = client.getMonitoredAgent(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetMonitoredAgentRequest actualRequest = ((GetMonitoredAgentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getMonitoredAgentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String name = "name3373707"; + client.getMonitoredAgent(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listMonitoredAgentsTest() throws Exception { + MonitoredAgent responsesElement = MonitoredAgent.newBuilder().build(); + ListMonitoredAgentsResponse expectedResponse = + ListMonitoredAgentsResponse.newBuilder() + .setNextPageToken("") + .addAllMonitoredAgents(Arrays.asList(responsesElement)) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListMonitoredAgentsPagedResponse pagedListResponse = client.listMonitoredAgents(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getMonitoredAgentsList().get(0), resources.get(0)); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListMonitoredAgentsRequest actualRequest = ((ListMonitoredAgentsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listMonitoredAgentsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listMonitoredAgents(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listMonitoredAgentsTest2() throws Exception { + MonitoredAgent responsesElement = MonitoredAgent.newBuilder().build(); + ListMonitoredAgentsResponse expectedResponse = + ListMonitoredAgentsResponse.newBuilder() + .setNextPageToken("") + .addAllMonitoredAgents(Arrays.asList(responsesElement)) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListMonitoredAgentsPagedResponse pagedListResponse = client.listMonitoredAgents(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getMonitoredAgentsList().get(0), resources.get(0)); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListMonitoredAgentsRequest actualRequest = ((ListMonitoredAgentsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listMonitoredAgentsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String parent = "parent-995424086"; + client.listMonitoredAgents(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void enableMonitoredAgentTest() throws Exception { + MonitoredAgent expectedResponse = + MonitoredAgent.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setDisplayName("displayName1714148973") + .setAgentResource(AgentResource.newBuilder().build()) + .setStatusMessage("statusMessage-958704715") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("enableMonitoredAgentTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentAnomalyDetectionService.addResponse(resultOperation); + + MonitoredAgentName name = MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + + MonitoredAgent actualResponse = client.enableMonitoredAgentAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + EnableMonitoredAgentRequest actualRequest = + ((EnableMonitoredAgentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void enableMonitoredAgentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + MonitoredAgentName name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + client.enableMonitoredAgentAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void enableMonitoredAgentTest2() throws Exception { + MonitoredAgent expectedResponse = + MonitoredAgent.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setDisplayName("displayName1714148973") + .setAgentResource(AgentResource.newBuilder().build()) + .setStatusMessage("statusMessage-958704715") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("enableMonitoredAgentTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentAnomalyDetectionService.addResponse(resultOperation); + + String name = "name3373707"; + + MonitoredAgent actualResponse = client.enableMonitoredAgentAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + EnableMonitoredAgentRequest actualRequest = + ((EnableMonitoredAgentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void enableMonitoredAgentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String name = "name3373707"; + client.enableMonitoredAgentAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void disableMonitoredAgentTest() throws Exception { + MonitoredAgent expectedResponse = + MonitoredAgent.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setDisplayName("displayName1714148973") + .setAgentResource(AgentResource.newBuilder().build()) + .setStatusMessage("statusMessage-958704715") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("disableMonitoredAgentTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentAnomalyDetectionService.addResponse(resultOperation); + + MonitoredAgentName name = MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + + MonitoredAgent actualResponse = client.disableMonitoredAgentAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DisableMonitoredAgentRequest actualRequest = + ((DisableMonitoredAgentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void disableMonitoredAgentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + MonitoredAgentName name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + client.disableMonitoredAgentAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void disableMonitoredAgentTest2() throws Exception { + MonitoredAgent expectedResponse = + MonitoredAgent.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setDisplayName("displayName1714148973") + .setAgentResource(AgentResource.newBuilder().build()) + .setStatusMessage("statusMessage-958704715") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("disableMonitoredAgentTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentAnomalyDetectionService.addResponse(resultOperation); + + String name = "name3373707"; + + MonitoredAgent actualResponse = client.disableMonitoredAgentAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DisableMonitoredAgentRequest actualRequest = + ((DisableMonitoredAgentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void disableMonitoredAgentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String name = "name3373707"; + client.disableMonitoredAgentAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteAgentAnomalyDetectionScopeTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteAgentAnomalyDetectionScopeTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentAnomalyDetectionService.addResponse(resultOperation); + + AgentAnomalyDetectionScopeName name = + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]"); + + client.deleteAgentAnomalyDetectionScopeAsync(name).get(); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteAgentAnomalyDetectionScopeRequest actualRequest = + ((DeleteAgentAnomalyDetectionScopeRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteAgentAnomalyDetectionScopeExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + AgentAnomalyDetectionScopeName name = + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]"); + client.deleteAgentAnomalyDetectionScopeAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteAgentAnomalyDetectionScopeTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteAgentAnomalyDetectionScopeTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentAnomalyDetectionService.addResponse(resultOperation); + + String name = "name3373707"; + + client.deleteAgentAnomalyDetectionScopeAsync(name).get(); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteAgentAnomalyDetectionScopeRequest actualRequest = + ((DeleteAgentAnomalyDetectionScopeRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteAgentAnomalyDetectionScopeExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String name = "name3373707"; + client.deleteAgentAnomalyDetectionScopeAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void createAgentAnomalyDetectionScopeTest() throws Exception { + AgentAnomalyDetectionScope expectedResponse = + AgentAnomalyDetectionScope.newBuilder() + .setName( + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]") + .toString()) + .setDisplayName("displayName1714148973") + .addAllLogBuckets(new ArrayList()) + .addAllObservabilityBuckets(new ArrayList()) + .setAutoEnroll(true) + .setEncryptionSpec(EncryptionSpec.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createAgentAnomalyDetectionScopeTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentAnomalyDetectionService.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + AgentAnomalyDetectionScope agentAnomalyDetectionScope = + AgentAnomalyDetectionScope.newBuilder().build(); + String agentAnomalyDetectionScopeId = "agentAnomalyDetectionScopeId-218530648"; + + AgentAnomalyDetectionScope actualResponse = + client + .createAgentAnomalyDetectionScopeAsync( + parent, agentAnomalyDetectionScope, agentAnomalyDetectionScopeId) + .get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateAgentAnomalyDetectionScopeRequest actualRequest = + ((CreateAgentAnomalyDetectionScopeRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(agentAnomalyDetectionScope, actualRequest.getAgentAnomalyDetectionScope()); + Assert.assertEquals( + agentAnomalyDetectionScopeId, actualRequest.getAgentAnomalyDetectionScopeId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createAgentAnomalyDetectionScopeExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + AgentAnomalyDetectionScope agentAnomalyDetectionScope = + AgentAnomalyDetectionScope.newBuilder().build(); + String agentAnomalyDetectionScopeId = "agentAnomalyDetectionScopeId-218530648"; + client + .createAgentAnomalyDetectionScopeAsync( + parent, agentAnomalyDetectionScope, agentAnomalyDetectionScopeId) + .get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void createAgentAnomalyDetectionScopeTest2() throws Exception { + AgentAnomalyDetectionScope expectedResponse = + AgentAnomalyDetectionScope.newBuilder() + .setName( + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]") + .toString()) + .setDisplayName("displayName1714148973") + .addAllLogBuckets(new ArrayList()) + .addAllObservabilityBuckets(new ArrayList()) + .setAutoEnroll(true) + .setEncryptionSpec(EncryptionSpec.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createAgentAnomalyDetectionScopeTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentAnomalyDetectionService.addResponse(resultOperation); + + String parent = "parent-995424086"; + AgentAnomalyDetectionScope agentAnomalyDetectionScope = + AgentAnomalyDetectionScope.newBuilder().build(); + String agentAnomalyDetectionScopeId = "agentAnomalyDetectionScopeId-218530648"; + + AgentAnomalyDetectionScope actualResponse = + client + .createAgentAnomalyDetectionScopeAsync( + parent, agentAnomalyDetectionScope, agentAnomalyDetectionScopeId) + .get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateAgentAnomalyDetectionScopeRequest actualRequest = + ((CreateAgentAnomalyDetectionScopeRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(agentAnomalyDetectionScope, actualRequest.getAgentAnomalyDetectionScope()); + Assert.assertEquals( + agentAnomalyDetectionScopeId, actualRequest.getAgentAnomalyDetectionScopeId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createAgentAnomalyDetectionScopeExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String parent = "parent-995424086"; + AgentAnomalyDetectionScope agentAnomalyDetectionScope = + AgentAnomalyDetectionScope.newBuilder().build(); + String agentAnomalyDetectionScopeId = "agentAnomalyDetectionScopeId-218530648"; + client + .createAgentAnomalyDetectionScopeAsync( + parent, agentAnomalyDetectionScope, agentAnomalyDetectionScopeId) + .get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void listAgentAnomalyDetectionScopesTest() throws Exception { + AgentAnomalyDetectionScope responsesElement = AgentAnomalyDetectionScope.newBuilder().build(); + ListAgentAnomalyDetectionScopesResponse expectedResponse = + ListAgentAnomalyDetectionScopesResponse.newBuilder() + .setNextPageToken("") + .addAllAgentAnomalyDetectionScopes(Arrays.asList(responsesElement)) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListAgentAnomalyDetectionScopesPagedResponse pagedListResponse = + client.listAgentAnomalyDetectionScopes(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals( + expectedResponse.getAgentAnomalyDetectionScopesList().get(0), resources.get(0)); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAgentAnomalyDetectionScopesRequest actualRequest = + ((ListAgentAnomalyDetectionScopesRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAgentAnomalyDetectionScopesExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listAgentAnomalyDetectionScopes(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAgentAnomalyDetectionScopesTest2() throws Exception { + AgentAnomalyDetectionScope responsesElement = AgentAnomalyDetectionScope.newBuilder().build(); + ListAgentAnomalyDetectionScopesResponse expectedResponse = + ListAgentAnomalyDetectionScopesResponse.newBuilder() + .setNextPageToken("") + .addAllAgentAnomalyDetectionScopes(Arrays.asList(responsesElement)) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListAgentAnomalyDetectionScopesPagedResponse pagedListResponse = + client.listAgentAnomalyDetectionScopes(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals( + expectedResponse.getAgentAnomalyDetectionScopesList().get(0), resources.get(0)); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAgentAnomalyDetectionScopesRequest actualRequest = + ((ListAgentAnomalyDetectionScopesRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAgentAnomalyDetectionScopesExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String parent = "parent-995424086"; + client.listAgentAnomalyDetectionScopes(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAnalyzedSessionsTest() throws Exception { + AnalyzedSession responsesElement = AnalyzedSession.newBuilder().build(); + ListAnalyzedSessionsResponse expectedResponse = + ListAnalyzedSessionsResponse.newBuilder() + .setNextPageToken("") + .addAllAnalyzedSessions(Arrays.asList(responsesElement)) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + MonitoredAgentName parent = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + + ListAnalyzedSessionsPagedResponse pagedListResponse = client.listAnalyzedSessions(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAnalyzedSessionsList().get(0), resources.get(0)); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAnalyzedSessionsRequest actualRequest = + ((ListAnalyzedSessionsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAnalyzedSessionsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + MonitoredAgentName parent = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + client.listAnalyzedSessions(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAnalyzedSessionsTest2() throws Exception { + AnalyzedSession responsesElement = AnalyzedSession.newBuilder().build(); + ListAnalyzedSessionsResponse expectedResponse = + ListAnalyzedSessionsResponse.newBuilder() + .setNextPageToken("") + .addAllAnalyzedSessions(Arrays.asList(responsesElement)) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListAnalyzedSessionsPagedResponse pagedListResponse = client.listAnalyzedSessions(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAnalyzedSessionsList().get(0), resources.get(0)); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAnalyzedSessionsRequest actualRequest = + ((ListAnalyzedSessionsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAnalyzedSessionsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String parent = "parent-995424086"; + client.listAnalyzedSessions(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAnalyzedSessionTest() throws Exception { + AnalyzedSession expectedResponse = + AnalyzedSession.newBuilder() + .setName( + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]") + .toString()) + .setSessionId("sessionId607796817") + .setUserId("userId-836030906") + .setAgentResourceName( + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setLatestAnalyzedTime(Timestamp.newBuilder().build()) + .setAssessment(Assessment.newBuilder().build()) + .putAllSeverities(new HashMap()) + .setAgentDisplayName("agentDisplayName2121176616") + .setLocation("location1901043637") + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + AnalyzedSessionName name = + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]"); + + AnalyzedSession actualResponse = client.getAnalyzedSession(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAnalyzedSessionRequest actualRequest = ((GetAnalyzedSessionRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAnalyzedSessionExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + AnalyzedSessionName name = + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]"); + client.getAnalyzedSession(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAnalyzedSessionTest2() throws Exception { + AnalyzedSession expectedResponse = + AnalyzedSession.newBuilder() + .setName( + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]") + .toString()) + .setSessionId("sessionId607796817") + .setUserId("userId-836030906") + .setAgentResourceName( + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setLatestAnalyzedTime(Timestamp.newBuilder().build()) + .setAssessment(Assessment.newBuilder().build()) + .putAllSeverities(new HashMap()) + .setAgentDisplayName("agentDisplayName2121176616") + .setLocation("location1901043637") + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + String name = "name3373707"; + + AnalyzedSession actualResponse = client.getAnalyzedSession(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAnalyzedSessionRequest actualRequest = ((GetAnalyzedSessionRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAnalyzedSessionExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String name = "name3373707"; + client.getAnalyzedSession(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAnalyzedInvocationsTest() throws Exception { + AnalyzedInvocation responsesElement = AnalyzedInvocation.newBuilder().build(); + ListAnalyzedInvocationsResponse expectedResponse = + ListAnalyzedInvocationsResponse.newBuilder() + .setNextPageToken("") + .addAllAnalyzedInvocations(Arrays.asList(responsesElement)) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + AnalyzedSessionName parent = + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]"); + + ListAnalyzedInvocationsPagedResponse pagedListResponse = client.listAnalyzedInvocations(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAnalyzedInvocationsList().get(0), resources.get(0)); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAnalyzedInvocationsRequest actualRequest = + ((ListAnalyzedInvocationsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAnalyzedInvocationsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + AnalyzedSessionName parent = + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]"); + client.listAnalyzedInvocations(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAnalyzedInvocationsTest2() throws Exception { + AnalyzedInvocation responsesElement = AnalyzedInvocation.newBuilder().build(); + ListAnalyzedInvocationsResponse expectedResponse = + ListAnalyzedInvocationsResponse.newBuilder() + .setNextPageToken("") + .addAllAnalyzedInvocations(Arrays.asList(responsesElement)) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListAnalyzedInvocationsPagedResponse pagedListResponse = client.listAnalyzedInvocations(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAnalyzedInvocationsList().get(0), resources.get(0)); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListAnalyzedInvocationsRequest actualRequest = + ((ListAnalyzedInvocationsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listAnalyzedInvocationsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String parent = "parent-995424086"; + client.listAnalyzedInvocations(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAnalyzedInvocationTest() throws Exception { + AnalyzedInvocation expectedResponse = + AnalyzedInvocation.newBuilder() + .setName( + AnalyzedInvocationName.of( + "[PROJECT]", + "[LOCATION]", + "[MONITORED_AGENT]", + "[ANALYZED_SESSION]", + "[ANALYZED_INVOCATION]") + .toString()) + .setInvocationId("invocationId149331403") + .setAssessment(Assessment.newBuilder().build()) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + AnalyzedInvocationName name = + AnalyzedInvocationName.of( + "[PROJECT]", + "[LOCATION]", + "[MONITORED_AGENT]", + "[ANALYZED_SESSION]", + "[ANALYZED_INVOCATION]"); + + AnalyzedInvocation actualResponse = client.getAnalyzedInvocation(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAnalyzedInvocationRequest actualRequest = + ((GetAnalyzedInvocationRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAnalyzedInvocationExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + AnalyzedInvocationName name = + AnalyzedInvocationName.of( + "[PROJECT]", + "[LOCATION]", + "[MONITORED_AGENT]", + "[ANALYZED_SESSION]", + "[ANALYZED_INVOCATION]"); + client.getAnalyzedInvocation(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAnalyzedInvocationTest2() throws Exception { + AnalyzedInvocation expectedResponse = + AnalyzedInvocation.newBuilder() + .setName( + AnalyzedInvocationName.of( + "[PROJECT]", + "[LOCATION]", + "[MONITORED_AGENT]", + "[ANALYZED_SESSION]", + "[ANALYZED_INVOCATION]") + .toString()) + .setInvocationId("invocationId149331403") + .setAssessment(Assessment.newBuilder().build()) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + String name = "name3373707"; + + AnalyzedInvocation actualResponse = client.getAnalyzedInvocation(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetAnalyzedInvocationRequest actualRequest = + ((GetAnalyzedInvocationRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getAnalyzedInvocationExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String name = "name3373707"; + client.getAnalyzedInvocation(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void aggregateAnalyzedSessionsTest() throws Exception { + AggregateAnalyzedSessionsResponse.AgentAggregate responsesElement = + AggregateAnalyzedSessionsResponse.AgentAggregate.newBuilder().build(); + AggregateAnalyzedSessionsResponse expectedResponse = + AggregateAnalyzedSessionsResponse.newBuilder() + .setNextPageToken("") + .addAllAgentAggregates(Arrays.asList(responsesElement)) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + MonitoredAgentName parent = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + + AggregateAnalyzedSessionsPagedResponse pagedListResponse = + client.aggregateAnalyzedSessions(parent); + + List resources = + Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAgentAggregatesList().get(0), resources.get(0)); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + AggregateAnalyzedSessionsRequest actualRequest = + ((AggregateAnalyzedSessionsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void aggregateAnalyzedSessionsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + MonitoredAgentName parent = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + client.aggregateAnalyzedSessions(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void aggregateAnalyzedSessionsTest2() throws Exception { + AggregateAnalyzedSessionsResponse.AgentAggregate responsesElement = + AggregateAnalyzedSessionsResponse.AgentAggregate.newBuilder().build(); + AggregateAnalyzedSessionsResponse expectedResponse = + AggregateAnalyzedSessionsResponse.newBuilder() + .setNextPageToken("") + .addAllAgentAggregates(Arrays.asList(responsesElement)) + .build(); + mockAgentAnomalyDetectionService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + AggregateAnalyzedSessionsPagedResponse pagedListResponse = + client.aggregateAnalyzedSessions(parent); + + List resources = + Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAgentAggregatesList().get(0), resources.get(0)); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + AggregateAnalyzedSessionsRequest actualRequest = + ((AggregateAnalyzedSessionsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void aggregateAnalyzedSessionsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String parent = "parent-995424086"; + client.aggregateAnalyzedSessions(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void clearTrainingDataTest() throws Exception { + ClearTrainingDataResponse expectedResponse = ClearTrainingDataResponse.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("clearTrainingDataTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentAnomalyDetectionService.addResponse(resultOperation); + + MonitoredAgentName name = MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + + ClearTrainingDataResponse actualResponse = client.clearTrainingDataAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ClearTrainingDataRequest actualRequest = ((ClearTrainingDataRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void clearTrainingDataExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + MonitoredAgentName name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + client.clearTrainingDataAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void clearTrainingDataTest2() throws Exception { + ClearTrainingDataResponse expectedResponse = ClearTrainingDataResponse.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("clearTrainingDataTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockAgentAnomalyDetectionService.addResponse(resultOperation); + + String name = "name3373707"; + + ClearTrainingDataResponse actualResponse = client.clearTrainingDataAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockAgentAnomalyDetectionService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ClearTrainingDataRequest actualRequest = ((ClearTrainingDataRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void clearTrainingDataExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockAgentAnomalyDetectionService.addException(exception); + + try { + String name = "name3373707"; + client.clearTrainingDataAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void listLocationsTest() throws Exception { + Location responsesElement = Location.newBuilder().build(); + ListLocationsResponse expectedResponse = + ListLocationsResponse.newBuilder() + .setNextPageToken("") + .addAllLocations(Arrays.asList(responsesElement)) + .build(); + mockLocations.addResponse(expectedResponse); + + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + + ListLocationsPagedResponse pagedListResponse = client.listLocations(request); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getLocationsList().get(0), resources.get(0)); + + List actualRequests = mockLocations.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListLocationsRequest actualRequest = ((ListLocationsRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getName(), actualRequest.getName()); + Assert.assertEquals(request.getFilter(), actualRequest.getFilter()); + Assert.assertEquals(request.getPageSize(), actualRequest.getPageSize()); + Assert.assertEquals(request.getPageToken(), actualRequest.getPageToken()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listLocationsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockLocations.addException(exception); + + try { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + client.listLocations(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getLocationTest() throws Exception { + Location expectedResponse = + Location.newBuilder() + .setName("name3373707") + .setLocationId("locationId1541836720") + .setDisplayName("displayName1714148973") + .putAllLabels(new HashMap()) + .setMetadata(Any.newBuilder().build()) + .build(); + mockLocations.addResponse(expectedResponse); + + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + + Location actualResponse = client.getLocation(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockLocations.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetLocationRequest actualRequest = ((GetLocationRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getName(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getLocationExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockLocations.addException(exception); + + try { + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + client.getLocation(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void setIamPolicyTest() throws Exception { + Policy expectedResponse = + Policy.newBuilder() + .setVersion(351608024) + .addAllBindings(new ArrayList()) + .addAllAuditConfigs(new ArrayList()) + .setEtag(ByteString.EMPTY) + .build(); + mockIAMPolicy.addResponse(expectedResponse); + + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .setPolicy(Policy.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + + Policy actualResponse = client.setIamPolicy(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockIAMPolicy.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + SetIamPolicyRequest actualRequest = ((SetIamPolicyRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getResource(), actualRequest.getResource()); + Assert.assertEquals(request.getPolicy(), actualRequest.getPolicy()); + Assert.assertEquals(request.getUpdateMask(), actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void setIamPolicyExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockIAMPolicy.addException(exception); + + try { + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName( + "[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .setPolicy(Policy.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + client.setIamPolicy(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getIamPolicyTest() throws Exception { + Policy expectedResponse = + Policy.newBuilder() + .setVersion(351608024) + .addAllBindings(new ArrayList()) + .addAllAuditConfigs(new ArrayList()) + .setEtag(ByteString.EMPTY) + .build(); + mockIAMPolicy.addResponse(expectedResponse); + + GetIamPolicyRequest request = + GetIamPolicyRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .setOptions(GetPolicyOptions.newBuilder().build()) + .build(); + + Policy actualResponse = client.getIamPolicy(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockIAMPolicy.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetIamPolicyRequest actualRequest = ((GetIamPolicyRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getResource(), actualRequest.getResource()); + Assert.assertEquals(request.getOptions(), actualRequest.getOptions()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getIamPolicyExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockIAMPolicy.addException(exception); + + try { + GetIamPolicyRequest request = + GetIamPolicyRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName( + "[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .setOptions(GetPolicyOptions.newBuilder().build()) + .build(); + client.getIamPolicy(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void testIamPermissionsTest() throws Exception { + TestIamPermissionsResponse expectedResponse = + TestIamPermissionsResponse.newBuilder().addAllPermissions(new ArrayList()).build(); + mockIAMPolicy.addResponse(expectedResponse); + + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName("[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .addAllPermissions(new ArrayList()) + .build(); + + TestIamPermissionsResponse actualResponse = client.testIamPermissions(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockIAMPolicy.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + TestIamPermissionsRequest actualRequest = ((TestIamPermissionsRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getResource(), actualRequest.getResource()); + Assert.assertEquals(request.getPermissionsList(), actualRequest.getPermissionsList()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void testIamPermissionsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockIAMPolicy.addException(exception); + + try { + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName( + "[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .addAllPermissions(new ArrayList()) + .build(); + client.testIamPermissions(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } +} diff --git a/java-aiplatform/google-cloud-aiplatform/src/test/java/com/google/cloud/aiplatform/v1/MockAgentAnomalyDetectionService.java b/java-aiplatform/google-cloud-aiplatform/src/test/java/com/google/cloud/aiplatform/v1/MockAgentAnomalyDetectionService.java new file mode 100644 index 000000000000..3cf82e6578b8 --- /dev/null +++ b/java-aiplatform/google-cloud-aiplatform/src/test/java/com/google/cloud/aiplatform/v1/MockAgentAnomalyDetectionService.java @@ -0,0 +1,59 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1; + +import com.google.api.core.BetaApi; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.protobuf.AbstractMessage; +import io.grpc.ServerServiceDefinition; +import java.util.List; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockAgentAnomalyDetectionService implements MockGrpcService { + private final MockAgentAnomalyDetectionServiceImpl serviceImpl; + + public MockAgentAnomalyDetectionService() { + serviceImpl = new MockAgentAnomalyDetectionServiceImpl(); + } + + @Override + public List getRequests() { + return serviceImpl.getRequests(); + } + + @Override + public void addResponse(AbstractMessage response) { + serviceImpl.addResponse(response); + } + + @Override + public void addException(Exception exception) { + serviceImpl.addException(exception); + } + + @Override + public ServerServiceDefinition getServiceDefinition() { + return serviceImpl.bindService(); + } + + @Override + public void reset() { + serviceImpl.reset(); + } +} diff --git a/java-aiplatform/google-cloud-aiplatform/src/test/java/com/google/cloud/aiplatform/v1/MockAgentAnomalyDetectionServiceImpl.java b/java-aiplatform/google-cloud-aiplatform/src/test/java/com/google/cloud/aiplatform/v1/MockAgentAnomalyDetectionServiceImpl.java new file mode 100644 index 000000000000..7c83abdf99f3 --- /dev/null +++ b/java-aiplatform/google-cloud-aiplatform/src/test/java/com/google/cloud/aiplatform/v1/MockAgentAnomalyDetectionServiceImpl.java @@ -0,0 +1,371 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1; + +import com.google.api.core.BetaApi; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceGrpc.AgentAnomalyDetectionServiceImplBase; +import com.google.longrunning.Operation; +import com.google.protobuf.AbstractMessage; +import io.grpc.stub.StreamObserver; +import java.util.ArrayList; +import java.util.LinkedList; +import java.util.List; +import java.util.Queue; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockAgentAnomalyDetectionServiceImpl extends AgentAnomalyDetectionServiceImplBase { + private List requests; + private Queue responses; + + public MockAgentAnomalyDetectionServiceImpl() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + public List getRequests() { + return requests; + } + + public void addResponse(AbstractMessage response) { + responses.add(response); + } + + public void setResponses(List responses) { + this.responses = new LinkedList(responses); + } + + public void addException(Exception exception) { + responses.add(exception); + } + + public void reset() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + @Override + public void getAgentAnomalyDetectionScope( + GetAgentAnomalyDetectionScopeRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof AgentAnomalyDetectionScope) { + requests.add(request); + responseObserver.onNext(((AgentAnomalyDetectionScope) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetAgentAnomalyDetectionScope, expected" + + " %s or %s", + response == null ? "null" : response.getClass().getName(), + AgentAnomalyDetectionScope.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getMonitoredAgent( + GetMonitoredAgentRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof MonitoredAgent) { + requests.add(request); + responseObserver.onNext(((MonitoredAgent) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetMonitoredAgent, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + MonitoredAgent.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listMonitoredAgents( + ListMonitoredAgentsRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListMonitoredAgentsResponse) { + requests.add(request); + responseObserver.onNext(((ListMonitoredAgentsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListMonitoredAgents, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListMonitoredAgentsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void enableMonitoredAgent( + EnableMonitoredAgentRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method EnableMonitoredAgent, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void disableMonitoredAgent( + DisableMonitoredAgentRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method DisableMonitoredAgent, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteAgentAnomalyDetectionScope( + DeleteAgentAnomalyDetectionScopeRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method DeleteAgentAnomalyDetectionScope," + + " expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void createAgentAnomalyDetectionScope( + CreateAgentAnomalyDetectionScopeRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method CreateAgentAnomalyDetectionScope," + + " expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listAgentAnomalyDetectionScopes( + ListAgentAnomalyDetectionScopesRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListAgentAnomalyDetectionScopesResponse) { + requests.add(request); + responseObserver.onNext(((ListAgentAnomalyDetectionScopesResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListAgentAnomalyDetectionScopes," + + " expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListAgentAnomalyDetectionScopesResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listAnalyzedSessions( + ListAnalyzedSessionsRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListAnalyzedSessionsResponse) { + requests.add(request); + responseObserver.onNext(((ListAnalyzedSessionsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListAnalyzedSessions, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + ListAnalyzedSessionsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getAnalyzedSession( + GetAnalyzedSessionRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof AnalyzedSession) { + requests.add(request); + responseObserver.onNext(((AnalyzedSession) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetAnalyzedSession, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + AnalyzedSession.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listAnalyzedInvocations( + ListAnalyzedInvocationsRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListAnalyzedInvocationsResponse) { + requests.add(request); + responseObserver.onNext(((ListAnalyzedInvocationsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListAnalyzedInvocations, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + ListAnalyzedInvocationsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getAnalyzedInvocation( + GetAnalyzedInvocationRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof AnalyzedInvocation) { + requests.add(request); + responseObserver.onNext(((AnalyzedInvocation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetAnalyzedInvocation, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + AnalyzedInvocation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void aggregateAnalyzedSessions( + AggregateAnalyzedSessionsRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof AggregateAnalyzedSessionsResponse) { + requests.add(request); + responseObserver.onNext(((AggregateAnalyzedSessionsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method AggregateAnalyzedSessions, expected %s" + + " or %s", + response == null ? "null" : response.getClass().getName(), + AggregateAnalyzedSessionsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void clearTrainingData( + ClearTrainingDataRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ClearTrainingData, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } +} diff --git a/java-aiplatform/grpc-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceGrpc.java b/java-aiplatform/grpc-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceGrpc.java new file mode 100644 index 000000000000..3b8ba5469959 --- /dev/null +++ b/java-aiplatform/grpc-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceGrpc.java @@ -0,0 +1,2316 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +package com.google.cloud.aiplatform.v1; + +import static io.grpc.MethodDescriptor.generateFullMethodName; + +/** + * + * + *
+ * A service for managing Agent Anomaly Detection for monitored agents.
+ * 
+ */ +@io.grpc.stub.annotations.GrpcGenerated +public final class AgentAnomalyDetectionServiceGrpc { + + private AgentAnomalyDetectionServiceGrpc() {} + + public static final java.lang.String SERVICE_NAME = + "google.cloud.aiplatform.v1.AgentAnomalyDetectionService"; + + // Static method descriptors that strictly reflect the proto. + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope> + getGetAgentAnomalyDetectionScopeMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetAgentAnomalyDetectionScope", + requestType = com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest.class, + responseType = com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope> + getGetAgentAnomalyDetectionScopeMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope> + getGetAgentAnomalyDetectionScopeMethod; + if ((getGetAgentAnomalyDetectionScopeMethod = + AgentAnomalyDetectionServiceGrpc.getGetAgentAnomalyDetectionScopeMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getGetAgentAnomalyDetectionScopeMethod = + AgentAnomalyDetectionServiceGrpc.getGetAgentAnomalyDetectionScopeMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getGetAgentAnomalyDetectionScopeMethod = + getGetAgentAnomalyDetectionScopeMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetAgentAnomalyDetectionScope")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "GetAgentAnomalyDetectionScope")) + .build(); + } + } + } + return getGetAgentAnomalyDetectionScopeMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest, + com.google.cloud.aiplatform.v1.MonitoredAgent> + getGetMonitoredAgentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetMonitoredAgent", + requestType = com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest.class, + responseType = com.google.cloud.aiplatform.v1.MonitoredAgent.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest, + com.google.cloud.aiplatform.v1.MonitoredAgent> + getGetMonitoredAgentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest, + com.google.cloud.aiplatform.v1.MonitoredAgent> + getGetMonitoredAgentMethod; + if ((getGetMonitoredAgentMethod = AgentAnomalyDetectionServiceGrpc.getGetMonitoredAgentMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getGetMonitoredAgentMethod = + AgentAnomalyDetectionServiceGrpc.getGetMonitoredAgentMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getGetMonitoredAgentMethod = + getGetMonitoredAgentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetMonitoredAgent")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.MonitoredAgent.getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "GetMonitoredAgent")) + .build(); + } + } + } + return getGetMonitoredAgentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest, + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse> + getListMonitoredAgentsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListMonitoredAgents", + requestType = com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest.class, + responseType = com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest, + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse> + getListMonitoredAgentsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest, + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse> + getListMonitoredAgentsMethod; + if ((getListMonitoredAgentsMethod = + AgentAnomalyDetectionServiceGrpc.getListMonitoredAgentsMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getListMonitoredAgentsMethod = + AgentAnomalyDetectionServiceGrpc.getListMonitoredAgentsMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getListMonitoredAgentsMethod = + getListMonitoredAgentsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListMonitoredAgents")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "ListMonitoredAgents")) + .build(); + } + } + } + return getListMonitoredAgentsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest, + com.google.longrunning.Operation> + getEnableMonitoredAgentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "EnableMonitoredAgent", + requestType = com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest, + com.google.longrunning.Operation> + getEnableMonitoredAgentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest, + com.google.longrunning.Operation> + getEnableMonitoredAgentMethod; + if ((getEnableMonitoredAgentMethod = + AgentAnomalyDetectionServiceGrpc.getEnableMonitoredAgentMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getEnableMonitoredAgentMethod = + AgentAnomalyDetectionServiceGrpc.getEnableMonitoredAgentMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getEnableMonitoredAgentMethod = + getEnableMonitoredAgentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "EnableMonitoredAgent")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "EnableMonitoredAgent")) + .build(); + } + } + } + return getEnableMonitoredAgentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest, + com.google.longrunning.Operation> + getDisableMonitoredAgentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DisableMonitoredAgent", + requestType = com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest, + com.google.longrunning.Operation> + getDisableMonitoredAgentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest, + com.google.longrunning.Operation> + getDisableMonitoredAgentMethod; + if ((getDisableMonitoredAgentMethod = + AgentAnomalyDetectionServiceGrpc.getDisableMonitoredAgentMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getDisableMonitoredAgentMethod = + AgentAnomalyDetectionServiceGrpc.getDisableMonitoredAgentMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getDisableMonitoredAgentMethod = + getDisableMonitoredAgentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "DisableMonitoredAgent")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "DisableMonitoredAgent")) + .build(); + } + } + } + return getDisableMonitoredAgentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest, + com.google.longrunning.Operation> + getDeleteAgentAnomalyDetectionScopeMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteAgentAnomalyDetectionScope", + requestType = com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest, + com.google.longrunning.Operation> + getDeleteAgentAnomalyDetectionScopeMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest, + com.google.longrunning.Operation> + getDeleteAgentAnomalyDetectionScopeMethod; + if ((getDeleteAgentAnomalyDetectionScopeMethod = + AgentAnomalyDetectionServiceGrpc.getDeleteAgentAnomalyDetectionScopeMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getDeleteAgentAnomalyDetectionScopeMethod = + AgentAnomalyDetectionServiceGrpc.getDeleteAgentAnomalyDetectionScopeMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getDeleteAgentAnomalyDetectionScopeMethod = + getDeleteAgentAnomalyDetectionScopeMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "DeleteAgentAnomalyDetectionScope")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "DeleteAgentAnomalyDetectionScope")) + .build(); + } + } + } + return getDeleteAgentAnomalyDetectionScopeMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest, + com.google.longrunning.Operation> + getCreateAgentAnomalyDetectionScopeMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateAgentAnomalyDetectionScope", + requestType = com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest, + com.google.longrunning.Operation> + getCreateAgentAnomalyDetectionScopeMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest, + com.google.longrunning.Operation> + getCreateAgentAnomalyDetectionScopeMethod; + if ((getCreateAgentAnomalyDetectionScopeMethod = + AgentAnomalyDetectionServiceGrpc.getCreateAgentAnomalyDetectionScopeMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getCreateAgentAnomalyDetectionScopeMethod = + AgentAnomalyDetectionServiceGrpc.getCreateAgentAnomalyDetectionScopeMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getCreateAgentAnomalyDetectionScopeMethod = + getCreateAgentAnomalyDetectionScopeMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "CreateAgentAnomalyDetectionScope")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "CreateAgentAnomalyDetectionScope")) + .build(); + } + } + } + return getCreateAgentAnomalyDetectionScopeMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest, + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse> + getListAgentAnomalyDetectionScopesMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListAgentAnomalyDetectionScopes", + requestType = com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest.class, + responseType = com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest, + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse> + getListAgentAnomalyDetectionScopesMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest, + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse> + getListAgentAnomalyDetectionScopesMethod; + if ((getListAgentAnomalyDetectionScopesMethod = + AgentAnomalyDetectionServiceGrpc.getListAgentAnomalyDetectionScopesMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getListAgentAnomalyDetectionScopesMethod = + AgentAnomalyDetectionServiceGrpc.getListAgentAnomalyDetectionScopesMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getListAgentAnomalyDetectionScopesMethod = + getListAgentAnomalyDetectionScopesMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListAgentAnomalyDetectionScopes")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "ListAgentAnomalyDetectionScopes")) + .build(); + } + } + } + return getListAgentAnomalyDetectionScopesMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse> + getListAnalyzedSessionsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListAnalyzedSessions", + requestType = com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest.class, + responseType = com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse> + getListAnalyzedSessionsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse> + getListAnalyzedSessionsMethod; + if ((getListAnalyzedSessionsMethod = + AgentAnomalyDetectionServiceGrpc.getListAnalyzedSessionsMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getListAnalyzedSessionsMethod = + AgentAnomalyDetectionServiceGrpc.getListAnalyzedSessionsMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getListAnalyzedSessionsMethod = + getListAnalyzedSessionsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListAnalyzedSessions")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "ListAnalyzedSessions")) + .build(); + } + } + } + return getListAnalyzedSessionsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest, + com.google.cloud.aiplatform.v1.AnalyzedSession> + getGetAnalyzedSessionMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetAnalyzedSession", + requestType = com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest.class, + responseType = com.google.cloud.aiplatform.v1.AnalyzedSession.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest, + com.google.cloud.aiplatform.v1.AnalyzedSession> + getGetAnalyzedSessionMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest, + com.google.cloud.aiplatform.v1.AnalyzedSession> + getGetAnalyzedSessionMethod; + if ((getGetAnalyzedSessionMethod = AgentAnomalyDetectionServiceGrpc.getGetAnalyzedSessionMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getGetAnalyzedSessionMethod = + AgentAnomalyDetectionServiceGrpc.getGetAnalyzedSessionMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getGetAnalyzedSessionMethod = + getGetAnalyzedSessionMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetAnalyzedSession")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.AnalyzedSession.getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "GetAnalyzedSession")) + .build(); + } + } + } + return getGetAnalyzedSessionMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest, + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse> + getListAnalyzedInvocationsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListAnalyzedInvocations", + requestType = com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest.class, + responseType = com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest, + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse> + getListAnalyzedInvocationsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest, + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse> + getListAnalyzedInvocationsMethod; + if ((getListAnalyzedInvocationsMethod = + AgentAnomalyDetectionServiceGrpc.getListAnalyzedInvocationsMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getListAnalyzedInvocationsMethod = + AgentAnomalyDetectionServiceGrpc.getListAnalyzedInvocationsMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getListAnalyzedInvocationsMethod = + getListAnalyzedInvocationsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListAnalyzedInvocations")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "ListAnalyzedInvocations")) + .build(); + } + } + } + return getListAnalyzedInvocationsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest, + com.google.cloud.aiplatform.v1.AnalyzedInvocation> + getGetAnalyzedInvocationMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetAnalyzedInvocation", + requestType = com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest.class, + responseType = com.google.cloud.aiplatform.v1.AnalyzedInvocation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest, + com.google.cloud.aiplatform.v1.AnalyzedInvocation> + getGetAnalyzedInvocationMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest, + com.google.cloud.aiplatform.v1.AnalyzedInvocation> + getGetAnalyzedInvocationMethod; + if ((getGetAnalyzedInvocationMethod = + AgentAnomalyDetectionServiceGrpc.getGetAnalyzedInvocationMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getGetAnalyzedInvocationMethod = + AgentAnomalyDetectionServiceGrpc.getGetAnalyzedInvocationMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getGetAnalyzedInvocationMethod = + getGetAnalyzedInvocationMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetAnalyzedInvocation")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.AnalyzedInvocation + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "GetAnalyzedInvocation")) + .build(); + } + } + } + return getGetAnalyzedInvocationMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse> + getAggregateAnalyzedSessionsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "AggregateAnalyzedSessions", + requestType = com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest.class, + responseType = com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse> + getAggregateAnalyzedSessionsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse> + getAggregateAnalyzedSessionsMethod; + if ((getAggregateAnalyzedSessionsMethod = + AgentAnomalyDetectionServiceGrpc.getAggregateAnalyzedSessionsMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getAggregateAnalyzedSessionsMethod = + AgentAnomalyDetectionServiceGrpc.getAggregateAnalyzedSessionsMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getAggregateAnalyzedSessionsMethod = + getAggregateAnalyzedSessionsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "AggregateAnalyzedSessions")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "AggregateAnalyzedSessions")) + .build(); + } + } + } + return getAggregateAnalyzedSessionsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest, com.google.longrunning.Operation> + getClearTrainingDataMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ClearTrainingData", + requestType = com.google.cloud.aiplatform.v1.ClearTrainingDataRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest, com.google.longrunning.Operation> + getClearTrainingDataMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest, + com.google.longrunning.Operation> + getClearTrainingDataMethod; + if ((getClearTrainingDataMethod = AgentAnomalyDetectionServiceGrpc.getClearTrainingDataMethod) + == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + if ((getClearTrainingDataMethod = + AgentAnomalyDetectionServiceGrpc.getClearTrainingDataMethod) + == null) { + AgentAnomalyDetectionServiceGrpc.getClearTrainingDataMethod = + getClearTrainingDataMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ClearTrainingData")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new AgentAnomalyDetectionServiceMethodDescriptorSupplier( + "ClearTrainingData")) + .build(); + } + } + } + return getClearTrainingDataMethod; + } + + /** Creates a new async stub that supports all call types for the service */ + public static AgentAnomalyDetectionServiceStub newStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public AgentAnomalyDetectionServiceStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentAnomalyDetectionServiceStub(channel, callOptions); + } + }; + return AgentAnomalyDetectionServiceStub.newStub(factory, channel); + } + + /** Creates a new blocking-style stub that supports all types of calls on the service */ + public static AgentAnomalyDetectionServiceBlockingV2Stub newBlockingV2Stub( + io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public AgentAnomalyDetectionServiceBlockingV2Stub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentAnomalyDetectionServiceBlockingV2Stub(channel, callOptions); + } + }; + return AgentAnomalyDetectionServiceBlockingV2Stub.newStub(factory, channel); + } + + /** + * Creates a new blocking-style stub that supports unary and streaming output calls on the service + */ + public static AgentAnomalyDetectionServiceBlockingStub newBlockingStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public AgentAnomalyDetectionServiceBlockingStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentAnomalyDetectionServiceBlockingStub(channel, callOptions); + } + }; + return AgentAnomalyDetectionServiceBlockingStub.newStub(factory, channel); + } + + /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ + public static AgentAnomalyDetectionServiceFutureStub newFutureStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public AgentAnomalyDetectionServiceFutureStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentAnomalyDetectionServiceFutureStub(channel, callOptions); + } + }; + return AgentAnomalyDetectionServiceFutureStub.newStub(factory, channel); + } + + /** + * + * + *
+   * A service for managing Agent Anomaly Detection for monitored agents.
+   * 
+ */ + public interface AsyncService { + + /** + * + * + *
+     * Gets the details of a specific AgentAnomalyDetectionScope.
+     * 
+ */ + default void getAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetAgentAnomalyDetectionScopeMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets the details of a specific MonitoredAgent.
+     * 
+ */ + default void getMonitoredAgent( + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetMonitoredAgentMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists MonitoredAgents in a specific Location.
+     * 
+ */ + default void listMonitoredAgents( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListMonitoredAgentsMethod(), responseObserver); + } + + /** + * + * + *
+     * Enables a specific MonitoredAgent.
+     * 
+ */ + default void enableMonitoredAgent( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getEnableMonitoredAgentMethod(), responseObserver); + } + + /** + * + * + *
+     * Disables a specific MonitoredAgent.
+     * 
+ */ + default void disableMonitoredAgent( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDisableMonitoredAgentMethod(), responseObserver); + } + + /** + * + * + *
+     * Deletes a specific AgentAnomalyDetectionScope.
+     * 
+ */ + default void deleteAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteAgentAnomalyDetectionScopeMethod(), responseObserver); + } + + /** + * + * + *
+     * Creates a new AgentAnomalyDetectionScope.
+     * 
+ */ + default void createAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateAgentAnomalyDetectionScopeMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists AgentAnomalyDetectionScopes in a Location.
+     * 
+ */ + default void listAgentAnomalyDetectionScopes( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse> + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListAgentAnomalyDetectionScopesMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists AnalyzedSessions in a MonitoredAgent.
+     * 
+ */ + default void listAnalyzedSessions( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListAnalyzedSessionsMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets the details of a specific AnalyzedSession.
+     * 
+ */ + default void getAnalyzedSession( + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetAnalyzedSessionMethod(), responseObserver); + } + + /** + * + * + *
+     * Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession.
+     * 
+ */ + default void listAnalyzedInvocations( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListAnalyzedInvocationsMethod(), responseObserver); + } + + /** + * + * + *
+     * Gets the details of a specific AnalyzedInvocation.
+     * 
+ */ + default void getAnalyzedInvocation( + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetAnalyzedInvocationMethod(), responseObserver); + } + + /** + * + * + *
+     * Aggregates AnalyzedSessions across MonitoredAgents.
+     * To aggregate across all MonitoredAgents in a
+     * location, use the following format for the parent field:
+     * `projects/{project}/locations/{location}/monitoredAgents/-`
+     * 
+ */ + default void aggregateAnalyzedSessions( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse> + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getAggregateAnalyzedSessionsMethod(), responseObserver); + } + + /** + * + * + *
+     * Clears (purges) the trained model artifacts derived from a MonitoredAgent's
+     * data. The purged model is rebuilt by the next scheduled training run.
+     * To clear every MonitoredAgent in a location's scope, use the `-` wildcard
+     * agent segment for the name field:
+     * `projects/{project}/locations/{location}/monitoredAgents/-`
+     * This is the on-demand data-deletion path for customers who have deleted the
+     * underlying logs / observability data a model was trained on. It deletes
+     * only the derived model artifacts (it does NOT delete the scope or stop
+     * monitoring). To stop monitoring an agent entirely, disable it via
+     * DisableMonitoredAgent.
+     * 
+ */ + default void clearTrainingData( + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getClearTrainingDataMethod(), responseObserver); + } + } + + /** + * Base class for the server implementation of the service AgentAnomalyDetectionService. + * + *
+   * A service for managing Agent Anomaly Detection for monitored agents.
+   * 
+ */ + public abstract static class AgentAnomalyDetectionServiceImplBase + implements io.grpc.BindableService, AsyncService { + + @java.lang.Override + public final io.grpc.ServerServiceDefinition bindService() { + return AgentAnomalyDetectionServiceGrpc.bindService(this); + } + } + + /** + * A stub to allow clients to do asynchronous rpc calls to service AgentAnomalyDetectionService. + * + *
+   * A service for managing Agent Anomaly Detection for monitored agents.
+   * 
+ */ + public static final class AgentAnomalyDetectionServiceStub + extends io.grpc.stub.AbstractAsyncStub { + private AgentAnomalyDetectionServiceStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected AgentAnomalyDetectionServiceStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentAnomalyDetectionServiceStub(channel, callOptions); + } + + /** + * + * + *
+     * Gets the details of a specific AgentAnomalyDetectionScope.
+     * 
+ */ + public void getAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetAgentAnomalyDetectionScopeMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets the details of a specific MonitoredAgent.
+     * 
+ */ + public void getMonitoredAgent( + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetMonitoredAgentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists MonitoredAgents in a specific Location.
+     * 
+ */ + public void listMonitoredAgents( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListMonitoredAgentsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Enables a specific MonitoredAgent.
+     * 
+ */ + public void enableMonitoredAgent( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getEnableMonitoredAgentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Disables a specific MonitoredAgent.
+     * 
+ */ + public void disableMonitoredAgent( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDisableMonitoredAgentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Deletes a specific AgentAnomalyDetectionScope.
+     * 
+ */ + public void deleteAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteAgentAnomalyDetectionScopeMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Creates a new AgentAnomalyDetectionScope.
+     * 
+ */ + public void createAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateAgentAnomalyDetectionScopeMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists AgentAnomalyDetectionScopes in a Location.
+     * 
+ */ + public void listAgentAnomalyDetectionScopes( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse> + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListAgentAnomalyDetectionScopesMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists AnalyzedSessions in a MonitoredAgent.
+     * 
+ */ + public void listAnalyzedSessions( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListAnalyzedSessionsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets the details of a specific AnalyzedSession.
+     * 
+ */ + public void getAnalyzedSession( + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetAnalyzedSessionMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession.
+     * 
+ */ + public void listAnalyzedInvocations( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListAnalyzedInvocationsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Gets the details of a specific AnalyzedInvocation.
+     * 
+ */ + public void getAnalyzedInvocation( + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetAnalyzedInvocationMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Aggregates AnalyzedSessions across MonitoredAgents.
+     * To aggregate across all MonitoredAgents in a
+     * location, use the following format for the parent field:
+     * `projects/{project}/locations/{location}/monitoredAgents/-`
+     * 
+ */ + public void aggregateAnalyzedSessions( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse> + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getAggregateAnalyzedSessionsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Clears (purges) the trained model artifacts derived from a MonitoredAgent's
+     * data. The purged model is rebuilt by the next scheduled training run.
+     * To clear every MonitoredAgent in a location's scope, use the `-` wildcard
+     * agent segment for the name field:
+     * `projects/{project}/locations/{location}/monitoredAgents/-`
+     * This is the on-demand data-deletion path for customers who have deleted the
+     * underlying logs / observability data a model was trained on. It deletes
+     * only the derived model artifacts (it does NOT delete the scope or stop
+     * monitoring). To stop monitoring an agent entirely, disable it via
+     * DisableMonitoredAgent.
+     * 
+ */ + public void clearTrainingData( + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getClearTrainingDataMethod(), getCallOptions()), + request, + responseObserver); + } + } + + /** + * A stub to allow clients to do synchronous rpc calls to service AgentAnomalyDetectionService. + * + *
+   * A service for managing Agent Anomaly Detection for monitored agents.
+   * 
+ */ + public static final class AgentAnomalyDetectionServiceBlockingV2Stub + extends io.grpc.stub.AbstractBlockingStub { + private AgentAnomalyDetectionServiceBlockingV2Stub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected AgentAnomalyDetectionServiceBlockingV2Stub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentAnomalyDetectionServiceBlockingV2Stub(channel, callOptions); + } + + /** + * + * + *
+     * Gets the details of a specific AgentAnomalyDetectionScope.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope getAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetAgentAnomalyDetectionScopeMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets the details of a specific MonitoredAgent.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.MonitoredAgent getMonitoredAgent( + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetMonitoredAgentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists MonitoredAgents in a specific Location.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse listMonitoredAgents( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListMonitoredAgentsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Enables a specific MonitoredAgent.
+     * 
+ */ + public com.google.longrunning.Operation enableMonitoredAgent( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getEnableMonitoredAgentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Disables a specific MonitoredAgent.
+     * 
+ */ + public com.google.longrunning.Operation disableMonitoredAgent( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getDisableMonitoredAgentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Deletes a specific AgentAnomalyDetectionScope.
+     * 
+ */ + public com.google.longrunning.Operation deleteAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getDeleteAgentAnomalyDetectionScopeMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Creates a new AgentAnomalyDetectionScope.
+     * 
+ */ + public com.google.longrunning.Operation createAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getCreateAgentAnomalyDetectionScopeMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists AgentAnomalyDetectionScopes in a Location.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse + listAgentAnomalyDetectionScopes( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListAgentAnomalyDetectionScopesMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists AnalyzedSessions in a MonitoredAgent.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse listAnalyzedSessions( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListAnalyzedSessionsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets the details of a specific AnalyzedSession.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.AnalyzedSession getAnalyzedSession( + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetAnalyzedSessionMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse listAnalyzedInvocations( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListAnalyzedInvocationsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets the details of a specific AnalyzedInvocation.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.AnalyzedInvocation getAnalyzedInvocation( + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetAnalyzedInvocationMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Aggregates AnalyzedSessions across MonitoredAgents.
+     * To aggregate across all MonitoredAgents in a
+     * location, use the following format for the parent field:
+     * `projects/{project}/locations/{location}/monitoredAgents/-`
+     * 
+ */ + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + aggregateAnalyzedSessions( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getAggregateAnalyzedSessionsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Clears (purges) the trained model artifacts derived from a MonitoredAgent's
+     * data. The purged model is rebuilt by the next scheduled training run.
+     * To clear every MonitoredAgent in a location's scope, use the `-` wildcard
+     * agent segment for the name field:
+     * `projects/{project}/locations/{location}/monitoredAgents/-`
+     * This is the on-demand data-deletion path for customers who have deleted the
+     * underlying logs / observability data a model was trained on. It deletes
+     * only the derived model artifacts (it does NOT delete the scope or stop
+     * monitoring). To stop monitoring an agent entirely, disable it via
+     * DisableMonitoredAgent.
+     * 
+ */ + public com.google.longrunning.Operation clearTrainingData( + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getClearTrainingDataMethod(), getCallOptions(), request); + } + } + + /** + * A stub to allow clients to do limited synchronous rpc calls to service + * AgentAnomalyDetectionService. + * + *
+   * A service for managing Agent Anomaly Detection for monitored agents.
+   * 
+ */ + public static final class AgentAnomalyDetectionServiceBlockingStub + extends io.grpc.stub.AbstractBlockingStub { + private AgentAnomalyDetectionServiceBlockingStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected AgentAnomalyDetectionServiceBlockingStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentAnomalyDetectionServiceBlockingStub(channel, callOptions); + } + + /** + * + * + *
+     * Gets the details of a specific AgentAnomalyDetectionScope.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope getAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetAgentAnomalyDetectionScopeMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets the details of a specific MonitoredAgent.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.MonitoredAgent getMonitoredAgent( + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetMonitoredAgentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists MonitoredAgents in a specific Location.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse listMonitoredAgents( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListMonitoredAgentsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Enables a specific MonitoredAgent.
+     * 
+ */ + public com.google.longrunning.Operation enableMonitoredAgent( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getEnableMonitoredAgentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Disables a specific MonitoredAgent.
+     * 
+ */ + public com.google.longrunning.Operation disableMonitoredAgent( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDisableMonitoredAgentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Deletes a specific AgentAnomalyDetectionScope.
+     * 
+ */ + public com.google.longrunning.Operation deleteAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteAgentAnomalyDetectionScopeMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Creates a new AgentAnomalyDetectionScope.
+     * 
+ */ + public com.google.longrunning.Operation createAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateAgentAnomalyDetectionScopeMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists AgentAnomalyDetectionScopes in a Location.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse + listAgentAnomalyDetectionScopes( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListAgentAnomalyDetectionScopesMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists AnalyzedSessions in a MonitoredAgent.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse listAnalyzedSessions( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListAnalyzedSessionsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets the details of a specific AnalyzedSession.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.AnalyzedSession getAnalyzedSession( + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetAnalyzedSessionMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse listAnalyzedInvocations( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListAnalyzedInvocationsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Gets the details of a specific AnalyzedInvocation.
+     * 
+ */ + public com.google.cloud.aiplatform.v1.AnalyzedInvocation getAnalyzedInvocation( + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetAnalyzedInvocationMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Aggregates AnalyzedSessions across MonitoredAgents.
+     * To aggregate across all MonitoredAgents in a
+     * location, use the following format for the parent field:
+     * `projects/{project}/locations/{location}/monitoredAgents/-`
+     * 
+ */ + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + aggregateAnalyzedSessions( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getAggregateAnalyzedSessionsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Clears (purges) the trained model artifacts derived from a MonitoredAgent's
+     * data. The purged model is rebuilt by the next scheduled training run.
+     * To clear every MonitoredAgent in a location's scope, use the `-` wildcard
+     * agent segment for the name field:
+     * `projects/{project}/locations/{location}/monitoredAgents/-`
+     * This is the on-demand data-deletion path for customers who have deleted the
+     * underlying logs / observability data a model was trained on. It deletes
+     * only the derived model artifacts (it does NOT delete the scope or stop
+     * monitoring). To stop monitoring an agent entirely, disable it via
+     * DisableMonitoredAgent.
+     * 
+ */ + public com.google.longrunning.Operation clearTrainingData( + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getClearTrainingDataMethod(), getCallOptions(), request); + } + } + + /** + * A stub to allow clients to do ListenableFuture-style rpc calls to service + * AgentAnomalyDetectionService. + * + *
+   * A service for managing Agent Anomaly Detection for monitored agents.
+   * 
+ */ + public static final class AgentAnomalyDetectionServiceFutureStub + extends io.grpc.stub.AbstractFutureStub { + private AgentAnomalyDetectionServiceFutureStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected AgentAnomalyDetectionServiceFutureStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new AgentAnomalyDetectionServiceFutureStub(channel, callOptions); + } + + /** + * + * + *
+     * Gets the details of a specific AgentAnomalyDetectionScope.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope> + getAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetAgentAnomalyDetectionScopeMethod(), getCallOptions()), + request); + } + + /** + * + * + *
+     * Gets the details of a specific MonitoredAgent.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.aiplatform.v1.MonitoredAgent> + getMonitoredAgent(com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetMonitoredAgentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Lists MonitoredAgents in a specific Location.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse> + listMonitoredAgents(com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListMonitoredAgentsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Enables a specific MonitoredAgent.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + enableMonitoredAgent(com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getEnableMonitoredAgentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Disables a specific MonitoredAgent.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + disableMonitoredAgent(com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDisableMonitoredAgentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Deletes a specific AgentAnomalyDetectionScope.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + deleteAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteAgentAnomalyDetectionScopeMethod(), getCallOptions()), + request); + } + + /** + * + * + *
+     * Creates a new AgentAnomalyDetectionScope.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + createAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateAgentAnomalyDetectionScopeMethod(), getCallOptions()), + request); + } + + /** + * + * + *
+     * Lists AgentAnomalyDetectionScopes in a Location.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse> + listAgentAnomalyDetectionScopes( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListAgentAnomalyDetectionScopesMethod(), getCallOptions()), + request); + } + + /** + * + * + *
+     * Lists AnalyzedSessions in a MonitoredAgent.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse> + listAnalyzedSessions(com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListAnalyzedSessionsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Gets the details of a specific AnalyzedSession.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.aiplatform.v1.AnalyzedSession> + getAnalyzedSession(com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetAnalyzedSessionMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse> + listAnalyzedInvocations( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListAnalyzedInvocationsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Gets the details of a specific AnalyzedInvocation.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.aiplatform.v1.AnalyzedInvocation> + getAnalyzedInvocation(com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetAnalyzedInvocationMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Aggregates AnalyzedSessions across MonitoredAgents.
+     * To aggregate across all MonitoredAgents in a
+     * location, use the following format for the parent field:
+     * `projects/{project}/locations/{location}/monitoredAgents/-`
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse> + aggregateAnalyzedSessions( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getAggregateAnalyzedSessionsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Clears (purges) the trained model artifacts derived from a MonitoredAgent's
+     * data. The purged model is rebuilt by the next scheduled training run.
+     * To clear every MonitoredAgent in a location's scope, use the `-` wildcard
+     * agent segment for the name field:
+     * `projects/{project}/locations/{location}/monitoredAgents/-`
+     * This is the on-demand data-deletion path for customers who have deleted the
+     * underlying logs / observability data a model was trained on. It deletes
+     * only the derived model artifacts (it does NOT delete the scope or stop
+     * monitoring). To stop monitoring an agent entirely, disable it via
+     * DisableMonitoredAgent.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + clearTrainingData(com.google.cloud.aiplatform.v1.ClearTrainingDataRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getClearTrainingDataMethod(), getCallOptions()), request); + } + } + + private static final int METHODID_GET_AGENT_ANOMALY_DETECTION_SCOPE = 0; + private static final int METHODID_GET_MONITORED_AGENT = 1; + private static final int METHODID_LIST_MONITORED_AGENTS = 2; + private static final int METHODID_ENABLE_MONITORED_AGENT = 3; + private static final int METHODID_DISABLE_MONITORED_AGENT = 4; + private static final int METHODID_DELETE_AGENT_ANOMALY_DETECTION_SCOPE = 5; + private static final int METHODID_CREATE_AGENT_ANOMALY_DETECTION_SCOPE = 6; + private static final int METHODID_LIST_AGENT_ANOMALY_DETECTION_SCOPES = 7; + private static final int METHODID_LIST_ANALYZED_SESSIONS = 8; + private static final int METHODID_GET_ANALYZED_SESSION = 9; + private static final int METHODID_LIST_ANALYZED_INVOCATIONS = 10; + private static final int METHODID_GET_ANALYZED_INVOCATION = 11; + private static final int METHODID_AGGREGATE_ANALYZED_SESSIONS = 12; + private static final int METHODID_CLEAR_TRAINING_DATA = 13; + + private static final class MethodHandlers + implements io.grpc.stub.ServerCalls.UnaryMethod, + io.grpc.stub.ServerCalls.ServerStreamingMethod, + io.grpc.stub.ServerCalls.ClientStreamingMethod, + io.grpc.stub.ServerCalls.BidiStreamingMethod { + private final AsyncService serviceImpl; + private final int methodId; + + MethodHandlers(AsyncService serviceImpl, int methodId) { + this.serviceImpl = serviceImpl; + this.methodId = methodId; + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + case METHODID_GET_AGENT_ANOMALY_DETECTION_SCOPE: + serviceImpl.getAgentAnomalyDetectionScope( + (com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope>) + responseObserver); + break; + case METHODID_GET_MONITORED_AGENT: + serviceImpl.getMonitoredAgent( + (com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_MONITORED_AGENTS: + serviceImpl.listMonitoredAgents( + (com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse>) + responseObserver); + break; + case METHODID_ENABLE_MONITORED_AGENT: + serviceImpl.enableMonitoredAgent( + (com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DISABLE_MONITORED_AGENT: + serviceImpl.disableMonitoredAgent( + (com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DELETE_AGENT_ANOMALY_DETECTION_SCOPE: + serviceImpl.deleteAgentAnomalyDetectionScope( + (com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_CREATE_AGENT_ANOMALY_DETECTION_SCOPE: + serviceImpl.createAgentAnomalyDetectionScope( + (com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_LIST_AGENT_ANOMALY_DETECTION_SCOPES: + serviceImpl.listAgentAnomalyDetectionScopes( + (com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse>) + responseObserver); + break; + case METHODID_LIST_ANALYZED_SESSIONS: + serviceImpl.listAnalyzedSessions( + (com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse>) + responseObserver); + break; + case METHODID_GET_ANALYZED_SESSION: + serviceImpl.getAnalyzedSession( + (com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_ANALYZED_INVOCATIONS: + serviceImpl.listAnalyzedInvocations( + (com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse>) + responseObserver); + break; + case METHODID_GET_ANALYZED_INVOCATION: + serviceImpl.getAnalyzedInvocation( + (com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_AGGREGATE_ANALYZED_SESSIONS: + serviceImpl.aggregateAnalyzedSessions( + (com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse>) + responseObserver); + break; + case METHODID_CLEAR_TRAINING_DATA: + serviceImpl.clearTrainingData( + (com.google.cloud.aiplatform.v1.ClearTrainingDataRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + default: + throw new AssertionError(); + } + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public io.grpc.stub.StreamObserver invoke( + io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + default: + throw new AssertionError(); + } + } + } + + public static final io.grpc.ServerServiceDefinition bindService(AsyncService service) { + return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) + .addMethod( + getGetAgentAnomalyDetectionScopeMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope>( + service, METHODID_GET_AGENT_ANOMALY_DETECTION_SCOPE))) + .addMethod( + getGetMonitoredAgentMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest, + com.google.cloud.aiplatform.v1.MonitoredAgent>( + service, METHODID_GET_MONITORED_AGENT))) + .addMethod( + getListMonitoredAgentsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest, + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse>( + service, METHODID_LIST_MONITORED_AGENTS))) + .addMethod( + getEnableMonitoredAgentMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest, + com.google.longrunning.Operation>(service, METHODID_ENABLE_MONITORED_AGENT))) + .addMethod( + getDisableMonitoredAgentMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest, + com.google.longrunning.Operation>(service, METHODID_DISABLE_MONITORED_AGENT))) + .addMethod( + getDeleteAgentAnomalyDetectionScopeMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest, + com.google.longrunning.Operation>( + service, METHODID_DELETE_AGENT_ANOMALY_DETECTION_SCOPE))) + .addMethod( + getCreateAgentAnomalyDetectionScopeMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest, + com.google.longrunning.Operation>( + service, METHODID_CREATE_AGENT_ANOMALY_DETECTION_SCOPE))) + .addMethod( + getListAgentAnomalyDetectionScopesMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest, + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse>( + service, METHODID_LIST_AGENT_ANOMALY_DETECTION_SCOPES))) + .addMethod( + getListAnalyzedSessionsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse>( + service, METHODID_LIST_ANALYZED_SESSIONS))) + .addMethod( + getGetAnalyzedSessionMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest, + com.google.cloud.aiplatform.v1.AnalyzedSession>( + service, METHODID_GET_ANALYZED_SESSION))) + .addMethod( + getListAnalyzedInvocationsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest, + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse>( + service, METHODID_LIST_ANALYZED_INVOCATIONS))) + .addMethod( + getGetAnalyzedInvocationMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest, + com.google.cloud.aiplatform.v1.AnalyzedInvocation>( + service, METHODID_GET_ANALYZED_INVOCATION))) + .addMethod( + getAggregateAnalyzedSessionsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse>( + service, METHODID_AGGREGATE_ANALYZED_SESSIONS))) + .addMethod( + getClearTrainingDataMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest, + com.google.longrunning.Operation>(service, METHODID_CLEAR_TRAINING_DATA))) + .build(); + } + + private abstract static class AgentAnomalyDetectionServiceBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoFileDescriptorSupplier, + io.grpc.protobuf.ProtoServiceDescriptorSupplier { + AgentAnomalyDetectionServiceBaseDescriptorSupplier() {} + + @java.lang.Override + public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto.getDescriptor(); + } + + @java.lang.Override + public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { + return getFileDescriptor().findServiceByName("AgentAnomalyDetectionService"); + } + } + + private static final class AgentAnomalyDetectionServiceFileDescriptorSupplier + extends AgentAnomalyDetectionServiceBaseDescriptorSupplier { + AgentAnomalyDetectionServiceFileDescriptorSupplier() {} + } + + private static final class AgentAnomalyDetectionServiceMethodDescriptorSupplier + extends AgentAnomalyDetectionServiceBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { + private final java.lang.String methodName; + + AgentAnomalyDetectionServiceMethodDescriptorSupplier(java.lang.String methodName) { + this.methodName = methodName; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { + return getServiceDescriptor().findMethodByName(methodName); + } + } + + private static volatile io.grpc.ServiceDescriptor serviceDescriptor; + + public static io.grpc.ServiceDescriptor getServiceDescriptor() { + io.grpc.ServiceDescriptor result = serviceDescriptor; + if (result == null) { + synchronized (AgentAnomalyDetectionServiceGrpc.class) { + result = serviceDescriptor; + if (result == null) { + serviceDescriptor = + result = + io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) + .setSchemaDescriptor(new AgentAnomalyDetectionServiceFileDescriptorSupplier()) + .addMethod(getGetAgentAnomalyDetectionScopeMethod()) + .addMethod(getGetMonitoredAgentMethod()) + .addMethod(getListMonitoredAgentsMethod()) + .addMethod(getEnableMonitoredAgentMethod()) + .addMethod(getDisableMonitoredAgentMethod()) + .addMethod(getDeleteAgentAnomalyDetectionScopeMethod()) + .addMethod(getCreateAgentAnomalyDetectionScopeMethod()) + .addMethod(getListAgentAnomalyDetectionScopesMethod()) + .addMethod(getListAnalyzedSessionsMethod()) + .addMethod(getGetAnalyzedSessionMethod()) + .addMethod(getListAnalyzedInvocationsMethod()) + .addMethod(getGetAnalyzedInvocationMethod()) + .addMethod(getAggregateAnalyzedSessionsMethod()) + .addMethod(getClearTrainingDataMethod()) + .build(); + } + } + } + return result; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionScope.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionScope.java new file mode 100644 index 000000000000..742f9bc5ffd8 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionScope.java @@ -0,0 +1,2395 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Represents an Agent Anomaly Detection Scope.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AgentAnomalyDetectionScope} + */ +@com.google.protobuf.Generated +public final class AgentAnomalyDetectionScope extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.AgentAnomalyDetectionScope) + AgentAnomalyDetectionScopeOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AgentAnomalyDetectionScope"); + } + + // Use AgentAnomalyDetectionScope.newBuilder() to construct. + private AgentAnomalyDetectionScope(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AgentAnomalyDetectionScope() { + name_ = ""; + displayName_ = ""; + logBuckets_ = com.google.protobuf.LazyStringArrayList.emptyList(); + observabilityBuckets_ = com.google.protobuf.LazyStringArrayList.emptyList(); + state_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AgentAnomalyDetectionScope_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AgentAnomalyDetectionScope_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.class, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder.class); + } + + /** + * + * + *
+   * The lifecycle state of an AgentAnomalyDetectionScope.
+   * 
+ * + * Protobuf enum {@code google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * The default value. This value is unused.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
+     * The scope is being created and is not yet usable.
+     * 
+ * + * CREATING = 1; + */ + CREATING(1), + /** + * + * + *
+     * The scope is active and usable.
+     * 
+ * + * ACTIVE = 2; + */ + ACTIVE(2), + /** + * + * + *
+     * The scope is being deleted.
+     * 
+ * + * DELETING = 3; + */ + DELETING(3), + /** + * + * + *
+     * Creation or deletion failed. The scope is not usable and must be deleted
+     * before a new scope can be created in the same region.
+     * 
+ * + * FAILED = 4; + */ + FAILED(4), + /** + * + * + *
+     * The scope is being updated.
+     * 
+ * + * UPDATING = 5; + */ + UPDATING(5), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "State"); + } + + /** + * + * + *
+     * The default value. This value is unused.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The scope is being created and is not yet usable.
+     * 
+ * + * CREATING = 1; + */ + public static final int CREATING_VALUE = 1; + + /** + * + * + *
+     * The scope is active and usable.
+     * 
+ * + * ACTIVE = 2; + */ + public static final int ACTIVE_VALUE = 2; + + /** + * + * + *
+     * The scope is being deleted.
+     * 
+ * + * DELETING = 3; + */ + public static final int DELETING_VALUE = 3; + + /** + * + * + *
+     * Creation or deletion failed. The scope is not usable and must be deleted
+     * before a new scope can be created in the same region.
+     * 
+ * + * FAILED = 4; + */ + public static final int FAILED_VALUE = 4; + + /** + * + * + *
+     * The scope is being updated.
+     * 
+ * + * UPDATING = 5; + */ + public static final int UPDATING_VALUE = 5; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return CREATING; + case 2: + return ACTIVE; + case 3: + return DELETING; + case 4: + return FAILED; + case 5: + return UPDATING; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public State findValueByNumber(int number) { + return State.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final State[] VALUES = values(); + + public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private State(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State) + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Identifier. The resource name of the AgentAnomalyDetectionScope.
+   * Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Identifier. The resource name of the AgentAnomalyDetectionScope.
+   * Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object displayName_ = ""; + + /** + * + * + *
+   * Optional. User-provided display name of the AgentAnomalyDetectionScope.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. User-provided display name of the AgentAnomalyDetectionScope.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int LOG_BUCKETS_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList logBuckets_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * Required. Customer-owned Cloud Logging bucket resource names attached to
+   * this scope. Specify exactly one bucket, in the same project as this scope.
+   * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+   * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return A list containing the logBuckets. + */ + public com.google.protobuf.ProtocolStringList getLogBucketsList() { + return logBuckets_; + } + + /** + * + * + *
+   * Required. Customer-owned Cloud Logging bucket resource names attached to
+   * this scope. Specify exactly one bucket, in the same project as this scope.
+   * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+   * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The count of logBuckets. + */ + public int getLogBucketsCount() { + return logBuckets_.size(); + } + + /** + * + * + *
+   * Required. Customer-owned Cloud Logging bucket resource names attached to
+   * this scope. Specify exactly one bucket, in the same project as this scope.
+   * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+   * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the element to return. + * @return The logBuckets at the given index. + */ + public java.lang.String getLogBuckets(int index) { + return logBuckets_.get(index); + } + + /** + * + * + *
+   * Required. Customer-owned Cloud Logging bucket resource names attached to
+   * this scope. Specify exactly one bucket, in the same project as this scope.
+   * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+   * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the value to return. + * @return The bytes of the logBuckets at the given index. + */ + public com.google.protobuf.ByteString getLogBucketsBytes(int index) { + return logBuckets_.getByteString(index); + } + + public static final int OBSERVABILITY_BUCKETS_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList observabilityBuckets_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+   * Required. Customer-owned Cloud Observability datasets attached to this
+   * scope. Each value is the resource name of a dataset in an Observability
+   * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+   * exactly one dataset, in the same project as this scope.
+   * Format:
+   * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+   * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return A list containing the observabilityBuckets. + */ + public com.google.protobuf.ProtocolStringList getObservabilityBucketsList() { + return observabilityBuckets_; + } + + /** + * + * + *
+   * Required. Customer-owned Cloud Observability datasets attached to this
+   * scope. Each value is the resource name of a dataset in an Observability
+   * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+   * exactly one dataset, in the same project as this scope.
+   * Format:
+   * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+   * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The count of observabilityBuckets. + */ + public int getObservabilityBucketsCount() { + return observabilityBuckets_.size(); + } + + /** + * + * + *
+   * Required. Customer-owned Cloud Observability datasets attached to this
+   * scope. Each value is the resource name of a dataset in an Observability
+   * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+   * exactly one dataset, in the same project as this scope.
+   * Format:
+   * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+   * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param index The index of the element to return. + * @return The observabilityBuckets at the given index. + */ + public java.lang.String getObservabilityBuckets(int index) { + return observabilityBuckets_.get(index); + } + + /** + * + * + *
+   * Required. Customer-owned Cloud Observability datasets attached to this
+   * scope. Each value is the resource name of a dataset in an Observability
+   * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+   * exactly one dataset, in the same project as this scope.
+   * Format:
+   * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+   * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param index The index of the value to return. + * @return The bytes of the observabilityBuckets at the given index. + */ + public com.google.protobuf.ByteString getObservabilityBucketsBytes(int index) { + return observabilityBuckets_.getByteString(index); + } + + public static final int AUTO_ENROLL_FIELD_NUMBER = 7; + private boolean autoEnroll_ = false; + + /** + * + * + *
+   * Optional. When `true`, newly discovered agents that share log and
+   * observability buckets with this scope are automatically enrolled as
+   * `ACTIVE` MonitoredAgents, up to the project's monitored agent quota. When
+   * `false`, newly discovered agents are added as `DISABLED` MonitoredAgents,
+   * and you must enable them explicitly through MonitoredAgent operations.
+   * 
+ * + * bool auto_enroll = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The autoEnroll. + */ + @java.lang.Override + public boolean getAutoEnroll() { + return autoEnroll_; + } + + public static final int STATE_FIELD_NUMBER = 8; + private int state_ = 0; + + /** + * + * + *
+   * Output only. The lifecycle state of the scope.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
+   * Output only. The lifecycle state of the scope.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State getState() { + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State result = + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State.forNumber(state_); + return result == null + ? com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State.UNRECOGNIZED + : result; + } + + public static final int ENCRYPTION_SPEC_FIELD_NUMBER = 9; + private com.google.cloud.aiplatform.v1.EncryptionSpec encryptionSpec_; + + /** + * + * + *
+   * Optional. Immutable. Specifies the customer-managed encryption key spec for
+   * a Scope. If set, this Scope and all sub-resources will be secured by this
+   * key.
+   *
+   * The key is immutable after the Scope is created and must be a multi-region
+   * (`us` or `eu`) key in the same region as the Scope.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return Whether the encryptionSpec field is set. + */ + @java.lang.Override + public boolean hasEncryptionSpec() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Optional. Immutable. Specifies the customer-managed encryption key spec for
+   * a Scope. If set, this Scope and all sub-resources will be secured by this
+   * key.
+   *
+   * The key is immutable after the Scope is created and must be a multi-region
+   * (`us` or `eu`) key in the same region as the Scope.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The encryptionSpec. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.EncryptionSpec getEncryptionSpec() { + return encryptionSpec_ == null + ? com.google.cloud.aiplatform.v1.EncryptionSpec.getDefaultInstance() + : encryptionSpec_; + } + + /** + * + * + *
+   * Optional. Immutable. Specifies the customer-managed encryption key spec for
+   * a Scope. If set, this Scope and all sub-resources will be secured by this
+   * key.
+   *
+   * The key is immutable after the Scope is created and must be a multi-region
+   * (`us` or `eu`) key in the same region as the Scope.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.EncryptionSpecOrBuilder getEncryptionSpecOrBuilder() { + return encryptionSpec_ == null + ? com.google.cloud.aiplatform.v1.EncryptionSpec.getDefaultInstance() + : encryptionSpec_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, displayName_); + } + for (int i = 0; i < logBuckets_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, logBuckets_.getRaw(i)); + } + for (int i = 0; i < observabilityBuckets_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, observabilityBuckets_.getRaw(i)); + } + if (autoEnroll_ != false) { + output.writeBool(7, autoEnroll_); + } + if (state_ + != com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State.STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(8, state_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(9, getEncryptionSpec()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, displayName_); + } + { + int dataSize = 0; + for (int i = 0; i < logBuckets_.size(); i++) { + dataSize += computeStringSizeNoTag(logBuckets_.getRaw(i)); + } + size += dataSize; + size += 1 * getLogBucketsList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < observabilityBuckets_.size(); i++) { + dataSize += computeStringSizeNoTag(observabilityBuckets_.getRaw(i)); + } + size += dataSize; + size += 1 * getObservabilityBucketsList().size(); + } + if (autoEnroll_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(7, autoEnroll_); + } + if (state_ + != com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State.STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(8, state_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, getEncryptionSpec()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope other = + (com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope) obj; + + if (!getName().equals(other.getName())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (!getLogBucketsList().equals(other.getLogBucketsList())) return false; + if (!getObservabilityBucketsList().equals(other.getObservabilityBucketsList())) return false; + if (getAutoEnroll() != other.getAutoEnroll()) return false; + if (state_ != other.state_) return false; + if (hasEncryptionSpec() != other.hasEncryptionSpec()) return false; + if (hasEncryptionSpec()) { + if (!getEncryptionSpec().equals(other.getEncryptionSpec())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + if (getLogBucketsCount() > 0) { + hash = (37 * hash) + LOG_BUCKETS_FIELD_NUMBER; + hash = (53 * hash) + getLogBucketsList().hashCode(); + } + if (getObservabilityBucketsCount() > 0) { + hash = (37 * hash) + OBSERVABILITY_BUCKETS_FIELD_NUMBER; + hash = (53 * hash) + getObservabilityBucketsList().hashCode(); + } + hash = (37 * hash) + AUTO_ENROLL_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAutoEnroll()); + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + if (hasEncryptionSpec()) { + hash = (37 * hash) + ENCRYPTION_SPEC_FIELD_NUMBER; + hash = (53 * hash) + getEncryptionSpec().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Represents an Agent Anomaly Detection Scope.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AgentAnomalyDetectionScope} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.AgentAnomalyDetectionScope) + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AgentAnomalyDetectionScope_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AgentAnomalyDetectionScope_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.class, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetEncryptionSpecFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + displayName_ = ""; + logBuckets_ = com.google.protobuf.LazyStringArrayList.emptyList(); + observabilityBuckets_ = com.google.protobuf.LazyStringArrayList.emptyList(); + autoEnroll_ = false; + state_ = 0; + encryptionSpec_ = null; + if (encryptionSpecBuilder_ != null) { + encryptionSpecBuilder_.dispose(); + encryptionSpecBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AgentAnomalyDetectionScope_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope build() { + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope buildPartial() { + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope result = + new com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.displayName_ = displayName_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + logBuckets_.makeImmutable(); + result.logBuckets_ = logBuckets_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + observabilityBuckets_.makeImmutable(); + result.observabilityBuckets_ = observabilityBuckets_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.autoEnroll_ = autoEnroll_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.state_ = state_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000040) != 0)) { + result.encryptionSpec_ = + encryptionSpecBuilder_ == null ? encryptionSpec_ : encryptionSpecBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope) { + return mergeFrom((com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope other) { + if (other == com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.logBuckets_.isEmpty()) { + if (logBuckets_.isEmpty()) { + logBuckets_ = other.logBuckets_; + bitField0_ |= 0x00000004; + } else { + ensureLogBucketsIsMutable(); + logBuckets_.addAll(other.logBuckets_); + } + onChanged(); + } + if (!other.observabilityBuckets_.isEmpty()) { + if (observabilityBuckets_.isEmpty()) { + observabilityBuckets_ = other.observabilityBuckets_; + bitField0_ |= 0x00000008; + } else { + ensureObservabilityBucketsIsMutable(); + observabilityBuckets_.addAll(other.observabilityBuckets_); + } + onChanged(); + } + if (other.getAutoEnroll() != false) { + setAutoEnroll(other.getAutoEnroll()); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (other.hasEncryptionSpec()) { + mergeEncryptionSpec(other.getEncryptionSpec()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureLogBucketsIsMutable(); + logBuckets_.add(s); + break; + } // case 42 + case 50: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureObservabilityBucketsIsMutable(); + observabilityBuckets_.add(s); + break; + } // case 50 + case 56: + { + autoEnroll_ = input.readBool(); + bitField0_ |= 0x00000010; + break; + } // case 56 + case 64: + { + state_ = input.readEnum(); + bitField0_ |= 0x00000020; + break; + } // case 64 + case 74: + { + input.readMessage( + internalGetEncryptionSpecFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000040; + break; + } // case 74 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Identifier. The resource name of the AgentAnomalyDetectionScope.
+     * Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Identifier. The resource name of the AgentAnomalyDetectionScope.
+     * Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Identifier. The resource name of the AgentAnomalyDetectionScope.
+     * Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. The resource name of the AgentAnomalyDetectionScope.
+     * Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. The resource name of the AgentAnomalyDetectionScope.
+     * Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + + /** + * + * + *
+     * Optional. User-provided display name of the AgentAnomalyDetectionScope.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. User-provided display name of the AgentAnomalyDetectionScope.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. User-provided display name of the AgentAnomalyDetectionScope.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. User-provided display name of the AgentAnomalyDetectionScope.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + displayName_ = getDefaultInstance().getDisplayName(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. User-provided display name of the AgentAnomalyDetectionScope.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList logBuckets_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureLogBucketsIsMutable() { + if (!logBuckets_.isModifiable()) { + logBuckets_ = new com.google.protobuf.LazyStringArrayList(logBuckets_); + } + bitField0_ |= 0x00000004; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Logging bucket resource names attached to
+     * this scope. Specify exactly one bucket, in the same project as this scope.
+     * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+     * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return A list containing the logBuckets. + */ + public com.google.protobuf.ProtocolStringList getLogBucketsList() { + logBuckets_.makeImmutable(); + return logBuckets_; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Logging bucket resource names attached to
+     * this scope. Specify exactly one bucket, in the same project as this scope.
+     * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+     * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The count of logBuckets. + */ + public int getLogBucketsCount() { + return logBuckets_.size(); + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Logging bucket resource names attached to
+     * this scope. Specify exactly one bucket, in the same project as this scope.
+     * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+     * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the element to return. + * @return The logBuckets at the given index. + */ + public java.lang.String getLogBuckets(int index) { + return logBuckets_.get(index); + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Logging bucket resource names attached to
+     * this scope. Specify exactly one bucket, in the same project as this scope.
+     * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+     * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the value to return. + * @return The bytes of the logBuckets at the given index. + */ + public com.google.protobuf.ByteString getLogBucketsBytes(int index) { + return logBuckets_.getByteString(index); + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Logging bucket resource names attached to
+     * this scope. Specify exactly one bucket, in the same project as this scope.
+     * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+     * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index to set the value at. + * @param value The logBuckets to set. + * @return This builder for chaining. + */ + public Builder setLogBuckets(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureLogBucketsIsMutable(); + logBuckets_.set(index, value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Logging bucket resource names attached to
+     * this scope. Specify exactly one bucket, in the same project as this scope.
+     * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+     * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The logBuckets to add. + * @return This builder for chaining. + */ + public Builder addLogBuckets(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureLogBucketsIsMutable(); + logBuckets_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Logging bucket resource names attached to
+     * this scope. Specify exactly one bucket, in the same project as this scope.
+     * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+     * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param values The logBuckets to add. + * @return This builder for chaining. + */ + public Builder addAllLogBuckets(java.lang.Iterable values) { + ensureLogBucketsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, logBuckets_); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Logging bucket resource names attached to
+     * this scope. Specify exactly one bucket, in the same project as this scope.
+     * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+     * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearLogBuckets() { + logBuckets_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Logging bucket resource names attached to
+     * this scope. Specify exactly one bucket, in the same project as this scope.
+     * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+     * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes of the logBuckets to add. + * @return This builder for chaining. + */ + public Builder addLogBucketsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureLogBucketsIsMutable(); + logBuckets_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList observabilityBuckets_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureObservabilityBucketsIsMutable() { + if (!observabilityBuckets_.isModifiable()) { + observabilityBuckets_ = new com.google.protobuf.LazyStringArrayList(observabilityBuckets_); + } + bitField0_ |= 0x00000008; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Observability datasets attached to this
+     * scope. Each value is the resource name of a dataset in an Observability
+     * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+     * exactly one dataset, in the same project as this scope.
+     * Format:
+     * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+     * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return A list containing the observabilityBuckets. + */ + public com.google.protobuf.ProtocolStringList getObservabilityBucketsList() { + observabilityBuckets_.makeImmutable(); + return observabilityBuckets_; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Observability datasets attached to this
+     * scope. Each value is the resource name of a dataset in an Observability
+     * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+     * exactly one dataset, in the same project as this scope.
+     * Format:
+     * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+     * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The count of observabilityBuckets. + */ + public int getObservabilityBucketsCount() { + return observabilityBuckets_.size(); + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Observability datasets attached to this
+     * scope. Each value is the resource name of a dataset in an Observability
+     * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+     * exactly one dataset, in the same project as this scope.
+     * Format:
+     * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+     * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param index The index of the element to return. + * @return The observabilityBuckets at the given index. + */ + public java.lang.String getObservabilityBuckets(int index) { + return observabilityBuckets_.get(index); + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Observability datasets attached to this
+     * scope. Each value is the resource name of a dataset in an Observability
+     * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+     * exactly one dataset, in the same project as this scope.
+     * Format:
+     * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+     * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param index The index of the value to return. + * @return The bytes of the observabilityBuckets at the given index. + */ + public com.google.protobuf.ByteString getObservabilityBucketsBytes(int index) { + return observabilityBuckets_.getByteString(index); + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Observability datasets attached to this
+     * scope. Each value is the resource name of a dataset in an Observability
+     * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+     * exactly one dataset, in the same project as this scope.
+     * Format:
+     * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+     * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param index The index to set the value at. + * @param value The observabilityBuckets to set. + * @return This builder for chaining. + */ + public Builder setObservabilityBuckets(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureObservabilityBucketsIsMutable(); + observabilityBuckets_.set(index, value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Observability datasets attached to this
+     * scope. Each value is the resource name of a dataset in an Observability
+     * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+     * exactly one dataset, in the same project as this scope.
+     * Format:
+     * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+     * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The observabilityBuckets to add. + * @return This builder for chaining. + */ + public Builder addObservabilityBuckets(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureObservabilityBucketsIsMutable(); + observabilityBuckets_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Observability datasets attached to this
+     * scope. Each value is the resource name of a dataset in an Observability
+     * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+     * exactly one dataset, in the same project as this scope.
+     * Format:
+     * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+     * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param values The observabilityBuckets to add. + * @return This builder for chaining. + */ + public Builder addAllObservabilityBuckets(java.lang.Iterable values) { + ensureObservabilityBucketsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, observabilityBuckets_); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Observability datasets attached to this
+     * scope. Each value is the resource name of a dataset in an Observability
+     * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+     * exactly one dataset, in the same project as this scope.
+     * Format:
+     * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+     * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearObservabilityBuckets() { + observabilityBuckets_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + ; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. Customer-owned Cloud Observability datasets attached to this
+     * scope. Each value is the resource name of a dataset in an Observability
+     * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+     * exactly one dataset, in the same project as this scope.
+     * Format:
+     * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+     * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The bytes of the observabilityBuckets to add. + * @return This builder for chaining. + */ + public Builder addObservabilityBucketsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureObservabilityBucketsIsMutable(); + observabilityBuckets_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private boolean autoEnroll_; + + /** + * + * + *
+     * Optional. When `true`, newly discovered agents that share log and
+     * observability buckets with this scope are automatically enrolled as
+     * `ACTIVE` MonitoredAgents, up to the project's monitored agent quota. When
+     * `false`, newly discovered agents are added as `DISABLED` MonitoredAgents,
+     * and you must enable them explicitly through MonitoredAgent operations.
+     * 
+ * + * bool auto_enroll = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The autoEnroll. + */ + @java.lang.Override + public boolean getAutoEnroll() { + return autoEnroll_; + } + + /** + * + * + *
+     * Optional. When `true`, newly discovered agents that share log and
+     * observability buckets with this scope are automatically enrolled as
+     * `ACTIVE` MonitoredAgents, up to the project's monitored agent quota. When
+     * `false`, newly discovered agents are added as `DISABLED` MonitoredAgents,
+     * and you must enable them explicitly through MonitoredAgent operations.
+     * 
+ * + * bool auto_enroll = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The autoEnroll to set. + * @return This builder for chaining. + */ + public Builder setAutoEnroll(boolean value) { + + autoEnroll_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. When `true`, newly discovered agents that share log and
+     * observability buckets with this scope are automatically enrolled as
+     * `ACTIVE` MonitoredAgents, up to the project's monitored agent quota. When
+     * `false`, newly discovered agents are added as `DISABLED` MonitoredAgents,
+     * and you must enable them explicitly through MonitoredAgent operations.
+     * 
+ * + * bool auto_enroll = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearAutoEnroll() { + bitField0_ = (bitField0_ & ~0x00000010); + autoEnroll_ = false; + onChanged(); + return this; + } + + private int state_ = 0; + + /** + * + * + *
+     * Output only. The lifecycle state of the scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
+     * Output only. The lifecycle state of the scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The lifecycle state of the scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State getState() { + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State result = + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State.forNumber(state_); + return result == null + ? com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Output only. The lifecycle state of the scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000020; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The lifecycle state of the scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000020); + state_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.aiplatform.v1.EncryptionSpec encryptionSpec_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.EncryptionSpec, + com.google.cloud.aiplatform.v1.EncryptionSpec.Builder, + com.google.cloud.aiplatform.v1.EncryptionSpecOrBuilder> + encryptionSpecBuilder_; + + /** + * + * + *
+     * Optional. Immutable. Specifies the customer-managed encryption key spec for
+     * a Scope. If set, this Scope and all sub-resources will be secured by this
+     * key.
+     *
+     * The key is immutable after the Scope is created and must be a multi-region
+     * (`us` or `eu`) key in the same region as the Scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return Whether the encryptionSpec field is set. + */ + public boolean hasEncryptionSpec() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
+     * Optional. Immutable. Specifies the customer-managed encryption key spec for
+     * a Scope. If set, this Scope and all sub-resources will be secured by this
+     * key.
+     *
+     * The key is immutable after the Scope is created and must be a multi-region
+     * (`us` or `eu`) key in the same region as the Scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The encryptionSpec. + */ + public com.google.cloud.aiplatform.v1.EncryptionSpec getEncryptionSpec() { + if (encryptionSpecBuilder_ == null) { + return encryptionSpec_ == null + ? com.google.cloud.aiplatform.v1.EncryptionSpec.getDefaultInstance() + : encryptionSpec_; + } else { + return encryptionSpecBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Optional. Immutable. Specifies the customer-managed encryption key spec for
+     * a Scope. If set, this Scope and all sub-resources will be secured by this
+     * key.
+     *
+     * The key is immutable after the Scope is created and must be a multi-region
+     * (`us` or `eu`) key in the same region as the Scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + */ + public Builder setEncryptionSpec(com.google.cloud.aiplatform.v1.EncryptionSpec value) { + if (encryptionSpecBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + encryptionSpec_ = value; + } else { + encryptionSpecBuilder_.setMessage(value); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Specifies the customer-managed encryption key spec for
+     * a Scope. If set, this Scope and all sub-resources will be secured by this
+     * key.
+     *
+     * The key is immutable after the Scope is created and must be a multi-region
+     * (`us` or `eu`) key in the same region as the Scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + */ + public Builder setEncryptionSpec( + com.google.cloud.aiplatform.v1.EncryptionSpec.Builder builderForValue) { + if (encryptionSpecBuilder_ == null) { + encryptionSpec_ = builderForValue.build(); + } else { + encryptionSpecBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Specifies the customer-managed encryption key spec for
+     * a Scope. If set, this Scope and all sub-resources will be secured by this
+     * key.
+     *
+     * The key is immutable after the Scope is created and must be a multi-region
+     * (`us` or `eu`) key in the same region as the Scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + */ + public Builder mergeEncryptionSpec(com.google.cloud.aiplatform.v1.EncryptionSpec value) { + if (encryptionSpecBuilder_ == null) { + if (((bitField0_ & 0x00000040) != 0) + && encryptionSpec_ != null + && encryptionSpec_ + != com.google.cloud.aiplatform.v1.EncryptionSpec.getDefaultInstance()) { + getEncryptionSpecBuilder().mergeFrom(value); + } else { + encryptionSpec_ = value; + } + } else { + encryptionSpecBuilder_.mergeFrom(value); + } + if (encryptionSpec_ != null) { + bitField0_ |= 0x00000040; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Specifies the customer-managed encryption key spec for
+     * a Scope. If set, this Scope and all sub-resources will be secured by this
+     * key.
+     *
+     * The key is immutable after the Scope is created and must be a multi-region
+     * (`us` or `eu`) key in the same region as the Scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + */ + public Builder clearEncryptionSpec() { + bitField0_ = (bitField0_ & ~0x00000040); + encryptionSpec_ = null; + if (encryptionSpecBuilder_ != null) { + encryptionSpecBuilder_.dispose(); + encryptionSpecBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Immutable. Specifies the customer-managed encryption key spec for
+     * a Scope. If set, this Scope and all sub-resources will be secured by this
+     * key.
+     *
+     * The key is immutable after the Scope is created and must be a multi-region
+     * (`us` or `eu`) key in the same region as the Scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + */ + public com.google.cloud.aiplatform.v1.EncryptionSpec.Builder getEncryptionSpecBuilder() { + bitField0_ |= 0x00000040; + onChanged(); + return internalGetEncryptionSpecFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Optional. Immutable. Specifies the customer-managed encryption key spec for
+     * a Scope. If set, this Scope and all sub-resources will be secured by this
+     * key.
+     *
+     * The key is immutable after the Scope is created and must be a multi-region
+     * (`us` or `eu`) key in the same region as the Scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + */ + public com.google.cloud.aiplatform.v1.EncryptionSpecOrBuilder getEncryptionSpecOrBuilder() { + if (encryptionSpecBuilder_ != null) { + return encryptionSpecBuilder_.getMessageOrBuilder(); + } else { + return encryptionSpec_ == null + ? com.google.cloud.aiplatform.v1.EncryptionSpec.getDefaultInstance() + : encryptionSpec_; + } + } + + /** + * + * + *
+     * Optional. Immutable. Specifies the customer-managed encryption key spec for
+     * a Scope. If set, this Scope and all sub-resources will be secured by this
+     * key.
+     *
+     * The key is immutable after the Scope is created and must be a multi-region
+     * (`us` or `eu`) key in the same region as the Scope.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.EncryptionSpec, + com.google.cloud.aiplatform.v1.EncryptionSpec.Builder, + com.google.cloud.aiplatform.v1.EncryptionSpecOrBuilder> + internalGetEncryptionSpecFieldBuilder() { + if (encryptionSpecBuilder_ == null) { + encryptionSpecBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.EncryptionSpec, + com.google.cloud.aiplatform.v1.EncryptionSpec.Builder, + com.google.cloud.aiplatform.v1.EncryptionSpecOrBuilder>( + getEncryptionSpec(), getParentForChildren(), isClean()); + encryptionSpec_ = null; + } + return encryptionSpecBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.AgentAnomalyDetectionScope) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.AgentAnomalyDetectionScope) + private static final com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope(); + } + + public static com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AgentAnomalyDetectionScope parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionScopeName.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionScopeName.java new file mode 100644 index 000000000000..044babdf4d49 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionScopeName.java @@ -0,0 +1,244 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class AgentAnomalyDetectionScopeName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_AGENT_ANOMALY_DETECTION_SCOPE = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String agentAnomalyDetectionScope; + + @Deprecated + protected AgentAnomalyDetectionScopeName() { + project = null; + location = null; + agentAnomalyDetectionScope = null; + } + + private AgentAnomalyDetectionScopeName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + agentAnomalyDetectionScope = + Preconditions.checkNotNull(builder.getAgentAnomalyDetectionScope()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAgentAnomalyDetectionScope() { + return agentAnomalyDetectionScope; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static AgentAnomalyDetectionScopeName of( + String project, String location, String agentAnomalyDetectionScope) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setAgentAnomalyDetectionScope(agentAnomalyDetectionScope) + .build(); + } + + public static String format(String project, String location, String agentAnomalyDetectionScope) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setAgentAnomalyDetectionScope(agentAnomalyDetectionScope) + .build() + .toString(); + } + + public static @Nullable AgentAnomalyDetectionScopeName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_AGENT_ANOMALY_DETECTION_SCOPE.validatedMatch( + formattedString, + "AgentAnomalyDetectionScopeName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("agent_anomaly_detection_scope")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable AgentAnomalyDetectionScopeName> values) { + List list = new ArrayList<>(values.size()); + for (AgentAnomalyDetectionScopeName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_AGENT_ANOMALY_DETECTION_SCOPE.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (agentAnomalyDetectionScope != null) { + fieldMapBuilder.put("agent_anomaly_detection_scope", agentAnomalyDetectionScope); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_AGENT_ANOMALY_DETECTION_SCOPE.instantiate( + "project", + project, + "location", + location, + "agent_anomaly_detection_scope", + agentAnomalyDetectionScope); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + AgentAnomalyDetectionScopeName that = ((AgentAnomalyDetectionScopeName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.agentAnomalyDetectionScope, that.agentAnomalyDetectionScope); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(agentAnomalyDetectionScope); + return h; + } + + /** + * Builder for + * projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}. + */ + public static class Builder { + private String project; + private String location; + private String agentAnomalyDetectionScope; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAgentAnomalyDetectionScope() { + return agentAnomalyDetectionScope; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setAgentAnomalyDetectionScope(String agentAnomalyDetectionScope) { + this.agentAnomalyDetectionScope = agentAnomalyDetectionScope; + return this; + } + + private Builder(AgentAnomalyDetectionScopeName agentAnomalyDetectionScopeName) { + this.project = agentAnomalyDetectionScopeName.project; + this.location = agentAnomalyDetectionScopeName.location; + this.agentAnomalyDetectionScope = agentAnomalyDetectionScopeName.agentAnomalyDetectionScope; + } + + public AgentAnomalyDetectionScopeName build() { + return new AgentAnomalyDetectionScopeName(this); + } + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionScopeOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionScopeOrBuilder.java new file mode 100644 index 000000000000..e624ae209e7e --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionScopeOrBuilder.java @@ -0,0 +1,329 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface AgentAnomalyDetectionScopeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.AgentAnomalyDetectionScope) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Identifier. The resource name of the AgentAnomalyDetectionScope.
+   * Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Identifier. The resource name of the AgentAnomalyDetectionScope.
+   * Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Optional. User-provided display name of the AgentAnomalyDetectionScope.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
+   * Optional. User-provided display name of the AgentAnomalyDetectionScope.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
+   * Required. Customer-owned Cloud Logging bucket resource names attached to
+   * this scope. Specify exactly one bucket, in the same project as this scope.
+   * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+   * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return A list containing the logBuckets. + */ + java.util.List getLogBucketsList(); + + /** + * + * + *
+   * Required. Customer-owned Cloud Logging bucket resource names attached to
+   * this scope. Specify exactly one bucket, in the same project as this scope.
+   * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+   * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The count of logBuckets. + */ + int getLogBucketsCount(); + + /** + * + * + *
+   * Required. Customer-owned Cloud Logging bucket resource names attached to
+   * this scope. Specify exactly one bucket, in the same project as this scope.
+   * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+   * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the element to return. + * @return The logBuckets at the given index. + */ + java.lang.String getLogBuckets(int index); + + /** + * + * + *
+   * Required. Customer-owned Cloud Logging bucket resource names attached to
+   * this scope. Specify exactly one bucket, in the same project as this scope.
+   * Format: `projects/{project}/locations/{location}/buckets/{bucket}`.
+   * 
+ * + * repeated string log_buckets = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the value to return. + * @return The bytes of the logBuckets at the given index. + */ + com.google.protobuf.ByteString getLogBucketsBytes(int index); + + /** + * + * + *
+   * Required. Customer-owned Cloud Observability datasets attached to this
+   * scope. Each value is the resource name of a dataset in an Observability
+   * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+   * exactly one dataset, in the same project as this scope.
+   * Format:
+   * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+   * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return A list containing the observabilityBuckets. + */ + java.util.List getObservabilityBucketsList(); + + /** + * + * + *
+   * Required. Customer-owned Cloud Observability datasets attached to this
+   * scope. Each value is the resource name of a dataset in an Observability
+   * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+   * exactly one dataset, in the same project as this scope.
+   * Format:
+   * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+   * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The count of observabilityBuckets. + */ + int getObservabilityBucketsCount(); + + /** + * + * + *
+   * Required. Customer-owned Cloud Observability datasets attached to this
+   * scope. Each value is the resource name of a dataset in an Observability
+   * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+   * exactly one dataset, in the same project as this scope.
+   * Format:
+   * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+   * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param index The index of the element to return. + * @return The observabilityBuckets at the given index. + */ + java.lang.String getObservabilityBuckets(int index); + + /** + * + * + *
+   * Required. Customer-owned Cloud Observability datasets attached to this
+   * scope. Each value is the resource name of a dataset in an Observability
+   * bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify
+   * exactly one dataset, in the same project as this scope.
+   * Format:
+   * `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`.
+   * 
+ * + * repeated string observability_buckets = 6 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param index The index of the value to return. + * @return The bytes of the observabilityBuckets at the given index. + */ + com.google.protobuf.ByteString getObservabilityBucketsBytes(int index); + + /** + * + * + *
+   * Optional. When `true`, newly discovered agents that share log and
+   * observability buckets with this scope are automatically enrolled as
+   * `ACTIVE` MonitoredAgents, up to the project's monitored agent quota. When
+   * `false`, newly discovered agents are added as `DISABLED` MonitoredAgents,
+   * and you must enable them explicitly through MonitoredAgent operations.
+   * 
+ * + * bool auto_enroll = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The autoEnroll. + */ + boolean getAutoEnroll(); + + /** + * + * + *
+   * Output only. The lifecycle state of the scope.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
+   * Output only. The lifecycle state of the scope.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.State getState(); + + /** + * + * + *
+   * Optional. Immutable. Specifies the customer-managed encryption key spec for
+   * a Scope. If set, this Scope and all sub-resources will be secured by this
+   * key.
+   *
+   * The key is immutable after the Scope is created and must be a multi-region
+   * (`us` or `eu`) key in the same region as the Scope.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return Whether the encryptionSpec field is set. + */ + boolean hasEncryptionSpec(); + + /** + * + * + *
+   * Optional. Immutable. Specifies the customer-managed encryption key spec for
+   * a Scope. If set, this Scope and all sub-resources will be secured by this
+   * key.
+   *
+   * The key is immutable after the Scope is created and must be a multi-region
+   * (`us` or `eu`) key in the same region as the Scope.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The encryptionSpec. + */ + com.google.cloud.aiplatform.v1.EncryptionSpec getEncryptionSpec(); + + /** + * + * + *
+   * Optional. Immutable. Specifies the customer-managed encryption key spec for
+   * a Scope. If set, this Scope and all sub-resources will be secured by this
+   * key.
+   *
+   * The key is immutable after the Scope is created and must be a multi-region
+   * (`us` or `eu`) key in the same region as the Scope.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.EncryptionSpec encryption_spec = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE]; + * + */ + com.google.cloud.aiplatform.v1.EncryptionSpecOrBuilder getEncryptionSpecOrBuilder(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceProto.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceProto.java new file mode 100644 index 000000000000..720e1f209d46 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentAnomalyDetectionServiceProto.java @@ -0,0 +1,949 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public final class AgentAnomalyDetectionServiceProto extends com.google.protobuf.GeneratedFile { + private AgentAnomalyDetectionServiceProto() {} + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AgentAnomalyDetectionServiceProto"); + } + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_AgentAnomalyDetectionScope_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_AgentAnomalyDetectionScope_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_MonitoredAgent_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_MonitoredAgent_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_AgentResource_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_AgentResource_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeOperationMetadata_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeOperationMetadata_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_GetAgentAnomalyDetectionScopeRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_GetAgentAnomalyDetectionScopeRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeOperationMetadata_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeOperationMetadata_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_GetMonitoredAgentRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_GetMonitoredAgentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentOperationMetadata_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentOperationMetadata_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentOperationMetadata_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentOperationMetadata_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataOperationMetadata_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataOperationMetadata_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_Assessment_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_Assessment_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_Assessment_DetectorFinding_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_Assessment_DetectorFinding_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritySummary_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritySummary_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritiesEntry_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritiesEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_SeveritiesEntry_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_SeveritiesEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_GetAnalyzedSessionRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_GetAnalyzedSessionRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_AnalyzedInvocation_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_AnalyzedInvocation_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_GetAnalyzedInvocationRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_GetAnalyzedInvocationRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_SeveritiesEntry_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_SeveritiesEntry_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n" + + "@google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto\022\032google.cloud" + + ".aiplatform.v1\032\034google/api/annotations.p" + + "roto\032\027google/api/client.proto\032\037google/ap" + + "i/field_behavior.proto\032\031google/api/resou" + + "rce.proto\0320google/cloud/aiplatform/v1/encryption_spec.proto\032*google/cloud/aiplat" + + "form/v1/operation.proto\032#google/longrunn" + + "ing/operations.proto\032\033google/protobuf/em" + + "pty.proto\032\037google/protobuf/timestamp.proto\"\203\005\n" + + "\032AgentAnomalyDetectionScope\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + + "\014display_name\030\002 \001(\tB\004\342A\001\001\022\031\n" + + "\013log_buckets\030\005 \003(\tB\004\342A\001\002\022#\n" + + "\025observability_buckets\030\006 \003(\tB\004\342A\001\002\022\031\n" + + "\013auto_enroll\030\007 \001(\010B\004\342A\001\001\022Q\n" + + "\005state\030\010 \001(\0162<.google.clo" + + "ud.aiplatform.v1.AgentAnomalyDetectionScope.StateB\004\342A\001\003\022J\n" + + "\017encryption_spec\030\t \001(\013" + + "2*.google.cloud.aiplatform.v1.EncryptionSpecB\005\342A\002\001\005\"`\n" + + "\005State\022\025\n" + + "\021STATE_UNSPECIFIED\020\000\022\014\n" + + "\010CREATING\020\001\022\n\n" + + "\006ACTIVE\020\002\022\014\n" + + "\010DELETING\020\003\022\n\n" + + "\006FAILED\020\004\022\014\n" + + "\010UPDATING\020\005:\330\001\352A\324\001\n" + + "4aiplatform.googleapis.com/AgentAnomalyDetectionScope\022cprojects/{project}/locations" + + "/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}*\033agentAn" + + "omalyDetectionScopes2\032agentAnomalyDetectionScope\"\340\004\n" + + "\016MonitoredAgent\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + + "\014display_name\030\002 \001(\tB\004\342A\001\001\022G\n" + + "\016agent_resource\030\003" + + " \001(\0132).google.cloud.aiplatform.v1.AgentResourceB\004\342A\001\002\022O\n" + + "\005state\030\004 " + + "\001(\0162:.google.cloud.aiplatform.v1.MonitoredAgent.EnablementStateB\004\342A\001\003\022\034\n" + + "\016status_message\030\005 \001(\tB\004\342A\001\003\0225\n" + + "\013create_time\030\010" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + + "\013update_time\030\t \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\"[\n" + + "\017EnablementState\022 \n" + + "\034ENABLEMENT_STATE_UNSPECIFIED\020\000\022\n\n" + + "\006ACTIVE\020\001\022\014\n" + + "\010ENABLING\020\003\022\014\n" + + "\010DISABLED\020\006:\232\001\352A\226\001\n" + + "(aiplatform.googleapis.com/MonitoredAgent\022Iproject" + + "s/{project}/locations/{location}/monitor" + + "edAgents/{monitored_agent}*\017monitoredAgents2\016monitoredAgent\"\313\003\n\r" + + "AgentResource\022M\n" + + "\n" + + "agent_type\030\001" + + " \001(\01623.google.cloud.aiplatform.v1.AgentResource.AgentTypeB\004\342A\001\002\022\031\n" + + "\005agent\030\002 \001(\tB\n" + + "\342A\001\002\372A\003\n" + + "\001*\022\026\n" + + "\010location\030\003 \001(\tB\004\342A\001\003\022W\n" + + "\017agent_framework\030\004 \001(\01628.googl" + + "e.cloud.aiplatform.v1.AgentResource.AgentFrameworkB\004\342A\001\001\"\242\001\n" + + "\tAgentType\022\032\n" + + "\026AGENT_TYPE_UNSPECIFIED\020\000\022\024\n" + + "\020REASONING_ENGINE\020\001\022\025\n" + + "\021CLOUD_RUN_SERVICE\020\002\022\020\n" + + "\014GKE_WORKLOAD\020\003\022\020\n" + + "\014GCE_INSTANCE\020\004\022\024\n" + + "\020AGENT_TYPE_OTHER\020\005\022\007\n" + + "\003AWS\020\010\022\t\n" + + "\005AZURE\020\t\":\n" + + "\016AgentFramework\022\037\n" + + "\033AGENT_FRAMEWORK_UNSPECIFIED\020\000\022\007\n" + + "\003ADK\020\001\"\372\001\n" + + "\'CreateAgentAnomalyDetectionScopeRequest\022:\n" + + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + + "!locations.googleapis.com/Location\022c\n" + + "\035agent_anomaly_detection_scope\030\002 \001(\01326.google.cloud." + + "aiplatform.v1.AgentAnomalyDetectionScopeB\004\342A\001\002\022.\n" + + " agent_anomaly_detection_scope_id\030\003 \001(\tB\004\342A\001\002\"\262\001\n" + + "1CreateAgentAnomalyDetectionScopeOperationMetadata\022N\n" + + "\020generic_metadata\030\001" + + " \001(\01324.google.cloud.aiplatform.v1.GenericOperationMetadata\022-\n" + + "\tdone_time\030\002 \001(\0132\032.google.protobuf.Timestamp\"s\n" + + "$GetAgentAnomalyDetectionScopeRequest\022K\n" + + "\004name\030\001 \001(\tB=\342A\001\002\372A6\n" + + "4aiplatform.googleapis.com/AgentAnomalyDetectionScope\"v\n" + + "\'DeleteAgentAnomalyDetectionScopeRequest\022K\n" + + "\004name\030\001 \001(\tB=\342A\001\002\372A6\n" + + "4aiplatform.googleapis.com/AgentAnomalyDetectionScope\"\262\001\n" + + "1DeleteAgentAnomalyDetectionScopeOperationMetadata\022N\n" + + "\020generic_metadata\030\001 \001(\01324.googl" + + "e.cloud.aiplatform.v1.GenericOperationMetadata\022-\n" + + "\tdone_time\030\002 \001(\0132\032.google.protobuf.Timestamp\"\227\001\n" + + "&ListAgentAnomalyDetectionScopesRequest\022:\n" + + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + + "!locations.googleapis.com/Location\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\"\242\001\n" + + "\'ListAgentAnomalyDetectionScopesResponse\022^\n" + + "\036agent_anomaly_detection_scopes\030\001" + + " \003(\01326.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope\022\027\n" + + "\017next_page_token\030\002 \001(\t\"[\n" + + "\030GetMonitoredAgentRequest\022?\n" + + "\004name\030\001 \001(\tB1\342A\001\002\372A*\n" + + "(aiplatform.googleapis.com/MonitoredAgent\"\241\001\n" + + "\032ListMonitoredAgentsRequest\022:\n" + + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + + "!locations.googleapis.com/Location\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + + "\006filter\030\004 \001(\tB\004\342A\001\001\"\220\001\n" + + "\033ListMonitoredAgentsResponse\022D\n" + + "\020monitored_agents\030\001" + + " \003(\0132*.google.cloud.aiplatform.v1.MonitoredAgent\022\027\n" + + "\017next_page_token\030\002 \001(\t\022\022\n\n" + + "total_size\030\003 \001(\005\"^\n" + + "\033EnableMonitoredAgentRequest\022?\n" + + "\004name\030\001 \001(\tB1\342A\001\002\372A*\n" + + "(aiplatform.googleapis.com/MonitoredAgent\"w\n" + + "%EnableMonitoredAgentOperationMetadata\022N\n" + + "\020generic_metadata\030\001" + + " \001(\01324.google.cloud.aiplatform.v1.GenericOperationMetadata\"_\n" + + "\034DisableMonitoredAgentRequest\022?\n" + + "\004name\030\001 \001(\tB1\342A\001\002\372A*\n" + + "(aiplatform.googleapis.com/MonitoredAgent\"x\n" + + "&DisableMonitoredAgentOperationMetadata\022N\n" + + "\020generic_metadata\030\001 \001(\01324" + + ".google.cloud.aiplatform.v1.GenericOperationMetadata\"[\n" + + "\030ClearTrainingDataRequest\022?\n" + + "\004name\030\001 \001(\tB1\342A\001\002\372A*\n" + + "(aiplatform.googleapis.com/MonitoredAgent\"\033\n" + + "\031ClearTrainingDataResponse\"\243\001\n" + + "\"ClearTrainingDataOperationMetadata\022N\n" + + "\020generic_metadata\030\001 \001(\0132" + + "4.google.cloud.aiplatform.v1.GenericOperationMetadata\022-\n" + + "\tdone_time\030\002 \001(\0132\032.google.protobuf.Timestamp\"\231\002\n\n" + + "Assessment\022Q\n" + + "\021detector_findings\030\001 \003(\01326.google.cloud.ai" + + "platform.v1.Assessment.DetectorFinding\032\267\001\n" + + "\017DetectorFinding\022\023\n" + + "\013detector_id\030\001 \001(\t\022\024\n" + + "\014display_name\030\002 \001(\t\0226\n" + + "\010severity\030\003 \001(\0162$.google.cloud.aiplatform.v1.Severity\022\023\n" + + "\013explanation\030\004 \001(\t\022\023\n" + + "\013probability\030\005 \001(\001\022\027\n" + + "\017recommendations\030\006 \003(\t\"\251\n\n" + + "\017AnalyzedSession\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\022\030\n\n" + + "session_id\030\002 \001(\tB\004\342A\001\003\022\025\n" + + "\007user_id\030\003 \001(\tB\004\342A\001\003\022\'\n" + + "\023agent_resource_name\030\004 \001(\tB\n" + + "\342A\001\003\372A\003\n" + + "\001*\0225\n" + + "\013create_time\030\005" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022>\n" + + "\024latest_analyzed_time\030\006" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022@\n\n" + + "assessment\030\007" + + " \001(\0132&.google.cloud.aiplatform.v1.AssessmentB\004\342A\001\003\022U\n\n" + + "severities\030\010 \003(\0132" + + ";.google.cloud.aiplatform.v1.AnalyzedSession.SeveritiesEntryB\004\342A\001\003\022U\n\r" + + "session_state\030\t" + + " \001(\01628.google.cloud.aiplatform.v1.AnalyzedSession.SessionStateB\004\342A\001\003\022" + + " \n" + + "\022agent_display_name\030\n" + + " \001(\tB\004\342A\001\003\022U\n" + + "\013agent_state\030\013" + + " \001(\0162:.google.cloud.aiplatform.v1.MonitoredAgent.EnablementStateB\004\342A\001\003\022\026\n" + + "\010location\030\014 \001(\tB\004\342A\001\003\022M\n\n" + + "agent_type\030\r" + + " \001(\01623" + + ".google.cloud.aiplatform.v1.AgentResource.AgentTypeB\004\342A\001\003\032\203\001\n" + + "\017SeveritySummary\022\024\n" + + "\014detector_ids\030\001 \003(\t\022<\n" + + "\016severity_level\030\002 \001(\0162$.google.cloud.aiplatform.v1.Severity\022\034\n" + + "\016sessions_count\030\003 \001(\005B\004\342A\001\003\032n\n" + + "\017SeveritiesEntry\022\013\n" + + "\003key\030\001 \001(\t\022J\n" + + "\005value\030\002 \001(\0132;" + + ".google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary:\0028\001\"\246\001\n" + + "\014SessionState\022\035\n" + + "\031SESSION_STATE_UNSPECIFIED\020\000\022\034\n" + + "\030SESSION_STATE_UNANALYZED\020\001\022\035\n" + + "\031SESSION_STATE_NOT_FLAGGED\020\002\022\031\n" + + "\025SESSION_STATE_FLAGGED\020\003\022\037\n" + + "\033SESSION_STATE_LLM_UNFLAGGED\020\004:\301\001\352A\275\001\n" + + ")aiplatform.googleapis.com/AnalyzedSession\022mprojects/{project}/locations/{locati" + + "on}/monitoredAgents/{monitored_agent}/an" + + "alyzedSessions/{analyzed_session}*\020analyzedSessions2\017analyzedSession\"\206\002\n" + + "\033ListAnalyzedSessionsRequest\022A\n" + + "\006parent\030\001 \001(\tB1\342A\001\002\372A*\n" + + "(aiplatform.googleapis.com/MonitoredAgent\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + + "\006filter\030\004 \001(\tB\004\342A\001\001\022C\n" + + "\004view\030\005" + + " \001(\0162/.google.cloud.aiplatform.v1.AnalyzedSessionViewB\004\342A\001\001\022\026\n" + + "\010order_by\030\006 \001(\tB\004\342A\001\001\"\320\004\n" + + "\034ListAnalyzedSessionsResponse\022F\n" + + "\021analyzed_sessions\030\001 \003(\0132+.goog" + + "le.cloud.aiplatform.v1.AnalyzedSession\022\027\n" + + "\017next_page_token\030\002 \001(\t\022U\n" + + "\007summary\030\003 \001(\013" + + "2D.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary\032\367\002\n" + + "\013ViewSummary\022h\n\n" + + "severities\030\001 \003(\0132T.google.clou" + + "d.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.SeveritiesEntry\022 \n" + + "\030anomalous_sessions_count\030\002 \001(\005\022\034\n" + + "\024total_sessions_count\030\003 \001(\005\022$\n" + + "\026anomalous_agents_count\030\004 \001(\005B\004\342A\001\003\022(\n" + + "\032llm_scanned_sessions_count\030\005 \001(\005B\004\342A\001\003\032n\n" + + "\017SeveritiesEntry\022\013\n" + + "\003key\030\001 \001(\t\022J\n" + + "\005value\030\002 \001(\0132;.google.cloud.a" + + "iplatform.v1.AnalyzedSession.SeveritySummary:\0028\001\"\242\001\n" + + "\031GetAnalyzedSessionRequest\022@\n" + + "\004name\030\001 \001(\tB2\342A\001\002\372A+\n" + + ")aiplatform.googleapis.com/AnalyzedSession\022C\n" + + "\004view\030\002 \001(\0162/" + + ".google.cloud.aiplatform.v1.AnalyzedSessionViewB\004\342A\001\001\"\330\004\n" + + "\022AnalyzedInvocation\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\022\033\n\r" + + "invocation_id\030\002 \001(\tB\004\342A\001\003\022@\n\n" + + "assessment\030\003" + + " \001(\0132&.google.cloud.aiplatform.v1.AssessmentB\004\342A\001\003\022^\n" + + "\020invocation_state\030\004 \001(\0162>.google.cloud.aiplatf" + + "orm.v1.AnalyzedInvocation.InvocationStateB\004\342A\001\003\"w\n" + + "\017InvocationState\022 \n" + + "\034INVOCATION_STATE_UNSPECIFIED\020\000\022\036\n" + + "\032INVOCATION_STATE_ANOMALOUS\020\001\022\"\n" + + "\036INVOCATION_STATE_NOT_ANOMALOUS\020\002:\365\001\352A\361\001\n" + + ",aiplatform.googleapis.com/AnalyzedInvocation\022\227\001projects/{projec" + + "t}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{anal" + + "yzed_session}/analyzedInvocations/{analy" + + "zed_invocation}*\023analyzedInvocations2\022analyzedInvocation\"c\n" + + "\034GetAnalyzedInvocationRequest\022C\n" + + "\004name\030\001 \001(\tB5\342A\001\002\372A.\n" + + ",aiplatform.googleapis.com/AnalyzedInvocation\"\227\001\n" + + "\036ListAnalyzedInvocationsRequest\022B\n" + + "\006parent\030\001 \001(\tB2\342A\001\002\372A+\n" + + ")aiplatform.googleapis.com/AnalyzedSession\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\"\210\001\n" + + "\037ListAnalyzedInvocationsResponse\022L\n" + + "\024analyzed_invocations\030\001" + + " \003(\0132..google.cloud.aiplatform.v1.AnalyzedInvocation\022\027\n" + + "\017next_page_token\030\002 \001(\t\"\256\001\n" + + " AggregateAnalyzedSessionsRequest\022A\n" + + "\006parent\030\001 \001(\tB1\342A\001\002\372A*\n" + + "(aiplatform.googleapis.com/MonitoredAgent\022\024\n" + + "\006filter\030\002 \001(\tB\004\342A\001\001\022\027\n" + + "\tpage_size\030\003 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\004 \001(\tB\004\342A\001\001\"\210\007\n" + + "!AggregateAnalyzedSessionsResponse\022f\n" + + "\020agent_aggregates\030\001 \003(\0132L.google.cloud.aiplatform.v1" + + ".AggregateAnalyzedSessionsResponse.AgentAggregate\022U\n" + + "\007summary\030\002 \001(\0132D.google.clou" + + "d.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary\022\027\n" + + "\017next_page_token\030\003 \001(\t\032\212\005\n" + + "\016AgentAggregate\022\027\n" + + "\017monitored_agent\030\001 \001(\t\022#\n" + + "\023agent_resource_name\030\002 \001(\tB\006\372A\003\n" + + "\001*\022 \n" + + "\022agent_display_name\030\007 \001(\tB\004\342A\001\003\022V\n" + + "\014agent_status\030\010 \001(\0162:.google.cloud.aiplat" + + "form.v1.MonitoredAgent.EnablementStateB\004\342A\001\003\022\026\n" + + "\010location\030\t \001(\tB\004\342A\001\003\022M\n\n" + + "agent_type\030\n" + + " \001(\01623.google.cloud.aiplatform.v1.AgentResource.AgentTypeB\004\342A\001\003\022\034\n" + + "\024total_sessions_count\030\003 \001(\005\022 \n" + + "\030anomalous_sessions_count\030\004 \001(\005\0227\n" + + "\023latest_session_time\030\005 \001(\0132\032.google.protobuf.Timestamp\022p\n\n" + + "severities\030\006 \003(\0132\\.google.cloud.aiplatform.v1.Ag" + + "gregateAnalyzedSessionsResponse.AgentAggregate.SeveritiesEntry\032n\n" + + "\017SeveritiesEntry\022\013\n" + + "\003key\030\001 \001(\t\022J\n" + + "\005value\030\002 \001(\0132;.google.c" + + "loud.aiplatform.v1.AnalyzedSession.SeveritySummary:\0028\001*}\n" + + "\023AnalyzedSessionView\022%\n" + + "!ANALYZED_SESSION_VIEW_UNSPECIFIED\020\000\022\037\n" + + "\033ANALYZED_SESSION_VIEW_BASIC\020\001\022\036\n" + + "\032ANALYZED_SESSION_VIEW_FULL\020\002*u\n" + + "\010Severity\022\030\n" + + "\024SEVERITY_UNSPECIFIED\020\000\022\020\n" + + "\014SEVERITY_LOW\020\001\022\023\n" + + "\017SEVERITY_MEDIUM\020\002\022\021\n\r" + + "SEVERITY_HIGH\020\003\022\025\n" + + "\021SEVERITY_CRITICAL\020\0042\277\034\n" + + "\034AgentAnomalyDetectionService\022\351\001\n" + + "\035GetAgentAnomalyDetectionScope\022@.google.cloud.aiplatform.v1.Get" + + "AgentAnomalyDetectionScopeRequest\0326.google.cloud.aiplatform.v1.AgentAnomalyDetec" + + "tionScope\"N\332A\004name\202\323\344\223\002A\022?/v1/{name=proj" + + "ects/*/locations/*/agentAnomalyDetectionScopes/*}\022\271\001\n" + + "\021GetMonitoredAgent\0224.google.cloud.aiplatform.v1.GetMonitoredAgentRe" + + "quest\032*.google.cloud.aiplatform.v1.Monit" + + "oredAgent\"B\332A\004name\202\323\344\223\0025\0223/v1/{name=proj" + + "ects/*/locations/*/monitoredAgents/*}\022\314\001\n" + + "\023ListMonitoredAgents\0226.google.cloud.aip" + + "latform.v1.ListMonitoredAgentsRequest\0327.google.cloud.aiplatform.v1.ListMonitored" + + "AgentsResponse\"D\332A\006parent\202\323\344\223\0025\0223/v1/{pa" + + "rent=projects/*/locations/*}/monitoredAgents\022\367\001\n" + + "\024EnableMonitoredAgent\0227.google.cloud.aiplatform.v1.EnableMonitoredAgentR" + + "equest\032\035.google.longrunning.Operation\"\206\001\312A7\n" + + "\016MonitoredAgent\022%EnableMonitoredAgen" + + "tOperationMetadata\332A\004name\202\323\344\223\002?\":/v1/{na" + + "me=projects/*/locations/*/monitoredAgents/*}:enable:\001*\022\373\001\n" + + "\025DisableMonitoredAgent\0228.google.cloud.aiplatform.v1.DisableMon" + + "itoredAgentRequest\032\035.google.longrunning.Operation\"\210\001\312A8\n" + + "\016MonitoredAgent\022&DisableMonitoredAgentOperationMetadata\332A\004name\202\323" + + "\344\223\002@\";/v1/{name=projects/*/locations/*/monitoredAgents/*}:disable:\001*\022\244\002\n" + + " DeleteAgentAnomalyDetectionScope\022C.google.cloud" + + ".aiplatform.v1.DeleteAgentAnomalyDetecti" + + "onScopeRequest\032\035.google.longrunning.Operation\"\233\001\312AJ\n" + + "\025google.protobuf.Empty\0221DeleteAgentAnomalyDetectionScopeOperationMet" + + "adata\332A\004name\202\323\344\223\002A*?/v1/{name=projects/*" + + "/locations/*/agentAnomalyDetectionScopes/*}\022\211\003\n" + + " CreateAgentAnomalyDetectionScope\022C.google.cloud.aiplatform.v1.CreateAgen" + + "tAnomalyDetectionScopeRequest\032\035.google.longrunning.Operation\"\200\002\312AO\n" + + "\032AgentAnomalyDetectionScope\0221CreateAgentAnomalyDetect" + + "ionScopeOperationMetadata\332AEparent,agent_anomaly_detection_scope,agent_anomaly_d" + + "etection_scope_id\202\323\344\223\002`\"?/v1/{parent=pro" + + "jects/*/locations/*}/agentAnomalyDetecti" + + "onScopes:\035agent_anomaly_detection_scope\022\374\001\n" + + "\037ListAgentAnomalyDetectionScopes\022B.google.cloud.aiplatform.v1.ListAgentAnomal" + + "yDetectionScopesRequest\032C.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionSc" + + "opesResponse\"P\332A\006parent\202\323\344\223\002A\022?/v1/{pare" + + "nt=projects/*/locations/*}/agentAnomalyDetectionScopes\022\342\001\n" + + "\024ListAnalyzedSessions\0227.google.cloud.aiplatform.v1.ListAnalyze" + + "dSessionsRequest\0328.google.cloud.aiplatfo" + + "rm.v1.ListAnalyzedSessionsResponse\"W\332A\006p" + + "arent\202\323\344\223\002H\022F/v1/{parent=projects/*/loca" + + "tions/*/monitoredAgents/*}/analyzedSessions\022\317\001\n" + + "\022GetAnalyzedSession\0225.google.cloud.aiplatform.v1.GetAnalyzedSessionReques" + + "t\032+.google.cloud.aiplatform.v1.AnalyzedS" + + "ession\"U\332A\004name\202\323\344\223\002H\022F/v1/{name=project" + + "s/*/locations/*/monitoredAgents/*/analyzedSessions/*}\022\201\002\n" + + "\027ListAnalyzedInvocations\022:.google.cloud.aiplatform.v1.ListAnaly" + + "zedInvocationsRequest\032;.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRespon" + + "se\"m\332A\006parent\202\323\344\223\002^\022\\/v1/{parent=project" + + "s/*/locations/*/monitoredAgents/*/analyzedSessions/*}/analyzedInvocations\022\356\001\n" + + "\025GetAnalyzedInvocation\0228.google.cloud.aipla" + + "tform.v1.GetAnalyzedInvocationRequest\032..google.cloud.aiplatform.v1.AnalyzedInvoc" + + "ation\"k\332A\004name\202\323\344\223\002^\022\\/v1/{name=projects" + + "/*/locations/*/monitoredAgents/*/analyzedSessions/*/analyzedInvocations/*}\022\373\001\n" + + "\031AggregateAnalyzedSessions\022<.google.cloud." + + "aiplatform.v1.AggregateAnalyzedSessionsRequest\032=.google.cloud.aiplatform.v1.Aggr" + + "egateAnalyzedSessionsResponse\"a\332A\006parent" + + "\202\323\344\223\002R\022P/v1/{parent=projects/*/locations" + + "/*/monitoredAgents/*}/analyzedSessions:aggregate\022\204\002\n" + + "\021ClearTrainingData\0224.google.cloud.aiplatform.v1.ClearTrainingDataReq" + + "uest\032\035.google.longrunning.Operation\"\231\001\312A?\n" + + "\031ClearTrainingDataResponse\022\"ClearTrain" + + "ingDataOperationMetadata\332A\004name\202\323\344\223\002J\"E/" + + "v1/{name=projects/*/locations/*/monitore" + + "dAgents/*}:clearTrainingData:\001*\032M\312A\031aipl" + + "atform.googleapis.com\322A.https://www.googleapis.com/auth/cloud-platformB\337\001\n" + + "\036com.google.cloud.aiplatform.v1B!AgentAnomalyD" + + "etectionServiceProtoP\001Z>cloud.google.com/go/aiplatform/apiv1/aiplatformpb;aiplat" + + "formpb\252\002\032Google.Cloud.AIPlatform.V1\312\002\032Go" + + "ogle\\Cloud\\AIPlatform\\V1\352\002\035Google::Cloud::AIPlatform::V1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.AnnotationsProto.getDescriptor(), + com.google.api.ClientProto.getDescriptor(), + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.cloud.aiplatform.v1.EncryptionSpecProto.getDescriptor(), + com.google.cloud.aiplatform.v1.OperationProto.getDescriptor(), + com.google.longrunning.OperationsProto.getDescriptor(), + com.google.protobuf.EmptyProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_aiplatform_v1_AgentAnomalyDetectionScope_descriptor = + getDescriptor().getMessageType(0); + internal_static_google_cloud_aiplatform_v1_AgentAnomalyDetectionScope_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_AgentAnomalyDetectionScope_descriptor, + new java.lang.String[] { + "Name", + "DisplayName", + "LogBuckets", + "ObservabilityBuckets", + "AutoEnroll", + "State", + "EncryptionSpec", + }); + internal_static_google_cloud_aiplatform_v1_MonitoredAgent_descriptor = + getDescriptor().getMessageType(1); + internal_static_google_cloud_aiplatform_v1_MonitoredAgent_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_MonitoredAgent_descriptor, + new java.lang.String[] { + "Name", + "DisplayName", + "AgentResource", + "State", + "StatusMessage", + "CreateTime", + "UpdateTime", + }); + internal_static_google_cloud_aiplatform_v1_AgentResource_descriptor = + getDescriptor().getMessageType(2); + internal_static_google_cloud_aiplatform_v1_AgentResource_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_AgentResource_descriptor, + new java.lang.String[] { + "AgentType", "Agent", "Location", "AgentFramework", + }); + internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeRequest_descriptor = + getDescriptor().getMessageType(3); + internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeRequest_descriptor, + new java.lang.String[] { + "Parent", "AgentAnomalyDetectionScope", "AgentAnomalyDetectionScopeId", + }); + internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeOperationMetadata_descriptor = + getDescriptor().getMessageType(4); + internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeOperationMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeOperationMetadata_descriptor, + new java.lang.String[] { + "GenericMetadata", "DoneTime", + }); + internal_static_google_cloud_aiplatform_v1_GetAgentAnomalyDetectionScopeRequest_descriptor = + getDescriptor().getMessageType(5); + internal_static_google_cloud_aiplatform_v1_GetAgentAnomalyDetectionScopeRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_GetAgentAnomalyDetectionScopeRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeRequest_descriptor = + getDescriptor().getMessageType(6); + internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeOperationMetadata_descriptor = + getDescriptor().getMessageType(7); + internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeOperationMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeOperationMetadata_descriptor, + new java.lang.String[] { + "GenericMetadata", "DoneTime", + }); + internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesRequest_descriptor = + getDescriptor().getMessageType(8); + internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesResponse_descriptor = + getDescriptor().getMessageType(9); + internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesResponse_descriptor, + new java.lang.String[] { + "AgentAnomalyDetectionScopes", "NextPageToken", + }); + internal_static_google_cloud_aiplatform_v1_GetMonitoredAgentRequest_descriptor = + getDescriptor().getMessageType(10); + internal_static_google_cloud_aiplatform_v1_GetMonitoredAgentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_GetMonitoredAgentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsRequest_descriptor = + getDescriptor().getMessageType(11); + internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "Filter", + }); + internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsResponse_descriptor = + getDescriptor().getMessageType(12); + internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsResponse_descriptor, + new java.lang.String[] { + "MonitoredAgents", "NextPageToken", "TotalSize", + }); + internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentRequest_descriptor = + getDescriptor().getMessageType(13); + internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentOperationMetadata_descriptor = + getDescriptor().getMessageType(14); + internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentOperationMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentOperationMetadata_descriptor, + new java.lang.String[] { + "GenericMetadata", + }); + internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentRequest_descriptor = + getDescriptor().getMessageType(15); + internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentOperationMetadata_descriptor = + getDescriptor().getMessageType(16); + internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentOperationMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentOperationMetadata_descriptor, + new java.lang.String[] { + "GenericMetadata", + }); + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataRequest_descriptor = + getDescriptor().getMessageType(17); + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataResponse_descriptor = + getDescriptor().getMessageType(18); + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataResponse_descriptor, + new java.lang.String[] {}); + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataOperationMetadata_descriptor = + getDescriptor().getMessageType(19); + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataOperationMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ClearTrainingDataOperationMetadata_descriptor, + new java.lang.String[] { + "GenericMetadata", "DoneTime", + }); + internal_static_google_cloud_aiplatform_v1_Assessment_descriptor = + getDescriptor().getMessageType(20); + internal_static_google_cloud_aiplatform_v1_Assessment_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_Assessment_descriptor, + new java.lang.String[] { + "DetectorFindings", + }); + internal_static_google_cloud_aiplatform_v1_Assessment_DetectorFinding_descriptor = + internal_static_google_cloud_aiplatform_v1_Assessment_descriptor.getNestedType(0); + internal_static_google_cloud_aiplatform_v1_Assessment_DetectorFinding_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_Assessment_DetectorFinding_descriptor, + new java.lang.String[] { + "DetectorId", + "DisplayName", + "Severity", + "Explanation", + "Probability", + "Recommendations", + }); + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_descriptor = + getDescriptor().getMessageType(21); + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_descriptor, + new java.lang.String[] { + "Name", + "SessionId", + "UserId", + "AgentResourceName", + "CreateTime", + "LatestAnalyzedTime", + "Assessment", + "Severities", + "SessionState", + "AgentDisplayName", + "AgentState", + "Location", + "AgentType", + }); + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritySummary_descriptor = + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_descriptor.getNestedType(0); + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritySummary_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritySummary_descriptor, + new java.lang.String[] { + "DetectorIds", "SeverityLevel", "SessionsCount", + }); + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritiesEntry_descriptor = + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_descriptor.getNestedType(1); + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritiesEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritiesEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsRequest_descriptor = + getDescriptor().getMessageType(22); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "Filter", "View", "OrderBy", + }); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_descriptor = + getDescriptor().getMessageType(23); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_descriptor, + new java.lang.String[] { + "AnalyzedSessions", "NextPageToken", "Summary", + }); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_descriptor = + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_descriptor + .getNestedType(0); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_descriptor, + new java.lang.String[] { + "Severities", + "AnomalousSessionsCount", + "TotalSessionsCount", + "AnomalousAgentsCount", + "LlmScannedSessionsCount", + }); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_SeveritiesEntry_descriptor = + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_descriptor + .getNestedType(0); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_SeveritiesEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_SeveritiesEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_aiplatform_v1_GetAnalyzedSessionRequest_descriptor = + getDescriptor().getMessageType(24); + internal_static_google_cloud_aiplatform_v1_GetAnalyzedSessionRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_GetAnalyzedSessionRequest_descriptor, + new java.lang.String[] { + "Name", "View", + }); + internal_static_google_cloud_aiplatform_v1_AnalyzedInvocation_descriptor = + getDescriptor().getMessageType(25); + internal_static_google_cloud_aiplatform_v1_AnalyzedInvocation_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_AnalyzedInvocation_descriptor, + new java.lang.String[] { + "Name", "InvocationId", "Assessment", "InvocationState", + }); + internal_static_google_cloud_aiplatform_v1_GetAnalyzedInvocationRequest_descriptor = + getDescriptor().getMessageType(26); + internal_static_google_cloud_aiplatform_v1_GetAnalyzedInvocationRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_GetAnalyzedInvocationRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsRequest_descriptor = + getDescriptor().getMessageType(27); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsResponse_descriptor = + getDescriptor().getMessageType(28); + internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsResponse_descriptor, + new java.lang.String[] { + "AnalyzedInvocations", "NextPageToken", + }); + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsRequest_descriptor = + getDescriptor().getMessageType(29); + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsRequest_descriptor, + new java.lang.String[] { + "Parent", "Filter", "PageSize", "PageToken", + }); + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_descriptor = + getDescriptor().getMessageType(30); + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_descriptor, + new java.lang.String[] { + "AgentAggregates", "Summary", "NextPageToken", + }); + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_descriptor = + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_descriptor + .getNestedType(0); + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_descriptor, + new java.lang.String[] { + "MonitoredAgent", + "AgentResourceName", + "AgentDisplayName", + "AgentStatus", + "Location", + "AgentType", + "TotalSessionsCount", + "AnomalousSessionsCount", + "LatestSessionTime", + "Severities", + }); + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_SeveritiesEntry_descriptor = + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_descriptor + .getNestedType(0); + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_SeveritiesEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_SeveritiesEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + descriptor.resolveAllFeaturesImmutable(); + com.google.api.AnnotationsProto.getDescriptor(); + com.google.api.ClientProto.getDescriptor(); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.cloud.aiplatform.v1.EncryptionSpecProto.getDescriptor(); + com.google.cloud.aiplatform.v1.OperationProto.getDescriptor(); + com.google.longrunning.OperationsProto.getDescriptor(); + com.google.protobuf.EmptyProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.ClientProto.defaultHost); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.AnnotationsProto.http); + registry.add(com.google.api.ClientProto.methodSignature); + registry.add(com.google.api.ClientProto.oauthScopes); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceReference); + registry.add(com.google.longrunning.OperationsProto.operationInfo); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentResource.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentResource.java new file mode 100644 index 000000000000..138d63a2b072 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentResource.java @@ -0,0 +1,1809 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Defines the identity of an agent being monitored.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AgentResource} + */ +@com.google.protobuf.Generated +public final class AgentResource extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.AgentResource) + AgentResourceOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AgentResource"); + } + + // Use AgentResource.newBuilder() to construct. + private AgentResource(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AgentResource() { + agentType_ = 0; + agent_ = ""; + location_ = ""; + agentFramework_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AgentResource_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AgentResource_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AgentResource.class, + com.google.cloud.aiplatform.v1.AgentResource.Builder.class); + } + + /** + * + * + *
+   * The runtime type of an agent, describing where the agent is hosted. This is
+   * orthogonal to the framework the agent is built with; see `AgentFramework`.
+   * 
+ * + * Protobuf enum {@code google.cloud.aiplatform.v1.AgentResource.AgentType} + */ + public enum AgentType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * The default value, used when the runtime type is unspecified.
+     * 
+ * + * AGENT_TYPE_UNSPECIFIED = 0; + */ + AGENT_TYPE_UNSPECIFIED(0), + /** + * + * + *
+     * The agent runs on the Gemini Enterprise Agent Platform Agent Runtime
+     * (Reasoning Engine).
+     * 
+ * + * REASONING_ENGINE = 1; + */ + REASONING_ENGINE(1), + /** + * + * + *
+     * The agent runs as a Google Cloud Run service.
+     * 
+ * + * CLOUD_RUN_SERVICE = 2; + */ + CLOUD_RUN_SERVICE(2), + /** + * + * + *
+     * The agent runs as a workload on Google Kubernetes Engine.
+     * 
+ * + * GKE_WORKLOAD = 3; + */ + GKE_WORKLOAD(3), + /** + * + * + *
+     * The agent runs on a Compute Engine instance.
+     * 
+ * + * GCE_INSTANCE = 4; + */ + GCE_INSTANCE(4), + /** + * + * + *
+     * The agent runs on a runtime that no other value represents, such as a
+     * self-hosted or on-premises environment.
+     * 
+ * + * AGENT_TYPE_OTHER = 5; + */ + AGENT_TYPE_OTHER(5), + /** + * + * + *
+     * The agent runs on Amazon Web Services (AWS), such as on AWS Lambda.
+     * 
+ * + * AWS = 8; + */ + AWS(8), + /** + * + * + *
+     * The agent runs on Microsoft Azure, such as on Azure Kubernetes Service
+     * (AKS) or as a Microsoft Foundry hosted agent.
+     * 
+ * + * AZURE = 9; + */ + AZURE(9), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AgentType"); + } + + /** + * + * + *
+     * The default value, used when the runtime type is unspecified.
+     * 
+ * + * AGENT_TYPE_UNSPECIFIED = 0; + */ + public static final int AGENT_TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The agent runs on the Gemini Enterprise Agent Platform Agent Runtime
+     * (Reasoning Engine).
+     * 
+ * + * REASONING_ENGINE = 1; + */ + public static final int REASONING_ENGINE_VALUE = 1; + + /** + * + * + *
+     * The agent runs as a Google Cloud Run service.
+     * 
+ * + * CLOUD_RUN_SERVICE = 2; + */ + public static final int CLOUD_RUN_SERVICE_VALUE = 2; + + /** + * + * + *
+     * The agent runs as a workload on Google Kubernetes Engine.
+     * 
+ * + * GKE_WORKLOAD = 3; + */ + public static final int GKE_WORKLOAD_VALUE = 3; + + /** + * + * + *
+     * The agent runs on a Compute Engine instance.
+     * 
+ * + * GCE_INSTANCE = 4; + */ + public static final int GCE_INSTANCE_VALUE = 4; + + /** + * + * + *
+     * The agent runs on a runtime that no other value represents, such as a
+     * self-hosted or on-premises environment.
+     * 
+ * + * AGENT_TYPE_OTHER = 5; + */ + public static final int AGENT_TYPE_OTHER_VALUE = 5; + + /** + * + * + *
+     * The agent runs on Amazon Web Services (AWS), such as on AWS Lambda.
+     * 
+ * + * AWS = 8; + */ + public static final int AWS_VALUE = 8; + + /** + * + * + *
+     * The agent runs on Microsoft Azure, such as on Azure Kubernetes Service
+     * (AKS) or as a Microsoft Foundry hosted agent.
+     * 
+ * + * AZURE = 9; + */ + public static final int AZURE_VALUE = 9; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static AgentType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static AgentType forNumber(int value) { + switch (value) { + case 0: + return AGENT_TYPE_UNSPECIFIED; + case 1: + return REASONING_ENGINE; + case 2: + return CLOUD_RUN_SERVICE; + case 3: + return GKE_WORKLOAD; + case 4: + return GCE_INSTANCE; + case 5: + return AGENT_TYPE_OTHER; + case 8: + return AWS; + case 9: + return AZURE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public AgentType findValueByNumber(int number) { + return AgentType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentResource.getDescriptor().getEnumTypes().get(0); + } + + private static final AgentType[] VALUES = values(); + + public static AgentType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private AgentType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.aiplatform.v1.AgentResource.AgentType) + } + + /** + * + * + *
+   * The framework used to build an agent, such as the Agent Development Kit
+   * (ADK). This is orthogonal to the runtime the agent is hosted on; see
+   * `AgentType`.
+   * 
+ * + * Protobuf enum {@code google.cloud.aiplatform.v1.AgentResource.AgentFramework} + */ + public enum AgentFramework implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * The default value, used when the framework is unspecified.
+     * 
+ * + * AGENT_FRAMEWORK_UNSPECIFIED = 0; + */ + AGENT_FRAMEWORK_UNSPECIFIED(0), + /** + * + * + *
+     * The agent is built with the Agent Development Kit (ADK).
+     * 
+ * + * ADK = 1; + */ + ADK(1), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AgentFramework"); + } + + /** + * + * + *
+     * The default value, used when the framework is unspecified.
+     * 
+ * + * AGENT_FRAMEWORK_UNSPECIFIED = 0; + */ + public static final int AGENT_FRAMEWORK_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The agent is built with the Agent Development Kit (ADK).
+     * 
+ * + * ADK = 1; + */ + public static final int ADK_VALUE = 1; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static AgentFramework valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static AgentFramework forNumber(int value) { + switch (value) { + case 0: + return AGENT_FRAMEWORK_UNSPECIFIED; + case 1: + return ADK; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public AgentFramework findValueByNumber(int number) { + return AgentFramework.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentResource.getDescriptor().getEnumTypes().get(1); + } + + private static final AgentFramework[] VALUES = values(); + + public static AgentFramework valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private AgentFramework(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.aiplatform.v1.AgentResource.AgentFramework) + } + + public static final int AGENT_TYPE_FIELD_NUMBER = 1; + private int agentType_ = 0; + + /** + * + * + *
+   * Required. The runtime type of the agent.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for agentType. + */ + @java.lang.Override + public int getAgentTypeValue() { + return agentType_; + } + + /** + * + * + *
+   * Required. The runtime type of the agent.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentType. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource.AgentType getAgentType() { + com.google.cloud.aiplatform.v1.AgentResource.AgentType result = + com.google.cloud.aiplatform.v1.AgentResource.AgentType.forNumber(agentType_); + return result == null + ? com.google.cloud.aiplatform.v1.AgentResource.AgentType.UNRECOGNIZED + : result; + } + + public static final int AGENT_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object agent_ = ""; + + /** + * + * + *
+   * Required. The resource name or identifier of the agent to monitor. The
+   * format depends on `agent_type`:
+   *
+   * * `REASONING_ENGINE`:
+   * `//aiplatform.googleapis.com/projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}`
+   * * `CLOUD_RUN_SERVICE`: the full resource name of the Cloud Run service,
+   * `//run.googleapis.com/projects/{project}/locations/{location}/services/{service}`
+   * * `GKE_WORKLOAD`: the full resource name of the Google Kubernetes Engine
+   * cluster followed by the agent's OpenTelemetry `service.name`,
+   * `//container.googleapis.com/projects/{project}/locations/{location}/clusters/{cluster}/{service}`.
+   * For a zonal cluster, `zones/{zone}` replaces `locations/{location}`.
+   * Some names end in
+   * `k8s/namespaces/{namespace}/apps/deployments/{deployment}` instead of
+   * `{service}`.
+   * * `GCE_INSTANCE`: the full resource name of the Compute Engine instance
+   * followed by the agent's OpenTelemetry `service.name`,
+   * `//compute.googleapis.com/projects/{project}/zones/{zone}/instances/{instance}/{service}`,
+   * where `{instance}` is the numeric instance ID.
+   * * `AWS` and `AZURE`: an identifier built from the agent's OpenTelemetry
+   * resource attributes, usually `{platform}:{account}:{region}:{name}`.
+   * `{platform}` is the `cloud.platform` value. `{account}` is
+   * `cloud.account.id`, or the ID of the Google Cloud project that receives
+   * the telemetry if `cloud.account.id` isn't set. `{region}` is
+   * `cloud.region`. `{name}` is `faas.name`, or the Kubernetes cluster name
+   * followed by `/k8s/namespaces/{namespace}/apps/deployments/{deployment}`
+   * or `/{service}`. For example,
+   * `aws_lambda:123456789012:us-east-2:inventory-agent`.
+   * * `AGENT_TYPE_OTHER`: a stable identifier for the agent, such as the full
+   * resource name of its runtime or its OpenTelemetry `service.name`.
+   * 
+ * + * + * string agent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The agent. + */ + @java.lang.Override + public java.lang.String getAgent() { + java.lang.Object ref = agent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The resource name or identifier of the agent to monitor. The
+   * format depends on `agent_type`:
+   *
+   * * `REASONING_ENGINE`:
+   * `//aiplatform.googleapis.com/projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}`
+   * * `CLOUD_RUN_SERVICE`: the full resource name of the Cloud Run service,
+   * `//run.googleapis.com/projects/{project}/locations/{location}/services/{service}`
+   * * `GKE_WORKLOAD`: the full resource name of the Google Kubernetes Engine
+   * cluster followed by the agent's OpenTelemetry `service.name`,
+   * `//container.googleapis.com/projects/{project}/locations/{location}/clusters/{cluster}/{service}`.
+   * For a zonal cluster, `zones/{zone}` replaces `locations/{location}`.
+   * Some names end in
+   * `k8s/namespaces/{namespace}/apps/deployments/{deployment}` instead of
+   * `{service}`.
+   * * `GCE_INSTANCE`: the full resource name of the Compute Engine instance
+   * followed by the agent's OpenTelemetry `service.name`,
+   * `//compute.googleapis.com/projects/{project}/zones/{zone}/instances/{instance}/{service}`,
+   * where `{instance}` is the numeric instance ID.
+   * * `AWS` and `AZURE`: an identifier built from the agent's OpenTelemetry
+   * resource attributes, usually `{platform}:{account}:{region}:{name}`.
+   * `{platform}` is the `cloud.platform` value. `{account}` is
+   * `cloud.account.id`, or the ID of the Google Cloud project that receives
+   * the telemetry if `cloud.account.id` isn't set. `{region}` is
+   * `cloud.region`. `{name}` is `faas.name`, or the Kubernetes cluster name
+   * followed by `/k8s/namespaces/{namespace}/apps/deployments/{deployment}`
+   * or `/{service}`. For example,
+   * `aws_lambda:123456789012:us-east-2:inventory-agent`.
+   * * `AGENT_TYPE_OTHER`: a stable identifier for the agent, such as the full
+   * resource name of its runtime or its OpenTelemetry `service.name`.
+   * 
+ * + * + * string agent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for agent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAgentBytes() { + java.lang.Object ref = agent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int LOCATION_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object location_ = ""; + + /** + * + * + *
+   * Output only. The region of the agent resource: a Google Cloud location
+   * (for example, `us-central1`), or for an `AWS` or `AZURE` agent, the region
+   * in that cloud (for example, `us-east-2`).
+   * 
+ * + * string location = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The location. + */ + @java.lang.Override + public java.lang.String getLocation() { + java.lang.Object ref = location_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + location_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. The region of the agent resource: a Google Cloud location
+   * (for example, `us-central1`), or for an `AWS` or `AZURE` agent, the region
+   * in that cloud (for example, `us-east-2`).
+   * 
+ * + * string location = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for location. + */ + @java.lang.Override + public com.google.protobuf.ByteString getLocationBytes() { + java.lang.Object ref = location_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + location_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int AGENT_FRAMEWORK_FIELD_NUMBER = 4; + private int agentFramework_ = 0; + + /** + * + * + *
+   * Optional. The framework used to build the agent, orthogonal to the runtime
+   * `agent_type`.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentFramework agent_framework = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for agentFramework. + */ + @java.lang.Override + public int getAgentFrameworkValue() { + return agentFramework_; + } + + /** + * + * + *
+   * Optional. The framework used to build the agent, orthogonal to the runtime
+   * `agent_type`.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentFramework agent_framework = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The agentFramework. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource.AgentFramework getAgentFramework() { + com.google.cloud.aiplatform.v1.AgentResource.AgentFramework result = + com.google.cloud.aiplatform.v1.AgentResource.AgentFramework.forNumber(agentFramework_); + return result == null + ? com.google.cloud.aiplatform.v1.AgentResource.AgentFramework.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (agentType_ + != com.google.cloud.aiplatform.v1.AgentResource.AgentType.AGENT_TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, agentType_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, agent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(location_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, location_); + } + if (agentFramework_ + != com.google.cloud.aiplatform.v1.AgentResource.AgentFramework.AGENT_FRAMEWORK_UNSPECIFIED + .getNumber()) { + output.writeEnum(4, agentFramework_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (agentType_ + != com.google.cloud.aiplatform.v1.AgentResource.AgentType.AGENT_TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, agentType_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, agent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(location_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, location_); + } + if (agentFramework_ + != com.google.cloud.aiplatform.v1.AgentResource.AgentFramework.AGENT_FRAMEWORK_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, agentFramework_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.AgentResource)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.AgentResource other = + (com.google.cloud.aiplatform.v1.AgentResource) obj; + + if (agentType_ != other.agentType_) return false; + if (!getAgent().equals(other.getAgent())) return false; + if (!getLocation().equals(other.getLocation())) return false; + if (agentFramework_ != other.agentFramework_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + AGENT_TYPE_FIELD_NUMBER; + hash = (53 * hash) + agentType_; + hash = (37 * hash) + AGENT_FIELD_NUMBER; + hash = (53 * hash) + getAgent().hashCode(); + hash = (37 * hash) + LOCATION_FIELD_NUMBER; + hash = (53 * hash) + getLocation().hashCode(); + hash = (37 * hash) + AGENT_FRAMEWORK_FIELD_NUMBER; + hash = (53 * hash) + agentFramework_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AgentResource parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.aiplatform.v1.AgentResource prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Defines the identity of an agent being monitored.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AgentResource} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.AgentResource) + com.google.cloud.aiplatform.v1.AgentResourceOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AgentResource_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AgentResource_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AgentResource.class, + com.google.cloud.aiplatform.v1.AgentResource.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.AgentResource.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + agentType_ = 0; + agent_ = ""; + location_ = ""; + agentFramework_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AgentResource_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.AgentResource.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource build() { + com.google.cloud.aiplatform.v1.AgentResource result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource buildPartial() { + com.google.cloud.aiplatform.v1.AgentResource result = + new com.google.cloud.aiplatform.v1.AgentResource(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.AgentResource result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.agentType_ = agentType_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.agent_ = agent_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.location_ = location_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.agentFramework_ = agentFramework_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.AgentResource) { + return mergeFrom((com.google.cloud.aiplatform.v1.AgentResource) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.AgentResource other) { + if (other == com.google.cloud.aiplatform.v1.AgentResource.getDefaultInstance()) return this; + if (other.agentType_ != 0) { + setAgentTypeValue(other.getAgentTypeValue()); + } + if (!other.getAgent().isEmpty()) { + agent_ = other.agent_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getLocation().isEmpty()) { + location_ = other.location_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.agentFramework_ != 0) { + setAgentFrameworkValue(other.getAgentFrameworkValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + agentType_ = input.readEnum(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 18: + { + agent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + location_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 32: + { + agentFramework_ = input.readEnum(); + bitField0_ |= 0x00000008; + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int agentType_ = 0; + + /** + * + * + *
+     * Required. The runtime type of the agent.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for agentType. + */ + @java.lang.Override + public int getAgentTypeValue() { + return agentType_; + } + + /** + * + * + *
+     * Required. The runtime type of the agent.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The enum numeric value on the wire for agentType to set. + * @return This builder for chaining. + */ + public Builder setAgentTypeValue(int value) { + agentType_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The runtime type of the agent.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentType. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource.AgentType getAgentType() { + com.google.cloud.aiplatform.v1.AgentResource.AgentType result = + com.google.cloud.aiplatform.v1.AgentResource.AgentType.forNumber(agentType_); + return result == null + ? com.google.cloud.aiplatform.v1.AgentResource.AgentType.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Required. The runtime type of the agent.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The agentType to set. + * @return This builder for chaining. + */ + public Builder setAgentType(com.google.cloud.aiplatform.v1.AgentResource.AgentType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + agentType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The runtime type of the agent.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearAgentType() { + bitField0_ = (bitField0_ & ~0x00000001); + agentType_ = 0; + onChanged(); + return this; + } + + private java.lang.Object agent_ = ""; + + /** + * + * + *
+     * Required. The resource name or identifier of the agent to monitor. The
+     * format depends on `agent_type`:
+     *
+     * * `REASONING_ENGINE`:
+     * `//aiplatform.googleapis.com/projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}`
+     * * `CLOUD_RUN_SERVICE`: the full resource name of the Cloud Run service,
+     * `//run.googleapis.com/projects/{project}/locations/{location}/services/{service}`
+     * * `GKE_WORKLOAD`: the full resource name of the Google Kubernetes Engine
+     * cluster followed by the agent's OpenTelemetry `service.name`,
+     * `//container.googleapis.com/projects/{project}/locations/{location}/clusters/{cluster}/{service}`.
+     * For a zonal cluster, `zones/{zone}` replaces `locations/{location}`.
+     * Some names end in
+     * `k8s/namespaces/{namespace}/apps/deployments/{deployment}` instead of
+     * `{service}`.
+     * * `GCE_INSTANCE`: the full resource name of the Compute Engine instance
+     * followed by the agent's OpenTelemetry `service.name`,
+     * `//compute.googleapis.com/projects/{project}/zones/{zone}/instances/{instance}/{service}`,
+     * where `{instance}` is the numeric instance ID.
+     * * `AWS` and `AZURE`: an identifier built from the agent's OpenTelemetry
+     * resource attributes, usually `{platform}:{account}:{region}:{name}`.
+     * `{platform}` is the `cloud.platform` value. `{account}` is
+     * `cloud.account.id`, or the ID of the Google Cloud project that receives
+     * the telemetry if `cloud.account.id` isn't set. `{region}` is
+     * `cloud.region`. `{name}` is `faas.name`, or the Kubernetes cluster name
+     * followed by `/k8s/namespaces/{namespace}/apps/deployments/{deployment}`
+     * or `/{service}`. For example,
+     * `aws_lambda:123456789012:us-east-2:inventory-agent`.
+     * * `AGENT_TYPE_OTHER`: a stable identifier for the agent, such as the full
+     * resource name of its runtime or its OpenTelemetry `service.name`.
+     * 
+ * + * + * string agent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The agent. + */ + public java.lang.String getAgent() { + java.lang.Object ref = agent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The resource name or identifier of the agent to monitor. The
+     * format depends on `agent_type`:
+     *
+     * * `REASONING_ENGINE`:
+     * `//aiplatform.googleapis.com/projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}`
+     * * `CLOUD_RUN_SERVICE`: the full resource name of the Cloud Run service,
+     * `//run.googleapis.com/projects/{project}/locations/{location}/services/{service}`
+     * * `GKE_WORKLOAD`: the full resource name of the Google Kubernetes Engine
+     * cluster followed by the agent's OpenTelemetry `service.name`,
+     * `//container.googleapis.com/projects/{project}/locations/{location}/clusters/{cluster}/{service}`.
+     * For a zonal cluster, `zones/{zone}` replaces `locations/{location}`.
+     * Some names end in
+     * `k8s/namespaces/{namespace}/apps/deployments/{deployment}` instead of
+     * `{service}`.
+     * * `GCE_INSTANCE`: the full resource name of the Compute Engine instance
+     * followed by the agent's OpenTelemetry `service.name`,
+     * `//compute.googleapis.com/projects/{project}/zones/{zone}/instances/{instance}/{service}`,
+     * where `{instance}` is the numeric instance ID.
+     * * `AWS` and `AZURE`: an identifier built from the agent's OpenTelemetry
+     * resource attributes, usually `{platform}:{account}:{region}:{name}`.
+     * `{platform}` is the `cloud.platform` value. `{account}` is
+     * `cloud.account.id`, or the ID of the Google Cloud project that receives
+     * the telemetry if `cloud.account.id` isn't set. `{region}` is
+     * `cloud.region`. `{name}` is `faas.name`, or the Kubernetes cluster name
+     * followed by `/k8s/namespaces/{namespace}/apps/deployments/{deployment}`
+     * or `/{service}`. For example,
+     * `aws_lambda:123456789012:us-east-2:inventory-agent`.
+     * * `AGENT_TYPE_OTHER`: a stable identifier for the agent, such as the full
+     * resource name of its runtime or its OpenTelemetry `service.name`.
+     * 
+ * + * + * string agent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for agent. + */ + public com.google.protobuf.ByteString getAgentBytes() { + java.lang.Object ref = agent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The resource name or identifier of the agent to monitor. The
+     * format depends on `agent_type`:
+     *
+     * * `REASONING_ENGINE`:
+     * `//aiplatform.googleapis.com/projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}`
+     * * `CLOUD_RUN_SERVICE`: the full resource name of the Cloud Run service,
+     * `//run.googleapis.com/projects/{project}/locations/{location}/services/{service}`
+     * * `GKE_WORKLOAD`: the full resource name of the Google Kubernetes Engine
+     * cluster followed by the agent's OpenTelemetry `service.name`,
+     * `//container.googleapis.com/projects/{project}/locations/{location}/clusters/{cluster}/{service}`.
+     * For a zonal cluster, `zones/{zone}` replaces `locations/{location}`.
+     * Some names end in
+     * `k8s/namespaces/{namespace}/apps/deployments/{deployment}` instead of
+     * `{service}`.
+     * * `GCE_INSTANCE`: the full resource name of the Compute Engine instance
+     * followed by the agent's OpenTelemetry `service.name`,
+     * `//compute.googleapis.com/projects/{project}/zones/{zone}/instances/{instance}/{service}`,
+     * where `{instance}` is the numeric instance ID.
+     * * `AWS` and `AZURE`: an identifier built from the agent's OpenTelemetry
+     * resource attributes, usually `{platform}:{account}:{region}:{name}`.
+     * `{platform}` is the `cloud.platform` value. `{account}` is
+     * `cloud.account.id`, or the ID of the Google Cloud project that receives
+     * the telemetry if `cloud.account.id` isn't set. `{region}` is
+     * `cloud.region`. `{name}` is `faas.name`, or the Kubernetes cluster name
+     * followed by `/k8s/namespaces/{namespace}/apps/deployments/{deployment}`
+     * or `/{service}`. For example,
+     * `aws_lambda:123456789012:us-east-2:inventory-agent`.
+     * * `AGENT_TYPE_OTHER`: a stable identifier for the agent, such as the full
+     * resource name of its runtime or its OpenTelemetry `service.name`.
+     * 
+ * + * + * string agent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The agent to set. + * @return This builder for chaining. + */ + public Builder setAgent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + agent_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The resource name or identifier of the agent to monitor. The
+     * format depends on `agent_type`:
+     *
+     * * `REASONING_ENGINE`:
+     * `//aiplatform.googleapis.com/projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}`
+     * * `CLOUD_RUN_SERVICE`: the full resource name of the Cloud Run service,
+     * `//run.googleapis.com/projects/{project}/locations/{location}/services/{service}`
+     * * `GKE_WORKLOAD`: the full resource name of the Google Kubernetes Engine
+     * cluster followed by the agent's OpenTelemetry `service.name`,
+     * `//container.googleapis.com/projects/{project}/locations/{location}/clusters/{cluster}/{service}`.
+     * For a zonal cluster, `zones/{zone}` replaces `locations/{location}`.
+     * Some names end in
+     * `k8s/namespaces/{namespace}/apps/deployments/{deployment}` instead of
+     * `{service}`.
+     * * `GCE_INSTANCE`: the full resource name of the Compute Engine instance
+     * followed by the agent's OpenTelemetry `service.name`,
+     * `//compute.googleapis.com/projects/{project}/zones/{zone}/instances/{instance}/{service}`,
+     * where `{instance}` is the numeric instance ID.
+     * * `AWS` and `AZURE`: an identifier built from the agent's OpenTelemetry
+     * resource attributes, usually `{platform}:{account}:{region}:{name}`.
+     * `{platform}` is the `cloud.platform` value. `{account}` is
+     * `cloud.account.id`, or the ID of the Google Cloud project that receives
+     * the telemetry if `cloud.account.id` isn't set. `{region}` is
+     * `cloud.region`. `{name}` is `faas.name`, or the Kubernetes cluster name
+     * followed by `/k8s/namespaces/{namespace}/apps/deployments/{deployment}`
+     * or `/{service}`. For example,
+     * `aws_lambda:123456789012:us-east-2:inventory-agent`.
+     * * `AGENT_TYPE_OTHER`: a stable identifier for the agent, such as the full
+     * resource name of its runtime or its OpenTelemetry `service.name`.
+     * 
+ * + * + * string agent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearAgent() { + agent_ = getDefaultInstance().getAgent(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The resource name or identifier of the agent to monitor. The
+     * format depends on `agent_type`:
+     *
+     * * `REASONING_ENGINE`:
+     * `//aiplatform.googleapis.com/projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}`
+     * * `CLOUD_RUN_SERVICE`: the full resource name of the Cloud Run service,
+     * `//run.googleapis.com/projects/{project}/locations/{location}/services/{service}`
+     * * `GKE_WORKLOAD`: the full resource name of the Google Kubernetes Engine
+     * cluster followed by the agent's OpenTelemetry `service.name`,
+     * `//container.googleapis.com/projects/{project}/locations/{location}/clusters/{cluster}/{service}`.
+     * For a zonal cluster, `zones/{zone}` replaces `locations/{location}`.
+     * Some names end in
+     * `k8s/namespaces/{namespace}/apps/deployments/{deployment}` instead of
+     * `{service}`.
+     * * `GCE_INSTANCE`: the full resource name of the Compute Engine instance
+     * followed by the agent's OpenTelemetry `service.name`,
+     * `//compute.googleapis.com/projects/{project}/zones/{zone}/instances/{instance}/{service}`,
+     * where `{instance}` is the numeric instance ID.
+     * * `AWS` and `AZURE`: an identifier built from the agent's OpenTelemetry
+     * resource attributes, usually `{platform}:{account}:{region}:{name}`.
+     * `{platform}` is the `cloud.platform` value. `{account}` is
+     * `cloud.account.id`, or the ID of the Google Cloud project that receives
+     * the telemetry if `cloud.account.id` isn't set. `{region}` is
+     * `cloud.region`. `{name}` is `faas.name`, or the Kubernetes cluster name
+     * followed by `/k8s/namespaces/{namespace}/apps/deployments/{deployment}`
+     * or `/{service}`. For example,
+     * `aws_lambda:123456789012:us-east-2:inventory-agent`.
+     * * `AGENT_TYPE_OTHER`: a stable identifier for the agent, such as the full
+     * resource name of its runtime or its OpenTelemetry `service.name`.
+     * 
+ * + * + * string agent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for agent to set. + * @return This builder for chaining. + */ + public Builder setAgentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + agent_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object location_ = ""; + + /** + * + * + *
+     * Output only. The region of the agent resource: a Google Cloud location
+     * (for example, `us-central1`), or for an `AWS` or `AZURE` agent, the region
+     * in that cloud (for example, `us-east-2`).
+     * 
+ * + * string location = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The location. + */ + public java.lang.String getLocation() { + java.lang.Object ref = location_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + location_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. The region of the agent resource: a Google Cloud location
+     * (for example, `us-central1`), or for an `AWS` or `AZURE` agent, the region
+     * in that cloud (for example, `us-east-2`).
+     * 
+ * + * string location = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for location. + */ + public com.google.protobuf.ByteString getLocationBytes() { + java.lang.Object ref = location_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + location_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. The region of the agent resource: a Google Cloud location
+     * (for example, `us-central1`), or for an `AWS` or `AZURE` agent, the region
+     * in that cloud (for example, `us-east-2`).
+     * 
+ * + * string location = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The location to set. + * @return This builder for chaining. + */ + public Builder setLocation(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + location_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The region of the agent resource: a Google Cloud location
+     * (for example, `us-central1`), or for an `AWS` or `AZURE` agent, the region
+     * in that cloud (for example, `us-east-2`).
+     * 
+ * + * string location = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearLocation() { + location_ = getDefaultInstance().getLocation(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The region of the agent resource: a Google Cloud location
+     * (for example, `us-central1`), or for an `AWS` or `AZURE` agent, the region
+     * in that cloud (for example, `us-east-2`).
+     * 
+ * + * string location = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for location to set. + * @return This builder for chaining. + */ + public Builder setLocationBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + location_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private int agentFramework_ = 0; + + /** + * + * + *
+     * Optional. The framework used to build the agent, orthogonal to the runtime
+     * `agent_type`.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentFramework agent_framework = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for agentFramework. + */ + @java.lang.Override + public int getAgentFrameworkValue() { + return agentFramework_; + } + + /** + * + * + *
+     * Optional. The framework used to build the agent, orthogonal to the runtime
+     * `agent_type`.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentFramework agent_framework = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for agentFramework to set. + * @return This builder for chaining. + */ + public Builder setAgentFrameworkValue(int value) { + agentFramework_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The framework used to build the agent, orthogonal to the runtime
+     * `agent_type`.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentFramework agent_framework = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The agentFramework. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource.AgentFramework getAgentFramework() { + com.google.cloud.aiplatform.v1.AgentResource.AgentFramework result = + com.google.cloud.aiplatform.v1.AgentResource.AgentFramework.forNumber(agentFramework_); + return result == null + ? com.google.cloud.aiplatform.v1.AgentResource.AgentFramework.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Optional. The framework used to build the agent, orthogonal to the runtime
+     * `agent_type`.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentFramework agent_framework = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The agentFramework to set. + * @return This builder for chaining. + */ + public Builder setAgentFramework( + com.google.cloud.aiplatform.v1.AgentResource.AgentFramework value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000008; + agentFramework_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The framework used to build the agent, orthogonal to the runtime
+     * `agent_type`.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentFramework agent_framework = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearAgentFramework() { + bitField0_ = (bitField0_ & ~0x00000008); + agentFramework_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.AgentResource) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.AgentResource) + private static final com.google.cloud.aiplatform.v1.AgentResource DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.AgentResource(); + } + + public static com.google.cloud.aiplatform.v1.AgentResource getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AgentResource parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentResourceOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentResourceOrBuilder.java new file mode 100644 index 000000000000..4fe3cdd46047 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AgentResourceOrBuilder.java @@ -0,0 +1,206 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface AgentResourceOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.AgentResource) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The runtime type of the agent.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for agentType. + */ + int getAgentTypeValue(); + + /** + * + * + *
+   * Required. The runtime type of the agent.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentType. + */ + com.google.cloud.aiplatform.v1.AgentResource.AgentType getAgentType(); + + /** + * + * + *
+   * Required. The resource name or identifier of the agent to monitor. The
+   * format depends on `agent_type`:
+   *
+   * * `REASONING_ENGINE`:
+   * `//aiplatform.googleapis.com/projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}`
+   * * `CLOUD_RUN_SERVICE`: the full resource name of the Cloud Run service,
+   * `//run.googleapis.com/projects/{project}/locations/{location}/services/{service}`
+   * * `GKE_WORKLOAD`: the full resource name of the Google Kubernetes Engine
+   * cluster followed by the agent's OpenTelemetry `service.name`,
+   * `//container.googleapis.com/projects/{project}/locations/{location}/clusters/{cluster}/{service}`.
+   * For a zonal cluster, `zones/{zone}` replaces `locations/{location}`.
+   * Some names end in
+   * `k8s/namespaces/{namespace}/apps/deployments/{deployment}` instead of
+   * `{service}`.
+   * * `GCE_INSTANCE`: the full resource name of the Compute Engine instance
+   * followed by the agent's OpenTelemetry `service.name`,
+   * `//compute.googleapis.com/projects/{project}/zones/{zone}/instances/{instance}/{service}`,
+   * where `{instance}` is the numeric instance ID.
+   * * `AWS` and `AZURE`: an identifier built from the agent's OpenTelemetry
+   * resource attributes, usually `{platform}:{account}:{region}:{name}`.
+   * `{platform}` is the `cloud.platform` value. `{account}` is
+   * `cloud.account.id`, or the ID of the Google Cloud project that receives
+   * the telemetry if `cloud.account.id` isn't set. `{region}` is
+   * `cloud.region`. `{name}` is `faas.name`, or the Kubernetes cluster name
+   * followed by `/k8s/namespaces/{namespace}/apps/deployments/{deployment}`
+   * or `/{service}`. For example,
+   * `aws_lambda:123456789012:us-east-2:inventory-agent`.
+   * * `AGENT_TYPE_OTHER`: a stable identifier for the agent, such as the full
+   * resource name of its runtime or its OpenTelemetry `service.name`.
+   * 
+ * + * + * string agent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The agent. + */ + java.lang.String getAgent(); + + /** + * + * + *
+   * Required. The resource name or identifier of the agent to monitor. The
+   * format depends on `agent_type`:
+   *
+   * * `REASONING_ENGINE`:
+   * `//aiplatform.googleapis.com/projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}`
+   * * `CLOUD_RUN_SERVICE`: the full resource name of the Cloud Run service,
+   * `//run.googleapis.com/projects/{project}/locations/{location}/services/{service}`
+   * * `GKE_WORKLOAD`: the full resource name of the Google Kubernetes Engine
+   * cluster followed by the agent's OpenTelemetry `service.name`,
+   * `//container.googleapis.com/projects/{project}/locations/{location}/clusters/{cluster}/{service}`.
+   * For a zonal cluster, `zones/{zone}` replaces `locations/{location}`.
+   * Some names end in
+   * `k8s/namespaces/{namespace}/apps/deployments/{deployment}` instead of
+   * `{service}`.
+   * * `GCE_INSTANCE`: the full resource name of the Compute Engine instance
+   * followed by the agent's OpenTelemetry `service.name`,
+   * `//compute.googleapis.com/projects/{project}/zones/{zone}/instances/{instance}/{service}`,
+   * where `{instance}` is the numeric instance ID.
+   * * `AWS` and `AZURE`: an identifier built from the agent's OpenTelemetry
+   * resource attributes, usually `{platform}:{account}:{region}:{name}`.
+   * `{platform}` is the `cloud.platform` value. `{account}` is
+   * `cloud.account.id`, or the ID of the Google Cloud project that receives
+   * the telemetry if `cloud.account.id` isn't set. `{region}` is
+   * `cloud.region`. `{name}` is `faas.name`, or the Kubernetes cluster name
+   * followed by `/k8s/namespaces/{namespace}/apps/deployments/{deployment}`
+   * or `/{service}`. For example,
+   * `aws_lambda:123456789012:us-east-2:inventory-agent`.
+   * * `AGENT_TYPE_OTHER`: a stable identifier for the agent, such as the full
+   * resource name of its runtime or its OpenTelemetry `service.name`.
+   * 
+ * + * + * string agent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for agent. + */ + com.google.protobuf.ByteString getAgentBytes(); + + /** + * + * + *
+   * Output only. The region of the agent resource: a Google Cloud location
+   * (for example, `us-central1`), or for an `AWS` or `AZURE` agent, the region
+   * in that cloud (for example, `us-east-2`).
+   * 
+ * + * string location = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The location. + */ + java.lang.String getLocation(); + + /** + * + * + *
+   * Output only. The region of the agent resource: a Google Cloud location
+   * (for example, `us-central1`), or for an `AWS` or `AZURE` agent, the region
+   * in that cloud (for example, `us-east-2`).
+   * 
+ * + * string location = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for location. + */ + com.google.protobuf.ByteString getLocationBytes(); + + /** + * + * + *
+   * Optional. The framework used to build the agent, orthogonal to the runtime
+   * `agent_type`.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentFramework agent_framework = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for agentFramework. + */ + int getAgentFrameworkValue(); + + /** + * + * + *
+   * Optional. The framework used to build the agent, orthogonal to the runtime
+   * `agent_type`.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentFramework agent_framework = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The agentFramework. + */ + com.google.cloud.aiplatform.v1.AgentResource.AgentFramework getAgentFramework(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsRequest.java new file mode 100644 index 000000000000..2309f5f55ec6 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsRequest.java @@ -0,0 +1,1211 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request to aggregate AnalyzedSessions across one or more MonitoredAgents.
+ * Use the `-` wildcard in the monitored_agent segment of the parent to
+ * aggregate across all MonitoredAgents in the location.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest} + */ +@com.google.protobuf.Generated +public final class AggregateAnalyzedSessionsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest) + AggregateAnalyzedSessionsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AggregateAnalyzedSessionsRequest"); + } + + // Use AggregateAnalyzedSessionsRequest.newBuilder() to construct. + private AggregateAnalyzedSessionsRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AggregateAnalyzedSessionsRequest() { + parent_ = ""; + filter_ = ""; + pageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest.class, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. The parent MonitoredAgent resource. Use the `-` wildcard
+   * for the monitored_agent segment to aggregate across multiple agents in the
+   * location.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The parent MonitoredAgent resource. Use the `-` wildcard
+   * for the monitored_agent segment to aggregate across multiple agents in the
+   * location.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object filter_ = ""; + + /** + * + * + *
+   * Optional. Filter expression restricting which AnalyzedSessions are included
+   * in the aggregation. Supports a subset of the
+   * `ListAnalyzedSessionsRequest.filter` grammar: a closed `detection_time`
+   * window with both bounds required. The `severity` clause is not supported
+   * here. If empty, the aggregation covers the last 3 days.
+   *
+   * Example:
+   *
+   * ```
+   * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+   * "2024-01-08T00:00:00Z"
+   * ```
+   * 
+ * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Filter expression restricting which AnalyzedSessions are included
+   * in the aggregation. Supports a subset of the
+   * `ListAnalyzedSessionsRequest.filter` grammar: a closed `detection_time`
+   * window with both bounds required. The `severity` clause is not supported
+   * here. If empty, the aggregation covers the last 3 days.
+   *
+   * Example:
+   *
+   * ```
+   * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+   * "2024-01-08T00:00:00Z"
+   * ```
+   * 
+ * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 3; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. The standard list page size. The maximum value is 100; values
+   * above 100 will be coerced to 100. If unspecified, at most 10
+   * MonitoredAgents will be returned.
+   * 
+ * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, filter_); + } + if (pageSize_ != 0) { + output.writeInt32(3, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, pageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, filter_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, pageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest other = + (com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request to aggregate AnalyzedSessions across one or more MonitoredAgents.
+   * Use the `-` wildcard in the monitored_agent segment of the parent to
+   * aggregate across all MonitoredAgents in the location.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest) + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest.class, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + filter_ = ""; + pageSize_ = 0; + pageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest build() { + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest buildPartial() { + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest result = + new com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.filter_ = filter_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.pageToken_ = pageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest) { + return mergeFrom((com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest other) { + if (other + == com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + filter_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 24: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000004; + break; + } // case 24 + case 34: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. The parent MonitoredAgent resource. Use the `-` wildcard
+     * for the monitored_agent segment to aggregate across multiple agents in the
+     * location.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The parent MonitoredAgent resource. Use the `-` wildcard
+     * for the monitored_agent segment to aggregate across multiple agents in the
+     * location.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The parent MonitoredAgent resource. Use the `-` wildcard
+     * for the monitored_agent segment to aggregate across multiple agents in the
+     * location.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The parent MonitoredAgent resource. Use the `-` wildcard
+     * for the monitored_agent segment to aggregate across multiple agents in the
+     * location.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The parent MonitoredAgent resource. Use the `-` wildcard
+     * for the monitored_agent segment to aggregate across multiple agents in the
+     * location.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + + /** + * + * + *
+     * Optional. Filter expression restricting which AnalyzedSessions are included
+     * in the aggregation. Supports a subset of the
+     * `ListAnalyzedSessionsRequest.filter` grammar: a closed `detection_time`
+     * window with both bounds required. The `severity` clause is not supported
+     * here. If empty, the aggregation covers the last 3 days.
+     *
+     * Example:
+     *
+     * ```
+     * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+     * "2024-01-08T00:00:00Z"
+     * ```
+     * 
+ * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Filter expression restricting which AnalyzedSessions are included
+     * in the aggregation. Supports a subset of the
+     * `ListAnalyzedSessionsRequest.filter` grammar: a closed `detection_time`
+     * window with both bounds required. The `severity` clause is not supported
+     * here. If empty, the aggregation covers the last 3 days.
+     *
+     * Example:
+     *
+     * ```
+     * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+     * "2024-01-08T00:00:00Z"
+     * ```
+     * 
+ * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Filter expression restricting which AnalyzedSessions are included
+     * in the aggregation. Supports a subset of the
+     * `ListAnalyzedSessionsRequest.filter` grammar: a closed `detection_time`
+     * window with both bounds required. The `severity` clause is not supported
+     * here. If empty, the aggregation covers the last 3 days.
+     *
+     * Example:
+     *
+     * ```
+     * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+     * "2024-01-08T00:00:00Z"
+     * ```
+     * 
+ * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + filter_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Filter expression restricting which AnalyzedSessions are included
+     * in the aggregation. Supports a subset of the
+     * `ListAnalyzedSessionsRequest.filter` grammar: a closed `detection_time`
+     * window with both bounds required. The `severity` clause is not supported
+     * here. If empty, the aggregation covers the last 3 days.
+     *
+     * Example:
+     *
+     * ```
+     * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+     * "2024-01-08T00:00:00Z"
+     * ```
+     * 
+ * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + filter_ = getDefaultInstance().getFilter(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Filter expression restricting which AnalyzedSessions are included
+     * in the aggregation. Supports a subset of the
+     * `ListAnalyzedSessionsRequest.filter` grammar: a closed `detection_time`
+     * window with both bounds required. The `severity` clause is not supported
+     * here. If empty, the aggregation covers the last 3 days.
+     *
+     * Example:
+     *
+     * ```
+     * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+     * "2024-01-08T00:00:00Z"
+     * ```
+     * 
+ * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. The standard list page size. The maximum value is 100; values
+     * above 100 will be coerced to 100. If unspecified, at most 10
+     * MonitoredAgents will be returned.
+     * 
+ * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. The standard list page size. The maximum value is 100; values
+     * above 100 will be coerced to 100. If unspecified, at most 10
+     * MonitoredAgents will be returned.
+     * 
+ * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The standard list page size. The maximum value is 100; values
+     * above 100 will be coerced to 100. If unspecified, at most 10
+     * MonitoredAgents will be returned.
+     * 
+ * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000004); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest) + private static final com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest(); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AggregateAnalyzedSessionsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsRequestOrBuilder.java new file mode 100644 index 000000000000..9dbccd9550a5 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsRequestOrBuilder.java @@ -0,0 +1,155 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface AggregateAnalyzedSessionsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The parent MonitoredAgent resource. Use the `-` wildcard
+   * for the monitored_agent segment to aggregate across multiple agents in the
+   * location.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. The parent MonitoredAgent resource. Use the `-` wildcard
+   * for the monitored_agent segment to aggregate across multiple agents in the
+   * location.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. Filter expression restricting which AnalyzedSessions are included
+   * in the aggregation. Supports a subset of the
+   * `ListAnalyzedSessionsRequest.filter` grammar: a closed `detection_time`
+   * window with both bounds required. The `severity` clause is not supported
+   * here. If empty, the aggregation covers the last 3 days.
+   *
+   * Example:
+   *
+   * ```
+   * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+   * "2024-01-08T00:00:00Z"
+   * ```
+   * 
+ * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
+   * Optional. Filter expression restricting which AnalyzedSessions are included
+   * in the aggregation. Supports a subset of the
+   * `ListAnalyzedSessionsRequest.filter` grammar: a closed `detection_time`
+   * window with both bounds required. The `severity` clause is not supported
+   * here. If empty, the aggregation covers the last 3 days.
+   *
+   * Example:
+   *
+   * ```
+   * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+   * "2024-01-08T00:00:00Z"
+   * ```
+   * 
+ * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
+   * Optional. The standard list page size. The maximum value is 100; values
+   * above 100 will be coerced to 100. If unspecified, at most 10
+   * MonitoredAgents will be returned.
+   * 
+ * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsResponse.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsResponse.java new file mode 100644 index 000000000000..8b016db2658a --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsResponse.java @@ -0,0 +1,4578 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Contains aggregated AnalyzedSession statistics, grouped by MonitoredAgent.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse} + */ +@com.google.protobuf.Generated +public final class AggregateAnalyzedSessionsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse) + AggregateAnalyzedSessionsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AggregateAnalyzedSessionsResponse"); + } + + // Use AggregateAnalyzedSessionsResponse.newBuilder() to construct. + private AggregateAnalyzedSessionsResponse( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AggregateAnalyzedSessionsResponse() { + agentAggregates_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.class, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.Builder.class); + } + + public interface AgentAggregateOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * The MonitoredAgent resource name.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * string monitored_agent = 1; + * + * @return The monitoredAgent. + */ + java.lang.String getMonitoredAgent(); + + /** + * + * + *
+     * The MonitoredAgent resource name.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * string monitored_agent = 1; + * + * @return The bytes for monitoredAgent. + */ + com.google.protobuf.ByteString getMonitoredAgentBytes(); + + /** + * + * + *
+     * The resource name or identifier of the agent. Matches
+     * `AgentResource.agent` on the corresponding `MonitoredAgent`, so the
+     * format depends on that agent's `AgentResource.agent_type`. For the
+     * format of each agent type, see
+     * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+     * 
+ * + * string agent_resource_name = 2 [(.google.api.resource_reference) = { ... } + * + * @return The agentResourceName. + */ + java.lang.String getAgentResourceName(); + + /** + * + * + *
+     * The resource name or identifier of the agent. Matches
+     * `AgentResource.agent` on the corresponding `MonitoredAgent`, so the
+     * format depends on that agent's `AgentResource.agent_type`. For the
+     * format of each agent type, see
+     * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+     * 
+ * + * string agent_resource_name = 2 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for agentResourceName. + */ + com.google.protobuf.ByteString getAgentResourceNameBytes(); + + /** + * + * + *
+     * Output only. The human-readable display name of the MonitoredAgent.
+     * 
+ * + * string agent_display_name = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The agentDisplayName. + */ + java.lang.String getAgentDisplayName(); + + /** + * + * + *
+     * Output only. The human-readable display name of the MonitoredAgent.
+     * 
+ * + * string agent_display_name = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for agentDisplayName. + */ + com.google.protobuf.ByteString getAgentDisplayNameBytes(); + + /** + * + * + *
+     * Output only. The enablement state of the MonitoredAgent (for example,
+     * ACTIVE, DISABLED, or ENABLING).
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_status = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentStatus. + */ + int getAgentStatusValue(); + + /** + * + * + *
+     * Output only. The enablement state of the MonitoredAgent (for example,
+     * ACTIVE, DISABLED, or ENABLING).
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_status = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentStatus. + */ + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState getAgentStatus(); + + /** + * + * + *
+     * Output only. The region of the agent, in the same form as
+     * `AgentResource.location` (for example, `us-central1`). Empty when the
+     * agent is not enrolled or its location is unknown.
+     * 
+ * + * string location = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The location. + */ + java.lang.String getLocation(); + + /** + * + * + *
+     * Output only. The region of the agent, in the same form as
+     * `AgentResource.location` (for example, `us-central1`). Empty when the
+     * agent is not enrolled or its location is unknown.
+     * 
+ * + * string location = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for location. + */ + com.google.protobuf.ByteString getLocationBytes(); + + /** + * + * + *
+     * Output only. The runtime the agent is hosted on (for example,
+     * `CLOUD_RUN_SERVICE`).
+     *
+     * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service,
+     * which is distinct from `AGENT_TYPE_OTHER` (known, and not one of the
+     * other enumerated runtimes).
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentType. + */ + int getAgentTypeValue(); + + /** + * + * + *
+     * Output only. The runtime the agent is hosted on (for example,
+     * `CLOUD_RUN_SERVICE`).
+     *
+     * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service,
+     * which is distinct from `AGENT_TYPE_OTHER` (known, and not one of the
+     * other enumerated runtimes).
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentType. + */ + com.google.cloud.aiplatform.v1.AgentResource.AgentType getAgentType(); + + /** + * + * + *
+     * The number of analyzed sessions for this agent matched by the request.
+     * 
+ * + * int32 total_sessions_count = 3; + * + * @return The totalSessionsCount. + */ + int getTotalSessionsCount(); + + /** + * + * + *
+     * The number of anomalous (SESSION_STATE_FLAGGED) sessions for this agent.
+     * 
+ * + * int32 anomalous_sessions_count = 4; + * + * @return The anomalousSessionsCount. + */ + int getAnomalousSessionsCount(); + + /** + * + * + *
+     * The latest session update_time observed for this agent.
+     * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + * + * @return Whether the latestSessionTime field is set. + */ + boolean hasLatestSessionTime(); + + /** + * + * + *
+     * The latest session update_time observed for this agent.
+     * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + * + * @return The latestSessionTime. + */ + com.google.protobuf.Timestamp getLatestSessionTime(); + + /** + * + * + *
+     * The latest session update_time observed for this agent.
+     * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + */ + com.google.protobuf.TimestampOrBuilder getLatestSessionTimeOrBuilder(); + + /** + * + * + *
+     * Map of severity level (string representation of Severity) to detector
+     * summaries aggregated across all sessions for this agent.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + int getSeveritiesCount(); + + /** + * + * + *
+     * Map of severity level (string representation of Severity) to detector
+     * summaries aggregated across all sessions for this agent.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + boolean containsSeverities(java.lang.String key); + + /** Use {@link #getSeveritiesMap()} instead. */ + @java.lang.Deprecated + java.util.Map + getSeverities(); + + /** + * + * + *
+     * Map of severity level (string representation of Severity) to detector
+     * summaries aggregated across all sessions for this agent.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + java.util.Map + getSeveritiesMap(); + + /** + * + * + *
+     * Map of severity level (string representation of Severity) to detector
+     * summaries aggregated across all sessions for this agent.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary defaultValue); + + /** + * + * + *
+     * Map of severity level (string representation of Severity) to detector
+     * summaries aggregated across all sessions for this agent.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrThrow( + java.lang.String key); + } + + /** + * + * + *
+   * Contains aggregated statistics for one MonitoredAgent.
+   * 
+ * + * Protobuf type {@code + * google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate} + */ + public static final class AgentAggregate extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate) + AgentAggregateOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AgentAggregate"); + } + + // Use AgentAggregate.newBuilder() to construct. + private AgentAggregate(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AgentAggregate() { + monitoredAgent_ = ""; + agentResourceName_ = ""; + agentDisplayName_ = ""; + agentStatus_ = 0; + location_ = ""; + agentType_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 6: + return internalGetSeverities(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate.class, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + .Builder.class); + } + + private int bitField0_; + public static final int MONITORED_AGENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object monitoredAgent_ = ""; + + /** + * + * + *
+     * The MonitoredAgent resource name.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * string monitored_agent = 1; + * + * @return The monitoredAgent. + */ + @java.lang.Override + public java.lang.String getMonitoredAgent() { + java.lang.Object ref = monitoredAgent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + monitoredAgent_ = s; + return s; + } + } + + /** + * + * + *
+     * The MonitoredAgent resource name.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * string monitored_agent = 1; + * + * @return The bytes for monitoredAgent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getMonitoredAgentBytes() { + java.lang.Object ref = monitoredAgent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + monitoredAgent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int AGENT_RESOURCE_NAME_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object agentResourceName_ = ""; + + /** + * + * + *
+     * The resource name or identifier of the agent. Matches
+     * `AgentResource.agent` on the corresponding `MonitoredAgent`, so the
+     * format depends on that agent's `AgentResource.agent_type`. For the
+     * format of each agent type, see
+     * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+     * 
+ * + * string agent_resource_name = 2 [(.google.api.resource_reference) = { ... } + * + * @return The agentResourceName. + */ + @java.lang.Override + public java.lang.String getAgentResourceName() { + java.lang.Object ref = agentResourceName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agentResourceName_ = s; + return s; + } + } + + /** + * + * + *
+     * The resource name or identifier of the agent. Matches
+     * `AgentResource.agent` on the corresponding `MonitoredAgent`, so the
+     * format depends on that agent's `AgentResource.agent_type`. For the
+     * format of each agent type, see
+     * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+     * 
+ * + * string agent_resource_name = 2 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for agentResourceName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAgentResourceNameBytes() { + java.lang.Object ref = agentResourceName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agentResourceName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int AGENT_DISPLAY_NAME_FIELD_NUMBER = 7; + + @SuppressWarnings("serial") + private volatile java.lang.Object agentDisplayName_ = ""; + + /** + * + * + *
+     * Output only. The human-readable display name of the MonitoredAgent.
+     * 
+ * + * string agent_display_name = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The agentDisplayName. + */ + @java.lang.Override + public java.lang.String getAgentDisplayName() { + java.lang.Object ref = agentDisplayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agentDisplayName_ = s; + return s; + } + } + + /** + * + * + *
+     * Output only. The human-readable display name of the MonitoredAgent.
+     * 
+ * + * string agent_display_name = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for agentDisplayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAgentDisplayNameBytes() { + java.lang.Object ref = agentDisplayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agentDisplayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int AGENT_STATUS_FIELD_NUMBER = 8; + private int agentStatus_ = 0; + + /** + * + * + *
+     * Output only. The enablement state of the MonitoredAgent (for example,
+     * ACTIVE, DISABLED, or ENABLING).
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_status = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentStatus. + */ + @java.lang.Override + public int getAgentStatusValue() { + return agentStatus_; + } + + /** + * + * + *
+     * Output only. The enablement state of the MonitoredAgent (for example,
+     * ACTIVE, DISABLED, or ENABLING).
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_status = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentStatus. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState getAgentStatus() { + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState result = + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.forNumber(agentStatus_); + return result == null + ? com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.UNRECOGNIZED + : result; + } + + public static final int LOCATION_FIELD_NUMBER = 9; + + @SuppressWarnings("serial") + private volatile java.lang.Object location_ = ""; + + /** + * + * + *
+     * Output only. The region of the agent, in the same form as
+     * `AgentResource.location` (for example, `us-central1`). Empty when the
+     * agent is not enrolled or its location is unknown.
+     * 
+ * + * string location = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The location. + */ + @java.lang.Override + public java.lang.String getLocation() { + java.lang.Object ref = location_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + location_ = s; + return s; + } + } + + /** + * + * + *
+     * Output only. The region of the agent, in the same form as
+     * `AgentResource.location` (for example, `us-central1`). Empty when the
+     * agent is not enrolled or its location is unknown.
+     * 
+ * + * string location = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for location. + */ + @java.lang.Override + public com.google.protobuf.ByteString getLocationBytes() { + java.lang.Object ref = location_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + location_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int AGENT_TYPE_FIELD_NUMBER = 10; + private int agentType_ = 0; + + /** + * + * + *
+     * Output only. The runtime the agent is hosted on (for example,
+     * `CLOUD_RUN_SERVICE`).
+     *
+     * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service,
+     * which is distinct from `AGENT_TYPE_OTHER` (known, and not one of the
+     * other enumerated runtimes).
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentType. + */ + @java.lang.Override + public int getAgentTypeValue() { + return agentType_; + } + + /** + * + * + *
+     * Output only. The runtime the agent is hosted on (for example,
+     * `CLOUD_RUN_SERVICE`).
+     *
+     * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service,
+     * which is distinct from `AGENT_TYPE_OTHER` (known, and not one of the
+     * other enumerated runtimes).
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentType. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource.AgentType getAgentType() { + com.google.cloud.aiplatform.v1.AgentResource.AgentType result = + com.google.cloud.aiplatform.v1.AgentResource.AgentType.forNumber(agentType_); + return result == null + ? com.google.cloud.aiplatform.v1.AgentResource.AgentType.UNRECOGNIZED + : result; + } + + public static final int TOTAL_SESSIONS_COUNT_FIELD_NUMBER = 3; + private int totalSessionsCount_ = 0; + + /** + * + * + *
+     * The number of analyzed sessions for this agent matched by the request.
+     * 
+ * + * int32 total_sessions_count = 3; + * + * @return The totalSessionsCount. + */ + @java.lang.Override + public int getTotalSessionsCount() { + return totalSessionsCount_; + } + + public static final int ANOMALOUS_SESSIONS_COUNT_FIELD_NUMBER = 4; + private int anomalousSessionsCount_ = 0; + + /** + * + * + *
+     * The number of anomalous (SESSION_STATE_FLAGGED) sessions for this agent.
+     * 
+ * + * int32 anomalous_sessions_count = 4; + * + * @return The anomalousSessionsCount. + */ + @java.lang.Override + public int getAnomalousSessionsCount() { + return anomalousSessionsCount_; + } + + public static final int LATEST_SESSION_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp latestSessionTime_; + + /** + * + * + *
+     * The latest session update_time observed for this agent.
+     * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + * + * @return Whether the latestSessionTime field is set. + */ + @java.lang.Override + public boolean hasLatestSessionTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+     * The latest session update_time observed for this agent.
+     * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + * + * @return The latestSessionTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLatestSessionTime() { + return latestSessionTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : latestSessionTime_; + } + + /** + * + * + *
+     * The latest session update_time observed for this agent.
+     * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLatestSessionTimeOrBuilder() { + return latestSessionTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : latestSessionTime_; + } + + public static final int SEVERITIES_FIELD_NUMBER = 6; + + private static final class SeveritiesDefaultEntryHolder { + static final com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + defaultEntry = + com.google.protobuf.MapEntry + . + newDefaultInstance( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_SeveritiesEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.MESSAGE, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + .getDefaultInstance()); + } + + @SuppressWarnings("serial") + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + severities_; + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + internalGetSeverities() { + if (severities_ == null) { + return com.google.protobuf.MapField.emptyMapField( + SeveritiesDefaultEntryHolder.defaultEntry); + } + return severities_; + } + + public int getSeveritiesCount() { + return internalGetSeverities().getMap().size(); + } + + /** + * + * + *
+     * Map of severity level (string representation of Severity) to detector
+     * summaries aggregated across all sessions for this agent.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + @java.lang.Override + public boolean containsSeverities(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetSeverities().getMap().containsKey(key); + } + + /** Use {@link #getSeveritiesMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeverities() { + return getSeveritiesMap(); + } + + /** + * + * + *
+     * Map of severity level (string representation of Severity) to detector
+     * summaries aggregated across all sessions for this agent.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + @java.lang.Override + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeveritiesMap() { + return internalGetSeverities().getMap(); + } + + /** + * + * + *
+     * Map of severity level (string representation of Severity) to detector
+     * summaries aggregated across all sessions for this agent.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + @java.lang.Override + public /* nullable */ com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + getSeveritiesOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + map = internalGetSeverities().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
+     * Map of severity level (string representation of Severity) to detector
+     * summaries aggregated across all sessions for this agent.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrThrow( + java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + map = internalGetSeverities().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(monitoredAgent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, monitoredAgent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agentResourceName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, agentResourceName_); + } + if (totalSessionsCount_ != 0) { + output.writeInt32(3, totalSessionsCount_); + } + if (anomalousSessionsCount_ != 0) { + output.writeInt32(4, anomalousSessionsCount_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getLatestSessionTime()); + } + com.google.protobuf.GeneratedMessage.serializeStringMapTo( + output, internalGetSeverities(), SeveritiesDefaultEntryHolder.defaultEntry, 6); + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agentDisplayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 7, agentDisplayName_); + } + if (agentStatus_ + != com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState + .ENABLEMENT_STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(8, agentStatus_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(location_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 9, location_); + } + if (agentType_ + != com.google.cloud.aiplatform.v1.AgentResource.AgentType.AGENT_TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(10, agentType_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(monitoredAgent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, monitoredAgent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agentResourceName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, agentResourceName_); + } + if (totalSessionsCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, totalSessionsCount_); + } + if (anomalousSessionsCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(4, anomalousSessionsCount_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getLatestSessionTime()); + } + for (java.util.Map.Entry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + entry : internalGetSeverities().getMap().entrySet()) { + com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + severities__ = + SeveritiesDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, severities__); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agentDisplayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(7, agentDisplayName_); + } + if (agentStatus_ + != com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState + .ENABLEMENT_STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(8, agentStatus_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(location_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(9, location_); + } + if (agentType_ + != com.google.cloud.aiplatform.v1.AgentResource.AgentType.AGENT_TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(10, agentType_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate other = + (com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate) obj; + + if (!getMonitoredAgent().equals(other.getMonitoredAgent())) return false; + if (!getAgentResourceName().equals(other.getAgentResourceName())) return false; + if (!getAgentDisplayName().equals(other.getAgentDisplayName())) return false; + if (agentStatus_ != other.agentStatus_) return false; + if (!getLocation().equals(other.getLocation())) return false; + if (agentType_ != other.agentType_) return false; + if (getTotalSessionsCount() != other.getTotalSessionsCount()) return false; + if (getAnomalousSessionsCount() != other.getAnomalousSessionsCount()) return false; + if (hasLatestSessionTime() != other.hasLatestSessionTime()) return false; + if (hasLatestSessionTime()) { + if (!getLatestSessionTime().equals(other.getLatestSessionTime())) return false; + } + if (!internalGetSeverities().equals(other.internalGetSeverities())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + MONITORED_AGENT_FIELD_NUMBER; + hash = (53 * hash) + getMonitoredAgent().hashCode(); + hash = (37 * hash) + AGENT_RESOURCE_NAME_FIELD_NUMBER; + hash = (53 * hash) + getAgentResourceName().hashCode(); + hash = (37 * hash) + AGENT_DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getAgentDisplayName().hashCode(); + hash = (37 * hash) + AGENT_STATUS_FIELD_NUMBER; + hash = (53 * hash) + agentStatus_; + hash = (37 * hash) + LOCATION_FIELD_NUMBER; + hash = (53 * hash) + getLocation().hashCode(); + hash = (37 * hash) + AGENT_TYPE_FIELD_NUMBER; + hash = (53 * hash) + agentType_; + hash = (37 * hash) + TOTAL_SESSIONS_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getTotalSessionsCount(); + hash = (37 * hash) + ANOMALOUS_SESSIONS_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getAnomalousSessionsCount(); + if (hasLatestSessionTime()) { + hash = (37 * hash) + LATEST_SESSION_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLatestSessionTime().hashCode(); + } + if (!internalGetSeverities().getMap().isEmpty()) { + hash = (37 * hash) + SEVERITIES_FIELD_NUMBER; + hash = (53 * hash) + internalGetSeverities().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+     * Contains aggregated statistics for one MonitoredAgent.
+     * 
+ * + * Protobuf type {@code + * google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate) + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregateOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 6: + return internalGetSeverities(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( + int number) { + switch (number) { + case 6: + return internalGetMutableSeverities(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + .class, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + .Builder.class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetLatestSessionTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + monitoredAgent_ = ""; + agentResourceName_ = ""; + agentDisplayName_ = ""; + agentStatus_ = 0; + location_ = ""; + agentType_ = 0; + totalSessionsCount_ = 0; + anomalousSessionsCount_ = 0; + latestSessionTime_ = null; + if (latestSessionTimeBuilder_ != null) { + latestSessionTimeBuilder_.dispose(); + latestSessionTimeBuilder_ = null; + } + internalGetMutableSeverities().clear(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_AgentAggregate_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + build() { + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + buildPartial() { + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate result = + new com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate( + this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.monitoredAgent_ = monitoredAgent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.agentResourceName_ = agentResourceName_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.agentDisplayName_ = agentDisplayName_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.agentStatus_ = agentStatus_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.location_ = location_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.agentType_ = agentType_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.totalSessionsCount_ = totalSessionsCount_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.anomalousSessionsCount_ = anomalousSessionsCount_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000100) != 0)) { + result.latestSessionTime_ = + latestSessionTimeBuilder_ == null + ? latestSessionTime_ + : latestSessionTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.severities_ = + internalGetSeverities().build(SeveritiesDefaultEntryHolder.defaultEntry); + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate) { + return mergeFrom( + (com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate other) { + if (other + == com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + .getDefaultInstance()) return this; + if (!other.getMonitoredAgent().isEmpty()) { + monitoredAgent_ = other.monitoredAgent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getAgentResourceName().isEmpty()) { + agentResourceName_ = other.agentResourceName_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getAgentDisplayName().isEmpty()) { + agentDisplayName_ = other.agentDisplayName_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.agentStatus_ != 0) { + setAgentStatusValue(other.getAgentStatusValue()); + } + if (!other.getLocation().isEmpty()) { + location_ = other.location_; + bitField0_ |= 0x00000010; + onChanged(); + } + if (other.agentType_ != 0) { + setAgentTypeValue(other.getAgentTypeValue()); + } + if (other.getTotalSessionsCount() != 0) { + setTotalSessionsCount(other.getTotalSessionsCount()); + } + if (other.getAnomalousSessionsCount() != 0) { + setAnomalousSessionsCount(other.getAnomalousSessionsCount()); + } + if (other.hasLatestSessionTime()) { + mergeLatestSessionTime(other.getLatestSessionTime()); + } + internalGetMutableSeverities().mergeFrom(other.internalGetSeverities()); + bitField0_ |= 0x00000200; + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + monitoredAgent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + agentResourceName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 24: + { + totalSessionsCount_ = input.readInt32(); + bitField0_ |= 0x00000040; + break; + } // case 24 + case 32: + { + anomalousSessionsCount_ = input.readInt32(); + bitField0_ |= 0x00000080; + break; + } // case 32 + case 42: + { + input.readMessage( + internalGetLatestSessionTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000100; + break; + } // case 42 + case 50: + { + com.google.protobuf.MapEntry< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + severities__ = + input.readMessage( + SeveritiesDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableSeverities() + .ensureBuilderMap() + .put(severities__.getKey(), severities__.getValue()); + bitField0_ |= 0x00000200; + break; + } // case 50 + case 58: + { + agentDisplayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 58 + case 64: + { + agentStatus_ = input.readEnum(); + bitField0_ |= 0x00000008; + break; + } // case 64 + case 74: + { + location_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 74 + case 80: + { + agentType_ = input.readEnum(); + bitField0_ |= 0x00000020; + break; + } // case 80 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object monitoredAgent_ = ""; + + /** + * + * + *
+       * The MonitoredAgent resource name.
+       * Format:
+       * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+       * 
+ * + * string monitored_agent = 1; + * + * @return The monitoredAgent. + */ + public java.lang.String getMonitoredAgent() { + java.lang.Object ref = monitoredAgent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + monitoredAgent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * The MonitoredAgent resource name.
+       * Format:
+       * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+       * 
+ * + * string monitored_agent = 1; + * + * @return The bytes for monitoredAgent. + */ + public com.google.protobuf.ByteString getMonitoredAgentBytes() { + java.lang.Object ref = monitoredAgent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + monitoredAgent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * The MonitoredAgent resource name.
+       * Format:
+       * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+       * 
+ * + * string monitored_agent = 1; + * + * @param value The monitoredAgent to set. + * @return This builder for chaining. + */ + public Builder setMonitoredAgent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + monitoredAgent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+       * The MonitoredAgent resource name.
+       * Format:
+       * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+       * 
+ * + * string monitored_agent = 1; + * + * @return This builder for chaining. + */ + public Builder clearMonitoredAgent() { + monitoredAgent_ = getDefaultInstance().getMonitoredAgent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+       * The MonitoredAgent resource name.
+       * Format:
+       * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+       * 
+ * + * string monitored_agent = 1; + * + * @param value The bytes for monitoredAgent to set. + * @return This builder for chaining. + */ + public Builder setMonitoredAgentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + monitoredAgent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object agentResourceName_ = ""; + + /** + * + * + *
+       * The resource name or identifier of the agent. Matches
+       * `AgentResource.agent` on the corresponding `MonitoredAgent`, so the
+       * format depends on that agent's `AgentResource.agent_type`. For the
+       * format of each agent type, see
+       * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+       * 
+ * + * string agent_resource_name = 2 [(.google.api.resource_reference) = { ... } + * + * @return The agentResourceName. + */ + public java.lang.String getAgentResourceName() { + java.lang.Object ref = agentResourceName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agentResourceName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * The resource name or identifier of the agent. Matches
+       * `AgentResource.agent` on the corresponding `MonitoredAgent`, so the
+       * format depends on that agent's `AgentResource.agent_type`. For the
+       * format of each agent type, see
+       * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+       * 
+ * + * string agent_resource_name = 2 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for agentResourceName. + */ + public com.google.protobuf.ByteString getAgentResourceNameBytes() { + java.lang.Object ref = agentResourceName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agentResourceName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * The resource name or identifier of the agent. Matches
+       * `AgentResource.agent` on the corresponding `MonitoredAgent`, so the
+       * format depends on that agent's `AgentResource.agent_type`. For the
+       * format of each agent type, see
+       * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+       * 
+ * + * string agent_resource_name = 2 [(.google.api.resource_reference) = { ... } + * + * @param value The agentResourceName to set. + * @return This builder for chaining. + */ + public Builder setAgentResourceName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + agentResourceName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+       * The resource name or identifier of the agent. Matches
+       * `AgentResource.agent` on the corresponding `MonitoredAgent`, so the
+       * format depends on that agent's `AgentResource.agent_type`. For the
+       * format of each agent type, see
+       * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+       * 
+ * + * string agent_resource_name = 2 [(.google.api.resource_reference) = { ... } + * + * @return This builder for chaining. + */ + public Builder clearAgentResourceName() { + agentResourceName_ = getDefaultInstance().getAgentResourceName(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+       * The resource name or identifier of the agent. Matches
+       * `AgentResource.agent` on the corresponding `MonitoredAgent`, so the
+       * format depends on that agent's `AgentResource.agent_type`. For the
+       * format of each agent type, see
+       * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+       * 
+ * + * string agent_resource_name = 2 [(.google.api.resource_reference) = { ... } + * + * @param value The bytes for agentResourceName to set. + * @return This builder for chaining. + */ + public Builder setAgentResourceNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + agentResourceName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object agentDisplayName_ = ""; + + /** + * + * + *
+       * Output only. The human-readable display name of the MonitoredAgent.
+       * 
+ * + * string agent_display_name = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The agentDisplayName. + */ + public java.lang.String getAgentDisplayName() { + java.lang.Object ref = agentDisplayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agentDisplayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * Output only. The human-readable display name of the MonitoredAgent.
+       * 
+ * + * string agent_display_name = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for agentDisplayName. + */ + public com.google.protobuf.ByteString getAgentDisplayNameBytes() { + java.lang.Object ref = agentDisplayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agentDisplayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * Output only. The human-readable display name of the MonitoredAgent.
+       * 
+ * + * string agent_display_name = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The agentDisplayName to set. + * @return This builder for chaining. + */ + public Builder setAgentDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + agentDisplayName_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The human-readable display name of the MonitoredAgent.
+       * 
+ * + * string agent_display_name = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearAgentDisplayName() { + agentDisplayName_ = getDefaultInstance().getAgentDisplayName(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The human-readable display name of the MonitoredAgent.
+       * 
+ * + * string agent_display_name = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for agentDisplayName to set. + * @return This builder for chaining. + */ + public Builder setAgentDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + agentDisplayName_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private int agentStatus_ = 0; + + /** + * + * + *
+       * Output only. The enablement state of the MonitoredAgent (for example,
+       * ACTIVE, DISABLED, or ENABLING).
+       * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_status = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentStatus. + */ + @java.lang.Override + public int getAgentStatusValue() { + return agentStatus_; + } + + /** + * + * + *
+       * Output only. The enablement state of the MonitoredAgent (for example,
+       * ACTIVE, DISABLED, or ENABLING).
+       * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_status = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for agentStatus to set. + * @return This builder for chaining. + */ + public Builder setAgentStatusValue(int value) { + agentStatus_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The enablement state of the MonitoredAgent (for example,
+       * ACTIVE, DISABLED, or ENABLING).
+       * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_status = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentStatus. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState getAgentStatus() { + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState result = + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.forNumber(agentStatus_); + return result == null + ? com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.UNRECOGNIZED + : result; + } + + /** + * + * + *
+       * Output only. The enablement state of the MonitoredAgent (for example,
+       * ACTIVE, DISABLED, or ENABLING).
+       * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_status = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The agentStatus to set. + * @return This builder for chaining. + */ + public Builder setAgentStatus( + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000008; + agentStatus_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The enablement state of the MonitoredAgent (for example,
+       * ACTIVE, DISABLED, or ENABLING).
+       * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_status = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearAgentStatus() { + bitField0_ = (bitField0_ & ~0x00000008); + agentStatus_ = 0; + onChanged(); + return this; + } + + private java.lang.Object location_ = ""; + + /** + * + * + *
+       * Output only. The region of the agent, in the same form as
+       * `AgentResource.location` (for example, `us-central1`). Empty when the
+       * agent is not enrolled or its location is unknown.
+       * 
+ * + * string location = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The location. + */ + public java.lang.String getLocation() { + java.lang.Object ref = location_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + location_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * Output only. The region of the agent, in the same form as
+       * `AgentResource.location` (for example, `us-central1`). Empty when the
+       * agent is not enrolled or its location is unknown.
+       * 
+ * + * string location = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for location. + */ + public com.google.protobuf.ByteString getLocationBytes() { + java.lang.Object ref = location_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + location_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * Output only. The region of the agent, in the same form as
+       * `AgentResource.location` (for example, `us-central1`). Empty when the
+       * agent is not enrolled or its location is unknown.
+       * 
+ * + * string location = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The location to set. + * @return This builder for chaining. + */ + public Builder setLocation(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + location_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The region of the agent, in the same form as
+       * `AgentResource.location` (for example, `us-central1`). Empty when the
+       * agent is not enrolled or its location is unknown.
+       * 
+ * + * string location = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearLocation() { + location_ = getDefaultInstance().getLocation(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The region of the agent, in the same form as
+       * `AgentResource.location` (for example, `us-central1`). Empty when the
+       * agent is not enrolled or its location is unknown.
+       * 
+ * + * string location = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for location to set. + * @return This builder for chaining. + */ + public Builder setLocationBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + location_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private int agentType_ = 0; + + /** + * + * + *
+       * Output only. The runtime the agent is hosted on (for example,
+       * `CLOUD_RUN_SERVICE`).
+       *
+       * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service,
+       * which is distinct from `AGENT_TYPE_OTHER` (known, and not one of the
+       * other enumerated runtimes).
+       * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentType. + */ + @java.lang.Override + public int getAgentTypeValue() { + return agentType_; + } + + /** + * + * + *
+       * Output only. The runtime the agent is hosted on (for example,
+       * `CLOUD_RUN_SERVICE`).
+       *
+       * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service,
+       * which is distinct from `AGENT_TYPE_OTHER` (known, and not one of the
+       * other enumerated runtimes).
+       * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for agentType to set. + * @return This builder for chaining. + */ + public Builder setAgentTypeValue(int value) { + agentType_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The runtime the agent is hosted on (for example,
+       * `CLOUD_RUN_SERVICE`).
+       *
+       * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service,
+       * which is distinct from `AGENT_TYPE_OTHER` (known, and not one of the
+       * other enumerated runtimes).
+       * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentType. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource.AgentType getAgentType() { + com.google.cloud.aiplatform.v1.AgentResource.AgentType result = + com.google.cloud.aiplatform.v1.AgentResource.AgentType.forNumber(agentType_); + return result == null + ? com.google.cloud.aiplatform.v1.AgentResource.AgentType.UNRECOGNIZED + : result; + } + + /** + * + * + *
+       * Output only. The runtime the agent is hosted on (for example,
+       * `CLOUD_RUN_SERVICE`).
+       *
+       * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service,
+       * which is distinct from `AGENT_TYPE_OTHER` (known, and not one of the
+       * other enumerated runtimes).
+       * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The agentType to set. + * @return This builder for chaining. + */ + public Builder setAgentType(com.google.cloud.aiplatform.v1.AgentResource.AgentType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000020; + agentType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The runtime the agent is hosted on (for example,
+       * `CLOUD_RUN_SERVICE`).
+       *
+       * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service,
+       * which is distinct from `AGENT_TYPE_OTHER` (known, and not one of the
+       * other enumerated runtimes).
+       * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearAgentType() { + bitField0_ = (bitField0_ & ~0x00000020); + agentType_ = 0; + onChanged(); + return this; + } + + private int totalSessionsCount_; + + /** + * + * + *
+       * The number of analyzed sessions for this agent matched by the request.
+       * 
+ * + * int32 total_sessions_count = 3; + * + * @return The totalSessionsCount. + */ + @java.lang.Override + public int getTotalSessionsCount() { + return totalSessionsCount_; + } + + /** + * + * + *
+       * The number of analyzed sessions for this agent matched by the request.
+       * 
+ * + * int32 total_sessions_count = 3; + * + * @param value The totalSessionsCount to set. + * @return This builder for chaining. + */ + public Builder setTotalSessionsCount(int value) { + + totalSessionsCount_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+       * The number of analyzed sessions for this agent matched by the request.
+       * 
+ * + * int32 total_sessions_count = 3; + * + * @return This builder for chaining. + */ + public Builder clearTotalSessionsCount() { + bitField0_ = (bitField0_ & ~0x00000040); + totalSessionsCount_ = 0; + onChanged(); + return this; + } + + private int anomalousSessionsCount_; + + /** + * + * + *
+       * The number of anomalous (SESSION_STATE_FLAGGED) sessions for this agent.
+       * 
+ * + * int32 anomalous_sessions_count = 4; + * + * @return The anomalousSessionsCount. + */ + @java.lang.Override + public int getAnomalousSessionsCount() { + return anomalousSessionsCount_; + } + + /** + * + * + *
+       * The number of anomalous (SESSION_STATE_FLAGGED) sessions for this agent.
+       * 
+ * + * int32 anomalous_sessions_count = 4; + * + * @param value The anomalousSessionsCount to set. + * @return This builder for chaining. + */ + public Builder setAnomalousSessionsCount(int value) { + + anomalousSessionsCount_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
+       * The number of anomalous (SESSION_STATE_FLAGGED) sessions for this agent.
+       * 
+ * + * int32 anomalous_sessions_count = 4; + * + * @return This builder for chaining. + */ + public Builder clearAnomalousSessionsCount() { + bitField0_ = (bitField0_ & ~0x00000080); + anomalousSessionsCount_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp latestSessionTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + latestSessionTimeBuilder_; + + /** + * + * + *
+       * The latest session update_time observed for this agent.
+       * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + * + * @return Whether the latestSessionTime field is set. + */ + public boolean hasLatestSessionTime() { + return ((bitField0_ & 0x00000100) != 0); + } + + /** + * + * + *
+       * The latest session update_time observed for this agent.
+       * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + * + * @return The latestSessionTime. + */ + public com.google.protobuf.Timestamp getLatestSessionTime() { + if (latestSessionTimeBuilder_ == null) { + return latestSessionTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : latestSessionTime_; + } else { + return latestSessionTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+       * The latest session update_time observed for this agent.
+       * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + */ + public Builder setLatestSessionTime(com.google.protobuf.Timestamp value) { + if (latestSessionTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + latestSessionTime_ = value; + } else { + latestSessionTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+       * The latest session update_time observed for this agent.
+       * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + */ + public Builder setLatestSessionTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (latestSessionTimeBuilder_ == null) { + latestSessionTime_ = builderForValue.build(); + } else { + latestSessionTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+       * The latest session update_time observed for this agent.
+       * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + */ + public Builder mergeLatestSessionTime(com.google.protobuf.Timestamp value) { + if (latestSessionTimeBuilder_ == null) { + if (((bitField0_ & 0x00000100) != 0) + && latestSessionTime_ != null + && latestSessionTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getLatestSessionTimeBuilder().mergeFrom(value); + } else { + latestSessionTime_ = value; + } + } else { + latestSessionTimeBuilder_.mergeFrom(value); + } + if (latestSessionTime_ != null) { + bitField0_ |= 0x00000100; + onChanged(); + } + return this; + } + + /** + * + * + *
+       * The latest session update_time observed for this agent.
+       * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + */ + public Builder clearLatestSessionTime() { + bitField0_ = (bitField0_ & ~0x00000100); + latestSessionTime_ = null; + if (latestSessionTimeBuilder_ != null) { + latestSessionTimeBuilder_.dispose(); + latestSessionTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+       * The latest session update_time observed for this agent.
+       * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + */ + public com.google.protobuf.Timestamp.Builder getLatestSessionTimeBuilder() { + bitField0_ |= 0x00000100; + onChanged(); + return internalGetLatestSessionTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+       * The latest session update_time observed for this agent.
+       * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + */ + public com.google.protobuf.TimestampOrBuilder getLatestSessionTimeOrBuilder() { + if (latestSessionTimeBuilder_ != null) { + return latestSessionTimeBuilder_.getMessageOrBuilder(); + } else { + return latestSessionTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : latestSessionTime_; + } + } + + /** + * + * + *
+       * The latest session update_time observed for this agent.
+       * 
+ * + * .google.protobuf.Timestamp latest_session_time = 5; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetLatestSessionTimeFieldBuilder() { + if (latestSessionTimeBuilder_ == null) { + latestSessionTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLatestSessionTime(), getParentForChildren(), isClean()); + latestSessionTime_ = null; + } + return latestSessionTimeBuilder_; + } + + private static final class SeveritiesConverter + implements com.google.protobuf.MapFieldBuilder.Converter< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> { + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary build( + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder val) { + if (val instanceof com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) { + return (com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) val; + } + return ((com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder) val) + .build(); + } + + @java.lang.Override + public com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + defaultEntry() { + return SeveritiesDefaultEntryHolder.defaultEntry; + } + } + ; + + private static final SeveritiesConverter severitiesConverter = new SeveritiesConverter(); + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder> + severities_; + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder> + internalGetSeverities() { + if (severities_ == null) { + return new com.google.protobuf.MapFieldBuilder<>(severitiesConverter); + } + return severities_; + } + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder> + internalGetMutableSeverities() { + if (severities_ == null) { + severities_ = new com.google.protobuf.MapFieldBuilder<>(severitiesConverter); + } + bitField0_ |= 0x00000200; + onChanged(); + return severities_; + } + + public int getSeveritiesCount() { + return internalGetSeverities().ensureBuilderMap().size(); + } + + /** + * + * + *
+       * Map of severity level (string representation of Severity) to detector
+       * summaries aggregated across all sessions for this agent.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + @java.lang.Override + public boolean containsSeverities(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetSeverities().ensureBuilderMap().containsKey(key); + } + + /** Use {@link #getSeveritiesMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeverities() { + return getSeveritiesMap(); + } + + /** + * + * + *
+       * Map of severity level (string representation of Severity) to detector
+       * summaries aggregated across all sessions for this agent.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + @java.lang.Override + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeveritiesMap() { + return internalGetSeverities().getImmutableMap(); + } + + /** + * + * + *
+       * Map of severity level (string representation of Severity) to detector
+       * summaries aggregated across all sessions for this agent.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + @java.lang.Override + public /* nullable */ com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + getSeveritiesOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder> + map = internalGetMutableSeverities().ensureBuilderMap(); + return map.containsKey(key) ? severitiesConverter.build(map.get(key)) : defaultValue; + } + + /** + * + * + *
+       * Map of severity level (string representation of Severity) to detector
+       * summaries aggregated across all sessions for this agent.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrThrow( + java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder> + map = internalGetMutableSeverities().ensureBuilderMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return severitiesConverter.build(map.get(key)); + } + + public Builder clearSeverities() { + bitField0_ = (bitField0_ & ~0x00000200); + internalGetMutableSeverities().clear(); + return this; + } + + /** + * + * + *
+       * Map of severity level (string representation of Severity) to detector
+       * summaries aggregated across all sessions for this agent.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + public Builder removeSeverities(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableSeverities().ensureBuilderMap().remove(key); + return this; + } + + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getMutableSeverities() { + bitField0_ |= 0x00000200; + return internalGetMutableSeverities().ensureMessageMap(); + } + + /** + * + * + *
+       * Map of severity level (string representation of Severity) to detector
+       * summaries aggregated across all sessions for this agent.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + public Builder putSeverities( + java.lang.String key, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + internalGetMutableSeverities().ensureBuilderMap().put(key, value); + bitField0_ |= 0x00000200; + return this; + } + + /** + * + * + *
+       * Map of severity level (string representation of Severity) to detector
+       * summaries aggregated across all sessions for this agent.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + public Builder putAllSeverities( + java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + values) { + for (java.util.Map.Entry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + e : values.entrySet()) { + if (e.getKey() == null || e.getValue() == null) { + throw new NullPointerException(); + } + } + internalGetMutableSeverities().ensureBuilderMap().putAll(values); + bitField0_ |= 0x00000200; + return this; + } + + /** + * + * + *
+       * Map of severity level (string representation of Severity) to detector
+       * summaries aggregated across all sessions for this agent.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 6; + * + */ + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder + putSeveritiesBuilderIfAbsent(java.lang.String key) { + java.util.Map< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder> + builderMap = internalGetMutableSeverities().ensureBuilderMap(); + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder entry = + builderMap.get(key); + if (entry == null) { + entry = com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.newBuilder(); + builderMap.put(key, entry); + } + if (entry instanceof com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) { + entry = + ((com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) entry).toBuilder(); + builderMap.put(key, entry); + } + return (com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder) entry; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate) + private static final com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + .AgentAggregate + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate(); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AgentAggregate parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int AGENT_AGGREGATES_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate> + agentAggregates_; + + /** + * + * + *
+   * Aggregated statistics — exactly one entry per unique MonitoredAgent
+   * matched by the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + @java.lang.Override + public java.util.List< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate> + getAgentAggregatesList() { + return agentAggregates_; + } + + /** + * + * + *
+   * Aggregated statistics — exactly one entry per unique MonitoredAgent
+   * matched by the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + .AgentAggregateOrBuilder> + getAgentAggregatesOrBuilderList() { + return agentAggregates_; + } + + /** + * + * + *
+   * Aggregated statistics — exactly one entry per unique MonitoredAgent
+   * matched by the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + @java.lang.Override + public int getAgentAggregatesCount() { + return agentAggregates_.size(); + } + + /** + * + * + *
+   * Aggregated statistics — exactly one entry per unique MonitoredAgent
+   * matched by the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + getAgentAggregates(int index) { + return agentAggregates_.get(index); + } + + /** + * + * + *
+   * Aggregated statistics — exactly one entry per unique MonitoredAgent
+   * matched by the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregateOrBuilder + getAgentAggregatesOrBuilder(int index) { + return agentAggregates_.get(index); + } + + public static final int SUMMARY_FIELD_NUMBER = 2; + private com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary_; + + /** + * + * + *
+   * Overall summary across every MonitoredAgent included in the response.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + * @return Whether the summary field is set. + */ + @java.lang.Override + public boolean hasSummary() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Overall summary across every MonitoredAgent included in the response.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + * @return The summary. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary getSummary() { + return summary_ == null + ? com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance() + : summary_; + } + + /** + * + * + *
+   * Overall summary across every MonitoredAgent included in the response.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder + getSummaryOrBuilder() { + return summary_ == null + ? com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance() + : summary_; + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 3; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 3; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < agentAggregates_.size(); i++) { + output.writeMessage(1, agentAggregates_.get(i)); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getSummary()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < agentAggregates_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, agentAggregates_.get(i)); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getSummary()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse other = + (com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse) obj; + + if (!getAgentAggregatesList().equals(other.getAgentAggregatesList())) return false; + if (hasSummary() != other.hasSummary()) return false; + if (hasSummary()) { + if (!getSummary().equals(other.getSummary())) return false; + } + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getAgentAggregatesCount() > 0) { + hash = (37 * hash) + AGENT_AGGREGATES_FIELD_NUMBER; + hash = (53 * hash) + getAgentAggregatesList().hashCode(); + } + if (hasSummary()) { + hash = (37 * hash) + SUMMARY_FIELD_NUMBER; + hash = (53 * hash) + getSummary().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Contains aggregated AnalyzedSession statistics, grouped by MonitoredAgent.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse) + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.class, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetAgentAggregatesFieldBuilder(); + internalGetSummaryFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (agentAggregatesBuilder_ == null) { + agentAggregates_ = java.util.Collections.emptyList(); + } else { + agentAggregates_ = null; + agentAggregatesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + summary_ = null; + if (summaryBuilder_ != null) { + summaryBuilder_.dispose(); + summaryBuilder_ = null; + } + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AggregateAnalyzedSessionsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse build() { + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse buildPartial() { + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse result = + new com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse result) { + if (agentAggregatesBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + agentAggregates_ = java.util.Collections.unmodifiableList(agentAggregates_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.agentAggregates_ = agentAggregates_; + } else { + result.agentAggregates_ = agentAggregatesBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.summary_ = summaryBuilder_ == null ? summary_ : summaryBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse) { + return mergeFrom((com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse other) { + if (other + == com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.getDefaultInstance()) + return this; + if (agentAggregatesBuilder_ == null) { + if (!other.agentAggregates_.isEmpty()) { + if (agentAggregates_.isEmpty()) { + agentAggregates_ = other.agentAggregates_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureAgentAggregatesIsMutable(); + agentAggregates_.addAll(other.agentAggregates_); + } + onChanged(); + } + } else { + if (!other.agentAggregates_.isEmpty()) { + if (agentAggregatesBuilder_.isEmpty()) { + agentAggregatesBuilder_.dispose(); + agentAggregatesBuilder_ = null; + agentAggregates_ = other.agentAggregates_; + bitField0_ = (bitField0_ & ~0x00000001); + agentAggregatesBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetAgentAggregatesFieldBuilder() + : null; + } else { + agentAggregatesBuilder_.addAllMessages(other.agentAggregates_); + } + } + } + if (other.hasSummary()) { + mergeSummary(other.getSummary()); + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate m = + input.readMessage( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + .AgentAggregate.parser(), + extensionRegistry); + if (agentAggregatesBuilder_ == null) { + ensureAgentAggregatesIsMutable(); + agentAggregates_.add(m); + } else { + agentAggregatesBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + input.readMessage(internalGetSummaryFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate> + agentAggregates_ = java.util.Collections.emptyList(); + + private void ensureAgentAggregatesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + agentAggregates_ = + new java.util.ArrayList< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate>( + agentAggregates_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate.Builder, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + .AgentAggregateOrBuilder> + agentAggregatesBuilder_; + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public java.util.List< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate> + getAgentAggregatesList() { + if (agentAggregatesBuilder_ == null) { + return java.util.Collections.unmodifiableList(agentAggregates_); + } else { + return agentAggregatesBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public int getAgentAggregatesCount() { + if (agentAggregatesBuilder_ == null) { + return agentAggregates_.size(); + } else { + return agentAggregatesBuilder_.getCount(); + } + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + getAgentAggregates(int index) { + if (agentAggregatesBuilder_ == null) { + return agentAggregates_.get(index); + } else { + return agentAggregatesBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public Builder setAgentAggregates( + int index, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate value) { + if (agentAggregatesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAgentAggregatesIsMutable(); + agentAggregates_.set(index, value); + onChanged(); + } else { + agentAggregatesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public Builder setAgentAggregates( + int index, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate.Builder + builderForValue) { + if (agentAggregatesBuilder_ == null) { + ensureAgentAggregatesIsMutable(); + agentAggregates_.set(index, builderForValue.build()); + onChanged(); + } else { + agentAggregatesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public Builder addAgentAggregates( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate value) { + if (agentAggregatesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAgentAggregatesIsMutable(); + agentAggregates_.add(value); + onChanged(); + } else { + agentAggregatesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public Builder addAgentAggregates( + int index, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate value) { + if (agentAggregatesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAgentAggregatesIsMutable(); + agentAggregates_.add(index, value); + onChanged(); + } else { + agentAggregatesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public Builder addAgentAggregates( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate.Builder + builderForValue) { + if (agentAggregatesBuilder_ == null) { + ensureAgentAggregatesIsMutable(); + agentAggregates_.add(builderForValue.build()); + onChanged(); + } else { + agentAggregatesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public Builder addAgentAggregates( + int index, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate.Builder + builderForValue) { + if (agentAggregatesBuilder_ == null) { + ensureAgentAggregatesIsMutable(); + agentAggregates_.add(index, builderForValue.build()); + onChanged(); + } else { + agentAggregatesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public Builder addAllAgentAggregates( + java.lang.Iterable< + ? extends + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate> + values) { + if (agentAggregatesBuilder_ == null) { + ensureAgentAggregatesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, agentAggregates_); + onChanged(); + } else { + agentAggregatesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public Builder clearAgentAggregates() { + if (agentAggregatesBuilder_ == null) { + agentAggregates_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + agentAggregatesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public Builder removeAgentAggregates(int index) { + if (agentAggregatesBuilder_ == null) { + ensureAgentAggregatesIsMutable(); + agentAggregates_.remove(index); + onChanged(); + } else { + agentAggregatesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate.Builder + getAgentAggregatesBuilder(int index) { + return internalGetAgentAggregatesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregateOrBuilder + getAgentAggregatesOrBuilder(int index) { + if (agentAggregatesBuilder_ == null) { + return agentAggregates_.get(index); + } else { + return agentAggregatesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public java.util.List< + ? extends + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + .AgentAggregateOrBuilder> + getAgentAggregatesOrBuilderList() { + if (agentAggregatesBuilder_ != null) { + return agentAggregatesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(agentAggregates_); + } + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate.Builder + addAgentAggregatesBuilder() { + return internalGetAgentAggregatesFieldBuilder() + .addBuilder( + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + .getDefaultInstance()); + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate.Builder + addAgentAggregatesBuilder(int index) { + return internalGetAgentAggregatesFieldBuilder() + .addBuilder( + index, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + .getDefaultInstance()); + } + + /** + * + * + *
+     * Aggregated statistics — exactly one entry per unique MonitoredAgent
+     * matched by the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + public java.util.List< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate.Builder> + getAgentAggregatesBuilderList() { + return internalGetAgentAggregatesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate.Builder, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + .AgentAggregateOrBuilder> + internalGetAgentAggregatesFieldBuilder() { + if (agentAggregatesBuilder_ == null) { + agentAggregatesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + .Builder, + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + .AgentAggregateOrBuilder>( + agentAggregates_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + agentAggregates_ = null; + } + return agentAggregatesBuilder_; + } + + private com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder> + summaryBuilder_; + + /** + * + * + *
+     * Overall summary across every MonitoredAgent included in the response.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + * + * @return Whether the summary field is set. + */ + public boolean hasSummary() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * Overall summary across every MonitoredAgent included in the response.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + * + * @return The summary. + */ + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary getSummary() { + if (summaryBuilder_ == null) { + return summary_ == null + ? com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance() + : summary_; + } else { + return summaryBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Overall summary across every MonitoredAgent included in the response.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + */ + public Builder setSummary( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary value) { + if (summaryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + summary_ = value; + } else { + summaryBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Overall summary across every MonitoredAgent included in the response.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + */ + public Builder setSummary( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder + builderForValue) { + if (summaryBuilder_ == null) { + summary_ = builderForValue.build(); + } else { + summaryBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Overall summary across every MonitoredAgent included in the response.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + */ + public Builder mergeSummary( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary value) { + if (summaryBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && summary_ != null + && summary_ + != com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance()) { + getSummaryBuilder().mergeFrom(value); + } else { + summary_ = value; + } + } else { + summaryBuilder_.mergeFrom(value); + } + if (summary_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Overall summary across every MonitoredAgent included in the response.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + */ + public Builder clearSummary() { + bitField0_ = (bitField0_ & ~0x00000002); + summary_ = null; + if (summaryBuilder_ != null) { + summaryBuilder_.dispose(); + summaryBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Overall summary across every MonitoredAgent included in the response.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + */ + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder + getSummaryBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetSummaryFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Overall summary across every MonitoredAgent included in the response.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + */ + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder + getSummaryOrBuilder() { + if (summaryBuilder_ != null) { + return summaryBuilder_.getMessageOrBuilder(); + } else { + return summary_ == null + ? com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance() + : summary_; + } + } + + /** + * + * + *
+     * Overall summary across every MonitoredAgent included in the response.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder> + internalGetSummaryFieldBuilder() { + if (summaryBuilder_ == null) { + summaryBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder>( + getSummary(), getParentForChildren(), isClean()); + summary_ = null; + } + return summaryBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 3; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 3; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 3; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 3; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 3; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse) + private static final com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse(); + } + + public static com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AggregateAnalyzedSessionsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsResponseOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsResponseOrBuilder.java new file mode 100644 index 000000000000..e8df1d9fcc76 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AggregateAnalyzedSessionsResponseOrBuilder.java @@ -0,0 +1,171 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface AggregateAnalyzedSessionsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Aggregated statistics — exactly one entry per unique MonitoredAgent
+   * matched by the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + java.util.List + getAgentAggregatesList(); + + /** + * + * + *
+   * Aggregated statistics — exactly one entry per unique MonitoredAgent
+   * matched by the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate + getAgentAggregates(int index); + + /** + * + * + *
+   * Aggregated statistics — exactly one entry per unique MonitoredAgent
+   * matched by the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + int getAgentAggregatesCount(); + + /** + * + * + *
+   * Aggregated statistics — exactly one entry per unique MonitoredAgent
+   * matched by the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + java.util.List< + ? extends + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse + .AgentAggregateOrBuilder> + getAgentAggregatesOrBuilderList(); + + /** + * + * + *
+   * Aggregated statistics — exactly one entry per unique MonitoredAgent
+   * matched by the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregate agent_aggregates = 1; + * + */ + com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse.AgentAggregateOrBuilder + getAgentAggregatesOrBuilder(int index); + + /** + * + * + *
+   * Overall summary across every MonitoredAgent included in the response.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + * @return Whether the summary field is set. + */ + boolean hasSummary(); + + /** + * + * + *
+   * Overall summary across every MonitoredAgent included in the response.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + * + * @return The summary. + */ + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary getSummary(); + + /** + * + * + *
+   * Overall summary across every MonitoredAgent included in the response.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 2; + */ + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder + getSummaryOrBuilder(); + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 3; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 3; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedInvocation.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedInvocation.java new file mode 100644 index 000000000000..2da6844fa545 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedInvocation.java @@ -0,0 +1,1457 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Represents an analyzed invocation for a monitored agent's session.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AnalyzedInvocation} + */ +@com.google.protobuf.Generated +public final class AnalyzedInvocation extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.AnalyzedInvocation) + AnalyzedInvocationOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AnalyzedInvocation"); + } + + // Use AnalyzedInvocation.newBuilder() to construct. + private AnalyzedInvocation(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AnalyzedInvocation() { + name_ = ""; + invocationId_ = ""; + invocationState_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedInvocation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedInvocation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AnalyzedInvocation.class, + com.google.cloud.aiplatform.v1.AnalyzedInvocation.Builder.class); + } + + /** + * + * + *
+   * State of the invocation.
+   * 
+ * + * Protobuf enum {@code google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState} + */ + public enum InvocationState implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unspecified state.
+     * 
+ * + * INVOCATION_STATE_UNSPECIFIED = 0; + */ + INVOCATION_STATE_UNSPECIFIED(0), + /** + * + * + *
+     * The invocation is anomalous.
+     * 
+ * + * INVOCATION_STATE_ANOMALOUS = 1; + */ + INVOCATION_STATE_ANOMALOUS(1), + /** + * + * + *
+     * The invocation is not anomalous.
+     * 
+ * + * INVOCATION_STATE_NOT_ANOMALOUS = 2; + */ + INVOCATION_STATE_NOT_ANOMALOUS(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "InvocationState"); + } + + /** + * + * + *
+     * Unspecified state.
+     * 
+ * + * INVOCATION_STATE_UNSPECIFIED = 0; + */ + public static final int INVOCATION_STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The invocation is anomalous.
+     * 
+ * + * INVOCATION_STATE_ANOMALOUS = 1; + */ + public static final int INVOCATION_STATE_ANOMALOUS_VALUE = 1; + + /** + * + * + *
+     * The invocation is not anomalous.
+     * 
+ * + * INVOCATION_STATE_NOT_ANOMALOUS = 2; + */ + public static final int INVOCATION_STATE_NOT_ANOMALOUS_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static InvocationState valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static InvocationState forNumber(int value) { + switch (value) { + case 0: + return INVOCATION_STATE_UNSPECIFIED; + case 1: + return INVOCATION_STATE_ANOMALOUS; + case 2: + return INVOCATION_STATE_NOT_ANOMALOUS; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public InvocationState findValueByNumber(int number) { + return InvocationState.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AnalyzedInvocation.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final InvocationState[] VALUES = values(); + + public static InvocationState valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private InvocationState(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState) + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Identifier. The resource name of the AnalyzedInvocation.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Identifier. The resource name of the AnalyzedInvocation.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int INVOCATION_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object invocationId_ = ""; + + /** + * + * + *
+   * Output only. The invocation ID.
+   * 
+ * + * string invocation_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The invocationId. + */ + @java.lang.Override + public java.lang.String getInvocationId() { + java.lang.Object ref = invocationId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + invocationId_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. The invocation ID.
+   * 
+ * + * string invocation_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for invocationId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getInvocationIdBytes() { + java.lang.Object ref = invocationId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + invocationId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ASSESSMENT_FIELD_NUMBER = 3; + private com.google.cloud.aiplatform.v1.Assessment assessment_; + + /** + * + * + *
+   * Output only. The assessment of the invocation.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the assessment field is set. + */ + @java.lang.Override + public boolean hasAssessment() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Output only. The assessment of the invocation.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The assessment. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment getAssessment() { + return assessment_ == null + ? com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance() + : assessment_; + } + + /** + * + * + *
+   * Output only. The assessment of the invocation.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AssessmentOrBuilder getAssessmentOrBuilder() { + return assessment_ == null + ? com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance() + : assessment_; + } + + public static final int INVOCATION_STATE_FIELD_NUMBER = 4; + private int invocationState_ = 0; + + /** + * + * + *
+   * Output only. The state of the invocation.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState invocation_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for invocationState. + */ + @java.lang.Override + public int getInvocationStateValue() { + return invocationState_; + } + + /** + * + * + *
+   * Output only. The state of the invocation.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState invocation_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The invocationState. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState getInvocationState() { + com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState result = + com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState.forNumber( + invocationState_); + return result == null + ? com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(invocationId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, invocationId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getAssessment()); + } + if (invocationState_ + != com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState + .INVOCATION_STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(4, invocationState_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(invocationId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, invocationId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getAssessment()); + } + if (invocationState_ + != com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState + .INVOCATION_STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, invocationState_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.AnalyzedInvocation)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.AnalyzedInvocation other = + (com.google.cloud.aiplatform.v1.AnalyzedInvocation) obj; + + if (!getName().equals(other.getName())) return false; + if (!getInvocationId().equals(other.getInvocationId())) return false; + if (hasAssessment() != other.hasAssessment()) return false; + if (hasAssessment()) { + if (!getAssessment().equals(other.getAssessment())) return false; + } + if (invocationState_ != other.invocationState_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + INVOCATION_ID_FIELD_NUMBER; + hash = (53 * hash) + getInvocationId().hashCode(); + if (hasAssessment()) { + hash = (37 * hash) + ASSESSMENT_FIELD_NUMBER; + hash = (53 * hash) + getAssessment().hashCode(); + } + hash = (37 * hash) + INVOCATION_STATE_FIELD_NUMBER; + hash = (53 * hash) + invocationState_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.aiplatform.v1.AnalyzedInvocation prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Represents an analyzed invocation for a monitored agent's session.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AnalyzedInvocation} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.AnalyzedInvocation) + com.google.cloud.aiplatform.v1.AnalyzedInvocationOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedInvocation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedInvocation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AnalyzedInvocation.class, + com.google.cloud.aiplatform.v1.AnalyzedInvocation.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.AnalyzedInvocation.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetAssessmentFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + invocationId_ = ""; + assessment_ = null; + if (assessmentBuilder_ != null) { + assessmentBuilder_.dispose(); + assessmentBuilder_ = null; + } + invocationState_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedInvocation_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedInvocation getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.AnalyzedInvocation.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedInvocation build() { + com.google.cloud.aiplatform.v1.AnalyzedInvocation result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedInvocation buildPartial() { + com.google.cloud.aiplatform.v1.AnalyzedInvocation result = + new com.google.cloud.aiplatform.v1.AnalyzedInvocation(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.AnalyzedInvocation result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.invocationId_ = invocationId_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.assessment_ = assessmentBuilder_ == null ? assessment_ : assessmentBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.invocationState_ = invocationState_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.AnalyzedInvocation) { + return mergeFrom((com.google.cloud.aiplatform.v1.AnalyzedInvocation) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.AnalyzedInvocation other) { + if (other == com.google.cloud.aiplatform.v1.AnalyzedInvocation.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getInvocationId().isEmpty()) { + invocationId_ = other.invocationId_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasAssessment()) { + mergeAssessment(other.getAssessment()); + } + if (other.invocationState_ != 0) { + setInvocationStateValue(other.getInvocationStateValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + invocationId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetAssessmentFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 32: + { + invocationState_ = input.readEnum(); + bitField0_ |= 0x00000008; + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Identifier. The resource name of the AnalyzedInvocation.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Identifier. The resource name of the AnalyzedInvocation.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Identifier. The resource name of the AnalyzedInvocation.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. The resource name of the AnalyzedInvocation.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. The resource name of the AnalyzedInvocation.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object invocationId_ = ""; + + /** + * + * + *
+     * Output only. The invocation ID.
+     * 
+ * + * string invocation_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The invocationId. + */ + public java.lang.String getInvocationId() { + java.lang.Object ref = invocationId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + invocationId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. The invocation ID.
+     * 
+ * + * string invocation_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for invocationId. + */ + public com.google.protobuf.ByteString getInvocationIdBytes() { + java.lang.Object ref = invocationId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + invocationId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. The invocation ID.
+     * 
+ * + * string invocation_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The invocationId to set. + * @return This builder for chaining. + */ + public Builder setInvocationId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + invocationId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The invocation ID.
+     * 
+ * + * string invocation_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearInvocationId() { + invocationId_ = getDefaultInstance().getInvocationId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The invocation ID.
+     * 
+ * + * string invocation_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for invocationId to set. + * @return This builder for chaining. + */ + public Builder setInvocationIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + invocationId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.cloud.aiplatform.v1.Assessment assessment_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.Assessment, + com.google.cloud.aiplatform.v1.Assessment.Builder, + com.google.cloud.aiplatform.v1.AssessmentOrBuilder> + assessmentBuilder_; + + /** + * + * + *
+     * Output only. The assessment of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the assessment field is set. + */ + public boolean hasAssessment() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+     * Output only. The assessment of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The assessment. + */ + public com.google.cloud.aiplatform.v1.Assessment getAssessment() { + if (assessmentBuilder_ == null) { + return assessment_ == null + ? com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance() + : assessment_; + } else { + return assessmentBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. The assessment of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setAssessment(com.google.cloud.aiplatform.v1.Assessment value) { + if (assessmentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + assessment_ = value; + } else { + assessmentBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The assessment of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setAssessment( + com.google.cloud.aiplatform.v1.Assessment.Builder builderForValue) { + if (assessmentBuilder_ == null) { + assessment_ = builderForValue.build(); + } else { + assessmentBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The assessment of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeAssessment(com.google.cloud.aiplatform.v1.Assessment value) { + if (assessmentBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && assessment_ != null + && assessment_ != com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance()) { + getAssessmentBuilder().mergeFrom(value); + } else { + assessment_ = value; + } + } else { + assessmentBuilder_.mergeFrom(value); + } + if (assessment_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. The assessment of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearAssessment() { + bitField0_ = (bitField0_ & ~0x00000004); + assessment_ = null; + if (assessmentBuilder_ != null) { + assessmentBuilder_.dispose(); + assessmentBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The assessment of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.aiplatform.v1.Assessment.Builder getAssessmentBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetAssessmentFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. The assessment of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.aiplatform.v1.AssessmentOrBuilder getAssessmentOrBuilder() { + if (assessmentBuilder_ != null) { + return assessmentBuilder_.getMessageOrBuilder(); + } else { + return assessment_ == null + ? com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance() + : assessment_; + } + } + + /** + * + * + *
+     * Output only. The assessment of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.Assessment, + com.google.cloud.aiplatform.v1.Assessment.Builder, + com.google.cloud.aiplatform.v1.AssessmentOrBuilder> + internalGetAssessmentFieldBuilder() { + if (assessmentBuilder_ == null) { + assessmentBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.Assessment, + com.google.cloud.aiplatform.v1.Assessment.Builder, + com.google.cloud.aiplatform.v1.AssessmentOrBuilder>( + getAssessment(), getParentForChildren(), isClean()); + assessment_ = null; + } + return assessmentBuilder_; + } + + private int invocationState_ = 0; + + /** + * + * + *
+     * Output only. The state of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState invocation_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for invocationState. + */ + @java.lang.Override + public int getInvocationStateValue() { + return invocationState_; + } + + /** + * + * + *
+     * Output only. The state of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState invocation_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for invocationState to set. + * @return This builder for chaining. + */ + public Builder setInvocationStateValue(int value) { + invocationState_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The state of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState invocation_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The invocationState. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState getInvocationState() { + com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState result = + com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState.forNumber( + invocationState_); + return result == null + ? com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Output only. The state of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState invocation_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The invocationState to set. + * @return This builder for chaining. + */ + public Builder setInvocationState( + com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000008; + invocationState_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The state of the invocation.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState invocation_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearInvocationState() { + bitField0_ = (bitField0_ & ~0x00000008); + invocationState_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.AnalyzedInvocation) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.AnalyzedInvocation) + private static final com.google.cloud.aiplatform.v1.AnalyzedInvocation DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.AnalyzedInvocation(); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedInvocation getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AnalyzedInvocation parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedInvocation getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedInvocationName.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedInvocationName.java new file mode 100644 index 000000000000..37d84f2e3696 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedInvocationName.java @@ -0,0 +1,311 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class AnalyzedInvocationName implements ResourceName { + private static final PathTemplate + PROJECT_LOCATION_MONITORED_AGENT_ANALYZED_SESSION_ANALYZED_INVOCATION = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String monitoredAgent; + private final String analyzedSession; + private final String analyzedInvocation; + + @Deprecated + protected AnalyzedInvocationName() { + project = null; + location = null; + monitoredAgent = null; + analyzedSession = null; + analyzedInvocation = null; + } + + private AnalyzedInvocationName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + monitoredAgent = Preconditions.checkNotNull(builder.getMonitoredAgent()); + analyzedSession = Preconditions.checkNotNull(builder.getAnalyzedSession()); + analyzedInvocation = Preconditions.checkNotNull(builder.getAnalyzedInvocation()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getMonitoredAgent() { + return monitoredAgent; + } + + public String getAnalyzedSession() { + return analyzedSession; + } + + public String getAnalyzedInvocation() { + return analyzedInvocation; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static AnalyzedInvocationName of( + String project, + String location, + String monitoredAgent, + String analyzedSession, + String analyzedInvocation) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setMonitoredAgent(monitoredAgent) + .setAnalyzedSession(analyzedSession) + .setAnalyzedInvocation(analyzedInvocation) + .build(); + } + + public static String format( + String project, + String location, + String monitoredAgent, + String analyzedSession, + String analyzedInvocation) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setMonitoredAgent(monitoredAgent) + .setAnalyzedSession(analyzedSession) + .setAnalyzedInvocation(analyzedInvocation) + .build() + .toString(); + } + + public static @Nullable AnalyzedInvocationName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_MONITORED_AGENT_ANALYZED_SESSION_ANALYZED_INVOCATION.validatedMatch( + formattedString, "AnalyzedInvocationName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("monitored_agent"), + matchMap.get("analyzed_session"), + matchMap.get("analyzed_invocation")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable AnalyzedInvocationName> values) { + List list = new ArrayList<>(values.size()); + for (AnalyzedInvocationName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_MONITORED_AGENT_ANALYZED_SESSION_ANALYZED_INVOCATION.matches( + formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (monitoredAgent != null) { + fieldMapBuilder.put("monitored_agent", monitoredAgent); + } + if (analyzedSession != null) { + fieldMapBuilder.put("analyzed_session", analyzedSession); + } + if (analyzedInvocation != null) { + fieldMapBuilder.put("analyzed_invocation", analyzedInvocation); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_MONITORED_AGENT_ANALYZED_SESSION_ANALYZED_INVOCATION.instantiate( + "project", + project, + "location", + location, + "monitored_agent", + monitoredAgent, + "analyzed_session", + analyzedSession, + "analyzed_invocation", + analyzedInvocation); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + AnalyzedInvocationName that = ((AnalyzedInvocationName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.monitoredAgent, that.monitoredAgent) + && Objects.equals(this.analyzedSession, that.analyzedSession) + && Objects.equals(this.analyzedInvocation, that.analyzedInvocation); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(monitoredAgent); + h *= 1000003; + h ^= Objects.hashCode(analyzedSession); + h *= 1000003; + h ^= Objects.hashCode(analyzedInvocation); + return h; + } + + /** + * Builder for + * projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}. + */ + public static class Builder { + private String project; + private String location; + private String monitoredAgent; + private String analyzedSession; + private String analyzedInvocation; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getMonitoredAgent() { + return monitoredAgent; + } + + public String getAnalyzedSession() { + return analyzedSession; + } + + public String getAnalyzedInvocation() { + return analyzedInvocation; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setMonitoredAgent(String monitoredAgent) { + this.monitoredAgent = monitoredAgent; + return this; + } + + public Builder setAnalyzedSession(String analyzedSession) { + this.analyzedSession = analyzedSession; + return this; + } + + public Builder setAnalyzedInvocation(String analyzedInvocation) { + this.analyzedInvocation = analyzedInvocation; + return this; + } + + private Builder(AnalyzedInvocationName analyzedInvocationName) { + this.project = analyzedInvocationName.project; + this.location = analyzedInvocationName.location; + this.monitoredAgent = analyzedInvocationName.monitoredAgent; + this.analyzedSession = analyzedInvocationName.analyzedSession; + this.analyzedInvocation = analyzedInvocationName.analyzedInvocation; + } + + public AnalyzedInvocationName build() { + return new AnalyzedInvocationName(this); + } + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedInvocationOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedInvocationOrBuilder.java new file mode 100644 index 000000000000..901fd1cf4cb6 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedInvocationOrBuilder.java @@ -0,0 +1,153 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface AnalyzedInvocationOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.AnalyzedInvocation) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Identifier. The resource name of the AnalyzedInvocation.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Identifier. The resource name of the AnalyzedInvocation.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Output only. The invocation ID.
+   * 
+ * + * string invocation_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The invocationId. + */ + java.lang.String getInvocationId(); + + /** + * + * + *
+   * Output only. The invocation ID.
+   * 
+ * + * string invocation_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for invocationId. + */ + com.google.protobuf.ByteString getInvocationIdBytes(); + + /** + * + * + *
+   * Output only. The assessment of the invocation.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the assessment field is set. + */ + boolean hasAssessment(); + + /** + * + * + *
+   * Output only. The assessment of the invocation.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The assessment. + */ + com.google.cloud.aiplatform.v1.Assessment getAssessment(); + + /** + * + * + *
+   * Output only. The assessment of the invocation.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.aiplatform.v1.AssessmentOrBuilder getAssessmentOrBuilder(); + + /** + * + * + *
+   * Output only. The state of the invocation.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState invocation_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for invocationState. + */ + int getInvocationStateValue(); + + /** + * + * + *
+   * Output only. The state of the invocation.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState invocation_state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The invocationState. + */ + com.google.cloud.aiplatform.v1.AnalyzedInvocation.InvocationState getInvocationState(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSession.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSession.java new file mode 100644 index 000000000000..b30e6b47cdd6 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSession.java @@ -0,0 +1,4963 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Represents an analyzed session for a monitored agent.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AnalyzedSession} + */ +@com.google.protobuf.Generated +public final class AnalyzedSession extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.AnalyzedSession) + AnalyzedSessionOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AnalyzedSession"); + } + + // Use AnalyzedSession.newBuilder() to construct. + private AnalyzedSession(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AnalyzedSession() { + name_ = ""; + sessionId_ = ""; + userId_ = ""; + agentResourceName_ = ""; + sessionState_ = 0; + agentDisplayName_ = ""; + agentState_ = 0; + location_ = ""; + agentType_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedSession_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 8: + return internalGetSeverities(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedSession_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AnalyzedSession.class, + com.google.cloud.aiplatform.v1.AnalyzedSession.Builder.class); + } + + /** + * + * + *
+   * The analysis state of a session.
+   * 
+ * + * Protobuf enum {@code google.cloud.aiplatform.v1.AnalyzedSession.SessionState} + */ + public enum SessionState implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * The session state is unspecified.
+     * 
+ * + * SESSION_STATE_UNSPECIFIED = 0; + */ + SESSION_STATE_UNSPECIFIED(0), + /** + * + * + *
+     * The session has not yet been analyzed.
+     * 
+ * + * SESSION_STATE_UNANALYZED = 1; + */ + SESSION_STATE_UNANALYZED(1), + /** + * + * + *
+     * The session has been analyzed and no anomalies were flagged.
+     * 
+ * + * SESSION_STATE_NOT_FLAGGED = 2; + */ + SESSION_STATE_NOT_FLAGGED(2), + /** + * + * + *
+     * The session has been analyzed and at least one anomaly was flagged.
+     * 
+ * + * SESSION_STATE_FLAGGED = 3; + */ + SESSION_STATE_FLAGGED(3), + /** + * + * + *
+     * The session was analyzed by the LLM judge, which did not flag any
+     * anomalies.
+     * 
+ * + * SESSION_STATE_LLM_UNFLAGGED = 4; + */ + SESSION_STATE_LLM_UNFLAGGED(4), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SessionState"); + } + + /** + * + * + *
+     * The session state is unspecified.
+     * 
+ * + * SESSION_STATE_UNSPECIFIED = 0; + */ + public static final int SESSION_STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The session has not yet been analyzed.
+     * 
+ * + * SESSION_STATE_UNANALYZED = 1; + */ + public static final int SESSION_STATE_UNANALYZED_VALUE = 1; + + /** + * + * + *
+     * The session has been analyzed and no anomalies were flagged.
+     * 
+ * + * SESSION_STATE_NOT_FLAGGED = 2; + */ + public static final int SESSION_STATE_NOT_FLAGGED_VALUE = 2; + + /** + * + * + *
+     * The session has been analyzed and at least one anomaly was flagged.
+     * 
+ * + * SESSION_STATE_FLAGGED = 3; + */ + public static final int SESSION_STATE_FLAGGED_VALUE = 3; + + /** + * + * + *
+     * The session was analyzed by the LLM judge, which did not flag any
+     * anomalies.
+     * 
+ * + * SESSION_STATE_LLM_UNFLAGGED = 4; + */ + public static final int SESSION_STATE_LLM_UNFLAGGED_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static SessionState valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static SessionState forNumber(int value) { + switch (value) { + case 0: + return SESSION_STATE_UNSPECIFIED; + case 1: + return SESSION_STATE_UNANALYZED; + case 2: + return SESSION_STATE_NOT_FLAGGED; + case 3: + return SESSION_STATE_FLAGGED; + case 4: + return SESSION_STATE_LLM_UNFLAGGED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public SessionState findValueByNumber(int number) { + return SessionState.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AnalyzedSession.getDescriptor().getEnumTypes().get(0); + } + + private static final SessionState[] VALUES = values(); + + public static SessionState valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private SessionState(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.aiplatform.v1.AnalyzedSession.SessionState) + } + + public interface SeveritySummaryOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * The list of detectors summaries for this severity level.
+     * 
+ * + * repeated string detector_ids = 1; + * + * @return A list containing the detectorIds. + */ + java.util.List getDetectorIdsList(); + + /** + * + * + *
+     * The list of detectors summaries for this severity level.
+     * 
+ * + * repeated string detector_ids = 1; + * + * @return The count of detectorIds. + */ + int getDetectorIdsCount(); + + /** + * + * + *
+     * The list of detectors summaries for this severity level.
+     * 
+ * + * repeated string detector_ids = 1; + * + * @param index The index of the element to return. + * @return The detectorIds at the given index. + */ + java.lang.String getDetectorIds(int index); + + /** + * + * + *
+     * The list of detectors summaries for this severity level.
+     * 
+ * + * repeated string detector_ids = 1; + * + * @param index The index of the value to return. + * @return The bytes of the detectorIds at the given index. + */ + com.google.protobuf.ByteString getDetectorIdsBytes(int index); + + /** + * + * + *
+     * The severity level of the detector.
+     * 
+ * + * .google.cloud.aiplatform.v1.Severity severity_level = 2; + * + * @return The enum numeric value on the wire for severityLevel. + */ + int getSeverityLevelValue(); + + /** + * + * + *
+     * The severity level of the detector.
+     * 
+ * + * .google.cloud.aiplatform.v1.Severity severity_level = 2; + * + * @return The severityLevel. + */ + com.google.cloud.aiplatform.v1.Severity getSeverityLevel(); + + /** + * + * + *
+     * Output only. The number of distinct sessions whose maximum severity
+     * equals `severity_level`. Each session is counted in exactly one bucket
+     * (its highest severity).
+     *
+     * Scope depends on where this appears: a global count on
+     * `AggregateAnalyzedSessionsResponse.summary`, per-agent on
+     * `agent_aggregates` entries, and page-scoped on
+     * `ListAnalyzedSessionsResponse`.
+     * 
+ * + * int32 sessions_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sessionsCount. + */ + int getSessionsCount(); + } + + /** + * + * + *
+   * Breaks down anomalies by severity.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary} + */ + public static final class SeveritySummary extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) + SeveritySummaryOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SeveritySummary"); + } + + // Use SeveritySummary.newBuilder() to construct. + private SeveritySummary(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private SeveritySummary() { + detectorIds_ = com.google.protobuf.LazyStringArrayList.emptyList(); + severityLevel_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritySummary_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritySummary_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.class, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder.class); + } + + public static final int DETECTOR_IDS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList detectorIds_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+     * The list of detectors summaries for this severity level.
+     * 
+ * + * repeated string detector_ids = 1; + * + * @return A list containing the detectorIds. + */ + public com.google.protobuf.ProtocolStringList getDetectorIdsList() { + return detectorIds_; + } + + /** + * + * + *
+     * The list of detectors summaries for this severity level.
+     * 
+ * + * repeated string detector_ids = 1; + * + * @return The count of detectorIds. + */ + public int getDetectorIdsCount() { + return detectorIds_.size(); + } + + /** + * + * + *
+     * The list of detectors summaries for this severity level.
+     * 
+ * + * repeated string detector_ids = 1; + * + * @param index The index of the element to return. + * @return The detectorIds at the given index. + */ + public java.lang.String getDetectorIds(int index) { + return detectorIds_.get(index); + } + + /** + * + * + *
+     * The list of detectors summaries for this severity level.
+     * 
+ * + * repeated string detector_ids = 1; + * + * @param index The index of the value to return. + * @return The bytes of the detectorIds at the given index. + */ + public com.google.protobuf.ByteString getDetectorIdsBytes(int index) { + return detectorIds_.getByteString(index); + } + + public static final int SEVERITY_LEVEL_FIELD_NUMBER = 2; + private int severityLevel_ = 0; + + /** + * + * + *
+     * The severity level of the detector.
+     * 
+ * + * .google.cloud.aiplatform.v1.Severity severity_level = 2; + * + * @return The enum numeric value on the wire for severityLevel. + */ + @java.lang.Override + public int getSeverityLevelValue() { + return severityLevel_; + } + + /** + * + * + *
+     * The severity level of the detector.
+     * 
+ * + * .google.cloud.aiplatform.v1.Severity severity_level = 2; + * + * @return The severityLevel. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.Severity getSeverityLevel() { + com.google.cloud.aiplatform.v1.Severity result = + com.google.cloud.aiplatform.v1.Severity.forNumber(severityLevel_); + return result == null ? com.google.cloud.aiplatform.v1.Severity.UNRECOGNIZED : result; + } + + public static final int SESSIONS_COUNT_FIELD_NUMBER = 3; + private int sessionsCount_ = 0; + + /** + * + * + *
+     * Output only. The number of distinct sessions whose maximum severity
+     * equals `severity_level`. Each session is counted in exactly one bucket
+     * (its highest severity).
+     *
+     * Scope depends on where this appears: a global count on
+     * `AggregateAnalyzedSessionsResponse.summary`, per-agent on
+     * `agent_aggregates` entries, and page-scoped on
+     * `ListAnalyzedSessionsResponse`.
+     * 
+ * + * int32 sessions_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sessionsCount. + */ + @java.lang.Override + public int getSessionsCount() { + return sessionsCount_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < detectorIds_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, detectorIds_.getRaw(i)); + } + if (severityLevel_ + != com.google.cloud.aiplatform.v1.Severity.SEVERITY_UNSPECIFIED.getNumber()) { + output.writeEnum(2, severityLevel_); + } + if (sessionsCount_ != 0) { + output.writeInt32(3, sessionsCount_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + for (int i = 0; i < detectorIds_.size(); i++) { + dataSize += computeStringSizeNoTag(detectorIds_.getRaw(i)); + } + size += dataSize; + size += 1 * getDetectorIdsList().size(); + } + if (severityLevel_ + != com.google.cloud.aiplatform.v1.Severity.SEVERITY_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, severityLevel_); + } + if (sessionsCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, sessionsCount_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary other = + (com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) obj; + + if (!getDetectorIdsList().equals(other.getDetectorIdsList())) return false; + if (severityLevel_ != other.severityLevel_) return false; + if (getSessionsCount() != other.getSessionsCount()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getDetectorIdsCount() > 0) { + hash = (37 * hash) + DETECTOR_IDS_FIELD_NUMBER; + hash = (53 * hash) + getDetectorIdsList().hashCode(); + } + hash = (37 * hash) + SEVERITY_LEVEL_FIELD_NUMBER; + hash = (53 * hash) + severityLevel_; + hash = (37 * hash) + SESSIONS_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getSessionsCount(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+     * Breaks down anomalies by severity.
+     * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritySummary_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritySummary_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.class, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + detectorIds_ = com.google.protobuf.LazyStringArrayList.emptyList(); + severityLevel_ = 0; + sessionsCount_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritySummary_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary build() { + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary buildPartial() { + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary result = + new com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + detectorIds_.makeImmutable(); + result.detectorIds_ = detectorIds_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.severityLevel_ = severityLevel_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.sessionsCount_ = sessionsCount_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) { + return mergeFrom((com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary other) { + if (other + == com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.getDefaultInstance()) + return this; + if (!other.detectorIds_.isEmpty()) { + if (detectorIds_.isEmpty()) { + detectorIds_ = other.detectorIds_; + bitField0_ |= 0x00000001; + } else { + ensureDetectorIdsIsMutable(); + detectorIds_.addAll(other.detectorIds_); + } + onChanged(); + } + if (other.severityLevel_ != 0) { + setSeverityLevelValue(other.getSeverityLevelValue()); + } + if (other.getSessionsCount() != 0) { + setSessionsCount(other.getSessionsCount()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureDetectorIdsIsMutable(); + detectorIds_.add(s); + break; + } // case 10 + case 16: + { + severityLevel_ = input.readEnum(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 24: + { + sessionsCount_ = input.readInt32(); + bitField0_ |= 0x00000004; + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringArrayList detectorIds_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureDetectorIdsIsMutable() { + if (!detectorIds_.isModifiable()) { + detectorIds_ = new com.google.protobuf.LazyStringArrayList(detectorIds_); + } + bitField0_ |= 0x00000001; + } + + /** + * + * + *
+       * The list of detectors summaries for this severity level.
+       * 
+ * + * repeated string detector_ids = 1; + * + * @return A list containing the detectorIds. + */ + public com.google.protobuf.ProtocolStringList getDetectorIdsList() { + detectorIds_.makeImmutable(); + return detectorIds_; + } + + /** + * + * + *
+       * The list of detectors summaries for this severity level.
+       * 
+ * + * repeated string detector_ids = 1; + * + * @return The count of detectorIds. + */ + public int getDetectorIdsCount() { + return detectorIds_.size(); + } + + /** + * + * + *
+       * The list of detectors summaries for this severity level.
+       * 
+ * + * repeated string detector_ids = 1; + * + * @param index The index of the element to return. + * @return The detectorIds at the given index. + */ + public java.lang.String getDetectorIds(int index) { + return detectorIds_.get(index); + } + + /** + * + * + *
+       * The list of detectors summaries for this severity level.
+       * 
+ * + * repeated string detector_ids = 1; + * + * @param index The index of the value to return. + * @return The bytes of the detectorIds at the given index. + */ + public com.google.protobuf.ByteString getDetectorIdsBytes(int index) { + return detectorIds_.getByteString(index); + } + + /** + * + * + *
+       * The list of detectors summaries for this severity level.
+       * 
+ * + * repeated string detector_ids = 1; + * + * @param index The index to set the value at. + * @param value The detectorIds to set. + * @return This builder for chaining. + */ + public Builder setDetectorIds(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDetectorIdsIsMutable(); + detectorIds_.set(index, value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+       * The list of detectors summaries for this severity level.
+       * 
+ * + * repeated string detector_ids = 1; + * + * @param value The detectorIds to add. + * @return This builder for chaining. + */ + public Builder addDetectorIds(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDetectorIdsIsMutable(); + detectorIds_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+       * The list of detectors summaries for this severity level.
+       * 
+ * + * repeated string detector_ids = 1; + * + * @param values The detectorIds to add. + * @return This builder for chaining. + */ + public Builder addAllDetectorIds(java.lang.Iterable values) { + ensureDetectorIdsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, detectorIds_); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+       * The list of detectors summaries for this severity level.
+       * 
+ * + * repeated string detector_ids = 1; + * + * @return This builder for chaining. + */ + public Builder clearDetectorIds() { + detectorIds_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + ; + onChanged(); + return this; + } + + /** + * + * + *
+       * The list of detectors summaries for this severity level.
+       * 
+ * + * repeated string detector_ids = 1; + * + * @param value The bytes of the detectorIds to add. + * @return This builder for chaining. + */ + public Builder addDetectorIdsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureDetectorIdsIsMutable(); + detectorIds_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int severityLevel_ = 0; + + /** + * + * + *
+       * The severity level of the detector.
+       * 
+ * + * .google.cloud.aiplatform.v1.Severity severity_level = 2; + * + * @return The enum numeric value on the wire for severityLevel. + */ + @java.lang.Override + public int getSeverityLevelValue() { + return severityLevel_; + } + + /** + * + * + *
+       * The severity level of the detector.
+       * 
+ * + * .google.cloud.aiplatform.v1.Severity severity_level = 2; + * + * @param value The enum numeric value on the wire for severityLevel to set. + * @return This builder for chaining. + */ + public Builder setSeverityLevelValue(int value) { + severityLevel_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+       * The severity level of the detector.
+       * 
+ * + * .google.cloud.aiplatform.v1.Severity severity_level = 2; + * + * @return The severityLevel. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.Severity getSeverityLevel() { + com.google.cloud.aiplatform.v1.Severity result = + com.google.cloud.aiplatform.v1.Severity.forNumber(severityLevel_); + return result == null ? com.google.cloud.aiplatform.v1.Severity.UNRECOGNIZED : result; + } + + /** + * + * + *
+       * The severity level of the detector.
+       * 
+ * + * .google.cloud.aiplatform.v1.Severity severity_level = 2; + * + * @param value The severityLevel to set. + * @return This builder for chaining. + */ + public Builder setSeverityLevel(com.google.cloud.aiplatform.v1.Severity value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000002; + severityLevel_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+       * The severity level of the detector.
+       * 
+ * + * .google.cloud.aiplatform.v1.Severity severity_level = 2; + * + * @return This builder for chaining. + */ + public Builder clearSeverityLevel() { + bitField0_ = (bitField0_ & ~0x00000002); + severityLevel_ = 0; + onChanged(); + return this; + } + + private int sessionsCount_; + + /** + * + * + *
+       * Output only. The number of distinct sessions whose maximum severity
+       * equals `severity_level`. Each session is counted in exactly one bucket
+       * (its highest severity).
+       *
+       * Scope depends on where this appears: a global count on
+       * `AggregateAnalyzedSessionsResponse.summary`, per-agent on
+       * `agent_aggregates` entries, and page-scoped on
+       * `ListAnalyzedSessionsResponse`.
+       * 
+ * + * int32 sessions_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sessionsCount. + */ + @java.lang.Override + public int getSessionsCount() { + return sessionsCount_; + } + + /** + * + * + *
+       * Output only. The number of distinct sessions whose maximum severity
+       * equals `severity_level`. Each session is counted in exactly one bucket
+       * (its highest severity).
+       *
+       * Scope depends on where this appears: a global count on
+       * `AggregateAnalyzedSessionsResponse.summary`, per-agent on
+       * `agent_aggregates` entries, and page-scoped on
+       * `ListAnalyzedSessionsResponse`.
+       * 
+ * + * int32 sessions_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The sessionsCount to set. + * @return This builder for chaining. + */ + public Builder setSessionsCount(int value) { + + sessionsCount_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The number of distinct sessions whose maximum severity
+       * equals `severity_level`. Each session is counted in exactly one bucket
+       * (its highest severity).
+       *
+       * Scope depends on where this appears: a global count on
+       * `AggregateAnalyzedSessionsResponse.summary`, per-agent on
+       * `agent_aggregates` entries, and page-scoped on
+       * `ListAnalyzedSessionsResponse`.
+       * 
+ * + * int32 sessions_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearSessionsCount() { + bitField0_ = (bitField0_ & ~0x00000004); + sessionsCount_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) + private static final com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary(); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SeveritySummary parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Identifier. The resource name of the AnalyzedSession.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Identifier. The resource name of the AnalyzedSession.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SESSION_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object sessionId_ = ""; + + /** + * + * + *
+   * Output only. The session ID.
+   * 
+ * + * string session_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sessionId. + */ + @java.lang.Override + public java.lang.String getSessionId() { + java.lang.Object ref = sessionId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sessionId_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. The session ID.
+   * 
+ * + * string session_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for sessionId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSessionIdBytes() { + java.lang.Object ref = sessionId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sessionId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int USER_ID_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object userId_ = ""; + + /** + * + * + *
+   * Output only. The user ID.
+   * 
+ * + * string user_id = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The userId. + */ + @java.lang.Override + public java.lang.String getUserId() { + java.lang.Object ref = userId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + userId_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. The user ID.
+   * 
+ * + * string user_id = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for userId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUserIdBytes() { + java.lang.Object ref = userId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + userId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int AGENT_RESOURCE_NAME_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object agentResourceName_ = ""; + + /** + * + * + *
+   * Output only. The resource name or identifier of the agent that ran this
+   * session. Matches `AgentResource.agent` on the corresponding
+   * `MonitoredAgent`, so the format depends on that agent's
+   * `AgentResource.agent_type`. For the format of each agent type, see
+   * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+   * 
+ * + * + * string agent_resource_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The agentResourceName. + */ + @java.lang.Override + public java.lang.String getAgentResourceName() { + java.lang.Object ref = agentResourceName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agentResourceName_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. The resource name or identifier of the agent that ran this
+   * session. Matches `AgentResource.agent` on the corresponding
+   * `MonitoredAgent`, so the format depends on that agent's
+   * `AgentResource.agent_type`. For the format of each agent type, see
+   * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+   * 
+ * + * + * string agent_resource_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for agentResourceName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAgentResourceNameBytes() { + java.lang.Object ref = agentResourceName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agentResourceName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
+   * Output only. The creation time of the session.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Output only. The creation time of the session.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
+   * Output only. The creation time of the session.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int LATEST_ANALYZED_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp latestAnalyzedTime_; + + /** + * + * + *
+   * Output only. The latest analyzed time of the session.
+   * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the latestAnalyzedTime field is set. + */ + @java.lang.Override + public boolean hasLatestAnalyzedTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Output only. The latest analyzed time of the session.
+   * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The latestAnalyzedTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLatestAnalyzedTime() { + return latestAnalyzedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : latestAnalyzedTime_; + } + + /** + * + * + *
+   * Output only. The latest analyzed time of the session.
+   * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLatestAnalyzedTimeOrBuilder() { + return latestAnalyzedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : latestAnalyzedTime_; + } + + public static final int ASSESSMENT_FIELD_NUMBER = 7; + private com.google.cloud.aiplatform.v1.Assessment assessment_; + + /** + * + * + *
+   * Output only. Overall security assessment. Populated only in FULL view.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the assessment field is set. + */ + @java.lang.Override + public boolean hasAssessment() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+   * Output only. Overall security assessment. Populated only in FULL view.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The assessment. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment getAssessment() { + return assessment_ == null + ? com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance() + : assessment_; + } + + /** + * + * + *
+   * Output only. Overall security assessment. Populated only in FULL view.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AssessmentOrBuilder getAssessmentOrBuilder() { + return assessment_ == null + ? com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance() + : assessment_; + } + + public static final int SEVERITIES_FIELD_NUMBER = 8; + + private static final class SeveritiesDefaultEntryHolder { + static final com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + defaultEntry = + com.google.protobuf.MapEntry + . + newDefaultInstance( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedSession_SeveritiesEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.MESSAGE, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + .getDefaultInstance()); + } + + @SuppressWarnings("serial") + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + severities_; + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + internalGetSeverities() { + if (severities_ == null) { + return com.google.protobuf.MapField.emptyMapField(SeveritiesDefaultEntryHolder.defaultEntry); + } + return severities_; + } + + public int getSeveritiesCount() { + return internalGetSeverities().getMap().size(); + } + + /** + * + * + *
+   * Output only. Map of the detectors that flagged this session, grouped by
+   * severity. The key is the string representation of `Severity`. Populated
+   * only for flagged sessions, in both views. In
+   * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+   * responses, the map holds only the session's highest severity.
+   * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public boolean containsSeverities(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetSeverities().getMap().containsKey(key); + } + + /** Use {@link #getSeveritiesMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeverities() { + return getSeveritiesMap(); + } + + /** + * + * + *
+   * Output only. Map of the detectors that flagged this session, grouped by
+   * severity. The key is the string representation of `Severity`. Populated
+   * only for flagged sessions, in both views. In
+   * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+   * responses, the map holds only the session's highest severity.
+   * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeveritiesMap() { + return internalGetSeverities().getMap(); + } + + /** + * + * + *
+   * Output only. Map of the detectors that flagged this session, grouped by
+   * severity. The key is the string representation of `Severity`. Populated
+   * only for flagged sessions, in both views. In
+   * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+   * responses, the map holds only the session's highest severity.
+   * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public /* nullable */ com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + getSeveritiesOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map + map = internalGetSeverities().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
+   * Output only. Map of the detectors that flagged this session, grouped by
+   * severity. The key is the string representation of `Severity`. Populated
+   * only for flagged sessions, in both views. In
+   * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+   * responses, the map holds only the session's highest severity.
+   * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrThrow( + java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map + map = internalGetSeverities().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public static final int SESSION_STATE_FIELD_NUMBER = 9; + private int sessionState_ = 0; + + /** + * + * + *
+   * Output only. The state of the session.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSession.SessionState session_state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for sessionState. + */ + @java.lang.Override + public int getSessionStateValue() { + return sessionState_; + } + + /** + * + * + *
+   * Output only. The state of the session.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSession.SessionState session_state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The sessionState. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState getSessionState() { + com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState result = + com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState.forNumber(sessionState_); + return result == null + ? com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState.UNRECOGNIZED + : result; + } + + public static final int AGENT_DISPLAY_NAME_FIELD_NUMBER = 10; + + @SuppressWarnings("serial") + private volatile java.lang.Object agentDisplayName_ = ""; + + /** + * + * + *
+   * Output only. The human-readable display name of the MonitoredAgent that
+   * owns this session. May be empty when the session's agent is not enrolled
+   * as a MonitoredAgent; the `agent_resource_name` is always present and can
+   * be used as a fallback identifier.
+   * 
+ * + * string agent_display_name = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The agentDisplayName. + */ + @java.lang.Override + public java.lang.String getAgentDisplayName() { + java.lang.Object ref = agentDisplayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agentDisplayName_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. The human-readable display name of the MonitoredAgent that
+   * owns this session. May be empty when the session's agent is not enrolled
+   * as a MonitoredAgent; the `agent_resource_name` is always present and can
+   * be used as a fallback identifier.
+   * 
+ * + * string agent_display_name = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for agentDisplayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAgentDisplayNameBytes() { + java.lang.Object ref = agentDisplayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agentDisplayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int AGENT_STATE_FIELD_NUMBER = 11; + private int agentState_ = 0; + + /** + * + * + *
+   * Output only. The current enablement state of the MonitoredAgent that owns
+   * this session (for example, ACTIVE, DISABLED, or ENABLING). Defaults to
+   * ENABLEMENT_STATE_UNSPECIFIED when the agent is not enrolled or its state
+   * is unknown.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_state = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentState. + */ + @java.lang.Override + public int getAgentStateValue() { + return agentState_; + } + + /** + * + * + *
+   * Output only. The current enablement state of the MonitoredAgent that owns
+   * this session (for example, ACTIVE, DISABLED, or ENABLING). Defaults to
+   * ENABLEMENT_STATE_UNSPECIFIED when the agent is not enrolled or its state
+   * is unknown.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_state = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentState. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState getAgentState() { + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState result = + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.forNumber(agentState_); + return result == null + ? com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.UNRECOGNIZED + : result; + } + + public static final int LOCATION_FIELD_NUMBER = 12; + + @SuppressWarnings("serial") + private volatile java.lang.Object location_ = ""; + + /** + * + * + *
+   * Output only. The region of the agent that ran this session, in the same
+   * form as `AgentResource.location` (for example, `us-central1`). Empty when
+   * the agent is not enrolled or its location is unknown.
+   * 
+ * + * string location = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The location. + */ + @java.lang.Override + public java.lang.String getLocation() { + java.lang.Object ref = location_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + location_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. The region of the agent that ran this session, in the same
+   * form as `AgentResource.location` (for example, `us-central1`). Empty when
+   * the agent is not enrolled or its location is unknown.
+   * 
+ * + * string location = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for location. + */ + @java.lang.Override + public com.google.protobuf.ByteString getLocationBytes() { + java.lang.Object ref = location_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + location_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int AGENT_TYPE_FIELD_NUMBER = 13; + private int agentType_ = 0; + + /** + * + * + *
+   * Output only. The runtime that the agent which ran this session is hosted
+   * on (for example, `CLOUD_RUN_SERVICE`).
+   *
+   * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service --
+   * the agent is not enrolled as a `MonitoredAgent`, or was enrolled before its
+   * runtime was recorded. That is distinct from `AGENT_TYPE_OTHER`, which means
+   * the runtime is known and is not one of the other enumerated runtimes.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentType. + */ + @java.lang.Override + public int getAgentTypeValue() { + return agentType_; + } + + /** + * + * + *
+   * Output only. The runtime that the agent which ran this session is hosted
+   * on (for example, `CLOUD_RUN_SERVICE`).
+   *
+   * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service --
+   * the agent is not enrolled as a `MonitoredAgent`, or was enrolled before its
+   * runtime was recorded. That is distinct from `AGENT_TYPE_OTHER`, which means
+   * the runtime is known and is not one of the other enumerated runtimes.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentType. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource.AgentType getAgentType() { + com.google.cloud.aiplatform.v1.AgentResource.AgentType result = + com.google.cloud.aiplatform.v1.AgentResource.AgentType.forNumber(agentType_); + return result == null + ? com.google.cloud.aiplatform.v1.AgentResource.AgentType.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sessionId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, sessionId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(userId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, userId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agentResourceName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, agentResourceName_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(6, getLatestAnalyzedTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(7, getAssessment()); + } + com.google.protobuf.GeneratedMessage.serializeStringMapTo( + output, internalGetSeverities(), SeveritiesDefaultEntryHolder.defaultEntry, 8); + if (sessionState_ + != com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState.SESSION_STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(9, sessionState_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agentDisplayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 10, agentDisplayName_); + } + if (agentState_ + != com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState + .ENABLEMENT_STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(11, agentState_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(location_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 12, location_); + } + if (agentType_ + != com.google.cloud.aiplatform.v1.AgentResource.AgentType.AGENT_TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(13, agentType_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sessionId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, sessionId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(userId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, userId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agentResourceName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, agentResourceName_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getLatestAnalyzedTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getAssessment()); + } + for (java.util.Map.Entry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + entry : internalGetSeverities().getMap().entrySet()) { + com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + severities__ = + SeveritiesDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, severities__); + } + if (sessionState_ + != com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState.SESSION_STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(9, sessionState_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agentDisplayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(10, agentDisplayName_); + } + if (agentState_ + != com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState + .ENABLEMENT_STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(11, agentState_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(location_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(12, location_); + } + if (agentType_ + != com.google.cloud.aiplatform.v1.AgentResource.AgentType.AGENT_TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(13, agentType_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.AnalyzedSession)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.AnalyzedSession other = + (com.google.cloud.aiplatform.v1.AnalyzedSession) obj; + + if (!getName().equals(other.getName())) return false; + if (!getSessionId().equals(other.getSessionId())) return false; + if (!getUserId().equals(other.getUserId())) return false; + if (!getAgentResourceName().equals(other.getAgentResourceName())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasLatestAnalyzedTime() != other.hasLatestAnalyzedTime()) return false; + if (hasLatestAnalyzedTime()) { + if (!getLatestAnalyzedTime().equals(other.getLatestAnalyzedTime())) return false; + } + if (hasAssessment() != other.hasAssessment()) return false; + if (hasAssessment()) { + if (!getAssessment().equals(other.getAssessment())) return false; + } + if (!internalGetSeverities().equals(other.internalGetSeverities())) return false; + if (sessionState_ != other.sessionState_) return false; + if (!getAgentDisplayName().equals(other.getAgentDisplayName())) return false; + if (agentState_ != other.agentState_) return false; + if (!getLocation().equals(other.getLocation())) return false; + if (agentType_ != other.agentType_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + SESSION_ID_FIELD_NUMBER; + hash = (53 * hash) + getSessionId().hashCode(); + hash = (37 * hash) + USER_ID_FIELD_NUMBER; + hash = (53 * hash) + getUserId().hashCode(); + hash = (37 * hash) + AGENT_RESOURCE_NAME_FIELD_NUMBER; + hash = (53 * hash) + getAgentResourceName().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasLatestAnalyzedTime()) { + hash = (37 * hash) + LATEST_ANALYZED_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLatestAnalyzedTime().hashCode(); + } + if (hasAssessment()) { + hash = (37 * hash) + ASSESSMENT_FIELD_NUMBER; + hash = (53 * hash) + getAssessment().hashCode(); + } + if (!internalGetSeverities().getMap().isEmpty()) { + hash = (37 * hash) + SEVERITIES_FIELD_NUMBER; + hash = (53 * hash) + internalGetSeverities().hashCode(); + } + hash = (37 * hash) + SESSION_STATE_FIELD_NUMBER; + hash = (53 * hash) + sessionState_; + hash = (37 * hash) + AGENT_DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getAgentDisplayName().hashCode(); + hash = (37 * hash) + AGENT_STATE_FIELD_NUMBER; + hash = (53 * hash) + agentState_; + hash = (37 * hash) + LOCATION_FIELD_NUMBER; + hash = (53 * hash) + getLocation().hashCode(); + hash = (37 * hash) + AGENT_TYPE_FIELD_NUMBER; + hash = (53 * hash) + agentType_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.aiplatform.v1.AnalyzedSession prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Represents an analyzed session for a monitored agent.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.AnalyzedSession} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.AnalyzedSession) + com.google.cloud.aiplatform.v1.AnalyzedSessionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedSession_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 8: + return internalGetSeverities(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( + int number) { + switch (number) { + case 8: + return internalGetMutableSeverities(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedSession_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.AnalyzedSession.class, + com.google.cloud.aiplatform.v1.AnalyzedSession.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.AnalyzedSession.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetCreateTimeFieldBuilder(); + internalGetLatestAnalyzedTimeFieldBuilder(); + internalGetAssessmentFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + sessionId_ = ""; + userId_ = ""; + agentResourceName_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + latestAnalyzedTime_ = null; + if (latestAnalyzedTimeBuilder_ != null) { + latestAnalyzedTimeBuilder_.dispose(); + latestAnalyzedTimeBuilder_ = null; + } + assessment_ = null; + if (assessmentBuilder_ != null) { + assessmentBuilder_.dispose(); + assessmentBuilder_ = null; + } + internalGetMutableSeverities().clear(); + sessionState_ = 0; + agentDisplayName_ = ""; + agentState_ = 0; + location_ = ""; + agentType_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_AnalyzedSession_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.AnalyzedSession.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession build() { + com.google.cloud.aiplatform.v1.AnalyzedSession result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession buildPartial() { + com.google.cloud.aiplatform.v1.AnalyzedSession result = + new com.google.cloud.aiplatform.v1.AnalyzedSession(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.AnalyzedSession result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.sessionId_ = sessionId_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.userId_ = userId_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.agentResourceName_ = agentResourceName_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000010) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.latestAnalyzedTime_ = + latestAnalyzedTimeBuilder_ == null + ? latestAnalyzedTime_ + : latestAnalyzedTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.assessment_ = assessmentBuilder_ == null ? assessment_ : assessmentBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.severities_ = + internalGetSeverities().build(SeveritiesDefaultEntryHolder.defaultEntry); + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.sessionState_ = sessionState_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.agentDisplayName_ = agentDisplayName_; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + result.agentState_ = agentState_; + } + if (((from_bitField0_ & 0x00000800) != 0)) { + result.location_ = location_; + } + if (((from_bitField0_ & 0x00001000) != 0)) { + result.agentType_ = agentType_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.AnalyzedSession) { + return mergeFrom((com.google.cloud.aiplatform.v1.AnalyzedSession) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.AnalyzedSession other) { + if (other == com.google.cloud.aiplatform.v1.AnalyzedSession.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getSessionId().isEmpty()) { + sessionId_ = other.sessionId_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getUserId().isEmpty()) { + userId_ = other.userId_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getAgentResourceName().isEmpty()) { + agentResourceName_ = other.agentResourceName_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasLatestAnalyzedTime()) { + mergeLatestAnalyzedTime(other.getLatestAnalyzedTime()); + } + if (other.hasAssessment()) { + mergeAssessment(other.getAssessment()); + } + internalGetMutableSeverities().mergeFrom(other.internalGetSeverities()); + bitField0_ |= 0x00000080; + if (other.sessionState_ != 0) { + setSessionStateValue(other.getSessionStateValue()); + } + if (!other.getAgentDisplayName().isEmpty()) { + agentDisplayName_ = other.agentDisplayName_; + bitField0_ |= 0x00000200; + onChanged(); + } + if (other.agentState_ != 0) { + setAgentStateValue(other.getAgentStateValue()); + } + if (!other.getLocation().isEmpty()) { + location_ = other.location_; + bitField0_ |= 0x00000800; + onChanged(); + } + if (other.agentType_ != 0) { + setAgentTypeValue(other.getAgentTypeValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + sessionId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + userId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + agentResourceName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + input.readMessage( + internalGetLatestAnalyzedTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + case 58: + { + input.readMessage( + internalGetAssessmentFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000040; + break; + } // case 58 + case 66: + { + com.google.protobuf.MapEntry< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + severities__ = + input.readMessage( + SeveritiesDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableSeverities() + .ensureBuilderMap() + .put(severities__.getKey(), severities__.getValue()); + bitField0_ |= 0x00000080; + break; + } // case 66 + case 72: + { + sessionState_ = input.readEnum(); + bitField0_ |= 0x00000100; + break; + } // case 72 + case 82: + { + agentDisplayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000200; + break; + } // case 82 + case 88: + { + agentState_ = input.readEnum(); + bitField0_ |= 0x00000400; + break; + } // case 88 + case 98: + { + location_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000800; + break; + } // case 98 + case 104: + { + agentType_ = input.readEnum(); + bitField0_ |= 0x00001000; + break; + } // case 104 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Identifier. The resource name of the AnalyzedSession.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Identifier. The resource name of the AnalyzedSession.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Identifier. The resource name of the AnalyzedSession.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. The resource name of the AnalyzedSession.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. The resource name of the AnalyzedSession.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object sessionId_ = ""; + + /** + * + * + *
+     * Output only. The session ID.
+     * 
+ * + * string session_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sessionId. + */ + public java.lang.String getSessionId() { + java.lang.Object ref = sessionId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sessionId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. The session ID.
+     * 
+ * + * string session_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for sessionId. + */ + public com.google.protobuf.ByteString getSessionIdBytes() { + java.lang.Object ref = sessionId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sessionId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. The session ID.
+     * 
+ * + * string session_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The sessionId to set. + * @return This builder for chaining. + */ + public Builder setSessionId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sessionId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The session ID.
+     * 
+ * + * string session_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearSessionId() { + sessionId_ = getDefaultInstance().getSessionId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The session ID.
+     * 
+ * + * string session_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for sessionId to set. + * @return This builder for chaining. + */ + public Builder setSessionIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sessionId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object userId_ = ""; + + /** + * + * + *
+     * Output only. The user ID.
+     * 
+ * + * string user_id = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The userId. + */ + public java.lang.String getUserId() { + java.lang.Object ref = userId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + userId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. The user ID.
+     * 
+ * + * string user_id = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for userId. + */ + public com.google.protobuf.ByteString getUserIdBytes() { + java.lang.Object ref = userId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + userId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. The user ID.
+     * 
+ * + * string user_id = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The userId to set. + * @return This builder for chaining. + */ + public Builder setUserId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + userId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The user ID.
+     * 
+ * + * string user_id = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearUserId() { + userId_ = getDefaultInstance().getUserId(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The user ID.
+     * 
+ * + * string user_id = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for userId to set. + * @return This builder for chaining. + */ + public Builder setUserIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + userId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object agentResourceName_ = ""; + + /** + * + * + *
+     * Output only. The resource name or identifier of the agent that ran this
+     * session. Matches `AgentResource.agent` on the corresponding
+     * `MonitoredAgent`, so the format depends on that agent's
+     * `AgentResource.agent_type`. For the format of each agent type, see
+     * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+     * 
+ * + * + * string agent_resource_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The agentResourceName. + */ + public java.lang.String getAgentResourceName() { + java.lang.Object ref = agentResourceName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agentResourceName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. The resource name or identifier of the agent that ran this
+     * session. Matches `AgentResource.agent` on the corresponding
+     * `MonitoredAgent`, so the format depends on that agent's
+     * `AgentResource.agent_type`. For the format of each agent type, see
+     * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+     * 
+ * + * + * string agent_resource_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for agentResourceName. + */ + public com.google.protobuf.ByteString getAgentResourceNameBytes() { + java.lang.Object ref = agentResourceName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agentResourceName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. The resource name or identifier of the agent that ran this
+     * session. Matches `AgentResource.agent` on the corresponding
+     * `MonitoredAgent`, so the format depends on that agent's
+     * `AgentResource.agent_type`. For the format of each agent type, see
+     * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+     * 
+ * + * + * string agent_resource_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The agentResourceName to set. + * @return This builder for chaining. + */ + public Builder setAgentResourceName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + agentResourceName_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The resource name or identifier of the agent that ran this
+     * session. Matches `AgentResource.agent` on the corresponding
+     * `MonitoredAgent`, so the format depends on that agent's
+     * `AgentResource.agent_type`. For the format of each agent type, see
+     * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+     * 
+ * + * + * string agent_resource_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearAgentResourceName() { + agentResourceName_ = getDefaultInstance().getAgentResourceName(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The resource name or identifier of the agent that ran this
+     * session. Matches `AgentResource.agent` on the corresponding
+     * `MonitoredAgent`, so the format depends on that agent's
+     * `AgentResource.agent_type`. For the format of each agent type, see
+     * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+     * 
+ * + * + * string agent_resource_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for agentResourceName to set. + * @return This builder for chaining. + */ + public Builder setAgentResourceNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + agentResourceName_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
+     * Output only. The creation time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
+     * Output only. The creation time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. The creation time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The creation time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The creation time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. The creation time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000010); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The creation time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. The creation time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
+     * Output only. The creation time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp latestAnalyzedTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + latestAnalyzedTimeBuilder_; + + /** + * + * + *
+     * Output only. The latest analyzed time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the latestAnalyzedTime field is set. + */ + public boolean hasLatestAnalyzedTime() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
+     * Output only. The latest analyzed time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The latestAnalyzedTime. + */ + public com.google.protobuf.Timestamp getLatestAnalyzedTime() { + if (latestAnalyzedTimeBuilder_ == null) { + return latestAnalyzedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : latestAnalyzedTime_; + } else { + return latestAnalyzedTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. The latest analyzed time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setLatestAnalyzedTime(com.google.protobuf.Timestamp value) { + if (latestAnalyzedTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + latestAnalyzedTime_ = value; + } else { + latestAnalyzedTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The latest analyzed time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setLatestAnalyzedTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (latestAnalyzedTimeBuilder_ == null) { + latestAnalyzedTime_ = builderForValue.build(); + } else { + latestAnalyzedTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The latest analyzed time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeLatestAnalyzedTime(com.google.protobuf.Timestamp value) { + if (latestAnalyzedTimeBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && latestAnalyzedTime_ != null + && latestAnalyzedTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getLatestAnalyzedTimeBuilder().mergeFrom(value); + } else { + latestAnalyzedTime_ = value; + } + } else { + latestAnalyzedTimeBuilder_.mergeFrom(value); + } + if (latestAnalyzedTime_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. The latest analyzed time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearLatestAnalyzedTime() { + bitField0_ = (bitField0_ & ~0x00000020); + latestAnalyzedTime_ = null; + if (latestAnalyzedTimeBuilder_ != null) { + latestAnalyzedTimeBuilder_.dispose(); + latestAnalyzedTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The latest analyzed time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getLatestAnalyzedTimeBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetLatestAnalyzedTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. The latest analyzed time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getLatestAnalyzedTimeOrBuilder() { + if (latestAnalyzedTimeBuilder_ != null) { + return latestAnalyzedTimeBuilder_.getMessageOrBuilder(); + } else { + return latestAnalyzedTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : latestAnalyzedTime_; + } + } + + /** + * + * + *
+     * Output only. The latest analyzed time of the session.
+     * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetLatestAnalyzedTimeFieldBuilder() { + if (latestAnalyzedTimeBuilder_ == null) { + latestAnalyzedTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLatestAnalyzedTime(), getParentForChildren(), isClean()); + latestAnalyzedTime_ = null; + } + return latestAnalyzedTimeBuilder_; + } + + private com.google.cloud.aiplatform.v1.Assessment assessment_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.Assessment, + com.google.cloud.aiplatform.v1.Assessment.Builder, + com.google.cloud.aiplatform.v1.AssessmentOrBuilder> + assessmentBuilder_; + + /** + * + * + *
+     * Output only. Overall security assessment. Populated only in FULL view.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the assessment field is set. + */ + public boolean hasAssessment() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
+     * Output only. Overall security assessment. Populated only in FULL view.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The assessment. + */ + public com.google.cloud.aiplatform.v1.Assessment getAssessment() { + if (assessmentBuilder_ == null) { + return assessment_ == null + ? com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance() + : assessment_; + } else { + return assessmentBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. Overall security assessment. Populated only in FULL view.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setAssessment(com.google.cloud.aiplatform.v1.Assessment value) { + if (assessmentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + assessment_ = value; + } else { + assessmentBuilder_.setMessage(value); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Overall security assessment. Populated only in FULL view.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setAssessment( + com.google.cloud.aiplatform.v1.Assessment.Builder builderForValue) { + if (assessmentBuilder_ == null) { + assessment_ = builderForValue.build(); + } else { + assessmentBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Overall security assessment. Populated only in FULL view.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeAssessment(com.google.cloud.aiplatform.v1.Assessment value) { + if (assessmentBuilder_ == null) { + if (((bitField0_ & 0x00000040) != 0) + && assessment_ != null + && assessment_ != com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance()) { + getAssessmentBuilder().mergeFrom(value); + } else { + assessment_ = value; + } + } else { + assessmentBuilder_.mergeFrom(value); + } + if (assessment_ != null) { + bitField0_ |= 0x00000040; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. Overall security assessment. Populated only in FULL view.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearAssessment() { + bitField0_ = (bitField0_ & ~0x00000040); + assessment_ = null; + if (assessmentBuilder_ != null) { + assessmentBuilder_.dispose(); + assessmentBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. Overall security assessment. Populated only in FULL view.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.aiplatform.v1.Assessment.Builder getAssessmentBuilder() { + bitField0_ |= 0x00000040; + onChanged(); + return internalGetAssessmentFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. Overall security assessment. Populated only in FULL view.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.aiplatform.v1.AssessmentOrBuilder getAssessmentOrBuilder() { + if (assessmentBuilder_ != null) { + return assessmentBuilder_.getMessageOrBuilder(); + } else { + return assessment_ == null + ? com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance() + : assessment_; + } + } + + /** + * + * + *
+     * Output only. Overall security assessment. Populated only in FULL view.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.Assessment, + com.google.cloud.aiplatform.v1.Assessment.Builder, + com.google.cloud.aiplatform.v1.AssessmentOrBuilder> + internalGetAssessmentFieldBuilder() { + if (assessmentBuilder_ == null) { + assessmentBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.Assessment, + com.google.cloud.aiplatform.v1.Assessment.Builder, + com.google.cloud.aiplatform.v1.AssessmentOrBuilder>( + getAssessment(), getParentForChildren(), isClean()); + assessment_ = null; + } + return assessmentBuilder_; + } + + private static final class SeveritiesConverter + implements com.google.protobuf.MapFieldBuilder.Converter< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> { + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary build( + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder val) { + if (val instanceof com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) { + return (com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) val; + } + return ((com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder) val) + .build(); + } + + @java.lang.Override + public com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + defaultEntry() { + return SeveritiesDefaultEntryHolder.defaultEntry; + } + } + ; + + private static final SeveritiesConverter severitiesConverter = new SeveritiesConverter(); + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder> + severities_; + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder> + internalGetSeverities() { + if (severities_ == null) { + return new com.google.protobuf.MapFieldBuilder<>(severitiesConverter); + } + return severities_; + } + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder> + internalGetMutableSeverities() { + if (severities_ == null) { + severities_ = new com.google.protobuf.MapFieldBuilder<>(severitiesConverter); + } + bitField0_ |= 0x00000080; + onChanged(); + return severities_; + } + + public int getSeveritiesCount() { + return internalGetSeverities().ensureBuilderMap().size(); + } + + /** + * + * + *
+     * Output only. Map of the detectors that flagged this session, grouped by
+     * severity. The key is the string representation of `Severity`. Populated
+     * only for flagged sessions, in both views. In
+     * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+     * responses, the map holds only the session's highest severity.
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public boolean containsSeverities(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetSeverities().ensureBuilderMap().containsKey(key); + } + + /** Use {@link #getSeveritiesMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeverities() { + return getSeveritiesMap(); + } + + /** + * + * + *
+     * Output only. Map of the detectors that flagged this session, grouped by
+     * severity. The key is the string representation of `Severity`. Populated
+     * only for flagged sessions, in both views. In
+     * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+     * responses, the map holds only the session's highest severity.
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeveritiesMap() { + return internalGetSeverities().getImmutableMap(); + } + + /** + * + * + *
+     * Output only. Map of the detectors that flagged this session, grouped by
+     * severity. The key is the string representation of `Severity`. Populated
+     * only for flagged sessions, in both views. In
+     * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+     * responses, the map holds only the session's highest severity.
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public /* nullable */ com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + getSeveritiesOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder> + map = internalGetMutableSeverities().ensureBuilderMap(); + return map.containsKey(key) ? severitiesConverter.build(map.get(key)) : defaultValue; + } + + /** + * + * + *
+     * Output only. Map of the detectors that flagged this session, grouped by
+     * severity. The key is the string representation of `Severity`. Populated
+     * only for flagged sessions, in both views. In
+     * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+     * responses, the map holds only the session's highest severity.
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrThrow( + java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder> + map = internalGetMutableSeverities().ensureBuilderMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return severitiesConverter.build(map.get(key)); + } + + public Builder clearSeverities() { + bitField0_ = (bitField0_ & ~0x00000080); + internalGetMutableSeverities().clear(); + return this; + } + + /** + * + * + *
+     * Output only. Map of the detectors that flagged this session, grouped by
+     * severity. The key is the string representation of `Severity`. Populated
+     * only for flagged sessions, in both views. In
+     * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+     * responses, the map holds only the session's highest severity.
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder removeSeverities(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableSeverities().ensureBuilderMap().remove(key); + return this; + } + + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getMutableSeverities() { + bitField0_ |= 0x00000080; + return internalGetMutableSeverities().ensureMessageMap(); + } + + /** + * + * + *
+     * Output only. Map of the detectors that flagged this session, grouped by
+     * severity. The key is the string representation of `Severity`. Populated
+     * only for flagged sessions, in both views. In
+     * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+     * responses, the map holds only the session's highest severity.
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder putSeverities( + java.lang.String key, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + internalGetMutableSeverities().ensureBuilderMap().put(key, value); + bitField0_ |= 0x00000080; + return this; + } + + /** + * + * + *
+     * Output only. Map of the detectors that flagged this session, grouped by
+     * severity. The key is the string representation of `Severity`. Populated
+     * only for flagged sessions, in both views. In
+     * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+     * responses, the map holds only the session's highest severity.
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder putAllSeverities( + java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + values) { + for (java.util.Map.Entry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + e : values.entrySet()) { + if (e.getKey() == null || e.getValue() == null) { + throw new NullPointerException(); + } + } + internalGetMutableSeverities().ensureBuilderMap().putAll(values); + bitField0_ |= 0x00000080; + return this; + } + + /** + * + * + *
+     * Output only. Map of the detectors that flagged this session, grouped by
+     * severity. The key is the string representation of `Severity`. Populated
+     * only for flagged sessions, in both views. In
+     * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+     * responses, the map holds only the session's highest severity.
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder + putSeveritiesBuilderIfAbsent(java.lang.String key) { + java.util.Map< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder> + builderMap = internalGetMutableSeverities().ensureBuilderMap(); + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder entry = + builderMap.get(key); + if (entry == null) { + entry = com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.newBuilder(); + builderMap.put(key, entry); + } + if (entry instanceof com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) { + entry = + ((com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) entry).toBuilder(); + builderMap.put(key, entry); + } + return (com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder) entry; + } + + private int sessionState_ = 0; + + /** + * + * + *
+     * Output only. The state of the session.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSession.SessionState session_state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for sessionState. + */ + @java.lang.Override + public int getSessionStateValue() { + return sessionState_; + } + + /** + * + * + *
+     * Output only. The state of the session.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSession.SessionState session_state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for sessionState to set. + * @return This builder for chaining. + */ + public Builder setSessionStateValue(int value) { + sessionState_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The state of the session.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSession.SessionState session_state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The sessionState. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState getSessionState() { + com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState result = + com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState.forNumber(sessionState_); + return result == null + ? com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Output only. The state of the session.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSession.SessionState session_state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The sessionState to set. + * @return This builder for chaining. + */ + public Builder setSessionState( + com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000100; + sessionState_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The state of the session.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSession.SessionState session_state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearSessionState() { + bitField0_ = (bitField0_ & ~0x00000100); + sessionState_ = 0; + onChanged(); + return this; + } + + private java.lang.Object agentDisplayName_ = ""; + + /** + * + * + *
+     * Output only. The human-readable display name of the MonitoredAgent that
+     * owns this session. May be empty when the session's agent is not enrolled
+     * as a MonitoredAgent; the `agent_resource_name` is always present and can
+     * be used as a fallback identifier.
+     * 
+ * + * string agent_display_name = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The agentDisplayName. + */ + public java.lang.String getAgentDisplayName() { + java.lang.Object ref = agentDisplayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agentDisplayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. The human-readable display name of the MonitoredAgent that
+     * owns this session. May be empty when the session's agent is not enrolled
+     * as a MonitoredAgent; the `agent_resource_name` is always present and can
+     * be used as a fallback identifier.
+     * 
+ * + * string agent_display_name = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for agentDisplayName. + */ + public com.google.protobuf.ByteString getAgentDisplayNameBytes() { + java.lang.Object ref = agentDisplayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agentDisplayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. The human-readable display name of the MonitoredAgent that
+     * owns this session. May be empty when the session's agent is not enrolled
+     * as a MonitoredAgent; the `agent_resource_name` is always present and can
+     * be used as a fallback identifier.
+     * 
+ * + * string agent_display_name = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The agentDisplayName to set. + * @return This builder for chaining. + */ + public Builder setAgentDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + agentDisplayName_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The human-readable display name of the MonitoredAgent that
+     * owns this session. May be empty when the session's agent is not enrolled
+     * as a MonitoredAgent; the `agent_resource_name` is always present and can
+     * be used as a fallback identifier.
+     * 
+ * + * string agent_display_name = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearAgentDisplayName() { + agentDisplayName_ = getDefaultInstance().getAgentDisplayName(); + bitField0_ = (bitField0_ & ~0x00000200); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The human-readable display name of the MonitoredAgent that
+     * owns this session. May be empty when the session's agent is not enrolled
+     * as a MonitoredAgent; the `agent_resource_name` is always present and can
+     * be used as a fallback identifier.
+     * 
+ * + * string agent_display_name = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for agentDisplayName to set. + * @return This builder for chaining. + */ + public Builder setAgentDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + agentDisplayName_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + private int agentState_ = 0; + + /** + * + * + *
+     * Output only. The current enablement state of the MonitoredAgent that owns
+     * this session (for example, ACTIVE, DISABLED, or ENABLING). Defaults to
+     * ENABLEMENT_STATE_UNSPECIFIED when the agent is not enrolled or its state
+     * is unknown.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_state = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentState. + */ + @java.lang.Override + public int getAgentStateValue() { + return agentState_; + } + + /** + * + * + *
+     * Output only. The current enablement state of the MonitoredAgent that owns
+     * this session (for example, ACTIVE, DISABLED, or ENABLING). Defaults to
+     * ENABLEMENT_STATE_UNSPECIFIED when the agent is not enrolled or its state
+     * is unknown.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_state = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for agentState to set. + * @return This builder for chaining. + */ + public Builder setAgentStateValue(int value) { + agentState_ = value; + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The current enablement state of the MonitoredAgent that owns
+     * this session (for example, ACTIVE, DISABLED, or ENABLING). Defaults to
+     * ENABLEMENT_STATE_UNSPECIFIED when the agent is not enrolled or its state
+     * is unknown.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_state = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentState. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState getAgentState() { + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState result = + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.forNumber(agentState_); + return result == null + ? com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Output only. The current enablement state of the MonitoredAgent that owns
+     * this session (for example, ACTIVE, DISABLED, or ENABLING). Defaults to
+     * ENABLEMENT_STATE_UNSPECIFIED when the agent is not enrolled or its state
+     * is unknown.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_state = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The agentState to set. + * @return This builder for chaining. + */ + public Builder setAgentState( + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000400; + agentState_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The current enablement state of the MonitoredAgent that owns
+     * this session (for example, ACTIVE, DISABLED, or ENABLING). Defaults to
+     * ENABLEMENT_STATE_UNSPECIFIED when the agent is not enrolled or its state
+     * is unknown.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_state = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearAgentState() { + bitField0_ = (bitField0_ & ~0x00000400); + agentState_ = 0; + onChanged(); + return this; + } + + private java.lang.Object location_ = ""; + + /** + * + * + *
+     * Output only. The region of the agent that ran this session, in the same
+     * form as `AgentResource.location` (for example, `us-central1`). Empty when
+     * the agent is not enrolled or its location is unknown.
+     * 
+ * + * string location = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The location. + */ + public java.lang.String getLocation() { + java.lang.Object ref = location_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + location_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. The region of the agent that ran this session, in the same
+     * form as `AgentResource.location` (for example, `us-central1`). Empty when
+     * the agent is not enrolled or its location is unknown.
+     * 
+ * + * string location = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for location. + */ + public com.google.protobuf.ByteString getLocationBytes() { + java.lang.Object ref = location_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + location_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. The region of the agent that ran this session, in the same
+     * form as `AgentResource.location` (for example, `us-central1`). Empty when
+     * the agent is not enrolled or its location is unknown.
+     * 
+ * + * string location = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The location to set. + * @return This builder for chaining. + */ + public Builder setLocation(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + location_ = value; + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The region of the agent that ran this session, in the same
+     * form as `AgentResource.location` (for example, `us-central1`). Empty when
+     * the agent is not enrolled or its location is unknown.
+     * 
+ * + * string location = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearLocation() { + location_ = getDefaultInstance().getLocation(); + bitField0_ = (bitField0_ & ~0x00000800); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The region of the agent that ran this session, in the same
+     * form as `AgentResource.location` (for example, `us-central1`). Empty when
+     * the agent is not enrolled or its location is unknown.
+     * 
+ * + * string location = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for location to set. + * @return This builder for chaining. + */ + public Builder setLocationBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + location_ = value; + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + private int agentType_ = 0; + + /** + * + * + *
+     * Output only. The runtime that the agent which ran this session is hosted
+     * on (for example, `CLOUD_RUN_SERVICE`).
+     *
+     * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service --
+     * the agent is not enrolled as a `MonitoredAgent`, or was enrolled before its
+     * runtime was recorded. That is distinct from `AGENT_TYPE_OTHER`, which means
+     * the runtime is known and is not one of the other enumerated runtimes.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentType. + */ + @java.lang.Override + public int getAgentTypeValue() { + return agentType_; + } + + /** + * + * + *
+     * Output only. The runtime that the agent which ran this session is hosted
+     * on (for example, `CLOUD_RUN_SERVICE`).
+     *
+     * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service --
+     * the agent is not enrolled as a `MonitoredAgent`, or was enrolled before its
+     * runtime was recorded. That is distinct from `AGENT_TYPE_OTHER`, which means
+     * the runtime is known and is not one of the other enumerated runtimes.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for agentType to set. + * @return This builder for chaining. + */ + public Builder setAgentTypeValue(int value) { + agentType_ = value; + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The runtime that the agent which ran this session is hosted
+     * on (for example, `CLOUD_RUN_SERVICE`).
+     *
+     * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service --
+     * the agent is not enrolled as a `MonitoredAgent`, or was enrolled before its
+     * runtime was recorded. That is distinct from `AGENT_TYPE_OTHER`, which means
+     * the runtime is known and is not one of the other enumerated runtimes.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentType. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource.AgentType getAgentType() { + com.google.cloud.aiplatform.v1.AgentResource.AgentType result = + com.google.cloud.aiplatform.v1.AgentResource.AgentType.forNumber(agentType_); + return result == null + ? com.google.cloud.aiplatform.v1.AgentResource.AgentType.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Output only. The runtime that the agent which ran this session is hosted
+     * on (for example, `CLOUD_RUN_SERVICE`).
+     *
+     * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service --
+     * the agent is not enrolled as a `MonitoredAgent`, or was enrolled before its
+     * runtime was recorded. That is distinct from `AGENT_TYPE_OTHER`, which means
+     * the runtime is known and is not one of the other enumerated runtimes.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The agentType to set. + * @return This builder for chaining. + */ + public Builder setAgentType(com.google.cloud.aiplatform.v1.AgentResource.AgentType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00001000; + agentType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The runtime that the agent which ran this session is hosted
+     * on (for example, `CLOUD_RUN_SERVICE`).
+     *
+     * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service --
+     * the agent is not enrolled as a `MonitoredAgent`, or was enrolled before its
+     * runtime was recorded. That is distinct from `AGENT_TYPE_OTHER`, which means
+     * the runtime is known and is not one of the other enumerated runtimes.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearAgentType() { + bitField0_ = (bitField0_ & ~0x00001000); + agentType_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.AnalyzedSession) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.AnalyzedSession) + private static final com.google.cloud.aiplatform.v1.AnalyzedSession DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.AnalyzedSession(); + } + + public static com.google.cloud.aiplatform.v1.AnalyzedSession getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AnalyzedSession parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSessionName.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSessionName.java new file mode 100644 index 000000000000..2a7288a0aa37 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSessionName.java @@ -0,0 +1,272 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class AnalyzedSessionName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_MONITORED_AGENT_ANALYZED_SESSION = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String monitoredAgent; + private final String analyzedSession; + + @Deprecated + protected AnalyzedSessionName() { + project = null; + location = null; + monitoredAgent = null; + analyzedSession = null; + } + + private AnalyzedSessionName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + monitoredAgent = Preconditions.checkNotNull(builder.getMonitoredAgent()); + analyzedSession = Preconditions.checkNotNull(builder.getAnalyzedSession()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getMonitoredAgent() { + return monitoredAgent; + } + + public String getAnalyzedSession() { + return analyzedSession; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static AnalyzedSessionName of( + String project, String location, String monitoredAgent, String analyzedSession) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setMonitoredAgent(monitoredAgent) + .setAnalyzedSession(analyzedSession) + .build(); + } + + public static String format( + String project, String location, String monitoredAgent, String analyzedSession) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setMonitoredAgent(monitoredAgent) + .setAnalyzedSession(analyzedSession) + .build() + .toString(); + } + + public static @Nullable AnalyzedSessionName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_MONITORED_AGENT_ANALYZED_SESSION.validatedMatch( + formattedString, "AnalyzedSessionName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("monitored_agent"), + matchMap.get("analyzed_session")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable AnalyzedSessionName> values) { + List list = new ArrayList<>(values.size()); + for (AnalyzedSessionName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_MONITORED_AGENT_ANALYZED_SESSION.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (monitoredAgent != null) { + fieldMapBuilder.put("monitored_agent", monitoredAgent); + } + if (analyzedSession != null) { + fieldMapBuilder.put("analyzed_session", analyzedSession); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_MONITORED_AGENT_ANALYZED_SESSION.instantiate( + "project", + project, + "location", + location, + "monitored_agent", + monitoredAgent, + "analyzed_session", + analyzedSession); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + AnalyzedSessionName that = ((AnalyzedSessionName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.monitoredAgent, that.monitoredAgent) + && Objects.equals(this.analyzedSession, that.analyzedSession); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(monitoredAgent); + h *= 1000003; + h ^= Objects.hashCode(analyzedSession); + return h; + } + + /** + * Builder for + * projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}. + */ + public static class Builder { + private String project; + private String location; + private String monitoredAgent; + private String analyzedSession; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getMonitoredAgent() { + return monitoredAgent; + } + + public String getAnalyzedSession() { + return analyzedSession; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setMonitoredAgent(String monitoredAgent) { + this.monitoredAgent = monitoredAgent; + return this; + } + + public Builder setAnalyzedSession(String analyzedSession) { + this.analyzedSession = analyzedSession; + return this; + } + + private Builder(AnalyzedSessionName analyzedSessionName) { + this.project = analyzedSessionName.project; + this.location = analyzedSessionName.location; + this.monitoredAgent = analyzedSessionName.monitoredAgent; + this.analyzedSession = analyzedSessionName.analyzedSession; + } + + public AnalyzedSessionName build() { + return new AnalyzedSessionName(this); + } + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSessionOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSessionOrBuilder.java new file mode 100644 index 000000000000..688353e5bcad --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSessionOrBuilder.java @@ -0,0 +1,536 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface AnalyzedSessionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.AnalyzedSession) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Identifier. The resource name of the AnalyzedSession.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Identifier. The resource name of the AnalyzedSession.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Output only. The session ID.
+   * 
+ * + * string session_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The sessionId. + */ + java.lang.String getSessionId(); + + /** + * + * + *
+   * Output only. The session ID.
+   * 
+ * + * string session_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for sessionId. + */ + com.google.protobuf.ByteString getSessionIdBytes(); + + /** + * + * + *
+   * Output only. The user ID.
+   * 
+ * + * string user_id = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The userId. + */ + java.lang.String getUserId(); + + /** + * + * + *
+   * Output only. The user ID.
+   * 
+ * + * string user_id = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for userId. + */ + com.google.protobuf.ByteString getUserIdBytes(); + + /** + * + * + *
+   * Output only. The resource name or identifier of the agent that ran this
+   * session. Matches `AgentResource.agent` on the corresponding
+   * `MonitoredAgent`, so the format depends on that agent's
+   * `AgentResource.agent_type`. For the format of each agent type, see
+   * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+   * 
+ * + * + * string agent_resource_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The agentResourceName. + */ + java.lang.String getAgentResourceName(); + + /** + * + * + *
+   * Output only. The resource name or identifier of the agent that ran this
+   * session. Matches `AgentResource.agent` on the corresponding
+   * `MonitoredAgent`, so the format depends on that agent's
+   * `AgentResource.agent_type`. For the format of each agent type, see
+   * [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent].
+   * 
+ * + * + * string agent_resource_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for agentResourceName. + */ + com.google.protobuf.ByteString getAgentResourceNameBytes(); + + /** + * + * + *
+   * Output only. The creation time of the session.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
+   * Output only. The creation time of the session.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
+   * Output only. The creation time of the session.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. The latest analyzed time of the session.
+   * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the latestAnalyzedTime field is set. + */ + boolean hasLatestAnalyzedTime(); + + /** + * + * + *
+   * Output only. The latest analyzed time of the session.
+   * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The latestAnalyzedTime. + */ + com.google.protobuf.Timestamp getLatestAnalyzedTime(); + + /** + * + * + *
+   * Output only. The latest analyzed time of the session.
+   * 
+ * + * + * .google.protobuf.Timestamp latest_analyzed_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getLatestAnalyzedTimeOrBuilder(); + + /** + * + * + *
+   * Output only. Overall security assessment. Populated only in FULL view.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the assessment field is set. + */ + boolean hasAssessment(); + + /** + * + * + *
+   * Output only. Overall security assessment. Populated only in FULL view.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The assessment. + */ + com.google.cloud.aiplatform.v1.Assessment getAssessment(); + + /** + * + * + *
+   * Output only. Overall security assessment. Populated only in FULL view.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.Assessment assessment = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.aiplatform.v1.AssessmentOrBuilder getAssessmentOrBuilder(); + + /** + * + * + *
+   * Output only. Map of the detectors that flagged this session, grouped by
+   * severity. The key is the string representation of `Severity`. Populated
+   * only for flagged sessions, in both views. In
+   * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+   * responses, the map holds only the session's highest severity.
+   * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + int getSeveritiesCount(); + + /** + * + * + *
+   * Output only. Map of the detectors that flagged this session, grouped by
+   * severity. The key is the string representation of `Severity`. Populated
+   * only for flagged sessions, in both views. In
+   * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+   * responses, the map holds only the session's highest severity.
+   * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + boolean containsSeverities(java.lang.String key); + + /** Use {@link #getSeveritiesMap()} instead. */ + @java.lang.Deprecated + java.util.Map + getSeverities(); + + /** + * + * + *
+   * Output only. Map of the detectors that flagged this session, grouped by
+   * severity. The key is the string representation of `Severity`. Populated
+   * only for flagged sessions, in both views. In
+   * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+   * responses, the map holds only the session's highest severity.
+   * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.Map + getSeveritiesMap(); + + /** + * + * + *
+   * Output only. Map of the detectors that flagged this session, grouped by
+   * severity. The key is the string representation of `Severity`. Populated
+   * only for flagged sessions, in both views. In
+   * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+   * responses, the map holds only the session's highest severity.
+   * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary defaultValue); + + /** + * + * + *
+   * Output only. Map of the detectors that flagged this session, grouped by
+   * severity. The key is the string representation of `Severity`. Populated
+   * only for flagged sessions, in both views. In
+   * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+   * responses, the map holds only the session's highest severity.
+   * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrThrow( + java.lang.String key); + + /** + * + * + *
+   * Output only. The state of the session.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSession.SessionState session_state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for sessionState. + */ + int getSessionStateValue(); + + /** + * + * + *
+   * Output only. The state of the session.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSession.SessionState session_state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The sessionState. + */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SessionState getSessionState(); + + /** + * + * + *
+   * Output only. The human-readable display name of the MonitoredAgent that
+   * owns this session. May be empty when the session's agent is not enrolled
+   * as a MonitoredAgent; the `agent_resource_name` is always present and can
+   * be used as a fallback identifier.
+   * 
+ * + * string agent_display_name = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The agentDisplayName. + */ + java.lang.String getAgentDisplayName(); + + /** + * + * + *
+   * Output only. The human-readable display name of the MonitoredAgent that
+   * owns this session. May be empty when the session's agent is not enrolled
+   * as a MonitoredAgent; the `agent_resource_name` is always present and can
+   * be used as a fallback identifier.
+   * 
+ * + * string agent_display_name = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for agentDisplayName. + */ + com.google.protobuf.ByteString getAgentDisplayNameBytes(); + + /** + * + * + *
+   * Output only. The current enablement state of the MonitoredAgent that owns
+   * this session (for example, ACTIVE, DISABLED, or ENABLING). Defaults to
+   * ENABLEMENT_STATE_UNSPECIFIED when the agent is not enrolled or its state
+   * is unknown.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_state = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentState. + */ + int getAgentStateValue(); + + /** + * + * + *
+   * Output only. The current enablement state of the MonitoredAgent that owns
+   * this session (for example, ACTIVE, DISABLED, or ENABLING). Defaults to
+   * ENABLEMENT_STATE_UNSPECIFIED when the agent is not enrolled or its state
+   * is unknown.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState agent_state = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentState. + */ + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState getAgentState(); + + /** + * + * + *
+   * Output only. The region of the agent that ran this session, in the same
+   * form as `AgentResource.location` (for example, `us-central1`). Empty when
+   * the agent is not enrolled or its location is unknown.
+   * 
+ * + * string location = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The location. + */ + java.lang.String getLocation(); + + /** + * + * + *
+   * Output only. The region of the agent that ran this session, in the same
+   * form as `AgentResource.location` (for example, `us-central1`). Empty when
+   * the agent is not enrolled or its location is unknown.
+   * 
+ * + * string location = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for location. + */ + com.google.protobuf.ByteString getLocationBytes(); + + /** + * + * + *
+   * Output only. The runtime that the agent which ran this session is hosted
+   * on (for example, `CLOUD_RUN_SERVICE`).
+   *
+   * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service --
+   * the agent is not enrolled as a `MonitoredAgent`, or was enrolled before its
+   * runtime was recorded. That is distinct from `AGENT_TYPE_OTHER`, which means
+   * the runtime is known and is not one of the other enumerated runtimes.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for agentType. + */ + int getAgentTypeValue(); + + /** + * + * + *
+   * Output only. The runtime that the agent which ran this session is hosted
+   * on (for example, `CLOUD_RUN_SERVICE`).
+   *
+   * `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service --
+   * the agent is not enrolled as a `MonitoredAgent`, or was enrolled before its
+   * runtime was recorded. That is distinct from `AGENT_TYPE_OTHER`, which means
+   * the runtime is known and is not one of the other enumerated runtimes.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource.AgentType agent_type = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The agentType. + */ + com.google.cloud.aiplatform.v1.AgentResource.AgentType getAgentType(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSessionView.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSessionView.java new file mode 100644 index 000000000000..2ca21f28466e --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AnalyzedSessionView.java @@ -0,0 +1,204 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * The view options for AnalyzedSession.
+ * 
+ * + * Protobuf enum {@code google.cloud.aiplatform.v1.AnalyzedSessionView} + */ +@com.google.protobuf.Generated +public enum AnalyzedSessionView implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * The default view: BASIC.
+   * 
+ * + * ANALYZED_SESSION_VIEW_UNSPECIFIED = 0; + */ + ANALYZED_SESSION_VIEW_UNSPECIFIED(0), + /** + * + * + *
+   * Includes every `AnalyzedSession` field except `assessment`.
+   * 
+ * + * ANALYZED_SESSION_VIEW_BASIC = 1; + */ + ANALYZED_SESSION_VIEW_BASIC(1), + /** + * + * + *
+   * Includes all fields, including the detailed `assessment`.
+   * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+   * omits `assessment` in every view. To get it, call
+   * [AgentAnomalyDetectionService.GetAnalyzedSession][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.GetAnalyzedSession]
+   * with this view.
+   * 
+ * + * ANALYZED_SESSION_VIEW_FULL = 2; + */ + ANALYZED_SESSION_VIEW_FULL(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AnalyzedSessionView"); + } + + /** + * + * + *
+   * The default view: BASIC.
+   * 
+ * + * ANALYZED_SESSION_VIEW_UNSPECIFIED = 0; + */ + public static final int ANALYZED_SESSION_VIEW_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+   * Includes every `AnalyzedSession` field except `assessment`.
+   * 
+ * + * ANALYZED_SESSION_VIEW_BASIC = 1; + */ + public static final int ANALYZED_SESSION_VIEW_BASIC_VALUE = 1; + + /** + * + * + *
+   * Includes all fields, including the detailed `assessment`.
+   * [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions]
+   * omits `assessment` in every view. To get it, call
+   * [AgentAnomalyDetectionService.GetAnalyzedSession][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.GetAnalyzedSession]
+   * with this view.
+   * 
+ * + * ANALYZED_SESSION_VIEW_FULL = 2; + */ + public static final int ANALYZED_SESSION_VIEW_FULL_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static AnalyzedSessionView valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static AnalyzedSessionView forNumber(int value) { + switch (value) { + case 0: + return ANALYZED_SESSION_VIEW_UNSPECIFIED; + case 1: + return ANALYZED_SESSION_VIEW_BASIC; + case 2: + return ANALYZED_SESSION_VIEW_FULL; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap + internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public AnalyzedSessionView findValueByNumber(int number) { + return AnalyzedSessionView.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final AnalyzedSessionView[] VALUES = values(); + + public static AnalyzedSessionView valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private AnalyzedSessionView(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.aiplatform.v1.AnalyzedSessionView) +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/Assessment.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/Assessment.java new file mode 100644 index 000000000000..b6410ac055cb --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/Assessment.java @@ -0,0 +1,2647 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Contains the detailed assessment for an analyzed session.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.Assessment} + */ +@com.google.protobuf.Generated +public final class Assessment extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.Assessment) + AssessmentOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Assessment"); + } + + // Use Assessment.newBuilder() to construct. + private Assessment(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Assessment() { + detectorFindings_ = java.util.Collections.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_Assessment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_Assessment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.Assessment.class, + com.google.cloud.aiplatform.v1.Assessment.Builder.class); + } + + public interface DetectorFindingOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.Assessment.DetectorFinding) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * The detector ID.
+     * 
+ * + * string detector_id = 1; + * + * @return The detectorId. + */ + java.lang.String getDetectorId(); + + /** + * + * + *
+     * The detector ID.
+     * 
+ * + * string detector_id = 1; + * + * @return The bytes for detectorId. + */ + com.google.protobuf.ByteString getDetectorIdBytes(); + + /** + * + * + *
+     * The detector display name.
+     * 
+ * + * string display_name = 2; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
+     * The detector display name.
+     * 
+ * + * string display_name = 2; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
+     * The severity of the finding.
+     * 
+ * + * .google.cloud.aiplatform.v1.Severity severity = 3; + * + * @return The enum numeric value on the wire for severity. + */ + int getSeverityValue(); + + /** + * + * + *
+     * The severity of the finding.
+     * 
+ * + * .google.cloud.aiplatform.v1.Severity severity = 3; + * + * @return The severity. + */ + com.google.cloud.aiplatform.v1.Severity getSeverity(); + + /** + * + * + *
+     * The explanation of the finding.
+     * 
+ * + * string explanation = 4; + * + * @return The explanation. + */ + java.lang.String getExplanation(); + + /** + * + * + *
+     * The explanation of the finding.
+     * 
+ * + * string explanation = 4; + * + * @return The bytes for explanation. + */ + com.google.protobuf.ByteString getExplanationBytes(); + + /** + * + * + *
+     * The probability that this finding is an anomaly, in the range [0.0, 1.0].
+     * 
+ * + * double probability = 5; + * + * @return The probability. + */ + double getProbability(); + + /** + * + * + *
+     * The list of recommendations for this detector finding.
+     * 
+ * + * repeated string recommendations = 6; + * + * @return A list containing the recommendations. + */ + java.util.List getRecommendationsList(); + + /** + * + * + *
+     * The list of recommendations for this detector finding.
+     * 
+ * + * repeated string recommendations = 6; + * + * @return The count of recommendations. + */ + int getRecommendationsCount(); + + /** + * + * + *
+     * The list of recommendations for this detector finding.
+     * 
+ * + * repeated string recommendations = 6; + * + * @param index The index of the element to return. + * @return The recommendations at the given index. + */ + java.lang.String getRecommendations(int index); + + /** + * + * + *
+     * The list of recommendations for this detector finding.
+     * 
+ * + * repeated string recommendations = 6; + * + * @param index The index of the value to return. + * @return The bytes of the recommendations at the given index. + */ + com.google.protobuf.ByteString getRecommendationsBytes(int index); + } + + /** + * + * + *
+   * The details of a detector's assessment within an analyzed session.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.Assessment.DetectorFinding} + */ + public static final class DetectorFinding extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.Assessment.DetectorFinding) + DetectorFindingOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DetectorFinding"); + } + + // Use DetectorFinding.newBuilder() to construct. + private DetectorFinding(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DetectorFinding() { + detectorId_ = ""; + displayName_ = ""; + severity_ = 0; + explanation_ = ""; + recommendations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_Assessment_DetectorFinding_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_Assessment_DetectorFinding_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.class, + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.Builder.class); + } + + public static final int DETECTOR_ID_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object detectorId_ = ""; + + /** + * + * + *
+     * The detector ID.
+     * 
+ * + * string detector_id = 1; + * + * @return The detectorId. + */ + @java.lang.Override + public java.lang.String getDetectorId() { + java.lang.Object ref = detectorId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + detectorId_ = s; + return s; + } + } + + /** + * + * + *
+     * The detector ID.
+     * 
+ * + * string detector_id = 1; + * + * @return The bytes for detectorId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDetectorIdBytes() { + java.lang.Object ref = detectorId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + detectorId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object displayName_ = ""; + + /** + * + * + *
+     * The detector display name.
+     * 
+ * + * string display_name = 2; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + + /** + * + * + *
+     * The detector display name.
+     * 
+ * + * string display_name = 2; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SEVERITY_FIELD_NUMBER = 3; + private int severity_ = 0; + + /** + * + * + *
+     * The severity of the finding.
+     * 
+ * + * .google.cloud.aiplatform.v1.Severity severity = 3; + * + * @return The enum numeric value on the wire for severity. + */ + @java.lang.Override + public int getSeverityValue() { + return severity_; + } + + /** + * + * + *
+     * The severity of the finding.
+     * 
+ * + * .google.cloud.aiplatform.v1.Severity severity = 3; + * + * @return The severity. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.Severity getSeverity() { + com.google.cloud.aiplatform.v1.Severity result = + com.google.cloud.aiplatform.v1.Severity.forNumber(severity_); + return result == null ? com.google.cloud.aiplatform.v1.Severity.UNRECOGNIZED : result; + } + + public static final int EXPLANATION_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object explanation_ = ""; + + /** + * + * + *
+     * The explanation of the finding.
+     * 
+ * + * string explanation = 4; + * + * @return The explanation. + */ + @java.lang.Override + public java.lang.String getExplanation() { + java.lang.Object ref = explanation_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + explanation_ = s; + return s; + } + } + + /** + * + * + *
+     * The explanation of the finding.
+     * 
+ * + * string explanation = 4; + * + * @return The bytes for explanation. + */ + @java.lang.Override + public com.google.protobuf.ByteString getExplanationBytes() { + java.lang.Object ref = explanation_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + explanation_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PROBABILITY_FIELD_NUMBER = 5; + private double probability_ = 0D; + + /** + * + * + *
+     * The probability that this finding is an anomaly, in the range [0.0, 1.0].
+     * 
+ * + * double probability = 5; + * + * @return The probability. + */ + @java.lang.Override + public double getProbability() { + return probability_; + } + + public static final int RECOMMENDATIONS_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList recommendations_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
+     * The list of recommendations for this detector finding.
+     * 
+ * + * repeated string recommendations = 6; + * + * @return A list containing the recommendations. + */ + public com.google.protobuf.ProtocolStringList getRecommendationsList() { + return recommendations_; + } + + /** + * + * + *
+     * The list of recommendations for this detector finding.
+     * 
+ * + * repeated string recommendations = 6; + * + * @return The count of recommendations. + */ + public int getRecommendationsCount() { + return recommendations_.size(); + } + + /** + * + * + *
+     * The list of recommendations for this detector finding.
+     * 
+ * + * repeated string recommendations = 6; + * + * @param index The index of the element to return. + * @return The recommendations at the given index. + */ + public java.lang.String getRecommendations(int index) { + return recommendations_.get(index); + } + + /** + * + * + *
+     * The list of recommendations for this detector finding.
+     * 
+ * + * repeated string recommendations = 6; + * + * @param index The index of the value to return. + * @return The bytes of the recommendations at the given index. + */ + public com.google.protobuf.ByteString getRecommendationsBytes(int index) { + return recommendations_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(detectorId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, detectorId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, displayName_); + } + if (severity_ != com.google.cloud.aiplatform.v1.Severity.SEVERITY_UNSPECIFIED.getNumber()) { + output.writeEnum(3, severity_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(explanation_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, explanation_); + } + if (java.lang.Double.doubleToRawLongBits(probability_) != 0) { + output.writeDouble(5, probability_); + } + for (int i = 0; i < recommendations_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, recommendations_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(detectorId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, detectorId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, displayName_); + } + if (severity_ != com.google.cloud.aiplatform.v1.Severity.SEVERITY_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, severity_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(explanation_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, explanation_); + } + if (java.lang.Double.doubleToRawLongBits(probability_) != 0) { + size += com.google.protobuf.CodedOutputStream.computeDoubleSize(5, probability_); + } + { + int dataSize = 0; + for (int i = 0; i < recommendations_.size(); i++) { + dataSize += computeStringSizeNoTag(recommendations_.getRaw(i)); + } + size += dataSize; + size += 1 * getRecommendationsList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.Assessment.DetectorFinding)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding other = + (com.google.cloud.aiplatform.v1.Assessment.DetectorFinding) obj; + + if (!getDetectorId().equals(other.getDetectorId())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (severity_ != other.severity_) return false; + if (!getExplanation().equals(other.getExplanation())) return false; + if (java.lang.Double.doubleToLongBits(getProbability()) + != java.lang.Double.doubleToLongBits(other.getProbability())) return false; + if (!getRecommendationsList().equals(other.getRecommendationsList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + DETECTOR_ID_FIELD_NUMBER; + hash = (53 * hash) + getDetectorId().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + hash = (37 * hash) + SEVERITY_FIELD_NUMBER; + hash = (53 * hash) + severity_; + hash = (37 * hash) + EXPLANATION_FIELD_NUMBER; + hash = (53 * hash) + getExplanation().hashCode(); + hash = (37 * hash) + PROBABILITY_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getProbability())); + if (getRecommendationsCount() > 0) { + hash = (37 * hash) + RECOMMENDATIONS_FIELD_NUMBER; + hash = (53 * hash) + getRecommendationsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+     * The details of a detector's assessment within an analyzed session.
+     * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.Assessment.DetectorFinding} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.Assessment.DetectorFinding) + com.google.cloud.aiplatform.v1.Assessment.DetectorFindingOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_Assessment_DetectorFinding_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_Assessment_DetectorFinding_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.class, + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + detectorId_ = ""; + displayName_ = ""; + severity_ = 0; + explanation_ = ""; + probability_ = 0D; + recommendations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_Assessment_DetectorFinding_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment.DetectorFinding getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment.DetectorFinding build() { + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment.DetectorFinding buildPartial() { + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding result = + new com.google.cloud.aiplatform.v1.Assessment.DetectorFinding(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.Assessment.DetectorFinding result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.detectorId_ = detectorId_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.displayName_ = displayName_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.severity_ = severity_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.explanation_ = explanation_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.probability_ = probability_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + recommendations_.makeImmutable(); + result.recommendations_ = recommendations_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.Assessment.DetectorFinding) { + return mergeFrom((com.google.cloud.aiplatform.v1.Assessment.DetectorFinding) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.Assessment.DetectorFinding other) { + if (other == com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.getDefaultInstance()) + return this; + if (!other.getDetectorId().isEmpty()) { + detectorId_ = other.detectorId_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.severity_ != 0) { + setSeverityValue(other.getSeverityValue()); + } + if (!other.getExplanation().isEmpty()) { + explanation_ = other.explanation_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (java.lang.Double.doubleToRawLongBits(other.getProbability()) != 0) { + setProbability(other.getProbability()); + } + if (!other.recommendations_.isEmpty()) { + if (recommendations_.isEmpty()) { + recommendations_ = other.recommendations_; + bitField0_ |= 0x00000020; + } else { + ensureRecommendationsIsMutable(); + recommendations_.addAll(other.recommendations_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + detectorId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 24: + { + severity_ = input.readEnum(); + bitField0_ |= 0x00000004; + break; + } // case 24 + case 34: + { + explanation_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 41: + { + probability_ = input.readDouble(); + bitField0_ |= 0x00000010; + break; + } // case 41 + case 50: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureRecommendationsIsMutable(); + recommendations_.add(s); + break; + } // case 50 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object detectorId_ = ""; + + /** + * + * + *
+       * The detector ID.
+       * 
+ * + * string detector_id = 1; + * + * @return The detectorId. + */ + public java.lang.String getDetectorId() { + java.lang.Object ref = detectorId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + detectorId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * The detector ID.
+       * 
+ * + * string detector_id = 1; + * + * @return The bytes for detectorId. + */ + public com.google.protobuf.ByteString getDetectorIdBytes() { + java.lang.Object ref = detectorId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + detectorId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * The detector ID.
+       * 
+ * + * string detector_id = 1; + * + * @param value The detectorId to set. + * @return This builder for chaining. + */ + public Builder setDetectorId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + detectorId_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+       * The detector ID.
+       * 
+ * + * string detector_id = 1; + * + * @return This builder for chaining. + */ + public Builder clearDetectorId() { + detectorId_ = getDefaultInstance().getDetectorId(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+       * The detector ID.
+       * 
+ * + * string detector_id = 1; + * + * @param value The bytes for detectorId to set. + * @return This builder for chaining. + */ + public Builder setDetectorIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + detectorId_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + + /** + * + * + *
+       * The detector display name.
+       * 
+ * + * string display_name = 2; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * The detector display name.
+       * 
+ * + * string display_name = 2; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * The detector display name.
+       * 
+ * + * string display_name = 2; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+       * The detector display name.
+       * 
+ * + * string display_name = 2; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + displayName_ = getDefaultInstance().getDisplayName(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+       * The detector display name.
+       * 
+ * + * string display_name = 2; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private int severity_ = 0; + + /** + * + * + *
+       * The severity of the finding.
+       * 
+ * + * .google.cloud.aiplatform.v1.Severity severity = 3; + * + * @return The enum numeric value on the wire for severity. + */ + @java.lang.Override + public int getSeverityValue() { + return severity_; + } + + /** + * + * + *
+       * The severity of the finding.
+       * 
+ * + * .google.cloud.aiplatform.v1.Severity severity = 3; + * + * @param value The enum numeric value on the wire for severity to set. + * @return This builder for chaining. + */ + public Builder setSeverityValue(int value) { + severity_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+       * The severity of the finding.
+       * 
+ * + * .google.cloud.aiplatform.v1.Severity severity = 3; + * + * @return The severity. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.Severity getSeverity() { + com.google.cloud.aiplatform.v1.Severity result = + com.google.cloud.aiplatform.v1.Severity.forNumber(severity_); + return result == null ? com.google.cloud.aiplatform.v1.Severity.UNRECOGNIZED : result; + } + + /** + * + * + *
+       * The severity of the finding.
+       * 
+ * + * .google.cloud.aiplatform.v1.Severity severity = 3; + * + * @param value The severity to set. + * @return This builder for chaining. + */ + public Builder setSeverity(com.google.cloud.aiplatform.v1.Severity value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000004; + severity_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+       * The severity of the finding.
+       * 
+ * + * .google.cloud.aiplatform.v1.Severity severity = 3; + * + * @return This builder for chaining. + */ + public Builder clearSeverity() { + bitField0_ = (bitField0_ & ~0x00000004); + severity_ = 0; + onChanged(); + return this; + } + + private java.lang.Object explanation_ = ""; + + /** + * + * + *
+       * The explanation of the finding.
+       * 
+ * + * string explanation = 4; + * + * @return The explanation. + */ + public java.lang.String getExplanation() { + java.lang.Object ref = explanation_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + explanation_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+       * The explanation of the finding.
+       * 
+ * + * string explanation = 4; + * + * @return The bytes for explanation. + */ + public com.google.protobuf.ByteString getExplanationBytes() { + java.lang.Object ref = explanation_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + explanation_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+       * The explanation of the finding.
+       * 
+ * + * string explanation = 4; + * + * @param value The explanation to set. + * @return This builder for chaining. + */ + public Builder setExplanation(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + explanation_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+       * The explanation of the finding.
+       * 
+ * + * string explanation = 4; + * + * @return This builder for chaining. + */ + public Builder clearExplanation() { + explanation_ = getDefaultInstance().getExplanation(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+       * The explanation of the finding.
+       * 
+ * + * string explanation = 4; + * + * @param value The bytes for explanation to set. + * @return This builder for chaining. + */ + public Builder setExplanationBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + explanation_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private double probability_; + + /** + * + * + *
+       * The probability that this finding is an anomaly, in the range [0.0, 1.0].
+       * 
+ * + * double probability = 5; + * + * @return The probability. + */ + @java.lang.Override + public double getProbability() { + return probability_; + } + + /** + * + * + *
+       * The probability that this finding is an anomaly, in the range [0.0, 1.0].
+       * 
+ * + * double probability = 5; + * + * @param value The probability to set. + * @return This builder for chaining. + */ + public Builder setProbability(double value) { + + probability_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+       * The probability that this finding is an anomaly, in the range [0.0, 1.0].
+       * 
+ * + * double probability = 5; + * + * @return This builder for chaining. + */ + public Builder clearProbability() { + bitField0_ = (bitField0_ & ~0x00000010); + probability_ = 0D; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList recommendations_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureRecommendationsIsMutable() { + if (!recommendations_.isModifiable()) { + recommendations_ = new com.google.protobuf.LazyStringArrayList(recommendations_); + } + bitField0_ |= 0x00000020; + } + + /** + * + * + *
+       * The list of recommendations for this detector finding.
+       * 
+ * + * repeated string recommendations = 6; + * + * @return A list containing the recommendations. + */ + public com.google.protobuf.ProtocolStringList getRecommendationsList() { + recommendations_.makeImmutable(); + return recommendations_; + } + + /** + * + * + *
+       * The list of recommendations for this detector finding.
+       * 
+ * + * repeated string recommendations = 6; + * + * @return The count of recommendations. + */ + public int getRecommendationsCount() { + return recommendations_.size(); + } + + /** + * + * + *
+       * The list of recommendations for this detector finding.
+       * 
+ * + * repeated string recommendations = 6; + * + * @param index The index of the element to return. + * @return The recommendations at the given index. + */ + public java.lang.String getRecommendations(int index) { + return recommendations_.get(index); + } + + /** + * + * + *
+       * The list of recommendations for this detector finding.
+       * 
+ * + * repeated string recommendations = 6; + * + * @param index The index of the value to return. + * @return The bytes of the recommendations at the given index. + */ + public com.google.protobuf.ByteString getRecommendationsBytes(int index) { + return recommendations_.getByteString(index); + } + + /** + * + * + *
+       * The list of recommendations for this detector finding.
+       * 
+ * + * repeated string recommendations = 6; + * + * @param index The index to set the value at. + * @param value The recommendations to set. + * @return This builder for chaining. + */ + public Builder setRecommendations(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureRecommendationsIsMutable(); + recommendations_.set(index, value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+       * The list of recommendations for this detector finding.
+       * 
+ * + * repeated string recommendations = 6; + * + * @param value The recommendations to add. + * @return This builder for chaining. + */ + public Builder addRecommendations(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureRecommendationsIsMutable(); + recommendations_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+       * The list of recommendations for this detector finding.
+       * 
+ * + * repeated string recommendations = 6; + * + * @param values The recommendations to add. + * @return This builder for chaining. + */ + public Builder addAllRecommendations(java.lang.Iterable values) { + ensureRecommendationsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, recommendations_); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+       * The list of recommendations for this detector finding.
+       * 
+ * + * repeated string recommendations = 6; + * + * @return This builder for chaining. + */ + public Builder clearRecommendations() { + recommendations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000020); + ; + onChanged(); + return this; + } + + /** + * + * + *
+       * The list of recommendations for this detector finding.
+       * 
+ * + * repeated string recommendations = 6; + * + * @param value The bytes of the recommendations to add. + * @return This builder for chaining. + */ + public Builder addRecommendationsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureRecommendationsIsMutable(); + recommendations_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.Assessment.DetectorFinding) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.Assessment.DetectorFinding) + private static final com.google.cloud.aiplatform.v1.Assessment.DetectorFinding DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.Assessment.DetectorFinding(); + } + + public static com.google.cloud.aiplatform.v1.Assessment.DetectorFinding getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DetectorFinding parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment.DetectorFinding getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public static final int DETECTOR_FINDINGS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List + detectorFindings_; + + /** + * + * + *
+   * The list of detector findings.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + @java.lang.Override + public java.util.List + getDetectorFindingsList() { + return detectorFindings_; + } + + /** + * + * + *
+   * The list of detector findings.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.cloud.aiplatform.v1.Assessment.DetectorFindingOrBuilder> + getDetectorFindingsOrBuilderList() { + return detectorFindings_; + } + + /** + * + * + *
+   * The list of detector findings.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + @java.lang.Override + public int getDetectorFindingsCount() { + return detectorFindings_.size(); + } + + /** + * + * + *
+   * The list of detector findings.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment.DetectorFinding getDetectorFindings(int index) { + return detectorFindings_.get(index); + } + + /** + * + * + *
+   * The list of detector findings.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment.DetectorFindingOrBuilder + getDetectorFindingsOrBuilder(int index) { + return detectorFindings_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < detectorFindings_.size(); i++) { + output.writeMessage(1, detectorFindings_.get(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < detectorFindings_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, detectorFindings_.get(i)); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.Assessment)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.Assessment other = + (com.google.cloud.aiplatform.v1.Assessment) obj; + + if (!getDetectorFindingsList().equals(other.getDetectorFindingsList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getDetectorFindingsCount() > 0) { + hash = (37 * hash) + DETECTOR_FINDINGS_FIELD_NUMBER; + hash = (53 * hash) + getDetectorFindingsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.Assessment parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.Assessment parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.Assessment parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.Assessment parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.Assessment parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.Assessment parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.Assessment parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.Assessment parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.Assessment parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.Assessment parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.Assessment parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.Assessment parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.aiplatform.v1.Assessment prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Contains the detailed assessment for an analyzed session.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.Assessment} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.Assessment) + com.google.cloud.aiplatform.v1.AssessmentOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_Assessment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_Assessment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.Assessment.class, + com.google.cloud.aiplatform.v1.Assessment.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.Assessment.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (detectorFindingsBuilder_ == null) { + detectorFindings_ = java.util.Collections.emptyList(); + } else { + detectorFindings_ = null; + detectorFindingsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_Assessment_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment build() { + com.google.cloud.aiplatform.v1.Assessment result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment buildPartial() { + com.google.cloud.aiplatform.v1.Assessment result = + new com.google.cloud.aiplatform.v1.Assessment(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.cloud.aiplatform.v1.Assessment result) { + if (detectorFindingsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + detectorFindings_ = java.util.Collections.unmodifiableList(detectorFindings_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.detectorFindings_ = detectorFindings_; + } else { + result.detectorFindings_ = detectorFindingsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.Assessment result) { + int from_bitField0_ = bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.Assessment) { + return mergeFrom((com.google.cloud.aiplatform.v1.Assessment) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.Assessment other) { + if (other == com.google.cloud.aiplatform.v1.Assessment.getDefaultInstance()) return this; + if (detectorFindingsBuilder_ == null) { + if (!other.detectorFindings_.isEmpty()) { + if (detectorFindings_.isEmpty()) { + detectorFindings_ = other.detectorFindings_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureDetectorFindingsIsMutable(); + detectorFindings_.addAll(other.detectorFindings_); + } + onChanged(); + } + } else { + if (!other.detectorFindings_.isEmpty()) { + if (detectorFindingsBuilder_.isEmpty()) { + detectorFindingsBuilder_.dispose(); + detectorFindingsBuilder_ = null; + detectorFindings_ = other.detectorFindings_; + bitField0_ = (bitField0_ & ~0x00000001); + detectorFindingsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetDetectorFindingsFieldBuilder() + : null; + } else { + detectorFindingsBuilder_.addAllMessages(other.detectorFindings_); + } + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding m = + input.readMessage( + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.parser(), + extensionRegistry); + if (detectorFindingsBuilder_ == null) { + ensureDetectorFindingsIsMutable(); + detectorFindings_.add(m); + } else { + detectorFindingsBuilder_.addMessage(m); + } + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List + detectorFindings_ = java.util.Collections.emptyList(); + + private void ensureDetectorFindingsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + detectorFindings_ = + new java.util.ArrayList( + detectorFindings_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding, + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.Builder, + com.google.cloud.aiplatform.v1.Assessment.DetectorFindingOrBuilder> + detectorFindingsBuilder_; + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public java.util.List + getDetectorFindingsList() { + if (detectorFindingsBuilder_ == null) { + return java.util.Collections.unmodifiableList(detectorFindings_); + } else { + return detectorFindingsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public int getDetectorFindingsCount() { + if (detectorFindingsBuilder_ == null) { + return detectorFindings_.size(); + } else { + return detectorFindingsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public com.google.cloud.aiplatform.v1.Assessment.DetectorFinding getDetectorFindings( + int index) { + if (detectorFindingsBuilder_ == null) { + return detectorFindings_.get(index); + } else { + return detectorFindingsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public Builder setDetectorFindings( + int index, com.google.cloud.aiplatform.v1.Assessment.DetectorFinding value) { + if (detectorFindingsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDetectorFindingsIsMutable(); + detectorFindings_.set(index, value); + onChanged(); + } else { + detectorFindingsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public Builder setDetectorFindings( + int index, + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.Builder builderForValue) { + if (detectorFindingsBuilder_ == null) { + ensureDetectorFindingsIsMutable(); + detectorFindings_.set(index, builderForValue.build()); + onChanged(); + } else { + detectorFindingsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public Builder addDetectorFindings( + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding value) { + if (detectorFindingsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDetectorFindingsIsMutable(); + detectorFindings_.add(value); + onChanged(); + } else { + detectorFindingsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public Builder addDetectorFindings( + int index, com.google.cloud.aiplatform.v1.Assessment.DetectorFinding value) { + if (detectorFindingsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDetectorFindingsIsMutable(); + detectorFindings_.add(index, value); + onChanged(); + } else { + detectorFindingsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public Builder addDetectorFindings( + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.Builder builderForValue) { + if (detectorFindingsBuilder_ == null) { + ensureDetectorFindingsIsMutable(); + detectorFindings_.add(builderForValue.build()); + onChanged(); + } else { + detectorFindingsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public Builder addDetectorFindings( + int index, + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.Builder builderForValue) { + if (detectorFindingsBuilder_ == null) { + ensureDetectorFindingsIsMutable(); + detectorFindings_.add(index, builderForValue.build()); + onChanged(); + } else { + detectorFindingsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public Builder addAllDetectorFindings( + java.lang.Iterable + values) { + if (detectorFindingsBuilder_ == null) { + ensureDetectorFindingsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, detectorFindings_); + onChanged(); + } else { + detectorFindingsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public Builder clearDetectorFindings() { + if (detectorFindingsBuilder_ == null) { + detectorFindings_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + detectorFindingsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public Builder removeDetectorFindings(int index) { + if (detectorFindingsBuilder_ == null) { + ensureDetectorFindingsIsMutable(); + detectorFindings_.remove(index); + onChanged(); + } else { + detectorFindingsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.Builder + getDetectorFindingsBuilder(int index) { + return internalGetDetectorFindingsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public com.google.cloud.aiplatform.v1.Assessment.DetectorFindingOrBuilder + getDetectorFindingsOrBuilder(int index) { + if (detectorFindingsBuilder_ == null) { + return detectorFindings_.get(index); + } else { + return detectorFindingsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public java.util.List< + ? extends com.google.cloud.aiplatform.v1.Assessment.DetectorFindingOrBuilder> + getDetectorFindingsOrBuilderList() { + if (detectorFindingsBuilder_ != null) { + return detectorFindingsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(detectorFindings_); + } + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.Builder + addDetectorFindingsBuilder() { + return internalGetDetectorFindingsFieldBuilder() + .addBuilder( + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.Builder + addDetectorFindingsBuilder(int index) { + return internalGetDetectorFindingsFieldBuilder() + .addBuilder( + index, + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of detector findings.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + public java.util.List + getDetectorFindingsBuilderList() { + return internalGetDetectorFindingsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding, + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.Builder, + com.google.cloud.aiplatform.v1.Assessment.DetectorFindingOrBuilder> + internalGetDetectorFindingsFieldBuilder() { + if (detectorFindingsBuilder_ == null) { + detectorFindingsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding, + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding.Builder, + com.google.cloud.aiplatform.v1.Assessment.DetectorFindingOrBuilder>( + detectorFindings_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + detectorFindings_ = null; + } + return detectorFindingsBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.Assessment) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.Assessment) + private static final com.google.cloud.aiplatform.v1.Assessment DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.Assessment(); + } + + public static com.google.cloud.aiplatform.v1.Assessment getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Assessment parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.Assessment getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AssessmentOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AssessmentOrBuilder.java new file mode 100644 index 000000000000..04b265be34ae --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/AssessmentOrBuilder.java @@ -0,0 +1,91 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface AssessmentOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.Assessment) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of detector findings.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + java.util.List + getDetectorFindingsList(); + + /** + * + * + *
+   * The list of detector findings.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + com.google.cloud.aiplatform.v1.Assessment.DetectorFinding getDetectorFindings(int index); + + /** + * + * + *
+   * The list of detector findings.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + int getDetectorFindingsCount(); + + /** + * + * + *
+   * The list of detector findings.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + java.util.List + getDetectorFindingsOrBuilderList(); + + /** + * + * + *
+   * The list of detector findings.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.Assessment.DetectorFinding detector_findings = 1; + * + */ + com.google.cloud.aiplatform.v1.Assessment.DetectorFindingOrBuilder getDetectorFindingsOrBuilder( + int index); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataOperationMetadata.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataOperationMetadata.java new file mode 100644 index 000000000000..f06d90a3e448 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataOperationMetadata.java @@ -0,0 +1,992 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Metadata information for
+ * [AgentAnomalyDetectionService.ClearTrainingData][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ClearTrainingData].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata} + */ +@com.google.protobuf.Generated +public final class ClearTrainingDataOperationMetadata extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata) + ClearTrainingDataOperationMetadataOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ClearTrainingDataOperationMetadata"); + } + + // Use ClearTrainingDataOperationMetadata.newBuilder() to construct. + private ClearTrainingDataOperationMetadata( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ClearTrainingDataOperationMetadata() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataOperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataOperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata.class, + com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata.Builder.class); + } + + private int bitField0_; + public static final int GENERIC_METADATA_FIELD_NUMBER = 1; + private com.google.cloud.aiplatform.v1.GenericOperationMetadata genericMetadata_; + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + @java.lang.Override + public boolean hasGenericMetadata() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata() { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder + getGenericMetadataOrBuilder() { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + + public static final int DONE_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp doneTime_; + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return Whether the doneTime field is set. + */ + @java.lang.Override + public boolean hasDoneTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return The doneTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getDoneTime() { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getDoneTimeOrBuilder() { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getGenericMetadata()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getDoneTime()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getGenericMetadata()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getDoneTime()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata other = + (com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata) obj; + + if (hasGenericMetadata() != other.hasGenericMetadata()) return false; + if (hasGenericMetadata()) { + if (!getGenericMetadata().equals(other.getGenericMetadata())) return false; + } + if (hasDoneTime() != other.hasDoneTime()) return false; + if (hasDoneTime()) { + if (!getDoneTime().equals(other.getDoneTime())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasGenericMetadata()) { + hash = (37 * hash) + GENERIC_METADATA_FIELD_NUMBER; + hash = (53 * hash) + getGenericMetadata().hashCode(); + } + if (hasDoneTime()) { + hash = (37 * hash) + DONE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getDoneTime().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Metadata information for
+   * [AgentAnomalyDetectionService.ClearTrainingData][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ClearTrainingData].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata) + com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataOperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataOperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata.class, + com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata.Builder.class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetGenericMetadataFieldBuilder(); + internalGetDoneTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + genericMetadata_ = null; + if (genericMetadataBuilder_ != null) { + genericMetadataBuilder_.dispose(); + genericMetadataBuilder_ = null; + } + doneTime_ = null; + if (doneTimeBuilder_ != null) { + doneTimeBuilder_.dispose(); + doneTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataOperationMetadata_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata build() { + com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata buildPartial() { + com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata result = + new com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.genericMetadata_ = + genericMetadataBuilder_ == null ? genericMetadata_ : genericMetadataBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.doneTime_ = doneTimeBuilder_ == null ? doneTime_ : doneTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata) { + return mergeFrom((com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata other) { + if (other + == com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata.getDefaultInstance()) + return this; + if (other.hasGenericMetadata()) { + mergeGenericMetadata(other.getGenericMetadata()); + } + if (other.hasDoneTime()) { + mergeDoneTime(other.getDoneTime()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetGenericMetadataFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetDoneTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.aiplatform.v1.GenericOperationMetadata genericMetadata_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder> + genericMetadataBuilder_; + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + public boolean hasGenericMetadata() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata() { + if (genericMetadataBuilder_ == null) { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } else { + return genericMetadataBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder setGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata value) { + if (genericMetadataBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + genericMetadata_ = value; + } else { + genericMetadataBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder setGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder builderForValue) { + if (genericMetadataBuilder_ == null) { + genericMetadata_ = builderForValue.build(); + } else { + genericMetadataBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder mergeGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata value) { + if (genericMetadataBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && genericMetadata_ != null + && genericMetadata_ + != com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance()) { + getGenericMetadataBuilder().mergeFrom(value); + } else { + genericMetadata_ = value; + } + } else { + genericMetadataBuilder_.mergeFrom(value); + } + if (genericMetadata_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder clearGenericMetadata() { + bitField0_ = (bitField0_ & ~0x00000001); + genericMetadata_ = null; + if (genericMetadataBuilder_ != null) { + genericMetadataBuilder_.dispose(); + genericMetadataBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder + getGenericMetadataBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetGenericMetadataFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder + getGenericMetadataOrBuilder() { + if (genericMetadataBuilder_ != null) { + return genericMetadataBuilder_.getMessageOrBuilder(); + } else { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder> + internalGetGenericMetadataFieldBuilder() { + if (genericMetadataBuilder_ == null) { + genericMetadataBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder>( + getGenericMetadata(), getParentForChildren(), isClean()); + genericMetadata_ = null; + } + return genericMetadataBuilder_; + } + + private com.google.protobuf.Timestamp doneTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + doneTimeBuilder_; + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return Whether the doneTime field is set. + */ + public boolean hasDoneTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return The doneTime. + */ + public com.google.protobuf.Timestamp getDoneTime() { + if (doneTimeBuilder_ == null) { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } else { + return doneTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder setDoneTime(com.google.protobuf.Timestamp value) { + if (doneTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + doneTime_ = value; + } else { + doneTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder setDoneTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (doneTimeBuilder_ == null) { + doneTime_ = builderForValue.build(); + } else { + doneTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder mergeDoneTime(com.google.protobuf.Timestamp value) { + if (doneTimeBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && doneTime_ != null + && doneTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getDoneTimeBuilder().mergeFrom(value); + } else { + doneTime_ = value; + } + } else { + doneTimeBuilder_.mergeFrom(value); + } + if (doneTime_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder clearDoneTime() { + bitField0_ = (bitField0_ & ~0x00000002); + doneTime_ = null; + if (doneTimeBuilder_ != null) { + doneTimeBuilder_.dispose(); + doneTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public com.google.protobuf.Timestamp.Builder getDoneTimeBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetDoneTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public com.google.protobuf.TimestampOrBuilder getDoneTimeOrBuilder() { + if (doneTimeBuilder_ != null) { + return doneTimeBuilder_.getMessageOrBuilder(); + } else { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetDoneTimeFieldBuilder() { + if (doneTimeBuilder_ == null) { + doneTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getDoneTime(), getParentForChildren(), isClean()); + doneTime_ = null; + } + return doneTimeBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata) + private static final com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata(); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ClearTrainingDataOperationMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataOperationMetadataOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataOperationMetadataOrBuilder.java new file mode 100644 index 000000000000..9657e44501b2 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataOperationMetadataOrBuilder.java @@ -0,0 +1,102 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface ClearTrainingDataOperationMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + boolean hasGenericMetadata(); + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata(); + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder getGenericMetadataOrBuilder(); + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return Whether the doneTime field is set. + */ + boolean hasDoneTime(); + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return The doneTime. + */ + com.google.protobuf.Timestamp getDoneTime(); + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + com.google.protobuf.TimestampOrBuilder getDoneTimeOrBuilder(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataRequest.java new file mode 100644 index 000000000000..b647ea15bdf1 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataRequest.java @@ -0,0 +1,641 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request message for
+ * [AgentAnomalyDetectionService.ClearTrainingData][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ClearTrainingData].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ClearTrainingDataRequest} + */ +@com.google.protobuf.Generated +public final class ClearTrainingDataRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ClearTrainingDataRequest) + ClearTrainingDataRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ClearTrainingDataRequest"); + } + + // Use ClearTrainingDataRequest.newBuilder() to construct. + private ClearTrainingDataRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ClearTrainingDataRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest.class, + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. The MonitoredAgent whose trained model artifacts to purge. Use
+   * the
+   * `-` wildcard agent segment to purge every MonitoredAgent in the scope.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The MonitoredAgent whose trained model artifacts to purge. Use
+   * the
+   * `-` wildcard agent segment to purge every MonitoredAgent in the scope.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.ClearTrainingDataRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest other = + (com.google.cloud.aiplatform.v1.ClearTrainingDataRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request message for
+   * [AgentAnomalyDetectionService.ClearTrainingData][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ClearTrainingData].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ClearTrainingDataRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ClearTrainingDataRequest) + com.google.cloud.aiplatform.v1.ClearTrainingDataRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest.class, + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.ClearTrainingDataRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataRequest getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ClearTrainingDataRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataRequest build() { + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataRequest buildPartial() { + com.google.cloud.aiplatform.v1.ClearTrainingDataRequest result = + new com.google.cloud.aiplatform.v1.ClearTrainingDataRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.ClearTrainingDataRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.ClearTrainingDataRequest) { + return mergeFrom((com.google.cloud.aiplatform.v1.ClearTrainingDataRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.ClearTrainingDataRequest other) { + if (other == com.google.cloud.aiplatform.v1.ClearTrainingDataRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. The MonitoredAgent whose trained model artifacts to purge. Use
+     * the
+     * `-` wildcard agent segment to purge every MonitoredAgent in the scope.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The MonitoredAgent whose trained model artifacts to purge. Use
+     * the
+     * `-` wildcard agent segment to purge every MonitoredAgent in the scope.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The MonitoredAgent whose trained model artifacts to purge. Use
+     * the
+     * `-` wildcard agent segment to purge every MonitoredAgent in the scope.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The MonitoredAgent whose trained model artifacts to purge. Use
+     * the
+     * `-` wildcard agent segment to purge every MonitoredAgent in the scope.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The MonitoredAgent whose trained model artifacts to purge. Use
+     * the
+     * `-` wildcard agent segment to purge every MonitoredAgent in the scope.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ClearTrainingDataRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ClearTrainingDataRequest) + private static final com.google.cloud.aiplatform.v1.ClearTrainingDataRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ClearTrainingDataRequest(); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ClearTrainingDataRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataRequestOrBuilder.java new file mode 100644 index 000000000000..f2d3303ba1d3 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataRequestOrBuilder.java @@ -0,0 +1,66 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface ClearTrainingDataRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ClearTrainingDataRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The MonitoredAgent whose trained model artifacts to purge. Use
+   * the
+   * `-` wildcard agent segment to purge every MonitoredAgent in the scope.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. The MonitoredAgent whose trained model artifacts to purge. Use
+   * the
+   * `-` wildcard agent segment to purge every MonitoredAgent in the scope.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataResponse.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataResponse.java new file mode 100644 index 000000000000..ebff1f818c25 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataResponse.java @@ -0,0 +1,403 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Response message for
+ * [AgentAnomalyDetectionService.ClearTrainingData][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ClearTrainingData].
+ * Intentionally empty; the purge either succeeds or the operation carries an
+ * error.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ClearTrainingDataResponse} + */ +@com.google.protobuf.Generated +public final class ClearTrainingDataResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ClearTrainingDataResponse) + ClearTrainingDataResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ClearTrainingDataResponse"); + } + + // Use ClearTrainingDataResponse.newBuilder() to construct. + private ClearTrainingDataResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ClearTrainingDataResponse() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ClearTrainingDataResponse.class, + com.google.cloud.aiplatform.v1.ClearTrainingDataResponse.Builder.class); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.ClearTrainingDataResponse)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ClearTrainingDataResponse other = + (com.google.cloud.aiplatform.v1.ClearTrainingDataResponse) obj; + + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ClearTrainingDataResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Response message for
+   * [AgentAnomalyDetectionService.ClearTrainingData][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ClearTrainingData].
+   * Intentionally empty; the purge either succeeds or the operation carries an
+   * error.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ClearTrainingDataResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ClearTrainingDataResponse) + com.google.cloud.aiplatform.v1.ClearTrainingDataResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ClearTrainingDataResponse.class, + com.google.cloud.aiplatform.v1.ClearTrainingDataResponse.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.ClearTrainingDataResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ClearTrainingDataResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataResponse getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ClearTrainingDataResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataResponse build() { + com.google.cloud.aiplatform.v1.ClearTrainingDataResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataResponse buildPartial() { + com.google.cloud.aiplatform.v1.ClearTrainingDataResponse result = + new com.google.cloud.aiplatform.v1.ClearTrainingDataResponse(this); + onBuilt(); + return result; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.ClearTrainingDataResponse) { + return mergeFrom((com.google.cloud.aiplatform.v1.ClearTrainingDataResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.ClearTrainingDataResponse other) { + if (other == com.google.cloud.aiplatform.v1.ClearTrainingDataResponse.getDefaultInstance()) + return this; + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ClearTrainingDataResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ClearTrainingDataResponse) + private static final com.google.cloud.aiplatform.v1.ClearTrainingDataResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ClearTrainingDataResponse(); + } + + public static com.google.cloud.aiplatform.v1.ClearTrainingDataResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ClearTrainingDataResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ClearTrainingDataResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataResponseOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataResponseOrBuilder.java new file mode 100644 index 000000000000..1e1b51c19005 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ClearTrainingDataResponseOrBuilder.java @@ -0,0 +1,27 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface ClearTrainingDataResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ClearTrainingDataResponse) + com.google.protobuf.MessageOrBuilder {} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeOperationMetadata.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeOperationMetadata.java new file mode 100644 index 000000000000..649c933b7ca8 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeOperationMetadata.java @@ -0,0 +1,1021 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Metadata information for
+ * [AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope].
+ * 
+ * + * Protobuf type {@code + * google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata} + */ +@com.google.protobuf.Generated +public final class CreateAgentAnomalyDetectionScopeOperationMetadata + extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata) + CreateAgentAnomalyDetectionScopeOperationMetadataOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "CreateAgentAnomalyDetectionScopeOperationMetadata"); + } + + // Use CreateAgentAnomalyDetectionScopeOperationMetadata.newBuilder() to construct. + private CreateAgentAnomalyDetectionScopeOperationMetadata( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private CreateAgentAnomalyDetectionScopeOperationMetadata() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeOperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeOperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata.class, + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata.Builder + .class); + } + + private int bitField0_; + public static final int GENERIC_METADATA_FIELD_NUMBER = 1; + private com.google.cloud.aiplatform.v1.GenericOperationMetadata genericMetadata_; + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + @java.lang.Override + public boolean hasGenericMetadata() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata() { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder + getGenericMetadataOrBuilder() { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + + public static final int DONE_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp doneTime_; + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return Whether the doneTime field is set. + */ + @java.lang.Override + public boolean hasDoneTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return The doneTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getDoneTime() { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getDoneTimeOrBuilder() { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getGenericMetadata()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getDoneTime()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getGenericMetadata()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getDoneTime()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata other = + (com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata) obj; + + if (hasGenericMetadata() != other.hasGenericMetadata()) return false; + if (hasGenericMetadata()) { + if (!getGenericMetadata().equals(other.getGenericMetadata())) return false; + } + if (hasDoneTime() != other.hasDoneTime()) return false; + if (hasDoneTime()) { + if (!getDoneTime().equals(other.getDoneTime())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasGenericMetadata()) { + hash = (37 * hash) + GENERIC_METADATA_FIELD_NUMBER; + hash = (53 * hash) + getGenericMetadata().hashCode(); + } + if (hasDoneTime()) { + hash = (37 * hash) + DONE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getDoneTime().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Metadata information for
+   * [AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope].
+   * 
+ * + * Protobuf type {@code + * google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata) + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeOperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeOperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + .class, + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + .Builder.class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetGenericMetadataFieldBuilder(); + internalGetDoneTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + genericMetadata_ = null; + if (genericMetadataBuilder_ != null) { + genericMetadataBuilder_.dispose(); + genericMetadataBuilder_ = null; + } + doneTime_ = null; + if (doneTimeBuilder_ != null) { + doneTimeBuilder_.dispose(); + doneTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeOperationMetadata_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + build() { + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + buildPartial() { + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata result = + new com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata( + this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.genericMetadata_ = + genericMetadataBuilder_ == null ? genericMetadata_ : genericMetadataBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.doneTime_ = doneTimeBuilder_ == null ? doneTime_ : doneTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata) { + return mergeFrom( + (com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata other) { + if (other + == com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + .getDefaultInstance()) return this; + if (other.hasGenericMetadata()) { + mergeGenericMetadata(other.getGenericMetadata()); + } + if (other.hasDoneTime()) { + mergeDoneTime(other.getDoneTime()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetGenericMetadataFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetDoneTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.aiplatform.v1.GenericOperationMetadata genericMetadata_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder> + genericMetadataBuilder_; + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + public boolean hasGenericMetadata() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata() { + if (genericMetadataBuilder_ == null) { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } else { + return genericMetadataBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder setGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata value) { + if (genericMetadataBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + genericMetadata_ = value; + } else { + genericMetadataBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder setGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder builderForValue) { + if (genericMetadataBuilder_ == null) { + genericMetadata_ = builderForValue.build(); + } else { + genericMetadataBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder mergeGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata value) { + if (genericMetadataBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && genericMetadata_ != null + && genericMetadata_ + != com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance()) { + getGenericMetadataBuilder().mergeFrom(value); + } else { + genericMetadata_ = value; + } + } else { + genericMetadataBuilder_.mergeFrom(value); + } + if (genericMetadata_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder clearGenericMetadata() { + bitField0_ = (bitField0_ & ~0x00000001); + genericMetadata_ = null; + if (genericMetadataBuilder_ != null) { + genericMetadataBuilder_.dispose(); + genericMetadataBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder + getGenericMetadataBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetGenericMetadataFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder + getGenericMetadataOrBuilder() { + if (genericMetadataBuilder_ != null) { + return genericMetadataBuilder_.getMessageOrBuilder(); + } else { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder> + internalGetGenericMetadataFieldBuilder() { + if (genericMetadataBuilder_ == null) { + genericMetadataBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder>( + getGenericMetadata(), getParentForChildren(), isClean()); + genericMetadata_ = null; + } + return genericMetadataBuilder_; + } + + private com.google.protobuf.Timestamp doneTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + doneTimeBuilder_; + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return Whether the doneTime field is set. + */ + public boolean hasDoneTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return The doneTime. + */ + public com.google.protobuf.Timestamp getDoneTime() { + if (doneTimeBuilder_ == null) { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } else { + return doneTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder setDoneTime(com.google.protobuf.Timestamp value) { + if (doneTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + doneTime_ = value; + } else { + doneTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder setDoneTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (doneTimeBuilder_ == null) { + doneTime_ = builderForValue.build(); + } else { + doneTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder mergeDoneTime(com.google.protobuf.Timestamp value) { + if (doneTimeBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && doneTime_ != null + && doneTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getDoneTimeBuilder().mergeFrom(value); + } else { + doneTime_ = value; + } + } else { + doneTimeBuilder_.mergeFrom(value); + } + if (doneTime_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder clearDoneTime() { + bitField0_ = (bitField0_ & ~0x00000002); + doneTime_ = null; + if (doneTimeBuilder_ != null) { + doneTimeBuilder_.dispose(); + doneTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public com.google.protobuf.Timestamp.Builder getDoneTimeBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetDoneTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public com.google.protobuf.TimestampOrBuilder getDoneTimeOrBuilder() { + if (doneTimeBuilder_ != null) { + return doneTimeBuilder_.getMessageOrBuilder(); + } else { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetDoneTimeFieldBuilder() { + if (doneTimeBuilder_ == null) { + doneTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getDoneTime(), getParentForChildren(), isClean()); + doneTime_ = null; + } + return doneTimeBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata) + private static final com.google.cloud.aiplatform.v1 + .CreateAgentAnomalyDetectionScopeOperationMetadata + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata(); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = + new com.google.protobuf.AbstractParser< + CreateAgentAnomalyDetectionScopeOperationMetadata>() { + @java.lang.Override + public CreateAgentAnomalyDetectionScopeOperationMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser + parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser + getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeOperationMetadataOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeOperationMetadataOrBuilder.java new file mode 100644 index 000000000000..f5d0bd10ae25 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeOperationMetadataOrBuilder.java @@ -0,0 +1,102 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface CreateAgentAnomalyDetectionScopeOperationMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + boolean hasGenericMetadata(); + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata(); + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder getGenericMetadataOrBuilder(); + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return Whether the doneTime field is set. + */ + boolean hasDoneTime(); + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return The doneTime. + */ + com.google.protobuf.Timestamp getDoneTime(); + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + com.google.protobuf.TimestampOrBuilder getDoneTimeOrBuilder(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeRequest.java new file mode 100644 index 000000000000..080b3432bcc3 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeRequest.java @@ -0,0 +1,1205 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request message for
+ * [AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest} + */ +@com.google.protobuf.Generated +public final class CreateAgentAnomalyDetectionScopeRequest + extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest) + CreateAgentAnomalyDetectionScopeRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "CreateAgentAnomalyDetectionScopeRequest"); + } + + // Use CreateAgentAnomalyDetectionScopeRequest.newBuilder() to construct. + private CreateAgentAnomalyDetectionScopeRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private CreateAgentAnomalyDetectionScopeRequest() { + parent_ = ""; + agentAnomalyDetectionScopeId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest.class, + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest.Builder.class); + } + + private int bitField0_; + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. The resource name of the Location to create the
+   * AgentAnomalyDetectionScope in. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The resource name of the Location to create the
+   * AgentAnomalyDetectionScope in. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int AGENT_ANOMALY_DETECTION_SCOPE_FIELD_NUMBER = 2; + private com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agentAnomalyDetectionScope_; + + /** + * + * + *
+   * Required. The AgentAnomalyDetectionScope to create.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the agentAnomalyDetectionScope field is set. + */ + @java.lang.Override + public boolean hasAgentAnomalyDetectionScope() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Required. The AgentAnomalyDetectionScope to create.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentAnomalyDetectionScope. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope getAgentAnomalyDetectionScope() { + return agentAnomalyDetectionScope_ == null + ? com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.getDefaultInstance() + : agentAnomalyDetectionScope_; + } + + /** + * + * + *
+   * Required. The AgentAnomalyDetectionScope to create.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder + getAgentAnomalyDetectionScopeOrBuilder() { + return agentAnomalyDetectionScope_ == null + ? com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.getDefaultInstance() + : agentAnomalyDetectionScope_; + } + + public static final int AGENT_ANOMALY_DETECTION_SCOPE_ID_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object agentAnomalyDetectionScopeId_ = ""; + + /** + * + * + *
+   * Required. The ID to use for the AgentAnomalyDetectionScope, which will
+   * become the final component of the AgentAnomalyDetectionScope's resource
+   * name.
+   *
+   * This value should be 1-63 characters, and valid characters
+   * are /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/.
+   * 
+ * + * string agent_anomaly_detection_scope_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentAnomalyDetectionScopeId. + */ + @java.lang.Override + public java.lang.String getAgentAnomalyDetectionScopeId() { + java.lang.Object ref = agentAnomalyDetectionScopeId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agentAnomalyDetectionScopeId_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The ID to use for the AgentAnomalyDetectionScope, which will
+   * become the final component of the AgentAnomalyDetectionScope's resource
+   * name.
+   *
+   * This value should be 1-63 characters, and valid characters
+   * are /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/.
+   * 
+ * + * string agent_anomaly_detection_scope_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The bytes for agentAnomalyDetectionScopeId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAgentAnomalyDetectionScopeIdBytes() { + java.lang.Object ref = agentAnomalyDetectionScopeId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agentAnomalyDetectionScopeId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getAgentAnomalyDetectionScope()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agentAnomalyDetectionScopeId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, agentAnomalyDetectionScopeId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, getAgentAnomalyDetectionScope()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(agentAnomalyDetectionScopeId_)) { + size += + com.google.protobuf.GeneratedMessage.computeStringSize(3, agentAnomalyDetectionScopeId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest other = + (com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (hasAgentAnomalyDetectionScope() != other.hasAgentAnomalyDetectionScope()) return false; + if (hasAgentAnomalyDetectionScope()) { + if (!getAgentAnomalyDetectionScope().equals(other.getAgentAnomalyDetectionScope())) + return false; + } + if (!getAgentAnomalyDetectionScopeId().equals(other.getAgentAnomalyDetectionScopeId())) + return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + if (hasAgentAnomalyDetectionScope()) { + hash = (37 * hash) + AGENT_ANOMALY_DETECTION_SCOPE_FIELD_NUMBER; + hash = (53 * hash) + getAgentAnomalyDetectionScope().hashCode(); + } + hash = (37 * hash) + AGENT_ANOMALY_DETECTION_SCOPE_ID_FIELD_NUMBER; + hash = (53 * hash) + getAgentAnomalyDetectionScopeId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request message for
+   * [AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest) + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest.class, + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest.Builder.class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetAgentAnomalyDetectionScopeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + agentAnomalyDetectionScope_ = null; + if (agentAnomalyDetectionScopeBuilder_ != null) { + agentAnomalyDetectionScopeBuilder_.dispose(); + agentAnomalyDetectionScopeBuilder_ = null; + } + agentAnomalyDetectionScopeId_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_CreateAgentAnomalyDetectionScopeRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest build() { + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest buildPartial() { + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest result = + new com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.agentAnomalyDetectionScope_ = + agentAnomalyDetectionScopeBuilder_ == null + ? agentAnomalyDetectionScope_ + : agentAnomalyDetectionScopeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.agentAnomalyDetectionScopeId_ = agentAnomalyDetectionScopeId_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest) { + return mergeFrom( + (com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest other) { + if (other + == com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest + .getDefaultInstance()) return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.hasAgentAnomalyDetectionScope()) { + mergeAgentAnomalyDetectionScope(other.getAgentAnomalyDetectionScope()); + } + if (!other.getAgentAnomalyDetectionScopeId().isEmpty()) { + agentAnomalyDetectionScopeId_ = other.agentAnomalyDetectionScopeId_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetAgentAnomalyDetectionScopeFieldBuilder().getBuilder(), + extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + agentAnomalyDetectionScopeId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. The resource name of the Location to create the
+     * AgentAnomalyDetectionScope in. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The resource name of the Location to create the
+     * AgentAnomalyDetectionScope in. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The resource name of the Location to create the
+     * AgentAnomalyDetectionScope in. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The resource name of the Location to create the
+     * AgentAnomalyDetectionScope in. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The resource name of the Location to create the
+     * AgentAnomalyDetectionScope in. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agentAnomalyDetectionScope_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder> + agentAnomalyDetectionScopeBuilder_; + + /** + * + * + *
+     * Required. The AgentAnomalyDetectionScope to create.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the agentAnomalyDetectionScope field is set. + */ + public boolean hasAgentAnomalyDetectionScope() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * Required. The AgentAnomalyDetectionScope to create.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentAnomalyDetectionScope. + */ + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope + getAgentAnomalyDetectionScope() { + if (agentAnomalyDetectionScopeBuilder_ == null) { + return agentAnomalyDetectionScope_ == null + ? com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.getDefaultInstance() + : agentAnomalyDetectionScope_; + } else { + return agentAnomalyDetectionScopeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Required. The AgentAnomalyDetectionScope to create.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope value) { + if (agentAnomalyDetectionScopeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + agentAnomalyDetectionScope_ = value; + } else { + agentAnomalyDetectionScopeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The AgentAnomalyDetectionScope to create.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder builderForValue) { + if (agentAnomalyDetectionScopeBuilder_ == null) { + agentAnomalyDetectionScope_ = builderForValue.build(); + } else { + agentAnomalyDetectionScopeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The AgentAnomalyDetectionScope to create.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeAgentAnomalyDetectionScope( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope value) { + if (agentAnomalyDetectionScopeBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && agentAnomalyDetectionScope_ != null + && agentAnomalyDetectionScope_ + != com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.getDefaultInstance()) { + getAgentAnomalyDetectionScopeBuilder().mergeFrom(value); + } else { + agentAnomalyDetectionScope_ = value; + } + } else { + agentAnomalyDetectionScopeBuilder_.mergeFrom(value); + } + if (agentAnomalyDetectionScope_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Required. The AgentAnomalyDetectionScope to create.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearAgentAnomalyDetectionScope() { + bitField0_ = (bitField0_ & ~0x00000002); + agentAnomalyDetectionScope_ = null; + if (agentAnomalyDetectionScopeBuilder_ != null) { + agentAnomalyDetectionScopeBuilder_.dispose(); + agentAnomalyDetectionScopeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The AgentAnomalyDetectionScope to create.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder + getAgentAnomalyDetectionScopeBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetAgentAnomalyDetectionScopeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Required. The AgentAnomalyDetectionScope to create.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder + getAgentAnomalyDetectionScopeOrBuilder() { + if (agentAnomalyDetectionScopeBuilder_ != null) { + return agentAnomalyDetectionScopeBuilder_.getMessageOrBuilder(); + } else { + return agentAnomalyDetectionScope_ == null + ? com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.getDefaultInstance() + : agentAnomalyDetectionScope_; + } + } + + /** + * + * + *
+     * Required. The AgentAnomalyDetectionScope to create.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder> + internalGetAgentAnomalyDetectionScopeFieldBuilder() { + if (agentAnomalyDetectionScopeBuilder_ == null) { + agentAnomalyDetectionScopeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder>( + getAgentAnomalyDetectionScope(), getParentForChildren(), isClean()); + agentAnomalyDetectionScope_ = null; + } + return agentAnomalyDetectionScopeBuilder_; + } + + private java.lang.Object agentAnomalyDetectionScopeId_ = ""; + + /** + * + * + *
+     * Required. The ID to use for the AgentAnomalyDetectionScope, which will
+     * become the final component of the AgentAnomalyDetectionScope's resource
+     * name.
+     *
+     * This value should be 1-63 characters, and valid characters
+     * are /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/.
+     * 
+ * + * string agent_anomaly_detection_scope_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentAnomalyDetectionScopeId. + */ + public java.lang.String getAgentAnomalyDetectionScopeId() { + java.lang.Object ref = agentAnomalyDetectionScopeId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agentAnomalyDetectionScopeId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The ID to use for the AgentAnomalyDetectionScope, which will
+     * become the final component of the AgentAnomalyDetectionScope's resource
+     * name.
+     *
+     * This value should be 1-63 characters, and valid characters
+     * are /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/.
+     * 
+ * + * string agent_anomaly_detection_scope_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The bytes for agentAnomalyDetectionScopeId. + */ + public com.google.protobuf.ByteString getAgentAnomalyDetectionScopeIdBytes() { + java.lang.Object ref = agentAnomalyDetectionScopeId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agentAnomalyDetectionScopeId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The ID to use for the AgentAnomalyDetectionScope, which will
+     * become the final component of the AgentAnomalyDetectionScope's resource
+     * name.
+     *
+     * This value should be 1-63 characters, and valid characters
+     * are /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/.
+     * 
+ * + * string agent_anomaly_detection_scope_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The agentAnomalyDetectionScopeId to set. + * @return This builder for chaining. + */ + public Builder setAgentAnomalyDetectionScopeId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + agentAnomalyDetectionScopeId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The ID to use for the AgentAnomalyDetectionScope, which will
+     * become the final component of the AgentAnomalyDetectionScope's resource
+     * name.
+     *
+     * This value should be 1-63 characters, and valid characters
+     * are /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/.
+     * 
+ * + * string agent_anomaly_detection_scope_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearAgentAnomalyDetectionScopeId() { + agentAnomalyDetectionScopeId_ = getDefaultInstance().getAgentAnomalyDetectionScopeId(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The ID to use for the AgentAnomalyDetectionScope, which will
+     * become the final component of the AgentAnomalyDetectionScope's resource
+     * name.
+     *
+     * This value should be 1-63 characters, and valid characters
+     * are /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/.
+     * 
+ * + * string agent_anomaly_detection_scope_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The bytes for agentAnomalyDetectionScopeId to set. + * @return This builder for chaining. + */ + public Builder setAgentAnomalyDetectionScopeIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + agentAnomalyDetectionScopeId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest) + private static final com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest(); + } + + public static com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateAgentAnomalyDetectionScopeRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeRequestOrBuilder.java new file mode 100644 index 000000000000..4c1be0b1da58 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/CreateAgentAnomalyDetectionScopeRequestOrBuilder.java @@ -0,0 +1,144 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface CreateAgentAnomalyDetectionScopeRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The resource name of the Location to create the
+   * AgentAnomalyDetectionScope in. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. The resource name of the Location to create the
+   * AgentAnomalyDetectionScope in. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Required. The AgentAnomalyDetectionScope to create.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the agentAnomalyDetectionScope field is set. + */ + boolean hasAgentAnomalyDetectionScope(); + + /** + * + * + *
+   * Required. The AgentAnomalyDetectionScope to create.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentAnomalyDetectionScope. + */ + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope getAgentAnomalyDetectionScope(); + + /** + * + * + *
+   * Required. The AgentAnomalyDetectionScope to create.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder + getAgentAnomalyDetectionScopeOrBuilder(); + + /** + * + * + *
+   * Required. The ID to use for the AgentAnomalyDetectionScope, which will
+   * become the final component of the AgentAnomalyDetectionScope's resource
+   * name.
+   *
+   * This value should be 1-63 characters, and valid characters
+   * are /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/.
+   * 
+ * + * string agent_anomaly_detection_scope_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentAnomalyDetectionScopeId. + */ + java.lang.String getAgentAnomalyDetectionScopeId(); + + /** + * + * + *
+   * Required. The ID to use for the AgentAnomalyDetectionScope, which will
+   * become the final component of the AgentAnomalyDetectionScope's resource
+   * name.
+   *
+   * This value should be 1-63 characters, and valid characters
+   * are /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/.
+   * 
+ * + * string agent_anomaly_detection_scope_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The bytes for agentAnomalyDetectionScopeId. + */ + com.google.protobuf.ByteString getAgentAnomalyDetectionScopeIdBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeOperationMetadata.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeOperationMetadata.java new file mode 100644 index 000000000000..2dcf5acdd1a1 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeOperationMetadata.java @@ -0,0 +1,1021 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Metadata information for
+ * [AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope].
+ * 
+ * + * Protobuf type {@code + * google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata} + */ +@com.google.protobuf.Generated +public final class DeleteAgentAnomalyDetectionScopeOperationMetadata + extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata) + DeleteAgentAnomalyDetectionScopeOperationMetadataOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DeleteAgentAnomalyDetectionScopeOperationMetadata"); + } + + // Use DeleteAgentAnomalyDetectionScopeOperationMetadata.newBuilder() to construct. + private DeleteAgentAnomalyDetectionScopeOperationMetadata( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DeleteAgentAnomalyDetectionScopeOperationMetadata() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeOperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeOperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata.class, + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata.Builder + .class); + } + + private int bitField0_; + public static final int GENERIC_METADATA_FIELD_NUMBER = 1; + private com.google.cloud.aiplatform.v1.GenericOperationMetadata genericMetadata_; + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + @java.lang.Override + public boolean hasGenericMetadata() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata() { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder + getGenericMetadataOrBuilder() { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + + public static final int DONE_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp doneTime_; + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return Whether the doneTime field is set. + */ + @java.lang.Override + public boolean hasDoneTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return The doneTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getDoneTime() { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getDoneTimeOrBuilder() { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getGenericMetadata()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getDoneTime()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getGenericMetadata()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getDoneTime()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata other = + (com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata) obj; + + if (hasGenericMetadata() != other.hasGenericMetadata()) return false; + if (hasGenericMetadata()) { + if (!getGenericMetadata().equals(other.getGenericMetadata())) return false; + } + if (hasDoneTime() != other.hasDoneTime()) return false; + if (hasDoneTime()) { + if (!getDoneTime().equals(other.getDoneTime())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasGenericMetadata()) { + hash = (37 * hash) + GENERIC_METADATA_FIELD_NUMBER; + hash = (53 * hash) + getGenericMetadata().hashCode(); + } + if (hasDoneTime()) { + hash = (37 * hash) + DONE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getDoneTime().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Metadata information for
+   * [AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope].
+   * 
+ * + * Protobuf type {@code + * google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata) + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeOperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeOperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + .class, + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + .Builder.class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetGenericMetadataFieldBuilder(); + internalGetDoneTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + genericMetadata_ = null; + if (genericMetadataBuilder_ != null) { + genericMetadataBuilder_.dispose(); + genericMetadataBuilder_ = null; + } + doneTime_ = null; + if (doneTimeBuilder_ != null) { + doneTimeBuilder_.dispose(); + doneTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeOperationMetadata_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + build() { + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + buildPartial() { + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata result = + new com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata( + this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.genericMetadata_ = + genericMetadataBuilder_ == null ? genericMetadata_ : genericMetadataBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.doneTime_ = doneTimeBuilder_ == null ? doneTime_ : doneTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata) { + return mergeFrom( + (com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata other) { + if (other + == com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + .getDefaultInstance()) return this; + if (other.hasGenericMetadata()) { + mergeGenericMetadata(other.getGenericMetadata()); + } + if (other.hasDoneTime()) { + mergeDoneTime(other.getDoneTime()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetGenericMetadataFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetDoneTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.aiplatform.v1.GenericOperationMetadata genericMetadata_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder> + genericMetadataBuilder_; + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + public boolean hasGenericMetadata() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata() { + if (genericMetadataBuilder_ == null) { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } else { + return genericMetadataBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder setGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata value) { + if (genericMetadataBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + genericMetadata_ = value; + } else { + genericMetadataBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder setGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder builderForValue) { + if (genericMetadataBuilder_ == null) { + genericMetadata_ = builderForValue.build(); + } else { + genericMetadataBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder mergeGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata value) { + if (genericMetadataBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && genericMetadata_ != null + && genericMetadata_ + != com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance()) { + getGenericMetadataBuilder().mergeFrom(value); + } else { + genericMetadata_ = value; + } + } else { + genericMetadataBuilder_.mergeFrom(value); + } + if (genericMetadata_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder clearGenericMetadata() { + bitField0_ = (bitField0_ & ~0x00000001); + genericMetadata_ = null; + if (genericMetadataBuilder_ != null) { + genericMetadataBuilder_.dispose(); + genericMetadataBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder + getGenericMetadataBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetGenericMetadataFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder + getGenericMetadataOrBuilder() { + if (genericMetadataBuilder_ != null) { + return genericMetadataBuilder_.getMessageOrBuilder(); + } else { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder> + internalGetGenericMetadataFieldBuilder() { + if (genericMetadataBuilder_ == null) { + genericMetadataBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder>( + getGenericMetadata(), getParentForChildren(), isClean()); + genericMetadata_ = null; + } + return genericMetadataBuilder_; + } + + private com.google.protobuf.Timestamp doneTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + doneTimeBuilder_; + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return Whether the doneTime field is set. + */ + public boolean hasDoneTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return The doneTime. + */ + public com.google.protobuf.Timestamp getDoneTime() { + if (doneTimeBuilder_ == null) { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } else { + return doneTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder setDoneTime(com.google.protobuf.Timestamp value) { + if (doneTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + doneTime_ = value; + } else { + doneTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder setDoneTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (doneTimeBuilder_ == null) { + doneTime_ = builderForValue.build(); + } else { + doneTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder mergeDoneTime(com.google.protobuf.Timestamp value) { + if (doneTimeBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && doneTime_ != null + && doneTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getDoneTimeBuilder().mergeFrom(value); + } else { + doneTime_ = value; + } + } else { + doneTimeBuilder_.mergeFrom(value); + } + if (doneTime_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public Builder clearDoneTime() { + bitField0_ = (bitField0_ & ~0x00000002); + doneTime_ = null; + if (doneTimeBuilder_ != null) { + doneTimeBuilder_.dispose(); + doneTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public com.google.protobuf.Timestamp.Builder getDoneTimeBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetDoneTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + public com.google.protobuf.TimestampOrBuilder getDoneTimeOrBuilder() { + if (doneTimeBuilder_ != null) { + return doneTimeBuilder_.getMessageOrBuilder(); + } else { + return doneTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : doneTime_; + } + } + + /** + * + * + *
+     * The time the operation was completed.
+     * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetDoneTimeFieldBuilder() { + if (doneTimeBuilder_ == null) { + doneTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getDoneTime(), getParentForChildren(), isClean()); + doneTime_ = null; + } + return doneTimeBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata) + private static final com.google.cloud.aiplatform.v1 + .DeleteAgentAnomalyDetectionScopeOperationMetadata + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata(); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = + new com.google.protobuf.AbstractParser< + DeleteAgentAnomalyDetectionScopeOperationMetadata>() { + @java.lang.Override + public DeleteAgentAnomalyDetectionScopeOperationMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser + parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser + getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeOperationMetadataOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeOperationMetadataOrBuilder.java new file mode 100644 index 000000000000..4e873687b0c7 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeOperationMetadataOrBuilder.java @@ -0,0 +1,102 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface DeleteAgentAnomalyDetectionScopeOperationMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + boolean hasGenericMetadata(); + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata(); + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder getGenericMetadataOrBuilder(); + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return Whether the doneTime field is set. + */ + boolean hasDoneTime(); + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + * + * @return The doneTime. + */ + com.google.protobuf.Timestamp getDoneTime(); + + /** + * + * + *
+   * The time the operation was completed.
+   * 
+ * + * .google.protobuf.Timestamp done_time = 2; + */ + com.google.protobuf.TimestampOrBuilder getDoneTimeOrBuilder(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeRequest.java new file mode 100644 index 000000000000..82ff58d03da4 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeRequest.java @@ -0,0 +1,641 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request message for
+ * [AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest} + */ +@com.google.protobuf.Generated +public final class DeleteAgentAnomalyDetectionScopeRequest + extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest) + DeleteAgentAnomalyDetectionScopeRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DeleteAgentAnomalyDetectionScopeRequest"); + } + + // Use DeleteAgentAnomalyDetectionScopeRequest.newBuilder() to construct. + private DeleteAgentAnomalyDetectionScopeRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DeleteAgentAnomalyDetectionScopeRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest.class, + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. The name of the AgentAnomalyDetectionScope resource to be
+   * deleted. Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The name of the AgentAnomalyDetectionScope resource to be
+   * deleted. Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest other = + (com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request message for
+   * [AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest) + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest.class, + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest.Builder.class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DeleteAgentAnomalyDetectionScopeRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest build() { + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest buildPartial() { + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest result = + new com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest) { + return mergeFrom( + (com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest other) { + if (other + == com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest + .getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. The name of the AgentAnomalyDetectionScope resource to be
+     * deleted. Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The name of the AgentAnomalyDetectionScope resource to be
+     * deleted. Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The name of the AgentAnomalyDetectionScope resource to be
+     * deleted. Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the AgentAnomalyDetectionScope resource to be
+     * deleted. Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the AgentAnomalyDetectionScope resource to be
+     * deleted. Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest) + private static final com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest(); + } + + public static com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteAgentAnomalyDetectionScopeRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeRequestOrBuilder.java new file mode 100644 index 000000000000..e64a4c0bfc3f --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DeleteAgentAnomalyDetectionScopeRequestOrBuilder.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface DeleteAgentAnomalyDetectionScopeRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the AgentAnomalyDetectionScope resource to be
+   * deleted. Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. The name of the AgentAnomalyDetectionScope resource to be
+   * deleted. Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentOperationMetadata.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentOperationMetadata.java new file mode 100644 index 000000000000..d991254448e5 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentOperationMetadata.java @@ -0,0 +1,722 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Metadata information for
+ * [AgentAnomalyDetectionService.DisableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DisableMonitoredAgent].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata} + */ +@com.google.protobuf.Generated +public final class DisableMonitoredAgentOperationMetadata + extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata) + DisableMonitoredAgentOperationMetadataOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DisableMonitoredAgentOperationMetadata"); + } + + // Use DisableMonitoredAgentOperationMetadata.newBuilder() to construct. + private DisableMonitoredAgentOperationMetadata( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DisableMonitoredAgentOperationMetadata() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentOperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentOperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata.class, + com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata.Builder.class); + } + + private int bitField0_; + public static final int GENERIC_METADATA_FIELD_NUMBER = 1; + private com.google.cloud.aiplatform.v1.GenericOperationMetadata genericMetadata_; + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + @java.lang.Override + public boolean hasGenericMetadata() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata() { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder + getGenericMetadataOrBuilder() { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getGenericMetadata()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getGenericMetadata()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata other = + (com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata) obj; + + if (hasGenericMetadata() != other.hasGenericMetadata()) return false; + if (hasGenericMetadata()) { + if (!getGenericMetadata().equals(other.getGenericMetadata())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasGenericMetadata()) { + hash = (37 * hash) + GENERIC_METADATA_FIELD_NUMBER; + hash = (53 * hash) + getGenericMetadata().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Metadata information for
+   * [AgentAnomalyDetectionService.DisableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DisableMonitoredAgent].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata) + com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentOperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentOperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata.class, + com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata.Builder.class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetGenericMetadataFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + genericMetadata_ = null; + if (genericMetadataBuilder_ != null) { + genericMetadataBuilder_.dispose(); + genericMetadataBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentOperationMetadata_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata build() { + com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata buildPartial() { + com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata result = + new com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.genericMetadata_ = + genericMetadataBuilder_ == null ? genericMetadata_ : genericMetadataBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata) { + return mergeFrom( + (com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata other) { + if (other + == com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata + .getDefaultInstance()) return this; + if (other.hasGenericMetadata()) { + mergeGenericMetadata(other.getGenericMetadata()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetGenericMetadataFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.aiplatform.v1.GenericOperationMetadata genericMetadata_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder> + genericMetadataBuilder_; + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + public boolean hasGenericMetadata() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata() { + if (genericMetadataBuilder_ == null) { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } else { + return genericMetadataBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder setGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata value) { + if (genericMetadataBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + genericMetadata_ = value; + } else { + genericMetadataBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder setGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder builderForValue) { + if (genericMetadataBuilder_ == null) { + genericMetadata_ = builderForValue.build(); + } else { + genericMetadataBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder mergeGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata value) { + if (genericMetadataBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && genericMetadata_ != null + && genericMetadata_ + != com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance()) { + getGenericMetadataBuilder().mergeFrom(value); + } else { + genericMetadata_ = value; + } + } else { + genericMetadataBuilder_.mergeFrom(value); + } + if (genericMetadata_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder clearGenericMetadata() { + bitField0_ = (bitField0_ & ~0x00000001); + genericMetadata_ = null; + if (genericMetadataBuilder_ != null) { + genericMetadataBuilder_.dispose(); + genericMetadataBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder + getGenericMetadataBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetGenericMetadataFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder + getGenericMetadataOrBuilder() { + if (genericMetadataBuilder_ != null) { + return genericMetadataBuilder_.getMessageOrBuilder(); + } else { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder> + internalGetGenericMetadataFieldBuilder() { + if (genericMetadataBuilder_ == null) { + genericMetadataBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder>( + getGenericMetadata(), getParentForChildren(), isClean()); + genericMetadata_ = null; + } + return genericMetadataBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata) + private static final com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata(); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DisableMonitoredAgentOperationMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentOperationMetadataOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentOperationMetadataOrBuilder.java new file mode 100644 index 000000000000..d932dcb99d8d --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentOperationMetadataOrBuilder.java @@ -0,0 +1,65 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface DisableMonitoredAgentOperationMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + boolean hasGenericMetadata(); + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata(); + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder getGenericMetadataOrBuilder(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentRequest.java new file mode 100644 index 000000000000..d65badc2ff36 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentRequest.java @@ -0,0 +1,627 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request message for
+ * [AgentAnomalyDetectionService.DisableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DisableMonitoredAgent].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.DisableMonitoredAgentRequest} + */ +@com.google.protobuf.Generated +public final class DisableMonitoredAgentRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.DisableMonitoredAgentRequest) + DisableMonitoredAgentRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DisableMonitoredAgentRequest"); + } + + // Use DisableMonitoredAgentRequest.newBuilder() to construct. + private DisableMonitoredAgentRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DisableMonitoredAgentRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest.class, + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource to be disabled.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource to be disabled.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest other = + (com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request message for
+   * [AgentAnomalyDetectionService.DisableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DisableMonitoredAgent].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.DisableMonitoredAgentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.DisableMonitoredAgentRequest) + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest.class, + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_DisableMonitoredAgentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest build() { + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest buildPartial() { + com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest result = + new com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest) { + return mergeFrom((com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest other) { + if (other == com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource to be disabled.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource to be disabled.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource to be disabled.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource to be disabled.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource to be disabled.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.DisableMonitoredAgentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.DisableMonitoredAgentRequest) + private static final com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest(); + } + + public static com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DisableMonitoredAgentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentRequestOrBuilder.java new file mode 100644 index 000000000000..3e9d46312bd5 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/DisableMonitoredAgentRequestOrBuilder.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface DisableMonitoredAgentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.DisableMonitoredAgentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource to be disabled.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource to be disabled.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentOperationMetadata.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentOperationMetadata.java new file mode 100644 index 000000000000..c6e8e74f76b2 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentOperationMetadata.java @@ -0,0 +1,722 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Metadata information for
+ * [AgentAnomalyDetectionService.EnableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.EnableMonitoredAgent].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata} + */ +@com.google.protobuf.Generated +public final class EnableMonitoredAgentOperationMetadata + extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata) + EnableMonitoredAgentOperationMetadataOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "EnableMonitoredAgentOperationMetadata"); + } + + // Use EnableMonitoredAgentOperationMetadata.newBuilder() to construct. + private EnableMonitoredAgentOperationMetadata( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private EnableMonitoredAgentOperationMetadata() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentOperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentOperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata.class, + com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata.Builder.class); + } + + private int bitField0_; + public static final int GENERIC_METADATA_FIELD_NUMBER = 1; + private com.google.cloud.aiplatform.v1.GenericOperationMetadata genericMetadata_; + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + @java.lang.Override + public boolean hasGenericMetadata() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata() { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder + getGenericMetadataOrBuilder() { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getGenericMetadata()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getGenericMetadata()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata other = + (com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata) obj; + + if (hasGenericMetadata() != other.hasGenericMetadata()) return false; + if (hasGenericMetadata()) { + if (!getGenericMetadata().equals(other.getGenericMetadata())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasGenericMetadata()) { + hash = (37 * hash) + GENERIC_METADATA_FIELD_NUMBER; + hash = (53 * hash) + getGenericMetadata().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Metadata information for
+   * [AgentAnomalyDetectionService.EnableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.EnableMonitoredAgent].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata) + com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentOperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentOperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata.class, + com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata.Builder.class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetGenericMetadataFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + genericMetadata_ = null; + if (genericMetadataBuilder_ != null) { + genericMetadataBuilder_.dispose(); + genericMetadataBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentOperationMetadata_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata build() { + com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata buildPartial() { + com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata result = + new com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.genericMetadata_ = + genericMetadataBuilder_ == null ? genericMetadata_ : genericMetadataBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata) { + return mergeFrom( + (com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata other) { + if (other + == com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata + .getDefaultInstance()) return this; + if (other.hasGenericMetadata()) { + mergeGenericMetadata(other.getGenericMetadata()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetGenericMetadataFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.aiplatform.v1.GenericOperationMetadata genericMetadata_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder> + genericMetadataBuilder_; + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + public boolean hasGenericMetadata() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata() { + if (genericMetadataBuilder_ == null) { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } else { + return genericMetadataBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder setGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata value) { + if (genericMetadataBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + genericMetadata_ = value; + } else { + genericMetadataBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder setGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder builderForValue) { + if (genericMetadataBuilder_ == null) { + genericMetadata_ = builderForValue.build(); + } else { + genericMetadataBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder mergeGenericMetadata( + com.google.cloud.aiplatform.v1.GenericOperationMetadata value) { + if (genericMetadataBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && genericMetadata_ != null + && genericMetadata_ + != com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance()) { + getGenericMetadataBuilder().mergeFrom(value); + } else { + genericMetadata_ = value; + } + } else { + genericMetadataBuilder_.mergeFrom(value); + } + if (genericMetadata_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public Builder clearGenericMetadata() { + bitField0_ = (bitField0_ & ~0x00000001); + genericMetadata_ = null; + if (genericMetadataBuilder_ != null) { + genericMetadataBuilder_.dispose(); + genericMetadataBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder + getGenericMetadataBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetGenericMetadataFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + public com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder + getGenericMetadataOrBuilder() { + if (genericMetadataBuilder_ != null) { + return genericMetadataBuilder_.getMessageOrBuilder(); + } else { + return genericMetadata_ == null + ? com.google.cloud.aiplatform.v1.GenericOperationMetadata.getDefaultInstance() + : genericMetadata_; + } + } + + /** + * + * + *
+     * The operation generic information.
+     * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder> + internalGetGenericMetadataFieldBuilder() { + if (genericMetadataBuilder_ == null) { + genericMetadataBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.GenericOperationMetadata, + com.google.cloud.aiplatform.v1.GenericOperationMetadata.Builder, + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder>( + getGenericMetadata(), getParentForChildren(), isClean()); + genericMetadata_ = null; + } + return genericMetadataBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata) + private static final com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata(); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EnableMonitoredAgentOperationMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentOperationMetadataOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentOperationMetadataOrBuilder.java new file mode 100644 index 000000000000..98ad77922fb1 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentOperationMetadataOrBuilder.java @@ -0,0 +1,65 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface EnableMonitoredAgentOperationMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return Whether the genericMetadata field is set. + */ + boolean hasGenericMetadata(); + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + * + * @return The genericMetadata. + */ + com.google.cloud.aiplatform.v1.GenericOperationMetadata getGenericMetadata(); + + /** + * + * + *
+   * The operation generic information.
+   * 
+ * + * .google.cloud.aiplatform.v1.GenericOperationMetadata generic_metadata = 1; + */ + com.google.cloud.aiplatform.v1.GenericOperationMetadataOrBuilder getGenericMetadataOrBuilder(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentRequest.java new file mode 100644 index 000000000000..29f8774aef10 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentRequest.java @@ -0,0 +1,627 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request message for
+ * [AgentAnomalyDetectionService.EnableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.EnableMonitoredAgent].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.EnableMonitoredAgentRequest} + */ +@com.google.protobuf.Generated +public final class EnableMonitoredAgentRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.EnableMonitoredAgentRequest) + EnableMonitoredAgentRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "EnableMonitoredAgentRequest"); + } + + // Use EnableMonitoredAgentRequest.newBuilder() to construct. + private EnableMonitoredAgentRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private EnableMonitoredAgentRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest.class, + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource to be enabled.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource to be enabled.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest other = + (com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request message for
+   * [AgentAnomalyDetectionService.EnableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.EnableMonitoredAgent].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.EnableMonitoredAgentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.EnableMonitoredAgentRequest) + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest.class, + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_EnableMonitoredAgentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest build() { + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest buildPartial() { + com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest result = + new com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest) { + return mergeFrom((com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest other) { + if (other == com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource to be enabled.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource to be enabled.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource to be enabled.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource to be enabled.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource to be enabled.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.EnableMonitoredAgentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.EnableMonitoredAgentRequest) + private static final com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest(); + } + + public static com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EnableMonitoredAgentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentRequestOrBuilder.java new file mode 100644 index 000000000000..9767d0269f1f --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/EnableMonitoredAgentRequestOrBuilder.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface EnableMonitoredAgentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.EnableMonitoredAgentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource to be enabled.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource to be enabled.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAgentAnomalyDetectionScopeRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAgentAnomalyDetectionScopeRequest.java new file mode 100644 index 000000000000..8eb17ab9b349 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAgentAnomalyDetectionScopeRequest.java @@ -0,0 +1,639 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request message for
+ * [AgentAnomalyDetectionService.GetAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.GetAgentAnomalyDetectionScope].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest} + */ +@com.google.protobuf.Generated +public final class GetAgentAnomalyDetectionScopeRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest) + GetAgentAnomalyDetectionScopeRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetAgentAnomalyDetectionScopeRequest"); + } + + // Use GetAgentAnomalyDetectionScopeRequest.newBuilder() to construct. + private GetAgentAnomalyDetectionScopeRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetAgentAnomalyDetectionScopeRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAgentAnomalyDetectionScopeRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAgentAnomalyDetectionScopeRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest.class, + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. The name of the AgentAnomalyDetectionScope resource.
+   * Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The name of the AgentAnomalyDetectionScope resource.
+   * Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest other = + (com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request message for
+   * [AgentAnomalyDetectionService.GetAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.GetAgentAnomalyDetectionScope].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest) + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAgentAnomalyDetectionScopeRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAgentAnomalyDetectionScopeRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest.class, + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest.Builder.class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAgentAnomalyDetectionScopeRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest build() { + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest buildPartial() { + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest result = + new com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest) { + return mergeFrom( + (com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest other) { + if (other + == com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest + .getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. The name of the AgentAnomalyDetectionScope resource.
+     * Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The name of the AgentAnomalyDetectionScope resource.
+     * Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The name of the AgentAnomalyDetectionScope resource.
+     * Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the AgentAnomalyDetectionScope resource.
+     * Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the AgentAnomalyDetectionScope resource.
+     * Format:
+     * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest) + private static final com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest(); + } + + public static com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetAgentAnomalyDetectionScopeRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAgentAnomalyDetectionScopeRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAgentAnomalyDetectionScopeRequestOrBuilder.java new file mode 100644 index 000000000000..e3ee8521d9c9 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAgentAnomalyDetectionScopeRequestOrBuilder.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface GetAgentAnomalyDetectionScopeRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the AgentAnomalyDetectionScope resource.
+   * Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. The name of the AgentAnomalyDetectionScope resource.
+   * Format:
+   * `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedInvocationRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedInvocationRequest.java new file mode 100644 index 000000000000..8945c581b459 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedInvocationRequest.java @@ -0,0 +1,625 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request to get the details of a specific analyzed invocation.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest} + */ +@com.google.protobuf.Generated +public final class GetAnalyzedInvocationRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest) + GetAnalyzedInvocationRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetAnalyzedInvocationRequest"); + } + + // Use GetAnalyzedInvocationRequest.newBuilder() to construct. + private GetAnalyzedInvocationRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetAnalyzedInvocationRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAnalyzedInvocationRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAnalyzedInvocationRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest.class, + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. The name of the AnalyzedInvocation resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The name of the AnalyzedInvocation resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest other = + (com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request to get the details of a specific analyzed invocation.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest) + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAnalyzedInvocationRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAnalyzedInvocationRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest.class, + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAnalyzedInvocationRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest build() { + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest buildPartial() { + com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest result = + new com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest) { + return mergeFrom((com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest other) { + if (other == com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. The name of the AnalyzedInvocation resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The name of the AnalyzedInvocation resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The name of the AnalyzedInvocation resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the AnalyzedInvocation resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the AnalyzedInvocation resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest) + private static final com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest(); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetAnalyzedInvocationRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedInvocationRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedInvocationRequestOrBuilder.java new file mode 100644 index 000000000000..5c5f96de8160 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedInvocationRequestOrBuilder.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface GetAnalyzedInvocationRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the AnalyzedInvocation resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. The name of the AnalyzedInvocation resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedSessionRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedSessionRequest.java new file mode 100644 index 000000000000..b368358958a7 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedSessionRequest.java @@ -0,0 +1,802 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request to get the details of a specific analyzed session.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.GetAnalyzedSessionRequest} + */ +@com.google.protobuf.Generated +public final class GetAnalyzedSessionRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.GetAnalyzedSessionRequest) + GetAnalyzedSessionRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetAnalyzedSessionRequest"); + } + + // Use GetAnalyzedSessionRequest.newBuilder() to construct. + private GetAnalyzedSessionRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetAnalyzedSessionRequest() { + name_ = ""; + view_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAnalyzedSessionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAnalyzedSessionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest.class, + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. The name of the AnalyzedSession resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The name of the AnalyzedSession resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VIEW_FIELD_NUMBER = 2; + private int view_ = 0; + + /** + * + * + *
+   * Optional. Resource view to control which fields are returned.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for view. + */ + @java.lang.Override + public int getViewValue() { + return view_; + } + + /** + * + * + *
+   * Optional. Resource view to control which fields are returned.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The view. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSessionView getView() { + com.google.cloud.aiplatform.v1.AnalyzedSessionView result = + com.google.cloud.aiplatform.v1.AnalyzedSessionView.forNumber(view_); + return result == null + ? com.google.cloud.aiplatform.v1.AnalyzedSessionView.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (view_ + != com.google.cloud.aiplatform.v1.AnalyzedSessionView.ANALYZED_SESSION_VIEW_UNSPECIFIED + .getNumber()) { + output.writeEnum(2, view_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (view_ + != com.google.cloud.aiplatform.v1.AnalyzedSessionView.ANALYZED_SESSION_VIEW_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, view_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest other = + (com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (view_ != other.view_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + VIEW_FIELD_NUMBER; + hash = (53 * hash) + view_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request to get the details of a specific analyzed session.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.GetAnalyzedSessionRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.GetAnalyzedSessionRequest) + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAnalyzedSessionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAnalyzedSessionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest.class, + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + view_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetAnalyzedSessionRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest build() { + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest buildPartial() { + com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest result = + new com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.view_ = view_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest) { + return mergeFrom((com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest other) { + if (other == com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.view_ != 0) { + setViewValue(other.getViewValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + view_ = input.readEnum(); + bitField0_ |= 0x00000002; + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. The name of the AnalyzedSession resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The name of the AnalyzedSession resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The name of the AnalyzedSession resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the AnalyzedSession resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the AnalyzedSession resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int view_ = 0; + + /** + * + * + *
+     * Optional. Resource view to control which fields are returned.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for view. + */ + @java.lang.Override + public int getViewValue() { + return view_; + } + + /** + * + * + *
+     * Optional. Resource view to control which fields are returned.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for view to set. + * @return This builder for chaining. + */ + public Builder setViewValue(int value) { + view_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Resource view to control which fields are returned.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The view. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSessionView getView() { + com.google.cloud.aiplatform.v1.AnalyzedSessionView result = + com.google.cloud.aiplatform.v1.AnalyzedSessionView.forNumber(view_); + return result == null + ? com.google.cloud.aiplatform.v1.AnalyzedSessionView.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Optional. Resource view to control which fields are returned.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The view to set. + * @return This builder for chaining. + */ + public Builder setView(com.google.cloud.aiplatform.v1.AnalyzedSessionView value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000002; + view_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Resource view to control which fields are returned.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearView() { + bitField0_ = (bitField0_ & ~0x00000002); + view_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.GetAnalyzedSessionRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.GetAnalyzedSessionRequest) + private static final com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest(); + } + + public static com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetAnalyzedSessionRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedSessionRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedSessionRequestOrBuilder.java new file mode 100644 index 000000000000..981b3465b9b2 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetAnalyzedSessionRequestOrBuilder.java @@ -0,0 +1,92 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface GetAnalyzedSessionRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.GetAnalyzedSessionRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the AnalyzedSession resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. The name of the AnalyzedSession resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Optional. Resource view to control which fields are returned.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for view. + */ + int getViewValue(); + + /** + * + * + *
+   * Optional. Resource view to control which fields are returned.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The view. + */ + com.google.cloud.aiplatform.v1.AnalyzedSessionView getView(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetMonitoredAgentRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetMonitoredAgentRequest.java new file mode 100644 index 000000000000..f66ef0383e98 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetMonitoredAgentRequest.java @@ -0,0 +1,627 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request message for
+ * [AgentAnomalyDetectionService.GetMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.GetMonitoredAgent].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.GetMonitoredAgentRequest} + */ +@com.google.protobuf.Generated +public final class GetMonitoredAgentRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.GetMonitoredAgentRequest) + GetMonitoredAgentRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetMonitoredAgentRequest"); + } + + // Use GetMonitoredAgentRequest.newBuilder() to construct. + private GetMonitoredAgentRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetMonitoredAgentRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetMonitoredAgentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetMonitoredAgentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest.class, + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest other = + (com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request message for
+   * [AgentAnomalyDetectionService.GetMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.GetMonitoredAgent].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.GetMonitoredAgentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.GetMonitoredAgentRequest) + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetMonitoredAgentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetMonitoredAgentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest.class, + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_GetMonitoredAgentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest build() { + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest buildPartial() { + com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest result = + new com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest) { + return mergeFrom((com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest other) { + if (other == com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The name of the MonitoredAgent resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.GetMonitoredAgentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.GetMonitoredAgentRequest) + private static final com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest(); + } + + public static com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetMonitoredAgentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetMonitoredAgentRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetMonitoredAgentRequestOrBuilder.java new file mode 100644 index 000000000000..b07ecd038f7c --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/GetMonitoredAgentRequestOrBuilder.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface GetMonitoredAgentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.GetMonitoredAgentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Required. The name of the MonitoredAgent resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesRequest.java new file mode 100644 index 000000000000..58bbbd96a2ee --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesRequest.java @@ -0,0 +1,934 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request message for
+ * [AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest} + */ +@com.google.protobuf.Generated +public final class ListAgentAnomalyDetectionScopesRequest + extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest) + ListAgentAnomalyDetectionScopesRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAgentAnomalyDetectionScopesRequest"); + } + + // Use ListAgentAnomalyDetectionScopesRequest.newBuilder() to construct. + private ListAgentAnomalyDetectionScopesRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAgentAnomalyDetectionScopesRequest() { + parent_ = ""; + pageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest.class, + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. The resource name of the Location to list the
+   * AgentAnomalyDetectionScopes from. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The resource name of the Location to list the
+   * AgentAnomalyDetectionScopes from. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. The standard list page size. The maximum value is 100; values
+   * above 100 will be coerced to 100. If unspecified, at most 10
+   * AgentAnomalyDetectionScopes will be returned.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest other = + (com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request message for
+   * [AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest) + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest.class, + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest.Builder.class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest build() { + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest buildPartial() { + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest result = + new com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest) { + return mergeFrom( + (com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest other) { + if (other + == com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest + .getDefaultInstance()) return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. The resource name of the Location to list the
+     * AgentAnomalyDetectionScopes from. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The resource name of the Location to list the
+     * AgentAnomalyDetectionScopes from. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The resource name of the Location to list the
+     * AgentAnomalyDetectionScopes from. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The resource name of the Location to list the
+     * AgentAnomalyDetectionScopes from. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The resource name of the Location to list the
+     * AgentAnomalyDetectionScopes from. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. The standard list page size. The maximum value is 100; values
+     * above 100 will be coerced to 100. If unspecified, at most 10
+     * AgentAnomalyDetectionScopes will be returned.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. The standard list page size. The maximum value is 100; values
+     * above 100 will be coerced to 100. If unspecified, at most 10
+     * AgentAnomalyDetectionScopes will be returned.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The standard list page size. The maximum value is 100; values
+     * above 100 will be coerced to 100. If unspecified, at most 10
+     * AgentAnomalyDetectionScopes will be returned.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest) + private static final com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest(); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAgentAnomalyDetectionScopesRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesRequestOrBuilder.java new file mode 100644 index 000000000000..c5498c599f3e --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesRequestOrBuilder.java @@ -0,0 +1,103 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface ListAgentAnomalyDetectionScopesRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The resource name of the Location to list the
+   * AgentAnomalyDetectionScopes from. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. The resource name of the Location to list the
+   * AgentAnomalyDetectionScopes from. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. The standard list page size. The maximum value is 100; values
+   * above 100 will be coerced to 100. If unspecified, at most 10
+   * AgentAnomalyDetectionScopes will be returned.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesResponse.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesResponse.java new file mode 100644 index 000000000000..fdd41bdca126 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesResponse.java @@ -0,0 +1,1237 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Response message for
+ * [AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse} + */ +@com.google.protobuf.Generated +public final class ListAgentAnomalyDetectionScopesResponse + extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse) + ListAgentAnomalyDetectionScopesResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAgentAnomalyDetectionScopesResponse"); + } + + // Use ListAgentAnomalyDetectionScopesResponse.newBuilder() to construct. + private ListAgentAnomalyDetectionScopesResponse( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAgentAnomalyDetectionScopesResponse() { + agentAnomalyDetectionScopes_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse.class, + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse.Builder.class); + } + + public static final int AGENT_ANOMALY_DETECTION_SCOPES_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List + agentAnomalyDetectionScopes_; + + /** + * + * + *
+   * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+   * the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + @java.lang.Override + public java.util.List + getAgentAnomalyDetectionScopesList() { + return agentAnomalyDetectionScopes_; + } + + /** + * + * + *
+   * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+   * the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder> + getAgentAnomalyDetectionScopesOrBuilderList() { + return agentAnomalyDetectionScopes_; + } + + /** + * + * + *
+   * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+   * the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + @java.lang.Override + public int getAgentAnomalyDetectionScopesCount() { + return agentAnomalyDetectionScopes_.size(); + } + + /** + * + * + *
+   * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+   * the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope getAgentAnomalyDetectionScopes( + int index) { + return agentAnomalyDetectionScopes_.get(index); + } + + /** + * + * + *
+   * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+   * the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder + getAgentAnomalyDetectionScopesOrBuilder(int index) { + return agentAnomalyDetectionScopes_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < agentAnomalyDetectionScopes_.size(); i++) { + output.writeMessage(1, agentAnomalyDetectionScopes_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < agentAnomalyDetectionScopes_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, agentAnomalyDetectionScopes_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse other = + (com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse) obj; + + if (!getAgentAnomalyDetectionScopesList().equals(other.getAgentAnomalyDetectionScopesList())) + return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getAgentAnomalyDetectionScopesCount() > 0) { + hash = (37 * hash) + AGENT_ANOMALY_DETECTION_SCOPES_FIELD_NUMBER; + hash = (53 * hash) + getAgentAnomalyDetectionScopesList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Response message for
+   * [AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse) + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse.class, + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse.Builder.class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (agentAnomalyDetectionScopesBuilder_ == null) { + agentAnomalyDetectionScopes_ = java.util.Collections.emptyList(); + } else { + agentAnomalyDetectionScopes_ = null; + agentAnomalyDetectionScopesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAgentAnomalyDetectionScopesResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse build() { + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse buildPartial() { + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse result = + new com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse result) { + if (agentAnomalyDetectionScopesBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + agentAnomalyDetectionScopes_ = + java.util.Collections.unmodifiableList(agentAnomalyDetectionScopes_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.agentAnomalyDetectionScopes_ = agentAnomalyDetectionScopes_; + } else { + result.agentAnomalyDetectionScopes_ = agentAnomalyDetectionScopesBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse) { + return mergeFrom( + (com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse other) { + if (other + == com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse + .getDefaultInstance()) return this; + if (agentAnomalyDetectionScopesBuilder_ == null) { + if (!other.agentAnomalyDetectionScopes_.isEmpty()) { + if (agentAnomalyDetectionScopes_.isEmpty()) { + agentAnomalyDetectionScopes_ = other.agentAnomalyDetectionScopes_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureAgentAnomalyDetectionScopesIsMutable(); + agentAnomalyDetectionScopes_.addAll(other.agentAnomalyDetectionScopes_); + } + onChanged(); + } + } else { + if (!other.agentAnomalyDetectionScopes_.isEmpty()) { + if (agentAnomalyDetectionScopesBuilder_.isEmpty()) { + agentAnomalyDetectionScopesBuilder_.dispose(); + agentAnomalyDetectionScopesBuilder_ = null; + agentAnomalyDetectionScopes_ = other.agentAnomalyDetectionScopes_; + bitField0_ = (bitField0_ & ~0x00000001); + agentAnomalyDetectionScopesBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetAgentAnomalyDetectionScopesFieldBuilder() + : null; + } else { + agentAnomalyDetectionScopesBuilder_.addAllMessages(other.agentAnomalyDetectionScopes_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope m = + input.readMessage( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.parser(), + extensionRegistry); + if (agentAnomalyDetectionScopesBuilder_ == null) { + ensureAgentAnomalyDetectionScopesIsMutable(); + agentAnomalyDetectionScopes_.add(m); + } else { + agentAnomalyDetectionScopesBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List + agentAnomalyDetectionScopes_ = java.util.Collections.emptyList(); + + private void ensureAgentAnomalyDetectionScopesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + agentAnomalyDetectionScopes_ = + new java.util.ArrayList( + agentAnomalyDetectionScopes_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder> + agentAnomalyDetectionScopesBuilder_; + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public java.util.List + getAgentAnomalyDetectionScopesList() { + if (agentAnomalyDetectionScopesBuilder_ == null) { + return java.util.Collections.unmodifiableList(agentAnomalyDetectionScopes_); + } else { + return agentAnomalyDetectionScopesBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public int getAgentAnomalyDetectionScopesCount() { + if (agentAnomalyDetectionScopesBuilder_ == null) { + return agentAnomalyDetectionScopes_.size(); + } else { + return agentAnomalyDetectionScopesBuilder_.getCount(); + } + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope getAgentAnomalyDetectionScopes( + int index) { + if (agentAnomalyDetectionScopesBuilder_ == null) { + return agentAnomalyDetectionScopes_.get(index); + } else { + return agentAnomalyDetectionScopesBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public Builder setAgentAnomalyDetectionScopes( + int index, com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope value) { + if (agentAnomalyDetectionScopesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAgentAnomalyDetectionScopesIsMutable(); + agentAnomalyDetectionScopes_.set(index, value); + onChanged(); + } else { + agentAnomalyDetectionScopesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public Builder setAgentAnomalyDetectionScopes( + int index, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder builderForValue) { + if (agentAnomalyDetectionScopesBuilder_ == null) { + ensureAgentAnomalyDetectionScopesIsMutable(); + agentAnomalyDetectionScopes_.set(index, builderForValue.build()); + onChanged(); + } else { + agentAnomalyDetectionScopesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public Builder addAgentAnomalyDetectionScopes( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope value) { + if (agentAnomalyDetectionScopesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAgentAnomalyDetectionScopesIsMutable(); + agentAnomalyDetectionScopes_.add(value); + onChanged(); + } else { + agentAnomalyDetectionScopesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public Builder addAgentAnomalyDetectionScopes( + int index, com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope value) { + if (agentAnomalyDetectionScopesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAgentAnomalyDetectionScopesIsMutable(); + agentAnomalyDetectionScopes_.add(index, value); + onChanged(); + } else { + agentAnomalyDetectionScopesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public Builder addAgentAnomalyDetectionScopes( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder builderForValue) { + if (agentAnomalyDetectionScopesBuilder_ == null) { + ensureAgentAnomalyDetectionScopesIsMutable(); + agentAnomalyDetectionScopes_.add(builderForValue.build()); + onChanged(); + } else { + agentAnomalyDetectionScopesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public Builder addAgentAnomalyDetectionScopes( + int index, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder builderForValue) { + if (agentAnomalyDetectionScopesBuilder_ == null) { + ensureAgentAnomalyDetectionScopesIsMutable(); + agentAnomalyDetectionScopes_.add(index, builderForValue.build()); + onChanged(); + } else { + agentAnomalyDetectionScopesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public Builder addAllAgentAnomalyDetectionScopes( + java.lang.Iterable + values) { + if (agentAnomalyDetectionScopesBuilder_ == null) { + ensureAgentAnomalyDetectionScopesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll( + values, agentAnomalyDetectionScopes_); + onChanged(); + } else { + agentAnomalyDetectionScopesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public Builder clearAgentAnomalyDetectionScopes() { + if (agentAnomalyDetectionScopesBuilder_ == null) { + agentAnomalyDetectionScopes_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + agentAnomalyDetectionScopesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public Builder removeAgentAnomalyDetectionScopes(int index) { + if (agentAnomalyDetectionScopesBuilder_ == null) { + ensureAgentAnomalyDetectionScopesIsMutable(); + agentAnomalyDetectionScopes_.remove(index); + onChanged(); + } else { + agentAnomalyDetectionScopesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder + getAgentAnomalyDetectionScopesBuilder(int index) { + return internalGetAgentAnomalyDetectionScopesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder + getAgentAnomalyDetectionScopesOrBuilder(int index) { + if (agentAnomalyDetectionScopesBuilder_ == null) { + return agentAnomalyDetectionScopes_.get(index); + } else { + return agentAnomalyDetectionScopesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public java.util.List< + ? extends com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder> + getAgentAnomalyDetectionScopesOrBuilderList() { + if (agentAnomalyDetectionScopesBuilder_ != null) { + return agentAnomalyDetectionScopesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(agentAnomalyDetectionScopes_); + } + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder + addAgentAnomalyDetectionScopesBuilder() { + return internalGetAgentAnomalyDetectionScopesFieldBuilder() + .addBuilder( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.getDefaultInstance()); + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder + addAgentAnomalyDetectionScopesBuilder(int index) { + return internalGetAgentAnomalyDetectionScopesFieldBuilder() + .addBuilder( + index, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.getDefaultInstance()); + } + + /** + * + * + *
+     * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+     * the request.
+     * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + public java.util.List + getAgentAnomalyDetectionScopesBuilderList() { + return internalGetAgentAnomalyDetectionScopesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder> + internalGetAgentAnomalyDetectionScopesFieldBuilder() { + if (agentAnomalyDetectionScopesBuilder_ == null) { + agentAnomalyDetectionScopesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope.Builder, + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder>( + agentAnomalyDetectionScopes_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + agentAnomalyDetectionScopes_ = null; + } + return agentAnomalyDetectionScopesBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse) + private static final com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse(); + } + + public static com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAgentAnomalyDetectionScopesResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesResponseOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesResponseOrBuilder.java new file mode 100644 index 000000000000..e26bc579d62e --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAgentAnomalyDetectionScopesResponseOrBuilder.java @@ -0,0 +1,130 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface ListAgentAnomalyDetectionScopesResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+   * the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + java.util.List + getAgentAnomalyDetectionScopesList(); + + /** + * + * + *
+   * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+   * the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope getAgentAnomalyDetectionScopes( + int index); + + /** + * + * + *
+   * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+   * the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + int getAgentAnomalyDetectionScopesCount(); + + /** + * + * + *
+   * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+   * the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + java.util.List + getAgentAnomalyDetectionScopesOrBuilderList(); + + /** + * + * + *
+   * A list of AgentAnomalyDetectionScopes that matches the specified filter in
+   * the request.
+   * 
+ * + * + * repeated .google.cloud.aiplatform.v1.AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + * + */ + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeOrBuilder + getAgentAnomalyDetectionScopesOrBuilder(int index); + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsRequest.java new file mode 100644 index 000000000000..2a8b0dc2fe2a --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsRequest.java @@ -0,0 +1,922 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request to list analyzed invocations.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest} + */ +@com.google.protobuf.Generated +public final class ListAnalyzedInvocationsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest) + ListAnalyzedInvocationsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAnalyzedInvocationsRequest"); + } + + // Use ListAnalyzedInvocationsRequest.newBuilder() to construct. + private ListAnalyzedInvocationsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAnalyzedInvocationsRequest() { + parent_ = ""; + pageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest.class, + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. The parent AnalyzedSession resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The parent AnalyzedSession resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. The maximum number of analyzed invocations to return.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. A page token, received from a previous `ListAnalyzedInvocations`
+   * call.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. A page token, received from a previous `ListAnalyzedInvocations`
+   * call.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest other = + (com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request to list analyzed invocations.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest) + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest.class, + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest build() { + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest buildPartial() { + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest result = + new com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest) { + return mergeFrom((com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest other) { + if (other + == com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. The parent AnalyzedSession resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The parent AnalyzedSession resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The parent AnalyzedSession resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The parent AnalyzedSession resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The parent AnalyzedSession resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. The maximum number of analyzed invocations to return.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. The maximum number of analyzed invocations to return.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The maximum number of analyzed invocations to return.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. A page token, received from a previous `ListAnalyzedInvocations`
+     * call.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. A page token, received from a previous `ListAnalyzedInvocations`
+     * call.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. A page token, received from a previous `ListAnalyzedInvocations`
+     * call.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A page token, received from a previous `ListAnalyzedInvocations`
+     * call.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A page token, received from a previous `ListAnalyzedInvocations`
+     * call.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest) + private static final com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest(); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAnalyzedInvocationsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsRequestOrBuilder.java new file mode 100644 index 000000000000..56429cef450c --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsRequestOrBuilder.java @@ -0,0 +1,103 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface ListAnalyzedInvocationsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The parent AnalyzedSession resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. The parent AnalyzedSession resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. The maximum number of analyzed invocations to return.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. A page token, received from a previous `ListAnalyzedInvocations`
+   * call.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. A page token, received from a previous `ListAnalyzedInvocations`
+   * call.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsResponse.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsResponse.java new file mode 100644 index 000000000000..a92bde6057f1 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsResponse.java @@ -0,0 +1,1154 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Response to list analyzed invocations.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse} + */ +@com.google.protobuf.Generated +public final class ListAnalyzedInvocationsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse) + ListAnalyzedInvocationsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAnalyzedInvocationsResponse"); + } + + // Use ListAnalyzedInvocationsResponse.newBuilder() to construct. + private ListAnalyzedInvocationsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAnalyzedInvocationsResponse() { + analyzedInvocations_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse.class, + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse.Builder.class); + } + + public static final int ANALYZED_INVOCATIONS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List analyzedInvocations_; + + /** + * + * + *
+   * The list of analyzed invocations.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + */ + @java.lang.Override + public java.util.List + getAnalyzedInvocationsList() { + return analyzedInvocations_; + } + + /** + * + * + *
+   * The list of analyzed invocations.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + */ + @java.lang.Override + public java.util.List + getAnalyzedInvocationsOrBuilderList() { + return analyzedInvocations_; + } + + /** + * + * + *
+   * The list of analyzed invocations.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + */ + @java.lang.Override + public int getAnalyzedInvocationsCount() { + return analyzedInvocations_.size(); + } + + /** + * + * + *
+   * The list of analyzed invocations.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedInvocation getAnalyzedInvocations(int index) { + return analyzedInvocations_.get(index); + } + + /** + * + * + *
+   * The list of analyzed invocations.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedInvocationOrBuilder getAnalyzedInvocationsOrBuilder( + int index) { + return analyzedInvocations_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * A token to retrieve the next page of results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * A token to retrieve the next page of results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < analyzedInvocations_.size(); i++) { + output.writeMessage(1, analyzedInvocations_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < analyzedInvocations_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, analyzedInvocations_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse other = + (com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse) obj; + + if (!getAnalyzedInvocationsList().equals(other.getAnalyzedInvocationsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getAnalyzedInvocationsCount() > 0) { + hash = (37 * hash) + ANALYZED_INVOCATIONS_FIELD_NUMBER; + hash = (53 * hash) + getAnalyzedInvocationsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Response to list analyzed invocations.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse) + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse.class, + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (analyzedInvocationsBuilder_ == null) { + analyzedInvocations_ = java.util.Collections.emptyList(); + } else { + analyzedInvocations_ = null; + analyzedInvocationsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedInvocationsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse build() { + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse buildPartial() { + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse result = + new com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse result) { + if (analyzedInvocationsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + analyzedInvocations_ = java.util.Collections.unmodifiableList(analyzedInvocations_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.analyzedInvocations_ = analyzedInvocations_; + } else { + result.analyzedInvocations_ = analyzedInvocationsBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse) { + return mergeFrom((com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse other) { + if (other + == com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse.getDefaultInstance()) + return this; + if (analyzedInvocationsBuilder_ == null) { + if (!other.analyzedInvocations_.isEmpty()) { + if (analyzedInvocations_.isEmpty()) { + analyzedInvocations_ = other.analyzedInvocations_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureAnalyzedInvocationsIsMutable(); + analyzedInvocations_.addAll(other.analyzedInvocations_); + } + onChanged(); + } + } else { + if (!other.analyzedInvocations_.isEmpty()) { + if (analyzedInvocationsBuilder_.isEmpty()) { + analyzedInvocationsBuilder_.dispose(); + analyzedInvocationsBuilder_ = null; + analyzedInvocations_ = other.analyzedInvocations_; + bitField0_ = (bitField0_ & ~0x00000001); + analyzedInvocationsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetAnalyzedInvocationsFieldBuilder() + : null; + } else { + analyzedInvocationsBuilder_.addAllMessages(other.analyzedInvocations_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.aiplatform.v1.AnalyzedInvocation m = + input.readMessage( + com.google.cloud.aiplatform.v1.AnalyzedInvocation.parser(), + extensionRegistry); + if (analyzedInvocationsBuilder_ == null) { + ensureAnalyzedInvocationsIsMutable(); + analyzedInvocations_.add(m); + } else { + analyzedInvocationsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List analyzedInvocations_ = + java.util.Collections.emptyList(); + + private void ensureAnalyzedInvocationsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + analyzedInvocations_ = + new java.util.ArrayList( + analyzedInvocations_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AnalyzedInvocation, + com.google.cloud.aiplatform.v1.AnalyzedInvocation.Builder, + com.google.cloud.aiplatform.v1.AnalyzedInvocationOrBuilder> + analyzedInvocationsBuilder_; + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public java.util.List + getAnalyzedInvocationsList() { + if (analyzedInvocationsBuilder_ == null) { + return java.util.Collections.unmodifiableList(analyzedInvocations_); + } else { + return analyzedInvocationsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public int getAnalyzedInvocationsCount() { + if (analyzedInvocationsBuilder_ == null) { + return analyzedInvocations_.size(); + } else { + return analyzedInvocationsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public com.google.cloud.aiplatform.v1.AnalyzedInvocation getAnalyzedInvocations(int index) { + if (analyzedInvocationsBuilder_ == null) { + return analyzedInvocations_.get(index); + } else { + return analyzedInvocationsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public Builder setAnalyzedInvocations( + int index, com.google.cloud.aiplatform.v1.AnalyzedInvocation value) { + if (analyzedInvocationsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAnalyzedInvocationsIsMutable(); + analyzedInvocations_.set(index, value); + onChanged(); + } else { + analyzedInvocationsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public Builder setAnalyzedInvocations( + int index, com.google.cloud.aiplatform.v1.AnalyzedInvocation.Builder builderForValue) { + if (analyzedInvocationsBuilder_ == null) { + ensureAnalyzedInvocationsIsMutable(); + analyzedInvocations_.set(index, builderForValue.build()); + onChanged(); + } else { + analyzedInvocationsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public Builder addAnalyzedInvocations(com.google.cloud.aiplatform.v1.AnalyzedInvocation value) { + if (analyzedInvocationsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAnalyzedInvocationsIsMutable(); + analyzedInvocations_.add(value); + onChanged(); + } else { + analyzedInvocationsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public Builder addAnalyzedInvocations( + int index, com.google.cloud.aiplatform.v1.AnalyzedInvocation value) { + if (analyzedInvocationsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAnalyzedInvocationsIsMutable(); + analyzedInvocations_.add(index, value); + onChanged(); + } else { + analyzedInvocationsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public Builder addAnalyzedInvocations( + com.google.cloud.aiplatform.v1.AnalyzedInvocation.Builder builderForValue) { + if (analyzedInvocationsBuilder_ == null) { + ensureAnalyzedInvocationsIsMutable(); + analyzedInvocations_.add(builderForValue.build()); + onChanged(); + } else { + analyzedInvocationsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public Builder addAnalyzedInvocations( + int index, com.google.cloud.aiplatform.v1.AnalyzedInvocation.Builder builderForValue) { + if (analyzedInvocationsBuilder_ == null) { + ensureAnalyzedInvocationsIsMutable(); + analyzedInvocations_.add(index, builderForValue.build()); + onChanged(); + } else { + analyzedInvocationsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public Builder addAllAnalyzedInvocations( + java.lang.Iterable values) { + if (analyzedInvocationsBuilder_ == null) { + ensureAnalyzedInvocationsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, analyzedInvocations_); + onChanged(); + } else { + analyzedInvocationsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public Builder clearAnalyzedInvocations() { + if (analyzedInvocationsBuilder_ == null) { + analyzedInvocations_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + analyzedInvocationsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public Builder removeAnalyzedInvocations(int index) { + if (analyzedInvocationsBuilder_ == null) { + ensureAnalyzedInvocationsIsMutable(); + analyzedInvocations_.remove(index); + onChanged(); + } else { + analyzedInvocationsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public com.google.cloud.aiplatform.v1.AnalyzedInvocation.Builder getAnalyzedInvocationsBuilder( + int index) { + return internalGetAnalyzedInvocationsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public com.google.cloud.aiplatform.v1.AnalyzedInvocationOrBuilder + getAnalyzedInvocationsOrBuilder(int index) { + if (analyzedInvocationsBuilder_ == null) { + return analyzedInvocations_.get(index); + } else { + return analyzedInvocationsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public java.util.List + getAnalyzedInvocationsOrBuilderList() { + if (analyzedInvocationsBuilder_ != null) { + return analyzedInvocationsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(analyzedInvocations_); + } + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public com.google.cloud.aiplatform.v1.AnalyzedInvocation.Builder + addAnalyzedInvocationsBuilder() { + return internalGetAnalyzedInvocationsFieldBuilder() + .addBuilder(com.google.cloud.aiplatform.v1.AnalyzedInvocation.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public com.google.cloud.aiplatform.v1.AnalyzedInvocation.Builder addAnalyzedInvocationsBuilder( + int index) { + return internalGetAnalyzedInvocationsFieldBuilder() + .addBuilder( + index, com.google.cloud.aiplatform.v1.AnalyzedInvocation.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of analyzed invocations.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + * + */ + public java.util.List + getAnalyzedInvocationsBuilderList() { + return internalGetAnalyzedInvocationsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AnalyzedInvocation, + com.google.cloud.aiplatform.v1.AnalyzedInvocation.Builder, + com.google.cloud.aiplatform.v1.AnalyzedInvocationOrBuilder> + internalGetAnalyzedInvocationsFieldBuilder() { + if (analyzedInvocationsBuilder_ == null) { + analyzedInvocationsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AnalyzedInvocation, + com.google.cloud.aiplatform.v1.AnalyzedInvocation.Builder, + com.google.cloud.aiplatform.v1.AnalyzedInvocationOrBuilder>( + analyzedInvocations_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + analyzedInvocations_ = null; + } + return analyzedInvocationsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * A token to retrieve the next page of results.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * A token to retrieve the next page of results.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * A token to retrieve the next page of results.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * A token to retrieve the next page of results.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * A token to retrieve the next page of results.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse) + private static final com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse(); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAnalyzedInvocationsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsResponseOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsResponseOrBuilder.java new file mode 100644 index 000000000000..a284b8255555 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedInvocationsResponseOrBuilder.java @@ -0,0 +1,111 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface ListAnalyzedInvocationsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of analyzed invocations.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + */ + java.util.List getAnalyzedInvocationsList(); + + /** + * + * + *
+   * The list of analyzed invocations.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + */ + com.google.cloud.aiplatform.v1.AnalyzedInvocation getAnalyzedInvocations(int index); + + /** + * + * + *
+   * The list of analyzed invocations.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + */ + int getAnalyzedInvocationsCount(); + + /** + * + * + *
+   * The list of analyzed invocations.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + */ + java.util.List + getAnalyzedInvocationsOrBuilderList(); + + /** + * + * + *
+   * The list of analyzed invocations.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedInvocation analyzed_invocations = 1; + */ + com.google.cloud.aiplatform.v1.AnalyzedInvocationOrBuilder getAnalyzedInvocationsOrBuilder( + int index); + + /** + * + * + *
+   * A token to retrieve the next page of results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * A token to retrieve the next page of results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsRequest.java new file mode 100644 index 000000000000..2aada35665cc --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsRequest.java @@ -0,0 +1,1900 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request to list analyzed sessions.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest} + */ +@com.google.protobuf.Generated +public final class ListAnalyzedSessionsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest) + ListAnalyzedSessionsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAnalyzedSessionsRequest"); + } + + // Use ListAnalyzedSessionsRequest.newBuilder() to construct. + private ListAnalyzedSessionsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAnalyzedSessionsRequest() { + parent_ = ""; + pageToken_ = ""; + filter_ = ""; + view_ = 0; + orderBy_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest.class, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. The parent MonitoredAgent resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The parent MonitoredAgent resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. The maximum number of analyzed sessions to return.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. A page token, received from a previous `ListAnalyzedSessions`
+   * call.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. A page token, received from a previous `ListAnalyzedSessions`
+   * call.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object filter_ = ""; + + /** + * + * + *
+   * Optional. Filter expression restricting which AnalyzedSessions are
+   * returned. Supports a subset of AIP-160: a closed `detection_time` window
+   * (both bounds required), an equality on `severity`, an equality on
+   * `agent_type`, and an equality on `session_id`, joined by `AND`. Each
+   * clause is optional, may appear at most once, and may appear in any order.
+   *
+   * The `severity` value is the **canonical** `Severity` enum name --
+   * `SEVERITY_CRITICAL`, `SEVERITY_HIGH`, `SEVERITY_MEDIUM` or `SEVERITY_LOW`.
+   * Short forms such as `"CRITICAL"` are rejected, as is
+   * `SEVERITY_UNSPECIFIED`. It matches sessions whose *maximum* severity equals
+   * that bucket: a session that fires at both LOW and CRITICAL matches
+   * `severity = "SEVERITY_CRITICAL"`, not `severity = "SEVERITY_LOW"`.
+   *
+   * The `agent_type` value is the canonical `AgentResource.AgentType` enum name
+   * -- `REASONING_ENGINE`, `CLOUD_RUN_SERVICE`, `GKE_WORKLOAD`, `GCE_INSTANCE`,
+   * `AWS`, `AZURE`, `AGENT_TYPE_OTHER` or `AGENT_TYPE_UNSPECIFIED` -- and
+   * matches sessions run by an agent on that runtime.
+   *
+   * Unlike `severity`, `agent_type` accepts its `UNSPECIFIED` value. The two
+   * are not analogous: a session always has a computed severity bucket, so
+   * `SEVERITY_UNSPECIFIED` is never returned and filtering on it could only
+   * match nothing. `AGENT_TYPE_UNSPECIFIED` *is* returned -- it is what
+   * `AnalyzedSession.agent_type` reports for an agent whose runtime was never
+   * recorded -- so it must remain filterable.
+   *
+   * The `session_id` value is a case-sensitive exact match (no substring or
+   * prefix matching) on `AnalyzedSession.session_id`. Unlike `severity` and
+   * `agent_type` it is not a closed enum, so any non-empty value is accepted;
+   * an empty value (`session_id = ""`) is rejected rather than treated as "no
+   * filter".
+   *
+   * Example (time window, severity and runtime):
+   *
+   * ```
+   * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+   * "2024-01-08T00:00:00Z" AND severity = "SEVERITY_CRITICAL" AND agent_type =
+   * "CLOUD_RUN_SERVICE"
+   * ```
+   *
+   * If empty, results are restricted to the last 7 days with no severity,
+   * runtime, or session restriction. Other fields, additional operators, set
+   * membership (`IN`), and boolean combinations (`OR`, `NOT`, parentheses) are
+   * not yet supported.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Filter expression restricting which AnalyzedSessions are
+   * returned. Supports a subset of AIP-160: a closed `detection_time` window
+   * (both bounds required), an equality on `severity`, an equality on
+   * `agent_type`, and an equality on `session_id`, joined by `AND`. Each
+   * clause is optional, may appear at most once, and may appear in any order.
+   *
+   * The `severity` value is the **canonical** `Severity` enum name --
+   * `SEVERITY_CRITICAL`, `SEVERITY_HIGH`, `SEVERITY_MEDIUM` or `SEVERITY_LOW`.
+   * Short forms such as `"CRITICAL"` are rejected, as is
+   * `SEVERITY_UNSPECIFIED`. It matches sessions whose *maximum* severity equals
+   * that bucket: a session that fires at both LOW and CRITICAL matches
+   * `severity = "SEVERITY_CRITICAL"`, not `severity = "SEVERITY_LOW"`.
+   *
+   * The `agent_type` value is the canonical `AgentResource.AgentType` enum name
+   * -- `REASONING_ENGINE`, `CLOUD_RUN_SERVICE`, `GKE_WORKLOAD`, `GCE_INSTANCE`,
+   * `AWS`, `AZURE`, `AGENT_TYPE_OTHER` or `AGENT_TYPE_UNSPECIFIED` -- and
+   * matches sessions run by an agent on that runtime.
+   *
+   * Unlike `severity`, `agent_type` accepts its `UNSPECIFIED` value. The two
+   * are not analogous: a session always has a computed severity bucket, so
+   * `SEVERITY_UNSPECIFIED` is never returned and filtering on it could only
+   * match nothing. `AGENT_TYPE_UNSPECIFIED` *is* returned -- it is what
+   * `AnalyzedSession.agent_type` reports for an agent whose runtime was never
+   * recorded -- so it must remain filterable.
+   *
+   * The `session_id` value is a case-sensitive exact match (no substring or
+   * prefix matching) on `AnalyzedSession.session_id`. Unlike `severity` and
+   * `agent_type` it is not a closed enum, so any non-empty value is accepted;
+   * an empty value (`session_id = ""`) is rejected rather than treated as "no
+   * filter".
+   *
+   * Example (time window, severity and runtime):
+   *
+   * ```
+   * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+   * "2024-01-08T00:00:00Z" AND severity = "SEVERITY_CRITICAL" AND agent_type =
+   * "CLOUD_RUN_SERVICE"
+   * ```
+   *
+   * If empty, results are restricted to the last 7 days with no severity,
+   * runtime, or session restriction. Other fields, additional operators, set
+   * membership (`IN`), and boolean combinations (`OR`, `NOT`, parentheses) are
+   * not yet supported.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VIEW_FIELD_NUMBER = 5; + private int view_ = 0; + + /** + * + * + *
+   * Optional. Resource view to control which fields are returned.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for view. + */ + @java.lang.Override + public int getViewValue() { + return view_; + } + + /** + * + * + *
+   * Optional. Resource view to control which fields are returned.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The view. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSessionView getView() { + com.google.cloud.aiplatform.v1.AnalyzedSessionView result = + com.google.cloud.aiplatform.v1.AnalyzedSessionView.forNumber(view_); + return result == null + ? com.google.cloud.aiplatform.v1.AnalyzedSessionView.UNRECOGNIZED + : result; + } + + public static final int ORDER_BY_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private volatile java.lang.Object orderBy_ = ""; + + /** + * + * + *
+   * Optional. Comma-separated list of fields to sort by, following AIP-132
+   * syntax. The default sort direction is ascending; append " desc" to a
+   * field to sort descending.
+   *
+   * Supported fields (any other field yields INVALID_ARGUMENT):
+   *
+   * * `latest_detection_time` - the session's most-recent flagged detection
+   * time. `latest_detection_time desc` puts the newest sessions first.
+   * * `max_severity_rank` - the session's bucketed maximum severity, ranked
+   * LOW=1 < MEDIUM=2 < HIGH=3 < CRITICAL=4. `max_severity_rank desc` puts
+   * the most-severe sessions first.
+   * * `agent_display_name` - the MonitoredAgent's display name. Sorted as a
+   * STRING (case-sensitive, code-point order).
+   *
+   * If empty, defaults to `latest_detection_time desc`. Multi-field sort
+   * (for example, `max_severity_rank desc, latest_detection_time desc`) is
+   * supported.
+   *
+   * The `order_by` value MUST match the value used on the call that minted any
+   * supplied `page_token` (AIP-158). Mismatches yield INVALID_ARGUMENT.
+   * 
+ * + * string order_by = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + @java.lang.Override + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. Comma-separated list of fields to sort by, following AIP-132
+   * syntax. The default sort direction is ascending; append " desc" to a
+   * field to sort descending.
+   *
+   * Supported fields (any other field yields INVALID_ARGUMENT):
+   *
+   * * `latest_detection_time` - the session's most-recent flagged detection
+   * time. `latest_detection_time desc` puts the newest sessions first.
+   * * `max_severity_rank` - the session's bucketed maximum severity, ranked
+   * LOW=1 < MEDIUM=2 < HIGH=3 < CRITICAL=4. `max_severity_rank desc` puts
+   * the most-severe sessions first.
+   * * `agent_display_name` - the MonitoredAgent's display name. Sorted as a
+   * STRING (case-sensitive, code-point order).
+   *
+   * If empty, defaults to `latest_detection_time desc`. Multi-field sort
+   * (for example, `max_severity_rank desc, latest_detection_time desc`) is
+   * supported.
+   *
+   * The `order_by` value MUST match the value used on the call that minted any
+   * supplied `page_token` (AIP-158). Mismatches yield INVALID_ARGUMENT.
+   * 
+ * + * string order_by = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + @java.lang.Override + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, filter_); + } + if (view_ + != com.google.cloud.aiplatform.v1.AnalyzedSessionView.ANALYZED_SESSION_VIEW_UNSPECIFIED + .getNumber()) { + output.writeEnum(5, view_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, orderBy_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, filter_); + } + if (view_ + != com.google.cloud.aiplatform.v1.AnalyzedSessionView.ANALYZED_SESSION_VIEW_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, view_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(6, orderBy_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest other = + (com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (view_ != other.view_) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (37 * hash) + VIEW_FIELD_NUMBER; + hash = (53 * hash) + view_; + hash = (37 * hash) + ORDER_BY_FIELD_NUMBER; + hash = (53 * hash) + getOrderBy().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request to list analyzed sessions.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest) + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest.class, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + filter_ = ""; + view_ = 0; + orderBy_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest build() { + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest buildPartial() { + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest result = + new com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.filter_ = filter_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.view_ = view_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.orderBy_ = orderBy_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest) { + return mergeFrom((com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest other) { + if (other == com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (other.view_ != 0) { + setViewValue(other.getViewValue()); + } + if (!other.getOrderBy().isEmpty()) { + orderBy_ = other.orderBy_; + bitField0_ |= 0x00000020; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + filter_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 40: + { + view_ = input.readEnum(); + bitField0_ |= 0x00000010; + break; + } // case 40 + case 50: + { + orderBy_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000020; + break; + } // case 50 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. The parent MonitoredAgent resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The parent MonitoredAgent resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The parent MonitoredAgent resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The parent MonitoredAgent resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The parent MonitoredAgent resource.
+     * Format:
+     * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. The maximum number of analyzed sessions to return.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. The maximum number of analyzed sessions to return.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The maximum number of analyzed sessions to return.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. A page token, received from a previous `ListAnalyzedSessions`
+     * call.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. A page token, received from a previous `ListAnalyzedSessions`
+     * call.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. A page token, received from a previous `ListAnalyzedSessions`
+     * call.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A page token, received from a previous `ListAnalyzedSessions`
+     * call.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. A page token, received from a previous `ListAnalyzedSessions`
+     * call.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + + /** + * + * + *
+     * Optional. Filter expression restricting which AnalyzedSessions are
+     * returned. Supports a subset of AIP-160: a closed `detection_time` window
+     * (both bounds required), an equality on `severity`, an equality on
+     * `agent_type`, and an equality on `session_id`, joined by `AND`. Each
+     * clause is optional, may appear at most once, and may appear in any order.
+     *
+     * The `severity` value is the **canonical** `Severity` enum name --
+     * `SEVERITY_CRITICAL`, `SEVERITY_HIGH`, `SEVERITY_MEDIUM` or `SEVERITY_LOW`.
+     * Short forms such as `"CRITICAL"` are rejected, as is
+     * `SEVERITY_UNSPECIFIED`. It matches sessions whose *maximum* severity equals
+     * that bucket: a session that fires at both LOW and CRITICAL matches
+     * `severity = "SEVERITY_CRITICAL"`, not `severity = "SEVERITY_LOW"`.
+     *
+     * The `agent_type` value is the canonical `AgentResource.AgentType` enum name
+     * -- `REASONING_ENGINE`, `CLOUD_RUN_SERVICE`, `GKE_WORKLOAD`, `GCE_INSTANCE`,
+     * `AWS`, `AZURE`, `AGENT_TYPE_OTHER` or `AGENT_TYPE_UNSPECIFIED` -- and
+     * matches sessions run by an agent on that runtime.
+     *
+     * Unlike `severity`, `agent_type` accepts its `UNSPECIFIED` value. The two
+     * are not analogous: a session always has a computed severity bucket, so
+     * `SEVERITY_UNSPECIFIED` is never returned and filtering on it could only
+     * match nothing. `AGENT_TYPE_UNSPECIFIED` *is* returned -- it is what
+     * `AnalyzedSession.agent_type` reports for an agent whose runtime was never
+     * recorded -- so it must remain filterable.
+     *
+     * The `session_id` value is a case-sensitive exact match (no substring or
+     * prefix matching) on `AnalyzedSession.session_id`. Unlike `severity` and
+     * `agent_type` it is not a closed enum, so any non-empty value is accepted;
+     * an empty value (`session_id = ""`) is rejected rather than treated as "no
+     * filter".
+     *
+     * Example (time window, severity and runtime):
+     *
+     * ```
+     * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+     * "2024-01-08T00:00:00Z" AND severity = "SEVERITY_CRITICAL" AND agent_type =
+     * "CLOUD_RUN_SERVICE"
+     * ```
+     *
+     * If empty, results are restricted to the last 7 days with no severity,
+     * runtime, or session restriction. Other fields, additional operators, set
+     * membership (`IN`), and boolean combinations (`OR`, `NOT`, parentheses) are
+     * not yet supported.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Filter expression restricting which AnalyzedSessions are
+     * returned. Supports a subset of AIP-160: a closed `detection_time` window
+     * (both bounds required), an equality on `severity`, an equality on
+     * `agent_type`, and an equality on `session_id`, joined by `AND`. Each
+     * clause is optional, may appear at most once, and may appear in any order.
+     *
+     * The `severity` value is the **canonical** `Severity` enum name --
+     * `SEVERITY_CRITICAL`, `SEVERITY_HIGH`, `SEVERITY_MEDIUM` or `SEVERITY_LOW`.
+     * Short forms such as `"CRITICAL"` are rejected, as is
+     * `SEVERITY_UNSPECIFIED`. It matches sessions whose *maximum* severity equals
+     * that bucket: a session that fires at both LOW and CRITICAL matches
+     * `severity = "SEVERITY_CRITICAL"`, not `severity = "SEVERITY_LOW"`.
+     *
+     * The `agent_type` value is the canonical `AgentResource.AgentType` enum name
+     * -- `REASONING_ENGINE`, `CLOUD_RUN_SERVICE`, `GKE_WORKLOAD`, `GCE_INSTANCE`,
+     * `AWS`, `AZURE`, `AGENT_TYPE_OTHER` or `AGENT_TYPE_UNSPECIFIED` -- and
+     * matches sessions run by an agent on that runtime.
+     *
+     * Unlike `severity`, `agent_type` accepts its `UNSPECIFIED` value. The two
+     * are not analogous: a session always has a computed severity bucket, so
+     * `SEVERITY_UNSPECIFIED` is never returned and filtering on it could only
+     * match nothing. `AGENT_TYPE_UNSPECIFIED` *is* returned -- it is what
+     * `AnalyzedSession.agent_type` reports for an agent whose runtime was never
+     * recorded -- so it must remain filterable.
+     *
+     * The `session_id` value is a case-sensitive exact match (no substring or
+     * prefix matching) on `AnalyzedSession.session_id`. Unlike `severity` and
+     * `agent_type` it is not a closed enum, so any non-empty value is accepted;
+     * an empty value (`session_id = ""`) is rejected rather than treated as "no
+     * filter".
+     *
+     * Example (time window, severity and runtime):
+     *
+     * ```
+     * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+     * "2024-01-08T00:00:00Z" AND severity = "SEVERITY_CRITICAL" AND agent_type =
+     * "CLOUD_RUN_SERVICE"
+     * ```
+     *
+     * If empty, results are restricted to the last 7 days with no severity,
+     * runtime, or session restriction. Other fields, additional operators, set
+     * membership (`IN`), and boolean combinations (`OR`, `NOT`, parentheses) are
+     * not yet supported.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Filter expression restricting which AnalyzedSessions are
+     * returned. Supports a subset of AIP-160: a closed `detection_time` window
+     * (both bounds required), an equality on `severity`, an equality on
+     * `agent_type`, and an equality on `session_id`, joined by `AND`. Each
+     * clause is optional, may appear at most once, and may appear in any order.
+     *
+     * The `severity` value is the **canonical** `Severity` enum name --
+     * `SEVERITY_CRITICAL`, `SEVERITY_HIGH`, `SEVERITY_MEDIUM` or `SEVERITY_LOW`.
+     * Short forms such as `"CRITICAL"` are rejected, as is
+     * `SEVERITY_UNSPECIFIED`. It matches sessions whose *maximum* severity equals
+     * that bucket: a session that fires at both LOW and CRITICAL matches
+     * `severity = "SEVERITY_CRITICAL"`, not `severity = "SEVERITY_LOW"`.
+     *
+     * The `agent_type` value is the canonical `AgentResource.AgentType` enum name
+     * -- `REASONING_ENGINE`, `CLOUD_RUN_SERVICE`, `GKE_WORKLOAD`, `GCE_INSTANCE`,
+     * `AWS`, `AZURE`, `AGENT_TYPE_OTHER` or `AGENT_TYPE_UNSPECIFIED` -- and
+     * matches sessions run by an agent on that runtime.
+     *
+     * Unlike `severity`, `agent_type` accepts its `UNSPECIFIED` value. The two
+     * are not analogous: a session always has a computed severity bucket, so
+     * `SEVERITY_UNSPECIFIED` is never returned and filtering on it could only
+     * match nothing. `AGENT_TYPE_UNSPECIFIED` *is* returned -- it is what
+     * `AnalyzedSession.agent_type` reports for an agent whose runtime was never
+     * recorded -- so it must remain filterable.
+     *
+     * The `session_id` value is a case-sensitive exact match (no substring or
+     * prefix matching) on `AnalyzedSession.session_id`. Unlike `severity` and
+     * `agent_type` it is not a closed enum, so any non-empty value is accepted;
+     * an empty value (`session_id = ""`) is rejected rather than treated as "no
+     * filter".
+     *
+     * Example (time window, severity and runtime):
+     *
+     * ```
+     * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+     * "2024-01-08T00:00:00Z" AND severity = "SEVERITY_CRITICAL" AND agent_type =
+     * "CLOUD_RUN_SERVICE"
+     * ```
+     *
+     * If empty, results are restricted to the last 7 days with no severity,
+     * runtime, or session restriction. Other fields, additional operators, set
+     * membership (`IN`), and boolean combinations (`OR`, `NOT`, parentheses) are
+     * not yet supported.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Filter expression restricting which AnalyzedSessions are
+     * returned. Supports a subset of AIP-160: a closed `detection_time` window
+     * (both bounds required), an equality on `severity`, an equality on
+     * `agent_type`, and an equality on `session_id`, joined by `AND`. Each
+     * clause is optional, may appear at most once, and may appear in any order.
+     *
+     * The `severity` value is the **canonical** `Severity` enum name --
+     * `SEVERITY_CRITICAL`, `SEVERITY_HIGH`, `SEVERITY_MEDIUM` or `SEVERITY_LOW`.
+     * Short forms such as `"CRITICAL"` are rejected, as is
+     * `SEVERITY_UNSPECIFIED`. It matches sessions whose *maximum* severity equals
+     * that bucket: a session that fires at both LOW and CRITICAL matches
+     * `severity = "SEVERITY_CRITICAL"`, not `severity = "SEVERITY_LOW"`.
+     *
+     * The `agent_type` value is the canonical `AgentResource.AgentType` enum name
+     * -- `REASONING_ENGINE`, `CLOUD_RUN_SERVICE`, `GKE_WORKLOAD`, `GCE_INSTANCE`,
+     * `AWS`, `AZURE`, `AGENT_TYPE_OTHER` or `AGENT_TYPE_UNSPECIFIED` -- and
+     * matches sessions run by an agent on that runtime.
+     *
+     * Unlike `severity`, `agent_type` accepts its `UNSPECIFIED` value. The two
+     * are not analogous: a session always has a computed severity bucket, so
+     * `SEVERITY_UNSPECIFIED` is never returned and filtering on it could only
+     * match nothing. `AGENT_TYPE_UNSPECIFIED` *is* returned -- it is what
+     * `AnalyzedSession.agent_type` reports for an agent whose runtime was never
+     * recorded -- so it must remain filterable.
+     *
+     * The `session_id` value is a case-sensitive exact match (no substring or
+     * prefix matching) on `AnalyzedSession.session_id`. Unlike `severity` and
+     * `agent_type` it is not a closed enum, so any non-empty value is accepted;
+     * an empty value (`session_id = ""`) is rejected rather than treated as "no
+     * filter".
+     *
+     * Example (time window, severity and runtime):
+     *
+     * ```
+     * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+     * "2024-01-08T00:00:00Z" AND severity = "SEVERITY_CRITICAL" AND agent_type =
+     * "CLOUD_RUN_SERVICE"
+     * ```
+     *
+     * If empty, results are restricted to the last 7 days with no severity,
+     * runtime, or session restriction. Other fields, additional operators, set
+     * membership (`IN`), and boolean combinations (`OR`, `NOT`, parentheses) are
+     * not yet supported.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + filter_ = getDefaultInstance().getFilter(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Filter expression restricting which AnalyzedSessions are
+     * returned. Supports a subset of AIP-160: a closed `detection_time` window
+     * (both bounds required), an equality on `severity`, an equality on
+     * `agent_type`, and an equality on `session_id`, joined by `AND`. Each
+     * clause is optional, may appear at most once, and may appear in any order.
+     *
+     * The `severity` value is the **canonical** `Severity` enum name --
+     * `SEVERITY_CRITICAL`, `SEVERITY_HIGH`, `SEVERITY_MEDIUM` or `SEVERITY_LOW`.
+     * Short forms such as `"CRITICAL"` are rejected, as is
+     * `SEVERITY_UNSPECIFIED`. It matches sessions whose *maximum* severity equals
+     * that bucket: a session that fires at both LOW and CRITICAL matches
+     * `severity = "SEVERITY_CRITICAL"`, not `severity = "SEVERITY_LOW"`.
+     *
+     * The `agent_type` value is the canonical `AgentResource.AgentType` enum name
+     * -- `REASONING_ENGINE`, `CLOUD_RUN_SERVICE`, `GKE_WORKLOAD`, `GCE_INSTANCE`,
+     * `AWS`, `AZURE`, `AGENT_TYPE_OTHER` or `AGENT_TYPE_UNSPECIFIED` -- and
+     * matches sessions run by an agent on that runtime.
+     *
+     * Unlike `severity`, `agent_type` accepts its `UNSPECIFIED` value. The two
+     * are not analogous: a session always has a computed severity bucket, so
+     * `SEVERITY_UNSPECIFIED` is never returned and filtering on it could only
+     * match nothing. `AGENT_TYPE_UNSPECIFIED` *is* returned -- it is what
+     * `AnalyzedSession.agent_type` reports for an agent whose runtime was never
+     * recorded -- so it must remain filterable.
+     *
+     * The `session_id` value is a case-sensitive exact match (no substring or
+     * prefix matching) on `AnalyzedSession.session_id`. Unlike `severity` and
+     * `agent_type` it is not a closed enum, so any non-empty value is accepted;
+     * an empty value (`session_id = ""`) is rejected rather than treated as "no
+     * filter".
+     *
+     * Example (time window, severity and runtime):
+     *
+     * ```
+     * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+     * "2024-01-08T00:00:00Z" AND severity = "SEVERITY_CRITICAL" AND agent_type =
+     * "CLOUD_RUN_SERVICE"
+     * ```
+     *
+     * If empty, results are restricted to the last 7 days with no severity,
+     * runtime, or session restriction. Other fields, additional operators, set
+     * membership (`IN`), and boolean combinations (`OR`, `NOT`, parentheses) are
+     * not yet supported.
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private int view_ = 0; + + /** + * + * + *
+     * Optional. Resource view to control which fields are returned.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for view. + */ + @java.lang.Override + public int getViewValue() { + return view_; + } + + /** + * + * + *
+     * Optional. Resource view to control which fields are returned.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for view to set. + * @return This builder for chaining. + */ + public Builder setViewValue(int value) { + view_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Resource view to control which fields are returned.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The view. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSessionView getView() { + com.google.cloud.aiplatform.v1.AnalyzedSessionView result = + com.google.cloud.aiplatform.v1.AnalyzedSessionView.forNumber(view_); + return result == null + ? com.google.cloud.aiplatform.v1.AnalyzedSessionView.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Optional. Resource view to control which fields are returned.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The view to set. + * @return This builder for chaining. + */ + public Builder setView(com.google.cloud.aiplatform.v1.AnalyzedSessionView value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000010; + view_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Resource view to control which fields are returned.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearView() { + bitField0_ = (bitField0_ & ~0x00000010); + view_ = 0; + onChanged(); + return this; + } + + private java.lang.Object orderBy_ = ""; + + /** + * + * + *
+     * Optional. Comma-separated list of fields to sort by, following AIP-132
+     * syntax. The default sort direction is ascending; append " desc" to a
+     * field to sort descending.
+     *
+     * Supported fields (any other field yields INVALID_ARGUMENT):
+     *
+     * * `latest_detection_time` - the session's most-recent flagged detection
+     * time. `latest_detection_time desc` puts the newest sessions first.
+     * * `max_severity_rank` - the session's bucketed maximum severity, ranked
+     * LOW=1 < MEDIUM=2 < HIGH=3 < CRITICAL=4. `max_severity_rank desc` puts
+     * the most-severe sessions first.
+     * * `agent_display_name` - the MonitoredAgent's display name. Sorted as a
+     * STRING (case-sensitive, code-point order).
+     *
+     * If empty, defaults to `latest_detection_time desc`. Multi-field sort
+     * (for example, `max_severity_rank desc, latest_detection_time desc`) is
+     * supported.
+     *
+     * The `order_by` value MUST match the value used on the call that minted any
+     * supplied `page_token` (AIP-158). Mismatches yield INVALID_ARGUMENT.
+     * 
+ * + * string order_by = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. Comma-separated list of fields to sort by, following AIP-132
+     * syntax. The default sort direction is ascending; append " desc" to a
+     * field to sort descending.
+     *
+     * Supported fields (any other field yields INVALID_ARGUMENT):
+     *
+     * * `latest_detection_time` - the session's most-recent flagged detection
+     * time. `latest_detection_time desc` puts the newest sessions first.
+     * * `max_severity_rank` - the session's bucketed maximum severity, ranked
+     * LOW=1 < MEDIUM=2 < HIGH=3 < CRITICAL=4. `max_severity_rank desc` puts
+     * the most-severe sessions first.
+     * * `agent_display_name` - the MonitoredAgent's display name. Sorted as a
+     * STRING (case-sensitive, code-point order).
+     *
+     * If empty, defaults to `latest_detection_time desc`. Multi-field sort
+     * (for example, `max_severity_rank desc, latest_detection_time desc`) is
+     * supported.
+     *
+     * The `order_by` value MUST match the value used on the call that minted any
+     * supplied `page_token` (AIP-158). Mismatches yield INVALID_ARGUMENT.
+     * 
+ * + * string order_by = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. Comma-separated list of fields to sort by, following AIP-132
+     * syntax. The default sort direction is ascending; append " desc" to a
+     * field to sort descending.
+     *
+     * Supported fields (any other field yields INVALID_ARGUMENT):
+     *
+     * * `latest_detection_time` - the session's most-recent flagged detection
+     * time. `latest_detection_time desc` puts the newest sessions first.
+     * * `max_severity_rank` - the session's bucketed maximum severity, ranked
+     * LOW=1 < MEDIUM=2 < HIGH=3 < CRITICAL=4. `max_severity_rank desc` puts
+     * the most-severe sessions first.
+     * * `agent_display_name` - the MonitoredAgent's display name. Sorted as a
+     * STRING (case-sensitive, code-point order).
+     *
+     * If empty, defaults to `latest_detection_time desc`. Multi-field sort
+     * (for example, `max_severity_rank desc, latest_detection_time desc`) is
+     * supported.
+     *
+     * The `order_by` value MUST match the value used on the call that minted any
+     * supplied `page_token` (AIP-158). Mismatches yield INVALID_ARGUMENT.
+     * 
+ * + * string order_by = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderBy(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + orderBy_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Comma-separated list of fields to sort by, following AIP-132
+     * syntax. The default sort direction is ascending; append " desc" to a
+     * field to sort descending.
+     *
+     * Supported fields (any other field yields INVALID_ARGUMENT):
+     *
+     * * `latest_detection_time` - the session's most-recent flagged detection
+     * time. `latest_detection_time desc` puts the newest sessions first.
+     * * `max_severity_rank` - the session's bucketed maximum severity, ranked
+     * LOW=1 < MEDIUM=2 < HIGH=3 < CRITICAL=4. `max_severity_rank desc` puts
+     * the most-severe sessions first.
+     * * `agent_display_name` - the MonitoredAgent's display name. Sorted as a
+     * STRING (case-sensitive, code-point order).
+     *
+     * If empty, defaults to `latest_detection_time desc`. Multi-field sort
+     * (for example, `max_severity_rank desc, latest_detection_time desc`) is
+     * supported.
+     *
+     * The `order_by` value MUST match the value used on the call that minted any
+     * supplied `page_token` (AIP-158). Mismatches yield INVALID_ARGUMENT.
+     * 
+ * + * string order_by = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearOrderBy() { + orderBy_ = getDefaultInstance().getOrderBy(); + bitField0_ = (bitField0_ & ~0x00000020); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. Comma-separated list of fields to sort by, following AIP-132
+     * syntax. The default sort direction is ascending; append " desc" to a
+     * field to sort descending.
+     *
+     * Supported fields (any other field yields INVALID_ARGUMENT):
+     *
+     * * `latest_detection_time` - the session's most-recent flagged detection
+     * time. `latest_detection_time desc` puts the newest sessions first.
+     * * `max_severity_rank` - the session's bucketed maximum severity, ranked
+     * LOW=1 < MEDIUM=2 < HIGH=3 < CRITICAL=4. `max_severity_rank desc` puts
+     * the most-severe sessions first.
+     * * `agent_display_name` - the MonitoredAgent's display name. Sorted as a
+     * STRING (case-sensitive, code-point order).
+     *
+     * If empty, defaults to `latest_detection_time desc`. Multi-field sort
+     * (for example, `max_severity_rank desc, latest_detection_time desc`) is
+     * supported.
+     *
+     * The `order_by` value MUST match the value used on the call that minted any
+     * supplied `page_token` (AIP-158). Mismatches yield INVALID_ARGUMENT.
+     * 
+ * + * string order_by = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + orderBy_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest) + private static final com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest(); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAnalyzedSessionsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsRequestOrBuilder.java new file mode 100644 index 000000000000..3384636299f0 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsRequestOrBuilder.java @@ -0,0 +1,307 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface ListAnalyzedSessionsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The parent MonitoredAgent resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. The parent MonitoredAgent resource.
+   * Format:
+   * `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. The maximum number of analyzed sessions to return.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. A page token, received from a previous `ListAnalyzedSessions`
+   * call.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. A page token, received from a previous `ListAnalyzedSessions`
+   * call.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
+   * Optional. Filter expression restricting which AnalyzedSessions are
+   * returned. Supports a subset of AIP-160: a closed `detection_time` window
+   * (both bounds required), an equality on `severity`, an equality on
+   * `agent_type`, and an equality on `session_id`, joined by `AND`. Each
+   * clause is optional, may appear at most once, and may appear in any order.
+   *
+   * The `severity` value is the **canonical** `Severity` enum name --
+   * `SEVERITY_CRITICAL`, `SEVERITY_HIGH`, `SEVERITY_MEDIUM` or `SEVERITY_LOW`.
+   * Short forms such as `"CRITICAL"` are rejected, as is
+   * `SEVERITY_UNSPECIFIED`. It matches sessions whose *maximum* severity equals
+   * that bucket: a session that fires at both LOW and CRITICAL matches
+   * `severity = "SEVERITY_CRITICAL"`, not `severity = "SEVERITY_LOW"`.
+   *
+   * The `agent_type` value is the canonical `AgentResource.AgentType` enum name
+   * -- `REASONING_ENGINE`, `CLOUD_RUN_SERVICE`, `GKE_WORKLOAD`, `GCE_INSTANCE`,
+   * `AWS`, `AZURE`, `AGENT_TYPE_OTHER` or `AGENT_TYPE_UNSPECIFIED` -- and
+   * matches sessions run by an agent on that runtime.
+   *
+   * Unlike `severity`, `agent_type` accepts its `UNSPECIFIED` value. The two
+   * are not analogous: a session always has a computed severity bucket, so
+   * `SEVERITY_UNSPECIFIED` is never returned and filtering on it could only
+   * match nothing. `AGENT_TYPE_UNSPECIFIED` *is* returned -- it is what
+   * `AnalyzedSession.agent_type` reports for an agent whose runtime was never
+   * recorded -- so it must remain filterable.
+   *
+   * The `session_id` value is a case-sensitive exact match (no substring or
+   * prefix matching) on `AnalyzedSession.session_id`. Unlike `severity` and
+   * `agent_type` it is not a closed enum, so any non-empty value is accepted;
+   * an empty value (`session_id = ""`) is rejected rather than treated as "no
+   * filter".
+   *
+   * Example (time window, severity and runtime):
+   *
+   * ```
+   * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+   * "2024-01-08T00:00:00Z" AND severity = "SEVERITY_CRITICAL" AND agent_type =
+   * "CLOUD_RUN_SERVICE"
+   * ```
+   *
+   * If empty, results are restricted to the last 7 days with no severity,
+   * runtime, or session restriction. Other fields, additional operators, set
+   * membership (`IN`), and boolean combinations (`OR`, `NOT`, parentheses) are
+   * not yet supported.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
+   * Optional. Filter expression restricting which AnalyzedSessions are
+   * returned. Supports a subset of AIP-160: a closed `detection_time` window
+   * (both bounds required), an equality on `severity`, an equality on
+   * `agent_type`, and an equality on `session_id`, joined by `AND`. Each
+   * clause is optional, may appear at most once, and may appear in any order.
+   *
+   * The `severity` value is the **canonical** `Severity` enum name --
+   * `SEVERITY_CRITICAL`, `SEVERITY_HIGH`, `SEVERITY_MEDIUM` or `SEVERITY_LOW`.
+   * Short forms such as `"CRITICAL"` are rejected, as is
+   * `SEVERITY_UNSPECIFIED`. It matches sessions whose *maximum* severity equals
+   * that bucket: a session that fires at both LOW and CRITICAL matches
+   * `severity = "SEVERITY_CRITICAL"`, not `severity = "SEVERITY_LOW"`.
+   *
+   * The `agent_type` value is the canonical `AgentResource.AgentType` enum name
+   * -- `REASONING_ENGINE`, `CLOUD_RUN_SERVICE`, `GKE_WORKLOAD`, `GCE_INSTANCE`,
+   * `AWS`, `AZURE`, `AGENT_TYPE_OTHER` or `AGENT_TYPE_UNSPECIFIED` -- and
+   * matches sessions run by an agent on that runtime.
+   *
+   * Unlike `severity`, `agent_type` accepts its `UNSPECIFIED` value. The two
+   * are not analogous: a session always has a computed severity bucket, so
+   * `SEVERITY_UNSPECIFIED` is never returned and filtering on it could only
+   * match nothing. `AGENT_TYPE_UNSPECIFIED` *is* returned -- it is what
+   * `AnalyzedSession.agent_type` reports for an agent whose runtime was never
+   * recorded -- so it must remain filterable.
+   *
+   * The `session_id` value is a case-sensitive exact match (no substring or
+   * prefix matching) on `AnalyzedSession.session_id`. Unlike `severity` and
+   * `agent_type` it is not a closed enum, so any non-empty value is accepted;
+   * an empty value (`session_id = ""`) is rejected rather than treated as "no
+   * filter".
+   *
+   * Example (time window, severity and runtime):
+   *
+   * ```
+   * detection_time >= "2024-01-01T00:00:00Z" AND detection_time <=
+   * "2024-01-08T00:00:00Z" AND severity = "SEVERITY_CRITICAL" AND agent_type =
+   * "CLOUD_RUN_SERVICE"
+   * ```
+   *
+   * If empty, results are restricted to the last 7 days with no severity,
+   * runtime, or session restriction. Other fields, additional operators, set
+   * membership (`IN`), and boolean combinations (`OR`, `NOT`, parentheses) are
+   * not yet supported.
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
+   * Optional. Resource view to control which fields are returned.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for view. + */ + int getViewValue(); + + /** + * + * + *
+   * Optional. Resource view to control which fields are returned.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AnalyzedSessionView view = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The view. + */ + com.google.cloud.aiplatform.v1.AnalyzedSessionView getView(); + + /** + * + * + *
+   * Optional. Comma-separated list of fields to sort by, following AIP-132
+   * syntax. The default sort direction is ascending; append " desc" to a
+   * field to sort descending.
+   *
+   * Supported fields (any other field yields INVALID_ARGUMENT):
+   *
+   * * `latest_detection_time` - the session's most-recent flagged detection
+   * time. `latest_detection_time desc` puts the newest sessions first.
+   * * `max_severity_rank` - the session's bucketed maximum severity, ranked
+   * LOW=1 < MEDIUM=2 < HIGH=3 < CRITICAL=4. `max_severity_rank desc` puts
+   * the most-severe sessions first.
+   * * `agent_display_name` - the MonitoredAgent's display name. Sorted as a
+   * STRING (case-sensitive, code-point order).
+   *
+   * If empty, defaults to `latest_detection_time desc`. Multi-field sort
+   * (for example, `max_severity_rank desc, latest_detection_time desc`) is
+   * supported.
+   *
+   * The `order_by` value MUST match the value used on the call that minted any
+   * supplied `page_token` (AIP-158). Mismatches yield INVALID_ARGUMENT.
+   * 
+ * + * string order_by = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + + /** + * + * + *
+   * Optional. Comma-separated list of fields to sort by, following AIP-132
+   * syntax. The default sort direction is ascending; append " desc" to a
+   * field to sort descending.
+   *
+   * Supported fields (any other field yields INVALID_ARGUMENT):
+   *
+   * * `latest_detection_time` - the session's most-recent flagged detection
+   * time. `latest_detection_time desc` puts the newest sessions first.
+   * * `max_severity_rank` - the session's bucketed maximum severity, ranked
+   * LOW=1 < MEDIUM=2 < HIGH=3 < CRITICAL=4. `max_severity_rank desc` puts
+   * the most-severe sessions first.
+   * * `agent_display_name` - the MonitoredAgent's display name. Sorted as a
+   * STRING (case-sensitive, code-point order).
+   *
+   * If empty, defaults to `latest_detection_time desc`. Multi-field sort
+   * (for example, `max_severity_rank desc, latest_detection_time desc`) is
+   * supported.
+   *
+   * The `order_by` value MUST match the value used on the call that minted any
+   * supplied `page_token` (AIP-158). Mismatches yield INVALID_ARGUMENT.
+   * 
+ * + * string order_by = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsResponse.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsResponse.java new file mode 100644 index 000000000000..da4948e212dc --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsResponse.java @@ -0,0 +1,2945 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Response to list analyzed sessions.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse} + */ +@com.google.protobuf.Generated +public final class ListAnalyzedSessionsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse) + ListAnalyzedSessionsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAnalyzedSessionsResponse"); + } + + // Use ListAnalyzedSessionsResponse.newBuilder() to construct. + private ListAnalyzedSessionsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAnalyzedSessionsResponse() { + analyzedSessions_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.class, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.Builder.class); + } + + public interface ViewSummaryOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * The list of severity summaries for the analyzed sessions.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + int getSeveritiesCount(); + + /** + * + * + *
+     * The list of severity summaries for the analyzed sessions.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + boolean containsSeverities(java.lang.String key); + + /** Use {@link #getSeveritiesMap()} instead. */ + @java.lang.Deprecated + java.util.Map + getSeverities(); + + /** + * + * + *
+     * The list of severity summaries for the analyzed sessions.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + java.util.Map + getSeveritiesMap(); + + /** + * + * + *
+     * The list of severity summaries for the analyzed sessions.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary defaultValue); + + /** + * + * + *
+     * The list of severity summaries for the analyzed sessions.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrThrow( + java.lang.String key); + + /** + * + * + *
+     * Number of anomalous sessions.
+     * 
+ * + * int32 anomalous_sessions_count = 2; + * + * @return The anomalousSessionsCount. + */ + int getAnomalousSessionsCount(); + + /** + * + * + *
+     * Total number of sessions.
+     * 
+ * + * int32 total_sessions_count = 3; + * + * @return The totalSessionsCount. + */ + int getTotalSessionsCount(); + + /** + * + * + *
+     * Output only. The number of distinct agents in the request scope with at
+     * least one anomalous session in the time window. On
+     * `AggregateAnalyzedSessionsResponse.summary` this is a global count; it
+     * is not populated on `ListAnalyzedSessionsResponse.summary`.
+     * 
+ * + * int32 anomalous_agents_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The anomalousAgentsCount. + */ + int getAnomalousAgentsCount(); + + /** + * + * + *
+     * Output only. The number of distinct sessions in the time window that were
+     * scanned by the LLM judge.
+     * 
+ * + * int32 llm_scanned_sessions_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The llmScannedSessionsCount. + */ + int getLlmScannedSessionsCount(); + } + + /** + * + * + *
+   * The view summary.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary} + */ + public static final class ViewSummary extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary) + ViewSummaryOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ViewSummary"); + } + + // Use ViewSummary.newBuilder() to construct. + private ViewSummary(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ViewSummary() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 1: + return internalGetSeverities(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.class, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder + .class); + } + + public static final int SEVERITIES_FIELD_NUMBER = 1; + + private static final class SeveritiesDefaultEntryHolder { + static final com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + defaultEntry = + com.google.protobuf.MapEntry + . + newDefaultInstance( + com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_SeveritiesEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.MESSAGE, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + .getDefaultInstance()); + } + + @SuppressWarnings("serial") + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + severities_; + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + internalGetSeverities() { + if (severities_ == null) { + return com.google.protobuf.MapField.emptyMapField( + SeveritiesDefaultEntryHolder.defaultEntry); + } + return severities_; + } + + public int getSeveritiesCount() { + return internalGetSeverities().getMap().size(); + } + + /** + * + * + *
+     * The list of severity summaries for the analyzed sessions.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + @java.lang.Override + public boolean containsSeverities(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetSeverities().getMap().containsKey(key); + } + + /** Use {@link #getSeveritiesMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeverities() { + return getSeveritiesMap(); + } + + /** + * + * + *
+     * The list of severity summaries for the analyzed sessions.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + @java.lang.Override + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeveritiesMap() { + return internalGetSeverities().getMap(); + } + + /** + * + * + *
+     * The list of severity summaries for the analyzed sessions.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + @java.lang.Override + public /* nullable */ com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + getSeveritiesOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + map = internalGetSeverities().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
+     * The list of severity summaries for the analyzed sessions.
+     * The key is the string representation of Severity enum:
+     * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+     * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+     * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrThrow( + java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + map = internalGetSeverities().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public static final int ANOMALOUS_SESSIONS_COUNT_FIELD_NUMBER = 2; + private int anomalousSessionsCount_ = 0; + + /** + * + * + *
+     * Number of anomalous sessions.
+     * 
+ * + * int32 anomalous_sessions_count = 2; + * + * @return The anomalousSessionsCount. + */ + @java.lang.Override + public int getAnomalousSessionsCount() { + return anomalousSessionsCount_; + } + + public static final int TOTAL_SESSIONS_COUNT_FIELD_NUMBER = 3; + private int totalSessionsCount_ = 0; + + /** + * + * + *
+     * Total number of sessions.
+     * 
+ * + * int32 total_sessions_count = 3; + * + * @return The totalSessionsCount. + */ + @java.lang.Override + public int getTotalSessionsCount() { + return totalSessionsCount_; + } + + public static final int ANOMALOUS_AGENTS_COUNT_FIELD_NUMBER = 4; + private int anomalousAgentsCount_ = 0; + + /** + * + * + *
+     * Output only. The number of distinct agents in the request scope with at
+     * least one anomalous session in the time window. On
+     * `AggregateAnalyzedSessionsResponse.summary` this is a global count; it
+     * is not populated on `ListAnalyzedSessionsResponse.summary`.
+     * 
+ * + * int32 anomalous_agents_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The anomalousAgentsCount. + */ + @java.lang.Override + public int getAnomalousAgentsCount() { + return anomalousAgentsCount_; + } + + public static final int LLM_SCANNED_SESSIONS_COUNT_FIELD_NUMBER = 5; + private int llmScannedSessionsCount_ = 0; + + /** + * + * + *
+     * Output only. The number of distinct sessions in the time window that were
+     * scanned by the LLM judge.
+     * 
+ * + * int32 llm_scanned_sessions_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The llmScannedSessionsCount. + */ + @java.lang.Override + public int getLlmScannedSessionsCount() { + return llmScannedSessionsCount_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + com.google.protobuf.GeneratedMessage.serializeStringMapTo( + output, internalGetSeverities(), SeveritiesDefaultEntryHolder.defaultEntry, 1); + if (anomalousSessionsCount_ != 0) { + output.writeInt32(2, anomalousSessionsCount_); + } + if (totalSessionsCount_ != 0) { + output.writeInt32(3, totalSessionsCount_); + } + if (anomalousAgentsCount_ != 0) { + output.writeInt32(4, anomalousAgentsCount_); + } + if (llmScannedSessionsCount_ != 0) { + output.writeInt32(5, llmScannedSessionsCount_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (java.util.Map.Entry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + entry : internalGetSeverities().getMap().entrySet()) { + com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + severities__ = + SeveritiesDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, severities__); + } + if (anomalousSessionsCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, anomalousSessionsCount_); + } + if (totalSessionsCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, totalSessionsCount_); + } + if (anomalousAgentsCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(4, anomalousAgentsCount_); + } + if (llmScannedSessionsCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(5, llmScannedSessionsCount_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary other = + (com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary) obj; + + if (!internalGetSeverities().equals(other.internalGetSeverities())) return false; + if (getAnomalousSessionsCount() != other.getAnomalousSessionsCount()) return false; + if (getTotalSessionsCount() != other.getTotalSessionsCount()) return false; + if (getAnomalousAgentsCount() != other.getAnomalousAgentsCount()) return false; + if (getLlmScannedSessionsCount() != other.getLlmScannedSessionsCount()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (!internalGetSeverities().getMap().isEmpty()) { + hash = (37 * hash) + SEVERITIES_FIELD_NUMBER; + hash = (53 * hash) + internalGetSeverities().hashCode(); + } + hash = (37 * hash) + ANOMALOUS_SESSIONS_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getAnomalousSessionsCount(); + hash = (37 * hash) + TOTAL_SESSIONS_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getTotalSessionsCount(); + hash = (37 * hash) + ANOMALOUS_AGENTS_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getAnomalousAgentsCount(); + hash = (37 * hash) + LLM_SCANNED_SESSIONS_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getLlmScannedSessionsCount(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+     * The view summary.
+     * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary) + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 1: + return internalGetSeverities(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( + int number) { + switch (number) { + case 1: + return internalGetMutableSeverities(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.class, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder + .class); + } + + // Construct using + // com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + internalGetMutableSeverities().clear(); + anomalousSessionsCount_ = 0; + totalSessionsCount_ = 0; + anomalousAgentsCount_ = 0; + llmScannedSessionsCount_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_ViewSummary_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary build() { + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + buildPartial() { + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary result = + new com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.severities_ = + internalGetSeverities().build(SeveritiesDefaultEntryHolder.defaultEntry); + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.anomalousSessionsCount_ = anomalousSessionsCount_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.totalSessionsCount_ = totalSessionsCount_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.anomalousAgentsCount_ = anomalousAgentsCount_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.llmScannedSessionsCount_ = llmScannedSessionsCount_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary) { + return mergeFrom( + (com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary other) { + if (other + == com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance()) return this; + internalGetMutableSeverities().mergeFrom(other.internalGetSeverities()); + bitField0_ |= 0x00000001; + if (other.getAnomalousSessionsCount() != 0) { + setAnomalousSessionsCount(other.getAnomalousSessionsCount()); + } + if (other.getTotalSessionsCount() != 0) { + setTotalSessionsCount(other.getTotalSessionsCount()); + } + if (other.getAnomalousAgentsCount() != 0) { + setAnomalousAgentsCount(other.getAnomalousAgentsCount()); + } + if (other.getLlmScannedSessionsCount() != 0) { + setLlmScannedSessionsCount(other.getLlmScannedSessionsCount()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.protobuf.MapEntry< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + severities__ = + input.readMessage( + SeveritiesDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableSeverities() + .ensureBuilderMap() + .put(severities__.getKey(), severities__.getValue()); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + anomalousSessionsCount_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 24: + { + totalSessionsCount_ = input.readInt32(); + bitField0_ |= 0x00000004; + break; + } // case 24 + case 32: + { + anomalousAgentsCount_ = input.readInt32(); + bitField0_ |= 0x00000008; + break; + } // case 32 + case 40: + { + llmScannedSessionsCount_ = input.readInt32(); + bitField0_ |= 0x00000010; + break; + } // case 40 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private static final class SeveritiesConverter + implements com.google.protobuf.MapFieldBuilder.Converter< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> { + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary build( + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder val) { + if (val instanceof com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) { + return (com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) val; + } + return ((com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder) val) + .build(); + } + + @java.lang.Override + public com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + defaultEntry() { + return SeveritiesDefaultEntryHolder.defaultEntry; + } + } + ; + + private static final SeveritiesConverter severitiesConverter = new SeveritiesConverter(); + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder> + severities_; + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder> + internalGetSeverities() { + if (severities_ == null) { + return new com.google.protobuf.MapFieldBuilder<>(severitiesConverter); + } + return severities_; + } + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder> + internalGetMutableSeverities() { + if (severities_ == null) { + severities_ = new com.google.protobuf.MapFieldBuilder<>(severitiesConverter); + } + bitField0_ |= 0x00000001; + onChanged(); + return severities_; + } + + public int getSeveritiesCount() { + return internalGetSeverities().ensureBuilderMap().size(); + } + + /** + * + * + *
+       * The list of severity summaries for the analyzed sessions.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + @java.lang.Override + public boolean containsSeverities(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetSeverities().ensureBuilderMap().containsKey(key); + } + + /** Use {@link #getSeveritiesMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeverities() { + return getSeveritiesMap(); + } + + /** + * + * + *
+       * The list of severity summaries for the analyzed sessions.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + @java.lang.Override + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getSeveritiesMap() { + return internalGetSeverities().getImmutableMap(); + } + + /** + * + * + *
+       * The list of severity summaries for the analyzed sessions.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + @java.lang.Override + public /* nullable */ com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary + getSeveritiesOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder> + map = internalGetMutableSeverities().ensureBuilderMap(); + return map.containsKey(key) ? severitiesConverter.build(map.get(key)) : defaultValue; + } + + /** + * + * + *
+       * The list of severity summaries for the analyzed sessions.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary getSeveritiesOrThrow( + java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder> + map = internalGetMutableSeverities().ensureBuilderMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return severitiesConverter.build(map.get(key)); + } + + public Builder clearSeverities() { + bitField0_ = (bitField0_ & ~0x00000001); + internalGetMutableSeverities().clear(); + return this; + } + + /** + * + * + *
+       * The list of severity summaries for the analyzed sessions.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + public Builder removeSeverities(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableSeverities().ensureBuilderMap().remove(key); + return this; + } + + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + getMutableSeverities() { + bitField0_ |= 0x00000001; + return internalGetMutableSeverities().ensureMessageMap(); + } + + /** + * + * + *
+       * The list of severity summaries for the analyzed sessions.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + public Builder putSeverities( + java.lang.String key, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + internalGetMutableSeverities().ensureBuilderMap().put(key, value); + bitField0_ |= 0x00000001; + return this; + } + + /** + * + * + *
+       * The list of severity summaries for the analyzed sessions.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + public Builder putAllSeverities( + java.util.Map< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + values) { + for (java.util.Map.Entry< + java.lang.String, com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> + e : values.entrySet()) { + if (e.getKey() == null || e.getValue() == null) { + throw new NullPointerException(); + } + } + internalGetMutableSeverities().ensureBuilderMap().putAll(values); + bitField0_ |= 0x00000001; + return this; + } + + /** + * + * + *
+       * The list of severity summaries for the analyzed sessions.
+       * The key is the string representation of Severity enum:
+       * "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH",
+       * "SEVERITY_MEDIUM", "SEVERITY_LOW".
+       * 
+ * + * + * map<string, .google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary> severities = 1; + * + */ + public com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder + putSeveritiesBuilderIfAbsent(java.lang.String key) { + java.util.Map< + java.lang.String, + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder> + builderMap = internalGetMutableSeverities().ensureBuilderMap(); + com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummaryOrBuilder entry = + builderMap.get(key); + if (entry == null) { + entry = com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.newBuilder(); + builderMap.put(key, entry); + } + if (entry instanceof com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) { + entry = + ((com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary) entry).toBuilder(); + builderMap.put(key, entry); + } + return (com.google.cloud.aiplatform.v1.AnalyzedSession.SeveritySummary.Builder) entry; + } + + private int anomalousSessionsCount_; + + /** + * + * + *
+       * Number of anomalous sessions.
+       * 
+ * + * int32 anomalous_sessions_count = 2; + * + * @return The anomalousSessionsCount. + */ + @java.lang.Override + public int getAnomalousSessionsCount() { + return anomalousSessionsCount_; + } + + /** + * + * + *
+       * Number of anomalous sessions.
+       * 
+ * + * int32 anomalous_sessions_count = 2; + * + * @param value The anomalousSessionsCount to set. + * @return This builder for chaining. + */ + public Builder setAnomalousSessionsCount(int value) { + + anomalousSessionsCount_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+       * Number of anomalous sessions.
+       * 
+ * + * int32 anomalous_sessions_count = 2; + * + * @return This builder for chaining. + */ + public Builder clearAnomalousSessionsCount() { + bitField0_ = (bitField0_ & ~0x00000002); + anomalousSessionsCount_ = 0; + onChanged(); + return this; + } + + private int totalSessionsCount_; + + /** + * + * + *
+       * Total number of sessions.
+       * 
+ * + * int32 total_sessions_count = 3; + * + * @return The totalSessionsCount. + */ + @java.lang.Override + public int getTotalSessionsCount() { + return totalSessionsCount_; + } + + /** + * + * + *
+       * Total number of sessions.
+       * 
+ * + * int32 total_sessions_count = 3; + * + * @param value The totalSessionsCount to set. + * @return This builder for chaining. + */ + public Builder setTotalSessionsCount(int value) { + + totalSessionsCount_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+       * Total number of sessions.
+       * 
+ * + * int32 total_sessions_count = 3; + * + * @return This builder for chaining. + */ + public Builder clearTotalSessionsCount() { + bitField0_ = (bitField0_ & ~0x00000004); + totalSessionsCount_ = 0; + onChanged(); + return this; + } + + private int anomalousAgentsCount_; + + /** + * + * + *
+       * Output only. The number of distinct agents in the request scope with at
+       * least one anomalous session in the time window. On
+       * `AggregateAnalyzedSessionsResponse.summary` this is a global count; it
+       * is not populated on `ListAnalyzedSessionsResponse.summary`.
+       * 
+ * + * int32 anomalous_agents_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The anomalousAgentsCount. + */ + @java.lang.Override + public int getAnomalousAgentsCount() { + return anomalousAgentsCount_; + } + + /** + * + * + *
+       * Output only. The number of distinct agents in the request scope with at
+       * least one anomalous session in the time window. On
+       * `AggregateAnalyzedSessionsResponse.summary` this is a global count; it
+       * is not populated on `ListAnalyzedSessionsResponse.summary`.
+       * 
+ * + * int32 anomalous_agents_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The anomalousAgentsCount to set. + * @return This builder for chaining. + */ + public Builder setAnomalousAgentsCount(int value) { + + anomalousAgentsCount_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The number of distinct agents in the request scope with at
+       * least one anomalous session in the time window. On
+       * `AggregateAnalyzedSessionsResponse.summary` this is a global count; it
+       * is not populated on `ListAnalyzedSessionsResponse.summary`.
+       * 
+ * + * int32 anomalous_agents_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearAnomalousAgentsCount() { + bitField0_ = (bitField0_ & ~0x00000008); + anomalousAgentsCount_ = 0; + onChanged(); + return this; + } + + private int llmScannedSessionsCount_; + + /** + * + * + *
+       * Output only. The number of distinct sessions in the time window that were
+       * scanned by the LLM judge.
+       * 
+ * + * int32 llm_scanned_sessions_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The llmScannedSessionsCount. + */ + @java.lang.Override + public int getLlmScannedSessionsCount() { + return llmScannedSessionsCount_; + } + + /** + * + * + *
+       * Output only. The number of distinct sessions in the time window that were
+       * scanned by the LLM judge.
+       * 
+ * + * int32 llm_scanned_sessions_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The llmScannedSessionsCount to set. + * @return This builder for chaining. + */ + public Builder setLlmScannedSessionsCount(int value) { + + llmScannedSessionsCount_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+       * Output only. The number of distinct sessions in the time window that were
+       * scanned by the LLM judge.
+       * 
+ * + * int32 llm_scanned_sessions_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearLlmScannedSessionsCount() { + bitField0_ = (bitField0_ & ~0x00000010); + llmScannedSessionsCount_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary) + private static final com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary(); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ViewSummary parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int ANALYZED_SESSIONS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List analyzedSessions_; + + /** + * + * + *
+   * The list of analyzed sessions.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + @java.lang.Override + public java.util.List getAnalyzedSessionsList() { + return analyzedSessions_; + } + + /** + * + * + *
+   * The list of analyzed sessions.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + @java.lang.Override + public java.util.List + getAnalyzedSessionsOrBuilderList() { + return analyzedSessions_; + } + + /** + * + * + *
+   * The list of analyzed sessions.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + @java.lang.Override + public int getAnalyzedSessionsCount() { + return analyzedSessions_.size(); + } + + /** + * + * + *
+   * The list of analyzed sessions.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSession getAnalyzedSessions(int index) { + return analyzedSessions_.get(index); + } + + /** + * + * + *
+   * The list of analyzed sessions.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AnalyzedSessionOrBuilder getAnalyzedSessionsOrBuilder( + int index) { + return analyzedSessions_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * A token to retrieve the next page of results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * A token to retrieve the next page of results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SUMMARY_FIELD_NUMBER = 3; + private com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary_; + + /** + * + * + *
+   * Summary statistics computed across the sessions on the current page only.
+   * For statistics across the entire result set, use AggregateAnalyzedSessions.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + * @return Whether the summary field is set. + */ + @java.lang.Override + public boolean hasSummary() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Summary statistics computed across the sessions on the current page only.
+   * For statistics across the entire result set, use AggregateAnalyzedSessions.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + * @return The summary. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary getSummary() { + return summary_ == null + ? com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance() + : summary_; + } + + /** + * + * + *
+   * Summary statistics computed across the sessions on the current page only.
+   * For statistics across the entire result set, use AggregateAnalyzedSessions.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder + getSummaryOrBuilder() { + return summary_ == null + ? com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance() + : summary_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < analyzedSessions_.size(); i++) { + output.writeMessage(1, analyzedSessions_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getSummary()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < analyzedSessions_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, analyzedSessions_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getSummary()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse other = + (com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse) obj; + + if (!getAnalyzedSessionsList().equals(other.getAnalyzedSessionsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (hasSummary() != other.hasSummary()) return false; + if (hasSummary()) { + if (!getSummary().equals(other.getSummary())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getAnalyzedSessionsCount() > 0) { + hash = (37 * hash) + ANALYZED_SESSIONS_FIELD_NUMBER; + hash = (53 * hash) + getAnalyzedSessionsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (hasSummary()) { + hash = (37 * hash) + SUMMARY_FIELD_NUMBER; + hash = (53 * hash) + getSummary().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Response to list analyzed sessions.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse) + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.class, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetAnalyzedSessionsFieldBuilder(); + internalGetSummaryFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (analyzedSessionsBuilder_ == null) { + analyzedSessions_ = java.util.Collections.emptyList(); + } else { + analyzedSessions_ = null; + analyzedSessionsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + summary_ = null; + if (summaryBuilder_ != null) { + summaryBuilder_.dispose(); + summaryBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListAnalyzedSessionsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse build() { + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse buildPartial() { + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse result = + new com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse result) { + if (analyzedSessionsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + analyzedSessions_ = java.util.Collections.unmodifiableList(analyzedSessions_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.analyzedSessions_ = analyzedSessions_; + } else { + result.analyzedSessions_ = analyzedSessionsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.summary_ = summaryBuilder_ == null ? summary_ : summaryBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse) { + return mergeFrom((com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse other) { + if (other == com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.getDefaultInstance()) + return this; + if (analyzedSessionsBuilder_ == null) { + if (!other.analyzedSessions_.isEmpty()) { + if (analyzedSessions_.isEmpty()) { + analyzedSessions_ = other.analyzedSessions_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureAnalyzedSessionsIsMutable(); + analyzedSessions_.addAll(other.analyzedSessions_); + } + onChanged(); + } + } else { + if (!other.analyzedSessions_.isEmpty()) { + if (analyzedSessionsBuilder_.isEmpty()) { + analyzedSessionsBuilder_.dispose(); + analyzedSessionsBuilder_ = null; + analyzedSessions_ = other.analyzedSessions_; + bitField0_ = (bitField0_ & ~0x00000001); + analyzedSessionsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetAnalyzedSessionsFieldBuilder() + : null; + } else { + analyzedSessionsBuilder_.addAllMessages(other.analyzedSessions_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasSummary()) { + mergeSummary(other.getSummary()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.aiplatform.v1.AnalyzedSession m = + input.readMessage( + com.google.cloud.aiplatform.v1.AnalyzedSession.parser(), extensionRegistry); + if (analyzedSessionsBuilder_ == null) { + ensureAnalyzedSessionsIsMutable(); + analyzedSessions_.add(m); + } else { + analyzedSessionsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage(internalGetSummaryFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List analyzedSessions_ = + java.util.Collections.emptyList(); + + private void ensureAnalyzedSessionsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + analyzedSessions_ = + new java.util.ArrayList( + analyzedSessions_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AnalyzedSession, + com.google.cloud.aiplatform.v1.AnalyzedSession.Builder, + com.google.cloud.aiplatform.v1.AnalyzedSessionOrBuilder> + analyzedSessionsBuilder_; + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public java.util.List + getAnalyzedSessionsList() { + if (analyzedSessionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(analyzedSessions_); + } else { + return analyzedSessionsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public int getAnalyzedSessionsCount() { + if (analyzedSessionsBuilder_ == null) { + return analyzedSessions_.size(); + } else { + return analyzedSessionsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public com.google.cloud.aiplatform.v1.AnalyzedSession getAnalyzedSessions(int index) { + if (analyzedSessionsBuilder_ == null) { + return analyzedSessions_.get(index); + } else { + return analyzedSessionsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public Builder setAnalyzedSessions( + int index, com.google.cloud.aiplatform.v1.AnalyzedSession value) { + if (analyzedSessionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAnalyzedSessionsIsMutable(); + analyzedSessions_.set(index, value); + onChanged(); + } else { + analyzedSessionsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public Builder setAnalyzedSessions( + int index, com.google.cloud.aiplatform.v1.AnalyzedSession.Builder builderForValue) { + if (analyzedSessionsBuilder_ == null) { + ensureAnalyzedSessionsIsMutable(); + analyzedSessions_.set(index, builderForValue.build()); + onChanged(); + } else { + analyzedSessionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public Builder addAnalyzedSessions(com.google.cloud.aiplatform.v1.AnalyzedSession value) { + if (analyzedSessionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAnalyzedSessionsIsMutable(); + analyzedSessions_.add(value); + onChanged(); + } else { + analyzedSessionsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public Builder addAnalyzedSessions( + int index, com.google.cloud.aiplatform.v1.AnalyzedSession value) { + if (analyzedSessionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAnalyzedSessionsIsMutable(); + analyzedSessions_.add(index, value); + onChanged(); + } else { + analyzedSessionsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public Builder addAnalyzedSessions( + com.google.cloud.aiplatform.v1.AnalyzedSession.Builder builderForValue) { + if (analyzedSessionsBuilder_ == null) { + ensureAnalyzedSessionsIsMutable(); + analyzedSessions_.add(builderForValue.build()); + onChanged(); + } else { + analyzedSessionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public Builder addAnalyzedSessions( + int index, com.google.cloud.aiplatform.v1.AnalyzedSession.Builder builderForValue) { + if (analyzedSessionsBuilder_ == null) { + ensureAnalyzedSessionsIsMutable(); + analyzedSessions_.add(index, builderForValue.build()); + onChanged(); + } else { + analyzedSessionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public Builder addAllAnalyzedSessions( + java.lang.Iterable values) { + if (analyzedSessionsBuilder_ == null) { + ensureAnalyzedSessionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, analyzedSessions_); + onChanged(); + } else { + analyzedSessionsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public Builder clearAnalyzedSessions() { + if (analyzedSessionsBuilder_ == null) { + analyzedSessions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + analyzedSessionsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public Builder removeAnalyzedSessions(int index) { + if (analyzedSessionsBuilder_ == null) { + ensureAnalyzedSessionsIsMutable(); + analyzedSessions_.remove(index); + onChanged(); + } else { + analyzedSessionsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public com.google.cloud.aiplatform.v1.AnalyzedSession.Builder getAnalyzedSessionsBuilder( + int index) { + return internalGetAnalyzedSessionsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public com.google.cloud.aiplatform.v1.AnalyzedSessionOrBuilder getAnalyzedSessionsOrBuilder( + int index) { + if (analyzedSessionsBuilder_ == null) { + return analyzedSessions_.get(index); + } else { + return analyzedSessionsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public java.util.List + getAnalyzedSessionsOrBuilderList() { + if (analyzedSessionsBuilder_ != null) { + return analyzedSessionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(analyzedSessions_); + } + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public com.google.cloud.aiplatform.v1.AnalyzedSession.Builder addAnalyzedSessionsBuilder() { + return internalGetAnalyzedSessionsFieldBuilder() + .addBuilder(com.google.cloud.aiplatform.v1.AnalyzedSession.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public com.google.cloud.aiplatform.v1.AnalyzedSession.Builder addAnalyzedSessionsBuilder( + int index) { + return internalGetAnalyzedSessionsFieldBuilder() + .addBuilder(index, com.google.cloud.aiplatform.v1.AnalyzedSession.getDefaultInstance()); + } + + /** + * + * + *
+     * The list of analyzed sessions.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + public java.util.List + getAnalyzedSessionsBuilderList() { + return internalGetAnalyzedSessionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AnalyzedSession, + com.google.cloud.aiplatform.v1.AnalyzedSession.Builder, + com.google.cloud.aiplatform.v1.AnalyzedSessionOrBuilder> + internalGetAnalyzedSessionsFieldBuilder() { + if (analyzedSessionsBuilder_ == null) { + analyzedSessionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.AnalyzedSession, + com.google.cloud.aiplatform.v1.AnalyzedSession.Builder, + com.google.cloud.aiplatform.v1.AnalyzedSessionOrBuilder>( + analyzedSessions_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + analyzedSessions_ = null; + } + return analyzedSessionsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * A token to retrieve the next page of results.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * A token to retrieve the next page of results.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * A token to retrieve the next page of results.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * A token to retrieve the next page of results.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * A token to retrieve the next page of results.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder> + summaryBuilder_; + + /** + * + * + *
+     * Summary statistics computed across the sessions on the current page only.
+     * For statistics across the entire result set, use AggregateAnalyzedSessions.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + * + * @return Whether the summary field is set. + */ + public boolean hasSummary() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+     * Summary statistics computed across the sessions on the current page only.
+     * For statistics across the entire result set, use AggregateAnalyzedSessions.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + * + * @return The summary. + */ + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary getSummary() { + if (summaryBuilder_ == null) { + return summary_ == null + ? com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance() + : summary_; + } else { + return summaryBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Summary statistics computed across the sessions on the current page only.
+     * For statistics across the entire result set, use AggregateAnalyzedSessions.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + */ + public Builder setSummary( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary value) { + if (summaryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + summary_ = value; + } else { + summaryBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Summary statistics computed across the sessions on the current page only.
+     * For statistics across the entire result set, use AggregateAnalyzedSessions.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + */ + public Builder setSummary( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder + builderForValue) { + if (summaryBuilder_ == null) { + summary_ = builderForValue.build(); + } else { + summaryBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Summary statistics computed across the sessions on the current page only.
+     * For statistics across the entire result set, use AggregateAnalyzedSessions.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + */ + public Builder mergeSummary( + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary value) { + if (summaryBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && summary_ != null + && summary_ + != com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance()) { + getSummaryBuilder().mergeFrom(value); + } else { + summary_ = value; + } + } else { + summaryBuilder_.mergeFrom(value); + } + if (summary_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Summary statistics computed across the sessions on the current page only.
+     * For statistics across the entire result set, use AggregateAnalyzedSessions.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + */ + public Builder clearSummary() { + bitField0_ = (bitField0_ & ~0x00000004); + summary_ = null; + if (summaryBuilder_ != null) { + summaryBuilder_.dispose(); + summaryBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Summary statistics computed across the sessions on the current page only.
+     * For statistics across the entire result set, use AggregateAnalyzedSessions.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + */ + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder + getSummaryBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetSummaryFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Summary statistics computed across the sessions on the current page only.
+     * For statistics across the entire result set, use AggregateAnalyzedSessions.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + */ + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder + getSummaryOrBuilder() { + if (summaryBuilder_ != null) { + return summaryBuilder_.getMessageOrBuilder(); + } else { + return summary_ == null + ? com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary + .getDefaultInstance() + : summary_; + } + } + + /** + * + * + *
+     * Summary statistics computed across the sessions on the current page only.
+     * For statistics across the entire result set, use AggregateAnalyzedSessions.
+     * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder> + internalGetSummaryFieldBuilder() { + if (summaryBuilder_ == null) { + summaryBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary.Builder, + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder>( + getSummary(), getParentForChildren(), isClean()); + summary_ = null; + } + return summaryBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse) + private static final com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse(); + } + + public static com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAnalyzedSessionsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsResponseOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsResponseOrBuilder.java new file mode 100644 index 000000000000..782498740abe --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListAnalyzedSessionsResponseOrBuilder.java @@ -0,0 +1,151 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface ListAnalyzedSessionsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of analyzed sessions.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + java.util.List getAnalyzedSessionsList(); + + /** + * + * + *
+   * The list of analyzed sessions.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + com.google.cloud.aiplatform.v1.AnalyzedSession getAnalyzedSessions(int index); + + /** + * + * + *
+   * The list of analyzed sessions.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + int getAnalyzedSessionsCount(); + + /** + * + * + *
+   * The list of analyzed sessions.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + java.util.List + getAnalyzedSessionsOrBuilderList(); + + /** + * + * + *
+   * The list of analyzed sessions.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.AnalyzedSession analyzed_sessions = 1; + */ + com.google.cloud.aiplatform.v1.AnalyzedSessionOrBuilder getAnalyzedSessionsOrBuilder(int index); + + /** + * + * + *
+   * A token to retrieve the next page of results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * A token to retrieve the next page of results.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); + + /** + * + * + *
+   * Summary statistics computed across the sessions on the current page only.
+   * For statistics across the entire result set, use AggregateAnalyzedSessions.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + * @return Whether the summary field is set. + */ + boolean hasSummary(); + + /** + * + * + *
+   * Summary statistics computed across the sessions on the current page only.
+   * For statistics across the entire result set, use AggregateAnalyzedSessions.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + * + * @return The summary. + */ + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary getSummary(); + + /** + * + * + *
+   * Summary statistics computed across the sessions on the current page only.
+   * For statistics across the entire result set, use AggregateAnalyzedSessions.
+   * 
+ * + * .google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummary summary = 3; + */ + com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse.ViewSummaryOrBuilder + getSummaryOrBuilder(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsRequest.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsRequest.java new file mode 100644 index 000000000000..c463ae898f9b --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsRequest.java @@ -0,0 +1,1187 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Request message for
+ * [AgentAnomalyDetectionService.ListMonitoredAgents][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListMonitoredAgents].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListMonitoredAgentsRequest} + */ +@com.google.protobuf.Generated +public final class ListMonitoredAgentsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ListMonitoredAgentsRequest) + ListMonitoredAgentsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListMonitoredAgentsRequest"); + } + + // Use ListMonitoredAgentsRequest.newBuilder() to construct. + private ListMonitoredAgentsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListMonitoredAgentsRequest() { + parent_ = ""; + pageToken_ = ""; + filter_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest.class, + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
+   * Required. The resource name of the Location to list the
+   * MonitoredAgents from. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
+   * Required. The resource name of the Location to list the
+   * MonitoredAgents from. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
+   * Optional. The standard list page size. The maximum value is 100; values
+   * above 100 will be coerced to 100. If unspecified, at most 10
+   * MonitoredAgents will be returned.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object filter_ = ""; + + /** + * + * + *
+   * Optional. An AIP-160 filter, currently restricted to a single equality
+   * predicate on `state`. The value must be the exact, case-sensitive name of a
+   * `MonitoredAgent.EnablementState` value: `ACTIVE`, `DISABLED`, `ENABLING`,
+   * or `ENABLEMENT_STATE_UNSPECIFIED`. A blank or absent filter returns every
+   * MonitoredAgent in the parent regardless of state; any other value returns
+   * `INVALID_ARGUMENT`.
+   *
+   * Example:
+   *
+   * ```
+   * state = ACTIVE
+   * ```
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. An AIP-160 filter, currently restricted to a single equality
+   * predicate on `state`. The value must be the exact, case-sensitive name of a
+   * `MonitoredAgent.EnablementState` value: `ACTIVE`, `DISABLED`, `ENABLING`,
+   * or `ENABLEMENT_STATE_UNSPECIFIED`. A blank or absent filter returns every
+   * MonitoredAgent in the parent regardless of state; any other value returns
+   * `INVALID_ARGUMENT`.
+   *
+   * Example:
+   *
+   * ```
+   * state = ACTIVE
+   * ```
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, filter_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, filter_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest other = + (com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Request message for
+   * [AgentAnomalyDetectionService.ListMonitoredAgents][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListMonitoredAgents].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListMonitoredAgentsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ListMonitoredAgentsRequest) + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest.class, + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + filter_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest build() { + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest buildPartial() { + com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest result = + new com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.filter_ = filter_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest) { + return mergeFrom((com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest other) { + if (other == com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + filter_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
+     * Required. The resource name of the Location to list the
+     * MonitoredAgents from. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Required. The resource name of the Location to list the
+     * MonitoredAgents from. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Required. The resource name of the Location to list the
+     * MonitoredAgents from. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The resource name of the Location to list the
+     * MonitoredAgents from. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The resource name of the Location to list the
+     * MonitoredAgents from. Format:
+     * `projects/{project}/locations/{location}`
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
+     * Optional. The standard list page size. The maximum value is 100; values
+     * above 100 will be coerced to 100. If unspecified, at most 10
+     * MonitoredAgents will be returned.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
+     * Optional. The standard list page size. The maximum value is 100; values
+     * above 100 will be coerced to 100. If unspecified, at most 10
+     * MonitoredAgents will be returned.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The standard list page size. The maximum value is 100; values
+     * above 100 will be coerced to 100. If unspecified, at most 10
+     * MonitoredAgents will be returned.
+     * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The standard list page token.
+     * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + + /** + * + * + *
+     * Optional. An AIP-160 filter, currently restricted to a single equality
+     * predicate on `state`. The value must be the exact, case-sensitive name of a
+     * `MonitoredAgent.EnablementState` value: `ACTIVE`, `DISABLED`, `ENABLING`,
+     * or `ENABLEMENT_STATE_UNSPECIFIED`. A blank or absent filter returns every
+     * MonitoredAgent in the parent regardless of state; any other value returns
+     * `INVALID_ARGUMENT`.
+     *
+     * Example:
+     *
+     * ```
+     * state = ACTIVE
+     * ```
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. An AIP-160 filter, currently restricted to a single equality
+     * predicate on `state`. The value must be the exact, case-sensitive name of a
+     * `MonitoredAgent.EnablementState` value: `ACTIVE`, `DISABLED`, `ENABLING`,
+     * or `ENABLEMENT_STATE_UNSPECIFIED`. A blank or absent filter returns every
+     * MonitoredAgent in the parent regardless of state; any other value returns
+     * `INVALID_ARGUMENT`.
+     *
+     * Example:
+     *
+     * ```
+     * state = ACTIVE
+     * ```
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. An AIP-160 filter, currently restricted to a single equality
+     * predicate on `state`. The value must be the exact, case-sensitive name of a
+     * `MonitoredAgent.EnablementState` value: `ACTIVE`, `DISABLED`, `ENABLING`,
+     * or `ENABLEMENT_STATE_UNSPECIFIED`. A blank or absent filter returns every
+     * MonitoredAgent in the parent regardless of state; any other value returns
+     * `INVALID_ARGUMENT`.
+     *
+     * Example:
+     *
+     * ```
+     * state = ACTIVE
+     * ```
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. An AIP-160 filter, currently restricted to a single equality
+     * predicate on `state`. The value must be the exact, case-sensitive name of a
+     * `MonitoredAgent.EnablementState` value: `ACTIVE`, `DISABLED`, `ENABLING`,
+     * or `ENABLEMENT_STATE_UNSPECIFIED`. A blank or absent filter returns every
+     * MonitoredAgent in the parent regardless of state; any other value returns
+     * `INVALID_ARGUMENT`.
+     *
+     * Example:
+     *
+     * ```
+     * state = ACTIVE
+     * ```
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + filter_ = getDefaultInstance().getFilter(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. An AIP-160 filter, currently restricted to a single equality
+     * predicate on `state`. The value must be the exact, case-sensitive name of a
+     * `MonitoredAgent.EnablementState` value: `ACTIVE`, `DISABLED`, `ENABLING`,
+     * or `ENABLEMENT_STATE_UNSPECIFIED`. A blank or absent filter returns every
+     * MonitoredAgent in the parent regardless of state; any other value returns
+     * `INVALID_ARGUMENT`.
+     *
+     * Example:
+     *
+     * ```
+     * state = ACTIVE
+     * ```
+     * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ListMonitoredAgentsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ListMonitoredAgentsRequest) + private static final com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest(); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListMonitoredAgentsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsRequestOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsRequestOrBuilder.java new file mode 100644 index 000000000000..797af8759370 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsRequestOrBuilder.java @@ -0,0 +1,151 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface ListMonitoredAgentsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ListMonitoredAgentsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The resource name of the Location to list the
+   * MonitoredAgents from. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
+   * Required. The resource name of the Location to list the
+   * MonitoredAgents from. Format:
+   * `projects/{project}/locations/{location}`
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Optional. The standard list page size. The maximum value is 100; values
+   * above 100 will be coerced to 100. If unspecified, at most 10
+   * MonitoredAgents will be returned.
+   * 
+ * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
+   * Optional. The standard list page token.
+   * 
+ * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
+   * Optional. An AIP-160 filter, currently restricted to a single equality
+   * predicate on `state`. The value must be the exact, case-sensitive name of a
+   * `MonitoredAgent.EnablementState` value: `ACTIVE`, `DISABLED`, `ENABLING`,
+   * or `ENABLEMENT_STATE_UNSPECIFIED`. A blank or absent filter returns every
+   * MonitoredAgent in the parent regardless of state; any other value returns
+   * `INVALID_ARGUMENT`.
+   *
+   * Example:
+   *
+   * ```
+   * state = ACTIVE
+   * ```
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
+   * Optional. An AIP-160 filter, currently restricted to a single equality
+   * predicate on `state`. The value must be the exact, case-sensitive name of a
+   * `MonitoredAgent.EnablementState` value: `ACTIVE`, `DISABLED`, `ENABLING`,
+   * or `ENABLEMENT_STATE_UNSPECIFIED`. A blank or absent filter returns every
+   * MonitoredAgent in the parent regardless of state; any other value returns
+   * `INVALID_ARGUMENT`.
+   *
+   * Example:
+   *
+   * ```
+   * state = ACTIVE
+   * ```
+   * 
+ * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsResponse.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsResponse.java new file mode 100644 index 000000000000..4c3166309609 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsResponse.java @@ -0,0 +1,1257 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Response message for
+ * [AgentAnomalyDetectionService.ListMonitoredAgents][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListMonitoredAgents].
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListMonitoredAgentsResponse} + */ +@com.google.protobuf.Generated +public final class ListMonitoredAgentsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ListMonitoredAgentsResponse) + ListMonitoredAgentsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListMonitoredAgentsResponse"); + } + + // Use ListMonitoredAgentsResponse.newBuilder() to construct. + private ListMonitoredAgentsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListMonitoredAgentsResponse() { + monitoredAgents_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse.class, + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse.Builder.class); + } + + public static final int MONITORED_AGENTS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List monitoredAgents_; + + /** + * + * + *
+   * A list of MonitoredAgents that matches the specified filter in
+   * the request.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + @java.lang.Override + public java.util.List getMonitoredAgentsList() { + return monitoredAgents_; + } + + /** + * + * + *
+   * A list of MonitoredAgents that matches the specified filter in
+   * the request.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + @java.lang.Override + public java.util.List + getMonitoredAgentsOrBuilderList() { + return monitoredAgents_; + } + + /** + * + * + *
+   * A list of MonitoredAgents that matches the specified filter in
+   * the request.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + @java.lang.Override + public int getMonitoredAgentsCount() { + return monitoredAgents_.size(); + } + + /** + * + * + *
+   * A list of MonitoredAgents that matches the specified filter in
+   * the request.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgent getMonitoredAgents(int index) { + return monitoredAgents_.get(index); + } + + /** + * + * + *
+   * A list of MonitoredAgents that matches the specified filter in
+   * the request.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgentOrBuilder getMonitoredAgentsOrBuilder( + int index) { + return monitoredAgents_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TOTAL_SIZE_FIELD_NUMBER = 3; + private int totalSize_ = 0; + + /** + * + * + *
+   * The total number of MonitoredAgents matching the request, after any
+   * `filter` is applied.
+   * 
+ * + * int32 total_size = 3; + * + * @return The totalSize. + */ + @java.lang.Override + public int getTotalSize() { + return totalSize_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < monitoredAgents_.size(); i++) { + output.writeMessage(1, monitoredAgents_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + if (totalSize_ != 0) { + output.writeInt32(3, totalSize_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < monitoredAgents_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, monitoredAgents_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + if (totalSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, totalSize_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse other = + (com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse) obj; + + if (!getMonitoredAgentsList().equals(other.getMonitoredAgentsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (getTotalSize() != other.getTotalSize()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getMonitoredAgentsCount() > 0) { + hash = (37 * hash) + MONITORED_AGENTS_FIELD_NUMBER; + hash = (53 * hash) + getMonitoredAgentsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (37 * hash) + TOTAL_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getTotalSize(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Response message for
+   * [AgentAnomalyDetectionService.ListMonitoredAgents][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListMonitoredAgents].
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.ListMonitoredAgentsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ListMonitoredAgentsResponse) + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse.class, + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (monitoredAgentsBuilder_ == null) { + monitoredAgents_ = java.util.Collections.emptyList(); + } else { + monitoredAgents_ = null; + monitoredAgentsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + totalSize_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_ListMonitoredAgentsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse build() { + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse buildPartial() { + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse result = + new com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse result) { + if (monitoredAgentsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + monitoredAgents_ = java.util.Collections.unmodifiableList(monitoredAgents_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.monitoredAgents_ = monitoredAgents_; + } else { + result.monitoredAgents_ = monitoredAgentsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.totalSize_ = totalSize_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse) { + return mergeFrom((com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse other) { + if (other == com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse.getDefaultInstance()) + return this; + if (monitoredAgentsBuilder_ == null) { + if (!other.monitoredAgents_.isEmpty()) { + if (monitoredAgents_.isEmpty()) { + monitoredAgents_ = other.monitoredAgents_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureMonitoredAgentsIsMutable(); + monitoredAgents_.addAll(other.monitoredAgents_); + } + onChanged(); + } + } else { + if (!other.monitoredAgents_.isEmpty()) { + if (monitoredAgentsBuilder_.isEmpty()) { + monitoredAgentsBuilder_.dispose(); + monitoredAgentsBuilder_ = null; + monitoredAgents_ = other.monitoredAgents_; + bitField0_ = (bitField0_ & ~0x00000001); + monitoredAgentsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetMonitoredAgentsFieldBuilder() + : null; + } else { + monitoredAgentsBuilder_.addAllMessages(other.monitoredAgents_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.getTotalSize() != 0) { + setTotalSize(other.getTotalSize()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.aiplatform.v1.MonitoredAgent m = + input.readMessage( + com.google.cloud.aiplatform.v1.MonitoredAgent.parser(), extensionRegistry); + if (monitoredAgentsBuilder_ == null) { + ensureMonitoredAgentsIsMutable(); + monitoredAgents_.add(m); + } else { + monitoredAgentsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 24: + { + totalSize_ = input.readInt32(); + bitField0_ |= 0x00000004; + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List monitoredAgents_ = + java.util.Collections.emptyList(); + + private void ensureMonitoredAgentsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + monitoredAgents_ = + new java.util.ArrayList( + monitoredAgents_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.MonitoredAgent, + com.google.cloud.aiplatform.v1.MonitoredAgent.Builder, + com.google.cloud.aiplatform.v1.MonitoredAgentOrBuilder> + monitoredAgentsBuilder_; + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public java.util.List getMonitoredAgentsList() { + if (monitoredAgentsBuilder_ == null) { + return java.util.Collections.unmodifiableList(monitoredAgents_); + } else { + return monitoredAgentsBuilder_.getMessageList(); + } + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public int getMonitoredAgentsCount() { + if (monitoredAgentsBuilder_ == null) { + return monitoredAgents_.size(); + } else { + return monitoredAgentsBuilder_.getCount(); + } + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public com.google.cloud.aiplatform.v1.MonitoredAgent getMonitoredAgents(int index) { + if (monitoredAgentsBuilder_ == null) { + return monitoredAgents_.get(index); + } else { + return monitoredAgentsBuilder_.getMessage(index); + } + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public Builder setMonitoredAgents( + int index, com.google.cloud.aiplatform.v1.MonitoredAgent value) { + if (monitoredAgentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMonitoredAgentsIsMutable(); + monitoredAgents_.set(index, value); + onChanged(); + } else { + monitoredAgentsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public Builder setMonitoredAgents( + int index, com.google.cloud.aiplatform.v1.MonitoredAgent.Builder builderForValue) { + if (monitoredAgentsBuilder_ == null) { + ensureMonitoredAgentsIsMutable(); + monitoredAgents_.set(index, builderForValue.build()); + onChanged(); + } else { + monitoredAgentsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public Builder addMonitoredAgents(com.google.cloud.aiplatform.v1.MonitoredAgent value) { + if (monitoredAgentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMonitoredAgentsIsMutable(); + monitoredAgents_.add(value); + onChanged(); + } else { + monitoredAgentsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public Builder addMonitoredAgents( + int index, com.google.cloud.aiplatform.v1.MonitoredAgent value) { + if (monitoredAgentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMonitoredAgentsIsMutable(); + monitoredAgents_.add(index, value); + onChanged(); + } else { + monitoredAgentsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public Builder addMonitoredAgents( + com.google.cloud.aiplatform.v1.MonitoredAgent.Builder builderForValue) { + if (monitoredAgentsBuilder_ == null) { + ensureMonitoredAgentsIsMutable(); + monitoredAgents_.add(builderForValue.build()); + onChanged(); + } else { + monitoredAgentsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public Builder addMonitoredAgents( + int index, com.google.cloud.aiplatform.v1.MonitoredAgent.Builder builderForValue) { + if (monitoredAgentsBuilder_ == null) { + ensureMonitoredAgentsIsMutable(); + monitoredAgents_.add(index, builderForValue.build()); + onChanged(); + } else { + monitoredAgentsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public Builder addAllMonitoredAgents( + java.lang.Iterable values) { + if (monitoredAgentsBuilder_ == null) { + ensureMonitoredAgentsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, monitoredAgents_); + onChanged(); + } else { + monitoredAgentsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public Builder clearMonitoredAgents() { + if (monitoredAgentsBuilder_ == null) { + monitoredAgents_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + monitoredAgentsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public Builder removeMonitoredAgents(int index) { + if (monitoredAgentsBuilder_ == null) { + ensureMonitoredAgentsIsMutable(); + monitoredAgents_.remove(index); + onChanged(); + } else { + monitoredAgentsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public com.google.cloud.aiplatform.v1.MonitoredAgent.Builder getMonitoredAgentsBuilder( + int index) { + return internalGetMonitoredAgentsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public com.google.cloud.aiplatform.v1.MonitoredAgentOrBuilder getMonitoredAgentsOrBuilder( + int index) { + if (monitoredAgentsBuilder_ == null) { + return monitoredAgents_.get(index); + } else { + return monitoredAgentsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public java.util.List + getMonitoredAgentsOrBuilderList() { + if (monitoredAgentsBuilder_ != null) { + return monitoredAgentsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(monitoredAgents_); + } + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public com.google.cloud.aiplatform.v1.MonitoredAgent.Builder addMonitoredAgentsBuilder() { + return internalGetMonitoredAgentsFieldBuilder() + .addBuilder(com.google.cloud.aiplatform.v1.MonitoredAgent.getDefaultInstance()); + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public com.google.cloud.aiplatform.v1.MonitoredAgent.Builder addMonitoredAgentsBuilder( + int index) { + return internalGetMonitoredAgentsFieldBuilder() + .addBuilder(index, com.google.cloud.aiplatform.v1.MonitoredAgent.getDefaultInstance()); + } + + /** + * + * + *
+     * A list of MonitoredAgents that matches the specified filter in
+     * the request.
+     * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + public java.util.List + getMonitoredAgentsBuilderList() { + return internalGetMonitoredAgentsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.MonitoredAgent, + com.google.cloud.aiplatform.v1.MonitoredAgent.Builder, + com.google.cloud.aiplatform.v1.MonitoredAgentOrBuilder> + internalGetMonitoredAgentsFieldBuilder() { + if (monitoredAgentsBuilder_ == null) { + monitoredAgentsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.aiplatform.v1.MonitoredAgent, + com.google.cloud.aiplatform.v1.MonitoredAgent.Builder, + com.google.cloud.aiplatform.v1.MonitoredAgentOrBuilder>( + monitoredAgents_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + monitoredAgents_ = null; + } + return monitoredAgentsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * A token, which can be sent as `page_token` to retrieve the next page.
+     * If this field is omitted, there are no subsequent pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private int totalSize_; + + /** + * + * + *
+     * The total number of MonitoredAgents matching the request, after any
+     * `filter` is applied.
+     * 
+ * + * int32 total_size = 3; + * + * @return The totalSize. + */ + @java.lang.Override + public int getTotalSize() { + return totalSize_; + } + + /** + * + * + *
+     * The total number of MonitoredAgents matching the request, after any
+     * `filter` is applied.
+     * 
+ * + * int32 total_size = 3; + * + * @param value The totalSize to set. + * @return This builder for chaining. + */ + public Builder setTotalSize(int value) { + + totalSize_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * The total number of MonitoredAgents matching the request, after any
+     * `filter` is applied.
+     * 
+ * + * int32 total_size = 3; + * + * @return This builder for chaining. + */ + public Builder clearTotalSize() { + bitField0_ = (bitField0_ & ~0x00000004); + totalSize_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ListMonitoredAgentsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ListMonitoredAgentsResponse) + private static final com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse(); + } + + public static com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListMonitoredAgentsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsResponseOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsResponseOrBuilder.java new file mode 100644 index 000000000000..1d53c6a8bb38 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ListMonitoredAgentsResponseOrBuilder.java @@ -0,0 +1,131 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface ListMonitoredAgentsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.ListMonitoredAgentsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * A list of MonitoredAgents that matches the specified filter in
+   * the request.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + java.util.List getMonitoredAgentsList(); + + /** + * + * + *
+   * A list of MonitoredAgents that matches the specified filter in
+   * the request.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + com.google.cloud.aiplatform.v1.MonitoredAgent getMonitoredAgents(int index); + + /** + * + * + *
+   * A list of MonitoredAgents that matches the specified filter in
+   * the request.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + int getMonitoredAgentsCount(); + + /** + * + * + *
+   * A list of MonitoredAgents that matches the specified filter in
+   * the request.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + java.util.List + getMonitoredAgentsOrBuilderList(); + + /** + * + * + *
+   * A list of MonitoredAgents that matches the specified filter in
+   * the request.
+   * 
+ * + * repeated .google.cloud.aiplatform.v1.MonitoredAgent monitored_agents = 1; + */ + com.google.cloud.aiplatform.v1.MonitoredAgentOrBuilder getMonitoredAgentsOrBuilder(int index); + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
+   * A token, which can be sent as `page_token` to retrieve the next page.
+   * If this field is omitted, there are no subsequent pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); + + /** + * + * + *
+   * The total number of MonitoredAgents matching the request, after any
+   * `filter` is applied.
+   * 
+ * + * int32 total_size = 3; + * + * @return The totalSize. + */ + int getTotalSize(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/MonitoredAgent.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/MonitoredAgent.java new file mode 100644 index 000000000000..83d34ce263c2 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/MonitoredAgent.java @@ -0,0 +1,2261 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Represents a monitored agent in a specific Location.
+ * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.MonitoredAgent} + */ +@com.google.protobuf.Generated +public final class MonitoredAgent extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.MonitoredAgent) + MonitoredAgentOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "MonitoredAgent"); + } + + // Use MonitoredAgent.newBuilder() to construct. + private MonitoredAgent(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private MonitoredAgent() { + name_ = ""; + displayName_ = ""; + state_ = 0; + statusMessage_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_MonitoredAgent_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_MonitoredAgent_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.MonitoredAgent.class, + com.google.cloud.aiplatform.v1.MonitoredAgent.Builder.class); + } + + /** + * + * + *
+   * Represents the detailed status of the MonitoredAgent.
+   * 
+ * + * Protobuf enum {@code google.cloud.aiplatform.v1.MonitoredAgent.EnablementState} + */ + public enum EnablementState implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * The default value. This value is used if the state is omitted.
+     * 
+ * + * ENABLEMENT_STATE_UNSPECIFIED = 0; + */ + ENABLEMENT_STATE_UNSPECIFIED(0), + /** + * + * + *
+     * The agent is successfully enabled and active.
+     * 
+ * + * ACTIVE = 1; + */ + ACTIVE(1), + /** + * + * + *
+     * The agent is in the process of being enabled.
+     * 
+ * + * ENABLING = 3; + */ + ENABLING(3), + /** + * + * + *
+     * The agent is disabled.
+     * 
+ * + * DISABLED = 6; + */ + DISABLED(6), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "EnablementState"); + } + + /** + * + * + *
+     * The default value. This value is used if the state is omitted.
+     * 
+ * + * ENABLEMENT_STATE_UNSPECIFIED = 0; + */ + public static final int ENABLEMENT_STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+     * The agent is successfully enabled and active.
+     * 
+ * + * ACTIVE = 1; + */ + public static final int ACTIVE_VALUE = 1; + + /** + * + * + *
+     * The agent is in the process of being enabled.
+     * 
+ * + * ENABLING = 3; + */ + public static final int ENABLING_VALUE = 3; + + /** + * + * + *
+     * The agent is disabled.
+     * 
+ * + * DISABLED = 6; + */ + public static final int DISABLED_VALUE = 6; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static EnablementState valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static EnablementState forNumber(int value) { + switch (value) { + case 0: + return ENABLEMENT_STATE_UNSPECIFIED; + case 1: + return ACTIVE; + case 3: + return ENABLING; + case 6: + return DISABLED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public EnablementState findValueByNumber(int number) { + return EnablementState.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.MonitoredAgent.getDescriptor().getEnumTypes().get(0); + } + + private static final EnablementState[] VALUES = values(); + + public static EnablementState valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private EnablementState(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.aiplatform.v1.MonitoredAgent.EnablementState) + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
+   * Identifier. The resource name of the MonitoredAgent.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
+   * Identifier. The resource name of the MonitoredAgent.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object displayName_ = ""; + + /** + * + * + *
+   * Optional. The display name of the MonitoredAgent.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + + /** + * + * + *
+   * Optional. The display name of the MonitoredAgent.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int AGENT_RESOURCE_FIELD_NUMBER = 3; + private com.google.cloud.aiplatform.v1.AgentResource agentResource_; + + /** + * + * + *
+   * Required. The configuration for the agent being monitored.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the agentResource field is set. + */ + @java.lang.Override + public boolean hasAgentResource() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
+   * Required. The configuration for the agent being monitored.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentResource. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResource getAgentResource() { + return agentResource_ == null + ? com.google.cloud.aiplatform.v1.AgentResource.getDefaultInstance() + : agentResource_; + } + + /** + * + * + *
+   * Required. The configuration for the agent being monitored.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.AgentResourceOrBuilder getAgentResourceOrBuilder() { + return agentResource_ == null + ? com.google.cloud.aiplatform.v1.AgentResource.getDefaultInstance() + : agentResource_; + } + + public static final int STATE_FIELD_NUMBER = 4; + private int state_ = 0; + + /** + * + * + *
+   * Output only. The current state of the agent's enablement.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
+   * Output only. The current state of the agent's enablement.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState getState() { + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState result = + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.forNumber(state_); + return result == null + ? com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.UNRECOGNIZED + : result; + } + + public static final int STATUS_MESSAGE_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object statusMessage_ = ""; + + /** + * + * + *
+   * Output only. A brief message explaining the current state.
+   * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The statusMessage. + */ + @java.lang.Override + public java.lang.String getStatusMessage() { + java.lang.Object ref = statusMessage_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + statusMessage_ = s; + return s; + } + } + + /** + * + * + *
+   * Output only. A brief message explaining the current state.
+   * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for statusMessage. + */ + @java.lang.Override + public com.google.protobuf.ByteString getStatusMessageBytes() { + java.lang.Object ref = statusMessage_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + statusMessage_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 8; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 9; + private com.google.protobuf.Timestamp updateTime_; + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, displayName_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getAgentResource()); + } + if (state_ + != com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState + .ENABLEMENT_STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(4, state_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(statusMessage_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, statusMessage_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(8, getCreateTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(9, getUpdateTime()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, displayName_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getAgentResource()); + } + if (state_ + != com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState + .ENABLEMENT_STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, state_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(statusMessage_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, statusMessage_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getCreateTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, getUpdateTime()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.aiplatform.v1.MonitoredAgent)) { + return super.equals(obj); + } + com.google.cloud.aiplatform.v1.MonitoredAgent other = + (com.google.cloud.aiplatform.v1.MonitoredAgent) obj; + + if (!getName().equals(other.getName())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (hasAgentResource() != other.hasAgentResource()) return false; + if (hasAgentResource()) { + if (!getAgentResource().equals(other.getAgentResource())) return false; + } + if (state_ != other.state_) return false; + if (!getStatusMessage().equals(other.getStatusMessage())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + if (hasAgentResource()) { + hash = (37 * hash) + AGENT_RESOURCE_FIELD_NUMBER; + hash = (53 * hash) + getAgentResource().hashCode(); + } + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + hash = (37 * hash) + STATUS_MESSAGE_FIELD_NUMBER; + hash = (53 * hash) + getStatusMessage().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.aiplatform.v1.MonitoredAgent prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
+   * Represents a monitored agent in a specific Location.
+   * 
+ * + * Protobuf type {@code google.cloud.aiplatform.v1.MonitoredAgent} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.MonitoredAgent) + com.google.cloud.aiplatform.v1.MonitoredAgentOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_MonitoredAgent_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_MonitoredAgent_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.aiplatform.v1.MonitoredAgent.class, + com.google.cloud.aiplatform.v1.MonitoredAgent.Builder.class); + } + + // Construct using com.google.cloud.aiplatform.v1.MonitoredAgent.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetAgentResourceFieldBuilder(); + internalGetCreateTimeFieldBuilder(); + internalGetUpdateTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + displayName_ = ""; + agentResource_ = null; + if (agentResourceBuilder_ != null) { + agentResourceBuilder_.dispose(); + agentResourceBuilder_ = null; + } + state_ = 0; + statusMessage_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto + .internal_static_google_cloud_aiplatform_v1_MonitoredAgent_descriptor; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgent getDefaultInstanceForType() { + return com.google.cloud.aiplatform.v1.MonitoredAgent.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgent build() { + com.google.cloud.aiplatform.v1.MonitoredAgent result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgent buildPartial() { + com.google.cloud.aiplatform.v1.MonitoredAgent result = + new com.google.cloud.aiplatform.v1.MonitoredAgent(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.aiplatform.v1.MonitoredAgent result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.displayName_ = displayName_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.agentResource_ = + agentResourceBuilder_ == null ? agentResource_ : agentResourceBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.state_ = state_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.statusMessage_ = statusMessage_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.aiplatform.v1.MonitoredAgent) { + return mergeFrom((com.google.cloud.aiplatform.v1.MonitoredAgent) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.aiplatform.v1.MonitoredAgent other) { + if (other == com.google.cloud.aiplatform.v1.MonitoredAgent.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasAgentResource()) { + mergeAgentResource(other.getAgentResource()); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (!other.getStatusMessage().isEmpty()) { + statusMessage_ = other.statusMessage_; + bitField0_ |= 0x00000010; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetAgentResourceFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 32: + { + state_ = input.readEnum(); + bitField0_ |= 0x00000008; + break; + } // case 32 + case 42: + { + statusMessage_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 66: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 66 + case 74: + { + input.readMessage( + internalGetUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000040; + break; + } // case 74 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
+     * Identifier. The resource name of the MonitoredAgent.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Identifier. The resource name of the MonitoredAgent.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Identifier. The resource name of the MonitoredAgent.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. The resource name of the MonitoredAgent.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
+     * Identifier. The resource name of the MonitoredAgent.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + + /** + * + * + *
+     * Optional. The display name of the MonitoredAgent.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Optional. The display name of the MonitoredAgent.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Optional. The display name of the MonitoredAgent.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The display name of the MonitoredAgent.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + displayName_ = getDefaultInstance().getDisplayName(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
+     * Optional. The display name of the MonitoredAgent.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.cloud.aiplatform.v1.AgentResource agentResource_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.AgentResource, + com.google.cloud.aiplatform.v1.AgentResource.Builder, + com.google.cloud.aiplatform.v1.AgentResourceOrBuilder> + agentResourceBuilder_; + + /** + * + * + *
+     * Required. The configuration for the agent being monitored.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the agentResource field is set. + */ + public boolean hasAgentResource() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
+     * Required. The configuration for the agent being monitored.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentResource. + */ + public com.google.cloud.aiplatform.v1.AgentResource getAgentResource() { + if (agentResourceBuilder_ == null) { + return agentResource_ == null + ? com.google.cloud.aiplatform.v1.AgentResource.getDefaultInstance() + : agentResource_; + } else { + return agentResourceBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Required. The configuration for the agent being monitored.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setAgentResource(com.google.cloud.aiplatform.v1.AgentResource value) { + if (agentResourceBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + agentResource_ = value; + } else { + agentResourceBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The configuration for the agent being monitored.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setAgentResource( + com.google.cloud.aiplatform.v1.AgentResource.Builder builderForValue) { + if (agentResourceBuilder_ == null) { + agentResource_ = builderForValue.build(); + } else { + agentResourceBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The configuration for the agent being monitored.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeAgentResource(com.google.cloud.aiplatform.v1.AgentResource value) { + if (agentResourceBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && agentResource_ != null + && agentResource_ + != com.google.cloud.aiplatform.v1.AgentResource.getDefaultInstance()) { + getAgentResourceBuilder().mergeFrom(value); + } else { + agentResource_ = value; + } + } else { + agentResourceBuilder_.mergeFrom(value); + } + if (agentResource_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Required. The configuration for the agent being monitored.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearAgentResource() { + bitField0_ = (bitField0_ & ~0x00000004); + agentResource_ = null; + if (agentResourceBuilder_ != null) { + agentResourceBuilder_.dispose(); + agentResourceBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Required. The configuration for the agent being monitored.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.aiplatform.v1.AgentResource.Builder getAgentResourceBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetAgentResourceFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Required. The configuration for the agent being monitored.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.aiplatform.v1.AgentResourceOrBuilder getAgentResourceOrBuilder() { + if (agentResourceBuilder_ != null) { + return agentResourceBuilder_.getMessageOrBuilder(); + } else { + return agentResource_ == null + ? com.google.cloud.aiplatform.v1.AgentResource.getDefaultInstance() + : agentResource_; + } + } + + /** + * + * + *
+     * Required. The configuration for the agent being monitored.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.AgentResource, + com.google.cloud.aiplatform.v1.AgentResource.Builder, + com.google.cloud.aiplatform.v1.AgentResourceOrBuilder> + internalGetAgentResourceFieldBuilder() { + if (agentResourceBuilder_ == null) { + agentResourceBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.aiplatform.v1.AgentResource, + com.google.cloud.aiplatform.v1.AgentResource.Builder, + com.google.cloud.aiplatform.v1.AgentResourceOrBuilder>( + getAgentResource(), getParentForChildren(), isClean()); + agentResource_ = null; + } + return agentResourceBuilder_; + } + + private int state_ = 0; + + /** + * + * + *
+     * Output only. The current state of the agent's enablement.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
+     * Output only. The current state of the agent's enablement.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The current state of the agent's enablement.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState getState() { + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState result = + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.forNumber(state_); + return result == null + ? com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState.UNRECOGNIZED + : result; + } + + /** + * + * + *
+     * Output only. The current state of the agent's enablement.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000008; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The current state of the agent's enablement.
+     * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000008); + state_ = 0; + onChanged(); + return this; + } + + private java.lang.Object statusMessage_ = ""; + + /** + * + * + *
+     * Output only. A brief message explaining the current state.
+     * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The statusMessage. + */ + public java.lang.String getStatusMessage() { + java.lang.Object ref = statusMessage_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + statusMessage_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
+     * Output only. A brief message explaining the current state.
+     * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for statusMessage. + */ + public com.google.protobuf.ByteString getStatusMessageBytes() { + java.lang.Object ref = statusMessage_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + statusMessage_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
+     * Output only. A brief message explaining the current state.
+     * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The statusMessage to set. + * @return This builder for chaining. + */ + public Builder setStatusMessage(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + statusMessage_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. A brief message explaining the current state.
+     * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearStatusMessage() { + statusMessage_ = getDefaultInstance().getStatusMessage(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. A brief message explaining the current state.
+     * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for statusMessage to set. + * @return This builder for chaining. + */ + public Builder setStatusMessageBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + statusMessage_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000020); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was last updated.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was last updated.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was last updated.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + } else { + updateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was last updated.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was last updated.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000040) != 0) + && updateTime_ != null + && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getUpdateTimeBuilder().mergeFrom(value); + } else { + updateTime_ = value; + } + } else { + updateTimeBuilder_.mergeFrom(value); + } + if (updateTime_ != null) { + bitField0_ |= 0x00000040; + onChanged(); + } + return this; + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was last updated.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000040); + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was last updated.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + bitField0_ |= 0x00000040; + onChanged(); + return internalGetUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was last updated.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + + /** + * + * + *
+     * Output only. The time the MonitoredAgent was last updated.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.MonitoredAgent) + } + + // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.MonitoredAgent) + private static final com.google.cloud.aiplatform.v1.MonitoredAgent DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.MonitoredAgent(); + } + + public static com.google.cloud.aiplatform.v1.MonitoredAgent getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public MonitoredAgent parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.aiplatform.v1.MonitoredAgent getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/MonitoredAgentName.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/MonitoredAgentName.java new file mode 100644 index 000000000000..56f9f81755c8 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/MonitoredAgentName.java @@ -0,0 +1,230 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class MonitoredAgentName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_MONITORED_AGENT = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String monitoredAgent; + + @Deprecated + protected MonitoredAgentName() { + project = null; + location = null; + monitoredAgent = null; + } + + private MonitoredAgentName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + monitoredAgent = Preconditions.checkNotNull(builder.getMonitoredAgent()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getMonitoredAgent() { + return monitoredAgent; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static MonitoredAgentName of(String project, String location, String monitoredAgent) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setMonitoredAgent(monitoredAgent) + .build(); + } + + public static String format(String project, String location, String monitoredAgent) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setMonitoredAgent(monitoredAgent) + .build() + .toString(); + } + + public static @Nullable MonitoredAgentName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_MONITORED_AGENT.validatedMatch( + formattedString, "MonitoredAgentName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("monitored_agent")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable MonitoredAgentName> values) { + List list = new ArrayList<>(values.size()); + for (MonitoredAgentName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_MONITORED_AGENT.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (monitoredAgent != null) { + fieldMapBuilder.put("monitored_agent", monitoredAgent); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_MONITORED_AGENT.instantiate( + "project", project, "location", location, "monitored_agent", monitoredAgent); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + MonitoredAgentName that = ((MonitoredAgentName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.monitoredAgent, that.monitoredAgent); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(monitoredAgent); + return h; + } + + /** Builder for projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}. */ + public static class Builder { + private String project; + private String location; + private String monitoredAgent; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getMonitoredAgent() { + return monitoredAgent; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setMonitoredAgent(String monitoredAgent) { + this.monitoredAgent = monitoredAgent; + return this; + } + + private Builder(MonitoredAgentName monitoredAgentName) { + this.project = monitoredAgentName.project; + this.location = monitoredAgentName.location; + this.monitoredAgent = monitoredAgentName.monitoredAgent; + } + + public MonitoredAgentName build() { + return new MonitoredAgentName(this); + } + } +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/MonitoredAgentOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/MonitoredAgentOrBuilder.java new file mode 100644 index 000000000000..1150d49ac720 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/MonitoredAgentOrBuilder.java @@ -0,0 +1,259 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +@com.google.protobuf.Generated +public interface MonitoredAgentOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1.MonitoredAgent) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Identifier. The resource name of the MonitoredAgent.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
+   * Identifier. The resource name of the MonitoredAgent.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Optional. The display name of the MonitoredAgent.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
+   * Optional. The display name of the MonitoredAgent.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
+   * Required. The configuration for the agent being monitored.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the agentResource field is set. + */ + boolean hasAgentResource(); + + /** + * + * + *
+   * Required. The configuration for the agent being monitored.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The agentResource. + */ + com.google.cloud.aiplatform.v1.AgentResource getAgentResource(); + + /** + * + * + *
+   * Required. The configuration for the agent being monitored.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.AgentResource agent_resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.aiplatform.v1.AgentResourceOrBuilder getAgentResourceOrBuilder(); + + /** + * + * + *
+   * Output only. The current state of the agent's enablement.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
+   * Output only. The current state of the agent's enablement.
+   * 
+ * + * + * .google.cloud.aiplatform.v1.MonitoredAgent.EnablementState state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.aiplatform.v1.MonitoredAgent.EnablementState getState(); + + /** + * + * + *
+   * Output only. A brief message explaining the current state.
+   * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The statusMessage. + */ + java.lang.String getStatusMessage(); + + /** + * + * + *
+   * Output only. A brief message explaining the current state.
+   * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for statusMessage. + */ + com.google.protobuf.ByteString getStatusMessageBytes(); + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + + /** + * + * + *
+   * Output only. The time the MonitoredAgent was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ReasoningEngineSpec.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ReasoningEngineSpec.java index 651c6c50c490..dd843cca1005 100644 --- a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ReasoningEngineSpec.java +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ReasoningEngineSpec.java @@ -89,7 +89,11 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { *
      * Default value. Use a custom service account if the `service_account`
      * field is set, otherwise use the default Vertex AI Reasoning Engine
-     * Service Agent in the project. Same behavior as SERVICE_ACCOUNT.
+     * Service Agent in the project. Same behavior as `SERVICE_ACCOUNT`.
+     *
+     * WARNING: The default service agent is shared across all Reasoning
+     * Engines in the project that do not specify an isolated identity or
+     * custom service account; see `identity_type` for security guidance.
      * 
* * IDENTITY_TYPE_UNSPECIFIED = 0; @@ -102,6 +106,10 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { * Use a custom service account if the `service_account` field is set, * otherwise use the default Vertex AI Reasoning Engine Service Agent in the * project. + * + * WARNING: The default service agent is shared across all Reasoning + * Engines in the project that do not specify an isolated identity or + * custom service account; see `identity_type` for security guidance. * * * SERVICE_ACCOUNT = 2; @@ -112,6 +120,9 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { * *
      * Use Agent Identity. The `service_account` field must not be set.
+     * Restrict `aiplatform.reasoningEngines.update` permissions on the engine
+     * because any principal permitted to update it can run code as its
+     * identity.
      * 
* * AGENT_IDENTITY = 3; @@ -136,7 +147,11 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { *
      * Default value. Use a custom service account if the `service_account`
      * field is set, otherwise use the default Vertex AI Reasoning Engine
-     * Service Agent in the project. Same behavior as SERVICE_ACCOUNT.
+     * Service Agent in the project. Same behavior as `SERVICE_ACCOUNT`.
+     *
+     * WARNING: The default service agent is shared across all Reasoning
+     * Engines in the project that do not specify an isolated identity or
+     * custom service account; see `identity_type` for security guidance.
      * 
* * IDENTITY_TYPE_UNSPECIFIED = 0; @@ -150,6 +165,10 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { * Use a custom service account if the `service_account` field is set, * otherwise use the default Vertex AI Reasoning Engine Service Agent in the * project. + * + * WARNING: The default service agent is shared across all Reasoning + * Engines in the project that do not specify an isolated identity or + * custom service account; see `identity_type` for security guidance. * * * SERVICE_ACCOUNT = 2; @@ -161,6 +180,9 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { * *
      * Use Agent Identity. The `service_account` field must not be set.
+     * Restrict `aiplatform.reasoningEngines.update` permissions on the engine
+     * because any principal permitted to update it can run code as its
+     * identity.
      * 
* * AGENT_IDENTITY = 3; @@ -1616,11 +1638,33 @@ public interface DeploymentSpecOrBuilder * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -1633,11 +1677,33 @@ public interface DeploymentSpecOrBuilder * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -1650,11 +1716,33 @@ public interface DeploymentSpecOrBuilder * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -1667,11 +1755,33 @@ public interface DeploymentSpecOrBuilder * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -1685,11 +1795,33 @@ public interface DeploymentSpecOrBuilder * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -2113,11 +2245,33 @@ public com.google.cloud.aiplatform.v1.EnvVarOrBuilder getEnvOrBuilder(int index) * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -2133,11 +2287,33 @@ public java.util.List getSecretEnvL * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -2154,11 +2330,33 @@ public java.util.List getSecretEnvL * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -2174,11 +2372,33 @@ public int getSecretEnvCount() { * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -2194,11 +2414,33 @@ public com.google.cloud.aiplatform.v1.SecretEnvVar getSecretEnv(int index) { * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -3621,11 +3863,33 @@ private void ensureSecretEnvIsMutable() { * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3644,11 +3908,33 @@ public java.util.List getSecretEnvL * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3667,11 +3953,33 @@ public int getSecretEnvCount() { * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3690,11 +3998,33 @@ public com.google.cloud.aiplatform.v1.SecretEnvVar getSecretEnv(int index) { * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3719,11 +4049,33 @@ public Builder setSecretEnv(int index, com.google.cloud.aiplatform.v1.SecretEnvV * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3746,11 +4098,33 @@ public Builder setSecretEnv( * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3775,11 +4149,33 @@ public Builder addSecretEnv(com.google.cloud.aiplatform.v1.SecretEnvVar value) { * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3804,11 +4200,33 @@ public Builder addSecretEnv(int index, com.google.cloud.aiplatform.v1.SecretEnvV * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3831,11 +4249,33 @@ public Builder addSecretEnv( * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3858,11 +4298,33 @@ public Builder addSecretEnv( * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3885,11 +4347,33 @@ public Builder addAllSecretEnv( * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3911,11 +4395,33 @@ public Builder clearSecretEnv() { * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3937,11 +4443,33 @@ public Builder removeSecretEnv(int index) { * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3956,11 +4484,33 @@ public com.google.cloud.aiplatform.v1.SecretEnvVar.Builder getSecretEnvBuilder(i * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3979,11 +4529,33 @@ public com.google.cloud.aiplatform.v1.SecretEnvVarOrBuilder getSecretEnvOrBuilde * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -4003,11 +4575,33 @@ public com.google.cloud.aiplatform.v1.SecretEnvVarOrBuilder getSecretEnvOrBuilde * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -4023,11 +4617,33 @@ public com.google.cloud.aiplatform.v1.SecretEnvVar.Builder addSecretEnvBuilder() * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -4043,11 +4659,33 @@ public com.google.cloud.aiplatform.v1.SecretEnvVar.Builder addSecretEnvBuilder(i * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -15148,8 +15786,19 @@ public com.google.cloud.aiplatform.v1.ReasoningEngineSpec.ContainerSpec getConta * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -15168,8 +15817,19 @@ public boolean hasServiceAccount() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -15196,8 +15856,19 @@ public java.lang.String getServiceAccount() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -15511,6 +16182,17 @@ public com.google.protobuf.ByteString getAgentFrameworkBytes() { * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -15532,6 +16214,17 @@ public int getIdentityTypeValue() { * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -16762,8 +17455,19 @@ public Builder clearContainerSpec() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -16781,8 +17485,19 @@ public boolean hasServiceAccount() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -16808,8 +17523,19 @@ public java.lang.String getServiceAccount() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -16835,8 +17561,19 @@ public com.google.protobuf.ByteString getServiceAccountBytes() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -16861,8 +17598,19 @@ public Builder setServiceAccount(java.lang.String value) { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -16883,8 +17631,19 @@ public Builder clearServiceAccount() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -17934,6 +18693,17 @@ public Builder setAgentFrameworkBytes(com.google.protobuf.ByteString value) { * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -17955,6 +18725,17 @@ public int getIdentityTypeValue() { * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -17979,6 +18760,17 @@ public Builder setIdentityTypeValue(int value) { * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -18004,6 +18796,17 @@ public com.google.cloud.aiplatform.v1.ReasoningEngineSpec.IdentityType getIdenti * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -18032,6 +18835,17 @@ public Builder setIdentityType( * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ReasoningEngineSpecOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ReasoningEngineSpecOrBuilder.java index 2c05ea3825bd..f4ae13fab203 100644 --- a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ReasoningEngineSpecOrBuilder.java +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/ReasoningEngineSpecOrBuilder.java @@ -112,8 +112,19 @@ public interface ReasoningEngineSpecOrBuilder * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -129,8 +140,19 @@ public interface ReasoningEngineSpecOrBuilder * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -146,8 +168,19 @@ public interface ReasoningEngineSpecOrBuilder * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -366,6 +399,17 @@ public interface ReasoningEngineSpecOrBuilder * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -384,6 +428,17 @@ public interface ReasoningEngineSpecOrBuilder * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/Severity.java b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/Severity.java new file mode 100644 index 000000000000..7c1547c2204a --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/java/com/google/cloud/aiplatform/v1/Severity.java @@ -0,0 +1,242 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.aiplatform.v1; + +/** + * + * + *
+ * Severity levels available for Agent Anomaly Detection findings.
+ * Numeric values are ordered ascending by severity, so comparisons such as
+ * `severity >= SEVERITY_HIGH` behave as expected.
+ * Additional values may be added in the future.
+ * 
+ * + * Protobuf enum {@code google.cloud.aiplatform.v1.Severity} + */ +@com.google.protobuf.Generated +public enum Severity implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * Unspecified severity.
+   * 
+ * + * SEVERITY_UNSPECIFIED = 0; + */ + SEVERITY_UNSPECIFIED(0), + /** + * + * + *
+   * Low severity.
+   * 
+ * + * SEVERITY_LOW = 1; + */ + SEVERITY_LOW(1), + /** + * + * + *
+   * Medium severity.
+   * 
+ * + * SEVERITY_MEDIUM = 2; + */ + SEVERITY_MEDIUM(2), + /** + * + * + *
+   * High severity.
+   * 
+ * + * SEVERITY_HIGH = 3; + */ + SEVERITY_HIGH(3), + /** + * + * + *
+   * Critical severity.
+   * 
+ * + * SEVERITY_CRITICAL = 4; + */ + SEVERITY_CRITICAL(4), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Severity"); + } + + /** + * + * + *
+   * Unspecified severity.
+   * 
+ * + * SEVERITY_UNSPECIFIED = 0; + */ + public static final int SEVERITY_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
+   * Low severity.
+   * 
+ * + * SEVERITY_LOW = 1; + */ + public static final int SEVERITY_LOW_VALUE = 1; + + /** + * + * + *
+   * Medium severity.
+   * 
+ * + * SEVERITY_MEDIUM = 2; + */ + public static final int SEVERITY_MEDIUM_VALUE = 2; + + /** + * + * + *
+   * High severity.
+   * 
+ * + * SEVERITY_HIGH = 3; + */ + public static final int SEVERITY_HIGH_VALUE = 3; + + /** + * + * + *
+   * Critical severity.
+   * 
+ * + * SEVERITY_CRITICAL = 4; + */ + public static final int SEVERITY_CRITICAL_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Severity valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static Severity forNumber(int value) { + switch (value) { + case 0: + return SEVERITY_UNSPECIFIED; + case 1: + return SEVERITY_LOW; + case 2: + return SEVERITY_MEDIUM; + case 3: + return SEVERITY_HIGH; + case 4: + return SEVERITY_CRITICAL; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Severity findValueByNumber(int number) { + return Severity.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceProto.getDescriptor() + .getEnumTypes() + .get(1); + } + + private static final Severity[] VALUES = values(); + + public static Severity valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Severity(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.aiplatform.v1.Severity) +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/proto/google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/proto/google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto new file mode 100644 index 000000000000..8fbd59dea436 --- /dev/null +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/proto/google/cloud/aiplatform/v1/agent_anomaly_detection_service.proto @@ -0,0 +1,1180 @@ +// Copyright 2026 Google LLC +// +// 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. + +syntax = "proto3"; + +package google.cloud.aiplatform.v1; + +import "google/api/annotations.proto"; +import "google/api/client.proto"; +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/cloud/aiplatform/v1/encryption_spec.proto"; +import "google/cloud/aiplatform/v1/operation.proto"; +import "google/longrunning/operations.proto"; +import "google/protobuf/empty.proto"; +import "google/protobuf/timestamp.proto"; + +option csharp_namespace = "Google.Cloud.AIPlatform.V1"; +option go_package = "cloud.google.com/go/aiplatform/apiv1/aiplatformpb;aiplatformpb"; +option java_multiple_files = true; +option java_outer_classname = "AgentAnomalyDetectionServiceProto"; +option java_package = "com.google.cloud.aiplatform.v1"; +option php_namespace = "Google\\Cloud\\AIPlatform\\V1"; +option ruby_package = "Google::Cloud::AIPlatform::V1"; + +// A service for managing Agent Anomaly Detection for monitored agents. +service AgentAnomalyDetectionService { + option (google.api.default_host) = "aiplatform.googleapis.com"; + option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/cloud-platform"; + + // Gets the details of a specific AgentAnomalyDetectionScope. + rpc GetAgentAnomalyDetectionScope(GetAgentAnomalyDetectionScopeRequest) + returns (AgentAnomalyDetectionScope) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/agentAnomalyDetectionScopes/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Gets the details of a specific MonitoredAgent. + rpc GetMonitoredAgent(GetMonitoredAgentRequest) returns (MonitoredAgent) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/monitoredAgents/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Lists MonitoredAgents in a specific Location. + rpc ListMonitoredAgents(ListMonitoredAgentsRequest) + returns (ListMonitoredAgentsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/monitoredAgents" + }; + option (google.api.method_signature) = "parent"; + } + + // Enables a specific MonitoredAgent. + rpc EnableMonitoredAgent(EnableMonitoredAgentRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{name=projects/*/locations/*/monitoredAgents/*}:enable" + body: "*" + }; + option (google.api.method_signature) = "name"; + option (google.longrunning.operation_info) = { + response_type: "MonitoredAgent" + metadata_type: "EnableMonitoredAgentOperationMetadata" + }; + } + + // Disables a specific MonitoredAgent. + rpc DisableMonitoredAgent(DisableMonitoredAgentRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{name=projects/*/locations/*/monitoredAgents/*}:disable" + body: "*" + }; + option (google.api.method_signature) = "name"; + option (google.longrunning.operation_info) = { + response_type: "MonitoredAgent" + metadata_type: "DisableMonitoredAgentOperationMetadata" + }; + } + + // Deletes a specific AgentAnomalyDetectionScope. + rpc DeleteAgentAnomalyDetectionScope(DeleteAgentAnomalyDetectionScopeRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/agentAnomalyDetectionScopes/*}" + }; + option (google.api.method_signature) = "name"; + option (google.longrunning.operation_info) = { + response_type: "google.protobuf.Empty" + metadata_type: "DeleteAgentAnomalyDetectionScopeOperationMetadata" + }; + } + + // Creates a new AgentAnomalyDetectionScope. + rpc CreateAgentAnomalyDetectionScope(CreateAgentAnomalyDetectionScopeRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*}/agentAnomalyDetectionScopes" + body: "agent_anomaly_detection_scope" + }; + option (google.api.method_signature) = + "parent,agent_anomaly_detection_scope,agent_anomaly_detection_scope_id"; + option (google.longrunning.operation_info) = { + response_type: "AgentAnomalyDetectionScope" + metadata_type: "CreateAgentAnomalyDetectionScopeOperationMetadata" + }; + } + + // Lists AgentAnomalyDetectionScopes in a Location. + rpc ListAgentAnomalyDetectionScopes(ListAgentAnomalyDetectionScopesRequest) + returns (ListAgentAnomalyDetectionScopesResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/agentAnomalyDetectionScopes" + }; + option (google.api.method_signature) = "parent"; + } + + // Lists AnalyzedSessions in a MonitoredAgent. + rpc ListAnalyzedSessions(ListAnalyzedSessionsRequest) + returns (ListAnalyzedSessionsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*/monitoredAgents/*}/analyzedSessions" + }; + option (google.api.method_signature) = "parent"; + } + + // Gets the details of a specific AnalyzedSession. + rpc GetAnalyzedSession(GetAnalyzedSessionRequest) returns (AnalyzedSession) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/monitoredAgents/*/analyzedSessions/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Lists AnalyzedInvocations in a MonitoredAgent's AnalyzedSession. + rpc ListAnalyzedInvocations(ListAnalyzedInvocationsRequest) + returns (ListAnalyzedInvocationsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*/monitoredAgents/*/analyzedSessions/*}/analyzedInvocations" + }; + option (google.api.method_signature) = "parent"; + } + + // Gets the details of a specific AnalyzedInvocation. + rpc GetAnalyzedInvocation(GetAnalyzedInvocationRequest) + returns (AnalyzedInvocation) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/monitoredAgents/*/analyzedSessions/*/analyzedInvocations/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Aggregates AnalyzedSessions across MonitoredAgents. + // + // To aggregate across all MonitoredAgents in a + // location, use the following format for the parent field: + // `projects/{project}/locations/{location}/monitoredAgents/-` + rpc AggregateAnalyzedSessions(AggregateAnalyzedSessionsRequest) + returns (AggregateAnalyzedSessionsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*/monitoredAgents/*}/analyzedSessions:aggregate" + }; + option (google.api.method_signature) = "parent"; + } + + // Clears (purges) the trained model artifacts derived from a MonitoredAgent's + // data. The purged model is rebuilt by the next scheduled training run. + // + // To clear every MonitoredAgent in a location's scope, use the `-` wildcard + // agent segment for the name field: + // `projects/{project}/locations/{location}/monitoredAgents/-` + // + // This is the on-demand data-deletion path for customers who have deleted the + // underlying logs / observability data a model was trained on. It deletes + // only the derived model artifacts (it does NOT delete the scope or stop + // monitoring). To stop monitoring an agent entirely, disable it via + // DisableMonitoredAgent. + rpc ClearTrainingData(ClearTrainingDataRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{name=projects/*/locations/*/monitoredAgents/*}:clearTrainingData" + body: "*" + }; + option (google.api.method_signature) = "name"; + option (google.longrunning.operation_info) = { + response_type: "ClearTrainingDataResponse" + metadata_type: "ClearTrainingDataOperationMetadata" + }; + } +} + +// The view options for AnalyzedSession. +enum AnalyzedSessionView { + // The default view: BASIC. + ANALYZED_SESSION_VIEW_UNSPECIFIED = 0; + + // Includes every `AnalyzedSession` field except `assessment`. + ANALYZED_SESSION_VIEW_BASIC = 1; + + // Includes all fields, including the detailed `assessment`. + // [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions] + // omits `assessment` in every view. To get it, call + // [AgentAnomalyDetectionService.GetAnalyzedSession][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.GetAnalyzedSession] + // with this view. + ANALYZED_SESSION_VIEW_FULL = 2; +} + +// Severity levels available for Agent Anomaly Detection findings. +// Numeric values are ordered ascending by severity, so comparisons such as +// `severity >= SEVERITY_HIGH` behave as expected. +// Additional values may be added in the future. +enum Severity { + // Unspecified severity. + SEVERITY_UNSPECIFIED = 0; + + // Low severity. + SEVERITY_LOW = 1; + + // Medium severity. + SEVERITY_MEDIUM = 2; + + // High severity. + SEVERITY_HIGH = 3; + + // Critical severity. + SEVERITY_CRITICAL = 4; +} + +// Represents an Agent Anomaly Detection Scope. +message AgentAnomalyDetectionScope { + option (google.api.resource) = { + type: "aiplatform.googleapis.com/AgentAnomalyDetectionScope" + pattern: "projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}" + plural: "agentAnomalyDetectionScopes" + singular: "agentAnomalyDetectionScope" + }; + + // The lifecycle state of an AgentAnomalyDetectionScope. + enum State { + // The default value. This value is unused. + STATE_UNSPECIFIED = 0; + + // The scope is being created and is not yet usable. + CREATING = 1; + + // The scope is active and usable. + ACTIVE = 2; + + // The scope is being deleted. + DELETING = 3; + + // Creation or deletion failed. The scope is not usable and must be deleted + // before a new scope can be created in the same region. + FAILED = 4; + + // The scope is being updated. + UPDATING = 5; + } + + // Identifier. The resource name of the AgentAnomalyDetectionScope. + // Format: + // `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}` + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Optional. User-provided display name of the AgentAnomalyDetectionScope. + string display_name = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Required. Customer-owned Cloud Logging bucket resource names attached to + // this scope. Specify exactly one bucket, in the same project as this scope. + // Format: `projects/{project}/locations/{location}/buckets/{bucket}`. + repeated string log_buckets = 5 [(google.api.field_behavior) = REQUIRED]; + + // Required. Customer-owned Cloud Observability datasets attached to this + // scope. Each value is the resource name of a dataset in an Observability + // bucket, such as the `Spans` dataset in the `_Trace` bucket. Specify + // exactly one dataset, in the same project as this scope. + // Format: + // `projects/{project}/locations/{location}/buckets/{bucket}/datasets/{dataset}`. + repeated string observability_buckets = 6 + [(google.api.field_behavior) = REQUIRED]; + + // Optional. When `true`, newly discovered agents that share log and + // observability buckets with this scope are automatically enrolled as + // `ACTIVE` MonitoredAgents, up to the project's monitored agent quota. When + // `false`, newly discovered agents are added as `DISABLED` MonitoredAgents, + // and you must enable them explicitly through MonitoredAgent operations. + bool auto_enroll = 7 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The lifecycle state of the scope. + State state = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Immutable. Specifies the customer-managed encryption key spec for + // a Scope. If set, this Scope and all sub-resources will be secured by this + // key. + // + // The key is immutable after the Scope is created and must be a multi-region + // (`us` or `eu`) key in the same region as the Scope. + EncryptionSpec encryption_spec = 9 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.field_behavior) = IMMUTABLE + ]; +} + +// Represents a monitored agent in a specific Location. +message MonitoredAgent { + option (google.api.resource) = { + type: "aiplatform.googleapis.com/MonitoredAgent" + pattern: "projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}" + plural: "monitoredAgents" + singular: "monitoredAgent" + }; + + // Represents the detailed status of the MonitoredAgent. + enum EnablementState { + // The default value. This value is used if the state is omitted. + ENABLEMENT_STATE_UNSPECIFIED = 0; + + // The agent is successfully enabled and active. + ACTIVE = 1; + + // The agent is in the process of being enabled. + ENABLING = 3; + + // The agent is disabled. + DISABLED = 6; + } + + // Identifier. The resource name of the MonitoredAgent. + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Optional. The display name of the MonitoredAgent. + string display_name = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Required. The configuration for the agent being monitored. + AgentResource agent_resource = 3 [(google.api.field_behavior) = REQUIRED]; + + // Output only. The current state of the agent's enablement. + EnablementState state = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. A brief message explaining the current state. + string status_message = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The time the MonitoredAgent was created. + google.protobuf.Timestamp create_time = 8 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The time the MonitoredAgent was last updated. + google.protobuf.Timestamp update_time = 9 + [(google.api.field_behavior) = OUTPUT_ONLY]; +} + +// Defines the identity of an agent being monitored. +message AgentResource { + // The runtime type of an agent, describing where the agent is hosted. This is + // orthogonal to the framework the agent is built with; see `AgentFramework`. + enum AgentType { + // The default value, used when the runtime type is unspecified. + AGENT_TYPE_UNSPECIFIED = 0; + + // The agent runs on the Gemini Enterprise Agent Platform Agent Runtime + // (Reasoning Engine). + REASONING_ENGINE = 1; + + // The agent runs as a Google Cloud Run service. + CLOUD_RUN_SERVICE = 2; + + // The agent runs as a workload on Google Kubernetes Engine. + GKE_WORKLOAD = 3; + + // The agent runs on a Compute Engine instance. + GCE_INSTANCE = 4; + + // The agent runs on a runtime that no other value represents, such as a + // self-hosted or on-premises environment. + AGENT_TYPE_OTHER = 5; + + // The agent runs on Amazon Web Services (AWS), such as on AWS Lambda. + AWS = 8; + + // The agent runs on Microsoft Azure, such as on Azure Kubernetes Service + // (AKS) or as a Microsoft Foundry hosted agent. + AZURE = 9; + } + + // The framework used to build an agent, such as the Agent Development Kit + // (ADK). This is orthogonal to the runtime the agent is hosted on; see + // `AgentType`. + enum AgentFramework { + // The default value, used when the framework is unspecified. + AGENT_FRAMEWORK_UNSPECIFIED = 0; + + // The agent is built with the Agent Development Kit (ADK). + ADK = 1; + } + + // Required. The runtime type of the agent. + AgentType agent_type = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The resource name or identifier of the agent to monitor. The + // format depends on `agent_type`: + // + // * `REASONING_ENGINE`: + // `//aiplatform.googleapis.com/projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}` + // * `CLOUD_RUN_SERVICE`: the full resource name of the Cloud Run service, + // `//run.googleapis.com/projects/{project}/locations/{location}/services/{service}` + // * `GKE_WORKLOAD`: the full resource name of the Google Kubernetes Engine + // cluster followed by the agent's OpenTelemetry `service.name`, + // `//container.googleapis.com/projects/{project}/locations/{location}/clusters/{cluster}/{service}`. + // For a zonal cluster, `zones/{zone}` replaces `locations/{location}`. + // Some names end in + // `k8s/namespaces/{namespace}/apps/deployments/{deployment}` instead of + // `{service}`. + // * `GCE_INSTANCE`: the full resource name of the Compute Engine instance + // followed by the agent's OpenTelemetry `service.name`, + // `//compute.googleapis.com/projects/{project}/zones/{zone}/instances/{instance}/{service}`, + // where `{instance}` is the numeric instance ID. + // * `AWS` and `AZURE`: an identifier built from the agent's OpenTelemetry + // resource attributes, usually `{platform}:{account}:{region}:{name}`. + // `{platform}` is the `cloud.platform` value. `{account}` is + // `cloud.account.id`, or the ID of the Google Cloud project that receives + // the telemetry if `cloud.account.id` isn't set. `{region}` is + // `cloud.region`. `{name}` is `faas.name`, or the Kubernetes cluster name + // followed by `/k8s/namespaces/{namespace}/apps/deployments/{deployment}` + // or `/{service}`. For example, + // `aws_lambda:123456789012:us-east-2:inventory-agent`. + // * `AGENT_TYPE_OTHER`: a stable identifier for the agent, such as the full + // resource name of its runtime or its OpenTelemetry `service.name`. + string agent = 2 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { type: "*" } + ]; + + // Output only. The region of the agent resource: a Google Cloud location + // (for example, `us-central1`), or for an `AWS` or `AZURE` agent, the region + // in that cloud (for example, `us-east-2`). + string location = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. The framework used to build the agent, orthogonal to the runtime + // `agent_type`. + AgentFramework agent_framework = 4 [(google.api.field_behavior) = OPTIONAL]; +} + +// Request message for +// [AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope]. +message CreateAgentAnomalyDetectionScopeRequest { + // Required. The resource name of the Location to create the + // AgentAnomalyDetectionScope in. Format: + // `projects/{project}/locations/{location}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "locations.googleapis.com/Location" + } + ]; + + // Required. The AgentAnomalyDetectionScope to create. + AgentAnomalyDetectionScope agent_anomaly_detection_scope = 2 + [(google.api.field_behavior) = REQUIRED]; + + // Required. The ID to use for the AgentAnomalyDetectionScope, which will + // become the final component of the AgentAnomalyDetectionScope's resource + // name. + // + // This value should be 1-63 characters, and valid characters + // are /[a-z]([a-z0-9-]{0,61}[a-z0-9])?/. + string agent_anomaly_detection_scope_id = 3 + [(google.api.field_behavior) = REQUIRED]; +} + +// Metadata information for +// [AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.CreateAgentAnomalyDetectionScope]. +message CreateAgentAnomalyDetectionScopeOperationMetadata { + // The operation generic information. + GenericOperationMetadata generic_metadata = 1; + + // The time the operation was completed. + google.protobuf.Timestamp done_time = 2; +} + +// Request message for +// [AgentAnomalyDetectionService.GetAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.GetAgentAnomalyDetectionScope]. +message GetAgentAnomalyDetectionScopeRequest { + // Required. The name of the AgentAnomalyDetectionScope resource. + // Format: + // `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "aiplatform.googleapis.com/AgentAnomalyDetectionScope" + } + ]; +} + +// Request message for +// [AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope]. +message DeleteAgentAnomalyDetectionScopeRequest { + // Required. The name of the AgentAnomalyDetectionScope resource to be + // deleted. Format: + // `projects/{project}/locations/{location}/agentAnomalyDetectionScopes/{agent_anomaly_detection_scope}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "aiplatform.googleapis.com/AgentAnomalyDetectionScope" + } + ]; +} + +// Metadata information for +// [AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DeleteAgentAnomalyDetectionScope]. +message DeleteAgentAnomalyDetectionScopeOperationMetadata { + // The operation generic information. + GenericOperationMetadata generic_metadata = 1; + + // The time the operation was completed. + google.protobuf.Timestamp done_time = 2; +} + +// Request message for +// [AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes]. +message ListAgentAnomalyDetectionScopesRequest { + // Required. The resource name of the Location to list the + // AgentAnomalyDetectionScopes from. Format: + // `projects/{project}/locations/{location}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "locations.googleapis.com/Location" + } + ]; + + // Optional. The standard list page size. The maximum value is 100; values + // above 100 will be coerced to 100. If unspecified, at most 10 + // AgentAnomalyDetectionScopes will be returned. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The standard list page token. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// Response message for +// [AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAgentAnomalyDetectionScopes]. +message ListAgentAnomalyDetectionScopesResponse { + // A list of AgentAnomalyDetectionScopes that matches the specified filter in + // the request. + repeated AgentAnomalyDetectionScope agent_anomaly_detection_scopes = 1; + + // A token, which can be sent as `page_token` to retrieve the next page. + // If this field is omitted, there are no subsequent pages. + string next_page_token = 2; +} + +// Request message for +// [AgentAnomalyDetectionService.GetMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.GetMonitoredAgent]. +message GetMonitoredAgentRequest { + // Required. The name of the MonitoredAgent resource. + // Format: + // `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "aiplatform.googleapis.com/MonitoredAgent" + } + ]; +} + +// Request message for +// [AgentAnomalyDetectionService.ListMonitoredAgents][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListMonitoredAgents]. +message ListMonitoredAgentsRequest { + // Required. The resource name of the Location to list the + // MonitoredAgents from. Format: + // `projects/{project}/locations/{location}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "locations.googleapis.com/Location" + } + ]; + + // Optional. The standard list page size. The maximum value is 100; values + // above 100 will be coerced to 100. If unspecified, at most 10 + // MonitoredAgents will be returned. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The standard list page token. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. An AIP-160 filter, currently restricted to a single equality + // predicate on `state`. The value must be the exact, case-sensitive name of a + // `MonitoredAgent.EnablementState` value: `ACTIVE`, `DISABLED`, `ENABLING`, + // or `ENABLEMENT_STATE_UNSPECIFIED`. A blank or absent filter returns every + // MonitoredAgent in the parent regardless of state; any other value returns + // `INVALID_ARGUMENT`. + // + // Example: + // + // ``` + // state = ACTIVE + // ``` + string filter = 4 [(google.api.field_behavior) = OPTIONAL]; +} + +// Response message for +// [AgentAnomalyDetectionService.ListMonitoredAgents][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListMonitoredAgents]. +message ListMonitoredAgentsResponse { + // A list of MonitoredAgents that matches the specified filter in + // the request. + repeated MonitoredAgent monitored_agents = 1; + + // A token, which can be sent as `page_token` to retrieve the next page. + // If this field is omitted, there are no subsequent pages. + string next_page_token = 2; + + // The total number of MonitoredAgents matching the request, after any + // `filter` is applied. + int32 total_size = 3; +} + +// Request message for +// [AgentAnomalyDetectionService.EnableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.EnableMonitoredAgent]. +message EnableMonitoredAgentRequest { + // Required. The name of the MonitoredAgent resource to be enabled. + // Format: + // `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "aiplatform.googleapis.com/MonitoredAgent" + } + ]; +} + +// Metadata information for +// [AgentAnomalyDetectionService.EnableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.EnableMonitoredAgent]. +message EnableMonitoredAgentOperationMetadata { + // The operation generic information. + GenericOperationMetadata generic_metadata = 1; +} + +// Request message for +// [AgentAnomalyDetectionService.DisableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DisableMonitoredAgent]. +message DisableMonitoredAgentRequest { + // Required. The name of the MonitoredAgent resource to be disabled. + // Format: + // `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "aiplatform.googleapis.com/MonitoredAgent" + } + ]; +} + +// Metadata information for +// [AgentAnomalyDetectionService.DisableMonitoredAgent][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.DisableMonitoredAgent]. +message DisableMonitoredAgentOperationMetadata { + // The operation generic information. + GenericOperationMetadata generic_metadata = 1; +} + +// Request message for +// [AgentAnomalyDetectionService.ClearTrainingData][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ClearTrainingData]. +message ClearTrainingDataRequest { + // Required. The MonitoredAgent whose trained model artifacts to purge. Use + // the + // `-` wildcard agent segment to purge every MonitoredAgent in the scope. + // Format: + // `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "aiplatform.googleapis.com/MonitoredAgent" + } + ]; +} + +// Response message for +// [AgentAnomalyDetectionService.ClearTrainingData][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ClearTrainingData]. +// Intentionally empty; the purge either succeeds or the operation carries an +// error. +message ClearTrainingDataResponse {} + +// Metadata information for +// [AgentAnomalyDetectionService.ClearTrainingData][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ClearTrainingData]. +message ClearTrainingDataOperationMetadata { + // The operation generic information. + GenericOperationMetadata generic_metadata = 1; + + // The time the operation was completed. + google.protobuf.Timestamp done_time = 2; +} + +// Contains the detailed assessment for an analyzed session. +message Assessment { + // The details of a detector's assessment within an analyzed session. + message DetectorFinding { + // The detector ID. + string detector_id = 1; + + // The detector display name. + string display_name = 2; + + // The severity of the finding. + Severity severity = 3; + + // The explanation of the finding. + string explanation = 4; + + // The probability that this finding is an anomaly, in the range [0.0, 1.0]. + double probability = 5; + + // The list of recommendations for this detector finding. + repeated string recommendations = 6; + } + + // The list of detector findings. + repeated DetectorFinding detector_findings = 1; +} + +// Represents an analyzed session for a monitored agent. +message AnalyzedSession { + option (google.api.resource) = { + type: "aiplatform.googleapis.com/AnalyzedSession" + pattern: "projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}" + plural: "analyzedSessions" + singular: "analyzedSession" + }; + + // Breaks down anomalies by severity. + message SeveritySummary { + // The list of detectors summaries for this severity level. + repeated string detector_ids = 1; + + // The severity level of the detector. + Severity severity_level = 2; + + // Output only. The number of distinct sessions whose maximum severity + // equals `severity_level`. Each session is counted in exactly one bucket + // (its highest severity). + // + // Scope depends on where this appears: a global count on + // `AggregateAnalyzedSessionsResponse.summary`, per-agent on + // `agent_aggregates` entries, and page-scoped on + // `ListAnalyzedSessionsResponse`. + int32 sessions_count = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + } + + // The analysis state of a session. + enum SessionState { + // The session state is unspecified. + SESSION_STATE_UNSPECIFIED = 0; + + // The session has not yet been analyzed. + SESSION_STATE_UNANALYZED = 1; + + // The session has been analyzed and no anomalies were flagged. + SESSION_STATE_NOT_FLAGGED = 2; + + // The session has been analyzed and at least one anomaly was flagged. + SESSION_STATE_FLAGGED = 3; + + // The session was analyzed by the LLM judge, which did not flag any + // anomalies. + SESSION_STATE_LLM_UNFLAGGED = 4; + } + + // Identifier. The resource name of the AnalyzedSession. + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Output only. The session ID. + string session_id = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The user ID. + string user_id = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The resource name or identifier of the agent that ran this + // session. Matches `AgentResource.agent` on the corresponding + // `MonitoredAgent`, so the format depends on that agent's + // `AgentResource.agent_type`. For the format of each agent type, see + // [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent]. + string agent_resource_name = 4 [ + (google.api.field_behavior) = OUTPUT_ONLY, + (google.api.resource_reference) = { type: "*" } + ]; + + // Output only. The creation time of the session. + google.protobuf.Timestamp create_time = 5 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The latest analyzed time of the session. + google.protobuf.Timestamp latest_analyzed_time = 6 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Overall security assessment. Populated only in FULL view. + Assessment assessment = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Map of the detectors that flagged this session, grouped by + // severity. The key is the string representation of `Severity`. Populated + // only for flagged sessions, in both views. In + // [AgentAnomalyDetectionService.ListAnalyzedSessions][google.cloud.aiplatform.v1.AgentAnomalyDetectionService.ListAnalyzedSessions] + // responses, the map holds only the session's highest severity. + map severities = 8 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The state of the session. + SessionState session_state = 9 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The human-readable display name of the MonitoredAgent that + // owns this session. May be empty when the session's agent is not enrolled + // as a MonitoredAgent; the `agent_resource_name` is always present and can + // be used as a fallback identifier. + string agent_display_name = 10 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The current enablement state of the MonitoredAgent that owns + // this session (for example, ACTIVE, DISABLED, or ENABLING). Defaults to + // ENABLEMENT_STATE_UNSPECIFIED when the agent is not enrolled or its state + // is unknown. + MonitoredAgent.EnablementState agent_state = 11 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The region of the agent that ran this session, in the same + // form as `AgentResource.location` (for example, `us-central1`). Empty when + // the agent is not enrolled or its location is unknown. + string location = 12 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The runtime that the agent which ran this session is hosted + // on (for example, `CLOUD_RUN_SERVICE`). + // + // `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service -- + // the agent is not enrolled as a `MonitoredAgent`, or was enrolled before its + // runtime was recorded. That is distinct from `AGENT_TYPE_OTHER`, which means + // the runtime is known and is not one of the other enumerated runtimes. + AgentResource.AgentType agent_type = 13 + [(google.api.field_behavior) = OUTPUT_ONLY]; +} + +// Request to list analyzed sessions. +message ListAnalyzedSessionsRequest { + // Required. The parent MonitoredAgent resource. + // Format: + // `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "aiplatform.googleapis.com/MonitoredAgent" + } + ]; + + // Optional. The maximum number of analyzed sessions to return. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A page token, received from a previous `ListAnalyzedSessions` + // call. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Filter expression restricting which AnalyzedSessions are + // returned. Supports a subset of AIP-160: a closed `detection_time` window + // (both bounds required), an equality on `severity`, an equality on + // `agent_type`, and an equality on `session_id`, joined by `AND`. Each + // clause is optional, may appear at most once, and may appear in any order. + // + // The `severity` value is the **canonical** `Severity` enum name -- + // `SEVERITY_CRITICAL`, `SEVERITY_HIGH`, `SEVERITY_MEDIUM` or `SEVERITY_LOW`. + // Short forms such as `"CRITICAL"` are rejected, as is + // `SEVERITY_UNSPECIFIED`. It matches sessions whose *maximum* severity equals + // that bucket: a session that fires at both LOW and CRITICAL matches + // `severity = "SEVERITY_CRITICAL"`, not `severity = "SEVERITY_LOW"`. + // + // The `agent_type` value is the canonical `AgentResource.AgentType` enum name + // -- `REASONING_ENGINE`, `CLOUD_RUN_SERVICE`, `GKE_WORKLOAD`, `GCE_INSTANCE`, + // `AWS`, `AZURE`, `AGENT_TYPE_OTHER` or `AGENT_TYPE_UNSPECIFIED` -- and + // matches sessions run by an agent on that runtime. + // + // Unlike `severity`, `agent_type` accepts its `UNSPECIFIED` value. The two + // are not analogous: a session always has a computed severity bucket, so + // `SEVERITY_UNSPECIFIED` is never returned and filtering on it could only + // match nothing. `AGENT_TYPE_UNSPECIFIED` *is* returned -- it is what + // `AnalyzedSession.agent_type` reports for an agent whose runtime was never + // recorded -- so it must remain filterable. + // + // The `session_id` value is a case-sensitive exact match (no substring or + // prefix matching) on `AnalyzedSession.session_id`. Unlike `severity` and + // `agent_type` it is not a closed enum, so any non-empty value is accepted; + // an empty value (`session_id = ""`) is rejected rather than treated as "no + // filter". + // + // Example (time window, severity and runtime): + // + // ``` + // detection_time >= "2024-01-01T00:00:00Z" AND detection_time <= + // "2024-01-08T00:00:00Z" AND severity = "SEVERITY_CRITICAL" AND agent_type = + // "CLOUD_RUN_SERVICE" + // ``` + // + // If empty, results are restricted to the last 7 days with no severity, + // runtime, or session restriction. Other fields, additional operators, set + // membership (`IN`), and boolean combinations (`OR`, `NOT`, parentheses) are + // not yet supported. + string filter = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Resource view to control which fields are returned. + AnalyzedSessionView view = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Comma-separated list of fields to sort by, following AIP-132 + // syntax. The default sort direction is ascending; append " desc" to a + // field to sort descending. + // + // Supported fields (any other field yields INVALID_ARGUMENT): + // + // * `latest_detection_time` - the session's most-recent flagged detection + // time. `latest_detection_time desc` puts the newest sessions first. + // * `max_severity_rank` - the session's bucketed maximum severity, ranked + // LOW=1 < MEDIUM=2 < HIGH=3 < CRITICAL=4. `max_severity_rank desc` puts + // the most-severe sessions first. + // * `agent_display_name` - the MonitoredAgent's display name. Sorted as a + // STRING (case-sensitive, code-point order). + // + // If empty, defaults to `latest_detection_time desc`. Multi-field sort + // (for example, `max_severity_rank desc, latest_detection_time desc`) is + // supported. + // + // The `order_by` value MUST match the value used on the call that minted any + // supplied `page_token` (AIP-158). Mismatches yield INVALID_ARGUMENT. + string order_by = 6 [(google.api.field_behavior) = OPTIONAL]; +} + +// Response to list analyzed sessions. +message ListAnalyzedSessionsResponse { + // The view summary. + message ViewSummary { + // The list of severity summaries for the analyzed sessions. + // The key is the string representation of Severity enum: + // "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH", + // "SEVERITY_MEDIUM", "SEVERITY_LOW". + map severities = 1; + + // Number of anomalous sessions. + int32 anomalous_sessions_count = 2; + + // Total number of sessions. + int32 total_sessions_count = 3; + + // Output only. The number of distinct agents in the request scope with at + // least one anomalous session in the time window. On + // `AggregateAnalyzedSessionsResponse.summary` this is a global count; it + // is not populated on `ListAnalyzedSessionsResponse.summary`. + int32 anomalous_agents_count = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The number of distinct sessions in the time window that were + // scanned by the LLM judge. + int32 llm_scanned_sessions_count = 5 + [(google.api.field_behavior) = OUTPUT_ONLY]; + } + + // The list of analyzed sessions. + repeated AnalyzedSession analyzed_sessions = 1; + + // A token to retrieve the next page of results. + string next_page_token = 2; + + // Summary statistics computed across the sessions on the current page only. + // For statistics across the entire result set, use AggregateAnalyzedSessions. + ViewSummary summary = 3; +} + +// Request to get the details of a specific analyzed session. +message GetAnalyzedSessionRequest { + // Required. The name of the AnalyzedSession resource. + // Format: + // `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "aiplatform.googleapis.com/AnalyzedSession" + } + ]; + + // Optional. Resource view to control which fields are returned. + AnalyzedSessionView view = 2 [(google.api.field_behavior) = OPTIONAL]; +} + +// Represents an analyzed invocation for a monitored agent's session. +message AnalyzedInvocation { + option (google.api.resource) = { + type: "aiplatform.googleapis.com/AnalyzedInvocation" + pattern: "projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}" + plural: "analyzedInvocations" + singular: "analyzedInvocation" + }; + + // State of the invocation. + enum InvocationState { + // Unspecified state. + INVOCATION_STATE_UNSPECIFIED = 0; + + // The invocation is anomalous. + INVOCATION_STATE_ANOMALOUS = 1; + + // The invocation is not anomalous. + INVOCATION_STATE_NOT_ANOMALOUS = 2; + } + + // Identifier. The resource name of the AnalyzedInvocation. + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Output only. The invocation ID. + string invocation_id = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The assessment of the invocation. + Assessment assessment = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The state of the invocation. + InvocationState invocation_state = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; +} + +// Request to get the details of a specific analyzed invocation. +message GetAnalyzedInvocationRequest { + // Required. The name of the AnalyzedInvocation resource. + // Format: + // `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}/analyzedInvocations/{analyzed_invocation}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "aiplatform.googleapis.com/AnalyzedInvocation" + } + ]; +} + +// Request to list analyzed invocations. +message ListAnalyzedInvocationsRequest { + // Required. The parent AnalyzedSession resource. + // Format: + // `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}/analyzedSessions/{analyzed_session}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "aiplatform.googleapis.com/AnalyzedSession" + } + ]; + + // Optional. The maximum number of analyzed invocations to return. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A page token, received from a previous `ListAnalyzedInvocations` + // call. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// Response to list analyzed invocations. +message ListAnalyzedInvocationsResponse { + // The list of analyzed invocations. + repeated AnalyzedInvocation analyzed_invocations = 1; + + // A token to retrieve the next page of results. + string next_page_token = 2; +} + +// Request to aggregate AnalyzedSessions across one or more MonitoredAgents. +// Use the `-` wildcard in the monitored_agent segment of the parent to +// aggregate across all MonitoredAgents in the location. +message AggregateAnalyzedSessionsRequest { + // Required. The parent MonitoredAgent resource. Use the `-` wildcard + // for the monitored_agent segment to aggregate across multiple agents in the + // location. + // Format: + // `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "aiplatform.googleapis.com/MonitoredAgent" + } + ]; + + // Optional. Filter expression restricting which AnalyzedSessions are included + // in the aggregation. Supports a subset of the + // `ListAnalyzedSessionsRequest.filter` grammar: a closed `detection_time` + // window with both bounds required. The `severity` clause is not supported + // here. If empty, the aggregation covers the last 3 days. + // + // Example: + // + // ``` + // detection_time >= "2024-01-01T00:00:00Z" AND detection_time <= + // "2024-01-08T00:00:00Z" + // ``` + string filter = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The standard list page size. The maximum value is 100; values + // above 100 will be coerced to 100. If unspecified, at most 10 + // MonitoredAgents will be returned. + int32 page_size = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The standard list page token. + string page_token = 4 [(google.api.field_behavior) = OPTIONAL]; +} + +// Contains aggregated AnalyzedSession statistics, grouped by MonitoredAgent. +message AggregateAnalyzedSessionsResponse { + // Contains aggregated statistics for one MonitoredAgent. + message AgentAggregate { + // The MonitoredAgent resource name. + // Format: + // `projects/{project}/locations/{location}/monitoredAgents/{monitored_agent}` + string monitored_agent = 1; + + // The resource name or identifier of the agent. Matches + // `AgentResource.agent` on the corresponding `MonitoredAgent`, so the + // format depends on that agent's `AgentResource.agent_type`. For the + // format of each agent type, see + // [AgentResource.agent][google.cloud.aiplatform.v1.AgentResource.agent]. + string agent_resource_name = 2 + [(google.api.resource_reference) = { type: "*" }]; + + // Output only. The human-readable display name of the MonitoredAgent. + string agent_display_name = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The enablement state of the MonitoredAgent (for example, + // ACTIVE, DISABLED, or ENABLING). + MonitoredAgent.EnablementState agent_status = 8 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The region of the agent, in the same form as + // `AgentResource.location` (for example, `us-central1`). Empty when the + // agent is not enrolled or its location is unknown. + string location = 9 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The runtime the agent is hosted on (for example, + // `CLOUD_RUN_SERVICE`). + // + // `AGENT_TYPE_UNSPECIFIED` means the runtime is unknown to this service, + // which is distinct from `AGENT_TYPE_OTHER` (known, and not one of the + // other enumerated runtimes). + AgentResource.AgentType agent_type = 10 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // The number of analyzed sessions for this agent matched by the request. + int32 total_sessions_count = 3; + + // The number of anomalous (SESSION_STATE_FLAGGED) sessions for this agent. + int32 anomalous_sessions_count = 4; + + // The latest session update_time observed for this agent. + google.protobuf.Timestamp latest_session_time = 5; + + // Map of severity level (string representation of Severity) to detector + // summaries aggregated across all sessions for this agent. + // The key is the string representation of Severity enum: + // "SEVERITY_UNSPECIFIED", "SEVERITY_CRITICAL", "SEVERITY_HIGH", + // "SEVERITY_MEDIUM", "SEVERITY_LOW". + map severities = 6; + } + + // Aggregated statistics — exactly one entry per unique MonitoredAgent + // matched by the request. + repeated AgentAggregate agent_aggregates = 1; + + // Overall summary across every MonitoredAgent included in the response. + ListAnalyzedSessionsResponse.ViewSummary summary = 2; + + // A token, which can be sent as `page_token` to retrieve the next page. + // If this field is omitted, there are no subsequent pages. + string next_page_token = 3; +} diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/proto/google/cloud/aiplatform/v1/reasoning_engine.proto b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/proto/google/cloud/aiplatform/v1/reasoning_engine.proto index 82a2cb13df28..276e8c0f3b19 100644 --- a/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/proto/google/cloud/aiplatform/v1/reasoning_engine.proto +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1/src/main/proto/google/cloud/aiplatform/v1/reasoning_engine.proto @@ -64,11 +64,33 @@ message ReasoningEngineSpec { // UpdateReasoningEngine API. repeated EnvVar env = 1 [(google.api.field_behavior) = OPTIONAL]; - // Optional. Environment variables where the value is a secret in Cloud - // Secret Manager. - // To use this feature, add 'Secret Manager Secret Accessor' role - // (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine - // Service Agent. + // Optional. Environment variables where the value is a secret in Secret + // Manager. Secrets must be global secrets in the same project as the + // Reasoning Engine. + // + // At startup (and during deployment validation for service-account-based + // deployments), the Reasoning Engine accesses the referenced secrets using + // its configured runtime identity. Grant the Secret Manager Secret Accessor + // role (`roles/secretmanager.secretAccessor`) on the specific secret to an + // isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a + // dedicated custom `service_account`. When using `AGENT_IDENTITY`, create + // the Reasoning Engine first without `secret_env`, grant access to its + // provisioned agent identity (prepend `principal://` to the + // `effective_identity` value returned by the SDK/CLI, e.g., + // `principal://agents.global...`), and then update the Reasoning Engine to + // add `secret_env`. + // + // WARNING: Avoid granting secret access to the default Vertex AI Reasoning + // Engine Service Agent + // (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`). + // That service agent is shared across all Reasoning Engines in the project + // that do not specify an isolated identity or custom service account, so + // any principal with permission to deploy or update agents in the project + // can access secrets granted to it (including without `secret_env`, by + // calling Secret Manager directly from agent code). Note also that any + // principal with `aiplatform.reasoningEngines.update` permission on an + // `AGENT_IDENTITY` engine can run code as that agent's identity; restrict + // update permissions accordingly. repeated SecretEnvVar secret_env = 2 [(google.api.field_behavior) = OPTIONAL]; @@ -231,15 +253,26 @@ message ReasoningEngineSpec { enum IdentityType { // Default value. Use a custom service account if the `service_account` // field is set, otherwise use the default Vertex AI Reasoning Engine - // Service Agent in the project. Same behavior as SERVICE_ACCOUNT. + // Service Agent in the project. Same behavior as `SERVICE_ACCOUNT`. + // + // WARNING: The default service agent is shared across all Reasoning + // Engines in the project that do not specify an isolated identity or + // custom service account; see `identity_type` for security guidance. IDENTITY_TYPE_UNSPECIFIED = 0; // Use a custom service account if the `service_account` field is set, // otherwise use the default Vertex AI Reasoning Engine Service Agent in the // project. + // + // WARNING: The default service agent is shared across all Reasoning + // Engines in the project that do not specify an isolated identity or + // custom service account; see `identity_type` for security guidance. SERVICE_ACCOUNT = 2; // Use Agent Identity. The `service_account` field must not be set. + // Restrict `aiplatform.reasoningEngines.update` permissions on the engine + // because any principal permitted to update it can run code as its + // identity. AGENT_IDENTITY = 3; } @@ -276,8 +309,19 @@ message ReasoningEngineSpec { // Optional. The service account that the Reasoning Engine artifact runs as. // It should have "roles/storage.objectViewer" for reading the user project's // Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - // not specified, the Vertex AI Reasoning Engine Service Agent in the project - // will be used. + // not specified and `identity_type` is not `AGENT_IDENTITY`, the default + // Vertex AI Reasoning Engine Service Agent in the project will be used. + // + // WARNING: The default Vertex AI Reasoning Engine Service Agent + // (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + // is shared across all Reasoning Engines in the project that do not specify + // an isolated identity or custom service account. Any permissions or secrets + // granted to it can be accessed by any principal permitted to deploy or + // update agents in the project (even without using `secret_env`, by calling + // APIs directly from agent code). For sensitive resources such as Secret + // Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + // `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + // custom `service_account`. optional string service_account = 1 [(google.api.field_behavior) = OPTIONAL]; // Optional. User provided package spec of the ReasoningEngine. @@ -305,6 +349,17 @@ message ReasoningEngineSpec { // specified, the `service_account` field will be used if set, otherwise the // default Vertex AI Reasoning Engine Service Agent in the project will be // used. + // + // WARNING: The default Vertex AI Reasoning Engine Service Agent + // (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + // is shared across all Reasoning Engines in the project that do not specify + // an isolated identity or custom service account. Any permissions or secrets + // granted to it can be accessed by any principal permitted to deploy or + // update agents in the project (even without using `secret_env`, by calling + // APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + // `aiplatform.reasoningEngines.update` permissions on the engine) or a + // dedicated custom `service_account` when granting access to sensitive + // resources such as Secret Manager secrets. IdentityType identity_type = 12 [(google.api.field_behavior) = OPTIONAL]; // Optional. Configuration for building container image. diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ReasoningEngineSpec.java b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ReasoningEngineSpec.java index fdb6da492da2..180834e1fb0f 100644 --- a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ReasoningEngineSpec.java +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ReasoningEngineSpec.java @@ -89,7 +89,11 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { *
      * Default value. Use a custom service account if the `service_account`
      * field is set, otherwise use the default Vertex AI Reasoning Engine
-     * Service Agent in the project. Same behavior as SERVICE_ACCOUNT.
+     * Service Agent in the project. Same behavior as `SERVICE_ACCOUNT`.
+     *
+     * WARNING: The default service agent is shared across all Reasoning
+     * Engines in the project that do not specify an isolated identity or
+     * custom service account; see `identity_type` for security guidance.
      * 
* * IDENTITY_TYPE_UNSPECIFIED = 0; @@ -102,6 +106,10 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { * Use a custom service account if the `service_account` field is set, * otherwise use the default Vertex AI Reasoning Engine Service Agent in the * project. + * + * WARNING: The default service agent is shared across all Reasoning + * Engines in the project that do not specify an isolated identity or + * custom service account; see `identity_type` for security guidance. * * * SERVICE_ACCOUNT = 2; @@ -112,6 +120,9 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { * *
      * Use Agent Identity. The `service_account` field must not be set.
+     * Restrict `aiplatform.reasoningEngines.update` permissions on the engine
+     * because any principal permitted to update it can run code as its
+     * identity.
      * 
* * AGENT_IDENTITY = 3; @@ -136,7 +147,11 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { *
      * Default value. Use a custom service account if the `service_account`
      * field is set, otherwise use the default Vertex AI Reasoning Engine
-     * Service Agent in the project. Same behavior as SERVICE_ACCOUNT.
+     * Service Agent in the project. Same behavior as `SERVICE_ACCOUNT`.
+     *
+     * WARNING: The default service agent is shared across all Reasoning
+     * Engines in the project that do not specify an isolated identity or
+     * custom service account; see `identity_type` for security guidance.
      * 
* * IDENTITY_TYPE_UNSPECIFIED = 0; @@ -150,6 +165,10 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { * Use a custom service account if the `service_account` field is set, * otherwise use the default Vertex AI Reasoning Engine Service Agent in the * project. + * + * WARNING: The default service agent is shared across all Reasoning + * Engines in the project that do not specify an isolated identity or + * custom service account; see `identity_type` for security guidance. * * * SERVICE_ACCOUNT = 2; @@ -161,6 +180,9 @@ public enum IdentityType implements com.google.protobuf.ProtocolMessageEnum { * *
      * Use Agent Identity. The `service_account` field must not be set.
+     * Restrict `aiplatform.reasoningEngines.update` permissions on the engine
+     * because any principal permitted to update it can run code as its
+     * identity.
      * 
* * AGENT_IDENTITY = 3; @@ -1621,11 +1643,33 @@ public interface DeploymentSpecOrBuilder * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -1638,11 +1682,33 @@ public interface DeploymentSpecOrBuilder * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -1655,11 +1721,33 @@ public interface DeploymentSpecOrBuilder * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -1672,11 +1760,33 @@ public interface DeploymentSpecOrBuilder * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -1690,11 +1800,33 @@ public interface DeploymentSpecOrBuilder * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -2119,11 +2251,33 @@ public com.google.cloud.aiplatform.v1beta1.EnvVarOrBuilder getEnvOrBuilder(int i * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -2139,11 +2293,33 @@ public java.util.List getSecre * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -2160,11 +2336,33 @@ public java.util.List getSecre * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -2180,11 +2378,33 @@ public int getSecretEnvCount() { * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -2200,11 +2420,33 @@ public com.google.cloud.aiplatform.v1beta1.SecretEnvVar getSecretEnv(int index) * * *
-     * Optional. Environment variables where the value is a secret in Cloud
-     * Secret Manager.
-     * To use this feature, add 'Secret Manager Secret Accessor' role
-     * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-     * Service Agent.
+     * Optional. Environment variables where the value is a secret in Secret
+     * Manager. Secrets must be global secrets in the same project as the
+     * Reasoning Engine.
+     *
+     * At startup (and during deployment validation for service-account-based
+     * deployments), the Reasoning Engine accesses the referenced secrets using
+     * its configured runtime identity. Grant the Secret Manager Secret Accessor
+     * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+     * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+     * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+     * the Reasoning Engine first without `secret_env`, grant access to its
+     * provisioned agent identity (prepend `principal://` to the
+     * `effective_identity` value returned by the SDK/CLI, e.g.,
+     * `principal://agents.global...`), and then update the Reasoning Engine to
+     * add `secret_env`.
+     *
+     * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+     * Engine Service Agent
+     * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+     * That service agent is shared across all Reasoning Engines in the project
+     * that do not specify an isolated identity or custom service account, so
+     * any principal with permission to deploy or update agents in the project
+     * can access secrets granted to it (including without `secret_env`, by
+     * calling Secret Manager directly from agent code). Note also that any
+     * principal with `aiplatform.reasoningEngines.update` permission on an
+     * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+     * update permissions accordingly.
      * 
* * @@ -3634,11 +3876,33 @@ private void ensureSecretEnvIsMutable() { * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3657,11 +3921,33 @@ public java.util.List getSecre * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3680,11 +3966,33 @@ public int getSecretEnvCount() { * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3703,11 +4011,33 @@ public com.google.cloud.aiplatform.v1beta1.SecretEnvVar getSecretEnv(int index) * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3733,11 +4063,33 @@ public Builder setSecretEnv( * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3760,11 +4112,33 @@ public Builder setSecretEnv( * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3789,11 +4163,33 @@ public Builder addSecretEnv(com.google.cloud.aiplatform.v1beta1.SecretEnvVar val * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3819,11 +4215,33 @@ public Builder addSecretEnv( * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3846,11 +4264,33 @@ public Builder addSecretEnv( * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3873,11 +4313,33 @@ public Builder addSecretEnv( * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3900,11 +4362,33 @@ public Builder addAllSecretEnv( * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3926,11 +4410,33 @@ public Builder clearSecretEnv() { * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3952,11 +4458,33 @@ public Builder removeSecretEnv(int index) { * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3972,11 +4500,33 @@ public com.google.cloud.aiplatform.v1beta1.SecretEnvVar.Builder getSecretEnvBuil * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -3996,11 +4546,33 @@ public com.google.cloud.aiplatform.v1beta1.SecretEnvVarOrBuilder getSecretEnvOrB * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -4020,11 +4592,33 @@ public com.google.cloud.aiplatform.v1beta1.SecretEnvVarOrBuilder getSecretEnvOrB * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -4040,11 +4634,33 @@ public com.google.cloud.aiplatform.v1beta1.SecretEnvVar.Builder addSecretEnvBuil * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -4062,11 +4678,33 @@ public com.google.cloud.aiplatform.v1beta1.SecretEnvVar.Builder addSecretEnvBuil * * *
-       * Optional. Environment variables where the value is a secret in Cloud
-       * Secret Manager.
-       * To use this feature, add 'Secret Manager Secret Accessor' role
-       * (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
-       * Service Agent.
+       * Optional. Environment variables where the value is a secret in Secret
+       * Manager. Secrets must be global secrets in the same project as the
+       * Reasoning Engine.
+       *
+       * At startup (and during deployment validation for service-account-based
+       * deployments), the Reasoning Engine accesses the referenced secrets using
+       * its configured runtime identity. Grant the Secret Manager Secret Accessor
+       * role (`roles/secretmanager.secretAccessor`) on the specific secret to an
+       * isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a
+       * dedicated custom `service_account`. When using `AGENT_IDENTITY`, create
+       * the Reasoning Engine first without `secret_env`, grant access to its
+       * provisioned agent identity (prepend `principal://` to the
+       * `effective_identity` value returned by the SDK/CLI, e.g.,
+       * `principal://agents.global...`), and then update the Reasoning Engine to
+       * add `secret_env`.
+       *
+       * WARNING: Avoid granting secret access to the default Vertex AI Reasoning
+       * Engine Service Agent
+       * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`).
+       * That service agent is shared across all Reasoning Engines in the project
+       * that do not specify an isolated identity or custom service account, so
+       * any principal with permission to deploy or update agents in the project
+       * can access secrets granted to it (including without `secret_env`, by
+       * calling Secret Manager directly from agent code). Note also that any
+       * principal with `aiplatform.reasoningEngines.update` permission on an
+       * `AGENT_IDENTITY` engine can run code as that agent's identity; restrict
+       * update permissions accordingly.
        * 
* * @@ -15315,8 +15953,19 @@ public com.google.cloud.aiplatform.v1beta1.ReasoningEngineSpec.ContainerSpec get * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -15335,8 +15984,19 @@ public boolean hasServiceAccount() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -15363,8 +16023,19 @@ public java.lang.String getServiceAccount() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -15681,6 +16352,17 @@ public com.google.protobuf.ByteString getAgentFrameworkBytes() { * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -15702,6 +16384,17 @@ public int getIdentityTypeValue() { * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -16955,8 +17648,19 @@ public Builder clearContainerSpec() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -16974,8 +17678,19 @@ public boolean hasServiceAccount() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -17001,8 +17716,19 @@ public java.lang.String getServiceAccount() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -17028,8 +17754,19 @@ public com.google.protobuf.ByteString getServiceAccountBytes() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -17054,8 +17791,19 @@ public Builder setServiceAccount(java.lang.String value) { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -17076,8 +17824,19 @@ public Builder clearServiceAccount() { * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -18134,6 +18893,17 @@ public Builder setAgentFrameworkBytes(com.google.protobuf.ByteString value) { * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -18155,6 +18925,17 @@ public int getIdentityTypeValue() { * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -18179,6 +18960,17 @@ public Builder setIdentityTypeValue(int value) { * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -18205,6 +18997,17 @@ public com.google.cloud.aiplatform.v1beta1.ReasoningEngineSpec.IdentityType getI * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -18233,6 +19036,17 @@ public Builder setIdentityType( * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ReasoningEngineSpecOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ReasoningEngineSpecOrBuilder.java index 6a212319b85e..50d62e1f3a7d 100644 --- a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ReasoningEngineSpecOrBuilder.java +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ReasoningEngineSpecOrBuilder.java @@ -118,8 +118,19 @@ public interface ReasoningEngineSpecOrBuilder * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -135,8 +146,19 @@ public interface ReasoningEngineSpecOrBuilder * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -152,8 +174,19 @@ public interface ReasoningEngineSpecOrBuilder * Optional. The service account that the Reasoning Engine artifact runs as. * It should have "roles/storage.objectViewer" for reading the user project's * Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - * not specified, the Vertex AI Reasoning Engine Service Agent in the project - * will be used. + * not specified and `identity_type` is not `AGENT_IDENTITY`, the default + * Vertex AI Reasoning Engine Service Agent in the project will be used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). For sensitive resources such as Secret + * Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + * `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + * custom `service_account`. * * * optional string service_account = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -373,6 +406,17 @@ public interface ReasoningEngineSpecOrBuilder * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * @@ -391,6 +435,17 @@ public interface ReasoningEngineSpecOrBuilder * specified, the `service_account` field will be used if set, otherwise the * default Vertex AI Reasoning Engine Service Agent in the project will be * used. + * + * WARNING: The default Vertex AI Reasoning Engine Service Agent + * (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + * is shared across all Reasoning Engines in the project that do not specify + * an isolated identity or custom service account. Any permissions or secrets + * granted to it can be accessed by any principal permitted to deploy or + * update agents in the project (even without using `secret_env`, by calling + * APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + * `aiplatform.reasoningEngines.update` permissions on the engine) or a + * dedicated custom `service_account` when granting access to sensitive + * resources such as Secret Manager secrets. * * * diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/proto/google/cloud/aiplatform/v1beta1/reasoning_engine.proto b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/proto/google/cloud/aiplatform/v1beta1/reasoning_engine.proto index 01222f8473f8..4442b1b3869f 100644 --- a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/proto/google/cloud/aiplatform/v1beta1/reasoning_engine.proto +++ b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/proto/google/cloud/aiplatform/v1beta1/reasoning_engine.proto @@ -65,11 +65,33 @@ message ReasoningEngineSpec { // UpdateReasoningEngine API. repeated EnvVar env = 1 [(google.api.field_behavior) = OPTIONAL]; - // Optional. Environment variables where the value is a secret in Cloud - // Secret Manager. - // To use this feature, add 'Secret Manager Secret Accessor' role - // (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine - // Service Agent. + // Optional. Environment variables where the value is a secret in Secret + // Manager. Secrets must be global secrets in the same project as the + // Reasoning Engine. + // + // At startup (and during deployment validation for service-account-based + // deployments), the Reasoning Engine accesses the referenced secrets using + // its configured runtime identity. Grant the Secret Manager Secret Accessor + // role (`roles/secretmanager.secretAccessor`) on the specific secret to an + // isolated per-agent identity (`identity_type = AGENT_IDENTITY`) or a + // dedicated custom `service_account`. When using `AGENT_IDENTITY`, create + // the Reasoning Engine first without `secret_env`, grant access to its + // provisioned agent identity (prepend `principal://` to the + // `effective_identity` value returned by the SDK/CLI, e.g., + // `principal://agents.global...`), and then update the Reasoning Engine to + // add `secret_env`. + // + // WARNING: Avoid granting secret access to the default Vertex AI Reasoning + // Engine Service Agent + // (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`). + // That service agent is shared across all Reasoning Engines in the project + // that do not specify an isolated identity or custom service account, so + // any principal with permission to deploy or update agents in the project + // can access secrets granted to it (including without `secret_env`, by + // calling Secret Manager directly from agent code). Note also that any + // principal with `aiplatform.reasoningEngines.update` permission on an + // `AGENT_IDENTITY` engine can run code as that agent's identity; restrict + // update permissions accordingly. repeated SecretEnvVar secret_env = 2 [(google.api.field_behavior) = OPTIONAL]; @@ -233,15 +255,26 @@ message ReasoningEngineSpec { enum IdentityType { // Default value. Use a custom service account if the `service_account` // field is set, otherwise use the default Vertex AI Reasoning Engine - // Service Agent in the project. Same behavior as SERVICE_ACCOUNT. + // Service Agent in the project. Same behavior as `SERVICE_ACCOUNT`. + // + // WARNING: The default service agent is shared across all Reasoning + // Engines in the project that do not specify an isolated identity or + // custom service account; see `identity_type` for security guidance. IDENTITY_TYPE_UNSPECIFIED = 0; // Use a custom service account if the `service_account` field is set, // otherwise use the default Vertex AI Reasoning Engine Service Agent in the // project. + // + // WARNING: The default service agent is shared across all Reasoning + // Engines in the project that do not specify an isolated identity or + // custom service account; see `identity_type` for security guidance. SERVICE_ACCOUNT = 2; // Use Agent Identity. The `service_account` field must not be set. + // Restrict `aiplatform.reasoningEngines.update` permissions on the engine + // because any principal permitted to update it can run code as its + // identity. AGENT_IDENTITY = 3; } @@ -278,8 +311,19 @@ message ReasoningEngineSpec { // Optional. The service account that the Reasoning Engine artifact runs as. // It should have "roles/storage.objectViewer" for reading the user project's // Cloud Storage and "roles/aiplatform.user" for using Vertex extensions. If - // not specified, the Vertex AI Reasoning Engine Service Agent in the project - // will be used. + // not specified and `identity_type` is not `AGENT_IDENTITY`, the default + // Vertex AI Reasoning Engine Service Agent in the project will be used. + // + // WARNING: The default Vertex AI Reasoning Engine Service Agent + // (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + // is shared across all Reasoning Engines in the project that do not specify + // an isolated identity or custom service account. Any permissions or secrets + // granted to it can be accessed by any principal permitted to deploy or + // update agents in the project (even without using `secret_env`, by calling + // APIs directly from agent code). For sensitive resources such as Secret + // Manager secrets, use `identity_type = AGENT_IDENTITY` (restricting + // `aiplatform.reasoningEngines.update` access to that engine) or a dedicated + // custom `service_account`. optional string service_account = 1 [(google.api.field_behavior) = OPTIONAL]; // Optional. User provided package spec of the ReasoningEngine. @@ -307,6 +351,17 @@ message ReasoningEngineSpec { // specified, the `service_account` field will be used if set, otherwise the // default Vertex AI Reasoning Engine Service Agent in the project will be // used. + // + // WARNING: The default Vertex AI Reasoning Engine Service Agent + // (`service-{project_number}@gcp-sa-aiplatform-re.iam.gserviceaccount.com`) + // is shared across all Reasoning Engines in the project that do not specify + // an isolated identity or custom service account. Any permissions or secrets + // granted to it can be accessed by any principal permitted to deploy or + // update agents in the project (even without using `secret_env`, by calling + // APIs directly from agent code). Prefer `AGENT_IDENTITY` (and restrict + // `aiplatform.reasoningEngines.update` permissions on the engine) or a + // dedicated custom `service_account` when granting access to sensitive + // resources such as Secret Manager secrets. IdentityType identity_type = 12 [(google.api.field_behavior) = OPTIONAL]; // Optional. Configuration for building container image. diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/AsyncAggregateAnalyzedSessions.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/AsyncAggregateAnalyzedSessions.java new file mode 100644 index 000000000000..54794bb9a86e --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/AsyncAggregateAnalyzedSessions.java @@ -0,0 +1,59 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_AggregateAnalyzedSessions_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class AsyncAggregateAnalyzedSessions { + + public static void main(String[] args) throws Exception { + asyncAggregateAnalyzedSessions(); + } + + public static void asyncAggregateAnalyzedSessions() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + AggregateAnalyzedSessionsRequest request = + AggregateAnalyzedSessionsRequest.newBuilder() + .setParent( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient + .aggregateAnalyzedSessionsPagedCallable() + .futureCall(request); + // Do something. + for (AggregateAnalyzedSessionsResponse.AgentAggregate element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_AggregateAnalyzedSessions_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/AsyncAggregateAnalyzedSessionsPaged.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/AsyncAggregateAnalyzedSessionsPaged.java new file mode 100644 index 000000000000..9cbbb7043c52 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/AsyncAggregateAnalyzedSessionsPaged.java @@ -0,0 +1,65 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_AggregateAnalyzedSessions_Paged_async] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; +import com.google.common.base.Strings; + +public class AsyncAggregateAnalyzedSessionsPaged { + + public static void main(String[] args) throws Exception { + asyncAggregateAnalyzedSessionsPaged(); + } + + public static void asyncAggregateAnalyzedSessionsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + AggregateAnalyzedSessionsRequest request = + AggregateAnalyzedSessionsRequest.newBuilder() + .setParent( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + AggregateAnalyzedSessionsResponse response = + agentAnomalyDetectionServiceClient.aggregateAnalyzedSessionsCallable().call(request); + for (AggregateAnalyzedSessionsResponse.AgentAggregate element : + response.getAgentAggregatesList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_AggregateAnalyzedSessions_Paged_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/SyncAggregateAnalyzedSessions.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/SyncAggregateAnalyzedSessions.java new file mode 100644 index 000000000000..09f516cf6eab --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/SyncAggregateAnalyzedSessions.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_AggregateAnalyzedSessions_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncAggregateAnalyzedSessions { + + public static void main(String[] args) throws Exception { + syncAggregateAnalyzedSessions(); + } + + public static void syncAggregateAnalyzedSessions() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + AggregateAnalyzedSessionsRequest request = + AggregateAnalyzedSessionsRequest.newBuilder() + .setParent( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (AggregateAnalyzedSessionsResponse.AgentAggregate element : + agentAnomalyDetectionServiceClient.aggregateAnalyzedSessions(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_AggregateAnalyzedSessions_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/SyncAggregateAnalyzedSessionsMonitoredagentname.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/SyncAggregateAnalyzedSessionsMonitoredagentname.java new file mode 100644 index 000000000000..18c70a552856 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/SyncAggregateAnalyzedSessionsMonitoredagentname.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_AggregateAnalyzedSessions_Monitoredagentname_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncAggregateAnalyzedSessionsMonitoredagentname { + + public static void main(String[] args) throws Exception { + syncAggregateAnalyzedSessionsMonitoredagentname(); + } + + public static void syncAggregateAnalyzedSessionsMonitoredagentname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + MonitoredAgentName parent = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + for (AggregateAnalyzedSessionsResponse.AgentAggregate element : + agentAnomalyDetectionServiceClient.aggregateAnalyzedSessions(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_AggregateAnalyzedSessions_Monitoredagentname_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/SyncAggregateAnalyzedSessionsString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/SyncAggregateAnalyzedSessionsString.java new file mode 100644 index 000000000000..0b5bb77d2de9 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/aggregateanalyzedsessions/SyncAggregateAnalyzedSessionsString.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_AggregateAnalyzedSessions_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AggregateAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncAggregateAnalyzedSessionsString { + + public static void main(String[] args) throws Exception { + syncAggregateAnalyzedSessionsString(); + } + + public static void syncAggregateAnalyzedSessionsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String parent = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString(); + for (AggregateAnalyzedSessionsResponse.AgentAggregate element : + agentAnomalyDetectionServiceClient.aggregateAnalyzedSessions(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_AggregateAnalyzedSessions_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/AsyncClearTrainingData.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/AsyncClearTrainingData.java new file mode 100644 index 000000000000..b1b7a469e61c --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/AsyncClearTrainingData.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ClearTrainingData_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.ClearTrainingDataRequest; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; +import com.google.longrunning.Operation; + +public class AsyncClearTrainingData { + + public static void main(String[] args) throws Exception { + asyncClearTrainingData(); + } + + public static void asyncClearTrainingData() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ClearTrainingDataRequest request = + ClearTrainingDataRequest.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.clearTrainingDataCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ClearTrainingData_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/AsyncClearTrainingDataLRO.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/AsyncClearTrainingDataLRO.java new file mode 100644 index 000000000000..5ce782c4d569 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/AsyncClearTrainingDataLRO.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ClearTrainingData_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.ClearTrainingDataOperationMetadata; +import com.google.cloud.aiplatform.v1.ClearTrainingDataRequest; +import com.google.cloud.aiplatform.v1.ClearTrainingDataResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class AsyncClearTrainingDataLRO { + + public static void main(String[] args) throws Exception { + asyncClearTrainingDataLRO(); + } + + public static void asyncClearTrainingDataLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ClearTrainingDataRequest request = + ClearTrainingDataRequest.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .build(); + OperationFuture future = + agentAnomalyDetectionServiceClient + .clearTrainingDataOperationCallable() + .futureCall(request); + // Do something. + ClearTrainingDataResponse response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ClearTrainingData_LRO_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/SyncClearTrainingData.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/SyncClearTrainingData.java new file mode 100644 index 000000000000..fbfdc4afc7a4 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/SyncClearTrainingData.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ClearTrainingData_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.ClearTrainingDataRequest; +import com.google.cloud.aiplatform.v1.ClearTrainingDataResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncClearTrainingData { + + public static void main(String[] args) throws Exception { + syncClearTrainingData(); + } + + public static void syncClearTrainingData() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ClearTrainingDataRequest request = + ClearTrainingDataRequest.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .build(); + ClearTrainingDataResponse response = + agentAnomalyDetectionServiceClient.clearTrainingDataAsync(request).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ClearTrainingData_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/SyncClearTrainingDataMonitoredagentname.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/SyncClearTrainingDataMonitoredagentname.java new file mode 100644 index 000000000000..08fc2e451d4c --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/SyncClearTrainingDataMonitoredagentname.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ClearTrainingData_Monitoredagentname_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.ClearTrainingDataResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncClearTrainingDataMonitoredagentname { + + public static void main(String[] args) throws Exception { + syncClearTrainingDataMonitoredagentname(); + } + + public static void syncClearTrainingDataMonitoredagentname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + MonitoredAgentName name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + ClearTrainingDataResponse response = + agentAnomalyDetectionServiceClient.clearTrainingDataAsync(name).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ClearTrainingData_Monitoredagentname_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/SyncClearTrainingDataString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/SyncClearTrainingDataString.java new file mode 100644 index 000000000000..0422ca2db212 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/cleartrainingdata/SyncClearTrainingDataString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ClearTrainingData_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.ClearTrainingDataResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncClearTrainingDataString { + + public static void main(String[] args) throws Exception { + syncClearTrainingDataString(); + } + + public static void syncClearTrainingDataString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString(); + ClearTrainingDataResponse response = + agentAnomalyDetectionServiceClient.clearTrainingDataAsync(name).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ClearTrainingData_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/create/SyncCreateSetCredentialsProvider.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/create/SyncCreateSetCredentialsProvider.java new file mode 100644 index 000000000000..294a156bc71e --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/create/SyncCreateSetCredentialsProvider.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_Create_SetCredentialsProvider_sync] +import com.google.api.gax.core.FixedCredentialsProvider; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceSettings; +import com.google.cloud.aiplatform.v1.myCredentials; + +public class SyncCreateSetCredentialsProvider { + + public static void main(String[] args) throws Exception { + syncCreateSetCredentialsProvider(); + } + + public static void syncCreateSetCredentialsProvider() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + AgentAnomalyDetectionServiceSettings agentAnomalyDetectionServiceSettings = + AgentAnomalyDetectionServiceSettings.newBuilder() + .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials)) + .build(); + AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create(agentAnomalyDetectionServiceSettings); + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_Create_SetCredentialsProvider_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/create/SyncCreateSetEndpoint.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/create/SyncCreateSetEndpoint.java new file mode 100644 index 000000000000..bf6f7123d02c --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/create/SyncCreateSetEndpoint.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_Create_SetEndpoint_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceSettings; +import com.google.cloud.aiplatform.v1.myEndpoint; + +public class SyncCreateSetEndpoint { + + public static void main(String[] args) throws Exception { + syncCreateSetEndpoint(); + } + + public static void syncCreateSetEndpoint() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + AgentAnomalyDetectionServiceSettings agentAnomalyDetectionServiceSettings = + AgentAnomalyDetectionServiceSettings.newBuilder().setEndpoint(myEndpoint).build(); + AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create(agentAnomalyDetectionServiceSettings); + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_Create_SetEndpoint_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/AsyncCreateAgentAnomalyDetectionScope.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/AsyncCreateAgentAnomalyDetectionScope.java new file mode 100644 index 000000000000..4054b0f72282 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/AsyncCreateAgentAnomalyDetectionScope.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_CreateAgentAnomalyDetectionScope_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.LocationName; +import com.google.longrunning.Operation; + +public class AsyncCreateAgentAnomalyDetectionScope { + + public static void main(String[] args) throws Exception { + asyncCreateAgentAnomalyDetectionScope(); + } + + public static void asyncCreateAgentAnomalyDetectionScope() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + CreateAgentAnomalyDetectionScopeRequest request = + CreateAgentAnomalyDetectionScopeRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setAgentAnomalyDetectionScope(AgentAnomalyDetectionScope.newBuilder().build()) + .setAgentAnomalyDetectionScopeId("agentAnomalyDetectionScopeId-218530648") + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient + .createAgentAnomalyDetectionScopeCallable() + .futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_CreateAgentAnomalyDetectionScope_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/AsyncCreateAgentAnomalyDetectionScopeLRO.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/AsyncCreateAgentAnomalyDetectionScopeLRO.java new file mode 100644 index 000000000000..40f5ab524669 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/AsyncCreateAgentAnomalyDetectionScopeLRO.java @@ -0,0 +1,57 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_CreateAgentAnomalyDetectionScope_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeOperationMetadata; +import com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.LocationName; + +public class AsyncCreateAgentAnomalyDetectionScopeLRO { + + public static void main(String[] args) throws Exception { + asyncCreateAgentAnomalyDetectionScopeLRO(); + } + + public static void asyncCreateAgentAnomalyDetectionScopeLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + CreateAgentAnomalyDetectionScopeRequest request = + CreateAgentAnomalyDetectionScopeRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setAgentAnomalyDetectionScope(AgentAnomalyDetectionScope.newBuilder().build()) + .setAgentAnomalyDetectionScopeId("agentAnomalyDetectionScopeId-218530648") + .build(); + OperationFuture + future = + agentAnomalyDetectionServiceClient + .createAgentAnomalyDetectionScopeOperationCallable() + .futureCall(request); + // Do something. + AgentAnomalyDetectionScope response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_CreateAgentAnomalyDetectionScope_LRO_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/SyncCreateAgentAnomalyDetectionScope.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/SyncCreateAgentAnomalyDetectionScope.java new file mode 100644 index 000000000000..9660f3340664 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/SyncCreateAgentAnomalyDetectionScope.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_CreateAgentAnomalyDetectionScope_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.CreateAgentAnomalyDetectionScopeRequest; +import com.google.cloud.aiplatform.v1.LocationName; + +public class SyncCreateAgentAnomalyDetectionScope { + + public static void main(String[] args) throws Exception { + syncCreateAgentAnomalyDetectionScope(); + } + + public static void syncCreateAgentAnomalyDetectionScope() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + CreateAgentAnomalyDetectionScopeRequest request = + CreateAgentAnomalyDetectionScopeRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setAgentAnomalyDetectionScope(AgentAnomalyDetectionScope.newBuilder().build()) + .setAgentAnomalyDetectionScopeId("agentAnomalyDetectionScopeId-218530648") + .build(); + AgentAnomalyDetectionScope response = + agentAnomalyDetectionServiceClient.createAgentAnomalyDetectionScopeAsync(request).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_CreateAgentAnomalyDetectionScope_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/SyncCreateAgentAnomalyDetectionScopeLocationnameAgentanomalydetectionscopeString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/SyncCreateAgentAnomalyDetectionScopeLocationnameAgentanomalydetectionscopeString.java new file mode 100644 index 000000000000..9d059044ffd2 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/SyncCreateAgentAnomalyDetectionScopeLocationnameAgentanomalydetectionscopeString.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_CreateAgentAnomalyDetectionScope_LocationnameAgentanomalydetectionscopeString_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.LocationName; + +public class SyncCreateAgentAnomalyDetectionScopeLocationnameAgentanomalydetectionscopeString { + + public static void main(String[] args) throws Exception { + syncCreateAgentAnomalyDetectionScopeLocationnameAgentanomalydetectionscopeString(); + } + + public static void + syncCreateAgentAnomalyDetectionScopeLocationnameAgentanomalydetectionscopeString() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + AgentAnomalyDetectionScope agentAnomalyDetectionScope = + AgentAnomalyDetectionScope.newBuilder().build(); + String agentAnomalyDetectionScopeId = "agentAnomalyDetectionScopeId-218530648"; + AgentAnomalyDetectionScope response = + agentAnomalyDetectionServiceClient + .createAgentAnomalyDetectionScopeAsync( + parent, agentAnomalyDetectionScope, agentAnomalyDetectionScopeId) + .get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_CreateAgentAnomalyDetectionScope_LocationnameAgentanomalydetectionscopeString_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/SyncCreateAgentAnomalyDetectionScopeStringAgentanomalydetectionscopeString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/SyncCreateAgentAnomalyDetectionScopeStringAgentanomalydetectionscopeString.java new file mode 100644 index 000000000000..a899d29233ba --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/createagentanomalydetectionscope/SyncCreateAgentAnomalyDetectionScopeStringAgentanomalydetectionscopeString.java @@ -0,0 +1,51 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_CreateAgentAnomalyDetectionScope_StringAgentanomalydetectionscopeString_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.LocationName; + +public class SyncCreateAgentAnomalyDetectionScopeStringAgentanomalydetectionscopeString { + + public static void main(String[] args) throws Exception { + syncCreateAgentAnomalyDetectionScopeStringAgentanomalydetectionscopeString(); + } + + public static void syncCreateAgentAnomalyDetectionScopeStringAgentanomalydetectionscopeString() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + AgentAnomalyDetectionScope agentAnomalyDetectionScope = + AgentAnomalyDetectionScope.newBuilder().build(); + String agentAnomalyDetectionScopeId = "agentAnomalyDetectionScopeId-218530648"; + AgentAnomalyDetectionScope response = + agentAnomalyDetectionServiceClient + .createAgentAnomalyDetectionScopeAsync( + parent, agentAnomalyDetectionScope, agentAnomalyDetectionScopeId) + .get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_CreateAgentAnomalyDetectionScope_StringAgentanomalydetectionscopeString_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/AsyncDeleteAgentAnomalyDetectionScope.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/AsyncDeleteAgentAnomalyDetectionScope.java new file mode 100644 index 000000000000..b3fbd260d257 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/AsyncDeleteAgentAnomalyDetectionScope.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_DeleteAgentAnomalyDetectionScope_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeName; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest; +import com.google.longrunning.Operation; + +public class AsyncDeleteAgentAnomalyDetectionScope { + + public static void main(String[] args) throws Exception { + asyncDeleteAgentAnomalyDetectionScope(); + } + + public static void asyncDeleteAgentAnomalyDetectionScope() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + DeleteAgentAnomalyDetectionScopeRequest request = + DeleteAgentAnomalyDetectionScopeRequest.newBuilder() + .setName( + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]") + .toString()) + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient + .deleteAgentAnomalyDetectionScopeCallable() + .futureCall(request); + // Do something. + future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_DeleteAgentAnomalyDetectionScope_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/AsyncDeleteAgentAnomalyDetectionScopeLRO.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/AsyncDeleteAgentAnomalyDetectionScopeLRO.java new file mode 100644 index 000000000000..a4fcc9c55642 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/AsyncDeleteAgentAnomalyDetectionScopeLRO.java @@ -0,0 +1,57 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_DeleteAgentAnomalyDetectionScope_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeName; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeOperationMetadata; +import com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest; +import com.google.protobuf.Empty; + +public class AsyncDeleteAgentAnomalyDetectionScopeLRO { + + public static void main(String[] args) throws Exception { + asyncDeleteAgentAnomalyDetectionScopeLRO(); + } + + public static void asyncDeleteAgentAnomalyDetectionScopeLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + DeleteAgentAnomalyDetectionScopeRequest request = + DeleteAgentAnomalyDetectionScopeRequest.newBuilder() + .setName( + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]") + .toString()) + .build(); + OperationFuture future = + agentAnomalyDetectionServiceClient + .deleteAgentAnomalyDetectionScopeOperationCallable() + .futureCall(request); + // Do something. + future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_DeleteAgentAnomalyDetectionScope_LRO_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/SyncDeleteAgentAnomalyDetectionScope.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/SyncDeleteAgentAnomalyDetectionScope.java new file mode 100644 index 000000000000..0a04c71b1c20 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/SyncDeleteAgentAnomalyDetectionScope.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_DeleteAgentAnomalyDetectionScope_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeName; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.DeleteAgentAnomalyDetectionScopeRequest; +import com.google.protobuf.Empty; + +public class SyncDeleteAgentAnomalyDetectionScope { + + public static void main(String[] args) throws Exception { + syncDeleteAgentAnomalyDetectionScope(); + } + + public static void syncDeleteAgentAnomalyDetectionScope() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + DeleteAgentAnomalyDetectionScopeRequest request = + DeleteAgentAnomalyDetectionScopeRequest.newBuilder() + .setName( + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]") + .toString()) + .build(); + agentAnomalyDetectionServiceClient.deleteAgentAnomalyDetectionScopeAsync(request).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_DeleteAgentAnomalyDetectionScope_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/SyncDeleteAgentAnomalyDetectionScopeAgentanomalydetectionscopename.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/SyncDeleteAgentAnomalyDetectionScopeAgentanomalydetectionscopename.java new file mode 100644 index 000000000000..ed74224032b5 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/SyncDeleteAgentAnomalyDetectionScopeAgentanomalydetectionscopename.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_DeleteAgentAnomalyDetectionScope_Agentanomalydetectionscopename_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeName; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.protobuf.Empty; + +public class SyncDeleteAgentAnomalyDetectionScopeAgentanomalydetectionscopename { + + public static void main(String[] args) throws Exception { + syncDeleteAgentAnomalyDetectionScopeAgentanomalydetectionscopename(); + } + + public static void syncDeleteAgentAnomalyDetectionScopeAgentanomalydetectionscopename() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + AgentAnomalyDetectionScopeName name = + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]"); + agentAnomalyDetectionServiceClient.deleteAgentAnomalyDetectionScopeAsync(name).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_DeleteAgentAnomalyDetectionScope_Agentanomalydetectionscopename_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/SyncDeleteAgentAnomalyDetectionScopeString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/SyncDeleteAgentAnomalyDetectionScopeString.java new file mode 100644 index 000000000000..8d1643e47576 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/deleteagentanomalydetectionscope/SyncDeleteAgentAnomalyDetectionScopeString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_DeleteAgentAnomalyDetectionScope_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeName; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.protobuf.Empty; + +public class SyncDeleteAgentAnomalyDetectionScopeString { + + public static void main(String[] args) throws Exception { + syncDeleteAgentAnomalyDetectionScopeString(); + } + + public static void syncDeleteAgentAnomalyDetectionScopeString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String name = + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]") + .toString(); + agentAnomalyDetectionServiceClient.deleteAgentAnomalyDetectionScopeAsync(name).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_DeleteAgentAnomalyDetectionScope_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/AsyncDisableMonitoredAgent.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/AsyncDisableMonitoredAgent.java new file mode 100644 index 000000000000..d3013440bbd9 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/AsyncDisableMonitoredAgent.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_DisableMonitoredAgent_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; +import com.google.longrunning.Operation; + +public class AsyncDisableMonitoredAgent { + + public static void main(String[] args) throws Exception { + asyncDisableMonitoredAgent(); + } + + public static void asyncDisableMonitoredAgent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + DisableMonitoredAgentRequest request = + DisableMonitoredAgentRequest.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.disableMonitoredAgentCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_DisableMonitoredAgent_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/AsyncDisableMonitoredAgentLRO.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/AsyncDisableMonitoredAgentLRO.java new file mode 100644 index 000000000000..db116bfb8cc1 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/AsyncDisableMonitoredAgentLRO.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_DisableMonitoredAgent_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.DisableMonitoredAgentOperationMetadata; +import com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class AsyncDisableMonitoredAgentLRO { + + public static void main(String[] args) throws Exception { + asyncDisableMonitoredAgentLRO(); + } + + public static void asyncDisableMonitoredAgentLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + DisableMonitoredAgentRequest request = + DisableMonitoredAgentRequest.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .build(); + OperationFuture future = + agentAnomalyDetectionServiceClient + .disableMonitoredAgentOperationCallable() + .futureCall(request); + // Do something. + MonitoredAgent response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_DisableMonitoredAgent_LRO_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/SyncDisableMonitoredAgent.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/SyncDisableMonitoredAgent.java new file mode 100644 index 000000000000..2002d12c8265 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/SyncDisableMonitoredAgent.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_DisableMonitoredAgent_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.DisableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncDisableMonitoredAgent { + + public static void main(String[] args) throws Exception { + syncDisableMonitoredAgent(); + } + + public static void syncDisableMonitoredAgent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + DisableMonitoredAgentRequest request = + DisableMonitoredAgentRequest.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .build(); + MonitoredAgent response = + agentAnomalyDetectionServiceClient.disableMonitoredAgentAsync(request).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_DisableMonitoredAgent_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/SyncDisableMonitoredAgentMonitoredagentname.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/SyncDisableMonitoredAgentMonitoredagentname.java new file mode 100644 index 000000000000..bfc510dafe7d --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/SyncDisableMonitoredAgentMonitoredagentname.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_DisableMonitoredAgent_Monitoredagentname_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncDisableMonitoredAgentMonitoredagentname { + + public static void main(String[] args) throws Exception { + syncDisableMonitoredAgentMonitoredagentname(); + } + + public static void syncDisableMonitoredAgentMonitoredagentname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + MonitoredAgentName name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + MonitoredAgent response = + agentAnomalyDetectionServiceClient.disableMonitoredAgentAsync(name).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_DisableMonitoredAgent_Monitoredagentname_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/SyncDisableMonitoredAgentString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/SyncDisableMonitoredAgentString.java new file mode 100644 index 000000000000..cb9fd7c11e99 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/disablemonitoredagent/SyncDisableMonitoredAgentString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_DisableMonitoredAgent_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncDisableMonitoredAgentString { + + public static void main(String[] args) throws Exception { + syncDisableMonitoredAgentString(); + } + + public static void syncDisableMonitoredAgentString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString(); + MonitoredAgent response = + agentAnomalyDetectionServiceClient.disableMonitoredAgentAsync(name).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_DisableMonitoredAgent_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/AsyncEnableMonitoredAgent.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/AsyncEnableMonitoredAgent.java new file mode 100644 index 000000000000..233b584b33f8 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/AsyncEnableMonitoredAgent.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_EnableMonitoredAgent_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; +import com.google.longrunning.Operation; + +public class AsyncEnableMonitoredAgent { + + public static void main(String[] args) throws Exception { + asyncEnableMonitoredAgent(); + } + + public static void asyncEnableMonitoredAgent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + EnableMonitoredAgentRequest request = + EnableMonitoredAgentRequest.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.enableMonitoredAgentCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_EnableMonitoredAgent_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/AsyncEnableMonitoredAgentLRO.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/AsyncEnableMonitoredAgentLRO.java new file mode 100644 index 000000000000..e06872ba3171 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/AsyncEnableMonitoredAgentLRO.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_EnableMonitoredAgent_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.EnableMonitoredAgentOperationMetadata; +import com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class AsyncEnableMonitoredAgentLRO { + + public static void main(String[] args) throws Exception { + asyncEnableMonitoredAgentLRO(); + } + + public static void asyncEnableMonitoredAgentLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + EnableMonitoredAgentRequest request = + EnableMonitoredAgentRequest.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .build(); + OperationFuture future = + agentAnomalyDetectionServiceClient + .enableMonitoredAgentOperationCallable() + .futureCall(request); + // Do something. + MonitoredAgent response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_EnableMonitoredAgent_LRO_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/SyncEnableMonitoredAgent.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/SyncEnableMonitoredAgent.java new file mode 100644 index 000000000000..ab665de99f07 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/SyncEnableMonitoredAgent.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_EnableMonitoredAgent_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.EnableMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncEnableMonitoredAgent { + + public static void main(String[] args) throws Exception { + syncEnableMonitoredAgent(); + } + + public static void syncEnableMonitoredAgent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + EnableMonitoredAgentRequest request = + EnableMonitoredAgentRequest.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .build(); + MonitoredAgent response = + agentAnomalyDetectionServiceClient.enableMonitoredAgentAsync(request).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_EnableMonitoredAgent_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/SyncEnableMonitoredAgentMonitoredagentname.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/SyncEnableMonitoredAgentMonitoredagentname.java new file mode 100644 index 000000000000..6a975b98df54 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/SyncEnableMonitoredAgentMonitoredagentname.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_EnableMonitoredAgent_Monitoredagentname_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncEnableMonitoredAgentMonitoredagentname { + + public static void main(String[] args) throws Exception { + syncEnableMonitoredAgentMonitoredagentname(); + } + + public static void syncEnableMonitoredAgentMonitoredagentname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + MonitoredAgentName name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + MonitoredAgent response = + agentAnomalyDetectionServiceClient.enableMonitoredAgentAsync(name).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_EnableMonitoredAgent_Monitoredagentname_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/SyncEnableMonitoredAgentString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/SyncEnableMonitoredAgentString.java new file mode 100644 index 000000000000..207d0bb39f9d --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/enablemonitoredagent/SyncEnableMonitoredAgentString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_EnableMonitoredAgent_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncEnableMonitoredAgentString { + + public static void main(String[] args) throws Exception { + syncEnableMonitoredAgentString(); + } + + public static void syncEnableMonitoredAgentString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString(); + MonitoredAgent response = + agentAnomalyDetectionServiceClient.enableMonitoredAgentAsync(name).get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_EnableMonitoredAgent_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/AsyncGetAgentAnomalyDetectionScope.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/AsyncGetAgentAnomalyDetectionScope.java new file mode 100644 index 000000000000..3c9c06bdc713 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/AsyncGetAgentAnomalyDetectionScope.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAgentAnomalyDetectionScope_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeName; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest; + +public class AsyncGetAgentAnomalyDetectionScope { + + public static void main(String[] args) throws Exception { + asyncGetAgentAnomalyDetectionScope(); + } + + public static void asyncGetAgentAnomalyDetectionScope() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetAgentAnomalyDetectionScopeRequest request = + GetAgentAnomalyDetectionScopeRequest.newBuilder() + .setName( + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]") + .toString()) + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient + .getAgentAnomalyDetectionScopeCallable() + .futureCall(request); + // Do something. + AgentAnomalyDetectionScope response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAgentAnomalyDetectionScope_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScope.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScope.java new file mode 100644 index 000000000000..617d943e547e --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScope.java @@ -0,0 +1,51 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAgentAnomalyDetectionScope_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeName; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.GetAgentAnomalyDetectionScopeRequest; + +public class SyncGetAgentAnomalyDetectionScope { + + public static void main(String[] args) throws Exception { + syncGetAgentAnomalyDetectionScope(); + } + + public static void syncGetAgentAnomalyDetectionScope() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetAgentAnomalyDetectionScopeRequest request = + GetAgentAnomalyDetectionScopeRequest.newBuilder() + .setName( + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]") + .toString()) + .build(); + AgentAnomalyDetectionScope response = + agentAnomalyDetectionServiceClient.getAgentAnomalyDetectionScope(request); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAgentAnomalyDetectionScope_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScopeAgentanomalydetectionscopename.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScopeAgentanomalydetectionscopename.java new file mode 100644 index 000000000000..0d472160b462 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScopeAgentanomalydetectionscopename.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAgentAnomalyDetectionScope_Agentanomalydetectionscopename_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeName; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; + +public class SyncGetAgentAnomalyDetectionScopeAgentanomalydetectionscopename { + + public static void main(String[] args) throws Exception { + syncGetAgentAnomalyDetectionScopeAgentanomalydetectionscopename(); + } + + public static void syncGetAgentAnomalyDetectionScopeAgentanomalydetectionscopename() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + AgentAnomalyDetectionScopeName name = + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]"); + AgentAnomalyDetectionScope response = + agentAnomalyDetectionServiceClient.getAgentAnomalyDetectionScope(name); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAgentAnomalyDetectionScope_Agentanomalydetectionscopename_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScopeString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScopeString.java new file mode 100644 index 000000000000..6591e285023b --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScopeString.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAgentAnomalyDetectionScope_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScopeName; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; + +public class SyncGetAgentAnomalyDetectionScopeString { + + public static void main(String[] args) throws Exception { + syncGetAgentAnomalyDetectionScopeString(); + } + + public static void syncGetAgentAnomalyDetectionScopeString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String name = + AgentAnomalyDetectionScopeName.of( + "[PROJECT]", "[LOCATION]", "[AGENT_ANOMALY_DETECTION_SCOPE]") + .toString(); + AgentAnomalyDetectionScope response = + agentAnomalyDetectionServiceClient.getAgentAnomalyDetectionScope(name); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAgentAnomalyDetectionScope_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/AsyncGetAnalyzedInvocation.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/AsyncGetAnalyzedInvocation.java new file mode 100644 index 000000000000..dc3c8b42bcb2 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/AsyncGetAnalyzedInvocation.java @@ -0,0 +1,58 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedInvocation_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedInvocationName; +import com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest; + +public class AsyncGetAnalyzedInvocation { + + public static void main(String[] args) throws Exception { + asyncGetAnalyzedInvocation(); + } + + public static void asyncGetAnalyzedInvocation() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetAnalyzedInvocationRequest request = + GetAnalyzedInvocationRequest.newBuilder() + .setName( + AnalyzedInvocationName.of( + "[PROJECT]", + "[LOCATION]", + "[MONITORED_AGENT]", + "[ANALYZED_SESSION]", + "[ANALYZED_INVOCATION]") + .toString()) + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.getAnalyzedInvocationCallable().futureCall(request); + // Do something. + AnalyzedInvocation response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedInvocation_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/SyncGetAnalyzedInvocation.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/SyncGetAnalyzedInvocation.java new file mode 100644 index 000000000000..9784282a910e --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/SyncGetAnalyzedInvocation.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedInvocation_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedInvocationName; +import com.google.cloud.aiplatform.v1.GetAnalyzedInvocationRequest; + +public class SyncGetAnalyzedInvocation { + + public static void main(String[] args) throws Exception { + syncGetAnalyzedInvocation(); + } + + public static void syncGetAnalyzedInvocation() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetAnalyzedInvocationRequest request = + GetAnalyzedInvocationRequest.newBuilder() + .setName( + AnalyzedInvocationName.of( + "[PROJECT]", + "[LOCATION]", + "[MONITORED_AGENT]", + "[ANALYZED_SESSION]", + "[ANALYZED_INVOCATION]") + .toString()) + .build(); + AnalyzedInvocation response = + agentAnomalyDetectionServiceClient.getAnalyzedInvocation(request); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedInvocation_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/SyncGetAnalyzedInvocationAnalyzedinvocationname.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/SyncGetAnalyzedInvocationAnalyzedinvocationname.java new file mode 100644 index 000000000000..6a70d1bd5c64 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/SyncGetAnalyzedInvocationAnalyzedinvocationname.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedInvocation_Analyzedinvocationname_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedInvocationName; + +public class SyncGetAnalyzedInvocationAnalyzedinvocationname { + + public static void main(String[] args) throws Exception { + syncGetAnalyzedInvocationAnalyzedinvocationname(); + } + + public static void syncGetAnalyzedInvocationAnalyzedinvocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + AnalyzedInvocationName name = + AnalyzedInvocationName.of( + "[PROJECT]", + "[LOCATION]", + "[MONITORED_AGENT]", + "[ANALYZED_SESSION]", + "[ANALYZED_INVOCATION]"); + AnalyzedInvocation response = agentAnomalyDetectionServiceClient.getAnalyzedInvocation(name); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedInvocation_Analyzedinvocationname_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/SyncGetAnalyzedInvocationString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/SyncGetAnalyzedInvocationString.java new file mode 100644 index 000000000000..c11559a8d544 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedinvocation/SyncGetAnalyzedInvocationString.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedInvocation_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedInvocationName; + +public class SyncGetAnalyzedInvocationString { + + public static void main(String[] args) throws Exception { + syncGetAnalyzedInvocationString(); + } + + public static void syncGetAnalyzedInvocationString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String name = + AnalyzedInvocationName.of( + "[PROJECT]", + "[LOCATION]", + "[MONITORED_AGENT]", + "[ANALYZED_SESSION]", + "[ANALYZED_INVOCATION]") + .toString(); + AnalyzedInvocation response = agentAnomalyDetectionServiceClient.getAnalyzedInvocation(name); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedInvocation_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/AsyncGetAnalyzedSession.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/AsyncGetAnalyzedSession.java new file mode 100644 index 000000000000..da3408651c73 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/AsyncGetAnalyzedSession.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedSession_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.AnalyzedSessionName; +import com.google.cloud.aiplatform.v1.AnalyzedSessionView; +import com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest; + +public class AsyncGetAnalyzedSession { + + public static void main(String[] args) throws Exception { + asyncGetAnalyzedSession(); + } + + public static void asyncGetAnalyzedSession() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetAnalyzedSessionRequest request = + GetAnalyzedSessionRequest.newBuilder() + .setName( + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]") + .toString()) + .setView(AnalyzedSessionView.forNumber(0)) + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.getAnalyzedSessionCallable().futureCall(request); + // Do something. + AnalyzedSession response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedSession_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/SyncGetAnalyzedSession.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/SyncGetAnalyzedSession.java new file mode 100644 index 000000000000..6b20929b4ebf --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/SyncGetAnalyzedSession.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedSession_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.AnalyzedSessionName; +import com.google.cloud.aiplatform.v1.AnalyzedSessionView; +import com.google.cloud.aiplatform.v1.GetAnalyzedSessionRequest; + +public class SyncGetAnalyzedSession { + + public static void main(String[] args) throws Exception { + syncGetAnalyzedSession(); + } + + public static void syncGetAnalyzedSession() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetAnalyzedSessionRequest request = + GetAnalyzedSessionRequest.newBuilder() + .setName( + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]") + .toString()) + .setView(AnalyzedSessionView.forNumber(0)) + .build(); + AnalyzedSession response = agentAnomalyDetectionServiceClient.getAnalyzedSession(request); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedSession_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/SyncGetAnalyzedSessionAnalyzedsessionname.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/SyncGetAnalyzedSessionAnalyzedsessionname.java new file mode 100644 index 000000000000..e45c9bae7de9 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/SyncGetAnalyzedSessionAnalyzedsessionname.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedSession_Analyzedsessionname_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.AnalyzedSessionName; + +public class SyncGetAnalyzedSessionAnalyzedsessionname { + + public static void main(String[] args) throws Exception { + syncGetAnalyzedSessionAnalyzedsessionname(); + } + + public static void syncGetAnalyzedSessionAnalyzedsessionname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + AnalyzedSessionName name = + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]"); + AnalyzedSession response = agentAnomalyDetectionServiceClient.getAnalyzedSession(name); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedSession_Analyzedsessionname_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/SyncGetAnalyzedSessionString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/SyncGetAnalyzedSessionString.java new file mode 100644 index 000000000000..a1d02d3fff0a --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getanalyzedsession/SyncGetAnalyzedSessionString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedSession_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.AnalyzedSessionName; + +public class SyncGetAnalyzedSessionString { + + public static void main(String[] args) throws Exception { + syncGetAnalyzedSessionString(); + } + + public static void syncGetAnalyzedSessionString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String name = + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]") + .toString(); + AnalyzedSession response = agentAnomalyDetectionServiceClient.getAnalyzedSession(name); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetAnalyzedSession_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getiampolicy/AsyncGetIamPolicy.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getiampolicy/AsyncGetIamPolicy.java new file mode 100644 index 000000000000..4fd77bcc81a6 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getiampolicy/AsyncGetIamPolicy.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetIamPolicy_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.EndpointName; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.GetPolicyOptions; +import com.google.iam.v1.Policy; + +public class AsyncGetIamPolicy { + + public static void main(String[] args) throws Exception { + asyncGetIamPolicy(); + } + + public static void asyncGetIamPolicy() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetIamPolicyRequest request = + GetIamPolicyRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName( + "[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .setOptions(GetPolicyOptions.newBuilder().build()) + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.getIamPolicyCallable().futureCall(request); + // Do something. + Policy response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetIamPolicy_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getiampolicy/SyncGetIamPolicy.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getiampolicy/SyncGetIamPolicy.java new file mode 100644 index 000000000000..fdc78b836fa4 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getiampolicy/SyncGetIamPolicy.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetIamPolicy_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.EndpointName; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.GetPolicyOptions; +import com.google.iam.v1.Policy; + +public class SyncGetIamPolicy { + + public static void main(String[] args) throws Exception { + syncGetIamPolicy(); + } + + public static void syncGetIamPolicy() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetIamPolicyRequest request = + GetIamPolicyRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName( + "[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .setOptions(GetPolicyOptions.newBuilder().build()) + .build(); + Policy response = agentAnomalyDetectionServiceClient.getIamPolicy(request); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetIamPolicy_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getlocation/AsyncGetLocation.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getlocation/AsyncGetLocation.java new file mode 100644 index 000000000000..4ab92bb91a70 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getlocation/AsyncGetLocation.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetLocation_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.Location; + +public class AsyncGetLocation { + + public static void main(String[] args) throws Exception { + asyncGetLocation(); + } + + public static void asyncGetLocation() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.getLocationCallable().futureCall(request); + // Do something. + Location response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetLocation_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getlocation/SyncGetLocation.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getlocation/SyncGetLocation.java new file mode 100644 index 000000000000..b0685fed0537 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getlocation/SyncGetLocation.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetLocation_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.Location; + +public class SyncGetLocation { + + public static void main(String[] args) throws Exception { + syncGetLocation(); + } + + public static void syncGetLocation() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + Location response = agentAnomalyDetectionServiceClient.getLocation(request); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetLocation_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/AsyncGetMonitoredAgent.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/AsyncGetMonitoredAgent.java new file mode 100644 index 000000000000..ae00cee67719 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/AsyncGetMonitoredAgent.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetMonitoredAgent_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class AsyncGetMonitoredAgent { + + public static void main(String[] args) throws Exception { + asyncGetMonitoredAgent(); + } + + public static void asyncGetMonitoredAgent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetMonitoredAgentRequest request = + GetMonitoredAgentRequest.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.getMonitoredAgentCallable().futureCall(request); + // Do something. + MonitoredAgent response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetMonitoredAgent_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/SyncGetMonitoredAgent.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/SyncGetMonitoredAgent.java new file mode 100644 index 000000000000..700050288cd0 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/SyncGetMonitoredAgent.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetMonitoredAgent_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.GetMonitoredAgentRequest; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncGetMonitoredAgent { + + public static void main(String[] args) throws Exception { + syncGetMonitoredAgent(); + } + + public static void syncGetMonitoredAgent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + GetMonitoredAgentRequest request = + GetMonitoredAgentRequest.newBuilder() + .setName( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .build(); + MonitoredAgent response = agentAnomalyDetectionServiceClient.getMonitoredAgent(request); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetMonitoredAgent_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/SyncGetMonitoredAgentMonitoredagentname.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/SyncGetMonitoredAgentMonitoredagentname.java new file mode 100644 index 000000000000..a16eda275188 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/SyncGetMonitoredAgentMonitoredagentname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetMonitoredAgent_Monitoredagentname_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncGetMonitoredAgentMonitoredagentname { + + public static void main(String[] args) throws Exception { + syncGetMonitoredAgentMonitoredagentname(); + } + + public static void syncGetMonitoredAgentMonitoredagentname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + MonitoredAgentName name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + MonitoredAgent response = agentAnomalyDetectionServiceClient.getMonitoredAgent(name); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetMonitoredAgent_Monitoredagentname_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/SyncGetMonitoredAgentString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/SyncGetMonitoredAgentString.java new file mode 100644 index 000000000000..194fa4e11610 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/getmonitoredagent/SyncGetMonitoredAgentString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_GetMonitoredAgent_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncGetMonitoredAgentString { + + public static void main(String[] args) throws Exception { + syncGetMonitoredAgentString(); + } + + public static void syncGetMonitoredAgentString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String name = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString(); + MonitoredAgent response = agentAnomalyDetectionServiceClient.getMonitoredAgent(name); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_GetMonitoredAgent_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/AsyncListAgentAnomalyDetectionScopes.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/AsyncListAgentAnomalyDetectionScopes.java new file mode 100644 index 000000000000..f0fa92ce25f7 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/AsyncListAgentAnomalyDetectionScopes.java @@ -0,0 +1,57 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAgentAnomalyDetectionScopes_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest; +import com.google.cloud.aiplatform.v1.LocationName; + +public class AsyncListAgentAnomalyDetectionScopes { + + public static void main(String[] args) throws Exception { + asyncListAgentAnomalyDetectionScopes(); + } + + public static void asyncListAgentAnomalyDetectionScopes() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListAgentAnomalyDetectionScopesRequest request = + ListAgentAnomalyDetectionScopesRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient + .listAgentAnomalyDetectionScopesPagedCallable() + .futureCall(request); + // Do something. + for (AgentAnomalyDetectionScope element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAgentAnomalyDetectionScopes_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/AsyncListAgentAnomalyDetectionScopesPaged.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/AsyncListAgentAnomalyDetectionScopesPaged.java new file mode 100644 index 000000000000..b75a89c921cc --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/AsyncListAgentAnomalyDetectionScopesPaged.java @@ -0,0 +1,65 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAgentAnomalyDetectionScopes_Paged_async] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest; +import com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesResponse; +import com.google.cloud.aiplatform.v1.LocationName; +import com.google.common.base.Strings; + +public class AsyncListAgentAnomalyDetectionScopesPaged { + + public static void main(String[] args) throws Exception { + asyncListAgentAnomalyDetectionScopesPaged(); + } + + public static void asyncListAgentAnomalyDetectionScopesPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListAgentAnomalyDetectionScopesRequest request = + ListAgentAnomalyDetectionScopesRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListAgentAnomalyDetectionScopesResponse response = + agentAnomalyDetectionServiceClient + .listAgentAnomalyDetectionScopesCallable() + .call(request); + for (AgentAnomalyDetectionScope element : response.getAgentAnomalyDetectionScopesList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAgentAnomalyDetectionScopes_Paged_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/SyncListAgentAnomalyDetectionScopes.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/SyncListAgentAnomalyDetectionScopes.java new file mode 100644 index 000000000000..bb728af847f7 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/SyncListAgentAnomalyDetectionScopes.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAgentAnomalyDetectionScopes_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.ListAgentAnomalyDetectionScopesRequest; +import com.google.cloud.aiplatform.v1.LocationName; + +public class SyncListAgentAnomalyDetectionScopes { + + public static void main(String[] args) throws Exception { + syncListAgentAnomalyDetectionScopes(); + } + + public static void syncListAgentAnomalyDetectionScopes() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListAgentAnomalyDetectionScopesRequest request = + ListAgentAnomalyDetectionScopesRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (AgentAnomalyDetectionScope element : + agentAnomalyDetectionServiceClient + .listAgentAnomalyDetectionScopes(request) + .iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAgentAnomalyDetectionScopes_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/SyncListAgentAnomalyDetectionScopesLocationname.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/SyncListAgentAnomalyDetectionScopesLocationname.java new file mode 100644 index 000000000000..c8b8fc7f7288 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/SyncListAgentAnomalyDetectionScopesLocationname.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAgentAnomalyDetectionScopes_Locationname_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.LocationName; + +public class SyncListAgentAnomalyDetectionScopesLocationname { + + public static void main(String[] args) throws Exception { + syncListAgentAnomalyDetectionScopesLocationname(); + } + + public static void syncListAgentAnomalyDetectionScopesLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (AgentAnomalyDetectionScope element : + agentAnomalyDetectionServiceClient.listAgentAnomalyDetectionScopes(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAgentAnomalyDetectionScopes_Locationname_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/SyncListAgentAnomalyDetectionScopesString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/SyncListAgentAnomalyDetectionScopesString.java new file mode 100644 index 000000000000..0f9413d35b52 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listagentanomalydetectionscopes/SyncListAgentAnomalyDetectionScopesString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAgentAnomalyDetectionScopes_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionScope; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.LocationName; + +public class SyncListAgentAnomalyDetectionScopesString { + + public static void main(String[] args) throws Exception { + syncListAgentAnomalyDetectionScopesString(); + } + + public static void syncListAgentAnomalyDetectionScopesString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (AgentAnomalyDetectionScope element : + agentAnomalyDetectionServiceClient.listAgentAnomalyDetectionScopes(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAgentAnomalyDetectionScopes_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/AsyncListAnalyzedInvocations.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/AsyncListAnalyzedInvocations.java new file mode 100644 index 000000000000..376049491e10 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/AsyncListAnalyzedInvocations.java @@ -0,0 +1,60 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedInvocations_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedSessionName; +import com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest; + +public class AsyncListAnalyzedInvocations { + + public static void main(String[] args) throws Exception { + asyncListAnalyzedInvocations(); + } + + public static void asyncListAnalyzedInvocations() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListAnalyzedInvocationsRequest request = + ListAnalyzedInvocationsRequest.newBuilder() + .setParent( + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]") + .toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient + .listAnalyzedInvocationsPagedCallable() + .futureCall(request); + // Do something. + for (AnalyzedInvocation element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedInvocations_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/AsyncListAnalyzedInvocationsPaged.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/AsyncListAnalyzedInvocationsPaged.java new file mode 100644 index 000000000000..d8221371a558 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/AsyncListAnalyzedInvocationsPaged.java @@ -0,0 +1,66 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedInvocations_Paged_async] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedSessionName; +import com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest; +import com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsResponse; +import com.google.common.base.Strings; + +public class AsyncListAnalyzedInvocationsPaged { + + public static void main(String[] args) throws Exception { + asyncListAnalyzedInvocationsPaged(); + } + + public static void asyncListAnalyzedInvocationsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListAnalyzedInvocationsRequest request = + ListAnalyzedInvocationsRequest.newBuilder() + .setParent( + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]") + .toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListAnalyzedInvocationsResponse response = + agentAnomalyDetectionServiceClient.listAnalyzedInvocationsCallable().call(request); + for (AnalyzedInvocation element : response.getAnalyzedInvocationsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedInvocations_Paged_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/SyncListAnalyzedInvocations.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/SyncListAnalyzedInvocations.java new file mode 100644 index 000000000000..8e555a71d120 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/SyncListAnalyzedInvocations.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedInvocations_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedSessionName; +import com.google.cloud.aiplatform.v1.ListAnalyzedInvocationsRequest; + +public class SyncListAnalyzedInvocations { + + public static void main(String[] args) throws Exception { + syncListAnalyzedInvocations(); + } + + public static void syncListAnalyzedInvocations() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListAnalyzedInvocationsRequest request = + ListAnalyzedInvocationsRequest.newBuilder() + .setParent( + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]") + .toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (AnalyzedInvocation element : + agentAnomalyDetectionServiceClient.listAnalyzedInvocations(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedInvocations_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/SyncListAnalyzedInvocationsAnalyzedsessionname.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/SyncListAnalyzedInvocationsAnalyzedsessionname.java new file mode 100644 index 000000000000..39d1c3dc0c9c --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/SyncListAnalyzedInvocationsAnalyzedsessionname.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedInvocations_Analyzedsessionname_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedSessionName; + +public class SyncListAnalyzedInvocationsAnalyzedsessionname { + + public static void main(String[] args) throws Exception { + syncListAnalyzedInvocationsAnalyzedsessionname(); + } + + public static void syncListAnalyzedInvocationsAnalyzedsessionname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + AnalyzedSessionName parent = + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]"); + for (AnalyzedInvocation element : + agentAnomalyDetectionServiceClient.listAnalyzedInvocations(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedInvocations_Analyzedsessionname_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/SyncListAnalyzedInvocationsString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/SyncListAnalyzedInvocationsString.java new file mode 100644 index 000000000000..5a7e6fb1a1de --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedinvocations/SyncListAnalyzedInvocationsString.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedInvocations_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedInvocation; +import com.google.cloud.aiplatform.v1.AnalyzedSessionName; + +public class SyncListAnalyzedInvocationsString { + + public static void main(String[] args) throws Exception { + syncListAnalyzedInvocationsString(); + } + + public static void syncListAnalyzedInvocationsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String parent = + AnalyzedSessionName.of( + "[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]", "[ANALYZED_SESSION]") + .toString(); + for (AnalyzedInvocation element : + agentAnomalyDetectionServiceClient.listAnalyzedInvocations(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedInvocations_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/AsyncListAnalyzedSessions.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/AsyncListAnalyzedSessions.java new file mode 100644 index 000000000000..a5ea0626313c --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/AsyncListAnalyzedSessions.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedSessions_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.AnalyzedSessionView; +import com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class AsyncListAnalyzedSessions { + + public static void main(String[] args) throws Exception { + asyncListAnalyzedSessions(); + } + + public static void asyncListAnalyzedSessions() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListAnalyzedSessionsRequest request = + ListAnalyzedSessionsRequest.newBuilder() + .setParent( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setView(AnalyzedSessionView.forNumber(0)) + .setOrderBy("orderBy-1207110587") + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient + .listAnalyzedSessionsPagedCallable() + .futureCall(request); + // Do something. + for (AnalyzedSession element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedSessions_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/AsyncListAnalyzedSessionsPaged.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/AsyncListAnalyzedSessionsPaged.java new file mode 100644 index 000000000000..dce2a860a235 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/AsyncListAnalyzedSessionsPaged.java @@ -0,0 +1,68 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedSessions_Paged_async] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.AnalyzedSessionView; +import com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.ListAnalyzedSessionsResponse; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; +import com.google.common.base.Strings; + +public class AsyncListAnalyzedSessionsPaged { + + public static void main(String[] args) throws Exception { + asyncListAnalyzedSessionsPaged(); + } + + public static void asyncListAnalyzedSessionsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListAnalyzedSessionsRequest request = + ListAnalyzedSessionsRequest.newBuilder() + .setParent( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setView(AnalyzedSessionView.forNumber(0)) + .setOrderBy("orderBy-1207110587") + .build(); + while (true) { + ListAnalyzedSessionsResponse response = + agentAnomalyDetectionServiceClient.listAnalyzedSessionsCallable().call(request); + for (AnalyzedSession element : response.getAnalyzedSessionsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedSessions_Paged_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/SyncListAnalyzedSessions.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/SyncListAnalyzedSessions.java new file mode 100644 index 000000000000..a259673df64c --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/SyncListAnalyzedSessions.java @@ -0,0 +1,57 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedSessions_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.AnalyzedSessionView; +import com.google.cloud.aiplatform.v1.ListAnalyzedSessionsRequest; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncListAnalyzedSessions { + + public static void main(String[] args) throws Exception { + syncListAnalyzedSessions(); + } + + public static void syncListAnalyzedSessions() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListAnalyzedSessionsRequest request = + ListAnalyzedSessionsRequest.newBuilder() + .setParent( + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setView(AnalyzedSessionView.forNumber(0)) + .setOrderBy("orderBy-1207110587") + .build(); + for (AnalyzedSession element : + agentAnomalyDetectionServiceClient.listAnalyzedSessions(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedSessions_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/SyncListAnalyzedSessionsMonitoredagentname.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/SyncListAnalyzedSessionsMonitoredagentname.java new file mode 100644 index 000000000000..73d919f0c657 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/SyncListAnalyzedSessionsMonitoredagentname.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedSessions_Monitoredagentname_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncListAnalyzedSessionsMonitoredagentname { + + public static void main(String[] args) throws Exception { + syncListAnalyzedSessionsMonitoredagentname(); + } + + public static void syncListAnalyzedSessionsMonitoredagentname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + MonitoredAgentName parent = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]"); + for (AnalyzedSession element : + agentAnomalyDetectionServiceClient.listAnalyzedSessions(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedSessions_Monitoredagentname_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/SyncListAnalyzedSessionsString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/SyncListAnalyzedSessionsString.java new file mode 100644 index 000000000000..5b992e9da4bb --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listanalyzedsessions/SyncListAnalyzedSessionsString.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedSessions_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.AnalyzedSession; +import com.google.cloud.aiplatform.v1.MonitoredAgentName; + +public class SyncListAnalyzedSessionsString { + + public static void main(String[] args) throws Exception { + syncListAnalyzedSessionsString(); + } + + public static void syncListAnalyzedSessionsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String parent = + MonitoredAgentName.of("[PROJECT]", "[LOCATION]", "[MONITORED_AGENT]").toString(); + for (AnalyzedSession element : + agentAnomalyDetectionServiceClient.listAnalyzedSessions(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListAnalyzedSessions_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listlocations/AsyncListLocations.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listlocations/AsyncListLocations.java new file mode 100644 index 000000000000..0411fd49889e --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listlocations/AsyncListLocations.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListLocations_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.Location; + +public class AsyncListLocations { + + public static void main(String[] args) throws Exception { + asyncListLocations(); + } + + public static void asyncListLocations() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.listLocationsPagedCallable().futureCall(request); + // Do something. + for (Location element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListLocations_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listlocations/AsyncListLocationsPaged.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listlocations/AsyncListLocationsPaged.java new file mode 100644 index 000000000000..cedd8ae05839 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listlocations/AsyncListLocationsPaged.java @@ -0,0 +1,63 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListLocations_Paged_async] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.base.Strings; + +public class AsyncListLocationsPaged { + + public static void main(String[] args) throws Exception { + asyncListLocationsPaged(); + } + + public static void asyncListLocationsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListLocationsResponse response = + agentAnomalyDetectionServiceClient.listLocationsCallable().call(request); + for (Location element : response.getLocationsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListLocations_Paged_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listlocations/SyncListLocations.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listlocations/SyncListLocations.java new file mode 100644 index 000000000000..30f959e20306 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listlocations/SyncListLocations.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListLocations_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.Location; + +public class SyncListLocations { + + public static void main(String[] args) throws Exception { + syncListLocations(); + } + + public static void syncListLocations() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (Location element : + agentAnomalyDetectionServiceClient.listLocations(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListLocations_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/AsyncListMonitoredAgents.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/AsyncListMonitoredAgents.java new file mode 100644 index 000000000000..b23fe904696e --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/AsyncListMonitoredAgents.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListMonitoredAgents_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest; +import com.google.cloud.aiplatform.v1.LocationName; +import com.google.cloud.aiplatform.v1.MonitoredAgent; + +public class AsyncListMonitoredAgents { + + public static void main(String[] args) throws Exception { + asyncListMonitoredAgents(); + } + + public static void asyncListMonitoredAgents() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListMonitoredAgentsRequest request = + ListMonitoredAgentsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.listMonitoredAgentsPagedCallable().futureCall(request); + // Do something. + for (MonitoredAgent element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListMonitoredAgents_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/AsyncListMonitoredAgentsPaged.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/AsyncListMonitoredAgentsPaged.java new file mode 100644 index 000000000000..9b5b1a82554e --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/AsyncListMonitoredAgentsPaged.java @@ -0,0 +1,64 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListMonitoredAgents_Paged_async] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest; +import com.google.cloud.aiplatform.v1.ListMonitoredAgentsResponse; +import com.google.cloud.aiplatform.v1.LocationName; +import com.google.cloud.aiplatform.v1.MonitoredAgent; +import com.google.common.base.Strings; + +public class AsyncListMonitoredAgentsPaged { + + public static void main(String[] args) throws Exception { + asyncListMonitoredAgentsPaged(); + } + + public static void asyncListMonitoredAgentsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListMonitoredAgentsRequest request = + ListMonitoredAgentsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .build(); + while (true) { + ListMonitoredAgentsResponse response = + agentAnomalyDetectionServiceClient.listMonitoredAgentsCallable().call(request); + for (MonitoredAgent element : response.getMonitoredAgentsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListMonitoredAgents_Paged_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/SyncListMonitoredAgents.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/SyncListMonitoredAgents.java new file mode 100644 index 000000000000..3decf4d0adb2 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/SyncListMonitoredAgents.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListMonitoredAgents_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.ListMonitoredAgentsRequest; +import com.google.cloud.aiplatform.v1.LocationName; +import com.google.cloud.aiplatform.v1.MonitoredAgent; + +public class SyncListMonitoredAgents { + + public static void main(String[] args) throws Exception { + syncListMonitoredAgents(); + } + + public static void syncListMonitoredAgents() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + ListMonitoredAgentsRequest request = + ListMonitoredAgentsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .build(); + for (MonitoredAgent element : + agentAnomalyDetectionServiceClient.listMonitoredAgents(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListMonitoredAgents_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/SyncListMonitoredAgentsLocationname.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/SyncListMonitoredAgentsLocationname.java new file mode 100644 index 000000000000..547b51cb4ade --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/SyncListMonitoredAgentsLocationname.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListMonitoredAgents_Locationname_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.LocationName; +import com.google.cloud.aiplatform.v1.MonitoredAgent; + +public class SyncListMonitoredAgentsLocationname { + + public static void main(String[] args) throws Exception { + syncListMonitoredAgentsLocationname(); + } + + public static void syncListMonitoredAgentsLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (MonitoredAgent element : + agentAnomalyDetectionServiceClient.listMonitoredAgents(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListMonitoredAgents_Locationname_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/SyncListMonitoredAgentsString.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/SyncListMonitoredAgentsString.java new file mode 100644 index 000000000000..f6ffe1cec10b --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/listmonitoredagents/SyncListMonitoredAgentsString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_ListMonitoredAgents_String_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.LocationName; +import com.google.cloud.aiplatform.v1.MonitoredAgent; + +public class SyncListMonitoredAgentsString { + + public static void main(String[] args) throws Exception { + syncListMonitoredAgentsString(); + } + + public static void syncListMonitoredAgentsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (MonitoredAgent element : + agentAnomalyDetectionServiceClient.listMonitoredAgents(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_ListMonitoredAgents_String_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/setiampolicy/AsyncSetIamPolicy.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/setiampolicy/AsyncSetIamPolicy.java new file mode 100644 index 000000000000..cf359f5793b9 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/setiampolicy/AsyncSetIamPolicy.java @@ -0,0 +1,57 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_SetIamPolicy_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.EndpointName; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.protobuf.FieldMask; + +public class AsyncSetIamPolicy { + + public static void main(String[] args) throws Exception { + asyncSetIamPolicy(); + } + + public static void asyncSetIamPolicy() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName( + "[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .setPolicy(Policy.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.setIamPolicyCallable().futureCall(request); + // Do something. + Policy response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_SetIamPolicy_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/setiampolicy/SyncSetIamPolicy.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/setiampolicy/SyncSetIamPolicy.java new file mode 100644 index 000000000000..3e55639a0efc --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/setiampolicy/SyncSetIamPolicy.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_SetIamPolicy_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.EndpointName; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.protobuf.FieldMask; + +public class SyncSetIamPolicy { + + public static void main(String[] args) throws Exception { + syncSetIamPolicy(); + } + + public static void syncSetIamPolicy() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName( + "[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .setPolicy(Policy.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + Policy response = agentAnomalyDetectionServiceClient.setIamPolicy(request); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_SetIamPolicy_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/testiampermissions/AsyncTestIamPermissions.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/testiampermissions/AsyncTestIamPermissions.java new file mode 100644 index 000000000000..a4abba573df4 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/testiampermissions/AsyncTestIamPermissions.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_TestIamPermissions_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.EndpointName; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import java.util.ArrayList; + +public class AsyncTestIamPermissions { + + public static void main(String[] args) throws Exception { + asyncTestIamPermissions(); + } + + public static void asyncTestIamPermissions() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName( + "[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .addAllPermissions(new ArrayList()) + .build(); + ApiFuture future = + agentAnomalyDetectionServiceClient.testIamPermissionsCallable().futureCall(request); + // Do something. + TestIamPermissionsResponse response = future.get(); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_TestIamPermissions_async] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/testiampermissions/SyncTestIamPermissions.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/testiampermissions/SyncTestIamPermissions.java new file mode 100644 index 000000000000..aeeb1192e4dd --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservice/testiampermissions/SyncTestIamPermissions.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionService_TestIamPermissions_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceClient; +import com.google.cloud.aiplatform.v1.EndpointName; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import java.util.ArrayList; + +public class SyncTestIamPermissions { + + public static void main(String[] args) throws Exception { + syncTestIamPermissions(); + } + + public static void syncTestIamPermissions() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (AgentAnomalyDetectionServiceClient agentAnomalyDetectionServiceClient = + AgentAnomalyDetectionServiceClient.create()) { + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource( + EndpointName.ofProjectLocationEndpointName( + "[PROJECT]", "[LOCATION]", "[ENDPOINT]") + .toString()) + .addAllPermissions(new ArrayList()) + .build(); + TestIamPermissionsResponse response = + agentAnomalyDetectionServiceClient.testIamPermissions(request); + } + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionService_TestIamPermissions_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservicesettings/enablemonitoredagent/SyncEnableMonitoredAgent.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservicesettings/enablemonitoredagent/SyncEnableMonitoredAgent.java new file mode 100644 index 000000000000..d1d0784f7bec --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservicesettings/enablemonitoredagent/SyncEnableMonitoredAgent.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionServiceSettings_EnableMonitoredAgent_sync] +import com.google.api.gax.longrunning.OperationalTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.retrying.TimedRetryAlgorithm; +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceSettings; +import java.time.Duration; + +public class SyncEnableMonitoredAgent { + + public static void main(String[] args) throws Exception { + syncEnableMonitoredAgent(); + } + + public static void syncEnableMonitoredAgent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + AgentAnomalyDetectionServiceSettings.Builder agentAnomalyDetectionServiceSettingsBuilder = + AgentAnomalyDetectionServiceSettings.newBuilder(); + TimedRetryAlgorithm timedRetryAlgorithm = + OperationalTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(500)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(5000)) + .setTotalTimeoutDuration(Duration.ofHours(24)) + .build()); + agentAnomalyDetectionServiceSettingsBuilder + .createClusterOperationSettings() + .setPollingAlgorithm(timedRetryAlgorithm) + .build(); + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionServiceSettings_EnableMonitoredAgent_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservicesettings/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScope.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservicesettings/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScope.java new file mode 100644 index 000000000000..8f4cc657df89 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/agentanomalydetectionservicesettings/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScope.java @@ -0,0 +1,57 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionServiceSettings_GetAgentAnomalyDetectionScope_sync] +import com.google.cloud.aiplatform.v1.AgentAnomalyDetectionServiceSettings; +import java.time.Duration; + +public class SyncGetAgentAnomalyDetectionScope { + + public static void main(String[] args) throws Exception { + syncGetAgentAnomalyDetectionScope(); + } + + public static void syncGetAgentAnomalyDetectionScope() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + AgentAnomalyDetectionServiceSettings.Builder agentAnomalyDetectionServiceSettingsBuilder = + AgentAnomalyDetectionServiceSettings.newBuilder(); + agentAnomalyDetectionServiceSettingsBuilder + .getAgentAnomalyDetectionScopeSettings() + .setRetrySettings( + agentAnomalyDetectionServiceSettingsBuilder + .getAgentAnomalyDetectionScopeSettings() + .getRetrySettings() + .toBuilder() + .setInitialRetryDelayDuration(Duration.ofSeconds(1)) + .setInitialRpcTimeoutDuration(Duration.ofSeconds(5)) + .setMaxAttempts(5) + .setMaxRetryDelayDuration(Duration.ofSeconds(30)) + .setMaxRpcTimeoutDuration(Duration.ofSeconds(60)) + .setRetryDelayMultiplier(1.3) + .setRpcTimeoutMultiplier(1.5) + .setTotalTimeoutDuration(Duration.ofSeconds(300)) + .build()); + AgentAnomalyDetectionServiceSettings agentAnomalyDetectionServiceSettings = + agentAnomalyDetectionServiceSettingsBuilder.build(); + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionServiceSettings_GetAgentAnomalyDetectionScope_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/stub/agentanomalydetectionservicestubsettings/enablemonitoredagent/SyncEnableMonitoredAgent.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/stub/agentanomalydetectionservicestubsettings/enablemonitoredagent/SyncEnableMonitoredAgent.java new file mode 100644 index 000000000000..07636f190de5 --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/stub/agentanomalydetectionservicestubsettings/enablemonitoredagent/SyncEnableMonitoredAgent.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.stub.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionServiceStubSettings_EnableMonitoredAgent_sync] +import com.google.api.gax.longrunning.OperationalTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.retrying.TimedRetryAlgorithm; +import com.google.cloud.aiplatform.v1.stub.AgentAnomalyDetectionServiceStubSettings; +import java.time.Duration; + +public class SyncEnableMonitoredAgent { + + public static void main(String[] args) throws Exception { + syncEnableMonitoredAgent(); + } + + public static void syncEnableMonitoredAgent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + AgentAnomalyDetectionServiceStubSettings.Builder agentAnomalyDetectionServiceSettingsBuilder = + AgentAnomalyDetectionServiceStubSettings.newBuilder(); + TimedRetryAlgorithm timedRetryAlgorithm = + OperationalTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(500)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(5000)) + .setTotalTimeoutDuration(Duration.ofHours(24)) + .build()); + agentAnomalyDetectionServiceSettingsBuilder + .createClusterOperationSettings() + .setPollingAlgorithm(timedRetryAlgorithm) + .build(); + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionServiceStubSettings_EnableMonitoredAgent_sync] diff --git a/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/stub/agentanomalydetectionservicestubsettings/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScope.java b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/stub/agentanomalydetectionservicestubsettings/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScope.java new file mode 100644 index 000000000000..9e1fe2e7992a --- /dev/null +++ b/java-aiplatform/samples/snippets/generated/com/google/cloud/aiplatform/v1/stub/agentanomalydetectionservicestubsettings/getagentanomalydetectionscope/SyncGetAgentAnomalyDetectionScope.java @@ -0,0 +1,57 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.aiplatform.v1.stub.samples; + +// [START aiplatform_v1_generated_AgentAnomalyDetectionServiceStubSettings_GetAgentAnomalyDetectionScope_sync] +import com.google.cloud.aiplatform.v1.stub.AgentAnomalyDetectionServiceStubSettings; +import java.time.Duration; + +public class SyncGetAgentAnomalyDetectionScope { + + public static void main(String[] args) throws Exception { + syncGetAgentAnomalyDetectionScope(); + } + + public static void syncGetAgentAnomalyDetectionScope() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + AgentAnomalyDetectionServiceStubSettings.Builder agentAnomalyDetectionServiceSettingsBuilder = + AgentAnomalyDetectionServiceStubSettings.newBuilder(); + agentAnomalyDetectionServiceSettingsBuilder + .getAgentAnomalyDetectionScopeSettings() + .setRetrySettings( + agentAnomalyDetectionServiceSettingsBuilder + .getAgentAnomalyDetectionScopeSettings() + .getRetrySettings() + .toBuilder() + .setInitialRetryDelayDuration(Duration.ofSeconds(1)) + .setInitialRpcTimeoutDuration(Duration.ofSeconds(5)) + .setMaxAttempts(5) + .setMaxRetryDelayDuration(Duration.ofSeconds(30)) + .setMaxRpcTimeoutDuration(Duration.ofSeconds(60)) + .setRetryDelayMultiplier(1.3) + .setRpcTimeoutMultiplier(1.5) + .setTotalTimeoutDuration(Duration.ofSeconds(300)) + .build()); + AgentAnomalyDetectionServiceStubSettings agentAnomalyDetectionServiceSettings = + agentAnomalyDetectionServiceSettingsBuilder.build(); + } +} +// [END aiplatform_v1_generated_AgentAnomalyDetectionServiceStubSettings_GetAgentAnomalyDetectionScope_sync] diff --git a/java-alloydb-connectors/README.md b/java-alloydb-connectors/README.md index ae5c4460cdfd..fd70bc21206e 100644 --- a/java-alloydb-connectors/README.md +++ b/java-alloydb-connectors/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-alloydb-connectors - 0.80.0 + 0.81.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-alloydb-connectors' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-alloydb-connectors:0.80.0' +implementation 'com.google.cloud:google-cloud-alloydb-connectors:0.81.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-alloydb-connectors" % "0.80.0" +libraryDependencies += "com.google.cloud" % "google-cloud-alloydb-connectors" % "0.81.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-alloydb-connectors/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-alloydb-connectors.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-alloydb-connectors/0.80.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-alloydb-connectors/0.81.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-alloydb/README.md b/java-alloydb/README.md index 21d12dd0399e..782231dc7269 100644 --- a/java-alloydb/README.md +++ b/java-alloydb/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-alloydb - 0.91.0 + 0.92.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-alloydb' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-alloydb:0.91.0' +implementation 'com.google.cloud:google-cloud-alloydb:0.92.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-alloydb" % "0.91.0" +libraryDependencies += "com.google.cloud" % "google-cloud-alloydb" % "0.92.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-alloydb/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-alloydb.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-alloydb/0.91.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-alloydb/0.92.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-analytics-admin/README.md b/java-analytics-admin/README.md index f17ca602cf2c..ca16a8ede4b8 100644 --- a/java-analytics-admin/README.md +++ b/java-analytics-admin/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.analytics google-analytics-admin - 0.112.0 + 0.113.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.analytics:google-analytics-admin' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.analytics:google-analytics-admin:0.112.0' +implementation 'com.google.analytics:google-analytics-admin:0.113.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.analytics" % "google-analytics-admin" % "0.112.0" +libraryDependencies += "com.google.analytics" % "google-analytics-admin" % "0.113.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-analytics-admin/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.analytics/google-analytics-admin.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.analytics/google-analytics-admin/0.112.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.analytics/google-analytics-admin/0.113.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-analytics-data/README.md b/java-analytics-data/README.md index 6a33e1be547f..c9d522897b47 100644 --- a/java-analytics-data/README.md +++ b/java-analytics-data/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.analytics google-analytics-data - 0.113.0 + 0.114.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.analytics:google-analytics-data' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.analytics:google-analytics-data:0.113.0' +implementation 'com.google.analytics:google-analytics-data:0.114.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.analytics" % "google-analytics-data" % "0.113.0" +libraryDependencies += "com.google.analytics" % "google-analytics-data" % "0.114.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-analytics-data/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.analytics/google-analytics-data.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.analytics/google-analytics-data/0.113.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.analytics/google-analytics-data/0.114.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-analyticshub/README.md b/java-analyticshub/README.md index f86d1d46d267..4c5469ced856 100644 --- a/java-analyticshub/README.md +++ b/java-analyticshub/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-analyticshub - 0.99.0 + 0.100.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-analyticshub' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-analyticshub:0.99.0' +implementation 'com.google.cloud:google-cloud-analyticshub:0.100.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-analyticshub" % "0.99.0" +libraryDependencies += "com.google.cloud" % "google-cloud-analyticshub" % "0.100.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-analyticshub/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-analyticshub.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-analyticshub/0.99.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-analyticshub/0.100.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-api-gateway/README.md b/java-api-gateway/README.md index 3b8e384775fc..5a58332abfdc 100644 --- a/java-api-gateway/README.md +++ b/java-api-gateway/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-api-gateway - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-api-gateway' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-api-gateway:2.102.0' +implementation 'com.google.cloud:google-cloud-api-gateway:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-api-gateway" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-api-gateway" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-api-gateway/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-api-gateway.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-api-gateway/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-api-gateway/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-apigee-connect/README.md b/java-apigee-connect/README.md index 9e8ce1af783d..6bf25a17426a 100644 --- a/java-apigee-connect/README.md +++ b/java-apigee-connect/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-apigee-connect - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-apigee-connect' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-apigee-connect:2.102.0' +implementation 'com.google.cloud:google-cloud-apigee-connect:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-apigee-connect" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-apigee-connect" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-apigee-connect/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-apigee-connect.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-apigee-connect/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-apigee-connect/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-apihub/README.md b/java-apihub/README.md index 896567b3892b..f780b464b79c 100644 --- a/java-apihub/README.md +++ b/java-apihub/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-apihub - 0.55.0 + 0.56.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-apihub' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-apihub:0.55.0' +implementation 'com.google.cloud:google-cloud-apihub:0.56.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-apihub" % "0.55.0" +libraryDependencies += "com.google.cloud" % "google-cloud-apihub" % "0.56.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-apihub/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-apihub.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-apihub/0.55.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-apihub/0.56.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubAddonClient.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubAddonClient.java new file mode 100644 index 000000000000..3e69663ee4b9 --- /dev/null +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubAddonClient.java @@ -0,0 +1,1073 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1; + +import com.google.api.core.ApiFuture; +import com.google.api.core.ApiFutures; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.httpjson.longrunning.OperationsClient; +import com.google.api.gax.longrunning.OperationFuture; +import com.google.api.gax.paging.AbstractFixedSizeCollection; +import com.google.api.gax.paging.AbstractPage; +import com.google.api.gax.paging.AbstractPagedListResponse; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.apihub.v1.stub.ApiHubAddonStub; +import com.google.cloud.apihub.v1.stub.ApiHubAddonStubSettings; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.util.concurrent.MoreExecutors; +import com.google.longrunning.Operation; +import java.io.IOException; +import java.util.List; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Service Description: This service is used for managing addons inside the API Hub. + * + *

This class provides the ability to make remote calls to the backing service through method + * calls that map to API methods. Sample code to get started: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+ *   AddonName name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]");
+ *   Addon response = apiHubAddonClient.getAddon(name);
+ * }
+ * }
+ * + *

Note: close() needs to be called on the ApiHubAddonClient object to clean up resources such as + * threads. In the example above, try-with-resources is used, which automatically calls close(). + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Methods
MethodDescriptionMethod Variants

GetAddon

Get an addon.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • getAddon(GetAddonRequest request) + *

+ *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ *
    + *
  • getAddon(AddonName name) + *

  • getAddon(String name) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • getAddonCallable() + *

+ *

ManageAddonConfig

Manage addon config. This RPC is used for managing the config of the addon. Calling this RPC moves the addon into an updating state until the long-running operation succeeds.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • manageAddonConfigAsync(ManageAddonConfigRequest request) + *

+ *

Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

+ *
    + *
  • manageAddonConfigAsync(AddonName name, AddonConfig config) + *

  • manageAddonConfigAsync(String name, AddonConfig config) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • manageAddonConfigOperationCallable() + *

  • manageAddonConfigCallable() + *

+ *

ListAddons

List addons.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • listAddons(ListAddonsRequest request) + *

+ *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ *
    + *
  • listAddons(LocationName parent) + *

  • listAddons(String parent) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • listAddonsPagedCallable() + *

  • listAddonsCallable() + *

+ *

ListLocations

Lists information about the supported locations for this service. + *

This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • listLocations(ListLocationsRequest request) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • listLocationsPagedCallable() + *

  • listLocationsCallable() + *

+ *

GetLocation

Gets information about a location.

+ *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ *
    + *
  • getLocation(GetLocationRequest request) + *

+ *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ *
    + *
  • getLocationCallable() + *

+ *
+ * + *

See the individual methods for example code. + * + *

Many parameters require resource names to be formatted in a particular way. To assist with + * these names, this class includes a format method for each type of name, and additionally a parse + * method to extract the individual identifiers contained within names that are returned. + * + *

This class can be customized by passing in a custom instance of ApiHubAddonSettings to + * create(). For example: + * + *

To customize credentials: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * ApiHubAddonSettings apiHubAddonSettings =
+ *     ApiHubAddonSettings.newBuilder()
+ *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ *         .build();
+ * ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create(apiHubAddonSettings);
+ * }
+ * + *

To customize the endpoint: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * ApiHubAddonSettings apiHubAddonSettings =
+ *     ApiHubAddonSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create(apiHubAddonSettings);
+ * }
+ * + *

Please refer to the GitHub repository's samples for more quickstart code snippets. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class ApiHubAddonClient implements BackgroundResource { + private final @Nullable ApiHubAddonSettings settings; + private final ApiHubAddonStub stub; + private final OperationsClient httpJsonOperationsClient; + + /** Constructs an instance of ApiHubAddonClient with default settings. */ + public static final ApiHubAddonClient create() throws IOException { + return create(ApiHubAddonSettings.newBuilder().build()); + } + + /** + * Constructs an instance of ApiHubAddonClient, using the given settings. The channels are created + * based on the settings passed in, or defaults for any settings that are not set. + */ + public static final ApiHubAddonClient create(ApiHubAddonSettings settings) throws IOException { + return new ApiHubAddonClient(settings); + } + + /** + * Constructs an instance of ApiHubAddonClient, using the given stub for making calls. This is for + * advanced usage - prefer using create(ApiHubAddonSettings). + */ + public static final ApiHubAddonClient create(ApiHubAddonStub stub) { + return new ApiHubAddonClient(stub); + } + + /** + * Constructs an instance of ApiHubAddonClient, using the given settings. This is protected so + * that it is easy to make a subclass, but otherwise, the static factory methods should be + * preferred. + */ + protected ApiHubAddonClient(ApiHubAddonSettings settings) throws IOException { + this.settings = settings; + this.stub = ((ApiHubAddonStubSettings) settings.getStubSettings()).createStub(); + this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); + } + + protected ApiHubAddonClient(ApiHubAddonStub stub) { + this.settings = null; + this.stub = stub; + this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); + } + + public final @Nullable ApiHubAddonSettings getSettings() { + return settings; + } + + public ApiHubAddonStub getStub() { + return stub; + } + + /** + * Returns the OperationsClient that can be used to query the status of a long-running operation + * returned by another API method call. + */ + public final OperationsClient getHttpJsonOperationsClient() { + return httpJsonOperationsClient; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get an addon. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   AddonName name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]");
+   *   Addon response = apiHubAddonClient.getAddon(name);
+   * }
+   * }
+ * + * @param name Required. The name of the addon to get. Format: + * `projects/{project}/locations/{location}/addons/{addon}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Addon getAddon(@Nullable AddonName name) { + GetAddonRequest request = + GetAddonRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getAddon(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get an addon. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   String name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString();
+   *   Addon response = apiHubAddonClient.getAddon(name);
+   * }
+   * }
+ * + * @param name Required. The name of the addon to get. Format: + * `projects/{project}/locations/{location}/addons/{addon}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Addon getAddon(String name) { + GetAddonRequest request = GetAddonRequest.newBuilder().setName(name).build(); + return getAddon(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get an addon. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   GetAddonRequest request =
+   *       GetAddonRequest.newBuilder()
+   *           .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString())
+   *           .build();
+   *   Addon response = apiHubAddonClient.getAddon(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Addon getAddon(GetAddonRequest request) { + return getAddonCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get an addon. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   GetAddonRequest request =
+   *       GetAddonRequest.newBuilder()
+   *           .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString())
+   *           .build();
+   *   ApiFuture future = apiHubAddonClient.getAddonCallable().futureCall(request);
+   *   // Do something.
+   *   Addon response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getAddonCallable() { + return stub.getAddonCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Manage addon config. This RPC is used for managing the config of the addon. Calling this RPC + * moves the addon into an updating state until the long-running operation succeeds. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   AddonName name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]");
+   *   AddonConfig config = AddonConfig.newBuilder().build();
+   *   Addon response = apiHubAddonClient.manageAddonConfigAsync(name, config).get();
+   * }
+   * }
+ * + * @param name Required. The name of the addon for which the config is to be managed. Format: + * `projects/{project}/locations/{location}/addons/{addon}`. + * @param config Required. The config of the addon to be managed. This config will replace the + * config present in the addon. The type of the config should match the config type already + * present in the addon. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture manageAddonConfigAsync( + @Nullable AddonName name, AddonConfig config) { + ManageAddonConfigRequest request = + ManageAddonConfigRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .setConfig(config) + .build(); + return manageAddonConfigAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Manage addon config. This RPC is used for managing the config of the addon. Calling this RPC + * moves the addon into an updating state until the long-running operation succeeds. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   String name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString();
+   *   AddonConfig config = AddonConfig.newBuilder().build();
+   *   Addon response = apiHubAddonClient.manageAddonConfigAsync(name, config).get();
+   * }
+   * }
+ * + * @param name Required. The name of the addon for which the config is to be managed. Format: + * `projects/{project}/locations/{location}/addons/{addon}`. + * @param config Required. The config of the addon to be managed. This config will replace the + * config present in the addon. The type of the config should match the config type already + * present in the addon. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture manageAddonConfigAsync( + String name, AddonConfig config) { + ManageAddonConfigRequest request = + ManageAddonConfigRequest.newBuilder().setName(name).setConfig(config).build(); + return manageAddonConfigAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Manage addon config. This RPC is used for managing the config of the addon. Calling this RPC + * moves the addon into an updating state until the long-running operation succeeds. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   ManageAddonConfigRequest request =
+   *       ManageAddonConfigRequest.newBuilder()
+   *           .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString())
+   *           .setConfig(AddonConfig.newBuilder().build())
+   *           .build();
+   *   Addon response = apiHubAddonClient.manageAddonConfigAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture manageAddonConfigAsync( + ManageAddonConfigRequest request) { + return manageAddonConfigOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Manage addon config. This RPC is used for managing the config of the addon. Calling this RPC + * moves the addon into an updating state until the long-running operation succeeds. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   ManageAddonConfigRequest request =
+   *       ManageAddonConfigRequest.newBuilder()
+   *           .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString())
+   *           .setConfig(AddonConfig.newBuilder().build())
+   *           .build();
+   *   OperationFuture future =
+   *       apiHubAddonClient.manageAddonConfigOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Addon response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + manageAddonConfigOperationCallable() { + return stub.manageAddonConfigOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Manage addon config. This RPC is used for managing the config of the addon. Calling this RPC + * moves the addon into an updating state until the long-running operation succeeds. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   ManageAddonConfigRequest request =
+   *       ManageAddonConfigRequest.newBuilder()
+   *           .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString())
+   *           .setConfig(AddonConfig.newBuilder().build())
+   *           .build();
+   *   ApiFuture future =
+   *       apiHubAddonClient.manageAddonConfigCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable manageAddonConfigCallable() { + return stub.manageAddonConfigCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List addons. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Addon element : apiHubAddonClient.listAddons(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent resource where this addon will be created. Format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAddonsPagedResponse listAddons(@Nullable LocationName parent) { + ListAddonsRequest request = + ListAddonsRequest.newBuilder().setParent(parent == null ? null : parent.toString()).build(); + return listAddons(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List addons. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Addon element : apiHubAddonClient.listAddons(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent resource where this addon will be created. Format: + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAddonsPagedResponse listAddons(String parent) { + ListAddonsRequest request = ListAddonsRequest.newBuilder().setParent(parent).build(); + return listAddons(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List addons. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   ListAddonsRequest request =
+   *       ListAddonsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (Addon element : apiHubAddonClient.listAddons(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListAddonsPagedResponse listAddons(ListAddonsRequest request) { + return listAddonsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List addons. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   ListAddonsRequest request =
+   *       ListAddonsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future = apiHubAddonClient.listAddonsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Addon element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listAddonsPagedCallable() { + return stub.listAddonsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List addons. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   ListAddonsRequest request =
+   *       ListAddonsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     ListAddonsResponse response = apiHubAddonClient.listAddonsCallable().call(request);
+   *     for (Addon element : response.getAddonsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listAddonsCallable() { + return stub.listAddonsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (Location element : apiHubAddonClient.listLocations(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListLocationsPagedResponse listLocations(ListLocationsRequest request) { + return listLocationsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future =
+   *       apiHubAddonClient.listLocationsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Location element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listLocationsPagedCallable() { + return stub.listLocationsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     ListLocationsResponse response = apiHubAddonClient.listLocationsCallable().call(request);
+   *     for (Location element : response.getLocationsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listLocationsCallable() { + return stub.listLocationsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets information about a location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
+   *   Location response = apiHubAddonClient.getLocation(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Location getLocation(GetLocationRequest request) { + return getLocationCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets information about a location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
+   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
+   *   ApiFuture future = apiHubAddonClient.getLocationCallable().futureCall(request);
+   *   // Do something.
+   *   Location response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getLocationCallable() { + return stub.getLocationCallable(); + } + + @Override + public final void close() { + stub.close(); + } + + @Override + public void shutdown() { + stub.shutdown(); + } + + @Override + public boolean isShutdown() { + return stub.isShutdown(); + } + + @Override + public boolean isTerminated() { + return stub.isTerminated(); + } + + @Override + public void shutdownNow() { + stub.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return stub.awaitTermination(duration, unit); + } + + public static class ListAddonsPagedResponse + extends AbstractPagedListResponse< + ListAddonsRequest, + ListAddonsResponse, + Addon, + ListAddonsPage, + ListAddonsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListAddonsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, input -> new ListAddonsPagedResponse(input), MoreExecutors.directExecutor()); + } + + private ListAddonsPagedResponse(ListAddonsPage page) { + super(page, ListAddonsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListAddonsPage + extends AbstractPage { + + private ListAddonsPage( + @Nullable PageContext context, + @Nullable ListAddonsResponse response) { + super(context, response); + } + + private static ListAddonsPage createEmptyPage() { + return new ListAddonsPage(null, null); + } + + @Override + protected ListAddonsPage createPage( + @Nullable PageContext context, + @Nullable ListAddonsResponse response) { + return new ListAddonsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListAddonsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListAddonsRequest, + ListAddonsResponse, + Addon, + ListAddonsPage, + ListAddonsFixedSizeCollection> { + + private ListAddonsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListAddonsFixedSizeCollection createEmptyCollection() { + return new ListAddonsFixedSizeCollection(null, 0); + } + + @Override + protected ListAddonsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListAddonsFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListLocationsPagedResponse + extends AbstractPagedListResponse< + ListLocationsRequest, + ListLocationsResponse, + Location, + ListLocationsPage, + ListLocationsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListLocationsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListLocationsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListLocationsPagedResponse(ListLocationsPage page) { + super(page, ListLocationsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListLocationsPage + extends AbstractPage< + ListLocationsRequest, ListLocationsResponse, Location, ListLocationsPage> { + + private ListLocationsPage( + @Nullable PageContext context, + @Nullable ListLocationsResponse response) { + super(context, response); + } + + private static ListLocationsPage createEmptyPage() { + return new ListLocationsPage(null, null); + } + + @Override + protected ListLocationsPage createPage( + @Nullable PageContext context, + @Nullable ListLocationsResponse response) { + return new ListLocationsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListLocationsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListLocationsRequest, + ListLocationsResponse, + Location, + ListLocationsPage, + ListLocationsFixedSizeCollection> { + + private ListLocationsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListLocationsFixedSizeCollection createEmptyCollection() { + return new ListLocationsFixedSizeCollection(null, 0); + } + + @Override + protected ListLocationsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListLocationsFixedSizeCollection(pages, collectionSize); + } + } +} diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubAddonSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubAddonSettings.java new file mode 100644 index 000000000000..3d668d3e3538 --- /dev/null +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubAddonSettings.java @@ -0,0 +1,292 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1; + +import static com.google.cloud.apihub.v1.ApiHubAddonClient.ListAddonsPagedResponse; +import static com.google.cloud.apihub.v1.ApiHubAddonClient.ListLocationsPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.httpjson.InstantiatingHttpJsonChannelProvider; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientSettings; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.cloud.apihub.v1.stub.ApiHubAddonStubSettings; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.longrunning.Operation; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link ApiHubAddonClient}. + * + *

The default instance has everything set to sensible defaults: + * + *

    + *
  • The default service address (apihub.googleapis.com) and default port (443) are used. + *
  • Credentials are acquired automatically through Application Default Credentials. + *
  • Retries are configured for idempotent methods but not for non-idempotent methods. + *
+ * + *

The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. + * + *

For example, to set the + * [RetrySettings](https://cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.retrying.RetrySettings) + * of getAddon: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * ApiHubAddonSettings.Builder apiHubAddonSettingsBuilder = ApiHubAddonSettings.newBuilder();
+ * apiHubAddonSettingsBuilder
+ *     .getAddonSettings()
+ *     .setRetrySettings(
+ *         apiHubAddonSettingsBuilder
+ *             .getAddonSettings()
+ *             .getRetrySettings()
+ *             .toBuilder()
+ *             .setInitialRetryDelayDuration(Duration.ofSeconds(1))
+ *             .setInitialRpcTimeoutDuration(Duration.ofSeconds(5))
+ *             .setMaxAttempts(5)
+ *             .setMaxRetryDelayDuration(Duration.ofSeconds(30))
+ *             .setMaxRpcTimeoutDuration(Duration.ofSeconds(60))
+ *             .setRetryDelayMultiplier(1.3)
+ *             .setRpcTimeoutMultiplier(1.5)
+ *             .setTotalTimeoutDuration(Duration.ofSeconds(300))
+ *             .build());
+ * ApiHubAddonSettings apiHubAddonSettings = apiHubAddonSettingsBuilder.build();
+ * }
+ * + * Please refer to the [Client Side Retry + * Guide](https://docs.cloud.google.com/java/docs/client-retries) for additional support in setting + * retries. + * + *

To configure the RetrySettings of a Long Running Operation method, create an + * OperationTimedPollAlgorithm object and update the RPC's polling algorithm. For example, to + * configure the RetrySettings for manageAddonConfig: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * ApiHubAddonSettings.Builder apiHubAddonSettingsBuilder = ApiHubAddonSettings.newBuilder();
+ * TimedRetryAlgorithm timedRetryAlgorithm =
+ *     OperationalTimedPollAlgorithm.create(
+ *         RetrySettings.newBuilder()
+ *             .setInitialRetryDelayDuration(Duration.ofMillis(500))
+ *             .setRetryDelayMultiplier(1.5)
+ *             .setMaxRetryDelayDuration(Duration.ofMillis(5000))
+ *             .setTotalTimeoutDuration(Duration.ofHours(24))
+ *             .build());
+ * apiHubAddonSettingsBuilder
+ *     .createClusterOperationSettings()
+ *     .setPollingAlgorithm(timedRetryAlgorithm)
+ *     .build();
+ * }
+ */ +@NullMarked +@Generated("by gapic-generator-java") +public class ApiHubAddonSettings extends ClientSettings { + + /** Returns the object with the settings used for calls to getAddon. */ + public UnaryCallSettings getAddonSettings() { + return ((ApiHubAddonStubSettings) getStubSettings()).getAddonSettings(); + } + + /** Returns the object with the settings used for calls to manageAddonConfig. */ + public UnaryCallSettings manageAddonConfigSettings() { + return ((ApiHubAddonStubSettings) getStubSettings()).manageAddonConfigSettings(); + } + + /** Returns the object with the settings used for calls to manageAddonConfig. */ + public OperationCallSettings + manageAddonConfigOperationSettings() { + return ((ApiHubAddonStubSettings) getStubSettings()).manageAddonConfigOperationSettings(); + } + + /** Returns the object with the settings used for calls to listAddons. */ + public PagedCallSettings + listAddonsSettings() { + return ((ApiHubAddonStubSettings) getStubSettings()).listAddonsSettings(); + } + + /** Returns the object with the settings used for calls to listLocations. */ + public PagedCallSettings + listLocationsSettings() { + return ((ApiHubAddonStubSettings) getStubSettings()).listLocationsSettings(); + } + + /** Returns the object with the settings used for calls to getLocation. */ + public UnaryCallSettings getLocationSettings() { + return ((ApiHubAddonStubSettings) getStubSettings()).getLocationSettings(); + } + + public static final ApiHubAddonSettings create(ApiHubAddonStubSettings stub) throws IOException { + return new ApiHubAddonSettings.Builder(stub.toBuilder()).build(); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return ApiHubAddonStubSettings.defaultExecutorProviderBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return ApiHubAddonStubSettings.getDefaultEndpoint(); + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return ApiHubAddonStubSettings.getDefaultServiceScopes(); + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return ApiHubAddonStubSettings.defaultCredentialsProviderBuilder(); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingHttpJsonChannelProvider.Builder + defaultHttpJsonTransportProviderBuilder() { + return ApiHubAddonStubSettings.defaultHttpJsonTransportProviderBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return ApiHubAddonStubSettings.defaultTransportChannelProvider(); + } + + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return ApiHubAddonStubSettings.defaultApiClientHeaderProviderBuilder(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(@Nullable ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected ApiHubAddonSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + } + + /** Builder for ApiHubAddonSettings. */ + public static class Builder extends ClientSettings.Builder { + + protected Builder() throws IOException { + this(((ClientContext) null)); + } + + protected Builder(@Nullable ClientContext clientContext) { + super(ApiHubAddonStubSettings.newBuilder(clientContext)); + } + + protected Builder(ApiHubAddonSettings settings) { + super(settings.getStubSettings().toBuilder()); + } + + protected Builder(ApiHubAddonStubSettings.Builder stubSettings) { + super(stubSettings); + } + + private static Builder createDefault() { + return new Builder(ApiHubAddonStubSettings.newBuilder()); + } + + public ApiHubAddonStubSettings.Builder getStubSettingsBuilder() { + return ((ApiHubAddonStubSettings.Builder) getStubSettings()); + } + + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) { + super.applyToAllUnaryMethods( + getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); + return this; + } + + /** Returns the builder for the settings used for calls to getAddon. */ + public UnaryCallSettings.Builder getAddonSettings() { + return getStubSettingsBuilder().getAddonSettings(); + } + + /** Returns the builder for the settings used for calls to manageAddonConfig. */ + public UnaryCallSettings.Builder + manageAddonConfigSettings() { + return getStubSettingsBuilder().manageAddonConfigSettings(); + } + + /** Returns the builder for the settings used for calls to manageAddonConfig. */ + public OperationCallSettings.Builder + manageAddonConfigOperationSettings() { + return getStubSettingsBuilder().manageAddonConfigOperationSettings(); + } + + /** Returns the builder for the settings used for calls to listAddons. */ + public PagedCallSettings.Builder + listAddonsSettings() { + return getStubSettingsBuilder().listAddonsSettings(); + } + + /** Returns the builder for the settings used for calls to listLocations. */ + public PagedCallSettings.Builder< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings() { + return getStubSettingsBuilder().listLocationsSettings(); + } + + /** Returns the builder for the settings used for calls to getLocation. */ + public UnaryCallSettings.Builder getLocationSettings() { + return getStubSettingsBuilder().getLocationSettings(); + } + + @Override + public ApiHubAddonSettings build() throws IOException { + return new ApiHubAddonSettings(this); + } + } +} diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubClient.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubClient.java index 2a3269f73ab0..aea1a549feff 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubClient.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubClient.java @@ -19,9 +19,12 @@ import com.google.api.core.ApiFuture; import com.google.api.core.ApiFutures; import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.httpjson.longrunning.OperationsClient; +import com.google.api.gax.longrunning.OperationFuture; import com.google.api.gax.paging.AbstractFixedSizeCollection; import com.google.api.gax.paging.AbstractPage; import com.google.api.gax.paging.AbstractPagedListResponse; +import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.PageContext; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.apihub.v1.stub.ApiHubStub; @@ -31,6 +34,7 @@ import com.google.cloud.location.ListLocationsResponse; import com.google.cloud.location.Location; import com.google.common.util.concurrent.MoreExecutors; +import com.google.longrunning.Operation; import com.google.protobuf.Empty; import com.google.protobuf.FieldMask; import java.io.IOException; @@ -143,6 +147,7 @@ *

  • [maturity_level][google.cloud.apihub.v1.Api.maturity_level] *
  • [api_style][google.cloud.apihub.v1.Api.api_style] *
  • [attributes][google.cloud.apihub.v1.Api.attributes] + *
  • [fingerprint][google.cloud.apihub.v1.Api.fingerprint] * *

    The [update_mask][google.cloud.apihub.v1.UpdateApiRequest.update_mask] should be used to specify the fields being updated. *

    Updating the owner field requires complete owner message and updates both owner and email fields. @@ -346,6 +351,25 @@ * * * + *

    FetchAdditionalSpecContent + *

    Fetch additional spec content. + * + *

    Request object method variants only take one parameter, a request object, which must be constructed before the call.

    + *
      + *
    • fetchAdditionalSpecContent(FetchAdditionalSpecContentRequest request) + *

    + *

    "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

    + *
      + *
    • fetchAdditionalSpecContent(SpecName name, SpecContentType specContentType) + *

    • fetchAdditionalSpecContent(String name, SpecContentType specContentType) + *

    + *

    Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

    + *
      + *
    • fetchAdditionalSpecContentCallable() + *

    + * + * + * *

    ListSpecs *

    List specs corresponding to a particular API resource. * @@ -396,7 +420,7 @@ * * *

    DeleteSpec - *

    Delete a spec. Deleting a spec will also delete the associated operations from the version. + *

    Delete a spec. Deleting a spec will also delete the associated operations from the version and remove any links between the spec and deployments. * *

    Request object method variants only take one parameter, a request object, which must be constructed before the call.

    *
      @@ -481,6 +505,18 @@ *
    • [details.http_operation.method][ApiOperation.details.http_operation.method] *
    • [details.deprecated][ApiOperation.details.deprecated] *
    • [attributes][google.cloud.apihub.v1.ApiOperation.attributes] + *
    • [details.mcp_tool.title][ApiOperation.details.mcp_tool.title] + *
    • [details.mcp_tool.description][ApiOperation.details.mcp_tool.description] + *
    • [details.mcp_tool.input_schema][ApiOperation.details.mcp_tool.input_schema] + *
    • [details.mcp_tool.output_schema][ApiOperation.details.mcp_tool.output_schema] + *
    • [details.input_schema][ApiOperation.details.input_schema] + *
    • [details.output_schema][ApiOperation.details.output_schema] + *
    • [details.mcp_tool.annotations.title][ApiOperation.details.mcp_tool.annotations.title] + *
    • [details.mcp_tool.annotations.read_only_hint][ApiOperation.details.mcp_tool.annotations.read_only_hint] + *
    • [details.mcp_tool.annotations.destructive_hint][ApiOperation.details.mcp_tool.annotations.destructive_hint] + *
    • [details.mcp_tool.annotations.idempotent_hint][ApiOperation.details.mcp_tool.annotations.idempotent_hint] + *
    • [details.mcp_tool.annotations.open_world_hint][ApiOperation.details.mcp_tool.annotations.open_world_hint] + *
    • [details.mcp_tool.annotations.additional_hints][ApiOperation.details.mcp_tool.annotations.additional_hints] *
    *

    The [update_mask][google.cloud.apihub.v1.UpdateApiOperationRequest.update_mask] should be used to specify the fields being updated. *

    An operation can be updated only if the operation was created via [CreateApiOperation][google.cloud.apihub.v1.ApiHub.CreateApiOperation] API. If the operation was created by parsing the spec, then it can be edited by updating the spec. @@ -501,7 +537,7 @@ * * *

    DeleteApiOperation - *

    Delete an operation in an API version and we can delete only the operations created via create API. If the operation was created by parsing the spec, then it can be deleted by editing or deleting the spec. + *

    Delete an operation in an API version and we can delete only the operations created via create API. If the operation was created by parsing the spec, then it can be deleted by editing or deleting the spec. Deleting an operation will also remove any links between the operation and deployments. * *

    Request object method variants only take one parameter, a request object, which must be constructed before the call.

    *
      @@ -630,7 +666,7 @@ * * *

      DeleteDeployment - *

      Delete a deployment resource in the API hub. + *

      Deletes a deployment resource in the API hub. A deployment can only be deleted after its links to any versions, specs, and API operations have been removed. * *

      Request object method variants only take one parameter, a request object, which must be constructed before the call.

      *
        @@ -875,8 +911,50 @@ * * * + *

        RetrieveApiViews + *

        Retrieve API views. + * + *

        Request object method variants only take one parameter, a request object, which must be constructed before the call.

        + *
          + *
        • retrieveApiViews(RetrieveApiViewsRequest request) + *

        + *

        "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

        + *
          + *
        • retrieveApiViews(LocationName parent, ApiViewType view) + *

        • retrieveApiViews(String parent, ApiViewType view) + *

        + *

        Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

        + *
          + *
        • retrieveApiViewsPagedCallable() + *

        • retrieveApiViewsCallable() + *

        + * + * + * + *

        ConfigureAndDeployServer + *

        Configures and deploys a given server config for given target. Currently this API supports only deploying MCP server in Apigee X. For mcp server deployment in apigee X, if there is already a mcp proxy deployed, then this method will try to overwrite it by creating new revision i.e. all existing tools will be removed and new set of tools will be deployed. + * + *

        Request object method variants only take one parameter, a request object, which must be constructed before the call.

        + *
          + *
        • configureAndDeployServerAsync(ConfigureAndDeployServerRequest request) + *

        + *

        Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

        + *
          + *
        • configureAndDeployServerAsync(LocationName parent, McpServerConfig mcpServerConfig) + *

        • configureAndDeployServerAsync(String parent, McpServerConfig mcpServerConfig) + *

        + *

        Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

        + *
          + *
        • configureAndDeployServerOperationCallable() + *

        • configureAndDeployServerCallable() + *

        + * + * + * *

        ListLocations - *

        Lists information about the supported locations for this service. + *

        Lists information about the supported locations for this service. + *

        This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

        For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. * *

        Request object method variants only take one parameter, a request object, which must be constructed before the call.

        *
          @@ -948,6 +1026,7 @@ public class ApiHubClient implements BackgroundResource { private final @Nullable ApiHubSettings settings; private final ApiHubStub stub; + private final OperationsClient httpJsonOperationsClient; /** Constructs an instance of ApiHubClient with default settings. */ public static final ApiHubClient create() throws IOException { @@ -977,11 +1056,13 @@ public static final ApiHubClient create(ApiHubStub stub) { protected ApiHubClient(ApiHubSettings settings) throws IOException { this.settings = settings; this.stub = ((ApiHubStubSettings) settings.getStubSettings()).createStub(); + this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); } protected ApiHubClient(ApiHubStub stub) { this.settings = null; this.stub = stub; + this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); } public final @Nullable ApiHubSettings getSettings() { @@ -992,6 +1073,14 @@ public ApiHubStub getStub() { return stub; } + /** + * Returns the OperationsClient that can be used to query the status of a long-running operation + * returned by another API method call. + */ + public final OperationsClient getHttpJsonOperationsClient() { + return httpJsonOperationsClient; + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Create an API resource in the API hub. Once an API resource is created, versions can be added @@ -1426,6 +1515,7 @@ public final UnaryCallable listApisCallable() *
        • [maturity_level][google.cloud.apihub.v1.Api.maturity_level] *
        • [api_style][google.cloud.apihub.v1.Api.api_style] *
        • [attributes][google.cloud.apihub.v1.Api.attributes] + *
        • [fingerprint][google.cloud.apihub.v1.Api.fingerprint] *
        * *

        The [update_mask][google.cloud.apihub.v1.UpdateApiRequest.update_mask] should be used to @@ -1477,6 +1567,7 @@ public final Api updateApi(Api api, FieldMask updateMask) { *

      • [maturity_level][google.cloud.apihub.v1.Api.maturity_level] *
      • [api_style][google.cloud.apihub.v1.Api.api_style] *
      • [attributes][google.cloud.apihub.v1.Api.attributes] + *
      • [fingerprint][google.cloud.apihub.v1.Api.fingerprint] *
      * *

      The [update_mask][google.cloud.apihub.v1.UpdateApiRequest.update_mask] should be used to @@ -1526,6 +1617,7 @@ public final Api updateApi(UpdateApiRequest request) { *

    • [maturity_level][google.cloud.apihub.v1.Api.maturity_level] *
    • [api_style][google.cloud.apihub.v1.Api.api_style] *
    • [attributes][google.cloud.apihub.v1.Api.attributes] + *
    • [fingerprint][google.cloud.apihub.v1.Api.fingerprint] *
    * *

    The [update_mask][google.cloud.apihub.v1.UpdateApiRequest.update_mask] should be used to @@ -2787,6 +2879,140 @@ public final UnaryCallable getSpecContents return stub.getSpecContentsCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetch additional spec content. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   SpecName name = SpecName.of("[PROJECT]", "[LOCATION]", "[API]", "[VERSION]", "[SPEC]");
    +   *   SpecContentType specContentType = SpecContentType.forNumber(0);
    +   *   FetchAdditionalSpecContentResponse response =
    +   *       apiHubClient.fetchAdditionalSpecContent(name, specContentType);
    +   * }
    +   * }
    + * + * @param name Required. The name of the spec whose contents need to be retrieved. Format: + * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}` + * @param specContentType Optional. The type of the spec contents to be retrieved. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final FetchAdditionalSpecContentResponse fetchAdditionalSpecContent( + @Nullable SpecName name, SpecContentType specContentType) { + FetchAdditionalSpecContentRequest request = + FetchAdditionalSpecContentRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .setSpecContentType(specContentType) + .build(); + return fetchAdditionalSpecContent(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetch additional spec content. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   String name =
    +   *       SpecName.of("[PROJECT]", "[LOCATION]", "[API]", "[VERSION]", "[SPEC]").toString();
    +   *   SpecContentType specContentType = SpecContentType.forNumber(0);
    +   *   FetchAdditionalSpecContentResponse response =
    +   *       apiHubClient.fetchAdditionalSpecContent(name, specContentType);
    +   * }
    +   * }
    + * + * @param name Required. The name of the spec whose contents need to be retrieved. Format: + * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}` + * @param specContentType Optional. The type of the spec contents to be retrieved. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final FetchAdditionalSpecContentResponse fetchAdditionalSpecContent( + String name, SpecContentType specContentType) { + FetchAdditionalSpecContentRequest request = + FetchAdditionalSpecContentRequest.newBuilder() + .setName(name) + .setSpecContentType(specContentType) + .build(); + return fetchAdditionalSpecContent(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetch additional spec content. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   FetchAdditionalSpecContentRequest request =
    +   *       FetchAdditionalSpecContentRequest.newBuilder()
    +   *           .setName(
    +   *               SpecName.of("[PROJECT]", "[LOCATION]", "[API]", "[VERSION]", "[SPEC]").toString())
    +   *           .setSpecContentType(SpecContentType.forNumber(0))
    +   *           .build();
    +   *   FetchAdditionalSpecContentResponse response =
    +   *       apiHubClient.fetchAdditionalSpecContent(request);
    +   * }
    +   * }
    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final FetchAdditionalSpecContentResponse fetchAdditionalSpecContent( + FetchAdditionalSpecContentRequest request) { + return fetchAdditionalSpecContentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Fetch additional spec content. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   FetchAdditionalSpecContentRequest request =
    +   *       FetchAdditionalSpecContentRequest.newBuilder()
    +   *           .setName(
    +   *               SpecName.of("[PROJECT]", "[LOCATION]", "[API]", "[VERSION]", "[SPEC]").toString())
    +   *           .setSpecContentType(SpecContentType.forNumber(0))
    +   *           .build();
    +   *   ApiFuture future =
    +   *       apiHubClient.fetchAdditionalSpecContentCallable().futureCall(request);
    +   *   // Do something.
    +   *   FetchAdditionalSpecContentResponse response = future.get();
    +   * }
    +   * }
    + */ + public final UnaryCallable + fetchAdditionalSpecContentCallable() { + return stub.fetchAdditionalSpecContentCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * List specs corresponding to a particular API resource. @@ -3100,7 +3326,8 @@ public final UnaryCallable updateSpecCallable() { // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Delete a spec. Deleting a spec will also delete the associated operations from the version. + * Delete a spec. Deleting a spec will also delete the associated operations from the version and + * remove any links between the spec and deployments. * *

    Sample code: * @@ -3128,7 +3355,8 @@ public final void deleteSpec(@Nullable SpecName name) { // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Delete a spec. Deleting a spec will also delete the associated operations from the version. + * Delete a spec. Deleting a spec will also delete the associated operations from the version and + * remove any links between the spec and deployments. * *

    Sample code: * @@ -3156,7 +3384,8 @@ public final void deleteSpec(String name) { // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Delete a spec. Deleting a spec will also delete the associated operations from the version. + * Delete a spec. Deleting a spec will also delete the associated operations from the version and + * remove any links between the spec and deployments. * *

    Sample code: * @@ -3185,7 +3414,8 @@ public final void deleteSpec(DeleteSpecRequest request) { // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Delete a spec. Deleting a spec will also delete the associated operations from the version. + * Delete a spec. Deleting a spec will also delete the associated operations from the version and + * remove any links between the spec and deployments. * *

    Sample code: * @@ -3244,7 +3474,7 @@ public final UnaryCallable deleteSpecCallable() { * *

    This value should be 4-500 characters, overall resource name which will be of format * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - * its length is limited to 700 characters, and valid characters are /[a-z][A-Z][0-9]-_/. + * its length is limited to 1000 characters, and valid characters are /[a-z][A-Z][0-9]-_/. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ApiOperation createApiOperation( @@ -3291,7 +3521,7 @@ public final ApiOperation createApiOperation( * *

    This value should be 4-500 characters, overall resource name which will be of format * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - * its length is limited to 700 characters, and valid characters are /[a-z][A-Z][0-9]-_/. + * its length is limited to 1000 characters, and valid characters are /[a-z][A-Z][0-9]-_/. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ApiOperation createApiOperation( @@ -3667,6 +3897,18 @@ public final ListApiOperationsPagedResponse listApiOperations(ListApiOperationsR *

  • [details.http_operation.method][ApiOperation.details.http_operation.method] *
  • [details.deprecated][ApiOperation.details.deprecated] *
  • [attributes][google.cloud.apihub.v1.ApiOperation.attributes] + *
  • [details.mcp_tool.title][ApiOperation.details.mcp_tool.title] + *
  • [details.mcp_tool.description][ApiOperation.details.mcp_tool.description] + *
  • [details.mcp_tool.input_schema][ApiOperation.details.mcp_tool.input_schema] + *
  • [details.mcp_tool.output_schema][ApiOperation.details.mcp_tool.output_schema] + *
  • [details.input_schema][ApiOperation.details.input_schema] + *
  • [details.output_schema][ApiOperation.details.output_schema] + *
  • [details.mcp_tool.annotations.title][ApiOperation.details.mcp_tool.annotations.title] + *
  • [details.mcp_tool.annotations.read_only_hint][ApiOperation.details.mcp_tool.annotations.read_only_hint] + *
  • [details.mcp_tool.annotations.destructive_hint][ApiOperation.details.mcp_tool.annotations.destructive_hint] + *
  • [details.mcp_tool.annotations.idempotent_hint][ApiOperation.details.mcp_tool.annotations.idempotent_hint] + *
  • [details.mcp_tool.annotations.open_world_hint][ApiOperation.details.mcp_tool.annotations.open_world_hint] + *
  • [details.mcp_tool.annotations.additional_hints][ApiOperation.details.mcp_tool.annotations.additional_hints] * * *

    The [update_mask][google.cloud.apihub.v1.UpdateApiOperationRequest.update_mask] should be @@ -3719,6 +3961,18 @@ public final ApiOperation updateApiOperation(ApiOperation apiOperation, FieldMas *

  • [details.http_operation.method][ApiOperation.details.http_operation.method] *
  • [details.deprecated][ApiOperation.details.deprecated] *
  • [attributes][google.cloud.apihub.v1.ApiOperation.attributes] + *
  • [details.mcp_tool.title][ApiOperation.details.mcp_tool.title] + *
  • [details.mcp_tool.description][ApiOperation.details.mcp_tool.description] + *
  • [details.mcp_tool.input_schema][ApiOperation.details.mcp_tool.input_schema] + *
  • [details.mcp_tool.output_schema][ApiOperation.details.mcp_tool.output_schema] + *
  • [details.input_schema][ApiOperation.details.input_schema] + *
  • [details.output_schema][ApiOperation.details.output_schema] + *
  • [details.mcp_tool.annotations.title][ApiOperation.details.mcp_tool.annotations.title] + *
  • [details.mcp_tool.annotations.read_only_hint][ApiOperation.details.mcp_tool.annotations.read_only_hint] + *
  • [details.mcp_tool.annotations.destructive_hint][ApiOperation.details.mcp_tool.annotations.destructive_hint] + *
  • [details.mcp_tool.annotations.idempotent_hint][ApiOperation.details.mcp_tool.annotations.idempotent_hint] + *
  • [details.mcp_tool.annotations.open_world_hint][ApiOperation.details.mcp_tool.annotations.open_world_hint] + *
  • [details.mcp_tool.annotations.additional_hints][ApiOperation.details.mcp_tool.annotations.additional_hints] * * *

    The [update_mask][google.cloud.apihub.v1.UpdateApiOperationRequest.update_mask] should be @@ -3765,6 +4019,18 @@ public final ApiOperation updateApiOperation(UpdateApiOperationRequest request) *

  • [details.http_operation.method][ApiOperation.details.http_operation.method] *
  • [details.deprecated][ApiOperation.details.deprecated] *
  • [attributes][google.cloud.apihub.v1.ApiOperation.attributes] + *
  • [details.mcp_tool.title][ApiOperation.details.mcp_tool.title] + *
  • [details.mcp_tool.description][ApiOperation.details.mcp_tool.description] + *
  • [details.mcp_tool.input_schema][ApiOperation.details.mcp_tool.input_schema] + *
  • [details.mcp_tool.output_schema][ApiOperation.details.mcp_tool.output_schema] + *
  • [details.input_schema][ApiOperation.details.input_schema] + *
  • [details.output_schema][ApiOperation.details.output_schema] + *
  • [details.mcp_tool.annotations.title][ApiOperation.details.mcp_tool.annotations.title] + *
  • [details.mcp_tool.annotations.read_only_hint][ApiOperation.details.mcp_tool.annotations.read_only_hint] + *
  • [details.mcp_tool.annotations.destructive_hint][ApiOperation.details.mcp_tool.annotations.destructive_hint] + *
  • [details.mcp_tool.annotations.idempotent_hint][ApiOperation.details.mcp_tool.annotations.idempotent_hint] + *
  • [details.mcp_tool.annotations.open_world_hint][ApiOperation.details.mcp_tool.annotations.open_world_hint] + *
  • [details.mcp_tool.annotations.additional_hints][ApiOperation.details.mcp_tool.annotations.additional_hints] * * *

    The [update_mask][google.cloud.apihub.v1.UpdateApiOperationRequest.update_mask] should be @@ -3803,7 +4069,8 @@ public final UnaryCallable updateApiOpe /** * Delete an operation in an API version and we can delete only the operations created via create * API. If the operation was created by parsing the spec, then it can be deleted by editing or - * deleting the spec. + * deleting the spec. Deleting an operation will also remove any links between the operation and + * deployments. * *

    Sample code: * @@ -3836,7 +4103,8 @@ public final void deleteApiOperation(@Nullable ApiOperationName name) { /** * Delete an operation in an API version and we can delete only the operations created via create * API. If the operation was created by parsing the spec, then it can be deleted by editing or - * deleting the spec. + * deleting the spec. Deleting an operation will also remove any links between the operation and + * deployments. * *

    Sample code: * @@ -3868,7 +4136,8 @@ public final void deleteApiOperation(String name) { /** * Delete an operation in an API version and we can delete only the operations created via create * API. If the operation was created by parsing the spec, then it can be deleted by editing or - * deleting the spec. + * deleting the spec. Deleting an operation will also remove any links between the operation and + * deployments. * *

    Sample code: * @@ -3901,7 +4170,8 @@ public final void deleteApiOperation(DeleteApiOperationRequest request) { /** * Delete an operation in an API version and we can delete only the operations created via create * API. If the operation was created by parsing the spec, then it can be deleted by editing or - * deleting the spec. + * deleting the spec. Deleting an operation will also remove any links between the operation and + * deployments. * *

    Sample code: * @@ -4625,7 +4895,8 @@ public final UnaryCallable updateDeployment // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Delete a deployment resource in the API hub. + * Deletes a deployment resource in the API hub. A deployment can only be deleted after its links + * to any versions, specs, and API operations have been removed. * *

    Sample code: * @@ -4653,7 +4924,8 @@ public final void deleteDeployment(@Nullable DeploymentName name) { // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Delete a deployment resource in the API hub. + * Deletes a deployment resource in the API hub. A deployment can only be deleted after its links + * to any versions, specs, and API operations have been removed. * *

    Sample code: * @@ -4680,7 +4952,8 @@ public final void deleteDeployment(String name) { // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Delete a deployment resource in the API hub. + * Deletes a deployment resource in the API hub. A deployment can only be deleted after its links + * to any versions, specs, and API operations have been removed. * *

    Sample code: * @@ -4708,7 +4981,8 @@ public final void deleteDeployment(DeleteDeploymentRequest request) { // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Delete a deployment resource in the API hub. + * Deletes a deployment resource in the API hub. A deployment can only be deleted after its links + * to any versions, specs, and API operations have been removed. * *

    Sample code: * @@ -6299,10 +6573,372 @@ public final ListExternalApisPagedResponse listExternalApis(ListExternalApisRequ return stub.listExternalApisCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieve API views. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
    +   *   ApiViewType view = ApiViewType.forNumber(0);
    +   *   for (ApiView element : apiHubClient.retrieveApiViews(parent, view).iterateAll()) {
    +   *     // doThingsWith(element);
    +   *   }
    +   * }
    +   * }
    + * + * @param parent Required. The parent resource name. Format: + * `projects/{project}/locations/{location}`. + * @param view Required. The view type to return. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final RetrieveApiViewsPagedResponse retrieveApiViews( + @Nullable LocationName parent, ApiViewType view) { + RetrieveApiViewsRequest request = + RetrieveApiViewsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setView(view) + .build(); + return retrieveApiViews(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieve API views. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
    +   *   ApiViewType view = ApiViewType.forNumber(0);
    +   *   for (ApiView element : apiHubClient.retrieveApiViews(parent, view).iterateAll()) {
    +   *     // doThingsWith(element);
    +   *   }
    +   * }
    +   * }
    + * + * @param parent Required. The parent resource name. Format: + * `projects/{project}/locations/{location}`. + * @param view Required. The view type to return. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final RetrieveApiViewsPagedResponse retrieveApiViews(String parent, ApiViewType view) { + RetrieveApiViewsRequest request = + RetrieveApiViewsRequest.newBuilder().setParent(parent).setView(view).build(); + return retrieveApiViews(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieve API views. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   RetrieveApiViewsRequest request =
    +   *       RetrieveApiViewsRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .setFilter("filter-1274492040")
    +   *           .setPageSize(883849137)
    +   *           .setPageToken("pageToken873572522")
    +   *           .setView(ApiViewType.forNumber(0))
    +   *           .build();
    +   *   for (ApiView element : apiHubClient.retrieveApiViews(request).iterateAll()) {
    +   *     // doThingsWith(element);
    +   *   }
    +   * }
    +   * }
    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final RetrieveApiViewsPagedResponse retrieveApiViews(RetrieveApiViewsRequest request) { + return retrieveApiViewsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieve API views. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   RetrieveApiViewsRequest request =
    +   *       RetrieveApiViewsRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .setFilter("filter-1274492040")
    +   *           .setPageSize(883849137)
    +   *           .setPageToken("pageToken873572522")
    +   *           .setView(ApiViewType.forNumber(0))
    +   *           .build();
    +   *   ApiFuture future = apiHubClient.retrieveApiViewsPagedCallable().futureCall(request);
    +   *   // Do something.
    +   *   for (ApiView element : future.get().iterateAll()) {
    +   *     // doThingsWith(element);
    +   *   }
    +   * }
    +   * }
    + */ + public final UnaryCallable + retrieveApiViewsPagedCallable() { + return stub.retrieveApiViewsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieve API views. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   RetrieveApiViewsRequest request =
    +   *       RetrieveApiViewsRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .setFilter("filter-1274492040")
    +   *           .setPageSize(883849137)
    +   *           .setPageToken("pageToken873572522")
    +   *           .setView(ApiViewType.forNumber(0))
    +   *           .build();
    +   *   while (true) {
    +   *     RetrieveApiViewsResponse response = apiHubClient.retrieveApiViewsCallable().call(request);
    +   *     for (ApiView element : response.getApiViewsList()) {
    +   *       // doThingsWith(element);
    +   *     }
    +   *     String nextPageToken = response.getNextPageToken();
    +   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
    +   *       request = request.toBuilder().setPageToken(nextPageToken).build();
    +   *     } else {
    +   *       break;
    +   *     }
    +   *   }
    +   * }
    +   * }
    + */ + public final UnaryCallable + retrieveApiViewsCallable() { + return stub.retrieveApiViewsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Configures and deploys a given server config for given target. Currently this API supports only + * deploying MCP server in Apigee X. For mcp server deployment in apigee X, if there is already a + * mcp proxy deployed, then this method will try to overwrite it by creating new revision i.e. all + * existing tools will be removed and new set of tools will be deployed. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
    +   *   McpServerConfig mcpServerConfig = McpServerConfig.newBuilder().build();
    +   *   ConfigureAndDeployServerResponse response =
    +   *       apiHubClient.configureAndDeployServerAsync(parent, mcpServerConfig).get();
    +   * }
    +   * }
    + * + * @param parent Required. Format: `projects/{project}/locations/{location}` + * @param mcpServerConfig MCP (Model Context Protocol) server configuration. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + configureAndDeployServerAsync( + @Nullable LocationName parent, McpServerConfig mcpServerConfig) { + ConfigureAndDeployServerRequest request = + ConfigureAndDeployServerRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setMcpServerConfig(mcpServerConfig) + .build(); + return configureAndDeployServerAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Configures and deploys a given server config for given target. Currently this API supports only + * deploying MCP server in Apigee X. For mcp server deployment in apigee X, if there is already a + * mcp proxy deployed, then this method will try to overwrite it by creating new revision i.e. all + * existing tools will be removed and new set of tools will be deployed. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
    +   *   McpServerConfig mcpServerConfig = McpServerConfig.newBuilder().build();
    +   *   ConfigureAndDeployServerResponse response =
    +   *       apiHubClient.configureAndDeployServerAsync(parent, mcpServerConfig).get();
    +   * }
    +   * }
    + * + * @param parent Required. Format: `projects/{project}/locations/{location}` + * @param mcpServerConfig MCP (Model Context Protocol) server configuration. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + configureAndDeployServerAsync(String parent, McpServerConfig mcpServerConfig) { + ConfigureAndDeployServerRequest request = + ConfigureAndDeployServerRequest.newBuilder() + .setParent(parent) + .setMcpServerConfig(mcpServerConfig) + .build(); + return configureAndDeployServerAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Configures and deploys a given server config for given target. Currently this API supports only + * deploying MCP server in Apigee X. For mcp server deployment in apigee X, if there is already a + * mcp proxy deployed, then this method will try to overwrite it by creating new revision i.e. all + * existing tools will be removed and new set of tools will be deployed. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   ConfigureAndDeployServerRequest request =
    +   *       ConfigureAndDeployServerRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .build();
    +   *   ConfigureAndDeployServerResponse response =
    +   *       apiHubClient.configureAndDeployServerAsync(request).get();
    +   * }
    +   * }
    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + configureAndDeployServerAsync(ConfigureAndDeployServerRequest request) { + return configureAndDeployServerOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Configures and deploys a given server config for given target. Currently this API supports only + * deploying MCP server in Apigee X. For mcp server deployment in apigee X, if there is already a + * mcp proxy deployed, then this method will try to overwrite it by creating new revision i.e. all + * existing tools will be removed and new set of tools will be deployed. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   ConfigureAndDeployServerRequest request =
    +   *       ConfigureAndDeployServerRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .build();
    +   *   OperationFuture future =
    +   *       apiHubClient.configureAndDeployServerOperationCallable().futureCall(request);
    +   *   // Do something.
    +   *   ConfigureAndDeployServerResponse response = future.get();
    +   * }
    +   * }
    + */ + public final OperationCallable< + ConfigureAndDeployServerRequest, ConfigureAndDeployServerResponse, OperationMetadata> + configureAndDeployServerOperationCallable() { + return stub.configureAndDeployServerOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Configures and deploys a given server config for given target. Currently this API supports only + * deploying MCP server in Apigee X. For mcp server deployment in apigee X, if there is already a + * mcp proxy deployed, then this method will try to overwrite it by creating new revision i.e. all + * existing tools will be removed and new set of tools will be deployed. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (ApiHubClient apiHubClient = ApiHubClient.create()) {
    +   *   ConfigureAndDeployServerRequest request =
    +   *       ConfigureAndDeployServerRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .build();
    +   *   ApiFuture future =
    +   *       apiHubClient.configureAndDeployServerCallable().futureCall(request);
    +   *   // Do something.
    +   *   Operation response = future.get();
    +   * }
    +   * }
    + */ + public final UnaryCallable + configureAndDeployServerCallable() { + return stub.configureAndDeployServerCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Lists information about the supported locations for this service. * + *

    This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

    For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

    Sample code: * *

    {@code
    @@ -6336,6 +6972,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
       /**
        * Lists information about the supported locations for this service.
        *
    +   * 

    This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

    For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

    Sample code: * *

    {@code
    @@ -6369,6 +7017,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
       /**
        * Lists information about the supported locations for this service.
        *
    +   * 

    This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

    For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

    Sample code: * *

    {@code
    @@ -7086,6 +7746,83 @@ protected ListExternalApisFixedSizeCollection createCollection(
         }
       }
     
    +  public static class RetrieveApiViewsPagedResponse
    +      extends AbstractPagedListResponse<
    +          RetrieveApiViewsRequest,
    +          RetrieveApiViewsResponse,
    +          ApiView,
    +          RetrieveApiViewsPage,
    +          RetrieveApiViewsFixedSizeCollection> {
    +
    +    public static ApiFuture createAsync(
    +        PageContext context,
    +        ApiFuture futureResponse) {
    +      ApiFuture futurePage =
    +          RetrieveApiViewsPage.createEmptyPage().createPageAsync(context, futureResponse);
    +      return ApiFutures.transform(
    +          futurePage,
    +          input -> new RetrieveApiViewsPagedResponse(input),
    +          MoreExecutors.directExecutor());
    +    }
    +
    +    private RetrieveApiViewsPagedResponse(RetrieveApiViewsPage page) {
    +      super(page, RetrieveApiViewsFixedSizeCollection.createEmptyCollection());
    +    }
    +  }
    +
    +  public static class RetrieveApiViewsPage
    +      extends AbstractPage<
    +          RetrieveApiViewsRequest, RetrieveApiViewsResponse, ApiView, RetrieveApiViewsPage> {
    +
    +    private RetrieveApiViewsPage(
    +        @Nullable PageContext context,
    +        @Nullable RetrieveApiViewsResponse response) {
    +      super(context, response);
    +    }
    +
    +    private static RetrieveApiViewsPage createEmptyPage() {
    +      return new RetrieveApiViewsPage(null, null);
    +    }
    +
    +    @Override
    +    protected RetrieveApiViewsPage createPage(
    +        @Nullable PageContext context,
    +        @Nullable RetrieveApiViewsResponse response) {
    +      return new RetrieveApiViewsPage(context, response);
    +    }
    +
    +    @Override
    +    public ApiFuture createPageAsync(
    +        @Nullable PageContext context,
    +        ApiFuture futureResponse) {
    +      return super.createPageAsync(context, futureResponse);
    +    }
    +  }
    +
    +  public static class RetrieveApiViewsFixedSizeCollection
    +      extends AbstractFixedSizeCollection<
    +          RetrieveApiViewsRequest,
    +          RetrieveApiViewsResponse,
    +          ApiView,
    +          RetrieveApiViewsPage,
    +          RetrieveApiViewsFixedSizeCollection> {
    +
    +    private RetrieveApiViewsFixedSizeCollection(
    +        @Nullable List pages, int collectionSize) {
    +      super(pages, collectionSize);
    +    }
    +
    +    private static RetrieveApiViewsFixedSizeCollection createEmptyCollection() {
    +      return new RetrieveApiViewsFixedSizeCollection(null, 0);
    +    }
    +
    +    @Override
    +    protected RetrieveApiViewsFixedSizeCollection createCollection(
    +        @Nullable List pages, int collectionSize) {
    +      return new RetrieveApiViewsFixedSizeCollection(pages, collectionSize);
    +    }
    +  }
    +
       public static class ListLocationsPagedResponse
           extends AbstractPagedListResponse<
               ListLocationsRequest,
    diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubCollectClient.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubCollectClient.java
    index 54320d11009f..d1fc0b49e3b7 100644
    --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubCollectClient.java
    +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubCollectClient.java
    @@ -94,7 +94,9 @@
      *    
      *    
      *      

    ListLocations - *

    Lists information about the supported locations for this service. + *

    Lists information about the supported locations for this service. + *

    This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

    For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. * *

    Request object method variants only take one parameter, a request object, which must be constructed before the call.

    *
      @@ -410,6 +412,18 @@ public final UnaryCallable collectApiDataCalla /** * Lists information about the supported locations for this service. * + *

      This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

      For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

      Sample code: * *

      {@code
      @@ -443,6 +457,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
         /**
          * Lists information about the supported locations for this service.
          *
      +   * 

      This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

      For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

      Sample code: * *

      {@code
      @@ -477,6 +503,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
         /**
          * Lists information about the supported locations for this service.
          *
      +   * 

      This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

      For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

      Sample code: * *

      {@code
      diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubCurateClient.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubCurateClient.java
      index 04407abea0a8..ea74b1ed4b02 100644
      --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubCurateClient.java
      +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubCurateClient.java
      @@ -174,7 +174,9 @@
        *    
        *    
        *      

      ListLocations - *

      Lists information about the supported locations for this service. + *

      Lists information about the supported locations for this service. + *

      This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

      For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. * *

      Request object method variants only take one parameter, a request object, which must be constructed before the call.

      *
        @@ -952,6 +954,18 @@ public final UnaryCallable deleteCurationCallable( /** * Lists information about the supported locations for this service. * + *

        This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

        For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

        Sample code: * *

        {@code
        @@ -985,6 +999,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
           /**
            * Lists information about the supported locations for this service.
            *
        +   * 

        This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

        For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

        Sample code: * *

        {@code
        @@ -1019,6 +1045,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
           /**
            * Lists information about the supported locations for this service.
            *
        +   * 

        This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

        For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

        Sample code: * *

        {@code
        diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubDependenciesClient.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubDependenciesClient.java
        index dd06d1391378..7644db9c13ea 100644
        --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubDependenciesClient.java
        +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubDependenciesClient.java
        @@ -175,7 +175,9 @@
          *    
          *    
          *      

        ListLocations - *

        Lists information about the supported locations for this service. + *

        Lists information about the supported locations for this service. + *

        This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

        For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. * *

        Request object method variants only take one parameter, a request object, which must be constructed before the call.

        *
          @@ -958,6 +960,18 @@ public final ListDependenciesPagedResponse listDependencies(ListDependenciesRequ /** * Lists information about the supported locations for this service. * + *

          This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

          For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

          Sample code: * *

          {@code
          @@ -991,6 +1005,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
             /**
              * Lists information about the supported locations for this service.
              *
          +   * 

          This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

          For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

          Sample code: * *

          {@code
          @@ -1025,6 +1051,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
             /**
              * Lists information about the supported locations for this service.
              *
          +   * 

          This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

          For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

          Sample code: * *

          {@code
          diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubDiscoveryClient.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubDiscoveryClient.java
          index c32f4ddb7166..d6b2f1f2da4d 100644
          --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubDiscoveryClient.java
          +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubDiscoveryClient.java
          @@ -151,7 +151,9 @@
            *    
            *    
            *      

          ListLocations - *

          Lists information about the supported locations for this service. + *

          Lists information about the supported locations for this service. + *

          This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

          For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. * *

          Request object method variants only take one parameter, a request object, which must be constructed before the call.

          *
            @@ -908,6 +910,18 @@ public final DiscoveredApiOperation getDiscoveredApiOperation( /** * Lists information about the supported locations for this service. * + *

            This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

            For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

            Sample code: * *

            {@code
            @@ -941,6 +955,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
               /**
                * Lists information about the supported locations for this service.
                *
            +   * 

            This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

            For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

            Sample code: * *

            {@code
            @@ -975,6 +1001,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
               /**
                * Lists information about the supported locations for this service.
                *
            +   * 

            This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

            For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

            Sample code: * *

            {@code
            diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubPluginClient.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubPluginClient.java
            index ff4a1c877da7..8def4e8925f8 100644
            --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubPluginClient.java
            +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubPluginClient.java
            @@ -35,6 +35,7 @@
             import com.google.cloud.location.Location;
             import com.google.common.util.concurrent.MoreExecutors;
             import com.google.longrunning.Operation;
            +import com.google.protobuf.ByteString;
             import com.google.protobuf.Empty;
             import com.google.protobuf.FieldMask;
             import java.io.IOException;
            @@ -353,8 +354,29 @@
              *       
              *    
              *    
            + *      

            ManagePluginInstanceSourceData + *

            Manages data for a given plugin instance. + * + *

            Request object method variants only take one parameter, a request object, which must be constructed before the call.

            + *
              + *
            • managePluginInstanceSourceData(ManagePluginInstanceSourceDataRequest request) + *

            + *

            "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

            + *
              + *
            • managePluginInstanceSourceData(PluginInstanceName name, ManagePluginInstanceSourceDataRequest.DataType dataType, ManagePluginInstanceSourceDataRequest.Action action, String relativePath, ByteString data) + *

            • managePluginInstanceSourceData(String name, ManagePluginInstanceSourceDataRequest.DataType dataType, ManagePluginInstanceSourceDataRequest.Action action, String relativePath, ByteString data) + *

            + *

            Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

            + *
              + *
            • managePluginInstanceSourceDataCallable() + *

            + * + * + * *

            ListLocations - *

            Lists information about the supported locations for this service. + *

            Lists information about the supported locations for this service. + *

            This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

            For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. * *

            Request object method variants only take one parameter, a request object, which must be constructed before the call.

            *
              @@ -2557,10 +2579,194 @@ public final OperationFuture deletePluginInstanceAsync return stub.deletePluginInstanceCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Manages data for a given plugin instance. + * + *

              Sample code: + * + *

              {@code
              +   * // This snippet has been automatically generated and should be regarded as a code template only.
              +   * // It will require modifications to work:
              +   * // - It may require correct/in-range values for request initialization.
              +   * // - It may require specifying regional endpoints when creating the service client as shown in
              +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
              +   * try (ApiHubPluginClient apiHubPluginClient = ApiHubPluginClient.create()) {
              +   *   PluginInstanceName name =
              +   *       PluginInstanceName.of("[PROJECT]", "[LOCATION]", "[PLUGIN]", "[INSTANCE]");
              +   *   ManagePluginInstanceSourceDataRequest.DataType dataType =
              +   *       ManagePluginInstanceSourceDataRequest.DataType.forNumber(0);
              +   *   ManagePluginInstanceSourceDataRequest.Action action =
              +   *       ManagePluginInstanceSourceDataRequest.Action.forNumber(0);
              +   *   String relativePath = "relativePath-70808303";
              +   *   ByteString data = ByteString.EMPTY;
              +   *   ManagePluginInstanceSourceDataResponse response =
              +   *       apiHubPluginClient.managePluginInstanceSourceData(
              +   *           name, dataType, action, relativePath, data);
              +   * }
              +   * }
              + * + * @param name Required. The name of the plugin instance for which data needs to be managed. + * Format: `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}` + * @param dataType Required. Type of data to be managed. + * @param action Required. Action to be performed. + * @param relativePath Required. Relative path of data being managed for a given plugin instance. + * @param data Required. Data to be managed. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ManagePluginInstanceSourceDataResponse managePluginInstanceSourceData( + @Nullable PluginInstanceName name, + ManagePluginInstanceSourceDataRequest.DataType dataType, + ManagePluginInstanceSourceDataRequest.Action action, + String relativePath, + ByteString data) { + ManagePluginInstanceSourceDataRequest request = + ManagePluginInstanceSourceDataRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .setDataType(dataType) + .setAction(action) + .setRelativePath(relativePath) + .setData(data) + .build(); + return managePluginInstanceSourceData(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Manages data for a given plugin instance. + * + *

              Sample code: + * + *

              {@code
              +   * // This snippet has been automatically generated and should be regarded as a code template only.
              +   * // It will require modifications to work:
              +   * // - It may require correct/in-range values for request initialization.
              +   * // - It may require specifying regional endpoints when creating the service client as shown in
              +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
              +   * try (ApiHubPluginClient apiHubPluginClient = ApiHubPluginClient.create()) {
              +   *   String name =
              +   *       PluginInstanceName.of("[PROJECT]", "[LOCATION]", "[PLUGIN]", "[INSTANCE]").toString();
              +   *   ManagePluginInstanceSourceDataRequest.DataType dataType =
              +   *       ManagePluginInstanceSourceDataRequest.DataType.forNumber(0);
              +   *   ManagePluginInstanceSourceDataRequest.Action action =
              +   *       ManagePluginInstanceSourceDataRequest.Action.forNumber(0);
              +   *   String relativePath = "relativePath-70808303";
              +   *   ByteString data = ByteString.EMPTY;
              +   *   ManagePluginInstanceSourceDataResponse response =
              +   *       apiHubPluginClient.managePluginInstanceSourceData(
              +   *           name, dataType, action, relativePath, data);
              +   * }
              +   * }
              + * + * @param name Required. The name of the plugin instance for which data needs to be managed. + * Format: `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}` + * @param dataType Required. Type of data to be managed. + * @param action Required. Action to be performed. + * @param relativePath Required. Relative path of data being managed for a given plugin instance. + * @param data Required. Data to be managed. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ManagePluginInstanceSourceDataResponse managePluginInstanceSourceData( + String name, + ManagePluginInstanceSourceDataRequest.DataType dataType, + ManagePluginInstanceSourceDataRequest.Action action, + String relativePath, + ByteString data) { + ManagePluginInstanceSourceDataRequest request = + ManagePluginInstanceSourceDataRequest.newBuilder() + .setName(name) + .setDataType(dataType) + .setAction(action) + .setRelativePath(relativePath) + .setData(data) + .build(); + return managePluginInstanceSourceData(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Manages data for a given plugin instance. + * + *

              Sample code: + * + *

              {@code
              +   * // This snippet has been automatically generated and should be regarded as a code template only.
              +   * // It will require modifications to work:
              +   * // - It may require correct/in-range values for request initialization.
              +   * // - It may require specifying regional endpoints when creating the service client as shown in
              +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
              +   * try (ApiHubPluginClient apiHubPluginClient = ApiHubPluginClient.create()) {
              +   *   ManagePluginInstanceSourceDataRequest request =
              +   *       ManagePluginInstanceSourceDataRequest.newBuilder()
              +   *           .setName(
              +   *               PluginInstanceName.of("[PROJECT]", "[LOCATION]", "[PLUGIN]", "[INSTANCE]")
              +   *                   .toString())
              +   *           .setRelativePath("relativePath-70808303")
              +   *           .setData(ByteString.EMPTY)
              +   *           .build();
              +   *   ManagePluginInstanceSourceDataResponse response =
              +   *       apiHubPluginClient.managePluginInstanceSourceData(request);
              +   * }
              +   * }
              + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ManagePluginInstanceSourceDataResponse managePluginInstanceSourceData( + ManagePluginInstanceSourceDataRequest request) { + return managePluginInstanceSourceDataCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Manages data for a given plugin instance. + * + *

              Sample code: + * + *

              {@code
              +   * // This snippet has been automatically generated and should be regarded as a code template only.
              +   * // It will require modifications to work:
              +   * // - It may require correct/in-range values for request initialization.
              +   * // - It may require specifying regional endpoints when creating the service client as shown in
              +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
              +   * try (ApiHubPluginClient apiHubPluginClient = ApiHubPluginClient.create()) {
              +   *   ManagePluginInstanceSourceDataRequest request =
              +   *       ManagePluginInstanceSourceDataRequest.newBuilder()
              +   *           .setName(
              +   *               PluginInstanceName.of("[PROJECT]", "[LOCATION]", "[PLUGIN]", "[INSTANCE]")
              +   *                   .toString())
              +   *           .setRelativePath("relativePath-70808303")
              +   *           .setData(ByteString.EMPTY)
              +   *           .build();
              +   *   ApiFuture future =
              +   *       apiHubPluginClient.managePluginInstanceSourceDataCallable().futureCall(request);
              +   *   // Do something.
              +   *   ManagePluginInstanceSourceDataResponse response = future.get();
              +   * }
              +   * }
              + */ + public final UnaryCallable< + ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse> + managePluginInstanceSourceDataCallable() { + return stub.managePluginInstanceSourceDataCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Lists information about the supported locations for this service. * + *

              This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

              For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

              Sample code: * *

              {@code
              @@ -2594,6 +2800,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
                 /**
                  * Lists information about the supported locations for this service.
                  *
              +   * 

              This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

              For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

              Sample code: * *

              {@code
              @@ -2628,6 +2846,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
                 /**
                  * Lists information about the supported locations for this service.
                  *
              +   * 

              This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

              For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

              Sample code: * *

              {@code
              diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubPluginSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubPluginSettings.java
              index b9fe5a48064c..e3bb0c56cbf2 100644
              --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubPluginSettings.java
              +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubPluginSettings.java
              @@ -245,6 +245,13 @@ public UnaryCallSettings deletePluginIns
                   return ((ApiHubPluginStubSettings) getStubSettings()).deletePluginInstanceOperationSettings();
                 }
               
              +  /** Returns the object with the settings used for calls to managePluginInstanceSourceData. */
              +  public UnaryCallSettings<
              +          ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse>
              +      managePluginInstanceSourceDataSettings() {
              +    return ((ApiHubPluginStubSettings) getStubSettings()).managePluginInstanceSourceDataSettings();
              +  }
              +
                 /** Returns the object with the settings used for calls to listLocations. */
                 public PagedCallSettings
                     listLocationsSettings() {
              @@ -482,6 +489,13 @@ public UnaryCallSettings.Builder deletePluginSet
                     return getStubSettingsBuilder().deletePluginInstanceOperationSettings();
                   }
               
              +    /** Returns the builder for the settings used for calls to managePluginInstanceSourceData. */
              +    public UnaryCallSettings.Builder<
              +            ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse>
              +        managePluginInstanceSourceDataSettings() {
              +      return getStubSettingsBuilder().managePluginInstanceSourceDataSettings();
              +    }
              +
                   /** Returns the builder for the settings used for calls to listLocations. */
                   public PagedCallSettings.Builder<
                           ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse>
              diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubSettings.java
              index d8f8a2ea8fe6..6a29555a0f82 100644
              --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubSettings.java
              +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ApiHubSettings.java
              @@ -24,6 +24,7 @@
               import static com.google.cloud.apihub.v1.ApiHubClient.ListLocationsPagedResponse;
               import static com.google.cloud.apihub.v1.ApiHubClient.ListSpecsPagedResponse;
               import static com.google.cloud.apihub.v1.ApiHubClient.ListVersionsPagedResponse;
              +import static com.google.cloud.apihub.v1.ApiHubClient.RetrieveApiViewsPagedResponse;
               import static com.google.cloud.apihub.v1.ApiHubClient.SearchResourcesPagedResponse;
               
               import com.google.api.core.ApiFunction;
              @@ -33,6 +34,7 @@
               import com.google.api.gax.rpc.ApiClientHeaderProvider;
               import com.google.api.gax.rpc.ClientContext;
               import com.google.api.gax.rpc.ClientSettings;
              +import com.google.api.gax.rpc.OperationCallSettings;
               import com.google.api.gax.rpc.PagedCallSettings;
               import com.google.api.gax.rpc.TransportChannelProvider;
               import com.google.api.gax.rpc.UnaryCallSettings;
              @@ -41,6 +43,7 @@
               import com.google.cloud.location.ListLocationsRequest;
               import com.google.cloud.location.ListLocationsResponse;
               import com.google.cloud.location.Location;
              +import com.google.longrunning.Operation;
               import com.google.protobuf.Empty;
               import java.io.IOException;
               import java.util.List;
              @@ -96,6 +99,31 @@
                * Please refer to the [Client Side Retry
                * Guide](https://docs.cloud.google.com/java/docs/client-retries) for additional support in setting
                * retries.
              + *
              + * 

              To configure the RetrySettings of a Long Running Operation method, create an + * OperationTimedPollAlgorithm object and update the RPC's polling algorithm. For example, to + * configure the RetrySettings for configureAndDeployServer: + * + *

              {@code
              + * // This snippet has been automatically generated and should be regarded as a code template only.
              + * // It will require modifications to work:
              + * // - It may require correct/in-range values for request initialization.
              + * // - It may require specifying regional endpoints when creating the service client as shown in
              + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
              + * ApiHubSettings.Builder apiHubSettingsBuilder = ApiHubSettings.newBuilder();
              + * TimedRetryAlgorithm timedRetryAlgorithm =
              + *     OperationalTimedPollAlgorithm.create(
              + *         RetrySettings.newBuilder()
              + *             .setInitialRetryDelayDuration(Duration.ofMillis(500))
              + *             .setRetryDelayMultiplier(1.5)
              + *             .setMaxRetryDelayDuration(Duration.ofMillis(5000))
              + *             .setTotalTimeoutDuration(Duration.ofHours(24))
              + *             .build());
              + * apiHubSettingsBuilder
              + *     .createClusterOperationSettings()
              + *     .setPollingAlgorithm(timedRetryAlgorithm)
              + *     .build();
              + * }
              */ @NullMarked @Generated("by gapic-generator-java") @@ -168,6 +196,12 @@ public UnaryCallSettings getSpecContentsSe return ((ApiHubStubSettings) getStubSettings()).getSpecContentsSettings(); } + /** Returns the object with the settings used for calls to fetchAdditionalSpecContent. */ + public UnaryCallSettings + fetchAdditionalSpecContentSettings() { + return ((ApiHubStubSettings) getStubSettings()).fetchAdditionalSpecContentSettings(); + } + /** Returns the object with the settings used for calls to listSpecs. */ public PagedCallSettings listSpecsSettings() { @@ -304,6 +338,26 @@ public UnaryCallSettings deleteExternalApiSetti return ((ApiHubStubSettings) getStubSettings()).listExternalApisSettings(); } + /** Returns the object with the settings used for calls to retrieveApiViews. */ + public PagedCallSettings< + RetrieveApiViewsRequest, RetrieveApiViewsResponse, RetrieveApiViewsPagedResponse> + retrieveApiViewsSettings() { + return ((ApiHubStubSettings) getStubSettings()).retrieveApiViewsSettings(); + } + + /** Returns the object with the settings used for calls to configureAndDeployServer. */ + public UnaryCallSettings + configureAndDeployServerSettings() { + return ((ApiHubStubSettings) getStubSettings()).configureAndDeployServerSettings(); + } + + /** Returns the object with the settings used for calls to configureAndDeployServer. */ + public OperationCallSettings< + ConfigureAndDeployServerRequest, ConfigureAndDeployServerResponse, OperationMetadata> + configureAndDeployServerOperationSettings() { + return ((ApiHubStubSettings) getStubSettings()).configureAndDeployServerOperationSettings(); + } + /** Returns the object with the settings used for calls to listLocations. */ public PagedCallSettings listLocationsSettings() { @@ -480,6 +534,13 @@ public UnaryCallSettings.Builder getSpecSettings() { return getStubSettingsBuilder().getSpecContentsSettings(); } + /** Returns the builder for the settings used for calls to fetchAdditionalSpecContent. */ + public UnaryCallSettings.Builder< + FetchAdditionalSpecContentRequest, FetchAdditionalSpecContentResponse> + fetchAdditionalSpecContentSettings() { + return getStubSettingsBuilder().fetchAdditionalSpecContentSettings(); + } + /** Returns the builder for the settings used for calls to listSpecs. */ public PagedCallSettings.Builder listSpecsSettings() { @@ -624,6 +685,26 @@ public UnaryCallSettings.Builder deleteExternal return getStubSettingsBuilder().listExternalApisSettings(); } + /** Returns the builder for the settings used for calls to retrieveApiViews. */ + public PagedCallSettings.Builder< + RetrieveApiViewsRequest, RetrieveApiViewsResponse, RetrieveApiViewsPagedResponse> + retrieveApiViewsSettings() { + return getStubSettingsBuilder().retrieveApiViewsSettings(); + } + + /** Returns the builder for the settings used for calls to configureAndDeployServer. */ + public UnaryCallSettings.Builder + configureAndDeployServerSettings() { + return getStubSettingsBuilder().configureAndDeployServerSettings(); + } + + /** Returns the builder for the settings used for calls to configureAndDeployServer. */ + public OperationCallSettings.Builder< + ConfigureAndDeployServerRequest, ConfigureAndDeployServerResponse, OperationMetadata> + configureAndDeployServerOperationSettings() { + return getStubSettingsBuilder().configureAndDeployServerOperationSettings(); + } + /** Returns the builder for the settings used for calls to listLocations. */ public PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/HostProjectRegistrationServiceClient.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/HostProjectRegistrationServiceClient.java index 83668a674da1..284b1edfcc8c 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/HostProjectRegistrationServiceClient.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/HostProjectRegistrationServiceClient.java @@ -76,7 +76,7 @@ * * *

              CreateHostProjectRegistration - *

              Create a host project registration. A Google cloud project can be registered as a host project if it is not attached as a runtime project to another host project. A project can be registered as a host project only once. Subsequent register calls for the same project will fail. + *

              Create a host project registration. A Google cloud project can be registered as a host project if it is not attached as a runtime project to another host project. A project can have only one host project registration at a time. Subsequent register calls for the same project will fail until the existing registration is deleted. * *

              Request object method variants only take one parameter, a request object, which must be constructed before the call.

              *
                @@ -134,7 +134,9 @@ * * *

                ListLocations - *

                Lists information about the supported locations for this service. + *

                Lists information about the supported locations for this service. + *

                This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

                For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. * *

                Request object method variants only take one parameter, a request object, which must be constructed before the call.

                *
                  @@ -263,8 +265,9 @@ public HostProjectRegistrationServiceStub getStub() { // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Create a host project registration. A Google cloud project can be registered as a host project - * if it is not attached as a runtime project to another host project. A project can be registered - * as a host project only once. Subsequent register calls for the same project will fail. + * if it is not attached as a runtime project to another host project. A project can have only one + * host project registration at a time. Subsequent register calls for the same project will fail + * until the existing registration is deleted. * *

                  Sample code: * @@ -311,8 +314,9 @@ public final HostProjectRegistration createHostProjectRegistration( // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Create a host project registration. A Google cloud project can be registered as a host project - * if it is not attached as a runtime project to another host project. A project can be registered - * as a host project only once. Subsequent register calls for the same project will fail. + * if it is not attached as a runtime project to another host project. A project can have only one + * host project registration at a time. Subsequent register calls for the same project will fail + * until the existing registration is deleted. * *

                  Sample code: * @@ -359,8 +363,9 @@ public final HostProjectRegistration createHostProjectRegistration( // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Create a host project registration. A Google cloud project can be registered as a host project - * if it is not attached as a runtime project to another host project. A project can be registered - * as a host project only once. Subsequent register calls for the same project will fail. + * if it is not attached as a runtime project to another host project. A project can have only one + * host project registration at a time. Subsequent register calls for the same project will fail + * until the existing registration is deleted. * *

                  Sample code: * @@ -394,8 +399,9 @@ public final HostProjectRegistration createHostProjectRegistration( // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Create a host project registration. A Google cloud project can be registered as a host project - * if it is not attached as a runtime project to another host project. A project can be registered - * as a host project only once. Subsequent register calls for the same project will fail. + * if it is not attached as a runtime project to another host project. A project can have only one + * host project registration at a time. Subsequent register calls for the same project will fail + * until the existing registration is deleted. * *

                  Sample code: * @@ -756,6 +762,18 @@ public final ListHostProjectRegistrationsPagedResponse listHostProjectRegistrati /** * Lists information about the supported locations for this service. * + *

                  This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                  For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                  Sample code: * *

                  {@code
                  @@ -791,6 +809,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
                     /**
                      * Lists information about the supported locations for this service.
                      *
                  +   * 

                  This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                  For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                  Sample code: * *

                  {@code
                  @@ -826,6 +856,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
                     /**
                      * Lists information about the supported locations for this service.
                      *
                  +   * 

                  This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                  For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                  Sample code: * *

                  {@code
                  diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/LintingServiceClient.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/LintingServiceClient.java
                  index e6262c41c027..76319590814e 100644
                  --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/LintingServiceClient.java
                  +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/LintingServiceClient.java
                  @@ -141,7 +141,9 @@
                    *    
                    *    
                    *      

                  ListLocations - *

                  Lists information about the supported locations for this service. + *

                  Lists information about the supported locations for this service. + *

                  This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

                  For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. * *

                  Request object method variants only take one parameter, a request object, which must be constructed before the call.

                  *
                    @@ -641,6 +643,18 @@ public final UnaryCallable lintSpecCallable() { /** * Lists information about the supported locations for this service. * + *

                    This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                    For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                    Sample code: * *

                    {@code
                    @@ -674,6 +688,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
                       /**
                        * Lists information about the supported locations for this service.
                        *
                    +   * 

                    This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                    For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                    Sample code: * *

                    {@code
                    @@ -708,6 +734,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
                       /**
                        * Lists information about the supported locations for this service.
                        *
                    +   * 

                    This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                    For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                    Sample code: * *

                    {@code
                    diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ProvisioningClient.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ProvisioningClient.java
                    index dca4d922678f..ef0a30d6edc9 100644
                    --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ProvisioningClient.java
                    +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ProvisioningClient.java
                    @@ -36,6 +36,7 @@
                     import com.google.common.util.concurrent.MoreExecutors;
                     import com.google.longrunning.Operation;
                     import com.google.protobuf.Empty;
                    +import com.google.protobuf.FieldMask;
                     import java.io.IOException;
                     import java.util.List;
                     import java.util.concurrent.TimeUnit;
                    @@ -96,7 +97,7 @@
                      *    
                      *    
                      *      

                    DeleteApiHubInstance - *

                    Deletes the API hub instance. + *

                    Deletes the API hub instance. Deleting the API hub instance will also result in the removal of all associated runtime project attachments and the host project registration. * *

                    Request object method variants only take one parameter, a request object, which must be constructed before the call.

                    *
                      @@ -134,8 +135,33 @@ * * * + *

                      UpdateApiHubInstance + *

                      Update an Api Hub instance. The following fields in the [ApiHubInstance][google.cloud.apihub.v1.ApiHubInstance] can be updated: + *

                        + *
                      • [disable_search][ApiHubInstance.config.disable_search] + *
                      • [vertex_location][ApiHubInstance.config.vertex_location] + *
                      • [agent_registry_sync_config][ApiHubInstance.config.agent_registry_sync_config] + *
                      + *

                      The [update_mask][google.cloud.apihub.v1.UpdateApiHubInstanceRequest.update_mask] should be used to specify the fields being updated. + * + *

                      Request object method variants only take one parameter, a request object, which must be constructed before the call.

                      + *
                        + *
                      • updateApiHubInstanceAsync(UpdateApiHubInstanceRequest request) + *

                      + *

                      Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

                      + *
                        + *
                      • updateApiHubInstanceAsync(ApiHubInstance apiHubInstance, FieldMask updateMask) + *

                      + *

                      Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

                      + *
                        + *
                      • updateApiHubInstanceOperationCallable() + *

                      • updateApiHubInstanceCallable() + *

                      + * + * + * *

                      LookupApiHubInstance - *

                      Looks up an Api Hub instance in a given GCP project. There will always be only one Api Hub instance for a GCP project across all locations. + *

                      Looks up an Api Hub instance in a given Google Cloud project. There will always be only one Api Hub instance for a Google Cloud project across all locations. * *

                      Request object method variants only take one parameter, a request object, which must be constructed before the call.

                      *
                        @@ -154,7 +180,9 @@ * * *

                        ListLocations - *

                        Lists information about the supported locations for this service. + *

                        Lists information about the supported locations for this service. + *

                        This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

                        For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. * *

                        Request object method variants only take one parameter, a request object, which must be constructed before the call.

                        *
                          @@ -464,7 +492,8 @@ public final OperationFuture createApiHubInst // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Deletes the API hub instance. + * Deletes the API hub instance. Deleting the API hub instance will also result in the removal of + * all associated runtime project attachments and the host project registration. * *

                          Sample code: * @@ -496,7 +525,8 @@ public final OperationFuture deleteApiHubInstanceAsync // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Deletes the API hub instance. + * Deletes the API hub instance. Deleting the API hub instance will also result in the removal of + * all associated runtime project attachments and the host project registration. * *

                          Sample code: * @@ -525,7 +555,8 @@ public final OperationFuture deleteApiHubInstanceAsync // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Deletes the API hub instance. + * Deletes the API hub instance. Deleting the API hub instance will also result in the removal of + * all associated runtime project attachments and the host project registration. * *

                          Sample code: * @@ -555,7 +586,8 @@ public final OperationFuture deleteApiHubInstanceAsync // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Deletes the API hub instance. + * Deletes the API hub instance. Deleting the API hub instance will also result in the removal of + * all associated runtime project attachments and the host project registration. * *

                          Sample code: * @@ -585,7 +617,8 @@ public final OperationFuture deleteApiHubInstanceAsync // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Deletes the API hub instance. + * Deletes the API hub instance. Deleting the API hub instance will also result in the removal of + * all associated runtime project attachments and the host project registration. * *

                          Sample code: * @@ -732,8 +765,174 @@ public final UnaryCallable getApiHubIn // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Looks up an Api Hub instance in a given GCP project. There will always be only one Api Hub - * instance for a GCP project across all locations. + * Update an Api Hub instance. The following fields in the + * [ApiHubInstance][google.cloud.apihub.v1.ApiHubInstance] can be updated: + * + *

                            + *
                          • [disable_search][ApiHubInstance.config.disable_search] + *
                          • [vertex_location][ApiHubInstance.config.vertex_location] + *
                          • [agent_registry_sync_config][ApiHubInstance.config.agent_registry_sync_config] + *
                          + * + *

                          The [update_mask][google.cloud.apihub.v1.UpdateApiHubInstanceRequest.update_mask] should be + * used to specify the fields being updated. + * + *

                          Sample code: + * + *

                          {@code
                          +   * // This snippet has been automatically generated and should be regarded as a code template only.
                          +   * // It will require modifications to work:
                          +   * // - It may require correct/in-range values for request initialization.
                          +   * // - It may require specifying regional endpoints when creating the service client as shown in
                          +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                          +   * try (ProvisioningClient provisioningClient = ProvisioningClient.create()) {
                          +   *   ApiHubInstance apiHubInstance = ApiHubInstance.newBuilder().build();
                          +   *   FieldMask updateMask = FieldMask.newBuilder().build();
                          +   *   ApiHubInstance response =
                          +   *       provisioningClient.updateApiHubInstanceAsync(apiHubInstance, updateMask).get();
                          +   * }
                          +   * }
                          + * + * @param apiHubInstance Required. The ApiHub instance to update. + *

                          The ApiHub instance's `name` field is used to identify the ApiHub instance to update. + * Format: `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`. + * @param updateMask Required. The list of fields to update. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateApiHubInstanceAsync( + ApiHubInstance apiHubInstance, FieldMask updateMask) { + UpdateApiHubInstanceRequest request = + UpdateApiHubInstanceRequest.newBuilder() + .setApiHubInstance(apiHubInstance) + .setUpdateMask(updateMask) + .build(); + return updateApiHubInstanceAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update an Api Hub instance. The following fields in the + * [ApiHubInstance][google.cloud.apihub.v1.ApiHubInstance] can be updated: + * + *

                            + *
                          • [disable_search][ApiHubInstance.config.disable_search] + *
                          • [vertex_location][ApiHubInstance.config.vertex_location] + *
                          • [agent_registry_sync_config][ApiHubInstance.config.agent_registry_sync_config] + *
                          + * + *

                          The [update_mask][google.cloud.apihub.v1.UpdateApiHubInstanceRequest.update_mask] should be + * used to specify the fields being updated. + * + *

                          Sample code: + * + *

                          {@code
                          +   * // This snippet has been automatically generated and should be regarded as a code template only.
                          +   * // It will require modifications to work:
                          +   * // - It may require correct/in-range values for request initialization.
                          +   * // - It may require specifying regional endpoints when creating the service client as shown in
                          +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                          +   * try (ProvisioningClient provisioningClient = ProvisioningClient.create()) {
                          +   *   UpdateApiHubInstanceRequest request =
                          +   *       UpdateApiHubInstanceRequest.newBuilder()
                          +   *           .setApiHubInstance(ApiHubInstance.newBuilder().build())
                          +   *           .setUpdateMask(FieldMask.newBuilder().build())
                          +   *           .build();
                          +   *   ApiHubInstance response = provisioningClient.updateApiHubInstanceAsync(request).get();
                          +   * }
                          +   * }
                          + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateApiHubInstanceAsync( + UpdateApiHubInstanceRequest request) { + return updateApiHubInstanceOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update an Api Hub instance. The following fields in the + * [ApiHubInstance][google.cloud.apihub.v1.ApiHubInstance] can be updated: + * + *
                            + *
                          • [disable_search][ApiHubInstance.config.disable_search] + *
                          • [vertex_location][ApiHubInstance.config.vertex_location] + *
                          • [agent_registry_sync_config][ApiHubInstance.config.agent_registry_sync_config] + *
                          + * + *

                          The [update_mask][google.cloud.apihub.v1.UpdateApiHubInstanceRequest.update_mask] should be + * used to specify the fields being updated. + * + *

                          Sample code: + * + *

                          {@code
                          +   * // This snippet has been automatically generated and should be regarded as a code template only.
                          +   * // It will require modifications to work:
                          +   * // - It may require correct/in-range values for request initialization.
                          +   * // - It may require specifying regional endpoints when creating the service client as shown in
                          +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                          +   * try (ProvisioningClient provisioningClient = ProvisioningClient.create()) {
                          +   *   UpdateApiHubInstanceRequest request =
                          +   *       UpdateApiHubInstanceRequest.newBuilder()
                          +   *           .setApiHubInstance(ApiHubInstance.newBuilder().build())
                          +   *           .setUpdateMask(FieldMask.newBuilder().build())
                          +   *           .build();
                          +   *   OperationFuture future =
                          +   *       provisioningClient.updateApiHubInstanceOperationCallable().futureCall(request);
                          +   *   // Do something.
                          +   *   ApiHubInstance response = future.get();
                          +   * }
                          +   * }
                          + */ + public final OperationCallable + updateApiHubInstanceOperationCallable() { + return stub.updateApiHubInstanceOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update an Api Hub instance. The following fields in the + * [ApiHubInstance][google.cloud.apihub.v1.ApiHubInstance] can be updated: + * + *
                            + *
                          • [disable_search][ApiHubInstance.config.disable_search] + *
                          • [vertex_location][ApiHubInstance.config.vertex_location] + *
                          • [agent_registry_sync_config][ApiHubInstance.config.agent_registry_sync_config] + *
                          + * + *

                          The [update_mask][google.cloud.apihub.v1.UpdateApiHubInstanceRequest.update_mask] should be + * used to specify the fields being updated. + * + *

                          Sample code: + * + *

                          {@code
                          +   * // This snippet has been automatically generated and should be regarded as a code template only.
                          +   * // It will require modifications to work:
                          +   * // - It may require correct/in-range values for request initialization.
                          +   * // - It may require specifying regional endpoints when creating the service client as shown in
                          +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                          +   * try (ProvisioningClient provisioningClient = ProvisioningClient.create()) {
                          +   *   UpdateApiHubInstanceRequest request =
                          +   *       UpdateApiHubInstanceRequest.newBuilder()
                          +   *           .setApiHubInstance(ApiHubInstance.newBuilder().build())
                          +   *           .setUpdateMask(FieldMask.newBuilder().build())
                          +   *           .build();
                          +   *   ApiFuture future =
                          +   *       provisioningClient.updateApiHubInstanceCallable().futureCall(request);
                          +   *   // Do something.
                          +   *   Operation response = future.get();
                          +   * }
                          +   * }
                          + */ + public final UnaryCallable + updateApiHubInstanceCallable() { + return stub.updateApiHubInstanceCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Looks up an Api Hub instance in a given Google Cloud project. There will always be only one Api + * Hub instance for a Google Cloud project across all locations. * *

                          Sample code: * @@ -749,9 +948,9 @@ public final UnaryCallable getApiHubIn * } * }

                    * - * @param parent Required. There will always be only one Api Hub instance for a GCP project across - * all locations. The parent resource for the Api Hub instance resource. Format: - * `projects/{project}/locations/{location}` + * @param parent Required. There will always be only one Api Hub instance for a Google Cloud + * project across all locations. The parent resource for the Api Hub instance resource. + * Format: `projects/{project}/locations/{location}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final LookupApiHubInstanceResponse lookupApiHubInstance(@Nullable LocationName parent) { @@ -764,8 +963,8 @@ public final LookupApiHubInstanceResponse lookupApiHubInstance(@Nullable Locatio // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Looks up an Api Hub instance in a given GCP project. There will always be only one Api Hub - * instance for a GCP project across all locations. + * Looks up an Api Hub instance in a given Google Cloud project. There will always be only one Api + * Hub instance for a Google Cloud project across all locations. * *

                    Sample code: * @@ -781,9 +980,9 @@ public final LookupApiHubInstanceResponse lookupApiHubInstance(@Nullable Locatio * } * }

                    * - * @param parent Required. There will always be only one Api Hub instance for a GCP project across - * all locations. The parent resource for the Api Hub instance resource. Format: - * `projects/{project}/locations/{location}` + * @param parent Required. There will always be only one Api Hub instance for a Google Cloud + * project across all locations. The parent resource for the Api Hub instance resource. + * Format: `projects/{project}/locations/{location}` * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final LookupApiHubInstanceResponse lookupApiHubInstance(String parent) { @@ -794,8 +993,8 @@ public final LookupApiHubInstanceResponse lookupApiHubInstance(String parent) { // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Looks up an Api Hub instance in a given GCP project. There will always be only one Api Hub - * instance for a GCP project across all locations. + * Looks up an Api Hub instance in a given Google Cloud project. There will always be only one Api + * Hub instance for a Google Cloud project across all locations. * *

                    Sample code: * @@ -824,8 +1023,8 @@ public final LookupApiHubInstanceResponse lookupApiHubInstance( // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Looks up an Api Hub instance in a given GCP project. There will always be only one Api Hub - * instance for a GCP project across all locations. + * Looks up an Api Hub instance in a given Google Cloud project. There will always be only one Api + * Hub instance for a Google Cloud project across all locations. * *

                    Sample code: * @@ -856,6 +1055,18 @@ public final LookupApiHubInstanceResponse lookupApiHubInstance( /** * Lists information about the supported locations for this service. * + *

                    This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                    For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                    Sample code: * *

                    {@code
                    @@ -889,6 +1100,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
                       /**
                        * Lists information about the supported locations for this service.
                        *
                    +   * 

                    This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                    For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                    Sample code: * *

                    {@code
                    @@ -923,6 +1146,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
                       /**
                        * Lists information about the supported locations for this service.
                        *
                    +   * 

                    This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                    For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                    Sample code: * *

                    {@code
                    diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ProvisioningSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ProvisioningSettings.java
                    index a0db870edc45..480b0d59f97e 100644
                    --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ProvisioningSettings.java
                    +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/ProvisioningSettings.java
                    @@ -147,6 +147,17 @@ public UnaryCallSettings getApiHubInst
                         return ((ProvisioningStubSettings) getStubSettings()).getApiHubInstanceSettings();
                       }
                     
                    +  /** Returns the object with the settings used for calls to updateApiHubInstance. */
                    +  public UnaryCallSettings updateApiHubInstanceSettings() {
                    +    return ((ProvisioningStubSettings) getStubSettings()).updateApiHubInstanceSettings();
                    +  }
                    +
                    +  /** Returns the object with the settings used for calls to updateApiHubInstance. */
                    +  public OperationCallSettings
                    +      updateApiHubInstanceOperationSettings() {
                    +    return ((ProvisioningStubSettings) getStubSettings()).updateApiHubInstanceOperationSettings();
                    +  }
                    +
                       /** Returns the object with the settings used for calls to lookupApiHubInstance. */
                       public UnaryCallSettings
                           lookupApiHubInstanceSettings() {
                    @@ -292,6 +303,19 @@ public Builder applyToAllUnaryMethods(
                           return getStubSettingsBuilder().getApiHubInstanceSettings();
                         }
                     
                    +    /** Returns the builder for the settings used for calls to updateApiHubInstance. */
                    +    public UnaryCallSettings.Builder
                    +        updateApiHubInstanceSettings() {
                    +      return getStubSettingsBuilder().updateApiHubInstanceSettings();
                    +    }
                    +
                    +    /** Returns the builder for the settings used for calls to updateApiHubInstance. */
                    +    public OperationCallSettings.Builder<
                    +            UpdateApiHubInstanceRequest, ApiHubInstance, OperationMetadata>
                    +        updateApiHubInstanceOperationSettings() {
                    +      return getStubSettingsBuilder().updateApiHubInstanceOperationSettings();
                    +    }
                    +
                         /** Returns the builder for the settings used for calls to lookupApiHubInstance. */
                         public UnaryCallSettings.Builder
                             lookupApiHubInstanceSettings() {
                    diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/RuntimeProjectAttachmentServiceClient.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/RuntimeProjectAttachmentServiceClient.java
                    index 8baafb7bdffd..10046aa2432a 100644
                    --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/RuntimeProjectAttachmentServiceClient.java
                    +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/RuntimeProjectAttachmentServiceClient.java
                    @@ -173,7 +173,9 @@
                      *    
                      *    
                      *      

                    ListLocations - *

                    Lists information about the supported locations for this service. + *

                    Lists information about the supported locations for this service. + *

                    This method lists locations based on the resource scope provided inthe [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: ***Global locations**: If `name` is empty, the method lists thepublic locations available to all projects. * **Project-specificlocations**: If `name` follows the format`projects/{project}`, the method lists locations visible to thatspecific project. This includes public, private, or otherproject-specific locations enabled for the project. + *

                    For gRPC and client library implementations, the resource name ispassed as the `name` field. For direct service calls, the resourcename isincorporated into the request path based on the specific serviceimplementation and version. * *

                    Request object method variants only take one parameter, a request object, which must be constructed before the call.

                    *
                      @@ -1056,6 +1058,18 @@ public final LookupRuntimeProjectAttachmentResponse lookupRuntimeProjectAttachme /** * Lists information about the supported locations for this service. * + *

                      This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                      For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                      Sample code: * *

                      {@code
                      @@ -1091,6 +1105,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
                         /**
                          * Lists information about the supported locations for this service.
                          *
                      +   * 

                      This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                      For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                      Sample code: * *

                      {@code
                      @@ -1126,6 +1152,18 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque
                         /**
                          * Lists information about the supported locations for this service.
                          *
                      +   * 

                      This method lists locations based on the resource scope provided inthe + * [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: + * ***Global locations**: If `name` is empty, the method lists thepublic + * locations available to all projects. * **Project-specificlocations**: If + * `name` follows the format`projects/{project}`, the method lists locations visible to + * thatspecific project. This includes public, private, or otherproject-specific locations enabled + * for the project. + * + *

                      For gRPC and client library implementations, the resource name ispassed as the `name` field. + * For direct service calls, the resourcename isincorporated into the request path based on the + * specific serviceimplementation and version. + * *

                      Sample code: * *

                      {@code
                      diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/gapic_metadata.json b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/gapic_metadata.json
                      index c227041503f8..0aaeac48ac13 100644
                      --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/gapic_metadata.json
                      +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/gapic_metadata.json
                      @@ -5,11 +5,38 @@
                         "protoPackage": "google.cloud.apihub.v1",
                         "libraryPackage": "com.google.cloud.apihub.v1",
                         "services": {
                      +    "ApiHubAddon": {
                      +      "clients": {
                      +        "grpc": {
                      +          "libraryClient": "ApiHubAddonClient",
                      +          "rpcs": {
                      +            "GetAddon": {
                      +              "methods": ["getAddon", "getAddon", "getAddon", "getAddonCallable"]
                      +            },
                      +            "GetLocation": {
                      +              "methods": ["getLocation", "getLocationCallable"]
                      +            },
                      +            "ListAddons": {
                      +              "methods": ["listAddons", "listAddons", "listAddons", "listAddonsPagedCallable", "listAddonsCallable"]
                      +            },
                      +            "ListLocations": {
                      +              "methods": ["listLocations", "listLocationsPagedCallable", "listLocationsCallable"]
                      +            },
                      +            "ManageAddonConfig": {
                      +              "methods": ["manageAddonConfigAsync", "manageAddonConfigAsync", "manageAddonConfigAsync", "manageAddonConfigOperationCallable", "manageAddonConfigCallable"]
                      +            }
                      +          }
                      +        }
                      +      }
                      +    },
                           "ApiHub": {
                             "clients": {
                               "grpc": {
                                 "libraryClient": "ApiHubClient",
                                 "rpcs": {
                      +            "ConfigureAndDeployServer": {
                      +              "methods": ["configureAndDeployServerAsync", "configureAndDeployServerAsync", "configureAndDeployServerAsync", "configureAndDeployServerOperationCallable", "configureAndDeployServerCallable"]
                      +            },
                                   "CreateApi": {
                                     "methods": ["createApi", "createApi", "createApi", "createApiCallable"]
                                   },
                      @@ -52,6 +79,9 @@
                                   "DeleteVersion": {
                                     "methods": ["deleteVersion", "deleteVersion", "deleteVersion", "deleteVersionCallable"]
                                   },
                      +            "FetchAdditionalSpecContent": {
                      +              "methods": ["fetchAdditionalSpecContent", "fetchAdditionalSpecContent", "fetchAdditionalSpecContent", "fetchAdditionalSpecContentCallable"]
                      +            },
                                   "GetApi": {
                                     "methods": ["getApi", "getApi", "getApi", "getApiCallable"]
                                   },
                      @@ -106,6 +136,9 @@
                                   "ListVersions": {
                                     "methods": ["listVersions", "listVersions", "listVersions", "listVersionsPagedCallable", "listVersionsCallable"]
                                   },
                      +            "RetrieveApiViews": {
                      +              "methods": ["retrieveApiViews", "retrieveApiViews", "retrieveApiViews", "retrieveApiViewsPagedCallable", "retrieveApiViewsCallable"]
                      +            },
                                   "SearchResources": {
                                     "methods": ["searchResources", "searchResources", "searchResources", "searchResourcesPagedCallable", "searchResourcesCallable"]
                                   },
                      @@ -340,6 +373,9 @@
                                   "ListPlugins": {
                                     "methods": ["listPlugins", "listPlugins", "listPlugins", "listPluginsPagedCallable", "listPluginsCallable"]
                                   },
                      +            "ManagePluginInstanceSourceData": {
                      +              "methods": ["managePluginInstanceSourceData", "managePluginInstanceSourceData", "managePluginInstanceSourceData", "managePluginInstanceSourceDataCallable"]
                      +            },
                                   "UpdatePluginInstance": {
                                     "methods": ["updatePluginInstance", "updatePluginInstance", "updatePluginInstanceCallable"]
                                   }
                      @@ -369,6 +405,9 @@
                                   },
                                   "LookupApiHubInstance": {
                                     "methods": ["lookupApiHubInstance", "lookupApiHubInstance", "lookupApiHubInstance", "lookupApiHubInstanceCallable"]
                      +            },
                      +            "UpdateApiHubInstance": {
                      +              "methods": ["updateApiHubInstanceAsync", "updateApiHubInstanceAsync", "updateApiHubInstanceOperationCallable", "updateApiHubInstanceCallable"]
                                   }
                                 }
                               }
                      diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/package-info.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/package-info.java
                      index dc53d702879c..dd73a9d5adef 100644
                      --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/package-info.java
                      +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/package-info.java
                      @@ -19,6 +19,24 @@
                        *
                        * 

                      The interfaces provided are listed below, along with usage samples. * + *

                      ======================= ApiHubAddonClient ======================= + * + *

                      Service Description: This service is used for managing addons inside the API Hub. + * + *

                      Sample for ApiHubAddonClient: + * + *

                      {@code
                      + * // This snippet has been automatically generated and should be regarded as a code template only.
                      + * // It will require modifications to work:
                      + * // - It may require correct/in-range values for request initialization.
                      + * // - It may require specifying regional endpoints when creating the service client as shown in
                      + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      + * try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) {
                      + *   AddonName name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]");
                      + *   Addon response = apiHubAddonClient.getAddon(name);
                      + * }
                      + * }
                      + * *

                      ======================= ApiHubClient ======================= * *

                      Service Description: This service provides all methods related to the API hub. diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubAddonStub.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubAddonStub.java new file mode 100644 index 000000000000..9eb2b99123fa --- /dev/null +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubAddonStub.java @@ -0,0 +1,92 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.stub; + +import static com.google.cloud.apihub.v1.ApiHubAddonClient.ListAddonsPagedResponse; +import static com.google.cloud.apihub.v1.ApiHubAddonClient.ListLocationsPagedResponse; + +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.httpjson.longrunning.stub.OperationsStub; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.GetAddonRequest; +import com.google.cloud.apihub.v1.ListAddonsRequest; +import com.google.cloud.apihub.v1.ListAddonsResponse; +import com.google.cloud.apihub.v1.ManageAddonConfigRequest; +import com.google.cloud.apihub.v1.OperationMetadata; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.longrunning.Operation; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Base stub class for the ApiHubAddon service API. + * + *

                      This class is for advanced usage and reflects the underlying API directly. + */ +@NullMarked +@Generated("by gapic-generator-java") +public abstract class ApiHubAddonStub implements BackgroundResource { + + public @Nullable OperationsStub getHttpJsonOperationsStub() { + throw new UnsupportedOperationException("Not implemented: getHttpJsonOperationsStub()"); + } + + public UnaryCallable getAddonCallable() { + throw new UnsupportedOperationException("Not implemented: getAddonCallable()"); + } + + public OperationCallable + manageAddonConfigOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: manageAddonConfigOperationCallable()"); + } + + public UnaryCallable manageAddonConfigCallable() { + throw new UnsupportedOperationException("Not implemented: manageAddonConfigCallable()"); + } + + public UnaryCallable listAddonsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listAddonsPagedCallable()"); + } + + public UnaryCallable listAddonsCallable() { + throw new UnsupportedOperationException("Not implemented: listAddonsCallable()"); + } + + public UnaryCallable + listLocationsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listLocationsPagedCallable()"); + } + + public UnaryCallable listLocationsCallable() { + throw new UnsupportedOperationException("Not implemented: listLocationsCallable()"); + } + + public UnaryCallable getLocationCallable() { + throw new UnsupportedOperationException("Not implemented: getLocationCallable()"); + } + + @Override + public abstract void close(); +} diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubAddonStubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubAddonStubSettings.java new file mode 100644 index 000000000000..9c0e9d205603 --- /dev/null +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubAddonStubSettings.java @@ -0,0 +1,627 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.stub; + +import static com.google.cloud.apihub.v1.ApiHubAddonClient.ListAddonsPagedResponse; +import static com.google.cloud.apihub.v1.ApiHubAddonClient.ListLocationsPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.ApiFuture; +import com.google.api.core.ObsoleteApi; +import com.google.api.gax.core.GaxProperties; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.httpjson.GaxHttpJsonProperties; +import com.google.api.gax.httpjson.HttpJsonTransportChannel; +import com.google.api.gax.httpjson.InstantiatingHttpJsonChannelProvider; +import com.google.api.gax.httpjson.ProtoOperationTransformers; +import com.google.api.gax.longrunning.OperationSnapshot; +import com.google.api.gax.longrunning.OperationTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.rpc.ApiCallContext; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.LibraryMetadata; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.PagedListDescriptor; +import com.google.api.gax.rpc.PagedListResponseFactory; +import com.google.api.gax.rpc.StatusCode; +import com.google.api.gax.rpc.StubSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.GetAddonRequest; +import com.google.cloud.apihub.v1.ListAddonsRequest; +import com.google.cloud.apihub.v1.ListAddonsResponse; +import com.google.cloud.apihub.v1.ManageAddonConfigRequest; +import com.google.cloud.apihub.v1.OperationMetadata; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.collect.ImmutableList; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableSet; +import com.google.common.collect.Lists; +import com.google.longrunning.Operation; +import java.io.IOException; +import java.time.Duration; +import java.util.List; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link ApiHubAddonStub}. + * + *

                      The default instance has everything set to sensible defaults: + * + *

                        + *
                      • The default service address (apihub.googleapis.com) and default port (443) are used. + *
                      • Credentials are acquired automatically through Application Default Credentials. + *
                      • Retries are configured for idempotent methods but not for non-idempotent methods. + *
                      + * + *

                      The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. + * + *

                      For example, to set the + * [RetrySettings](https://cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.retrying.RetrySettings) + * of getAddon: + * + *

                      {@code
                      + * // This snippet has been automatically generated and should be regarded as a code template only.
                      + * // It will require modifications to work:
                      + * // - It may require correct/in-range values for request initialization.
                      + * // - It may require specifying regional endpoints when creating the service client as shown in
                      + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      + * ApiHubAddonStubSettings.Builder apiHubAddonSettingsBuilder =
                      + *     ApiHubAddonStubSettings.newBuilder();
                      + * apiHubAddonSettingsBuilder
                      + *     .getAddonSettings()
                      + *     .setRetrySettings(
                      + *         apiHubAddonSettingsBuilder
                      + *             .getAddonSettings()
                      + *             .getRetrySettings()
                      + *             .toBuilder()
                      + *             .setInitialRetryDelayDuration(Duration.ofSeconds(1))
                      + *             .setInitialRpcTimeoutDuration(Duration.ofSeconds(5))
                      + *             .setMaxAttempts(5)
                      + *             .setMaxRetryDelayDuration(Duration.ofSeconds(30))
                      + *             .setMaxRpcTimeoutDuration(Duration.ofSeconds(60))
                      + *             .setRetryDelayMultiplier(1.3)
                      + *             .setRpcTimeoutMultiplier(1.5)
                      + *             .setTotalTimeoutDuration(Duration.ofSeconds(300))
                      + *             .build());
                      + * ApiHubAddonStubSettings apiHubAddonSettings = apiHubAddonSettingsBuilder.build();
                      + * }
                      + * + * Please refer to the [Client Side Retry + * Guide](https://docs.cloud.google.com/java/docs/client-retries) for additional support in setting + * retries. + * + *

                      To configure the RetrySettings of a Long Running Operation method, create an + * OperationTimedPollAlgorithm object and update the RPC's polling algorithm. For example, to + * configure the RetrySettings for manageAddonConfig: + * + *

                      {@code
                      + * // This snippet has been automatically generated and should be regarded as a code template only.
                      + * // It will require modifications to work:
                      + * // - It may require correct/in-range values for request initialization.
                      + * // - It may require specifying regional endpoints when creating the service client as shown in
                      + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      + * ApiHubAddonStubSettings.Builder apiHubAddonSettingsBuilder =
                      + *     ApiHubAddonStubSettings.newBuilder();
                      + * TimedRetryAlgorithm timedRetryAlgorithm =
                      + *     OperationalTimedPollAlgorithm.create(
                      + *         RetrySettings.newBuilder()
                      + *             .setInitialRetryDelayDuration(Duration.ofMillis(500))
                      + *             .setRetryDelayMultiplier(1.5)
                      + *             .setMaxRetryDelayDuration(Duration.ofMillis(5000))
                      + *             .setTotalTimeoutDuration(Duration.ofHours(24))
                      + *             .build());
                      + * apiHubAddonSettingsBuilder
                      + *     .createClusterOperationSettings()
                      + *     .setPollingAlgorithm(timedRetryAlgorithm)
                      + *     .build();
                      + * }
                      + */ +@NullMarked +@Generated("by gapic-generator-java") +@SuppressWarnings("CanonicalDuration") +public class ApiHubAddonStubSettings extends StubSettings { + /** The default scopes of the service. */ + private static final ImmutableList DEFAULT_SERVICE_SCOPES = + ImmutableList.builder() + .add("https://www.googleapis.com/auth/apihub.readonly") + .add("https://www.googleapis.com/auth/apihub.readwrite") + .add("https://www.googleapis.com/auth/cloud-platform") + .build(); + + private final UnaryCallSettings getAddonSettings; + private final UnaryCallSettings manageAddonConfigSettings; + private final OperationCallSettings + manageAddonConfigOperationSettings; + private final PagedCallSettings + listAddonsSettings; + private final PagedCallSettings< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings; + private final UnaryCallSettings getLocationSettings; + + private static final PagedListDescriptor + LIST_ADDONS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListAddonsRequest injectToken(ListAddonsRequest payload, String token) { + return ListAddonsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListAddonsRequest injectPageSize(ListAddonsRequest payload, int pageSize) { + return ListAddonsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListAddonsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListAddonsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListAddonsResponse payload) { + return payload.getAddonsList(); + } + }; + + private static final PagedListDescriptor + LIST_LOCATIONS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListLocationsRequest injectToken(ListLocationsRequest payload, String token) { + return ListLocationsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListLocationsRequest injectPageSize(ListLocationsRequest payload, int pageSize) { + return ListLocationsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListLocationsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListLocationsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListLocationsResponse payload) { + return payload.getLocationsList(); + } + }; + + private static final PagedListResponseFactory< + ListAddonsRequest, ListAddonsResponse, ListAddonsPagedResponse> + LIST_ADDONS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListAddonsRequest, ListAddonsResponse, ListAddonsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListAddonsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_ADDONS_PAGE_STR_DESC, request, context); + return ListAddonsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + LIST_LOCATIONS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListLocationsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_LOCATIONS_PAGE_STR_DESC, request, context); + return ListLocationsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + /** Returns the object with the settings used for calls to getAddon. */ + public UnaryCallSettings getAddonSettings() { + return getAddonSettings; + } + + /** Returns the object with the settings used for calls to manageAddonConfig. */ + public UnaryCallSettings manageAddonConfigSettings() { + return manageAddonConfigSettings; + } + + /** Returns the object with the settings used for calls to manageAddonConfig. */ + public OperationCallSettings + manageAddonConfigOperationSettings() { + return manageAddonConfigOperationSettings; + } + + /** Returns the object with the settings used for calls to listAddons. */ + public PagedCallSettings + listAddonsSettings() { + return listAddonsSettings; + } + + /** Returns the object with the settings used for calls to listLocations. */ + public PagedCallSettings + listLocationsSettings() { + return listLocationsSettings; + } + + /** Returns the object with the settings used for calls to getLocation. */ + public UnaryCallSettings getLocationSettings() { + return getLocationSettings; + } + + public ApiHubAddonStub createStub() throws IOException { + if (getTransportChannelProvider() + .getTransportName() + .equals(HttpJsonTransportChannel.getHttpJsonTransportName())) { + return HttpJsonApiHubAddonStub.create(this); + } + throw new UnsupportedOperationException( + String.format( + "Transport not supported: %s", getTransportChannelProvider().getTransportName())); + } + + /** Returns the default service name. */ + @Override + public String getServiceName() { + return "apihub"; + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return InstantiatingExecutorProvider.newBuilder(); + } + + /** Returns the default service endpoint. */ + @ObsoleteApi("Use getEndpoint() instead") + public static String getDefaultEndpoint() { + return "apihub.googleapis.com:443"; + } + + /** Returns the default mTLS service endpoint. */ + public static String getDefaultMtlsEndpoint() { + return "apihub.mtls.googleapis.com:443"; + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return DEFAULT_SERVICE_SCOPES; + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return GoogleCredentialsProvider.newBuilder() + .setScopesToApply(DEFAULT_SERVICE_SCOPES) + .setUseJwtAccessWithScope(true); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingHttpJsonChannelProvider.Builder + defaultHttpJsonTransportProviderBuilder() { + return InstantiatingHttpJsonChannelProvider.newBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return defaultHttpJsonTransportProviderBuilder().build(); + } + + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken( + "gapic", GaxProperties.getLibraryVersion(ApiHubAddonStubSettings.class)) + .setTransportToken( + GaxHttpJsonProperties.getHttpJsonTokenName(), + GaxHttpJsonProperties.getHttpJsonVersion()); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(@Nullable ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected ApiHubAddonStubSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + + getAddonSettings = settingsBuilder.getAddonSettings().build(); + manageAddonConfigSettings = settingsBuilder.manageAddonConfigSettings().build(); + manageAddonConfigOperationSettings = + settingsBuilder.manageAddonConfigOperationSettings().build(); + listAddonsSettings = settingsBuilder.listAddonsSettings().build(); + listLocationsSettings = settingsBuilder.listLocationsSettings().build(); + getLocationSettings = settingsBuilder.getLocationSettings().build(); + } + + @Override + protected LibraryMetadata getLibraryMetadata() { + return LibraryMetadata.newBuilder() + .setArtifactName("com.google.cloud:google-cloud-apihub") + .setRepository("googleapis/google-cloud-java") + .setVersion(Version.VERSION) + .build(); + } + + /** Builder for ApiHubAddonStubSettings. */ + public static class Builder extends StubSettings.Builder { + private final ImmutableList> unaryMethodSettingsBuilders; + private final UnaryCallSettings.Builder getAddonSettings; + private final UnaryCallSettings.Builder + manageAddonConfigSettings; + private final OperationCallSettings.Builder + manageAddonConfigOperationSettings; + private final PagedCallSettings.Builder< + ListAddonsRequest, ListAddonsResponse, ListAddonsPagedResponse> + listAddonsSettings; + private final PagedCallSettings.Builder< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings; + private final UnaryCallSettings.Builder getLocationSettings; + private static final ImmutableMap> + RETRYABLE_CODE_DEFINITIONS; + + static { + ImmutableMap.Builder> definitions = + ImmutableMap.builder(); + definitions.put( + "retry_policy_0_codes", + ImmutableSet.copyOf(Lists.newArrayList(StatusCode.Code.UNAVAILABLE))); + definitions.put( + "no_retry_1_codes", ImmutableSet.copyOf(Lists.newArrayList())); + definitions.put("no_retry_codes", ImmutableSet.copyOf(Lists.newArrayList())); + RETRYABLE_CODE_DEFINITIONS = definitions.build(); + } + + private static final ImmutableMap RETRY_PARAM_DEFINITIONS; + + static { + ImmutableMap.Builder definitions = ImmutableMap.builder(); + RetrySettings settings = null; + settings = + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(1000L)) + .setRetryDelayMultiplier(1.3) + .setMaxRetryDelayDuration(Duration.ofMillis(10000L)) + .setInitialRpcTimeoutDuration(Duration.ofMillis(60000L)) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ofMillis(60000L)) + .setTotalTimeoutDuration(Duration.ofMillis(60000L)) + .build(); + definitions.put("retry_policy_0_params", settings); + settings = + RetrySettings.newBuilder() + .setInitialRpcTimeoutDuration(Duration.ofMillis(60000L)) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ofMillis(60000L)) + .setTotalTimeoutDuration(Duration.ofMillis(60000L)) + .build(); + definitions.put("no_retry_1_params", settings); + settings = RetrySettings.newBuilder().setRpcTimeoutMultiplier(1.0).build(); + definitions.put("no_retry_params", settings); + RETRY_PARAM_DEFINITIONS = definitions.build(); + } + + protected Builder() { + this(((ClientContext) null)); + } + + protected Builder(@Nullable ClientContext clientContext) { + super(clientContext); + + getAddonSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + manageAddonConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + manageAddonConfigOperationSettings = OperationCallSettings.newBuilder(); + listAddonsSettings = PagedCallSettings.newBuilder(LIST_ADDONS_PAGE_STR_FACT); + listLocationsSettings = PagedCallSettings.newBuilder(LIST_LOCATIONS_PAGE_STR_FACT); + getLocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + getAddonSettings, + manageAddonConfigSettings, + listAddonsSettings, + listLocationsSettings, + getLocationSettings); + initDefaults(this); + } + + protected Builder(ApiHubAddonStubSettings settings) { + super(settings); + + getAddonSettings = settings.getAddonSettings.toBuilder(); + manageAddonConfigSettings = settings.manageAddonConfigSettings.toBuilder(); + manageAddonConfigOperationSettings = settings.manageAddonConfigOperationSettings.toBuilder(); + listAddonsSettings = settings.listAddonsSettings.toBuilder(); + listLocationsSettings = settings.listLocationsSettings.toBuilder(); + getLocationSettings = settings.getLocationSettings.toBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + getAddonSettings, + manageAddonConfigSettings, + listAddonsSettings, + listLocationsSettings, + getLocationSettings); + } + + private static Builder createDefault() { + Builder builder = new Builder(((ClientContext) null)); + + builder.setTransportChannelProvider(defaultTransportChannelProvider()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); + builder.setMtlsEndpoint(getDefaultMtlsEndpoint()); + builder.setSwitchToMtlsEndpointAllowed(true); + + return initDefaults(builder); + } + + private static Builder initDefaults(Builder builder) { + builder + .getAddonSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .manageAddonConfigSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + + builder + .listAddonsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .listLocationsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getLocationSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .manageAddonConfigOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Addon.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + return builder; + } + + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

                      Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) { + super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); + return this; + } + + public ImmutableList> unaryMethodSettingsBuilders() { + return unaryMethodSettingsBuilders; + } + + /** Returns the builder for the settings used for calls to getAddon. */ + public UnaryCallSettings.Builder getAddonSettings() { + return getAddonSettings; + } + + /** Returns the builder for the settings used for calls to manageAddonConfig. */ + public UnaryCallSettings.Builder + manageAddonConfigSettings() { + return manageAddonConfigSettings; + } + + /** Returns the builder for the settings used for calls to manageAddonConfig. */ + public OperationCallSettings.Builder + manageAddonConfigOperationSettings() { + return manageAddonConfigOperationSettings; + } + + /** Returns the builder for the settings used for calls to listAddons. */ + public PagedCallSettings.Builder + listAddonsSettings() { + return listAddonsSettings; + } + + /** Returns the builder for the settings used for calls to listLocations. */ + public PagedCallSettings.Builder< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings() { + return listLocationsSettings; + } + + /** Returns the builder for the settings used for calls to getLocation. */ + public UnaryCallSettings.Builder getLocationSettings() { + return getLocationSettings; + } + + @Override + public ApiHubAddonStubSettings build() throws IOException { + return new ApiHubAddonStubSettings(this); + } + } +} diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubCollectStubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubCollectStubSettings.java index 3a31b3a45c25..093e72f538ec 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubCollectStubSettings.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubCollectStubSettings.java @@ -146,7 +146,10 @@ public class ApiHubCollectStubSettings extends StubSettings { /** The default scopes of the service. */ private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + ImmutableList.builder() + .add("https://www.googleapis.com/auth/apihub.readwrite") + .add("https://www.googleapis.com/auth/cloud-platform") + .build(); private final UnaryCallSettings collectApiDataSettings; private final OperationCallSettings< diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubCurateStubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubCurateStubSettings.java index 83a70985bd05..a9a5659d81da 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubCurateStubSettings.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubCurateStubSettings.java @@ -120,7 +120,11 @@ public class ApiHubCurateStubSettings extends StubSettings { /** The default scopes of the service. */ private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + ImmutableList.builder() + .add("https://www.googleapis.com/auth/apihub.readonly") + .add("https://www.googleapis.com/auth/apihub.readwrite") + .add("https://www.googleapis.com/auth/cloud-platform") + .build(); private final UnaryCallSettings createCurationSettings; private final UnaryCallSettings getCurationSettings; diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubDependenciesStubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubDependenciesStubSettings.java index 2143c626c481..380fde48a244 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubDependenciesStubSettings.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubDependenciesStubSettings.java @@ -122,7 +122,11 @@ public class ApiHubDependenciesStubSettings extends StubSettings { /** The default scopes of the service. */ private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + ImmutableList.builder() + .add("https://www.googleapis.com/auth/apihub.readonly") + .add("https://www.googleapis.com/auth/apihub.readwrite") + .add("https://www.googleapis.com/auth/cloud-platform") + .build(); private final UnaryCallSettings createDependencySettings; private final UnaryCallSettings getDependencySettings; diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubDiscoveryStubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubDiscoveryStubSettings.java index 771a6faf71bc..f4a2e1c371c9 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubDiscoveryStubSettings.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubDiscoveryStubSettings.java @@ -121,7 +121,11 @@ public class ApiHubDiscoveryStubSettings extends StubSettings { /** The default scopes of the service. */ private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + ImmutableList.builder() + .add("https://www.googleapis.com/auth/apihub.readonly") + .add("https://www.googleapis.com/auth/apihub.readwrite") + .add("https://www.googleapis.com/auth/cloud-platform") + .build(); private final PagedCallSettings< ListDiscoveredApiObservationsRequest, diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubPluginStub.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubPluginStub.java index c7b7325d91f7..c2712a897a12 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubPluginStub.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubPluginStub.java @@ -42,6 +42,8 @@ import com.google.cloud.apihub.v1.ListPluginInstancesResponse; import com.google.cloud.apihub.v1.ListPluginsRequest; import com.google.cloud.apihub.v1.ListPluginsResponse; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse; import com.google.cloud.apihub.v1.OperationMetadata; import com.google.cloud.apihub.v1.Plugin; import com.google.cloud.apihub.v1.PluginInstance; @@ -184,6 +186,13 @@ public UnaryCallable deletePluginInstanc throw new UnsupportedOperationException("Not implemented: deletePluginInstanceCallable()"); } + public UnaryCallable< + ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse> + managePluginInstanceSourceDataCallable() { + throw new UnsupportedOperationException( + "Not implemented: managePluginInstanceSourceDataCallable()"); + } + public UnaryCallable listLocationsPagedCallable() { throw new UnsupportedOperationException("Not implemented: listLocationsPagedCallable()"); diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubPluginStubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubPluginStubSettings.java index ea4674be7f91..30aeb89d6d81 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubPluginStubSettings.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubPluginStubSettings.java @@ -65,6 +65,8 @@ import com.google.cloud.apihub.v1.ListPluginInstancesResponse; import com.google.cloud.apihub.v1.ListPluginsRequest; import com.google.cloud.apihub.v1.ListPluginsResponse; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse; import com.google.cloud.apihub.v1.OperationMetadata; import com.google.cloud.apihub.v1.Plugin; import com.google.cloud.apihub.v1.PluginInstance; @@ -168,7 +170,11 @@ public class ApiHubPluginStubSettings extends StubSettings { /** The default scopes of the service. */ private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + ImmutableList.builder() + .add("https://www.googleapis.com/auth/apihub.readonly") + .add("https://www.googleapis.com/auth/apihub.readwrite") + .add("https://www.googleapis.com/auth/cloud-platform") + .build(); private final UnaryCallSettings getPluginSettings; private final UnaryCallSettings enablePluginSettings; @@ -214,6 +220,9 @@ public class ApiHubPluginStubSettings extends StubSettings deletePluginInstanceOperationSettings; + private final UnaryCallSettings< + ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse> + managePluginInstanceSourceDataSettings; private final PagedCallSettings< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> listLocationsSettings; @@ -500,6 +509,13 @@ public UnaryCallSettings deletePluginIns return deletePluginInstanceOperationSettings; } + /** Returns the object with the settings used for calls to managePluginInstanceSourceData. */ + public UnaryCallSettings< + ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse> + managePluginInstanceSourceDataSettings() { + return managePluginInstanceSourceDataSettings; + } + /** Returns the object with the settings used for calls to listLocations. */ public PagedCallSettings listLocationsSettings() { @@ -621,6 +637,8 @@ protected ApiHubPluginStubSettings(Builder settingsBuilder) throws IOException { deletePluginInstanceSettings = settingsBuilder.deletePluginInstanceSettings().build(); deletePluginInstanceOperationSettings = settingsBuilder.deletePluginInstanceOperationSettings().build(); + managePluginInstanceSourceDataSettings = + settingsBuilder.managePluginInstanceSourceDataSettings().build(); listLocationsSettings = settingsBuilder.listLocationsSettings().build(); getLocationSettings = settingsBuilder.getLocationSettings().build(); } @@ -687,6 +705,9 @@ public static class Builder extends StubSettings.Builder deletePluginInstanceOperationSettings; + private final UnaryCallSettings.Builder< + ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse> + managePluginInstanceSourceDataSettings; private final PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> listLocationsSettings; @@ -763,6 +784,7 @@ protected Builder(@Nullable ClientContext clientContext) { updatePluginInstanceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); deletePluginInstanceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); deletePluginInstanceOperationSettings = OperationCallSettings.newBuilder(); + managePluginInstanceSourceDataSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); listLocationsSettings = PagedCallSettings.newBuilder(LIST_LOCATIONS_PAGE_STR_FACT); getLocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -782,6 +804,7 @@ protected Builder(@Nullable ClientContext clientContext) { disablePluginInstanceActionSettings, updatePluginInstanceSettings, deletePluginInstanceSettings, + managePluginInstanceSourceDataSettings, listLocationsSettings, getLocationSettings); initDefaults(this); @@ -817,6 +840,8 @@ protected Builder(ApiHubPluginStubSettings settings) { deletePluginInstanceSettings = settings.deletePluginInstanceSettings.toBuilder(); deletePluginInstanceOperationSettings = settings.deletePluginInstanceOperationSettings.toBuilder(); + managePluginInstanceSourceDataSettings = + settings.managePluginInstanceSourceDataSettings.toBuilder(); listLocationsSettings = settings.listLocationsSettings.toBuilder(); getLocationSettings = settings.getLocationSettings.toBuilder(); @@ -836,6 +861,7 @@ protected Builder(ApiHubPluginStubSettings settings) { disablePluginInstanceActionSettings, updatePluginInstanceSettings, deletePluginInstanceSettings, + managePluginInstanceSourceDataSettings, listLocationsSettings, getLocationSettings); } @@ -923,6 +949,11 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + builder + .managePluginInstanceSourceDataSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + builder .listLocationsSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) @@ -1230,6 +1261,13 @@ public UnaryCallSettings.Builder deletePluginSet return deletePluginInstanceOperationSettings; } + /** Returns the builder for the settings used for calls to managePluginInstanceSourceData. */ + public UnaryCallSettings.Builder< + ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse> + managePluginInstanceSourceDataSettings() { + return managePluginInstanceSourceDataSettings; + } + /** Returns the builder for the settings used for calls to listLocations. */ public PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubStub.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubStub.java index 7fcb15bdca48..a12b82843d35 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubStub.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubStub.java @@ -24,13 +24,18 @@ import static com.google.cloud.apihub.v1.ApiHubClient.ListLocationsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.ListSpecsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.ListVersionsPagedResponse; +import static com.google.cloud.apihub.v1.ApiHubClient.RetrieveApiViewsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.SearchResourcesPagedResponse; import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.httpjson.longrunning.stub.OperationsStub; +import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.apihub.v1.Api; import com.google.cloud.apihub.v1.ApiOperation; import com.google.cloud.apihub.v1.Attribute; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse; import com.google.cloud.apihub.v1.CreateApiOperationRequest; import com.google.cloud.apihub.v1.CreateApiRequest; import com.google.cloud.apihub.v1.CreateAttributeRequest; @@ -48,6 +53,8 @@ import com.google.cloud.apihub.v1.DeleteVersionRequest; import com.google.cloud.apihub.v1.Deployment; import com.google.cloud.apihub.v1.ExternalApi; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse; import com.google.cloud.apihub.v1.GetApiOperationRequest; import com.google.cloud.apihub.v1.GetApiRequest; import com.google.cloud.apihub.v1.GetAttributeRequest; @@ -71,6 +78,9 @@ import com.google.cloud.apihub.v1.ListSpecsResponse; import com.google.cloud.apihub.v1.ListVersionsRequest; import com.google.cloud.apihub.v1.ListVersionsResponse; +import com.google.cloud.apihub.v1.OperationMetadata; +import com.google.cloud.apihub.v1.RetrieveApiViewsRequest; +import com.google.cloud.apihub.v1.RetrieveApiViewsResponse; import com.google.cloud.apihub.v1.SearchResourcesRequest; import com.google.cloud.apihub.v1.SearchResourcesResponse; import com.google.cloud.apihub.v1.Spec; @@ -87,9 +97,11 @@ import com.google.cloud.location.ListLocationsRequest; import com.google.cloud.location.ListLocationsResponse; import com.google.cloud.location.Location; +import com.google.longrunning.Operation; import com.google.protobuf.Empty; import javax.annotation.Generated; import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; // AUTO-GENERATED DOCUMENTATION AND CLASS. /** @@ -101,6 +113,10 @@ @Generated("by gapic-generator-java") public abstract class ApiHubStub implements BackgroundResource { + public @Nullable OperationsStub getHttpJsonOperationsStub() { + throw new UnsupportedOperationException("Not implemented: getHttpJsonOperationsStub()"); + } + public UnaryCallable createApiCallable() { throw new UnsupportedOperationException("Not implemented: createApiCallable()"); } @@ -161,6 +177,12 @@ public UnaryCallable getSpecContentsCallab throw new UnsupportedOperationException("Not implemented: getSpecContentsCallable()"); } + public UnaryCallable + fetchAdditionalSpecContentCallable() { + throw new UnsupportedOperationException( + "Not implemented: fetchAdditionalSpecContentCallable()"); + } + public UnaryCallable listSpecsPagedCallable() { throw new UnsupportedOperationException("Not implemented: listSpecsPagedCallable()"); } @@ -292,6 +314,28 @@ public UnaryCallable deleteExternalApiCallable( throw new UnsupportedOperationException("Not implemented: listExternalApisCallable()"); } + public UnaryCallable + retrieveApiViewsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: retrieveApiViewsPagedCallable()"); + } + + public UnaryCallable + retrieveApiViewsCallable() { + throw new UnsupportedOperationException("Not implemented: retrieveApiViewsCallable()"); + } + + public OperationCallable< + ConfigureAndDeployServerRequest, ConfigureAndDeployServerResponse, OperationMetadata> + configureAndDeployServerOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: configureAndDeployServerOperationCallable()"); + } + + public UnaryCallable + configureAndDeployServerCallable() { + throw new UnsupportedOperationException("Not implemented: configureAndDeployServerCallable()"); + } + public UnaryCallable listLocationsPagedCallable() { throw new UnsupportedOperationException("Not implemented: listLocationsPagedCallable()"); diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubStubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubStubSettings.java index 3182aff6f2f5..c95358bccade 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubStubSettings.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ApiHubStubSettings.java @@ -24,6 +24,7 @@ import static com.google.cloud.apihub.v1.ApiHubClient.ListLocationsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.ListSpecsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.ListVersionsPagedResponse; +import static com.google.cloud.apihub.v1.ApiHubClient.RetrieveApiViewsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.SearchResourcesPagedResponse; import com.google.api.core.ApiFunction; @@ -35,11 +36,15 @@ import com.google.api.gax.httpjson.GaxHttpJsonProperties; import com.google.api.gax.httpjson.HttpJsonTransportChannel; import com.google.api.gax.httpjson.InstantiatingHttpJsonChannelProvider; +import com.google.api.gax.httpjson.ProtoOperationTransformers; +import com.google.api.gax.longrunning.OperationSnapshot; +import com.google.api.gax.longrunning.OperationTimedPollAlgorithm; import com.google.api.gax.retrying.RetrySettings; import com.google.api.gax.rpc.ApiCallContext; import com.google.api.gax.rpc.ApiClientHeaderProvider; import com.google.api.gax.rpc.ClientContext; import com.google.api.gax.rpc.LibraryMetadata; +import com.google.api.gax.rpc.OperationCallSettings; import com.google.api.gax.rpc.PageContext; import com.google.api.gax.rpc.PagedCallSettings; import com.google.api.gax.rpc.PagedListDescriptor; @@ -51,7 +56,10 @@ import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.apihub.v1.Api; import com.google.cloud.apihub.v1.ApiOperation; +import com.google.cloud.apihub.v1.ApiView; import com.google.cloud.apihub.v1.Attribute; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse; import com.google.cloud.apihub.v1.CreateApiOperationRequest; import com.google.cloud.apihub.v1.CreateApiRequest; import com.google.cloud.apihub.v1.CreateAttributeRequest; @@ -69,6 +77,8 @@ import com.google.cloud.apihub.v1.DeleteVersionRequest; import com.google.cloud.apihub.v1.Deployment; import com.google.cloud.apihub.v1.ExternalApi; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse; import com.google.cloud.apihub.v1.GetApiOperationRequest; import com.google.cloud.apihub.v1.GetApiRequest; import com.google.cloud.apihub.v1.GetAttributeRequest; @@ -92,6 +102,9 @@ import com.google.cloud.apihub.v1.ListSpecsResponse; import com.google.cloud.apihub.v1.ListVersionsRequest; import com.google.cloud.apihub.v1.ListVersionsResponse; +import com.google.cloud.apihub.v1.OperationMetadata; +import com.google.cloud.apihub.v1.RetrieveApiViewsRequest; +import com.google.cloud.apihub.v1.RetrieveApiViewsResponse; import com.google.cloud.apihub.v1.SearchResourcesRequest; import com.google.cloud.apihub.v1.SearchResourcesResponse; import com.google.cloud.apihub.v1.SearchResult; @@ -113,6 +126,7 @@ import com.google.common.collect.ImmutableMap; import com.google.common.collect.ImmutableSet; import com.google.common.collect.Lists; +import com.google.longrunning.Operation; import com.google.protobuf.Empty; import java.io.IOException; import java.time.Duration; @@ -169,6 +183,31 @@ * Please refer to the [Client Side Retry * Guide](https://docs.cloud.google.com/java/docs/client-retries) for additional support in setting * retries. + * + *

                      To configure the RetrySettings of a Long Running Operation method, create an + * OperationTimedPollAlgorithm object and update the RPC's polling algorithm. For example, to + * configure the RetrySettings for configureAndDeployServer: + * + *

                      {@code
                      + * // This snippet has been automatically generated and should be regarded as a code template only.
                      + * // It will require modifications to work:
                      + * // - It may require correct/in-range values for request initialization.
                      + * // - It may require specifying regional endpoints when creating the service client as shown in
                      + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      + * ApiHubStubSettings.Builder apiHubSettingsBuilder = ApiHubStubSettings.newBuilder();
                      + * TimedRetryAlgorithm timedRetryAlgorithm =
                      + *     OperationalTimedPollAlgorithm.create(
                      + *         RetrySettings.newBuilder()
                      + *             .setInitialRetryDelayDuration(Duration.ofMillis(500))
                      + *             .setRetryDelayMultiplier(1.5)
                      + *             .setMaxRetryDelayDuration(Duration.ofMillis(5000))
                      + *             .setTotalTimeoutDuration(Duration.ofHours(24))
                      + *             .build());
                      + * apiHubSettingsBuilder
                      + *     .createClusterOperationSettings()
                      + *     .setPollingAlgorithm(timedRetryAlgorithm)
                      + *     .build();
                      + * }
                      */ @NullMarked @Generated("by gapic-generator-java") @@ -176,7 +215,11 @@ public class ApiHubStubSettings extends StubSettings { /** The default scopes of the service. */ private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + ImmutableList.builder() + .add("https://www.googleapis.com/auth/apihub.readonly") + .add("https://www.googleapis.com/auth/apihub.readwrite") + .add("https://www.googleapis.com/auth/cloud-platform") + .build(); private final UnaryCallSettings createApiSettings; private final UnaryCallSettings getApiSettings; @@ -194,6 +237,9 @@ public class ApiHubStubSettings extends StubSettings { private final UnaryCallSettings createSpecSettings; private final UnaryCallSettings getSpecSettings; private final UnaryCallSettings getSpecContentsSettings; + private final UnaryCallSettings< + FetchAdditionalSpecContentRequest, FetchAdditionalSpecContentResponse> + fetchAdditionalSpecContentSettings; private final PagedCallSettings listSpecsSettings; private final UnaryCallSettings updateSpecSettings; @@ -232,6 +278,14 @@ public class ApiHubStubSettings extends StubSettings { private final PagedCallSettings< ListExternalApisRequest, ListExternalApisResponse, ListExternalApisPagedResponse> listExternalApisSettings; + private final PagedCallSettings< + RetrieveApiViewsRequest, RetrieveApiViewsResponse, RetrieveApiViewsPagedResponse> + retrieveApiViewsSettings; + private final UnaryCallSettings + configureAndDeployServerSettings; + private final OperationCallSettings< + ConfigureAndDeployServerRequest, ConfigureAndDeployServerResponse, OperationMetadata> + configureAndDeployServerOperationSettings; private final PagedCallSettings< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> listLocationsSettings; @@ -524,6 +578,43 @@ public Iterable extractResources(ListExternalApisResponse payload) } }; + private static final PagedListDescriptor< + RetrieveApiViewsRequest, RetrieveApiViewsResponse, ApiView> + RETRIEVE_API_VIEWS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public RetrieveApiViewsRequest injectToken( + RetrieveApiViewsRequest payload, String token) { + return RetrieveApiViewsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public RetrieveApiViewsRequest injectPageSize( + RetrieveApiViewsRequest payload, int pageSize) { + return RetrieveApiViewsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(RetrieveApiViewsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(RetrieveApiViewsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(RetrieveApiViewsResponse payload) { + return payload.getApiViewsList(); + } + }; + private static final PagedListDescriptor LIST_LOCATIONS_PAGE_STR_DESC = new PagedListDescriptor() { @@ -701,6 +792,23 @@ public ApiFuture getFuturePagedResponse( } }; + private static final PagedListResponseFactory< + RetrieveApiViewsRequest, RetrieveApiViewsResponse, RetrieveApiViewsPagedResponse> + RETRIEVE_API_VIEWS_PAGE_STR_FACT = + new PagedListResponseFactory< + RetrieveApiViewsRequest, RetrieveApiViewsResponse, RetrieveApiViewsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + RetrieveApiViewsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, RETRIEVE_API_VIEWS_PAGE_STR_DESC, request, context); + return RetrieveApiViewsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + private static final PagedListResponseFactory< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> LIST_LOCATIONS_PAGE_STR_FACT = @@ -785,6 +893,12 @@ public UnaryCallSettings getSpecContentsSe return getSpecContentsSettings; } + /** Returns the object with the settings used for calls to fetchAdditionalSpecContent. */ + public UnaryCallSettings + fetchAdditionalSpecContentSettings() { + return fetchAdditionalSpecContentSettings; + } + /** Returns the object with the settings used for calls to listSpecs. */ public PagedCallSettings listSpecsSettings() { @@ -921,6 +1035,26 @@ public UnaryCallSettings deleteExternalApiSetti return listExternalApisSettings; } + /** Returns the object with the settings used for calls to retrieveApiViews. */ + public PagedCallSettings< + RetrieveApiViewsRequest, RetrieveApiViewsResponse, RetrieveApiViewsPagedResponse> + retrieveApiViewsSettings() { + return retrieveApiViewsSettings; + } + + /** Returns the object with the settings used for calls to configureAndDeployServer. */ + public UnaryCallSettings + configureAndDeployServerSettings() { + return configureAndDeployServerSettings; + } + + /** Returns the object with the settings used for calls to configureAndDeployServer. */ + public OperationCallSettings< + ConfigureAndDeployServerRequest, ConfigureAndDeployServerResponse, OperationMetadata> + configureAndDeployServerOperationSettings() { + return configureAndDeployServerOperationSettings; + } + /** Returns the object with the settings used for calls to listLocations. */ public PagedCallSettings listLocationsSettings() { @@ -1026,6 +1160,8 @@ protected ApiHubStubSettings(Builder settingsBuilder) throws IOException { createSpecSettings = settingsBuilder.createSpecSettings().build(); getSpecSettings = settingsBuilder.getSpecSettings().build(); getSpecContentsSettings = settingsBuilder.getSpecContentsSettings().build(); + fetchAdditionalSpecContentSettings = + settingsBuilder.fetchAdditionalSpecContentSettings().build(); listSpecsSettings = settingsBuilder.listSpecsSettings().build(); updateSpecSettings = settingsBuilder.updateSpecSettings().build(); deleteSpecSettings = settingsBuilder.deleteSpecSettings().build(); @@ -1051,6 +1187,10 @@ protected ApiHubStubSettings(Builder settingsBuilder) throws IOException { updateExternalApiSettings = settingsBuilder.updateExternalApiSettings().build(); deleteExternalApiSettings = settingsBuilder.deleteExternalApiSettings().build(); listExternalApisSettings = settingsBuilder.listExternalApisSettings().build(); + retrieveApiViewsSettings = settingsBuilder.retrieveApiViewsSettings().build(); + configureAndDeployServerSettings = settingsBuilder.configureAndDeployServerSettings().build(); + configureAndDeployServerOperationSettings = + settingsBuilder.configureAndDeployServerOperationSettings().build(); listLocationsSettings = settingsBuilder.listLocationsSettings().build(); getLocationSettings = settingsBuilder.getLocationSettings().build(); } @@ -1085,6 +1225,9 @@ public static class Builder extends StubSettings.Builder getSpecSettings; private final UnaryCallSettings.Builder getSpecContentsSettings; + private final UnaryCallSettings.Builder< + FetchAdditionalSpecContentRequest, FetchAdditionalSpecContentResponse> + fetchAdditionalSpecContentSettings; private final PagedCallSettings.Builder< ListSpecsRequest, ListSpecsResponse, ListSpecsPagedResponse> listSpecsSettings; @@ -1135,6 +1278,14 @@ public static class Builder extends StubSettings.Builder listExternalApisSettings; + private final PagedCallSettings.Builder< + RetrieveApiViewsRequest, RetrieveApiViewsResponse, RetrieveApiViewsPagedResponse> + retrieveApiViewsSettings; + private final UnaryCallSettings.Builder + configureAndDeployServerSettings; + private final OperationCallSettings.Builder< + ConfigureAndDeployServerRequest, ConfigureAndDeployServerResponse, OperationMetadata> + configureAndDeployServerOperationSettings; private final PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> listLocationsSettings; @@ -1213,6 +1364,7 @@ protected Builder(@Nullable ClientContext clientContext) { createSpecSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); getSpecSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); getSpecContentsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + fetchAdditionalSpecContentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); listSpecsSettings = PagedCallSettings.newBuilder(LIST_SPECS_PAGE_STR_FACT); updateSpecSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); deleteSpecSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -1238,6 +1390,9 @@ protected Builder(@Nullable ClientContext clientContext) { updateExternalApiSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); deleteExternalApiSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); listExternalApisSettings = PagedCallSettings.newBuilder(LIST_EXTERNAL_APIS_PAGE_STR_FACT); + retrieveApiViewsSettings = PagedCallSettings.newBuilder(RETRIEVE_API_VIEWS_PAGE_STR_FACT); + configureAndDeployServerSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + configureAndDeployServerOperationSettings = OperationCallSettings.newBuilder(); listLocationsSettings = PagedCallSettings.newBuilder(LIST_LOCATIONS_PAGE_STR_FACT); getLocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -1256,6 +1411,7 @@ protected Builder(@Nullable ClientContext clientContext) { createSpecSettings, getSpecSettings, getSpecContentsSettings, + fetchAdditionalSpecContentSettings, listSpecsSettings, updateSpecSettings, deleteSpecSettings, @@ -1281,6 +1437,8 @@ protected Builder(@Nullable ClientContext clientContext) { updateExternalApiSettings, deleteExternalApiSettings, listExternalApisSettings, + retrieveApiViewsSettings, + configureAndDeployServerSettings, listLocationsSettings, getLocationSettings); initDefaults(this); @@ -1302,6 +1460,7 @@ protected Builder(ApiHubStubSettings settings) { createSpecSettings = settings.createSpecSettings.toBuilder(); getSpecSettings = settings.getSpecSettings.toBuilder(); getSpecContentsSettings = settings.getSpecContentsSettings.toBuilder(); + fetchAdditionalSpecContentSettings = settings.fetchAdditionalSpecContentSettings.toBuilder(); listSpecsSettings = settings.listSpecsSettings.toBuilder(); updateSpecSettings = settings.updateSpecSettings.toBuilder(); deleteSpecSettings = settings.deleteSpecSettings.toBuilder(); @@ -1327,6 +1486,10 @@ protected Builder(ApiHubStubSettings settings) { updateExternalApiSettings = settings.updateExternalApiSettings.toBuilder(); deleteExternalApiSettings = settings.deleteExternalApiSettings.toBuilder(); listExternalApisSettings = settings.listExternalApisSettings.toBuilder(); + retrieveApiViewsSettings = settings.retrieveApiViewsSettings.toBuilder(); + configureAndDeployServerSettings = settings.configureAndDeployServerSettings.toBuilder(); + configureAndDeployServerOperationSettings = + settings.configureAndDeployServerOperationSettings.toBuilder(); listLocationsSettings = settings.listLocationsSettings.toBuilder(); getLocationSettings = settings.getLocationSettings.toBuilder(); @@ -1345,6 +1508,7 @@ protected Builder(ApiHubStubSettings settings) { createSpecSettings, getSpecSettings, getSpecContentsSettings, + fetchAdditionalSpecContentSettings, listSpecsSettings, updateSpecSettings, deleteSpecSettings, @@ -1370,6 +1534,8 @@ protected Builder(ApiHubStubSettings settings) { updateExternalApiSettings, deleteExternalApiSettings, listExternalApisSettings, + retrieveApiViewsSettings, + configureAndDeployServerSettings, listLocationsSettings, getLocationSettings); } @@ -1452,6 +1618,11 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + builder + .fetchAdditionalSpecContentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + builder .listSpecsSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) @@ -1577,6 +1748,16 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + builder + .retrieveApiViewsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .configureAndDeployServerSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + builder .listLocationsSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) @@ -1587,6 +1768,31 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + builder + .configureAndDeployServerOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create( + ConfigureAndDeployServerResponse.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + return builder; } @@ -1674,6 +1880,13 @@ public UnaryCallSettings.Builder getSpecSettings() { return getSpecContentsSettings; } + /** Returns the builder for the settings used for calls to fetchAdditionalSpecContent. */ + public UnaryCallSettings.Builder< + FetchAdditionalSpecContentRequest, FetchAdditionalSpecContentResponse> + fetchAdditionalSpecContentSettings() { + return fetchAdditionalSpecContentSettings; + } + /** Returns the builder for the settings used for calls to listSpecs. */ public PagedCallSettings.Builder listSpecsSettings() { @@ -1818,6 +2031,26 @@ public UnaryCallSettings.Builder deleteExternal return listExternalApisSettings; } + /** Returns the builder for the settings used for calls to retrieveApiViews. */ + public PagedCallSettings.Builder< + RetrieveApiViewsRequest, RetrieveApiViewsResponse, RetrieveApiViewsPagedResponse> + retrieveApiViewsSettings() { + return retrieveApiViewsSettings; + } + + /** Returns the builder for the settings used for calls to configureAndDeployServer. */ + public UnaryCallSettings.Builder + configureAndDeployServerSettings() { + return configureAndDeployServerSettings; + } + + /** Returns the builder for the settings used for calls to configureAndDeployServer. */ + public OperationCallSettings.Builder< + ConfigureAndDeployServerRequest, ConfigureAndDeployServerResponse, OperationMetadata> + configureAndDeployServerOperationSettings() { + return configureAndDeployServerOperationSettings; + } + /** Returns the builder for the settings used for calls to listLocations. */ public PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HostProjectRegistrationServiceStubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HostProjectRegistrationServiceStubSettings.java index 98cb69155c14..ee73d90ffd8c 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HostProjectRegistrationServiceStubSettings.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HostProjectRegistrationServiceStubSettings.java @@ -121,7 +121,11 @@ public class HostProjectRegistrationServiceStubSettings extends StubSettings { /** The default scopes of the service. */ private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + ImmutableList.builder() + .add("https://www.googleapis.com/auth/apihub.readonly") + .add("https://www.googleapis.com/auth/apihub.readwrite") + .add("https://www.googleapis.com/auth/cloud-platform") + .build(); private final UnaryCallSettings createHostProjectRegistrationSettings; diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubAddonCallableFactory.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubAddonCallableFactory.java new file mode 100644 index 000000000000..b0d487d3413e --- /dev/null +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubAddonCallableFactory.java @@ -0,0 +1,103 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.stub; + +import com.google.api.gax.httpjson.HttpJsonCallSettings; +import com.google.api.gax.httpjson.HttpJsonCallableFactory; +import com.google.api.gax.httpjson.HttpJsonOperationSnapshotCallable; +import com.google.api.gax.httpjson.HttpJsonStubCallableFactory; +import com.google.api.gax.httpjson.longrunning.stub.OperationsStub; +import com.google.api.gax.rpc.BatchingCallSettings; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallable; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.longrunning.Operation; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * REST callable factory implementation for the ApiHubAddon service API. + * + *

                      This class is for advanced usage. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class HttpJsonApiHubAddonCallableFactory + implements HttpJsonStubCallableFactory { + + @Override + public UnaryCallable createUnaryCallable( + HttpJsonCallSettings httpJsonCallSettings, + UnaryCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createUnaryCallable( + httpJsonCallSettings, callSettings, clientContext); + } + + @Override + public + UnaryCallable createPagedCallable( + HttpJsonCallSettings httpJsonCallSettings, + PagedCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createPagedCallable( + httpJsonCallSettings, callSettings, clientContext); + } + + @Override + public UnaryCallable createBatchingCallable( + HttpJsonCallSettings httpJsonCallSettings, + BatchingCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createBatchingCallable( + httpJsonCallSettings, callSettings, clientContext); + } + + @Override + public + OperationCallable createOperationCallable( + HttpJsonCallSettings httpJsonCallSettings, + OperationCallSettings callSettings, + ClientContext clientContext, + OperationsStub operationsStub) { + UnaryCallable innerCallable = + HttpJsonCallableFactory.createBaseUnaryCallable( + httpJsonCallSettings, callSettings.getInitialCallSettings(), clientContext); + HttpJsonOperationSnapshotCallable initialCallable = + new HttpJsonOperationSnapshotCallable( + innerCallable, + httpJsonCallSettings.getMethodDescriptor().getOperationSnapshotFactory()); + return HttpJsonCallableFactory.createOperationCallable( + callSettings, clientContext, operationsStub.longRunningClient(), initialCallable); + } + + @Override + public + ServerStreamingCallable createServerStreamingCallable( + HttpJsonCallSettings httpJsonCallSettings, + ServerStreamingCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createServerStreamingCallable( + httpJsonCallSettings, callSettings, clientContext); + } +} diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubAddonStub.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubAddonStub.java new file mode 100644 index 000000000000..20c96654b83e --- /dev/null +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubAddonStub.java @@ -0,0 +1,519 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.stub; + +import static com.google.cloud.apihub.v1.ApiHubAddonClient.ListAddonsPagedResponse; +import static com.google.cloud.apihub.v1.ApiHubAddonClient.ListLocationsPagedResponse; + +import com.google.api.HttpRule; +import com.google.api.core.InternalApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.core.BackgroundResourceAggregation; +import com.google.api.gax.httpjson.ApiMethodDescriptor; +import com.google.api.gax.httpjson.HttpJsonCallSettings; +import com.google.api.gax.httpjson.HttpJsonOperationSnapshot; +import com.google.api.gax.httpjson.HttpJsonStubCallableFactory; +import com.google.api.gax.httpjson.ProtoMessageRequestFormatter; +import com.google.api.gax.httpjson.ProtoMessageResponseParser; +import com.google.api.gax.httpjson.ProtoRestSerializer; +import com.google.api.gax.httpjson.longrunning.stub.HttpJsonOperationsStub; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.RequestParamsBuilder; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.GetAddonRequest; +import com.google.cloud.apihub.v1.ListAddonsRequest; +import com.google.cloud.apihub.v1.ListAddonsResponse; +import com.google.cloud.apihub.v1.ManageAddonConfigRequest; +import com.google.cloud.apihub.v1.OperationMetadata; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.collect.ImmutableMap; +import com.google.longrunning.Operation; +import com.google.protobuf.TypeRegistry; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * REST stub implementation for the ApiHubAddon service API. + * + *

                      This class is for advanced usage and reflects the underlying API directly. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class HttpJsonApiHubAddonStub extends ApiHubAddonStub { + private static final TypeRegistry typeRegistry = + TypeRegistry.newBuilder() + .add(Addon.getDescriptor()) + .add(OperationMetadata.getDescriptor()) + .build(); + + private static final ApiMethodDescriptor getAddonMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.apihub.v1.ApiHubAddon/GetAddon") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/addons/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Addon.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + manageAddonConfigMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.apihub.v1.ApiHubAddon/ManageAddonConfig") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/addons/*}:manageConfig", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("*", request.toBuilder().clearName().build(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (ManageAddonConfigRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + listAddonsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.apihub.v1.ApiHubAddon/ListAddons") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/addons", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "filter", request.getFilter()); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListAddonsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + listLocationsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.location.Locations/ListLocations") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*}/locations", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListLocationsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getLocationMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.location.Locations/GetLocation") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Location.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private final UnaryCallable getAddonCallable; + private final UnaryCallable manageAddonConfigCallable; + private final OperationCallable + manageAddonConfigOperationCallable; + private final UnaryCallable listAddonsCallable; + private final UnaryCallable listAddonsPagedCallable; + private final UnaryCallable listLocationsCallable; + private final UnaryCallable + listLocationsPagedCallable; + private final UnaryCallable getLocationCallable; + + private final BackgroundResource backgroundResources; + private final HttpJsonOperationsStub httpJsonOperationsStub; + private final HttpJsonStubCallableFactory callableFactory; + + public static final HttpJsonApiHubAddonStub create(ApiHubAddonStubSettings settings) + throws IOException { + return new HttpJsonApiHubAddonStub(settings, ClientContext.create(settings)); + } + + public static final HttpJsonApiHubAddonStub create(ClientContext clientContext) + throws IOException { + return new HttpJsonApiHubAddonStub(ApiHubAddonStubSettings.newBuilder().build(), clientContext); + } + + public static final HttpJsonApiHubAddonStub create( + ClientContext clientContext, HttpJsonStubCallableFactory callableFactory) throws IOException { + return new HttpJsonApiHubAddonStub( + ApiHubAddonStubSettings.newBuilder().build(), clientContext, callableFactory); + } + + /** + * Constructs an instance of HttpJsonApiHubAddonStub, using the given settings. This is protected + * so that it is easy to make a subclass, but otherwise, the static factory methods should be + * preferred. + */ + protected HttpJsonApiHubAddonStub(ApiHubAddonStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new HttpJsonApiHubAddonCallableFactory()); + } + + /** + * Constructs an instance of HttpJsonApiHubAddonStub, using the given settings. This is protected + * so that it is easy to make a subclass, but otherwise, the static factory methods should be + * preferred. + */ + protected HttpJsonApiHubAddonStub( + ApiHubAddonStubSettings settings, + ClientContext clientContext, + HttpJsonStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + this.httpJsonOperationsStub = + HttpJsonOperationsStub.create( + clientContext, + callableFactory, + typeRegistry, + ImmutableMap.builder() + .put( + "google.longrunning.Operations.CancelOperation", + HttpRule.newBuilder() + .setPost("/v1/{name=projects/*/locations/*/operations/*}:cancel") + .build()) + .put( + "google.longrunning.Operations.DeleteOperation", + HttpRule.newBuilder() + .setDelete("/v1/{name=projects/*/locations/*/operations/*}") + .build()) + .put( + "google.longrunning.Operations.GetOperation", + HttpRule.newBuilder() + .setGet("/v1/{name=projects/*/locations/*/operations/*}") + .build()) + .put( + "google.longrunning.Operations.ListOperations", + HttpRule.newBuilder() + .setGet("/v1/{name=projects/*/locations/*}/operations") + .build()) + .build()); + + HttpJsonCallSettings getAddonTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getAddonMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings manageAddonConfigTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(manageAddonConfigMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings listAddonsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listAddonsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings + listLocationsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listLocationsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings getLocationTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getLocationMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + + this.getAddonCallable = + callableFactory.createUnaryCallable( + getAddonTransportSettings, settings.getAddonSettings(), clientContext); + this.manageAddonConfigCallable = + callableFactory.createUnaryCallable( + manageAddonConfigTransportSettings, + settings.manageAddonConfigSettings(), + clientContext); + this.manageAddonConfigOperationCallable = + callableFactory.createOperationCallable( + manageAddonConfigTransportSettings, + settings.manageAddonConfigOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.listAddonsCallable = + callableFactory.createUnaryCallable( + listAddonsTransportSettings, settings.listAddonsSettings(), clientContext); + this.listAddonsPagedCallable = + callableFactory.createPagedCallable( + listAddonsTransportSettings, settings.listAddonsSettings(), clientContext); + this.listLocationsCallable = + callableFactory.createUnaryCallable( + listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); + this.listLocationsPagedCallable = + callableFactory.createPagedCallable( + listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); + this.getLocationCallable = + callableFactory.createUnaryCallable( + getLocationTransportSettings, settings.getLocationSettings(), clientContext); + + this.backgroundResources = + new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + @InternalApi + public static List getMethodDescriptors() { + List methodDescriptors = new ArrayList<>(); + methodDescriptors.add(getAddonMethodDescriptor); + methodDescriptors.add(manageAddonConfigMethodDescriptor); + methodDescriptors.add(listAddonsMethodDescriptor); + methodDescriptors.add(listLocationsMethodDescriptor); + methodDescriptors.add(getLocationMethodDescriptor); + return methodDescriptors; + } + + public HttpJsonOperationsStub getHttpJsonOperationsStub() { + return httpJsonOperationsStub; + } + + @Override + public UnaryCallable getAddonCallable() { + return getAddonCallable; + } + + @Override + public UnaryCallable manageAddonConfigCallable() { + return manageAddonConfigCallable; + } + + @Override + public OperationCallable + manageAddonConfigOperationCallable() { + return manageAddonConfigOperationCallable; + } + + @Override + public UnaryCallable listAddonsCallable() { + return listAddonsCallable; + } + + @Override + public UnaryCallable listAddonsPagedCallable() { + return listAddonsPagedCallable; + } + + @Override + public UnaryCallable listLocationsCallable() { + return listLocationsCallable; + } + + @Override + public UnaryCallable + listLocationsPagedCallable() { + return listLocationsPagedCallable; + } + + @Override + public UnaryCallable getLocationCallable() { + return getLocationCallable; + } + + @Override + public final void close() { + try { + backgroundResources.close(); + } catch (RuntimeException e) { + throw e; + } catch (Exception e) { + throw new IllegalStateException("Failed to close resource", e); + } + } + + @Override + public void shutdown() { + backgroundResources.shutdown(); + } + + @Override + public boolean isShutdown() { + return backgroundResources.isShutdown(); + } + + @Override + public boolean isTerminated() { + return backgroundResources.isTerminated(); + } + + @Override + public void shutdownNow() { + backgroundResources.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return backgroundResources.awaitTermination(duration, unit); + } +} diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubPluginStub.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubPluginStub.java index eb8a5f91b2f5..cb39e1a4f93f 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubPluginStub.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubPluginStub.java @@ -54,6 +54,8 @@ import com.google.cloud.apihub.v1.ListPluginInstancesResponse; import com.google.cloud.apihub.v1.ListPluginsRequest; import com.google.cloud.apihub.v1.ListPluginsResponse; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse; import com.google.cloud.apihub.v1.OperationMetadata; import com.google.cloud.apihub.v1.Plugin; import com.google.cloud.apihub.v1.PluginInstance; @@ -624,6 +626,48 @@ public class HttpJsonApiHubPluginStub extends ApiHubPluginStub { HttpJsonOperationSnapshot.create(response)) .build(); + private static final ApiMethodDescriptor< + ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse> + managePluginInstanceSourceDataMethodDescriptor = + ApiMethodDescriptor + . + newBuilder() + .setFullMethodName( + "google.cloud.apihub.v1.ApiHubPlugin/ManagePluginInstanceSourceData") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/plugins/*/instances/*}:manageSourceData", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("*", request.toBuilder().clearName().build(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance( + ManagePluginInstanceSourceDataResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + private static final ApiMethodDescriptor listLocationsMethodDescriptor = ApiMethodDescriptor.newBuilder() @@ -734,6 +778,9 @@ public class HttpJsonApiHubPluginStub extends ApiHubPluginStub { private final UnaryCallable deletePluginInstanceCallable; private final OperationCallable deletePluginInstanceOperationCallable; + private final UnaryCallable< + ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse> + managePluginInstanceSourceDataCallable; private final UnaryCallable listLocationsCallable; private final UnaryCallable listLocationsPagedCallable; @@ -987,6 +1034,22 @@ protected HttpJsonApiHubPluginStub( }) .setResourceNameExtractor(request -> request.getName()) .build(); + HttpJsonCallSettings< + ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse> + managePluginInstanceSourceDataTransportSettings = + HttpJsonCallSettings + . + newBuilder() + .setMethodDescriptor(managePluginInstanceSourceDataMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); HttpJsonCallSettings listLocationsTransportSettings = HttpJsonCallSettings.newBuilder() @@ -1113,6 +1176,11 @@ protected HttpJsonApiHubPluginStub( settings.deletePluginInstanceOperationSettings(), clientContext, httpJsonOperationsStub); + this.managePluginInstanceSourceDataCallable = + callableFactory.createUnaryCallable( + managePluginInstanceSourceDataTransportSettings, + settings.managePluginInstanceSourceDataSettings(), + clientContext); this.listLocationsCallable = callableFactory.createUnaryCallable( listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); @@ -1144,6 +1212,7 @@ public static List getMethodDescriptors() { methodDescriptors.add(disablePluginInstanceActionMethodDescriptor); methodDescriptors.add(updatePluginInstanceMethodDescriptor); methodDescriptors.add(deletePluginInstanceMethodDescriptor); + methodDescriptors.add(managePluginInstanceSourceDataMethodDescriptor); methodDescriptors.add(listLocationsMethodDescriptor); methodDescriptors.add(getLocationMethodDescriptor); return methodDescriptors; @@ -1281,6 +1350,13 @@ public UnaryCallable deletePluginInstanc return deletePluginInstanceOperationCallable; } + @Override + public UnaryCallable< + ManagePluginInstanceSourceDataRequest, ManagePluginInstanceSourceDataResponse> + managePluginInstanceSourceDataCallable() { + return managePluginInstanceSourceDataCallable; + } + @Override public UnaryCallable listLocationsCallable() { return listLocationsCallable; diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubStub.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubStub.java index 512368c2fbe6..fb9b98733101 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubStub.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonApiHubStub.java @@ -24,23 +24,30 @@ import static com.google.cloud.apihub.v1.ApiHubClient.ListLocationsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.ListSpecsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.ListVersionsPagedResponse; +import static com.google.cloud.apihub.v1.ApiHubClient.RetrieveApiViewsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.SearchResourcesPagedResponse; +import com.google.api.HttpRule; import com.google.api.core.InternalApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.httpjson.ApiMethodDescriptor; import com.google.api.gax.httpjson.HttpJsonCallSettings; +import com.google.api.gax.httpjson.HttpJsonOperationSnapshot; import com.google.api.gax.httpjson.HttpJsonStubCallableFactory; import com.google.api.gax.httpjson.ProtoMessageRequestFormatter; import com.google.api.gax.httpjson.ProtoMessageResponseParser; import com.google.api.gax.httpjson.ProtoRestSerializer; +import com.google.api.gax.httpjson.longrunning.stub.HttpJsonOperationsStub; import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.RequestParamsBuilder; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.apihub.v1.Api; import com.google.cloud.apihub.v1.ApiOperation; import com.google.cloud.apihub.v1.Attribute; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse; import com.google.cloud.apihub.v1.CreateApiOperationRequest; import com.google.cloud.apihub.v1.CreateApiRequest; import com.google.cloud.apihub.v1.CreateAttributeRequest; @@ -58,6 +65,8 @@ import com.google.cloud.apihub.v1.DeleteVersionRequest; import com.google.cloud.apihub.v1.Deployment; import com.google.cloud.apihub.v1.ExternalApi; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse; import com.google.cloud.apihub.v1.GetApiOperationRequest; import com.google.cloud.apihub.v1.GetApiRequest; import com.google.cloud.apihub.v1.GetAttributeRequest; @@ -81,6 +90,9 @@ import com.google.cloud.apihub.v1.ListSpecsResponse; import com.google.cloud.apihub.v1.ListVersionsRequest; import com.google.cloud.apihub.v1.ListVersionsResponse; +import com.google.cloud.apihub.v1.OperationMetadata; +import com.google.cloud.apihub.v1.RetrieveApiViewsRequest; +import com.google.cloud.apihub.v1.RetrieveApiViewsResponse; import com.google.cloud.apihub.v1.SearchResourcesRequest; import com.google.cloud.apihub.v1.SearchResourcesResponse; import com.google.cloud.apihub.v1.Spec; @@ -97,6 +109,8 @@ import com.google.cloud.location.ListLocationsRequest; import com.google.cloud.location.ListLocationsResponse; import com.google.cloud.location.Location; +import com.google.common.collect.ImmutableMap; +import com.google.longrunning.Operation; import com.google.protobuf.Empty; import com.google.protobuf.TypeRegistry; import java.io.IOException; @@ -117,7 +131,11 @@ @NullMarked @Generated("by gapic-generator-java") public class HttpJsonApiHubStub extends ApiHubStub { - private static final TypeRegistry typeRegistry = TypeRegistry.newBuilder().build(); + private static final TypeRegistry typeRegistry = + TypeRegistry.newBuilder() + .add(OperationMetadata.getDescriptor()) + .add(ConfigureAndDeployServerResponse.getDescriptor()) + .build(); private static final ApiMethodDescriptor createApiMethodDescriptor = ApiMethodDescriptor.newBuilder() @@ -578,6 +596,44 @@ public class HttpJsonApiHubStub extends ApiHubStub { .build()) .build(); + private static final ApiMethodDescriptor< + FetchAdditionalSpecContentRequest, FetchAdditionalSpecContentResponse> + fetchAdditionalSpecContentMethodDescriptor = + ApiMethodDescriptor + .newBuilder() + .setFullMethodName("google.cloud.apihub.v1.ApiHub/FetchAdditionalSpecContent") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:fetchAdditionalSpecContent", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam( + fields, "specContentType", request.getSpecContentTypeValue()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(FetchAdditionalSpecContentResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + private static final ApiMethodDescriptor listSpecsMethodDescriptor = ApiMethodDescriptor.newBuilder() @@ -1486,6 +1542,84 @@ public class HttpJsonApiHubStub extends ApiHubStub { .build()) .build(); + private static final ApiMethodDescriptor + retrieveApiViewsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.apihub.v1.ApiHub/RetrieveApiViews") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}:retrieveApiViews", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "filter", request.getFilter()); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + serializer.putQueryParam(fields, "view", request.getViewValue()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(RetrieveApiViewsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + configureAndDeployServerMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.apihub.v1.ApiHub/ConfigureAndDeployServer") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/servers:configureAndDeployServer", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("*", request.toBuilder().clearParent().build(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (ConfigureAndDeployServerRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + private static final ApiMethodDescriptor listLocationsMethodDescriptor = ApiMethodDescriptor.newBuilder() @@ -1570,6 +1704,8 @@ public class HttpJsonApiHubStub extends ApiHubStub { private final UnaryCallable createSpecCallable; private final UnaryCallable getSpecCallable; private final UnaryCallable getSpecContentsCallable; + private final UnaryCallable + fetchAdditionalSpecContentCallable; private final UnaryCallable listSpecsCallable; private final UnaryCallable listSpecsPagedCallable; private final UnaryCallable updateSpecCallable; @@ -1610,12 +1746,22 @@ public class HttpJsonApiHubStub extends ApiHubStub { listExternalApisCallable; private final UnaryCallable listExternalApisPagedCallable; + private final UnaryCallable + retrieveApiViewsCallable; + private final UnaryCallable + retrieveApiViewsPagedCallable; + private final UnaryCallable + configureAndDeployServerCallable; + private final OperationCallable< + ConfigureAndDeployServerRequest, ConfigureAndDeployServerResponse, OperationMetadata> + configureAndDeployServerOperationCallable; private final UnaryCallable listLocationsCallable; private final UnaryCallable listLocationsPagedCallable; private final UnaryCallable getLocationCallable; private final BackgroundResource backgroundResources; + private final HttpJsonOperationsStub httpJsonOperationsStub; private final HttpJsonStubCallableFactory callableFactory; public static final HttpJsonApiHubStub create(ApiHubStubSettings settings) throws IOException { @@ -1653,6 +1799,33 @@ protected HttpJsonApiHubStub( HttpJsonStubCallableFactory callableFactory) throws IOException { this.callableFactory = callableFactory; + this.httpJsonOperationsStub = + HttpJsonOperationsStub.create( + clientContext, + callableFactory, + typeRegistry, + ImmutableMap.builder() + .put( + "google.longrunning.Operations.CancelOperation", + HttpRule.newBuilder() + .setPost("/v1/{name=projects/*/locations/*/operations/*}:cancel") + .build()) + .put( + "google.longrunning.Operations.DeleteOperation", + HttpRule.newBuilder() + .setDelete("/v1/{name=projects/*/locations/*/operations/*}") + .build()) + .put( + "google.longrunning.Operations.GetOperation", + HttpRule.newBuilder() + .setGet("/v1/{name=projects/*/locations/*/operations/*}") + .build()) + .put( + "google.longrunning.Operations.ListOperations", + HttpRule.newBuilder() + .setGet("/v1/{name=projects/*/locations/*}/operations") + .build()) + .build()); HttpJsonCallSettings createApiTransportSettings = HttpJsonCallSettings.newBuilder() @@ -1808,6 +1981,20 @@ protected HttpJsonApiHubStub( }) .setResourceNameExtractor(request -> request.getName()) .build(); + HttpJsonCallSettings + fetchAdditionalSpecContentTransportSettings = + HttpJsonCallSettings + .newBuilder() + .setMethodDescriptor(fetchAdditionalSpecContentMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); HttpJsonCallSettings listSpecsTransportSettings = HttpJsonCallSettings.newBuilder() .setMethodDescriptor(listSpecsMethodDescriptor) @@ -2113,6 +2300,32 @@ protected HttpJsonApiHubStub( }) .setResourceNameExtractor(request -> request.getParent()) .build(); + HttpJsonCallSettings + retrieveApiViewsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(retrieveApiViewsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings + configureAndDeployServerTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(configureAndDeployServerMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); HttpJsonCallSettings listLocationsTransportSettings = HttpJsonCallSettings.newBuilder() @@ -2182,6 +2395,11 @@ protected HttpJsonApiHubStub( this.getSpecContentsCallable = callableFactory.createUnaryCallable( getSpecContentsTransportSettings, settings.getSpecContentsSettings(), clientContext); + this.fetchAdditionalSpecContentCallable = + callableFactory.createUnaryCallable( + fetchAdditionalSpecContentTransportSettings, + settings.fetchAdditionalSpecContentSettings(), + clientContext); this.listSpecsCallable = callableFactory.createUnaryCallable( listSpecsTransportSettings, settings.listSpecsSettings(), clientContext); @@ -2291,6 +2509,23 @@ protected HttpJsonApiHubStub( this.listExternalApisPagedCallable = callableFactory.createPagedCallable( listExternalApisTransportSettings, settings.listExternalApisSettings(), clientContext); + this.retrieveApiViewsCallable = + callableFactory.createUnaryCallable( + retrieveApiViewsTransportSettings, settings.retrieveApiViewsSettings(), clientContext); + this.retrieveApiViewsPagedCallable = + callableFactory.createPagedCallable( + retrieveApiViewsTransportSettings, settings.retrieveApiViewsSettings(), clientContext); + this.configureAndDeployServerCallable = + callableFactory.createUnaryCallable( + configureAndDeployServerTransportSettings, + settings.configureAndDeployServerSettings(), + clientContext); + this.configureAndDeployServerOperationCallable = + callableFactory.createOperationCallable( + configureAndDeployServerTransportSettings, + settings.configureAndDeployServerOperationSettings(), + clientContext, + httpJsonOperationsStub); this.listLocationsCallable = callableFactory.createUnaryCallable( listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); @@ -2321,6 +2556,7 @@ public static List getMethodDescriptors() { methodDescriptors.add(createSpecMethodDescriptor); methodDescriptors.add(getSpecMethodDescriptor); methodDescriptors.add(getSpecContentsMethodDescriptor); + methodDescriptors.add(fetchAdditionalSpecContentMethodDescriptor); methodDescriptors.add(listSpecsMethodDescriptor); methodDescriptors.add(updateSpecMethodDescriptor); methodDescriptors.add(deleteSpecMethodDescriptor); @@ -2346,11 +2582,17 @@ public static List getMethodDescriptors() { methodDescriptors.add(updateExternalApiMethodDescriptor); methodDescriptors.add(deleteExternalApiMethodDescriptor); methodDescriptors.add(listExternalApisMethodDescriptor); + methodDescriptors.add(retrieveApiViewsMethodDescriptor); + methodDescriptors.add(configureAndDeployServerMethodDescriptor); methodDescriptors.add(listLocationsMethodDescriptor); methodDescriptors.add(getLocationMethodDescriptor); return methodDescriptors; } + public HttpJsonOperationsStub getHttpJsonOperationsStub() { + return httpJsonOperationsStub; + } + @Override public UnaryCallable createApiCallable() { return createApiCallable; @@ -2426,6 +2668,12 @@ public UnaryCallable getSpecContentsCallab return getSpecContentsCallable; } + @Override + public UnaryCallable + fetchAdditionalSpecContentCallable() { + return fetchAdditionalSpecContentCallable; + } + @Override public UnaryCallable listSpecsCallable() { return listSpecsCallable; @@ -2588,6 +2836,31 @@ public UnaryCallable deleteExternalApiCallable( return listExternalApisPagedCallable; } + @Override + public UnaryCallable + retrieveApiViewsCallable() { + return retrieveApiViewsCallable; + } + + @Override + public UnaryCallable + retrieveApiViewsPagedCallable() { + return retrieveApiViewsPagedCallable; + } + + @Override + public UnaryCallable + configureAndDeployServerCallable() { + return configureAndDeployServerCallable; + } + + @Override + public OperationCallable< + ConfigureAndDeployServerRequest, ConfigureAndDeployServerResponse, OperationMetadata> + configureAndDeployServerOperationCallable() { + return configureAndDeployServerOperationCallable; + } + @Override public UnaryCallable listLocationsCallable() { return listLocationsCallable; diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonProvisioningStub.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonProvisioningStub.java index 9ff3ed6935ad..83ff498c6902 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonProvisioningStub.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/HttpJsonProvisioningStub.java @@ -41,6 +41,7 @@ import com.google.cloud.apihub.v1.LookupApiHubInstanceRequest; import com.google.cloud.apihub.v1.LookupApiHubInstanceResponse; import com.google.cloud.apihub.v1.OperationMetadata; +import com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest; import com.google.cloud.location.GetLocationRequest; import com.google.cloud.location.ListLocationsRequest; import com.google.cloud.location.ListLocationsResponse; @@ -187,6 +188,50 @@ public class HttpJsonProvisioningStub extends ProvisioningStub { .build()) .build(); + private static final ApiMethodDescriptor + updateApiHubInstanceMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.apihub.v1.Provisioning/UpdateApiHubInstance") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{apiHubInstance.name=projects/*/locations/*/apiHubInstances/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, + "apiHubInstance.name", + request.getApiHubInstance().getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("apiHubInstance", request.getApiHubInstance(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (UpdateApiHubInstanceRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + private static final ApiMethodDescriptor< LookupApiHubInstanceRequest, LookupApiHubInstanceResponse> lookupApiHubInstanceMethodDescriptor = @@ -298,6 +343,9 @@ public class HttpJsonProvisioningStub extends ProvisioningStub { private final OperationCallable deleteApiHubInstanceOperationCallable; private final UnaryCallable getApiHubInstanceCallable; + private final UnaryCallable updateApiHubInstanceCallable; + private final OperationCallable + updateApiHubInstanceOperationCallable; private final UnaryCallable lookupApiHubInstanceCallable; private final UnaryCallable listLocationsCallable; @@ -414,6 +462,20 @@ protected HttpJsonProvisioningStub( }) .setResourceNameExtractor(request -> request.getName()) .build(); + HttpJsonCallSettings + updateApiHubInstanceTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateApiHubInstanceMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add( + "api_hub_instance.name", + String.valueOf(request.getApiHubInstance().getName())); + return builder.build(); + }) + .build(); HttpJsonCallSettings lookupApiHubInstanceTransportSettings = HttpJsonCallSettings @@ -479,6 +541,17 @@ protected HttpJsonProvisioningStub( getApiHubInstanceTransportSettings, settings.getApiHubInstanceSettings(), clientContext); + this.updateApiHubInstanceCallable = + callableFactory.createUnaryCallable( + updateApiHubInstanceTransportSettings, + settings.updateApiHubInstanceSettings(), + clientContext); + this.updateApiHubInstanceOperationCallable = + callableFactory.createOperationCallable( + updateApiHubInstanceTransportSettings, + settings.updateApiHubInstanceOperationSettings(), + clientContext, + httpJsonOperationsStub); this.lookupApiHubInstanceCallable = callableFactory.createUnaryCallable( lookupApiHubInstanceTransportSettings, @@ -504,6 +577,7 @@ public static List getMethodDescriptors() { methodDescriptors.add(createApiHubInstanceMethodDescriptor); methodDescriptors.add(deleteApiHubInstanceMethodDescriptor); methodDescriptors.add(getApiHubInstanceMethodDescriptor); + methodDescriptors.add(updateApiHubInstanceMethodDescriptor); methodDescriptors.add(lookupApiHubInstanceMethodDescriptor); methodDescriptors.add(listLocationsMethodDescriptor); methodDescriptors.add(getLocationMethodDescriptor); @@ -541,6 +615,17 @@ public UnaryCallable getApiHubInstance return getApiHubInstanceCallable; } + @Override + public UnaryCallable updateApiHubInstanceCallable() { + return updateApiHubInstanceCallable; + } + + @Override + public OperationCallable + updateApiHubInstanceOperationCallable() { + return updateApiHubInstanceOperationCallable; + } + @Override public UnaryCallable lookupApiHubInstanceCallable() { diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/LintingServiceStubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/LintingServiceStubSettings.java index 61c6629b4f81..92b573b71570 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/LintingServiceStubSettings.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/LintingServiceStubSettings.java @@ -119,7 +119,11 @@ public class LintingServiceStubSettings extends StubSettings { /** The default scopes of the service. */ private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + ImmutableList.builder() + .add("https://www.googleapis.com/auth/apihub.readonly") + .add("https://www.googleapis.com/auth/apihub.readwrite") + .add("https://www.googleapis.com/auth/cloud-platform") + .build(); private final UnaryCallSettings getStyleGuideSettings; private final UnaryCallSettings updateStyleGuideSettings; diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ProvisioningStub.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ProvisioningStub.java index 6e8a428a70e6..a9a3f9d6b015 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ProvisioningStub.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ProvisioningStub.java @@ -29,6 +29,7 @@ import com.google.cloud.apihub.v1.LookupApiHubInstanceRequest; import com.google.cloud.apihub.v1.LookupApiHubInstanceResponse; import com.google.cloud.apihub.v1.OperationMetadata; +import com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest; import com.google.cloud.location.GetLocationRequest; import com.google.cloud.location.ListLocationsRequest; import com.google.cloud.location.ListLocationsResponse; @@ -77,6 +78,16 @@ public UnaryCallable getApiHubInstance throw new UnsupportedOperationException("Not implemented: getApiHubInstanceCallable()"); } + public OperationCallable + updateApiHubInstanceOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: updateApiHubInstanceOperationCallable()"); + } + + public UnaryCallable updateApiHubInstanceCallable() { + throw new UnsupportedOperationException("Not implemented: updateApiHubInstanceCallable()"); + } + public UnaryCallable lookupApiHubInstanceCallable() { throw new UnsupportedOperationException("Not implemented: lookupApiHubInstanceCallable()"); diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ProvisioningStubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ProvisioningStubSettings.java index 13f88fcac1ba..a7905775e634 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ProvisioningStubSettings.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/ProvisioningStubSettings.java @@ -52,6 +52,7 @@ import com.google.cloud.apihub.v1.LookupApiHubInstanceRequest; import com.google.cloud.apihub.v1.LookupApiHubInstanceResponse; import com.google.cloud.apihub.v1.OperationMetadata; +import com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest; import com.google.cloud.location.GetLocationRequest; import com.google.cloud.location.ListLocationsRequest; import com.google.cloud.location.ListLocationsResponse; @@ -151,7 +152,11 @@ public class ProvisioningStubSettings extends StubSettings { /** The default scopes of the service. */ private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + ImmutableList.builder() + .add("https://www.googleapis.com/auth/apihub.readonly") + .add("https://www.googleapis.com/auth/apihub.readwrite") + .add("https://www.googleapis.com/auth/cloud-platform") + .build(); private final UnaryCallSettings createApiHubInstanceSettings; @@ -164,6 +169,11 @@ public class ProvisioningStubSettings extends StubSettings getApiHubInstanceSettings; + private final UnaryCallSettings + updateApiHubInstanceSettings; + private final OperationCallSettings< + UpdateApiHubInstanceRequest, ApiHubInstance, OperationMetadata> + updateApiHubInstanceOperationSettings; private final UnaryCallSettings lookupApiHubInstanceSettings; private final PagedCallSettings< @@ -249,6 +259,17 @@ public UnaryCallSettings getApiHubInst return getApiHubInstanceSettings; } + /** Returns the object with the settings used for calls to updateApiHubInstance. */ + public UnaryCallSettings updateApiHubInstanceSettings() { + return updateApiHubInstanceSettings; + } + + /** Returns the object with the settings used for calls to updateApiHubInstance. */ + public OperationCallSettings + updateApiHubInstanceOperationSettings() { + return updateApiHubInstanceOperationSettings; + } + /** Returns the object with the settings used for calls to lookupApiHubInstance. */ public UnaryCallSettings lookupApiHubInstanceSettings() { @@ -355,6 +376,9 @@ protected ProvisioningStubSettings(Builder settingsBuilder) throws IOException { deleteApiHubInstanceOperationSettings = settingsBuilder.deleteApiHubInstanceOperationSettings().build(); getApiHubInstanceSettings = settingsBuilder.getApiHubInstanceSettings().build(); + updateApiHubInstanceSettings = settingsBuilder.updateApiHubInstanceSettings().build(); + updateApiHubInstanceOperationSettings = + settingsBuilder.updateApiHubInstanceOperationSettings().build(); lookupApiHubInstanceSettings = settingsBuilder.lookupApiHubInstanceSettings().build(); listLocationsSettings = settingsBuilder.listLocationsSettings().build(); getLocationSettings = settingsBuilder.getLocationSettings().build(); @@ -384,6 +408,11 @@ public static class Builder extends StubSettings.Builder getApiHubInstanceSettings; + private final UnaryCallSettings.Builder + updateApiHubInstanceSettings; + private final OperationCallSettings.Builder< + UpdateApiHubInstanceRequest, ApiHubInstance, OperationMetadata> + updateApiHubInstanceOperationSettings; private final UnaryCallSettings.Builder< LookupApiHubInstanceRequest, LookupApiHubInstanceResponse> lookupApiHubInstanceSettings; @@ -447,6 +476,8 @@ protected Builder(@Nullable ClientContext clientContext) { deleteApiHubInstanceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); deleteApiHubInstanceOperationSettings = OperationCallSettings.newBuilder(); getApiHubInstanceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateApiHubInstanceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateApiHubInstanceOperationSettings = OperationCallSettings.newBuilder(); lookupApiHubInstanceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); listLocationsSettings = PagedCallSettings.newBuilder(LIST_LOCATIONS_PAGE_STR_FACT); getLocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -456,6 +487,7 @@ protected Builder(@Nullable ClientContext clientContext) { createApiHubInstanceSettings, deleteApiHubInstanceSettings, getApiHubInstanceSettings, + updateApiHubInstanceSettings, lookupApiHubInstanceSettings, listLocationsSettings, getLocationSettings); @@ -472,6 +504,9 @@ protected Builder(ProvisioningStubSettings settings) { deleteApiHubInstanceOperationSettings = settings.deleteApiHubInstanceOperationSettings.toBuilder(); getApiHubInstanceSettings = settings.getApiHubInstanceSettings.toBuilder(); + updateApiHubInstanceSettings = settings.updateApiHubInstanceSettings.toBuilder(); + updateApiHubInstanceOperationSettings = + settings.updateApiHubInstanceOperationSettings.toBuilder(); lookupApiHubInstanceSettings = settings.lookupApiHubInstanceSettings.toBuilder(); listLocationsSettings = settings.listLocationsSettings.toBuilder(); getLocationSettings = settings.getLocationSettings.toBuilder(); @@ -481,6 +516,7 @@ protected Builder(ProvisioningStubSettings settings) { createApiHubInstanceSettings, deleteApiHubInstanceSettings, getApiHubInstanceSettings, + updateApiHubInstanceSettings, lookupApiHubInstanceSettings, listLocationsSettings, getLocationSettings); @@ -514,6 +550,11 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + builder + .updateApiHubInstanceSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + builder .lookupApiHubInstanceSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) @@ -577,6 +618,30 @@ private static Builder initDefaults(Builder builder) { .setTotalTimeoutDuration(Duration.ofMillis(300000L)) .build())); + builder + .updateApiHubInstanceOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(ApiHubInstance.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + return builder; } @@ -626,6 +691,19 @@ public Builder applyToAllUnaryMethods( return getApiHubInstanceSettings; } + /** Returns the builder for the settings used for calls to updateApiHubInstance. */ + public UnaryCallSettings.Builder + updateApiHubInstanceSettings() { + return updateApiHubInstanceSettings; + } + + /** Returns the builder for the settings used for calls to updateApiHubInstance. */ + public OperationCallSettings.Builder< + UpdateApiHubInstanceRequest, ApiHubInstance, OperationMetadata> + updateApiHubInstanceOperationSettings() { + return updateApiHubInstanceOperationSettings; + } + /** Returns the builder for the settings used for calls to lookupApiHubInstance. */ public UnaryCallSettings.Builder lookupApiHubInstanceSettings() { diff --git a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/RuntimeProjectAttachmentServiceStubSettings.java b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/RuntimeProjectAttachmentServiceStubSettings.java index 43fb84f9dde1..2ce9b0e70c1c 100644 --- a/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/RuntimeProjectAttachmentServiceStubSettings.java +++ b/java-apihub/google-cloud-apihub/src/main/java/com/google/cloud/apihub/v1/stub/RuntimeProjectAttachmentServiceStubSettings.java @@ -125,7 +125,11 @@ public class RuntimeProjectAttachmentServiceStubSettings extends StubSettings { /** The default scopes of the service. */ private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + ImmutableList.builder() + .add("https://www.googleapis.com/auth/apihub.readonly") + .add("https://www.googleapis.com/auth/apihub.readwrite") + .add("https://www.googleapis.com/auth/cloud-platform") + .build(); private final UnaryCallSettings createRuntimeProjectAttachmentSettings; diff --git a/java-apihub/google-cloud-apihub/src/main/resources/META-INF/native-image/com.google.cloud.apihub.v1/reflect-config.json b/java-apihub/google-cloud-apihub/src/main/resources/META-INF/native-image/com.google.cloud.apihub.v1/reflect-config.json index f22b4beb2c70..d8a672399ae8 100644 --- a/java-apihub/google-cloud-apihub/src/main/resources/META-INF/native-image/com.google.cloud.apihub.v1/reflect-config.json +++ b/java-apihub/google-cloud-apihub/src/main/resources/META-INF/native-image/com.google.cloud.apihub.v1/reflect-config.json @@ -521,6 +521,87 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.apihub.v1.AdditionalSpecContent", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.AdditionalSpecContent$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.Addon", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.Addon$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.AddonConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.AddonConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.AddonState", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.AllDataAddonConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.AllDataAddonConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.apihub.v1.Api", "queryAllDeclaredConstructors": true, @@ -584,6 +665,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.apihub.v1.ApiHubInstance$Config$AgentRegistrySyncConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApiHubInstance$Config$AgentRegistrySyncConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.apihub.v1.ApiHubInstance$Config$Builder", "queryAllDeclaredConstructors": true, @@ -665,6 +764,123 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.apihub.v1.ApiView", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApiView$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApiViewType", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApigeeEdgeConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApigeeEdgeConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApigeeOPDKConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApigeeOPDKConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApigeeXHybridConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApigeeXHybridConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApigeeXTargetDetails", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApigeeXTargetDetails$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApigeeXTargetDetails$MetaData", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ApigeeXTargetDetails$MetaData$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.apihub.v1.ApplicationIntegrationEndpointDetails", "queryAllDeclaredConstructors": true, @@ -1052,6 +1268,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.apihub.v1.CreateApiHubInstanceRequest", "queryAllDeclaredConstructors": true, @@ -1403,6 +1655,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.apihub.v1.DataSource", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.apihub.v1.Definition", "queryAllDeclaredConstructors": true, @@ -2006,6 +2267,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.apihub.v1.EnvironmentFilter", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.EnvironmentFilter$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.apihub.v1.ExecutePluginInstanceActionRequest", "queryAllDeclaredConstructors": true, @@ -2115,7 +2394,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.GatewayType", + "name": "com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2124,7 +2403,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.GetApiHubInstanceRequest", + "name": "com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2133,7 +2412,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.GetApiHubInstanceRequest$Builder", + "name": "com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2142,7 +2421,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.GetApiOperationRequest", + "name": "com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2151,7 +2430,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.GetApiOperationRequest$Builder", + "name": "com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2160,7 +2439,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.GetApiRequest", + "name": "com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2169,7 +2448,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.GetApiRequest$Builder", + "name": "com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2178,7 +2457,133 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.GetAttributeRequest", + "name": "com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GatewayPluginAddonConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GatewayPluginAddonConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GatewayPluginConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GatewayPluginConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GatewayType", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GetAddonRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GetAddonRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GetApiHubInstanceRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GetApiHubInstanceRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GetApiOperationRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GetApiOperationRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GetApiRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GetApiRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.GetAttributeRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2753,6 +3158,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.apihub.v1.ListAddonsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListAddonsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListAddonsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListAddonsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.apihub.v1.ListApiOperationsRequest", "queryAllDeclaredConstructors": true, @@ -2826,7 +3267,205 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListAttributesRequest", + "name": "com.google.cloud.apihub.v1.ListAttributesRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListAttributesRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListAttributesResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListAttributesResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListCurationsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListCurationsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListCurationsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListCurationsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDependenciesRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDependenciesRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDependenciesResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDependenciesResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDeploymentsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDeploymentsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDeploymentsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDeploymentsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDiscoveredApiObservationsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDiscoveredApiObservationsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDiscoveredApiObservationsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDiscoveredApiObservationsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDiscoveredApiOperationsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDiscoveredApiOperationsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ListDiscoveredApiOperationsResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2835,7 +3474,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListAttributesRequest$Builder", + "name": "com.google.cloud.apihub.v1.ListDiscoveredApiOperationsResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2844,7 +3483,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListAttributesResponse", + "name": "com.google.cloud.apihub.v1.ListExternalApisRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2853,7 +3492,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListAttributesResponse$Builder", + "name": "com.google.cloud.apihub.v1.ListExternalApisRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2862,7 +3501,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListCurationsRequest", + "name": "com.google.cloud.apihub.v1.ListExternalApisResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2871,7 +3510,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListCurationsRequest$Builder", + "name": "com.google.cloud.apihub.v1.ListExternalApisResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2880,7 +3519,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListCurationsResponse", + "name": "com.google.cloud.apihub.v1.ListHostProjectRegistrationsRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2889,7 +3528,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListCurationsResponse$Builder", + "name": "com.google.cloud.apihub.v1.ListHostProjectRegistrationsRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2898,7 +3537,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDependenciesRequest", + "name": "com.google.cloud.apihub.v1.ListHostProjectRegistrationsResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2907,7 +3546,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDependenciesRequest$Builder", + "name": "com.google.cloud.apihub.v1.ListHostProjectRegistrationsResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2916,7 +3555,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDependenciesResponse", + "name": "com.google.cloud.apihub.v1.ListPluginInstancesRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2925,7 +3564,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDependenciesResponse$Builder", + "name": "com.google.cloud.apihub.v1.ListPluginInstancesRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2934,7 +3573,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDeploymentsRequest", + "name": "com.google.cloud.apihub.v1.ListPluginInstancesResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2943,7 +3582,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDeploymentsRequest$Builder", + "name": "com.google.cloud.apihub.v1.ListPluginInstancesResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2952,7 +3591,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDeploymentsResponse", + "name": "com.google.cloud.apihub.v1.ListPluginsRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2961,7 +3600,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDeploymentsResponse$Builder", + "name": "com.google.cloud.apihub.v1.ListPluginsRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2970,7 +3609,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDiscoveredApiObservationsRequest", + "name": "com.google.cloud.apihub.v1.ListPluginsResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2979,7 +3618,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDiscoveredApiObservationsRequest$Builder", + "name": "com.google.cloud.apihub.v1.ListPluginsResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2988,7 +3627,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDiscoveredApiObservationsResponse", + "name": "com.google.cloud.apihub.v1.ListRuntimeProjectAttachmentsRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -2997,7 +3636,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDiscoveredApiObservationsResponse$Builder", + "name": "com.google.cloud.apihub.v1.ListRuntimeProjectAttachmentsRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3006,7 +3645,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDiscoveredApiOperationsRequest", + "name": "com.google.cloud.apihub.v1.ListRuntimeProjectAttachmentsResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3015,7 +3654,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDiscoveredApiOperationsRequest$Builder", + "name": "com.google.cloud.apihub.v1.ListRuntimeProjectAttachmentsResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3024,7 +3663,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDiscoveredApiOperationsResponse", + "name": "com.google.cloud.apihub.v1.ListSpecsRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3033,7 +3672,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListDiscoveredApiOperationsResponse$Builder", + "name": "com.google.cloud.apihub.v1.ListSpecsRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3042,7 +3681,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListExternalApisRequest", + "name": "com.google.cloud.apihub.v1.ListSpecsResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3051,7 +3690,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListExternalApisRequest$Builder", + "name": "com.google.cloud.apihub.v1.ListSpecsResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3060,7 +3699,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListExternalApisResponse", + "name": "com.google.cloud.apihub.v1.ListVersionsRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3069,7 +3708,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListExternalApisResponse$Builder", + "name": "com.google.cloud.apihub.v1.ListVersionsRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3078,7 +3717,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListHostProjectRegistrationsRequest", + "name": "com.google.cloud.apihub.v1.ListVersionsResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3087,7 +3726,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListHostProjectRegistrationsRequest$Builder", + "name": "com.google.cloud.apihub.v1.ListVersionsResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3096,7 +3735,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListHostProjectRegistrationsResponse", + "name": "com.google.cloud.apihub.v1.LookupApiHubInstanceRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3105,7 +3744,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListHostProjectRegistrationsResponse$Builder", + "name": "com.google.cloud.apihub.v1.LookupApiHubInstanceRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3114,7 +3753,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListPluginInstancesRequest", + "name": "com.google.cloud.apihub.v1.LookupApiHubInstanceResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3123,7 +3762,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListPluginInstancesRequest$Builder", + "name": "com.google.cloud.apihub.v1.LookupApiHubInstanceResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3132,7 +3771,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListPluginInstancesResponse", + "name": "com.google.cloud.apihub.v1.LookupRuntimeProjectAttachmentRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3141,7 +3780,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListPluginInstancesResponse$Builder", + "name": "com.google.cloud.apihub.v1.LookupRuntimeProjectAttachmentRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3150,7 +3789,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListPluginsRequest", + "name": "com.google.cloud.apihub.v1.LookupRuntimeProjectAttachmentResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3159,7 +3798,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListPluginsRequest$Builder", + "name": "com.google.cloud.apihub.v1.LookupRuntimeProjectAttachmentResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3168,7 +3807,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListPluginsResponse", + "name": "com.google.cloud.apihub.v1.ManageAddonConfigRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3177,7 +3816,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListPluginsResponse$Builder", + "name": "com.google.cloud.apihub.v1.ManageAddonConfigRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3186,7 +3825,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListRuntimeProjectAttachmentsRequest", + "name": "com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3195,7 +3834,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListRuntimeProjectAttachmentsRequest$Builder", + "name": "com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest$Action", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3204,7 +3843,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListRuntimeProjectAttachmentsResponse", + "name": "com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3213,7 +3852,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListRuntimeProjectAttachmentsResponse$Builder", + "name": "com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest$DataType", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3222,7 +3861,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListSpecsRequest", + "name": "com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3231,7 +3870,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListSpecsRequest$Builder", + "name": "com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3240,7 +3879,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListSpecsResponse", + "name": "com.google.cloud.apihub.v1.McpServerConfig", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3249,7 +3888,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListSpecsResponse$Builder", + "name": "com.google.cloud.apihub.v1.McpServerConfig$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3258,7 +3897,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListVersionsRequest", + "name": "com.google.cloud.apihub.v1.McpServerConfig$McpToolConfig", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3267,7 +3906,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListVersionsRequest$Builder", + "name": "com.google.cloud.apihub.v1.McpServerConfig$McpToolConfig$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3276,7 +3915,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListVersionsResponse", + "name": "com.google.cloud.apihub.v1.McpServerDetails", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3285,7 +3924,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.ListVersionsResponse$Builder", + "name": "com.google.cloud.apihub.v1.McpServerDetails$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3294,7 +3933,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.LookupApiHubInstanceRequest", + "name": "com.google.cloud.apihub.v1.McpTool", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3303,7 +3942,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.LookupApiHubInstanceRequest$Builder", + "name": "com.google.cloud.apihub.v1.McpTool$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3312,7 +3951,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.LookupApiHubInstanceResponse", + "name": "com.google.cloud.apihub.v1.OpenApiSpecDetails", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3321,7 +3960,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.LookupApiHubInstanceResponse$Builder", + "name": "com.google.cloud.apihub.v1.OpenApiSpecDetails$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3330,7 +3969,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.LookupRuntimeProjectAttachmentRequest", + "name": "com.google.cloud.apihub.v1.OpenApiSpecDetails$Format", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3339,7 +3978,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.LookupRuntimeProjectAttachmentRequest$Builder", + "name": "com.google.cloud.apihub.v1.OperationConfig", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3348,7 +3987,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.LookupRuntimeProjectAttachmentResponse", + "name": "com.google.cloud.apihub.v1.OperationConfig$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3357,7 +3996,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.LookupRuntimeProjectAttachmentResponse$Builder", + "name": "com.google.cloud.apihub.v1.OperationConfig$HttpOperationConfig", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3366,7 +4005,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.OpenApiSpecDetails", + "name": "com.google.cloud.apihub.v1.OperationConfig$HttpOperationConfig$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3375,7 +4014,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.OpenApiSpecDetails$Builder", + "name": "com.google.cloud.apihub.v1.OperationDetails", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3384,7 +4023,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.OpenApiSpecDetails$Format", + "name": "com.google.cloud.apihub.v1.OperationDetails$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3393,7 +4032,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.OperationDetails", + "name": "com.google.cloud.apihub.v1.OperationMetadata", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3402,7 +4041,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.OperationDetails$Builder", + "name": "com.google.cloud.apihub.v1.OperationMetadata$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3411,7 +4050,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.OperationMetadata", + "name": "com.google.cloud.apihub.v1.OperationSchema", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3420,7 +4059,7 @@ "allPublicClasses": true }, { - "name": "com.google.cloud.apihub.v1.OperationMetadata$Builder", + "name": "com.google.cloud.apihub.v1.OperationSchema$Builder", "queryAllDeclaredConstructors": true, "queryAllPublicConstructors": true, "queryAllDeclaredMethods": true, @@ -3698,6 +4337,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.apihub.v1.RetrieveApiViewsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.RetrieveApiViewsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.RetrieveApiViewsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.RetrieveApiViewsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.apihub.v1.RuntimeProjectAttachment", "queryAllDeclaredConstructors": true, @@ -3815,6 +4490,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.apihub.v1.SourceEnvironment", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.SourceEnvironment$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.apihub.v1.SourceMetadata", "queryAllDeclaredConstructors": true, @@ -3887,6 +4580,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.apihub.v1.SpecContentType", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.apihub.v1.SpecContents", "queryAllDeclaredConstructors": true, @@ -3977,6 +4679,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.apihub.v1.ToolAnnotations", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.ToolAnnotations$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.apihub.v1.UpdateApiOperationRequest", "queryAllDeclaredConstructors": true, @@ -5291,6 +6029,51 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.protobuf.ListValue", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.protobuf.ListValue$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.protobuf.NullValue", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.protobuf.Struct", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.protobuf.Struct$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.protobuf.Timestamp", "queryAllDeclaredConstructors": true, @@ -5309,6 +6092,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.protobuf.Value", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.protobuf.Value$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.rpc.Status", "queryAllDeclaredConstructors": true, diff --git a/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ApiHubAddonClientTest.java b/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ApiHubAddonClientTest.java new file mode 100644 index 000000000000..7372aaa68696 --- /dev/null +++ b/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ApiHubAddonClientTest.java @@ -0,0 +1,525 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1; + +import static com.google.cloud.apihub.v1.ApiHubAddonClient.ListAddonsPagedResponse; +import static com.google.cloud.apihub.v1.ApiHubAddonClient.ListLocationsPagedResponse; + +import com.google.api.gax.core.NoCredentialsProvider; +import com.google.api.gax.httpjson.GaxHttpJsonProperties; +import com.google.api.gax.httpjson.testing.MockHttpService; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ApiException; +import com.google.api.gax.rpc.ApiExceptionFactory; +import com.google.api.gax.rpc.InvalidArgumentException; +import com.google.api.gax.rpc.StatusCode; +import com.google.api.gax.rpc.testing.FakeStatusCode; +import com.google.cloud.apihub.v1.stub.HttpJsonApiHubAddonStub; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.collect.Lists; +import com.google.longrunning.Operation; +import com.google.protobuf.Any; +import com.google.protobuf.Timestamp; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.concurrent.ExecutionException; +import javax.annotation.Generated; +import org.junit.After; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; + +@Generated("by gapic-generator-java") +public class ApiHubAddonClientTest { + private static MockHttpService mockService; + private static ApiHubAddonClient client; + + @BeforeClass + public static void startStaticServer() throws IOException { + mockService = + new MockHttpService( + HttpJsonApiHubAddonStub.getMethodDescriptors(), + ApiHubAddonSettings.getDefaultEndpoint()); + ApiHubAddonSettings settings = + ApiHubAddonSettings.newBuilder() + .setTransportChannelProvider( + ApiHubAddonSettings.defaultHttpJsonTransportProviderBuilder() + .setHttpTransport(mockService) + .build()) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = ApiHubAddonClient.create(settings); + } + + @AfterClass + public static void stopServer() { + client.close(); + } + + @Before + public void setUp() {} + + @After + public void tearDown() throws Exception { + mockService.reset(); + } + + @Test + public void getAddonTest() throws Exception { + Addon expectedResponse = + Addon.newBuilder() + .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDataSource(DataSource.forNumber(0)) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setConfig(AddonConfig.newBuilder().build()) + .setState(AddonState.forNumber(0)) + .setBoostSpecGeminiRegionId("boostSpecGeminiRegionId-315575774") + .build(); + mockService.addResponse(expectedResponse); + + AddonName name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]"); + + Addon actualResponse = client.getAddon(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getAddonExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + AddonName name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]"); + client.getAddon(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getAddonTest2() throws Exception { + Addon expectedResponse = + Addon.newBuilder() + .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDataSource(DataSource.forNumber(0)) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setConfig(AddonConfig.newBuilder().build()) + .setState(AddonState.forNumber(0)) + .setBoostSpecGeminiRegionId("boostSpecGeminiRegionId-315575774") + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-1053/locations/location-1053/addons/addon-1053"; + + Addon actualResponse = client.getAddon(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getAddonExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-1053/locations/location-1053/addons/addon-1053"; + client.getAddon(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void manageAddonConfigTest() throws Exception { + Addon expectedResponse = + Addon.newBuilder() + .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDataSource(DataSource.forNumber(0)) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setConfig(AddonConfig.newBuilder().build()) + .setState(AddonState.forNumber(0)) + .setBoostSpecGeminiRegionId("boostSpecGeminiRegionId-315575774") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("manageAddonConfigTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + AddonName name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]"); + AddonConfig config = AddonConfig.newBuilder().build(); + + Addon actualResponse = client.manageAddonConfigAsync(name, config).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void manageAddonConfigExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + AddonName name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]"); + AddonConfig config = AddonConfig.newBuilder().build(); + client.manageAddonConfigAsync(name, config).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void manageAddonConfigTest2() throws Exception { + Addon expectedResponse = + Addon.newBuilder() + .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDataSource(DataSource.forNumber(0)) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setConfig(AddonConfig.newBuilder().build()) + .setState(AddonState.forNumber(0)) + .setBoostSpecGeminiRegionId("boostSpecGeminiRegionId-315575774") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("manageAddonConfigTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String name = "projects/project-1053/locations/location-1053/addons/addon-1053"; + AddonConfig config = AddonConfig.newBuilder().build(); + + Addon actualResponse = client.manageAddonConfigAsync(name, config).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void manageAddonConfigExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-1053/locations/location-1053/addons/addon-1053"; + AddonConfig config = AddonConfig.newBuilder().build(); + client.manageAddonConfigAsync(name, config).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void listAddonsTest() throws Exception { + Addon responsesElement = Addon.newBuilder().build(); + ListAddonsResponse expectedResponse = + ListAddonsResponse.newBuilder() + .setNextPageToken("") + .addAllAddons(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListAddonsPagedResponse pagedListResponse = client.listAddons(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAddonsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listAddonsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listAddons(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listAddonsTest2() throws Exception { + Addon responsesElement = Addon.newBuilder().build(); + ListAddonsResponse expectedResponse = + ListAddonsResponse.newBuilder() + .setNextPageToken("") + .addAllAddons(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + + ListAddonsPagedResponse pagedListResponse = client.listAddons(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getAddonsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listAddonsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + client.listAddons(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listLocationsTest() throws Exception { + Location responsesElement = Location.newBuilder().build(); + ListLocationsResponse expectedResponse = + ListLocationsResponse.newBuilder() + .setNextPageToken("") + .addAllLocations(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("projects/project-3664") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + + ListLocationsPagedResponse pagedListResponse = client.listLocations(request); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getLocationsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listLocationsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("projects/project-3664") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + client.listLocations(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getLocationTest() throws Exception { + Location expectedResponse = + Location.newBuilder() + .setName("name3373707") + .setLocationId("locationId1541836720") + .setDisplayName("displayName1714148973") + .putAllLabels(new HashMap()) + .setMetadata(Any.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + GetLocationRequest request = + GetLocationRequest.newBuilder() + .setName("projects/project-9062/locations/location-9062") + .build(); + + Location actualResponse = client.getLocation(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getLocationExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GetLocationRequest request = + GetLocationRequest.newBuilder() + .setName("projects/project-9062/locations/location-9062") + .build(); + client.getLocation(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } +} diff --git a/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ApiHubClientTest.java b/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ApiHubClientTest.java index 900446348e0e..3ea99b90bdad 100644 --- a/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ApiHubClientTest.java +++ b/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ApiHubClientTest.java @@ -24,6 +24,7 @@ import static com.google.cloud.apihub.v1.ApiHubClient.ListLocationsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.ListSpecsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.ListVersionsPagedResponse; +import static com.google.cloud.apihub.v1.ApiHubClient.RetrieveApiViewsPagedResponse; import static com.google.cloud.apihub.v1.ApiHubClient.SearchResourcesPagedResponse; import com.google.api.gax.core.NoCredentialsProvider; @@ -41,6 +42,7 @@ import com.google.cloud.location.ListLocationsResponse; import com.google.cloud.location.Location; import com.google.common.collect.Lists; +import com.google.longrunning.Operation; import com.google.protobuf.Any; import com.google.protobuf.ByteString; import com.google.protobuf.Empty; @@ -51,6 +53,7 @@ import java.util.Arrays; import java.util.HashMap; import java.util.List; +import java.util.concurrent.ExecutionException; import javax.annotation.Generated; import org.junit.After; import org.junit.AfterClass; @@ -118,6 +121,7 @@ public void createApiTest() throws Exception { .addAllSourceMetadata(new ArrayList()) .setApiFunctionalRequirements(AttributeValues.newBuilder().build()) .setApiTechnicalRequirements(AttributeValues.newBuilder().build()) + .setServiceType(AttributeValues.newBuilder().build()) .build(); mockService.addResponse(expectedResponse); @@ -186,6 +190,7 @@ public void createApiTest2() throws Exception { .addAllSourceMetadata(new ArrayList()) .setApiFunctionalRequirements(AttributeValues.newBuilder().build()) .setApiTechnicalRequirements(AttributeValues.newBuilder().build()) + .setServiceType(AttributeValues.newBuilder().build()) .build(); mockService.addResponse(expectedResponse); @@ -254,6 +259,7 @@ public void getApiTest() throws Exception { .addAllSourceMetadata(new ArrayList()) .setApiFunctionalRequirements(AttributeValues.newBuilder().build()) .setApiTechnicalRequirements(AttributeValues.newBuilder().build()) + .setServiceType(AttributeValues.newBuilder().build()) .build(); mockService.addResponse(expectedResponse); @@ -318,6 +324,7 @@ public void getApiTest2() throws Exception { .addAllSourceMetadata(new ArrayList()) .setApiFunctionalRequirements(AttributeValues.newBuilder().build()) .setApiTechnicalRequirements(AttributeValues.newBuilder().build()) + .setServiceType(AttributeValues.newBuilder().build()) .build(); mockService.addResponse(expectedResponse); @@ -482,6 +489,7 @@ public void updateApiTest() throws Exception { .addAllSourceMetadata(new ArrayList()) .setApiFunctionalRequirements(AttributeValues.newBuilder().build()) .setApiTechnicalRequirements(AttributeValues.newBuilder().build()) + .setServiceType(AttributeValues.newBuilder().build()) .build(); mockService.addResponse(expectedResponse); @@ -508,6 +516,7 @@ public void updateApiTest() throws Exception { .addAllSourceMetadata(new ArrayList()) .setApiFunctionalRequirements(AttributeValues.newBuilder().build()) .setApiTechnicalRequirements(AttributeValues.newBuilder().build()) + .setServiceType(AttributeValues.newBuilder().build()) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); @@ -560,6 +569,7 @@ public void updateApiExceptionTest() throws Exception { .addAllSourceMetadata(new ArrayList()) .setApiFunctionalRequirements(AttributeValues.newBuilder().build()) .setApiTechnicalRequirements(AttributeValues.newBuilder().build()) + .setServiceType(AttributeValues.newBuilder().build()) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); client.updateApi(api, updateMask); @@ -1198,6 +1208,8 @@ public void createSpecTest() throws Exception { .putAllAttributes(new HashMap()) .setDocumentation(Documentation.newBuilder().build()) .addAllSourceMetadata(new ArrayList()) + .addAllAdditionalSpecContents(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -1258,6 +1270,8 @@ public void createSpecTest2() throws Exception { .putAllAttributes(new HashMap()) .setDocumentation(Documentation.newBuilder().build()) .addAllSourceMetadata(new ArrayList()) + .addAllAdditionalSpecContents(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -1320,6 +1334,8 @@ public void getSpecTest() throws Exception { .putAllAttributes(new HashMap()) .setDocumentation(Documentation.newBuilder().build()) .addAllSourceMetadata(new ArrayList()) + .addAllAdditionalSpecContents(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -1376,6 +1392,8 @@ public void getSpecTest2() throws Exception { .putAllAttributes(new HashMap()) .setDocumentation(Documentation.newBuilder().build()) .addAllSourceMetadata(new ArrayList()) + .addAllAdditionalSpecContents(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -1509,6 +1527,102 @@ public void getSpecContentsExceptionTest2() throws Exception { } } + @Test + public void fetchAdditionalSpecContentTest() throws Exception { + FetchAdditionalSpecContentResponse expectedResponse = + FetchAdditionalSpecContentResponse.newBuilder() + .setAdditionalSpecContent(AdditionalSpecContent.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + SpecName name = SpecName.of("[PROJECT]", "[LOCATION]", "[API]", "[VERSION]", "[SPEC]"); + SpecContentType specContentType = SpecContentType.forNumber(0); + + FetchAdditionalSpecContentResponse actualResponse = + client.fetchAdditionalSpecContent(name, specContentType); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void fetchAdditionalSpecContentExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + SpecName name = SpecName.of("[PROJECT]", "[LOCATION]", "[API]", "[VERSION]", "[SPEC]"); + SpecContentType specContentType = SpecContentType.forNumber(0); + client.fetchAdditionalSpecContent(name, specContentType); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void fetchAdditionalSpecContentTest2() throws Exception { + FetchAdditionalSpecContentResponse expectedResponse = + FetchAdditionalSpecContentResponse.newBuilder() + .setAdditionalSpecContent(AdditionalSpecContent.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-1520/locations/location-1520/apis/api-1520/versions/version-1520/specs/spec-1520"; + SpecContentType specContentType = SpecContentType.forNumber(0); + + FetchAdditionalSpecContentResponse actualResponse = + client.fetchAdditionalSpecContent(name, specContentType); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void fetchAdditionalSpecContentExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-1520/locations/location-1520/apis/api-1520/versions/version-1520/specs/spec-1520"; + SpecContentType specContentType = SpecContentType.forNumber(0); + client.fetchAdditionalSpecContent(name, specContentType); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + @Test public void listSpecsTest() throws Exception { Spec responsesElement = Spec.newBuilder().build(); @@ -1628,6 +1742,8 @@ public void updateSpecTest() throws Exception { .putAllAttributes(new HashMap()) .setDocumentation(Documentation.newBuilder().build()) .addAllSourceMetadata(new ArrayList()) + .addAllAdditionalSpecContents(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -1646,6 +1762,8 @@ public void updateSpecTest() throws Exception { .putAllAttributes(new HashMap()) .setDocumentation(Documentation.newBuilder().build()) .addAllSourceMetadata(new ArrayList()) + .addAllAdditionalSpecContents(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); @@ -1690,6 +1808,8 @@ public void updateSpecExceptionTest() throws Exception { .putAllAttributes(new HashMap()) .setDocumentation(Documentation.newBuilder().build()) .addAllSourceMetadata(new ArrayList()) + .addAllAdditionalSpecContents(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); client.updateSpec(spec, updateMask); @@ -1795,6 +1915,7 @@ public void createApiOperationTest() throws Exception { .setUpdateTime(Timestamp.newBuilder().build()) .putAllAttributes(new HashMap()) .addAllSourceMetadata(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -1852,6 +1973,7 @@ public void createApiOperationTest2() throws Exception { .setUpdateTime(Timestamp.newBuilder().build()) .putAllAttributes(new HashMap()) .addAllSourceMetadata(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -1911,6 +2033,7 @@ public void getApiOperationTest() throws Exception { .setUpdateTime(Timestamp.newBuilder().build()) .putAllAttributes(new HashMap()) .addAllSourceMetadata(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -1966,6 +2089,7 @@ public void getApiOperationTest2() throws Exception { .setUpdateTime(Timestamp.newBuilder().build()) .putAllAttributes(new HashMap()) .addAllSourceMetadata(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -2123,6 +2247,7 @@ public void updateApiOperationTest() throws Exception { .setUpdateTime(Timestamp.newBuilder().build()) .putAllAttributes(new HashMap()) .addAllSourceMetadata(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -2138,6 +2263,7 @@ public void updateApiOperationTest() throws Exception { .setUpdateTime(Timestamp.newBuilder().build()) .putAllAttributes(new HashMap()) .addAllSourceMetadata(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); @@ -2180,6 +2306,7 @@ public void updateApiOperationExceptionTest() throws Exception { .setUpdateTime(Timestamp.newBuilder().build()) .putAllAttributes(new HashMap()) .addAllSourceMetadata(new ArrayList()) + .addAllDeployments(new ArrayList()) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); client.updateApiOperation(apiOperation, updateMask); @@ -2401,6 +2528,9 @@ public void createDeploymentTest() throws Exception { .setSourceUri(AttributeValues.newBuilder().build()) .setSourceProject("sourceProject-214747522") .setSourceEnvironment("sourceEnvironment1420157688") + .addAllSpecs(new ArrayList()) + .addAllApiOperations(new ArrayList()) + .setSourceRevision("sourceRevision-1624295146") .build(); mockService.addResponse(expectedResponse); @@ -2466,6 +2596,9 @@ public void createDeploymentTest2() throws Exception { .setSourceUri(AttributeValues.newBuilder().build()) .setSourceProject("sourceProject-214747522") .setSourceEnvironment("sourceEnvironment1420157688") + .addAllSpecs(new ArrayList()) + .addAllApiOperations(new ArrayList()) + .setSourceRevision("sourceRevision-1624295146") .build(); mockService.addResponse(expectedResponse); @@ -2531,6 +2664,9 @@ public void getDeploymentTest() throws Exception { .setSourceUri(AttributeValues.newBuilder().build()) .setSourceProject("sourceProject-214747522") .setSourceEnvironment("sourceEnvironment1420157688") + .addAllSpecs(new ArrayList()) + .addAllApiOperations(new ArrayList()) + .setSourceRevision("sourceRevision-1624295146") .build(); mockService.addResponse(expectedResponse); @@ -2592,6 +2728,9 @@ public void getDeploymentTest2() throws Exception { .setSourceUri(AttributeValues.newBuilder().build()) .setSourceProject("sourceProject-214747522") .setSourceEnvironment("sourceEnvironment1420157688") + .addAllSpecs(new ArrayList()) + .addAllApiOperations(new ArrayList()) + .setSourceRevision("sourceRevision-1624295146") .build(); mockService.addResponse(expectedResponse); @@ -2753,6 +2892,9 @@ public void updateDeploymentTest() throws Exception { .setSourceUri(AttributeValues.newBuilder().build()) .setSourceProject("sourceProject-214747522") .setSourceEnvironment("sourceEnvironment1420157688") + .addAllSpecs(new ArrayList()) + .addAllApiOperations(new ArrayList()) + .setSourceRevision("sourceRevision-1624295146") .build(); mockService.addResponse(expectedResponse); @@ -2776,6 +2918,9 @@ public void updateDeploymentTest() throws Exception { .setSourceUri(AttributeValues.newBuilder().build()) .setSourceProject("sourceProject-214747522") .setSourceEnvironment("sourceEnvironment1420157688") + .addAllSpecs(new ArrayList()) + .addAllApiOperations(new ArrayList()) + .setSourceRevision("sourceRevision-1624295146") .build(); FieldMask updateMask = FieldMask.newBuilder().build(); @@ -2825,6 +2970,9 @@ public void updateDeploymentExceptionTest() throws Exception { .setSourceUri(AttributeValues.newBuilder().build()) .setSourceProject("sourceProject-214747522") .setSourceEnvironment("sourceEnvironment1420157688") + .addAllSpecs(new ArrayList()) + .addAllApiOperations(new ArrayList()) + .setSourceRevision("sourceRevision-1624295146") .build(); FieldMask updateMask = FieldMask.newBuilder().build(); client.updateDeployment(deployment, updateMask); @@ -3955,6 +4103,210 @@ public void listExternalApisExceptionTest2() throws Exception { } } + @Test + public void retrieveApiViewsTest() throws Exception { + ApiView responsesElement = ApiView.newBuilder().build(); + RetrieveApiViewsResponse expectedResponse = + RetrieveApiViewsResponse.newBuilder() + .setNextPageToken("") + .addAllApiViews(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + ApiViewType view = ApiViewType.forNumber(0); + + RetrieveApiViewsPagedResponse pagedListResponse = client.retrieveApiViews(parent, view); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getApiViewsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void retrieveApiViewsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + ApiViewType view = ApiViewType.forNumber(0); + client.retrieveApiViews(parent, view); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void retrieveApiViewsTest2() throws Exception { + ApiView responsesElement = ApiView.newBuilder().build(); + RetrieveApiViewsResponse expectedResponse = + RetrieveApiViewsResponse.newBuilder() + .setNextPageToken("") + .addAllApiViews(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + ApiViewType view = ApiViewType.forNumber(0); + + RetrieveApiViewsPagedResponse pagedListResponse = client.retrieveApiViews(parent, view); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getApiViewsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void retrieveApiViewsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + ApiViewType view = ApiViewType.forNumber(0); + client.retrieveApiViews(parent, view); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void configureAndDeployServerTest() throws Exception { + ConfigureAndDeployServerResponse expectedResponse = + ConfigureAndDeployServerResponse.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("configureAndDeployServerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + McpServerConfig mcpServerConfig = McpServerConfig.newBuilder().build(); + + ConfigureAndDeployServerResponse actualResponse = + client.configureAndDeployServerAsync(parent, mcpServerConfig).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void configureAndDeployServerExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + McpServerConfig mcpServerConfig = McpServerConfig.newBuilder().build(); + client.configureAndDeployServerAsync(parent, mcpServerConfig).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void configureAndDeployServerTest2() throws Exception { + ConfigureAndDeployServerResponse expectedResponse = + ConfigureAndDeployServerResponse.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("configureAndDeployServerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String parent = "projects/project-5833/locations/location-5833"; + McpServerConfig mcpServerConfig = McpServerConfig.newBuilder().build(); + + ConfigureAndDeployServerResponse actualResponse = + client.configureAndDeployServerAsync(parent, mcpServerConfig).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void configureAndDeployServerExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + McpServerConfig mcpServerConfig = McpServerConfig.newBuilder().build(); + client.configureAndDeployServerAsync(parent, mcpServerConfig).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + @Test public void listLocationsTest() throws Exception { Location responsesElement = Location.newBuilder().build(); diff --git a/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ApiHubPluginClientTest.java b/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ApiHubPluginClientTest.java index fdd1c5907854..ea5d2db3bef0 100644 --- a/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ApiHubPluginClientTest.java +++ b/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ApiHubPluginClientTest.java @@ -37,6 +37,7 @@ import com.google.common.collect.Lists; import com.google.longrunning.Operation; import com.google.protobuf.Any; +import com.google.protobuf.ByteString; import com.google.protobuf.Empty; import com.google.protobuf.FieldMask; import com.google.protobuf.Timestamp; @@ -742,6 +743,7 @@ public void createPluginInstanceTest() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setUpdateTime(Timestamp.newBuilder().build()) .setSourceProjectId("sourceProjectId-213936071") + .putAllSourceEnvironmentsConfig(new HashMap()) .build(); Operation resultOperation = Operation.newBuilder() @@ -806,6 +808,7 @@ public void createPluginInstanceTest2() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setUpdateTime(Timestamp.newBuilder().build()) .setSourceProjectId("sourceProjectId-213936071") + .putAllSourceEnvironmentsConfig(new HashMap()) .build(); Operation resultOperation = Operation.newBuilder() @@ -974,6 +977,7 @@ public void getPluginInstanceTest() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setUpdateTime(Timestamp.newBuilder().build()) .setSourceProjectId("sourceProjectId-213936071") + .putAllSourceEnvironmentsConfig(new HashMap()) .build(); mockService.addResponse(expectedResponse); @@ -1030,6 +1034,7 @@ public void getPluginInstanceTest2() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setUpdateTime(Timestamp.newBuilder().build()) .setSourceProjectId("sourceProjectId-213936071") + .putAllSourceEnvironmentsConfig(new HashMap()) .build(); mockService.addResponse(expectedResponse); @@ -1394,6 +1399,7 @@ public void updatePluginInstanceTest() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setUpdateTime(Timestamp.newBuilder().build()) .setSourceProjectId("sourceProjectId-213936071") + .putAllSourceEnvironmentsConfig(new HashMap()) .build(); mockService.addResponse(expectedResponse); @@ -1410,6 +1416,7 @@ public void updatePluginInstanceTest() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setUpdateTime(Timestamp.newBuilder().build()) .setSourceProjectId("sourceProjectId-213936071") + .putAllSourceEnvironmentsConfig(new HashMap()) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); @@ -1452,6 +1459,7 @@ public void updatePluginInstanceExceptionTest() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setUpdateTime(Timestamp.newBuilder().build()) .setSourceProjectId("sourceProjectId-213936071") + .putAllSourceEnvironmentsConfig(new HashMap()) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); client.updatePluginInstance(pluginInstance, updateMask); @@ -1555,6 +1563,120 @@ public void deletePluginInstanceExceptionTest2() throws Exception { } } + @Test + public void managePluginInstanceSourceDataTest() throws Exception { + ManagePluginInstanceSourceDataResponse expectedResponse = + ManagePluginInstanceSourceDataResponse.newBuilder().build(); + mockService.addResponse(expectedResponse); + + PluginInstanceName name = + PluginInstanceName.of("[PROJECT]", "[LOCATION]", "[PLUGIN]", "[INSTANCE]"); + ManagePluginInstanceSourceDataRequest.DataType dataType = + ManagePluginInstanceSourceDataRequest.DataType.forNumber(0); + ManagePluginInstanceSourceDataRequest.Action action = + ManagePluginInstanceSourceDataRequest.Action.forNumber(0); + String relativePath = "relativePath-70808303"; + ByteString data = ByteString.EMPTY; + + ManagePluginInstanceSourceDataResponse actualResponse = + client.managePluginInstanceSourceData(name, dataType, action, relativePath, data); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void managePluginInstanceSourceDataExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + PluginInstanceName name = + PluginInstanceName.of("[PROJECT]", "[LOCATION]", "[PLUGIN]", "[INSTANCE]"); + ManagePluginInstanceSourceDataRequest.DataType dataType = + ManagePluginInstanceSourceDataRequest.DataType.forNumber(0); + ManagePluginInstanceSourceDataRequest.Action action = + ManagePluginInstanceSourceDataRequest.Action.forNumber(0); + String relativePath = "relativePath-70808303"; + ByteString data = ByteString.EMPTY; + client.managePluginInstanceSourceData(name, dataType, action, relativePath, data); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void managePluginInstanceSourceDataTest2() throws Exception { + ManagePluginInstanceSourceDataResponse expectedResponse = + ManagePluginInstanceSourceDataResponse.newBuilder().build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-528/locations/location-528/plugins/plugin-528/instances/instance-528"; + ManagePluginInstanceSourceDataRequest.DataType dataType = + ManagePluginInstanceSourceDataRequest.DataType.forNumber(0); + ManagePluginInstanceSourceDataRequest.Action action = + ManagePluginInstanceSourceDataRequest.Action.forNumber(0); + String relativePath = "relativePath-70808303"; + ByteString data = ByteString.EMPTY; + + ManagePluginInstanceSourceDataResponse actualResponse = + client.managePluginInstanceSourceData(name, dataType, action, relativePath, data); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void managePluginInstanceSourceDataExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-528/locations/location-528/plugins/plugin-528/instances/instance-528"; + ManagePluginInstanceSourceDataRequest.DataType dataType = + ManagePluginInstanceSourceDataRequest.DataType.forNumber(0); + ManagePluginInstanceSourceDataRequest.Action action = + ManagePluginInstanceSourceDataRequest.Action.forNumber(0); + String relativePath = "relativePath-70808303"; + ByteString data = ByteString.EMPTY; + client.managePluginInstanceSourceData(name, dataType, action, relativePath, data); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + @Test public void listLocationsTest() throws Exception { Location responsesElement = Location.newBuilder().build(); diff --git a/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ProvisioningClientTest.java b/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ProvisioningClientTest.java index 53a9ab533f5b..05669c5d4c3f 100644 --- a/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ProvisioningClientTest.java +++ b/java-apihub/google-cloud-apihub/src/test/java/com/google/cloud/apihub/v1/ProvisioningClientTest.java @@ -36,6 +36,7 @@ import com.google.longrunning.Operation; import com.google.protobuf.Any; import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; import com.google.protobuf.Timestamp; import java.io.IOException; import java.util.Arrays; @@ -407,6 +408,85 @@ public void getApiHubInstanceExceptionTest2() throws Exception { } } + @Test + public void updateApiHubInstanceTest() throws Exception { + ApiHubInstance expectedResponse = + ApiHubInstance.newBuilder() + .setName( + ApiHubInstanceName.of("[PROJECT]", "[LOCATION]", "[API_HUB_INSTANCE]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setStateMessage("stateMessage1128185398") + .setConfig(ApiHubInstance.Config.newBuilder().build()) + .putAllLabels(new HashMap()) + .setDescription("description-1724546052") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateApiHubInstanceTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + ApiHubInstance apiHubInstance = + ApiHubInstance.newBuilder() + .setName( + ApiHubInstanceName.of("[PROJECT]", "[LOCATION]", "[API_HUB_INSTANCE]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setStateMessage("stateMessage1128185398") + .setConfig(ApiHubInstance.Config.newBuilder().build()) + .putAllLabels(new HashMap()) + .setDescription("description-1724546052") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + ApiHubInstance actualResponse = + client.updateApiHubInstanceAsync(apiHubInstance, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void updateApiHubInstanceExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + ApiHubInstance apiHubInstance = + ApiHubInstance.newBuilder() + .setName( + ApiHubInstanceName.of("[PROJECT]", "[LOCATION]", "[API_HUB_INSTANCE]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setStateMessage("stateMessage1128185398") + .setConfig(ApiHubInstance.Config.newBuilder().build()) + .putAllLabels(new HashMap()) + .setDescription("description-1724546052") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateApiHubInstanceAsync(apiHubInstance, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + @Test public void lookupApiHubInstanceTest() throws Exception { LookupApiHubInstanceResponse expectedResponse = diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AdditionalSpecContent.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AdditionalSpecContent.java new file mode 100644 index 000000000000..da6de637dfac --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AdditionalSpecContent.java @@ -0,0 +1,1845 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/common_fields.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *

                      + * The additional spec content for the spec.
                      + * This contains the metadata and the last update time for the additional spec
                      + * content.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.AdditionalSpecContent} + */ +@com.google.protobuf.Generated +public final class AdditionalSpecContent extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.AdditionalSpecContent) + AdditionalSpecContentOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AdditionalSpecContent"); + } + + // Use AdditionalSpecContent.newBuilder() to construct. + private AdditionalSpecContent(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AdditionalSpecContent() { + specContentType_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_AdditionalSpecContent_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 5: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_AdditionalSpecContent_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.AdditionalSpecContent.class, + com.google.cloud.apihub.v1.AdditionalSpecContent.Builder.class); + } + + private int bitField0_; + public static final int SPEC_CONTENT_TYPE_FIELD_NUMBER = 1; + private int specContentType_ = 0; + + /** + * + * + *
                      +   * Required. The type of the spec content.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for specContentType. + */ + @java.lang.Override + public int getSpecContentTypeValue() { + return specContentType_; + } + + /** + * + * + *
                      +   * Required. The type of the spec content.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The specContentType. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.SpecContentType getSpecContentType() { + com.google.cloud.apihub.v1.SpecContentType result = + com.google.cloud.apihub.v1.SpecContentType.forNumber(specContentType_); + return result == null ? com.google.cloud.apihub.v1.SpecContentType.UNRECOGNIZED : result; + } + + public static final int SPEC_CONTENTS_FIELD_NUMBER = 2; + private com.google.cloud.apihub.v1.SpecContents specContents_; + + /** + * + * + *
                      +   * Optional. The additional spec contents.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the specContents field is set. + */ + @java.lang.Override + public boolean hasSpecContents() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Optional. The additional spec contents.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The specContents. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.SpecContents getSpecContents() { + return specContents_ == null + ? com.google.cloud.apihub.v1.SpecContents.getDefaultInstance() + : specContents_; + } + + /** + * + * + *
                      +   * Optional. The additional spec contents.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.SpecContentsOrBuilder getSpecContentsOrBuilder() { + return specContents_ == null + ? com.google.cloud.apihub.v1.SpecContents.getDefaultInstance() + : specContents_; + } + + public static final int CREATE_TIME_FIELD_NUMBER = 3; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
                      +   * Output only. The time at which the spec content was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Output only. The time at which the spec content was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
                      +   * Output only. The time at which the spec content was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 4; + private com.google.protobuf.Timestamp updateTime_; + + /** + * + * + *
                      +   * Output only. The time at which the spec content was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +   * Output only. The time at which the spec content was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + /** + * + * + *
                      +   * Output only. The time at which the spec content was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + public static final int LABELS_FIELD_NUMBER = 5; + + private static final class LabelsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_AdditionalSpecContent_LabelsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + + @SuppressWarnings("serial") + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + + /** + * + * + *
                      +   * Optional. The labels of the spec content e.g. specboost addon version.
                      +   * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetLabels().getMap().containsKey(key); + } + + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + + /** + * + * + *
                      +   * Optional. The labels of the spec content e.g. specboost addon version.
                      +   * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
                      +   * Optional. The labels of the spec content e.g. specboost addon version.
                      +   * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public /* nullable */ java.lang.String getLabelsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
                      +   * Optional. The labels of the spec content e.g. specboost addon version.
                      +   * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (specContentType_ + != com.google.cloud.apihub.v1.SpecContentType.SPEC_CONTENT_TYPE_UNSPECIFIED.getNumber()) { + output.writeEnum(1, specContentType_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getSpecContents()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(3, getCreateTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(4, getUpdateTime()); + } + com.google.protobuf.GeneratedMessage.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 5); + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (specContentType_ + != com.google.cloud.apihub.v1.SpecContentType.SPEC_CONTENT_TYPE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, specContentType_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getSpecContents()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCreateTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getUpdateTime()); + } + for (java.util.Map.Entry entry : + internalGetLabels().getMap().entrySet()) { + com.google.protobuf.MapEntry labels__ = + LabelsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, labels__); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.AdditionalSpecContent)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.AdditionalSpecContent other = + (com.google.cloud.apihub.v1.AdditionalSpecContent) obj; + + if (specContentType_ != other.specContentType_) return false; + if (hasSpecContents() != other.hasSpecContents()) return false; + if (hasSpecContents()) { + if (!getSpecContents().equals(other.getSpecContents())) return false; + } + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!internalGetLabels().equals(other.internalGetLabels())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + SPEC_CONTENT_TYPE_FIELD_NUMBER; + hash = (53 * hash) + specContentType_; + if (hasSpecContents()) { + hash = (37 * hash) + SPEC_CONTENTS_FIELD_NUMBER; + hash = (53 * hash) + getSpecContents().hashCode(); + } + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + if (!internalGetLabels().getMap().isEmpty()) { + hash = (37 * hash) + LABELS_FIELD_NUMBER; + hash = (53 * hash) + internalGetLabels().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.AdditionalSpecContent prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The additional spec content for the spec.
                      +   * This contains the metadata and the last update time for the additional spec
                      +   * content.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.AdditionalSpecContent} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.AdditionalSpecContent) + com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_AdditionalSpecContent_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 5: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( + int number) { + switch (number) { + case 5: + return internalGetMutableLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_AdditionalSpecContent_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.AdditionalSpecContent.class, + com.google.cloud.apihub.v1.AdditionalSpecContent.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.AdditionalSpecContent.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetSpecContentsFieldBuilder(); + internalGetCreateTimeFieldBuilder(); + internalGetUpdateTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + specContentType_ = 0; + specContents_ = null; + if (specContentsBuilder_ != null) { + specContentsBuilder_.dispose(); + specContentsBuilder_ = null; + } + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + internalGetMutableLabels().clear(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_AdditionalSpecContent_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AdditionalSpecContent getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.AdditionalSpecContent.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AdditionalSpecContent build() { + com.google.cloud.apihub.v1.AdditionalSpecContent result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AdditionalSpecContent buildPartial() { + com.google.cloud.apihub.v1.AdditionalSpecContent result = + new com.google.cloud.apihub.v1.AdditionalSpecContent(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.AdditionalSpecContent result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.specContentType_ = specContentType_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.specContents_ = + specContentsBuilder_ == null ? specContents_ : specContentsBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.labels_ = internalGetLabels(); + result.labels_.makeImmutable(); + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.AdditionalSpecContent) { + return mergeFrom((com.google.cloud.apihub.v1.AdditionalSpecContent) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.AdditionalSpecContent other) { + if (other == com.google.cloud.apihub.v1.AdditionalSpecContent.getDefaultInstance()) + return this; + if (other.specContentType_ != 0) { + setSpecContentTypeValue(other.getSpecContentTypeValue()); + } + if (other.hasSpecContents()) { + mergeSpecContents(other.getSpecContents()); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); + bitField0_ |= 0x00000010; + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + specContentType_ = input.readEnum(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 18: + { + input.readMessage( + internalGetSpecContentsFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + com.google.protobuf.MapEntry labels__ = + input.readMessage( + LabelsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableLabels() + .getMutableMap() + .put(labels__.getKey(), labels__.getValue()); + bitField0_ |= 0x00000010; + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int specContentType_ = 0; + + /** + * + * + *
                      +     * Required. The type of the spec content.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for specContentType. + */ + @java.lang.Override + public int getSpecContentTypeValue() { + return specContentType_; + } + + /** + * + * + *
                      +     * Required. The type of the spec content.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The enum numeric value on the wire for specContentType to set. + * @return This builder for chaining. + */ + public Builder setSpecContentTypeValue(int value) { + specContentType_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The type of the spec content.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The specContentType. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.SpecContentType getSpecContentType() { + com.google.cloud.apihub.v1.SpecContentType result = + com.google.cloud.apihub.v1.SpecContentType.forNumber(specContentType_); + return result == null ? com.google.cloud.apihub.v1.SpecContentType.UNRECOGNIZED : result; + } + + /** + * + * + *
                      +     * Required. The type of the spec content.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The specContentType to set. + * @return This builder for chaining. + */ + public Builder setSpecContentType(com.google.cloud.apihub.v1.SpecContentType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + specContentType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The type of the spec content.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearSpecContentType() { + bitField0_ = (bitField0_ & ~0x00000001); + specContentType_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.apihub.v1.SpecContents specContents_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.SpecContents, + com.google.cloud.apihub.v1.SpecContents.Builder, + com.google.cloud.apihub.v1.SpecContentsOrBuilder> + specContentsBuilder_; + + /** + * + * + *
                      +     * Optional. The additional spec contents.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the specContents field is set. + */ + public boolean hasSpecContents() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +     * Optional. The additional spec contents.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The specContents. + */ + public com.google.cloud.apihub.v1.SpecContents getSpecContents() { + if (specContentsBuilder_ == null) { + return specContents_ == null + ? com.google.cloud.apihub.v1.SpecContents.getDefaultInstance() + : specContents_; + } else { + return specContentsBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The additional spec contents.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setSpecContents(com.google.cloud.apihub.v1.SpecContents value) { + if (specContentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + specContents_ = value; + } else { + specContentsBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The additional spec contents.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setSpecContents( + com.google.cloud.apihub.v1.SpecContents.Builder builderForValue) { + if (specContentsBuilder_ == null) { + specContents_ = builderForValue.build(); + } else { + specContentsBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The additional spec contents.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeSpecContents(com.google.cloud.apihub.v1.SpecContents value) { + if (specContentsBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && specContents_ != null + && specContents_ != com.google.cloud.apihub.v1.SpecContents.getDefaultInstance()) { + getSpecContentsBuilder().mergeFrom(value); + } else { + specContents_ = value; + } + } else { + specContentsBuilder_.mergeFrom(value); + } + if (specContents_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The additional spec contents.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearSpecContents() { + bitField0_ = (bitField0_ & ~0x00000002); + specContents_ = null; + if (specContentsBuilder_ != null) { + specContentsBuilder_.dispose(); + specContentsBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The additional spec contents.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.SpecContents.Builder getSpecContentsBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetSpecContentsFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The additional spec contents.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.SpecContentsOrBuilder getSpecContentsOrBuilder() { + if (specContentsBuilder_ != null) { + return specContentsBuilder_.getMessageOrBuilder(); + } else { + return specContents_ == null + ? com.google.cloud.apihub.v1.SpecContents.getDefaultInstance() + : specContents_; + } + } + + /** + * + * + *
                      +     * Optional. The additional spec contents.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.SpecContents, + com.google.cloud.apihub.v1.SpecContents.Builder, + com.google.cloud.apihub.v1.SpecContentsOrBuilder> + internalGetSpecContentsFieldBuilder() { + if (specContentsBuilder_ == null) { + specContentsBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.SpecContents, + com.google.cloud.apihub.v1.SpecContents.Builder, + com.google.cloud.apihub.v1.SpecContentsOrBuilder>( + getSpecContents(), getParentForChildren(), isClean()); + specContents_ = null; + } + return specContentsBuilder_; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
                      +     * Output only. The time at which the spec content was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000004); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
                      +     * Output only. The time at which the spec content was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + } else { + updateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && updateTime_ != null + && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getUpdateTimeBuilder().mergeFrom(value); + } else { + updateTime_ = value; + } + } else { + updateTimeBuilder_.mergeFrom(value); + } + if (updateTime_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000008); + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + + /** + * + * + *
                      +     * Output only. The time at which the spec content was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + private com.google.protobuf.MapField + internalGetMutableLabels() { + if (labels_ == null) { + labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); + } + if (!labels_.isMutable()) { + labels_ = labels_.copy(); + } + bitField0_ |= 0x00000010; + onChanged(); + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + + /** + * + * + *
                      +     * Optional. The labels of the spec content e.g. specboost addon version.
                      +     * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetLabels().getMap().containsKey(key); + } + + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + + /** + * + * + *
                      +     * Optional. The labels of the spec content e.g. specboost addon version.
                      +     * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
                      +     * Optional. The labels of the spec content e.g. specboost addon version.
                      +     * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public /* nullable */ java.lang.String getLabelsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
                      +     * Optional. The labels of the spec content e.g. specboost addon version.
                      +     * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearLabels() { + bitField0_ = (bitField0_ & ~0x00000010); + internalGetMutableLabels().getMutableMap().clear(); + return this; + } + + /** + * + * + *
                      +     * Optional. The labels of the spec content e.g. specboost addon version.
                      +     * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder removeLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableLabels().getMutableMap().remove(key); + return this; + } + + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableLabels() { + bitField0_ |= 0x00000010; + return internalGetMutableLabels().getMutableMap(); + } + + /** + * + * + *
                      +     * Optional. The labels of the spec content e.g. specboost addon version.
                      +     * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder putLabels(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + internalGetMutableLabels().getMutableMap().put(key, value); + bitField0_ |= 0x00000010; + return this; + } + + /** + * + * + *
                      +     * Optional. The labels of the spec content e.g. specboost addon version.
                      +     * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder putAllLabels(java.util.Map values) { + internalGetMutableLabels().getMutableMap().putAll(values); + bitField0_ |= 0x00000010; + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.AdditionalSpecContent) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.AdditionalSpecContent) + private static final com.google.cloud.apihub.v1.AdditionalSpecContent DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.AdditionalSpecContent(); + } + + public static com.google.cloud.apihub.v1.AdditionalSpecContent getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AdditionalSpecContent parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AdditionalSpecContent getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AdditionalSpecContentOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AdditionalSpecContentOrBuilder.java new file mode 100644 index 000000000000..0c398a1f29a6 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AdditionalSpecContentOrBuilder.java @@ -0,0 +1,244 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/common_fields.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface AdditionalSpecContentOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.AdditionalSpecContent) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The type of the spec content.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for specContentType. + */ + int getSpecContentTypeValue(); + + /** + * + * + *
                      +   * Required. The type of the spec content.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The specContentType. + */ + com.google.cloud.apihub.v1.SpecContentType getSpecContentType(); + + /** + * + * + *
                      +   * Optional. The additional spec contents.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the specContents field is set. + */ + boolean hasSpecContents(); + + /** + * + * + *
                      +   * Optional. The additional spec contents.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The specContents. + */ + com.google.cloud.apihub.v1.SpecContents getSpecContents(); + + /** + * + * + *
                      +   * Optional. The additional spec contents.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContents spec_contents = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.SpecContentsOrBuilder getSpecContentsOrBuilder(); + + /** + * + * + *
                      +   * Output only. The time at which the spec content was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
                      +   * Output only. The time at which the spec content was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
                      +   * Output only. The time at which the spec content was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
                      +   * Output only. The time at which the spec content was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + + /** + * + * + *
                      +   * Output only. The time at which the spec content was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + + /** + * + * + *
                      +   * Output only. The time at which the spec content was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
                      +   * Optional. The labels of the spec content e.g. specboost addon version.
                      +   * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + int getLabelsCount(); + + /** + * + * + *
                      +   * Optional. The labels of the spec content e.g. specboost addon version.
                      +   * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + boolean containsLabels(java.lang.String key); + + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Deprecated + java.util.Map getLabels(); + + /** + * + * + *
                      +   * Optional. The labels of the spec content e.g. specboost addon version.
                      +   * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.util.Map getLabelsMap(); + + /** + * + * + *
                      +   * Optional. The labels of the spec content e.g. specboost addon version.
                      +   * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + /* nullable */ + java.lang.String getLabelsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue); + + /** + * + * + *
                      +   * Optional. The labels of the spec content e.g. specboost addon version.
                      +   * 
                      + * + * map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.lang.String getLabelsOrThrow(java.lang.String key); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Addon.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Addon.java new file mode 100644 index 000000000000..720138da0887 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Addon.java @@ -0,0 +1,2540 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Addon resource.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.Addon} + */ +@com.google.protobuf.Generated +public final class Addon extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.Addon) + AddonOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Addon"); + } + + // Use Addon.newBuilder() to construct. + private Addon(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Addon() { + name_ = ""; + displayName_ = ""; + description_ = ""; + dataSource_ = 0; + state_ = 0; + boostSpecGeminiRegionId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_Addon_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_Addon_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.Addon.class, com.google.cloud.apihub.v1.Addon.Builder.class); + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
                      +   * Identifier. The name of the addon to enable.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Identifier. The name of the addon to enable.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object displayName_ = ""; + + /** + * + * + *
                      +   * Required. The display name of the addon.
                      +   * 
                      + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The display name of the addon.
                      +   * 
                      + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object description_ = ""; + + /** + * + * + *
                      +   * Optional. The description of the addon.
                      +   * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Optional. The description of the addon.
                      +   * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DATA_SOURCE_FIELD_NUMBER = 4; + private int dataSource_ = 0; + + /** + * + * + *
                      +   * Required. The data source on which the addon operates. This determines
                      +   * which field in the `config` oneof is used.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.DataSource data_source = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for dataSource. + */ + @java.lang.Override + public int getDataSourceValue() { + return dataSource_; + } + + /** + * + * + *
                      +   * Required. The data source on which the addon operates. This determines
                      +   * which field in the `config` oneof is used.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.DataSource data_source = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The dataSource. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.DataSource getDataSource() { + com.google.cloud.apihub.v1.DataSource result = + com.google.cloud.apihub.v1.DataSource.forNumber(dataSource_); + return result == null ? com.google.cloud.apihub.v1.DataSource.UNRECOGNIZED : result; + } + + public static final int CREATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
                      +   * Output only. The time at which the addon was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Output only. The time at which the addon was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
                      +   * Output only. The time at which the addon was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp updateTime_; + + /** + * + * + *
                      +   * Output only. The time at which the addon was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Output only. The time at which the addon was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + /** + * + * + *
                      +   * Output only. The time at which the addon was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + public static final int CONFIG_FIELD_NUMBER = 7; + private com.google.cloud.apihub.v1.AddonConfig config_; + + /** + * + * + *
                      +   * Required. The configuration of the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the config field is set. + */ + @java.lang.Override + public boolean hasConfig() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +   * Required. The configuration of the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The config. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AddonConfig getConfig() { + return config_ == null ? com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance() : config_; + } + + /** + * + * + *
                      +   * Required. The configuration of the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AddonConfigOrBuilder getConfigOrBuilder() { + return config_ == null ? com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance() : config_; + } + + public static final int STATE_FIELD_NUMBER = 8; + private int state_ = 0; + + /** + * + * + *
                      +   * Output only. The state of the addon.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.AddonState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
                      +   * Output only. The state of the addon.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.AddonState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AddonState getState() { + com.google.cloud.apihub.v1.AddonState result = + com.google.cloud.apihub.v1.AddonState.forNumber(state_); + return result == null ? com.google.cloud.apihub.v1.AddonState.UNRECOGNIZED : result; + } + + public static final int BOOST_SPEC_GEMINI_REGION_ID_FIELD_NUMBER = 9; + + @SuppressWarnings("serial") + private volatile java.lang.Object boostSpecGeminiRegionId_ = ""; + + /** + * + * + *
                      +   * Output only. The Vertex AI region where the BoostSpec Gemini model calls
                      +   * run for this API Hub instance. Populated only for the SpecGen addon
                      +   * (`system-spec-generation`); other addons leave this field empty.
                      +   *
                      +   * `gemini-2.5-flash` is not available in every API Hub region, so the
                      +   * effective region may differ from the API Hub instance's own region.
                      +   * The value follows these semantics:
                      +   *
                      +   * - `""`: BoostSpec is disabled in this region (the addon is not
                      +   * SpecGen, or the API Hub instance region has no configured
                      +   * Gemini endpoint or fallback).
                      +   * - Equal to the API Hub instance region: BoostSpec calls run
                      +   * in-region.
                      +   * - Differs from the API Hub instance region: BoostSpec calls run
                      +   * in the specified fallback region.
                      +   *
                      +   * Callers rendering this field can derive the three display states
                      +   * from this single field combined with the API Hub instance region.
                      +   * 
                      + * + * string boost_spec_gemini_region_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The boostSpecGeminiRegionId. + */ + @java.lang.Override + public java.lang.String getBoostSpecGeminiRegionId() { + java.lang.Object ref = boostSpecGeminiRegionId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + boostSpecGeminiRegionId_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Output only. The Vertex AI region where the BoostSpec Gemini model calls
                      +   * run for this API Hub instance. Populated only for the SpecGen addon
                      +   * (`system-spec-generation`); other addons leave this field empty.
                      +   *
                      +   * `gemini-2.5-flash` is not available in every API Hub region, so the
                      +   * effective region may differ from the API Hub instance's own region.
                      +   * The value follows these semantics:
                      +   *
                      +   * - `""`: BoostSpec is disabled in this region (the addon is not
                      +   * SpecGen, or the API Hub instance region has no configured
                      +   * Gemini endpoint or fallback).
                      +   * - Equal to the API Hub instance region: BoostSpec calls run
                      +   * in-region.
                      +   * - Differs from the API Hub instance region: BoostSpec calls run
                      +   * in the specified fallback region.
                      +   *
                      +   * Callers rendering this field can derive the three display states
                      +   * from this single field combined with the API Hub instance region.
                      +   * 
                      + * + * string boost_spec_gemini_region_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The bytes for boostSpecGeminiRegionId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getBoostSpecGeminiRegionIdBytes() { + java.lang.Object ref = boostSpecGeminiRegionId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + boostSpecGeminiRegionId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, displayName_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, description_); + } + if (dataSource_ != com.google.cloud.apihub.v1.DataSource.DATA_SOURCE_UNSPECIFIED.getNumber()) { + output.writeEnum(4, dataSource_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(6, getUpdateTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(7, getConfig()); + } + if (state_ != com.google.cloud.apihub.v1.AddonState.ADDON_STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(8, state_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(boostSpecGeminiRegionId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 9, boostSpecGeminiRegionId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, displayName_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, description_); + } + if (dataSource_ != com.google.cloud.apihub.v1.DataSource.DATA_SOURCE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, dataSource_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getConfig()); + } + if (state_ != com.google.cloud.apihub.v1.AddonState.ADDON_STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(8, state_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(boostSpecGeminiRegionId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(9, boostSpecGeminiRegionId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.Addon)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.Addon other = (com.google.cloud.apihub.v1.Addon) obj; + + if (!getName().equals(other.getName())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (dataSource_ != other.dataSource_) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (hasConfig() != other.hasConfig()) return false; + if (hasConfig()) { + if (!getConfig().equals(other.getConfig())) return false; + } + if (state_ != other.state_) return false; + if (!getBoostSpecGeminiRegionId().equals(other.getBoostSpecGeminiRegionId())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + hash = (37 * hash) + DATA_SOURCE_FIELD_NUMBER; + hash = (53 * hash) + dataSource_; + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + if (hasConfig()) { + hash = (37 * hash) + CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getConfig().hashCode(); + } + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + hash = (37 * hash) + BOOST_SPEC_GEMINI_REGION_ID_FIELD_NUMBER; + hash = (53 * hash) + getBoostSpecGeminiRegionId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.Addon parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.Addon parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.Addon parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.Addon parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.Addon parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.Addon parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.Addon parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.Addon parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.Addon parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.Addon parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.Addon parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.Addon parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.Addon prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Addon resource.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.Addon} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.Addon) + com.google.cloud.apihub.v1.AddonOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_Addon_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_Addon_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.Addon.class, + com.google.cloud.apihub.v1.Addon.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.Addon.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetCreateTimeFieldBuilder(); + internalGetUpdateTimeFieldBuilder(); + internalGetConfigFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + displayName_ = ""; + description_ = ""; + dataSource_ = 0; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + config_ = null; + if (configBuilder_ != null) { + configBuilder_.dispose(); + configBuilder_ = null; + } + state_ = 0; + boostSpecGeminiRegionId_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_Addon_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.Addon getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.Addon.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.Addon build() { + com.google.cloud.apihub.v1.Addon result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.Addon buildPartial() { + com.google.cloud.apihub.v1.Addon result = new com.google.cloud.apihub.v1.Addon(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.Addon result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.displayName_ = displayName_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.description_ = description_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.dataSource_ = dataSource_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000010) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.config_ = configBuilder_ == null ? config_ : configBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.state_ = state_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.boostSpecGeminiRegionId_ = boostSpecGeminiRegionId_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.Addon) { + return mergeFrom((com.google.cloud.apihub.v1.Addon) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.Addon other) { + if (other == com.google.cloud.apihub.v1.Addon.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.dataSource_ != 0) { + setDataSourceValue(other.getDataSourceValue()); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (other.hasConfig()) { + mergeConfig(other.getConfig()); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (!other.getBoostSpecGeminiRegionId().isEmpty()) { + boostSpecGeminiRegionId_ = other.boostSpecGeminiRegionId_; + bitField0_ |= 0x00000100; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 32: + { + dataSource_ = input.readEnum(); + bitField0_ |= 0x00000008; + break; + } // case 32 + case 42: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + input.readMessage( + internalGetUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + case 58: + { + input.readMessage(internalGetConfigFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000040; + break; + } // case 58 + case 64: + { + state_ = input.readEnum(); + bitField0_ |= 0x00000080; + break; + } // case 64 + case 74: + { + boostSpecGeminiRegionId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000100; + break; + } // case 74 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
                      +     * Identifier. The name of the addon to enable.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Identifier. The name of the addon to enable.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Identifier. The name of the addon to enable.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Identifier. The name of the addon to enable.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Identifier. The name of the addon to enable.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + + /** + * + * + *
                      +     * Required. The display name of the addon.
                      +     * 
                      + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The display name of the addon.
                      +     * 
                      + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The display name of the addon.
                      +     * 
                      + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The display name of the addon.
                      +     * 
                      + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + displayName_ = getDefaultInstance().getDisplayName(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The display name of the addon.
                      +     * 
                      + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + + /** + * + * + *
                      +     * Optional. The description of the addon.
                      +     * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Optional. The description of the addon.
                      +     * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Optional. The description of the addon.
                      +     * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + description_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The description of the addon.
                      +     * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + description_ = getDefaultInstance().getDescription(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The description of the addon.
                      +     * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private int dataSource_ = 0; + + /** + * + * + *
                      +     * Required. The data source on which the addon operates. This determines
                      +     * which field in the `config` oneof is used.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.DataSource data_source = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for dataSource. + */ + @java.lang.Override + public int getDataSourceValue() { + return dataSource_; + } + + /** + * + * + *
                      +     * Required. The data source on which the addon operates. This determines
                      +     * which field in the `config` oneof is used.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.DataSource data_source = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The enum numeric value on the wire for dataSource to set. + * @return This builder for chaining. + */ + public Builder setDataSourceValue(int value) { + dataSource_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The data source on which the addon operates. This determines
                      +     * which field in the `config` oneof is used.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.DataSource data_source = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The dataSource. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.DataSource getDataSource() { + com.google.cloud.apihub.v1.DataSource result = + com.google.cloud.apihub.v1.DataSource.forNumber(dataSource_); + return result == null ? com.google.cloud.apihub.v1.DataSource.UNRECOGNIZED : result; + } + + /** + * + * + *
                      +     * Required. The data source on which the addon operates. This determines
                      +     * which field in the `config` oneof is used.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.DataSource data_source = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The dataSource to set. + * @return This builder for chaining. + */ + public Builder setDataSource(com.google.cloud.apihub.v1.DataSource value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000008; + dataSource_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The data source on which the addon operates. This determines
                      +     * which field in the `config` oneof is used.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.DataSource data_source = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearDataSource() { + bitField0_ = (bitField0_ & ~0x00000008); + dataSource_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
                      +     * Output only. The time at which the addon was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000010); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was created.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
                      +     * Output only. The time at which the addon was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + } else { + updateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && updateTime_ != null + && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getUpdateTimeBuilder().mergeFrom(value); + } else { + updateTime_ = value; + } + } else { + updateTimeBuilder_.mergeFrom(value); + } + if (updateTime_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000020); + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + + /** + * + * + *
                      +     * Output only. The time at which the addon was last updated.
                      +     * 
                      + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private com.google.cloud.apihub.v1.AddonConfig config_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AddonConfig, + com.google.cloud.apihub.v1.AddonConfig.Builder, + com.google.cloud.apihub.v1.AddonConfigOrBuilder> + configBuilder_; + + /** + * + * + *
                      +     * Required. The configuration of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the config field is set. + */ + public boolean hasConfig() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
                      +     * Required. The configuration of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The config. + */ + public com.google.cloud.apihub.v1.AddonConfig getConfig() { + if (configBuilder_ == null) { + return config_ == null + ? com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance() + : config_; + } else { + return configBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Required. The configuration of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setConfig(com.google.cloud.apihub.v1.AddonConfig value) { + if (configBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + } else { + configBuilder_.setMessage(value); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The configuration of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setConfig(com.google.cloud.apihub.v1.AddonConfig.Builder builderForValue) { + if (configBuilder_ == null) { + config_ = builderForValue.build(); + } else { + configBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The configuration of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeConfig(com.google.cloud.apihub.v1.AddonConfig value) { + if (configBuilder_ == null) { + if (((bitField0_ & 0x00000040) != 0) + && config_ != null + && config_ != com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance()) { + getConfigBuilder().mergeFrom(value); + } else { + config_ = value; + } + } else { + configBuilder_.mergeFrom(value); + } + if (config_ != null) { + bitField0_ |= 0x00000040; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Required. The configuration of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearConfig() { + bitField0_ = (bitField0_ & ~0x00000040); + config_ = null; + if (configBuilder_ != null) { + configBuilder_.dispose(); + configBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The configuration of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.AddonConfig.Builder getConfigBuilder() { + bitField0_ |= 0x00000040; + onChanged(); + return internalGetConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Required. The configuration of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.AddonConfigOrBuilder getConfigOrBuilder() { + if (configBuilder_ != null) { + return configBuilder_.getMessageOrBuilder(); + } else { + return config_ == null + ? com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance() + : config_; + } + } + + /** + * + * + *
                      +     * Required. The configuration of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AddonConfig, + com.google.cloud.apihub.v1.AddonConfig.Builder, + com.google.cloud.apihub.v1.AddonConfigOrBuilder> + internalGetConfigFieldBuilder() { + if (configBuilder_ == null) { + configBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AddonConfig, + com.google.cloud.apihub.v1.AddonConfig.Builder, + com.google.cloud.apihub.v1.AddonConfigOrBuilder>( + getConfig(), getParentForChildren(), isClean()); + config_ = null; + } + return configBuilder_; + } + + private int state_ = 0; + + /** + * + * + *
                      +     * Output only. The state of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
                      +     * Output only. The state of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The state of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AddonState getState() { + com.google.cloud.apihub.v1.AddonState result = + com.google.cloud.apihub.v1.AddonState.forNumber(state_); + return result == null ? com.google.cloud.apihub.v1.AddonState.UNRECOGNIZED : result; + } + + /** + * + * + *
                      +     * Output only. The state of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.apihub.v1.AddonState value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000080; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The state of the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000080); + state_ = 0; + onChanged(); + return this; + } + + private java.lang.Object boostSpecGeminiRegionId_ = ""; + + /** + * + * + *
                      +     * Output only. The Vertex AI region where the BoostSpec Gemini model calls
                      +     * run for this API Hub instance. Populated only for the SpecGen addon
                      +     * (`system-spec-generation`); other addons leave this field empty.
                      +     *
                      +     * `gemini-2.5-flash` is not available in every API Hub region, so the
                      +     * effective region may differ from the API Hub instance's own region.
                      +     * The value follows these semantics:
                      +     *
                      +     * - `""`: BoostSpec is disabled in this region (the addon is not
                      +     * SpecGen, or the API Hub instance region has no configured
                      +     * Gemini endpoint or fallback).
                      +     * - Equal to the API Hub instance region: BoostSpec calls run
                      +     * in-region.
                      +     * - Differs from the API Hub instance region: BoostSpec calls run
                      +     * in the specified fallback region.
                      +     *
                      +     * Callers rendering this field can derive the three display states
                      +     * from this single field combined with the API Hub instance region.
                      +     * 
                      + * + * string boost_spec_gemini_region_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The boostSpecGeminiRegionId. + */ + public java.lang.String getBoostSpecGeminiRegionId() { + java.lang.Object ref = boostSpecGeminiRegionId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + boostSpecGeminiRegionId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Output only. The Vertex AI region where the BoostSpec Gemini model calls
                      +     * run for this API Hub instance. Populated only for the SpecGen addon
                      +     * (`system-spec-generation`); other addons leave this field empty.
                      +     *
                      +     * `gemini-2.5-flash` is not available in every API Hub region, so the
                      +     * effective region may differ from the API Hub instance's own region.
                      +     * The value follows these semantics:
                      +     *
                      +     * - `""`: BoostSpec is disabled in this region (the addon is not
                      +     * SpecGen, or the API Hub instance region has no configured
                      +     * Gemini endpoint or fallback).
                      +     * - Equal to the API Hub instance region: BoostSpec calls run
                      +     * in-region.
                      +     * - Differs from the API Hub instance region: BoostSpec calls run
                      +     * in the specified fallback region.
                      +     *
                      +     * Callers rendering this field can derive the three display states
                      +     * from this single field combined with the API Hub instance region.
                      +     * 
                      + * + * string boost_spec_gemini_region_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The bytes for boostSpecGeminiRegionId. + */ + public com.google.protobuf.ByteString getBoostSpecGeminiRegionIdBytes() { + java.lang.Object ref = boostSpecGeminiRegionId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + boostSpecGeminiRegionId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Output only. The Vertex AI region where the BoostSpec Gemini model calls
                      +     * run for this API Hub instance. Populated only for the SpecGen addon
                      +     * (`system-spec-generation`); other addons leave this field empty.
                      +     *
                      +     * `gemini-2.5-flash` is not available in every API Hub region, so the
                      +     * effective region may differ from the API Hub instance's own region.
                      +     * The value follows these semantics:
                      +     *
                      +     * - `""`: BoostSpec is disabled in this region (the addon is not
                      +     * SpecGen, or the API Hub instance region has no configured
                      +     * Gemini endpoint or fallback).
                      +     * - Equal to the API Hub instance region: BoostSpec calls run
                      +     * in-region.
                      +     * - Differs from the API Hub instance region: BoostSpec calls run
                      +     * in the specified fallback region.
                      +     *
                      +     * Callers rendering this field can derive the three display states
                      +     * from this single field combined with the API Hub instance region.
                      +     * 
                      + * + * string boost_spec_gemini_region_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The boostSpecGeminiRegionId to set. + * @return This builder for chaining. + */ + public Builder setBoostSpecGeminiRegionId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + boostSpecGeminiRegionId_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The Vertex AI region where the BoostSpec Gemini model calls
                      +     * run for this API Hub instance. Populated only for the SpecGen addon
                      +     * (`system-spec-generation`); other addons leave this field empty.
                      +     *
                      +     * `gemini-2.5-flash` is not available in every API Hub region, so the
                      +     * effective region may differ from the API Hub instance's own region.
                      +     * The value follows these semantics:
                      +     *
                      +     * - `""`: BoostSpec is disabled in this region (the addon is not
                      +     * SpecGen, or the API Hub instance region has no configured
                      +     * Gemini endpoint or fallback).
                      +     * - Equal to the API Hub instance region: BoostSpec calls run
                      +     * in-region.
                      +     * - Differs from the API Hub instance region: BoostSpec calls run
                      +     * in the specified fallback region.
                      +     *
                      +     * Callers rendering this field can derive the three display states
                      +     * from this single field combined with the API Hub instance region.
                      +     * 
                      + * + * string boost_spec_gemini_region_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearBoostSpecGeminiRegionId() { + boostSpecGeminiRegionId_ = getDefaultInstance().getBoostSpecGeminiRegionId(); + bitField0_ = (bitField0_ & ~0x00000100); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The Vertex AI region where the BoostSpec Gemini model calls
                      +     * run for this API Hub instance. Populated only for the SpecGen addon
                      +     * (`system-spec-generation`); other addons leave this field empty.
                      +     *
                      +     * `gemini-2.5-flash` is not available in every API Hub region, so the
                      +     * effective region may differ from the API Hub instance's own region.
                      +     * The value follows these semantics:
                      +     *
                      +     * - `""`: BoostSpec is disabled in this region (the addon is not
                      +     * SpecGen, or the API Hub instance region has no configured
                      +     * Gemini endpoint or fallback).
                      +     * - Equal to the API Hub instance region: BoostSpec calls run
                      +     * in-region.
                      +     * - Differs from the API Hub instance region: BoostSpec calls run
                      +     * in the specified fallback region.
                      +     *
                      +     * Callers rendering this field can derive the three display states
                      +     * from this single field combined with the API Hub instance region.
                      +     * 
                      + * + * string boost_spec_gemini_region_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The bytes for boostSpecGeminiRegionId to set. + * @return This builder for chaining. + */ + public Builder setBoostSpecGeminiRegionIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + boostSpecGeminiRegionId_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.Addon) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.Addon) + private static final com.google.cloud.apihub.v1.Addon DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.Addon(); + } + + public static com.google.cloud.apihub.v1.Addon getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Addon parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.Addon getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonConfig.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonConfig.java new file mode 100644 index 000000000000..855875dd27ec --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonConfig.java @@ -0,0 +1,1118 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Configuration for the addon.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.AddonConfig} + */ +@com.google.protobuf.Generated +public final class AddonConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.AddonConfig) + AddonConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AddonConfig"); + } + + // Use AddonConfig.newBuilder() to construct. + private AddonConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AddonConfig() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_AddonConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_AddonConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.AddonConfig.class, + com.google.cloud.apihub.v1.AddonConfig.Builder.class); + } + + private int configCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object config_; + + public enum ConfigCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + GATEWAY_PLUGIN_ADDON_CONFIG(1), + ALL_DATA_ADDON_CONFIG(2), + CONFIG_NOT_SET(0); + private final int value; + + private ConfigCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ConfigCase valueOf(int value) { + return forNumber(value); + } + + public static ConfigCase forNumber(int value) { + switch (value) { + case 1: + return GATEWAY_PLUGIN_ADDON_CONFIG; + case 2: + return ALL_DATA_ADDON_CONFIG; + case 0: + return CONFIG_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ConfigCase getConfigCase() { + return ConfigCase.forNumber(configCase_); + } + + public static final int GATEWAY_PLUGIN_ADDON_CONFIG_FIELD_NUMBER = 1; + + /** + * + * + *
                      +   * Configuration for gateway plugin addons.
                      +   * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + * @return Whether the gatewayPluginAddonConfig field is set. + */ + @java.lang.Override + public boolean hasGatewayPluginAddonConfig() { + return configCase_ == 1; + } + + /** + * + * + *
                      +   * Configuration for gateway plugin addons.
                      +   * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + * @return The gatewayPluginAddonConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginAddonConfig getGatewayPluginAddonConfig() { + if (configCase_ == 1) { + return (com.google.cloud.apihub.v1.GatewayPluginAddonConfig) config_; + } + return com.google.cloud.apihub.v1.GatewayPluginAddonConfig.getDefaultInstance(); + } + + /** + * + * + *
                      +   * Configuration for gateway plugin addons.
                      +   * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginAddonConfigOrBuilder + getGatewayPluginAddonConfigOrBuilder() { + if (configCase_ == 1) { + return (com.google.cloud.apihub.v1.GatewayPluginAddonConfig) config_; + } + return com.google.cloud.apihub.v1.GatewayPluginAddonConfig.getDefaultInstance(); + } + + public static final int ALL_DATA_ADDON_CONFIG_FIELD_NUMBER = 2; + + /** + * + * + *
                      +   * Configuration for addons which act on all data in the API hub.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + * + * @return Whether the allDataAddonConfig field is set. + */ + @java.lang.Override + public boolean hasAllDataAddonConfig() { + return configCase_ == 2; + } + + /** + * + * + *
                      +   * Configuration for addons which act on all data in the API hub.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + * + * @return The allDataAddonConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AllDataAddonConfig getAllDataAddonConfig() { + if (configCase_ == 2) { + return (com.google.cloud.apihub.v1.AllDataAddonConfig) config_; + } + return com.google.cloud.apihub.v1.AllDataAddonConfig.getDefaultInstance(); + } + + /** + * + * + *
                      +   * Configuration for addons which act on all data in the API hub.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AllDataAddonConfigOrBuilder getAllDataAddonConfigOrBuilder() { + if (configCase_ == 2) { + return (com.google.cloud.apihub.v1.AllDataAddonConfig) config_; + } + return com.google.cloud.apihub.v1.AllDataAddonConfig.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (configCase_ == 1) { + output.writeMessage(1, (com.google.cloud.apihub.v1.GatewayPluginAddonConfig) config_); + } + if (configCase_ == 2) { + output.writeMessage(2, (com.google.cloud.apihub.v1.AllDataAddonConfig) config_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (configCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.cloud.apihub.v1.GatewayPluginAddonConfig) config_); + } + if (configCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.apihub.v1.AllDataAddonConfig) config_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.AddonConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.AddonConfig other = (com.google.cloud.apihub.v1.AddonConfig) obj; + + if (!getConfigCase().equals(other.getConfigCase())) return false; + switch (configCase_) { + case 1: + if (!getGatewayPluginAddonConfig().equals(other.getGatewayPluginAddonConfig())) + return false; + break; + case 2: + if (!getAllDataAddonConfig().equals(other.getAllDataAddonConfig())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (configCase_) { + case 1: + hash = (37 * hash) + GATEWAY_PLUGIN_ADDON_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getGatewayPluginAddonConfig().hashCode(); + break; + case 2: + hash = (37 * hash) + ALL_DATA_ADDON_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getAllDataAddonConfig().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.AddonConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.AddonConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AddonConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.AddonConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AddonConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.AddonConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AddonConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.AddonConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AddonConfig parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.AddonConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AddonConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.AddonConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.AddonConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Configuration for the addon.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.AddonConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.AddonConfig) + com.google.cloud.apihub.v1.AddonConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_AddonConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_AddonConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.AddonConfig.class, + com.google.cloud.apihub.v1.AddonConfig.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.AddonConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (gatewayPluginAddonConfigBuilder_ != null) { + gatewayPluginAddonConfigBuilder_.clear(); + } + if (allDataAddonConfigBuilder_ != null) { + allDataAddonConfigBuilder_.clear(); + } + configCase_ = 0; + config_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_AddonConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AddonConfig getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AddonConfig build() { + com.google.cloud.apihub.v1.AddonConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AddonConfig buildPartial() { + com.google.cloud.apihub.v1.AddonConfig result = + new com.google.cloud.apihub.v1.AddonConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.AddonConfig result) { + int from_bitField0_ = bitField0_; + } + + private void buildPartialOneofs(com.google.cloud.apihub.v1.AddonConfig result) { + result.configCase_ = configCase_; + result.config_ = this.config_; + if (configCase_ == 1 && gatewayPluginAddonConfigBuilder_ != null) { + result.config_ = gatewayPluginAddonConfigBuilder_.build(); + } + if (configCase_ == 2 && allDataAddonConfigBuilder_ != null) { + result.config_ = allDataAddonConfigBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.AddonConfig) { + return mergeFrom((com.google.cloud.apihub.v1.AddonConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.AddonConfig other) { + if (other == com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance()) return this; + switch (other.getConfigCase()) { + case GATEWAY_PLUGIN_ADDON_CONFIG: + { + mergeGatewayPluginAddonConfig(other.getGatewayPluginAddonConfig()); + break; + } + case ALL_DATA_ADDON_CONFIG: + { + mergeAllDataAddonConfig(other.getAllDataAddonConfig()); + break; + } + case CONFIG_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetGatewayPluginAddonConfigFieldBuilder().getBuilder(), + extensionRegistry); + configCase_ = 1; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetAllDataAddonConfigFieldBuilder().getBuilder(), extensionRegistry); + configCase_ = 2; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int configCase_ = 0; + private java.lang.Object config_; + + public ConfigCase getConfigCase() { + return ConfigCase.forNumber(configCase_); + } + + public Builder clearConfig() { + configCase_ = 0; + config_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.GatewayPluginAddonConfig, + com.google.cloud.apihub.v1.GatewayPluginAddonConfig.Builder, + com.google.cloud.apihub.v1.GatewayPluginAddonConfigOrBuilder> + gatewayPluginAddonConfigBuilder_; + + /** + * + * + *
                      +     * Configuration for gateway plugin addons.
                      +     * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + * + * @return Whether the gatewayPluginAddonConfig field is set. + */ + @java.lang.Override + public boolean hasGatewayPluginAddonConfig() { + return configCase_ == 1; + } + + /** + * + * + *
                      +     * Configuration for gateway plugin addons.
                      +     * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + * + * @return The gatewayPluginAddonConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginAddonConfig getGatewayPluginAddonConfig() { + if (gatewayPluginAddonConfigBuilder_ == null) { + if (configCase_ == 1) { + return (com.google.cloud.apihub.v1.GatewayPluginAddonConfig) config_; + } + return com.google.cloud.apihub.v1.GatewayPluginAddonConfig.getDefaultInstance(); + } else { + if (configCase_ == 1) { + return gatewayPluginAddonConfigBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.GatewayPluginAddonConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Configuration for gateway plugin addons.
                      +     * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + */ + public Builder setGatewayPluginAddonConfig( + com.google.cloud.apihub.v1.GatewayPluginAddonConfig value) { + if (gatewayPluginAddonConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + gatewayPluginAddonConfigBuilder_.setMessage(value); + } + configCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * Configuration for gateway plugin addons.
                      +     * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + */ + public Builder setGatewayPluginAddonConfig( + com.google.cloud.apihub.v1.GatewayPluginAddonConfig.Builder builderForValue) { + if (gatewayPluginAddonConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + gatewayPluginAddonConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * Configuration for gateway plugin addons.
                      +     * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + */ + public Builder mergeGatewayPluginAddonConfig( + com.google.cloud.apihub.v1.GatewayPluginAddonConfig value) { + if (gatewayPluginAddonConfigBuilder_ == null) { + if (configCase_ == 1 + && config_ + != com.google.cloud.apihub.v1.GatewayPluginAddonConfig.getDefaultInstance()) { + config_ = + com.google.cloud.apihub.v1.GatewayPluginAddonConfig.newBuilder( + (com.google.cloud.apihub.v1.GatewayPluginAddonConfig) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 1) { + gatewayPluginAddonConfigBuilder_.mergeFrom(value); + } else { + gatewayPluginAddonConfigBuilder_.setMessage(value); + } + } + configCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * Configuration for gateway plugin addons.
                      +     * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + */ + public Builder clearGatewayPluginAddonConfig() { + if (gatewayPluginAddonConfigBuilder_ == null) { + if (configCase_ == 1) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 1) { + configCase_ = 0; + config_ = null; + } + gatewayPluginAddonConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Configuration for gateway plugin addons.
                      +     * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + */ + public com.google.cloud.apihub.v1.GatewayPluginAddonConfig.Builder + getGatewayPluginAddonConfigBuilder() { + return internalGetGatewayPluginAddonConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Configuration for gateway plugin addons.
                      +     * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginAddonConfigOrBuilder + getGatewayPluginAddonConfigOrBuilder() { + if ((configCase_ == 1) && (gatewayPluginAddonConfigBuilder_ != null)) { + return gatewayPluginAddonConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 1) { + return (com.google.cloud.apihub.v1.GatewayPluginAddonConfig) config_; + } + return com.google.cloud.apihub.v1.GatewayPluginAddonConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Configuration for gateway plugin addons.
                      +     * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.GatewayPluginAddonConfig, + com.google.cloud.apihub.v1.GatewayPluginAddonConfig.Builder, + com.google.cloud.apihub.v1.GatewayPluginAddonConfigOrBuilder> + internalGetGatewayPluginAddonConfigFieldBuilder() { + if (gatewayPluginAddonConfigBuilder_ == null) { + if (!(configCase_ == 1)) { + config_ = com.google.cloud.apihub.v1.GatewayPluginAddonConfig.getDefaultInstance(); + } + gatewayPluginAddonConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.GatewayPluginAddonConfig, + com.google.cloud.apihub.v1.GatewayPluginAddonConfig.Builder, + com.google.cloud.apihub.v1.GatewayPluginAddonConfigOrBuilder>( + (com.google.cloud.apihub.v1.GatewayPluginAddonConfig) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 1; + onChanged(); + return gatewayPluginAddonConfigBuilder_; + } + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AllDataAddonConfig, + com.google.cloud.apihub.v1.AllDataAddonConfig.Builder, + com.google.cloud.apihub.v1.AllDataAddonConfigOrBuilder> + allDataAddonConfigBuilder_; + + /** + * + * + *
                      +     * Configuration for addons which act on all data in the API hub.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + * + * @return Whether the allDataAddonConfig field is set. + */ + @java.lang.Override + public boolean hasAllDataAddonConfig() { + return configCase_ == 2; + } + + /** + * + * + *
                      +     * Configuration for addons which act on all data in the API hub.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + * + * @return The allDataAddonConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AllDataAddonConfig getAllDataAddonConfig() { + if (allDataAddonConfigBuilder_ == null) { + if (configCase_ == 2) { + return (com.google.cloud.apihub.v1.AllDataAddonConfig) config_; + } + return com.google.cloud.apihub.v1.AllDataAddonConfig.getDefaultInstance(); + } else { + if (configCase_ == 2) { + return allDataAddonConfigBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.AllDataAddonConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Configuration for addons which act on all data in the API hub.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + */ + public Builder setAllDataAddonConfig(com.google.cloud.apihub.v1.AllDataAddonConfig value) { + if (allDataAddonConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + allDataAddonConfigBuilder_.setMessage(value); + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * Configuration for addons which act on all data in the API hub.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + */ + public Builder setAllDataAddonConfig( + com.google.cloud.apihub.v1.AllDataAddonConfig.Builder builderForValue) { + if (allDataAddonConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + allDataAddonConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * Configuration for addons which act on all data in the API hub.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + */ + public Builder mergeAllDataAddonConfig(com.google.cloud.apihub.v1.AllDataAddonConfig value) { + if (allDataAddonConfigBuilder_ == null) { + if (configCase_ == 2 + && config_ != com.google.cloud.apihub.v1.AllDataAddonConfig.getDefaultInstance()) { + config_ = + com.google.cloud.apihub.v1.AllDataAddonConfig.newBuilder( + (com.google.cloud.apihub.v1.AllDataAddonConfig) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 2) { + allDataAddonConfigBuilder_.mergeFrom(value); + } else { + allDataAddonConfigBuilder_.setMessage(value); + } + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * Configuration for addons which act on all data in the API hub.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + */ + public Builder clearAllDataAddonConfig() { + if (allDataAddonConfigBuilder_ == null) { + if (configCase_ == 2) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 2) { + configCase_ = 0; + config_ = null; + } + allDataAddonConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Configuration for addons which act on all data in the API hub.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + */ + public com.google.cloud.apihub.v1.AllDataAddonConfig.Builder getAllDataAddonConfigBuilder() { + return internalGetAllDataAddonConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Configuration for addons which act on all data in the API hub.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AllDataAddonConfigOrBuilder getAllDataAddonConfigOrBuilder() { + if ((configCase_ == 2) && (allDataAddonConfigBuilder_ != null)) { + return allDataAddonConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 2) { + return (com.google.cloud.apihub.v1.AllDataAddonConfig) config_; + } + return com.google.cloud.apihub.v1.AllDataAddonConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Configuration for addons which act on all data in the API hub.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AllDataAddonConfig, + com.google.cloud.apihub.v1.AllDataAddonConfig.Builder, + com.google.cloud.apihub.v1.AllDataAddonConfigOrBuilder> + internalGetAllDataAddonConfigFieldBuilder() { + if (allDataAddonConfigBuilder_ == null) { + if (!(configCase_ == 2)) { + config_ = com.google.cloud.apihub.v1.AllDataAddonConfig.getDefaultInstance(); + } + allDataAddonConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AllDataAddonConfig, + com.google.cloud.apihub.v1.AllDataAddonConfig.Builder, + com.google.cloud.apihub.v1.AllDataAddonConfigOrBuilder>( + (com.google.cloud.apihub.v1.AllDataAddonConfig) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 2; + onChanged(); + return allDataAddonConfigBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.AddonConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.AddonConfig) + private static final com.google.cloud.apihub.v1.AddonConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.AddonConfig(); + } + + public static com.google.cloud.apihub.v1.AddonConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AddonConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AddonConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonConfigOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonConfigOrBuilder.java new file mode 100644 index 000000000000..4f8d6b9565c9 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonConfigOrBuilder.java @@ -0,0 +1,105 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface AddonConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.AddonConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Configuration for gateway plugin addons.
                      +   * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + * @return Whether the gatewayPluginAddonConfig field is set. + */ + boolean hasGatewayPluginAddonConfig(); + + /** + * + * + *
                      +   * Configuration for gateway plugin addons.
                      +   * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + * + * @return The gatewayPluginAddonConfig. + */ + com.google.cloud.apihub.v1.GatewayPluginAddonConfig getGatewayPluginAddonConfig(); + + /** + * + * + *
                      +   * Configuration for gateway plugin addons.
                      +   * 
                      + * + * .google.cloud.apihub.v1.GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + */ + com.google.cloud.apihub.v1.GatewayPluginAddonConfigOrBuilder + getGatewayPluginAddonConfigOrBuilder(); + + /** + * + * + *
                      +   * Configuration for addons which act on all data in the API hub.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + * + * @return Whether the allDataAddonConfig field is set. + */ + boolean hasAllDataAddonConfig(); + + /** + * + * + *
                      +   * Configuration for addons which act on all data in the API hub.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + * + * @return The allDataAddonConfig. + */ + com.google.cloud.apihub.v1.AllDataAddonConfig getAllDataAddonConfig(); + + /** + * + * + *
                      +   * Configuration for addons which act on all data in the API hub.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AllDataAddonConfig all_data_addon_config = 2; + */ + com.google.cloud.apihub.v1.AllDataAddonConfigOrBuilder getAllDataAddonConfigOrBuilder(); + + com.google.cloud.apihub.v1.AddonConfig.ConfigCase getConfigCase(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonName.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonName.java new file mode 100644 index 000000000000..7d12015adcef --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonName.java @@ -0,0 +1,226 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class AddonName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_ADDON = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/addons/{addon}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String addon; + + @Deprecated + protected AddonName() { + project = null; + location = null; + addon = null; + } + + private AddonName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + addon = Preconditions.checkNotNull(builder.getAddon()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAddon() { + return addon; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static AddonName of(String project, String location, String addon) { + return newBuilder().setProject(project).setLocation(location).setAddon(addon).build(); + } + + public static String format(String project, String location, String addon) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setAddon(addon) + .build() + .toString(); + } + + public static @Nullable AddonName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_ADDON.validatedMatch( + formattedString, "AddonName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("addon")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable AddonName> values) { + List list = new ArrayList<>(values.size()); + for (AddonName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_ADDON.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (addon != null) { + fieldMapBuilder.put("addon", addon); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_ADDON.instantiate( + "project", project, "location", location, "addon", addon); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + AddonName that = ((AddonName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.addon, that.addon); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(addon); + return h; + } + + /** Builder for projects/{project}/locations/{location}/addons/{addon}. */ + public static class Builder { + private String project; + private String location; + private String addon; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAddon() { + return addon; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setAddon(String addon) { + this.addon = addon; + return this; + } + + private Builder(AddonName addonName) { + this.project = addonName.project; + this.location = addonName.location; + this.addon = addonName.addon; + } + + public AddonName build() { + return new AddonName(this); + } + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonOrBuilder.java new file mode 100644 index 000000000000..8aef5772e6c2 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonOrBuilder.java @@ -0,0 +1,352 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface AddonOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.Addon) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Identifier. The name of the addon to enable.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
                      +   * Identifier. The name of the addon to enable.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
                      +   * Required. The display name of the addon.
                      +   * 
                      + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
                      +   * Required. The display name of the addon.
                      +   * 
                      + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
                      +   * Optional. The description of the addon.
                      +   * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
                      +   * Optional. The description of the addon.
                      +   * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
                      +   * Required. The data source on which the addon operates. This determines
                      +   * which field in the `config` oneof is used.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.DataSource data_source = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for dataSource. + */ + int getDataSourceValue(); + + /** + * + * + *
                      +   * Required. The data source on which the addon operates. This determines
                      +   * which field in the `config` oneof is used.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.DataSource data_source = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The dataSource. + */ + com.google.cloud.apihub.v1.DataSource getDataSource(); + + /** + * + * + *
                      +   * Output only. The time at which the addon was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
                      +   * Output only. The time at which the addon was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
                      +   * Output only. The time at which the addon was created.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
                      +   * Output only. The time at which the addon was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + + /** + * + * + *
                      +   * Output only. The time at which the addon was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + + /** + * + * + *
                      +   * Output only. The time at which the addon was last updated.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
                      +   * Required. The configuration of the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the config field is set. + */ + boolean hasConfig(); + + /** + * + * + *
                      +   * Required. The configuration of the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The config. + */ + com.google.cloud.apihub.v1.AddonConfig getConfig(); + + /** + * + * + *
                      +   * Required. The configuration of the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 7 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.apihub.v1.AddonConfigOrBuilder getConfigOrBuilder(); + + /** + * + * + *
                      +   * Output only. The state of the addon.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.AddonState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
                      +   * Output only. The state of the addon.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.AddonState state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.apihub.v1.AddonState getState(); + + /** + * + * + *
                      +   * Output only. The Vertex AI region where the BoostSpec Gemini model calls
                      +   * run for this API Hub instance. Populated only for the SpecGen addon
                      +   * (`system-spec-generation`); other addons leave this field empty.
                      +   *
                      +   * `gemini-2.5-flash` is not available in every API Hub region, so the
                      +   * effective region may differ from the API Hub instance's own region.
                      +   * The value follows these semantics:
                      +   *
                      +   * - `""`: BoostSpec is disabled in this region (the addon is not
                      +   * SpecGen, or the API Hub instance region has no configured
                      +   * Gemini endpoint or fallback).
                      +   * - Equal to the API Hub instance region: BoostSpec calls run
                      +   * in-region.
                      +   * - Differs from the API Hub instance region: BoostSpec calls run
                      +   * in the specified fallback region.
                      +   *
                      +   * Callers rendering this field can derive the three display states
                      +   * from this single field combined with the API Hub instance region.
                      +   * 
                      + * + * string boost_spec_gemini_region_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The boostSpecGeminiRegionId. + */ + java.lang.String getBoostSpecGeminiRegionId(); + + /** + * + * + *
                      +   * Output only. The Vertex AI region where the BoostSpec Gemini model calls
                      +   * run for this API Hub instance. Populated only for the SpecGen addon
                      +   * (`system-spec-generation`); other addons leave this field empty.
                      +   *
                      +   * `gemini-2.5-flash` is not available in every API Hub region, so the
                      +   * effective region may differ from the API Hub instance's own region.
                      +   * The value follows these semantics:
                      +   *
                      +   * - `""`: BoostSpec is disabled in this region (the addon is not
                      +   * SpecGen, or the API Hub instance region has no configured
                      +   * Gemini endpoint or fallback).
                      +   * - Equal to the API Hub instance region: BoostSpec calls run
                      +   * in-region.
                      +   * - Differs from the API Hub instance region: BoostSpec calls run
                      +   * in the specified fallback region.
                      +   *
                      +   * Callers rendering this field can derive the three display states
                      +   * from this single field combined with the API Hub instance region.
                      +   * 
                      + * + * string boost_spec_gemini_region_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The bytes for boostSpecGeminiRegionId. + */ + com.google.protobuf.ByteString getBoostSpecGeminiRegionIdBytes(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonServiceProto.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonServiceProto.java new file mode 100644 index 000000000000..3aec16af8923 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonServiceProto.java @@ -0,0 +1,348 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public final class AddonServiceProto extends com.google.protobuf.GeneratedFile { + private AddonServiceProto() {} + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AddonServiceProto"); + } + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_Addon_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_Addon_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_EnvironmentFilter_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_EnvironmentFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_GatewayPluginConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_GatewayPluginConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ApigeeXHybridConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ApigeeXHybridConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ApigeeEdgeConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ApigeeEdgeConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ApigeeOPDKConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ApigeeOPDKConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_GatewayPluginAddonConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_GatewayPluginAddonConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_AllDataAddonConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_AllDataAddonConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_AddonConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_AddonConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_GetAddonRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_GetAddonRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ManageAddonConfigRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ManageAddonConfigRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ListAddonsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ListAddonsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ListAddonsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ListAddonsResponse_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n" + + "*google/cloud/apihub/v1/addon_service.p" + + "roto\022\026google.cloud.apihub.v1\032\034google/api" + + "/annotations.proto\032\027google/api/client.pr" + + "oto\032\037google/api/field_behavior.proto\032\031go" + + "ogle/api/resource.proto\032*google/cloud/apihub/v1/common_fields.proto\032#google/long" + + "running/operations.proto\032\037google/protobuf/timestamp.proto\"\207\004\n" + + "\005Addon\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + + "\014display_name\030\002 \001(\tB\004\342A\001\002\022\031\n" + + "\013description\030\003 \001(\tB\004\342A\001\001\022=\n" + + "\013data_source\030\004 " + + "\001(\0162\".google.cloud.apihub.v1.DataSourceB\004\342A\001\002\0225\n" + + "\013create_time\030\005" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + + "\013update_time\030\006" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0229\n" + + "\006config\030\007" + + " \001(\0132#.google.cloud.apihub.v1.AddonConfigB\004\342A\001\002\0227\n" + + "\005state\030\010" + + " \001(\0162\".google.cloud.apihub.v1.AddonStateB\004\342A\001\003\022)\n" + + "\033boost_spec_gemini_region_id\030\t \001(\tB\004\342A\001\003:g\352Ad\n" + + "\033apihub.googleapis.com/Addon\0226projects/{" + + "project}/locations/{location}/addons/{addon}*\006addons2\005addon\"O\n" + + "\021EnvironmentFilter\022\036\n" + + "\020all_environments\030\002 \001(\010B\004\342A\001\001\022\032\n" + + "\014environments\030\003 \003(\tB\004\342A\001\001\"\235\002\n" + + "\023GatewayPluginConfig\022M\n" + + "\026apigee_x_hybrid_config\030\002 \001(\0132+.g" + + "oogle.cloud.apihub.v1.ApigeeXHybridConfigH\000\022F\n" + + "\022apigee_edge_config\030\003" + + " \001(\0132(.google.cloud.apihub.v1.ApigeeEdgeConfigH\000\022F\n" + + "\022apigee_opdk_config\030\004" + + " \001(\0132(.google.cloud.apihub.v1.ApigeeOPDKConfigH\000\022\035\n" + + "\017plugin_instance\030\001 \001(\tB\004\342A\001\002B\010\n" + + "\006config\"b\n" + + "\023ApigeeXHybridConfig\022K\n" + + "\022environment_filter\030\001 \001(\0132" + + ").google.cloud.apihub.v1.EnvironmentFilterB\004\342A\001\001\"_\n" + + "\020ApigeeEdgeConfig\022K\n" + + "\022environment_filter\030\001" + + " \001(\0132).google.cloud.apihub.v1.EnvironmentFilterB\004\342A\001\001\"_\n" + + "\020ApigeeOPDKConfig\022K\n" + + "\022environment_filter\030\001 \001(\0132).goog" + + "le.cloud.apihub.v1.EnvironmentFilterB\004\342A\001\001\"m\n" + + "\030GatewayPluginAddonConfig\022Q\n" + + "\026gateway_plugin_configs\030\001" + + " \003(\0132+.google.cloud.apihub.v1.GatewayPluginConfigB\004\342A\001\002\"+\n" + + "\022AllDataAddonConfig\022\025\n" + + "\007enabled\030\001 \001(\010B\004\342A\001\002\"\275\001\n" + + "\013AddonConfig\022W\n" + + "\033gateway_plugin_addon_config\030\001" + + " \001(\01320.google.cloud.apihub.v1.GatewayPluginAddonConfigH\000\022K\n" + + "\025all_data_addon_config\030\002" + + " \001(\0132*.google.cloud.apihub.v1.AllDataAddonConfigH\000B\010\n" + + "\006config\"E\n" + + "\017GetAddonRequest\0222\n" + + "\004name\030\001 \001(\tB$\342A\001\002\372A\035\n" + + "\033apihub.googleapis.com/Addon\"\211\001\n" + + "\030ManageAddonConfigRequest\0222\n" + + "\004name\030\001 \001(\tB$\342A\001\002\372A\035\n" + + "\033apihub.googleapis.com/Addon\0229\n" + + "\006config\030\002 \001(\0132#" + + ".google.cloud.apihub.v1.AddonConfigB\004\342A\001\002\"\222\001\n" + + "\021ListAddonsRequest\0224\n" + + "\006parent\030\001 \001(" + + "\tB$\342A\001\002\372A\035\022\033apihub.googleapis.com/Addon\022\024\n" + + "\006filter\030\002 \001(\tB\004\342A\001\001\022\027\n" + + "\tpage_size\030\003 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\004 \001(\tB\004\342A\001\001\"\\\n" + + "\022ListAddonsResponse\022-\n" + + "\006addons\030\001 \003(\0132\035.google.cloud.apihub.v1.Addon\022\027\n" + + "\017next_page_token\030\002 \001(\t2\304\005\n" + + "\013ApiHubAddon\022\215\001\n" + + "\010GetAddon\022\'.google.cloud.apihub.v1.GetAddonRequest\032\035.goo" + + "gle.cloud.apihub.v1.Addon\"9\332A\004name\202\323\344\223\002," + + "\022*/v1/{name=projects/*/locations/*/addons/*}\022\323\001\n" + + "\021ManageAddonConfig\0220.google.clou" + + "d.apihub.v1.ManageAddonConfigRequest\032\035.google.longrunning.Operation\"m\312A\032\n" + + "\005Addon\022\021OperationMetadata\332A\013name,config\202\323\344\223\002<\"7" + + "/v1/{name=projects/*/locations/*/addons/*}:manageConfig:\001*\022\240\001\n\n" + + "ListAddons\022).google.cloud.apihub.v1.ListAddonsRequest\032*.g" + + "oogle.cloud.apihub.v1.ListAddonsResponse" + + "\";\332A\006parent\202\323\344\223\002,\022*/v1/{parent=projects/" + + "*/locations/*}/addons\032\253\001\312A\025apihub.google" + + "apis.com\322A\217\001https://www.googleapis.com/a" + + "uth/apihub.readonly,https://www.googleap" + + "is.com/auth/apihub.readwrite,https://www.googleapis.com/auth/cloud-platformB\263\001\n" + + "\032com.google.cloud.apihub.v1B\021AddonService" + + "ProtoP\001Z2cloud.google.com/go/apihub/apiv" + + "1/apihubpb;apihubpb\252\002\026Google.Cloud.ApiHu" + + "b.V1\312\002\026Google\\Cloud\\ApiHub\\V1\352\002\031Google::" + + "Cloud::ApiHub::V1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.AnnotationsProto.getDescriptor(), + com.google.api.ClientProto.getDescriptor(), + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.cloud.apihub.v1.CommonFieldsProto.getDescriptor(), + com.google.longrunning.OperationsProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_apihub_v1_Addon_descriptor = getDescriptor().getMessageType(0); + internal_static_google_cloud_apihub_v1_Addon_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_Addon_descriptor, + new java.lang.String[] { + "Name", + "DisplayName", + "Description", + "DataSource", + "CreateTime", + "UpdateTime", + "Config", + "State", + "BoostSpecGeminiRegionId", + }); + internal_static_google_cloud_apihub_v1_EnvironmentFilter_descriptor = + getDescriptor().getMessageType(1); + internal_static_google_cloud_apihub_v1_EnvironmentFilter_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_EnvironmentFilter_descriptor, + new java.lang.String[] { + "AllEnvironments", "Environments", + }); + internal_static_google_cloud_apihub_v1_GatewayPluginConfig_descriptor = + getDescriptor().getMessageType(2); + internal_static_google_cloud_apihub_v1_GatewayPluginConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_GatewayPluginConfig_descriptor, + new java.lang.String[] { + "ApigeeXHybridConfig", + "ApigeeEdgeConfig", + "ApigeeOpdkConfig", + "PluginInstance", + "Config", + }); + internal_static_google_cloud_apihub_v1_ApigeeXHybridConfig_descriptor = + getDescriptor().getMessageType(3); + internal_static_google_cloud_apihub_v1_ApigeeXHybridConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ApigeeXHybridConfig_descriptor, + new java.lang.String[] { + "EnvironmentFilter", + }); + internal_static_google_cloud_apihub_v1_ApigeeEdgeConfig_descriptor = + getDescriptor().getMessageType(4); + internal_static_google_cloud_apihub_v1_ApigeeEdgeConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ApigeeEdgeConfig_descriptor, + new java.lang.String[] { + "EnvironmentFilter", + }); + internal_static_google_cloud_apihub_v1_ApigeeOPDKConfig_descriptor = + getDescriptor().getMessageType(5); + internal_static_google_cloud_apihub_v1_ApigeeOPDKConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ApigeeOPDKConfig_descriptor, + new java.lang.String[] { + "EnvironmentFilter", + }); + internal_static_google_cloud_apihub_v1_GatewayPluginAddonConfig_descriptor = + getDescriptor().getMessageType(6); + internal_static_google_cloud_apihub_v1_GatewayPluginAddonConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_GatewayPluginAddonConfig_descriptor, + new java.lang.String[] { + "GatewayPluginConfigs", + }); + internal_static_google_cloud_apihub_v1_AllDataAddonConfig_descriptor = + getDescriptor().getMessageType(7); + internal_static_google_cloud_apihub_v1_AllDataAddonConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_AllDataAddonConfig_descriptor, + new java.lang.String[] { + "Enabled", + }); + internal_static_google_cloud_apihub_v1_AddonConfig_descriptor = + getDescriptor().getMessageType(8); + internal_static_google_cloud_apihub_v1_AddonConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_AddonConfig_descriptor, + new java.lang.String[] { + "GatewayPluginAddonConfig", "AllDataAddonConfig", "Config", + }); + internal_static_google_cloud_apihub_v1_GetAddonRequest_descriptor = + getDescriptor().getMessageType(9); + internal_static_google_cloud_apihub_v1_GetAddonRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_GetAddonRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_apihub_v1_ManageAddonConfigRequest_descriptor = + getDescriptor().getMessageType(10); + internal_static_google_cloud_apihub_v1_ManageAddonConfigRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ManageAddonConfigRequest_descriptor, + new java.lang.String[] { + "Name", "Config", + }); + internal_static_google_cloud_apihub_v1_ListAddonsRequest_descriptor = + getDescriptor().getMessageType(11); + internal_static_google_cloud_apihub_v1_ListAddonsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ListAddonsRequest_descriptor, + new java.lang.String[] { + "Parent", "Filter", "PageSize", "PageToken", + }); + internal_static_google_cloud_apihub_v1_ListAddonsResponse_descriptor = + getDescriptor().getMessageType(12); + internal_static_google_cloud_apihub_v1_ListAddonsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ListAddonsResponse_descriptor, + new java.lang.String[] { + "Addons", "NextPageToken", + }); + descriptor.resolveAllFeaturesImmutable(); + com.google.api.AnnotationsProto.getDescriptor(); + com.google.api.ClientProto.getDescriptor(); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.cloud.apihub.v1.CommonFieldsProto.getDescriptor(); + com.google.longrunning.OperationsProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.ClientProto.defaultHost); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.AnnotationsProto.http); + registry.add(com.google.api.ClientProto.methodSignature); + registry.add(com.google.api.ClientProto.oauthScopes); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceReference); + registry.add(com.google.longrunning.OperationsProto.operationInfo); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonState.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonState.java new file mode 100644 index 000000000000..31b215a524ba --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AddonState.java @@ -0,0 +1,237 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/common_fields.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The state of the addon.
                      + * 
                      + * + * Protobuf enum {@code google.cloud.apihub.v1.AddonState} + */ +@com.google.protobuf.Generated +public enum AddonState implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                      +   * The addon state is not specified.
                      +   * 
                      + * + * ADDON_STATE_UNSPECIFIED = 0; + */ + ADDON_STATE_UNSPECIFIED(0), + /** + * + * + *
                      +   * The addon is active.
                      +   * 
                      + * + * ACTIVE = 1; + */ + ACTIVE(1), + /** + * + * + *
                      +   * The addon is being updated.
                      +   * 
                      + * + * UPDATING = 2; + */ + UPDATING(2), + /** + * + * + *
                      +   * The addon is in error state.
                      +   * 
                      + * + * ERROR = 3; + */ + ERROR(3), + /** + * + * + *
                      +   * The addon is inactive.
                      +   * 
                      + * + * INACTIVE = 4; + */ + INACTIVE(4), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AddonState"); + } + + /** + * + * + *
                      +   * The addon state is not specified.
                      +   * 
                      + * + * ADDON_STATE_UNSPECIFIED = 0; + */ + public static final int ADDON_STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                      +   * The addon is active.
                      +   * 
                      + * + * ACTIVE = 1; + */ + public static final int ACTIVE_VALUE = 1; + + /** + * + * + *
                      +   * The addon is being updated.
                      +   * 
                      + * + * UPDATING = 2; + */ + public static final int UPDATING_VALUE = 2; + + /** + * + * + *
                      +   * The addon is in error state.
                      +   * 
                      + * + * ERROR = 3; + */ + public static final int ERROR_VALUE = 3; + + /** + * + * + *
                      +   * The addon is inactive.
                      +   * 
                      + * + * INACTIVE = 4; + */ + public static final int INACTIVE_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static AddonState valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static AddonState forNumber(int value) { + switch (value) { + case 0: + return ADDON_STATE_UNSPECIFIED; + case 1: + return ACTIVE; + case 2: + return UPDATING; + case 3: + return ERROR; + case 4: + return INACTIVE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public AddonState findValueByNumber(int number) { + return AddonState.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto.getDescriptor().getEnumTypes().get(5); + } + + private static final AddonState[] VALUES = values(); + + public static AddonState valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private AddonState(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.apihub.v1.AddonState) +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AllDataAddonConfig.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AllDataAddonConfig.java new file mode 100644 index 000000000000..b83bc60c6855 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AllDataAddonConfig.java @@ -0,0 +1,504 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Configuration for addons which act on all data in the API hub.
                      + * This is used to specify if the addon is enabled for all data in the API hub.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.AllDataAddonConfig} + */ +@com.google.protobuf.Generated +public final class AllDataAddonConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.AllDataAddonConfig) + AllDataAddonConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AllDataAddonConfig"); + } + + // Use AllDataAddonConfig.newBuilder() to construct. + private AllDataAddonConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AllDataAddonConfig() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_AllDataAddonConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_AllDataAddonConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.AllDataAddonConfig.class, + com.google.cloud.apihub.v1.AllDataAddonConfig.Builder.class); + } + + public static final int ENABLED_FIELD_NUMBER = 1; + private boolean enabled_ = false; + + /** + * + * + *
                      +   * Required. If true, the addon is enabled for all data in the API hub.
                      +   * 
                      + * + * bool enabled = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The enabled. + */ + @java.lang.Override + public boolean getEnabled() { + return enabled_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (enabled_ != false) { + output.writeBool(1, enabled_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (enabled_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, enabled_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.AllDataAddonConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.AllDataAddonConfig other = + (com.google.cloud.apihub.v1.AllDataAddonConfig) obj; + + if (getEnabled() != other.getEnabled()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ENABLED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getEnabled()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.AllDataAddonConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Configuration for addons which act on all data in the API hub.
                      +   * This is used to specify if the addon is enabled for all data in the API hub.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.AllDataAddonConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.AllDataAddonConfig) + com.google.cloud.apihub.v1.AllDataAddonConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_AllDataAddonConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_AllDataAddonConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.AllDataAddonConfig.class, + com.google.cloud.apihub.v1.AllDataAddonConfig.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.AllDataAddonConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + enabled_ = false; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_AllDataAddonConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AllDataAddonConfig getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.AllDataAddonConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AllDataAddonConfig build() { + com.google.cloud.apihub.v1.AllDataAddonConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AllDataAddonConfig buildPartial() { + com.google.cloud.apihub.v1.AllDataAddonConfig result = + new com.google.cloud.apihub.v1.AllDataAddonConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.AllDataAddonConfig result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.enabled_ = enabled_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.AllDataAddonConfig) { + return mergeFrom((com.google.cloud.apihub.v1.AllDataAddonConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.AllDataAddonConfig other) { + if (other == com.google.cloud.apihub.v1.AllDataAddonConfig.getDefaultInstance()) return this; + if (other.getEnabled() != false) { + setEnabled(other.getEnabled()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + enabled_ = input.readBool(); + bitField0_ |= 0x00000001; + break; + } // case 8 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private boolean enabled_; + + /** + * + * + *
                      +     * Required. If true, the addon is enabled for all data in the API hub.
                      +     * 
                      + * + * bool enabled = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The enabled. + */ + @java.lang.Override + public boolean getEnabled() { + return enabled_; + } + + /** + * + * + *
                      +     * Required. If true, the addon is enabled for all data in the API hub.
                      +     * 
                      + * + * bool enabled = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The enabled to set. + * @return This builder for chaining. + */ + public Builder setEnabled(boolean value) { + + enabled_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. If true, the addon is enabled for all data in the API hub.
                      +     * 
                      + * + * bool enabled = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearEnabled() { + bitField0_ = (bitField0_ & ~0x00000001); + enabled_ = false; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.AllDataAddonConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.AllDataAddonConfig) + private static final com.google.cloud.apihub.v1.AllDataAddonConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.AllDataAddonConfig(); + } + + public static com.google.cloud.apihub.v1.AllDataAddonConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AllDataAddonConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.AllDataAddonConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AllDataAddonConfigOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AllDataAddonConfigOrBuilder.java new file mode 100644 index 000000000000..e65c233e76e7 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/AllDataAddonConfigOrBuilder.java @@ -0,0 +1,41 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface AllDataAddonConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.AllDataAddonConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. If true, the addon is enabled for all data in the API hub.
                      +   * 
                      + * + * bool enabled = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The enabled. + */ + boolean getEnabled(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Api.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Api.java index 43b81a29f44d..f72c9134a24c 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Api.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Api.java @@ -1156,7 +1156,7 @@ public com.google.protobuf.ByteString getSelectedVersionBytes() { * *
                          * Optional. The api requirement doc associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1180,7 +1180,7 @@ public boolean hasApiRequirements() {
                          *
                          * 
                          * Optional. The api requirement doc associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1206,7 +1206,7 @@ public com.google.cloud.apihub.v1.AttributeValues getApiRequirements() {
                          *
                          * 
                          * Optional. The api requirement doc associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1234,7 +1234,9 @@ public com.google.cloud.apihub.v1.AttributeValuesOrBuilder getApiRequirementsOrB
                          *
                          *
                          * 
                      -   * Optional. Fingerprint of the API resource.
                      +   * Optional. Fingerprint of the API resource. This must be unique for each API
                      +   * resource. It can neither be unset nor be updated to an existing fingerprint
                      +   * of another API resource.
                          * 
                      * * string fingerprint = 17 [(.google.api.field_behavior) = OPTIONAL]; @@ -1258,7 +1260,9 @@ public java.lang.String getFingerprint() { * * *
                      -   * Optional. Fingerprint of the API resource.
                      +   * Optional. Fingerprint of the API resource. This must be unique for each API
                      +   * resource. It can neither be unset nor be updated to an existing fingerprint
                      +   * of another API resource.
                          * 
                      * * string fingerprint = 17 [(.google.api.field_behavior) = OPTIONAL]; @@ -1377,7 +1381,7 @@ public com.google.cloud.apihub.v1.SourceMetadataOrBuilder getSourceMetadataOrBui * *
                          * Optional. The api functional requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute.
                      +   * Cardinality is 1 for this attribute.
                          * This maps to the following system defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1401,7 +1405,7 @@ public boolean hasApiFunctionalRequirements() {
                          *
                          * 
                          * Optional. The api functional requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute.
                      +   * Cardinality is 1 for this attribute.
                          * This maps to the following system defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1427,7 +1431,7 @@ public com.google.cloud.apihub.v1.AttributeValues getApiFunctionalRequirements()
                          *
                          * 
                          * Optional. The api functional requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute.
                      +   * Cardinality is 1 for this attribute.
                          * This maps to the following system defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1455,7 +1459,7 @@ public com.google.cloud.apihub.v1.AttributeValues getApiFunctionalRequirements()
                          *
                          * 
                          * Optional. The api technical requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1479,7 +1483,7 @@ public boolean hasApiTechnicalRequirements() {
                          *
                          * 
                          * Optional. The api technical requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1505,7 +1509,7 @@ public com.google.cloud.apihub.v1.AttributeValues getApiTechnicalRequirements()
                          *
                          * 
                          * Optional. The api technical requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1525,6 +1529,80 @@ public com.google.cloud.apihub.v1.AttributeValues getApiTechnicalRequirements()
                               : apiTechnicalRequirements_;
                         }
                       
                      +  public static final int SERVICE_TYPE_FIELD_NUMBER = 21;
                      +  private com.google.cloud.apihub.v1.AttributeValues serviceType_;
                      +
                      +  /**
                      +   *
                      +   *
                      +   * 
                      +   * Optional. The type of the service.
                      +   * This maps to the following system defined attribute:
                      +   * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +   * attribute.
                      +   * The cardinality of this attribute is 1. All values should be from the list
                      +   * of allowed values defined for the attribute.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the serviceType field is set. + */ + @java.lang.Override + public boolean hasServiceType() { + return ((bitField0_ & 0x00001000) != 0); + } + + /** + * + * + *
                      +   * Optional. The type of the service.
                      +   * This maps to the following system defined attribute:
                      +   * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +   * attribute.
                      +   * The cardinality of this attribute is 1. All values should be from the list
                      +   * of allowed values defined for the attribute.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The serviceType. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AttributeValues getServiceType() { + return serviceType_ == null + ? com.google.cloud.apihub.v1.AttributeValues.getDefaultInstance() + : serviceType_; + } + + /** + * + * + *
                      +   * Optional. The type of the service.
                      +   * This maps to the following system defined attribute:
                      +   * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +   * attribute.
                      +   * The cardinality of this attribute is 1. All values should be from the list
                      +   * of allowed values defined for the attribute.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AttributeValuesOrBuilder getServiceTypeOrBuilder() { + return serviceType_ == null + ? com.google.cloud.apihub.v1.AttributeValues.getDefaultInstance() + : serviceType_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -1598,6 +1676,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000800) != 0)) { output.writeMessage(20, getApiTechnicalRequirements()); } + if (((bitField0_ & 0x00001000) != 0)) { + output.writeMessage(21, getServiceType()); + } getUnknownFields().writeTo(output); } @@ -1684,6 +1765,9 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 20, getApiTechnicalRequirements()); } + if (((bitField0_ & 0x00001000) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(21, getServiceType()); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1756,6 +1840,10 @@ public boolean equals(final java.lang.Object obj) { if (hasApiTechnicalRequirements()) { if (!getApiTechnicalRequirements().equals(other.getApiTechnicalRequirements())) return false; } + if (hasServiceType() != other.hasServiceType()) return false; + if (hasServiceType()) { + if (!getServiceType().equals(other.getServiceType())) return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1837,6 +1925,10 @@ public int hashCode() { hash = (37 * hash) + API_TECHNICAL_REQUIREMENTS_FIELD_NUMBER; hash = (53 * hash) + getApiTechnicalRequirements().hashCode(); } + if (hasServiceType()) { + hash = (37 * hash) + SERVICE_TYPE_FIELD_NUMBER; + hash = (53 * hash) + getServiceType().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -2011,6 +2103,7 @@ private void maybeForceBuilderInitialization() { internalGetSourceMetadataFieldBuilder(); internalGetApiFunctionalRequirementsFieldBuilder(); internalGetApiTechnicalRequirementsFieldBuilder(); + internalGetServiceTypeFieldBuilder(); } } @@ -2092,6 +2185,11 @@ public Builder clear() { apiTechnicalRequirementsBuilder_.dispose(); apiTechnicalRequirementsBuilder_ = null; } + serviceType_ = null; + if (serviceTypeBuilder_ != null) { + serviceTypeBuilder_.dispose(); + serviceTypeBuilder_ = null; + } return this; } @@ -2222,6 +2320,11 @@ private void buildPartial0(com.google.cloud.apihub.v1.Api result) { : apiTechnicalRequirementsBuilder_.build(); to_bitField0_ |= 0x00000800; } + if (((from_bitField0_ & 0x00100000) != 0)) { + result.serviceType_ = + serviceTypeBuilder_ == null ? serviceType_ : serviceTypeBuilder_.build(); + to_bitField0_ |= 0x00001000; + } result.bitField0_ |= to_bitField0_; } @@ -2337,6 +2440,9 @@ public Builder mergeFrom(com.google.cloud.apihub.v1.Api other) { if (other.hasApiTechnicalRequirements()) { mergeApiTechnicalRequirements(other.getApiTechnicalRequirements()); } + if (other.hasServiceType()) { + mergeServiceType(other.getServiceType()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -2511,6 +2617,13 @@ public Builder mergeFrom( bitField0_ |= 0x00080000; break; } // case 162 + case 170: + { + input.readMessage( + internalGetServiceTypeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00100000; + break; + } // case 170 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -5754,7 +5867,7 @@ public Builder setSelectedVersionBytes(com.google.protobuf.ByteString value) { * *
                            * Optional. The api requirement doc associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -5777,7 +5890,7 @@ public boolean hasApiRequirements() {
                            *
                            * 
                            * Optional. The api requirement doc associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -5806,7 +5919,7 @@ public com.google.cloud.apihub.v1.AttributeValues getApiRequirements() {
                            *
                            * 
                            * Optional. The api requirement doc associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -5837,7 +5950,7 @@ public Builder setApiRequirements(com.google.cloud.apihub.v1.AttributeValues val
                            *
                            * 
                            * Optional. The api requirement doc associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -5866,7 +5979,7 @@ public Builder setApiRequirements(
                            *
                            * 
                            * Optional. The api requirement doc associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -5903,7 +6016,7 @@ public Builder mergeApiRequirements(com.google.cloud.apihub.v1.AttributeValues v
                            *
                            * 
                            * Optional. The api requirement doc associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -5931,7 +6044,7 @@ public Builder clearApiRequirements() {
                            *
                            * 
                            * Optional. The api requirement doc associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -5954,7 +6067,7 @@ public com.google.cloud.apihub.v1.AttributeValues.Builder getApiRequirementsBuil
                            *
                            * 
                            * Optional. The api requirement doc associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -5981,7 +6094,7 @@ public com.google.cloud.apihub.v1.AttributeValuesOrBuilder getApiRequirementsOrB
                            *
                            * 
                            * Optional. The api requirement doc associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6016,7 +6129,9 @@ public com.google.cloud.apihub.v1.AttributeValuesOrBuilder getApiRequirementsOrB
                            *
                            *
                            * 
                      -     * Optional. Fingerprint of the API resource.
                      +     * Optional. Fingerprint of the API resource. This must be unique for each API
                      +     * resource. It can neither be unset nor be updated to an existing fingerprint
                      +     * of another API resource.
                            * 
                      * * string fingerprint = 17 [(.google.api.field_behavior) = OPTIONAL]; @@ -6039,7 +6154,9 @@ public java.lang.String getFingerprint() { * * *
                      -     * Optional. Fingerprint of the API resource.
                      +     * Optional. Fingerprint of the API resource. This must be unique for each API
                      +     * resource. It can neither be unset nor be updated to an existing fingerprint
                      +     * of another API resource.
                            * 
                      * * string fingerprint = 17 [(.google.api.field_behavior) = OPTIONAL]; @@ -6062,7 +6179,9 @@ public com.google.protobuf.ByteString getFingerprintBytes() { * * *
                      -     * Optional. Fingerprint of the API resource.
                      +     * Optional. Fingerprint of the API resource. This must be unique for each API
                      +     * resource. It can neither be unset nor be updated to an existing fingerprint
                      +     * of another API resource.
                            * 
                      * * string fingerprint = 17 [(.google.api.field_behavior) = OPTIONAL]; @@ -6084,7 +6203,9 @@ public Builder setFingerprint(java.lang.String value) { * * *
                      -     * Optional. Fingerprint of the API resource.
                      +     * Optional. Fingerprint of the API resource. This must be unique for each API
                      +     * resource. It can neither be unset nor be updated to an existing fingerprint
                      +     * of another API resource.
                            * 
                      * * string fingerprint = 17 [(.google.api.field_behavior) = OPTIONAL]; @@ -6102,7 +6223,9 @@ public Builder clearFingerprint() { * * *
                      -     * Optional. Fingerprint of the API resource.
                      +     * Optional. Fingerprint of the API resource. This must be unique for each API
                      +     * resource. It can neither be unset nor be updated to an existing fingerprint
                      +     * of another API resource.
                            * 
                      * * string fingerprint = 17 [(.google.api.field_behavior) = OPTIONAL]; @@ -6559,7 +6682,7 @@ public com.google.cloud.apihub.v1.SourceMetadata.Builder addSourceMetadataBuilde * *
                            * Optional. The api functional requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute.
                      +     * Cardinality is 1 for this attribute.
                            * This maps to the following system defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6582,7 +6705,7 @@ public boolean hasApiFunctionalRequirements() {
                            *
                            * 
                            * Optional. The api functional requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute.
                      +     * Cardinality is 1 for this attribute.
                            * This maps to the following system defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6611,7 +6734,7 @@ public com.google.cloud.apihub.v1.AttributeValues getApiFunctionalRequirements()
                            *
                            * 
                            * Optional. The api functional requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute.
                      +     * Cardinality is 1 for this attribute.
                            * This maps to the following system defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6642,7 +6765,7 @@ public Builder setApiFunctionalRequirements(com.google.cloud.apihub.v1.Attribute
                            *
                            * 
                            * Optional. The api functional requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute.
                      +     * Cardinality is 1 for this attribute.
                            * This maps to the following system defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6671,7 +6794,7 @@ public Builder setApiFunctionalRequirements(
                            *
                            * 
                            * Optional. The api functional requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute.
                      +     * Cardinality is 1 for this attribute.
                            * This maps to the following system defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6709,7 +6832,7 @@ public Builder mergeApiFunctionalRequirements(
                            *
                            * 
                            * Optional. The api functional requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute.
                      +     * Cardinality is 1 for this attribute.
                            * This maps to the following system defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6737,7 +6860,7 @@ public Builder clearApiFunctionalRequirements() {
                            *
                            * 
                            * Optional. The api functional requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute.
                      +     * Cardinality is 1 for this attribute.
                            * This maps to the following system defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6761,7 +6884,7 @@ public Builder clearApiFunctionalRequirements() {
                            *
                            * 
                            * Optional. The api functional requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute.
                      +     * Cardinality is 1 for this attribute.
                            * This maps to the following system defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6789,7 +6912,7 @@ public Builder clearApiFunctionalRequirements() {
                            *
                            * 
                            * Optional. The api functional requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute.
                      +     * Cardinality is 1 for this attribute.
                            * This maps to the following system defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6830,7 +6953,7 @@ public Builder clearApiFunctionalRequirements() {
                            *
                            * 
                            * Optional. The api technical requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6853,7 +6976,7 @@ public boolean hasApiTechnicalRequirements() {
                            *
                            * 
                            * Optional. The api technical requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6882,7 +7005,7 @@ public com.google.cloud.apihub.v1.AttributeValues getApiTechnicalRequirements()
                            *
                            * 
                            * Optional. The api technical requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6913,7 +7036,7 @@ public Builder setApiTechnicalRequirements(com.google.cloud.apihub.v1.AttributeV
                            *
                            * 
                            * Optional. The api technical requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6942,7 +7065,7 @@ public Builder setApiTechnicalRequirements(
                            *
                            * 
                            * Optional. The api technical requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -6979,7 +7102,7 @@ public Builder mergeApiTechnicalRequirements(com.google.cloud.apihub.v1.Attribut
                            *
                            * 
                            * Optional. The api technical requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -7007,7 +7130,7 @@ public Builder clearApiTechnicalRequirements() {
                            *
                            * 
                            * Optional. The api technical requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -7030,7 +7153,7 @@ public com.google.cloud.apihub.v1.AttributeValues.Builder getApiTechnicalRequire
                            *
                            * 
                            * Optional. The api technical requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -7058,7 +7181,7 @@ public com.google.cloud.apihub.v1.AttributeValues.Builder getApiTechnicalRequire
                            *
                            * 
                            * Optional. The api technical requirements associated with the API resource.
                      -     * Carinality is 1 for this attribute. This maps to the following system
                      +     * Cardinality is 1 for this attribute. This maps to the following system
                            * defined attribute:
                            * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                            * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -7087,6 +7210,264 @@ public com.google.cloud.apihub.v1.AttributeValues.Builder getApiTechnicalRequire
                             return apiTechnicalRequirementsBuilder_;
                           }
                       
                      +    private com.google.cloud.apihub.v1.AttributeValues serviceType_;
                      +    private com.google.protobuf.SingleFieldBuilder<
                      +            com.google.cloud.apihub.v1.AttributeValues,
                      +            com.google.cloud.apihub.v1.AttributeValues.Builder,
                      +            com.google.cloud.apihub.v1.AttributeValuesOrBuilder>
                      +        serviceTypeBuilder_;
                      +
                      +    /**
                      +     *
                      +     *
                      +     * 
                      +     * Optional. The type of the service.
                      +     * This maps to the following system defined attribute:
                      +     * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +     * attribute.
                      +     * The cardinality of this attribute is 1. All values should be from the list
                      +     * of allowed values defined for the attribute.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the serviceType field is set. + */ + public boolean hasServiceType() { + return ((bitField0_ & 0x00100000) != 0); + } + + /** + * + * + *
                      +     * Optional. The type of the service.
                      +     * This maps to the following system defined attribute:
                      +     * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +     * attribute.
                      +     * The cardinality of this attribute is 1. All values should be from the list
                      +     * of allowed values defined for the attribute.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The serviceType. + */ + public com.google.cloud.apihub.v1.AttributeValues getServiceType() { + if (serviceTypeBuilder_ == null) { + return serviceType_ == null + ? com.google.cloud.apihub.v1.AttributeValues.getDefaultInstance() + : serviceType_; + } else { + return serviceTypeBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The type of the service.
                      +     * This maps to the following system defined attribute:
                      +     * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +     * attribute.
                      +     * The cardinality of this attribute is 1. All values should be from the list
                      +     * of allowed values defined for the attribute.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setServiceType(com.google.cloud.apihub.v1.AttributeValues value) { + if (serviceTypeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + serviceType_ = value; + } else { + serviceTypeBuilder_.setMessage(value); + } + bitField0_ |= 0x00100000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The type of the service.
                      +     * This maps to the following system defined attribute:
                      +     * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +     * attribute.
                      +     * The cardinality of this attribute is 1. All values should be from the list
                      +     * of allowed values defined for the attribute.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setServiceType( + com.google.cloud.apihub.v1.AttributeValues.Builder builderForValue) { + if (serviceTypeBuilder_ == null) { + serviceType_ = builderForValue.build(); + } else { + serviceTypeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00100000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The type of the service.
                      +     * This maps to the following system defined attribute:
                      +     * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +     * attribute.
                      +     * The cardinality of this attribute is 1. All values should be from the list
                      +     * of allowed values defined for the attribute.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeServiceType(com.google.cloud.apihub.v1.AttributeValues value) { + if (serviceTypeBuilder_ == null) { + if (((bitField0_ & 0x00100000) != 0) + && serviceType_ != null + && serviceType_ != com.google.cloud.apihub.v1.AttributeValues.getDefaultInstance()) { + getServiceTypeBuilder().mergeFrom(value); + } else { + serviceType_ = value; + } + } else { + serviceTypeBuilder_.mergeFrom(value); + } + if (serviceType_ != null) { + bitField0_ |= 0x00100000; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The type of the service.
                      +     * This maps to the following system defined attribute:
                      +     * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +     * attribute.
                      +     * The cardinality of this attribute is 1. All values should be from the list
                      +     * of allowed values defined for the attribute.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearServiceType() { + bitField0_ = (bitField0_ & ~0x00100000); + serviceType_ = null; + if (serviceTypeBuilder_ != null) { + serviceTypeBuilder_.dispose(); + serviceTypeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The type of the service.
                      +     * This maps to the following system defined attribute:
                      +     * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +     * attribute.
                      +     * The cardinality of this attribute is 1. All values should be from the list
                      +     * of allowed values defined for the attribute.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.AttributeValues.Builder getServiceTypeBuilder() { + bitField0_ |= 0x00100000; + onChanged(); + return internalGetServiceTypeFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The type of the service.
                      +     * This maps to the following system defined attribute:
                      +     * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +     * attribute.
                      +     * The cardinality of this attribute is 1. All values should be from the list
                      +     * of allowed values defined for the attribute.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.AttributeValuesOrBuilder getServiceTypeOrBuilder() { + if (serviceTypeBuilder_ != null) { + return serviceTypeBuilder_.getMessageOrBuilder(); + } else { + return serviceType_ == null + ? com.google.cloud.apihub.v1.AttributeValues.getDefaultInstance() + : serviceType_; + } + } + + /** + * + * + *
                      +     * Optional. The type of the service.
                      +     * This maps to the following system defined attribute:
                      +     * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +     * attribute.
                      +     * The cardinality of this attribute is 1. All values should be from the list
                      +     * of allowed values defined for the attribute.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AttributeValues, + com.google.cloud.apihub.v1.AttributeValues.Builder, + com.google.cloud.apihub.v1.AttributeValuesOrBuilder> + internalGetServiceTypeFieldBuilder() { + if (serviceTypeBuilder_ == null) { + serviceTypeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AttributeValues, + com.google.cloud.apihub.v1.AttributeValues.Builder, + com.google.cloud.apihub.v1.AttributeValuesOrBuilder>( + getServiceType(), getParentForChildren(), isClean()); + serviceType_ = null; + } + return serviceTypeBuilder_; + } + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.Api) } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiHubInstance.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiHubInstance.java index a260716d96e4..141eb8241861 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiHubInstance.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiHubInstance.java @@ -461,6 +461,54 @@ public interface ConfigOrBuilder * @return The encryptionType. */ com.google.cloud.apihub.v1.ApiHubInstance.Config.EncryptionType getEncryptionType(); + + /** + * + * + *
                      +     * Optional. The configuration for syncing MCP data in the API Hub instance
                      +     * to the Agent Registry.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the agentRegistrySyncConfig field is set. + */ + boolean hasAgentRegistrySyncConfig(); + + /** + * + * + *
                      +     * Optional. The configuration for syncing MCP data in the API Hub instance
                      +     * to the Agent Registry.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The agentRegistrySyncConfig. + */ + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + getAgentRegistrySyncConfig(); + + /** + * + * + *
                      +     * Optional. The configuration for syncing MCP data in the API Hub instance
                      +     * to the Agent Registry.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfigOrBuilder + getAgentRegistrySyncConfigOrBuilder(); } /** @@ -687,6 +735,541 @@ private EncryptionType(int value) { // @@protoc_insertion_point(enum_scope:google.cloud.apihub.v1.ApiHubInstance.Config.EncryptionType) } + public interface AgentRegistrySyncConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +       * Optional. If true, the MCP data sync to the Agent Registry will be
                      +       * disabled. The default value is false.
                      +       * 
                      + * + * bool disabled = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The disabled. + */ + boolean getDisabled(); + } + + /** + * + * + *
                      +     * The configuration for Agent Registry sync.
                      +     * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig} + */ + public static final class AgentRegistrySyncConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig) + AgentRegistrySyncConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AgentRegistrySyncConfig"); + } + + // Use AgentRegistrySyncConfig.newBuilder() to construct. + private AgentRegistrySyncConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AgentRegistrySyncConfig() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_AgentRegistrySyncConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_AgentRegistrySyncConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig.class, + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig.Builder + .class); + } + + public static final int DISABLED_FIELD_NUMBER = 1; + private boolean disabled_ = false; + + /** + * + * + *
                      +       * Optional. If true, the MCP data sync to the Agent Registry will be
                      +       * disabled. The default value is false.
                      +       * 
                      + * + * bool disabled = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The disabled. + */ + @java.lang.Override + public boolean getDisabled() { + return disabled_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (disabled_ != false) { + output.writeBool(1, disabled_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (disabled_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, disabled_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig other = + (com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig) obj; + + if (getDisabled() != other.getDisabled()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + DISABLED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getDisabled()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +       * The configuration for Agent Registry sync.
                      +       * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig) + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_AgentRegistrySyncConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_AgentRegistrySyncConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig.class, + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig.Builder + .class); + } + + // Construct using + // com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + disabled_ = false; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_AgentRegistrySyncConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig build() { + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + buildPartial() { + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig result = + new com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.disabled_ = disabled_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig) { + return mergeFrom( + (com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig other) { + if (other + == com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + .getDefaultInstance()) return this; + if (other.getDisabled() != false) { + setDisabled(other.getDisabled()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + disabled_ = input.readBool(); + bitField0_ |= 0x00000001; + break; + } // case 8 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private boolean disabled_; + + /** + * + * + *
                      +         * Optional. If true, the MCP data sync to the Agent Registry will be
                      +         * disabled. The default value is false.
                      +         * 
                      + * + * bool disabled = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The disabled. + */ + @java.lang.Override + public boolean getDisabled() { + return disabled_; + } + + /** + * + * + *
                      +         * Optional. If true, the MCP data sync to the Agent Registry will be
                      +         * disabled. The default value is false.
                      +         * 
                      + * + * bool disabled = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The disabled to set. + * @return This builder for chaining. + */ + public Builder setDisabled(boolean value) { + + disabled_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +         * Optional. If true, the MCP data sync to the Agent Registry will be
                      +         * disabled. The default value is false.
                      +         * 
                      + * + * bool disabled = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDisabled() { + bitField0_ = (bitField0_ & ~0x00000001); + disabled_ = false; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig) + private static final com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig(); + } + + public static com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AgentRegistrySyncConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; public static final int CMEK_KEY_NAME_FIELD_NUMBER = 1; @SuppressWarnings("serial") @@ -871,6 +1454,73 @@ public com.google.cloud.apihub.v1.ApiHubInstance.Config.EncryptionType getEncryp : result; } + public static final int AGENT_REGISTRY_SYNC_CONFIG_FIELD_NUMBER = 5; + private com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + agentRegistrySyncConfig_; + + /** + * + * + *
                      +     * Optional. The configuration for syncing MCP data in the API Hub instance
                      +     * to the Agent Registry.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the agentRegistrySyncConfig field is set. + */ + @java.lang.Override + public boolean hasAgentRegistrySyncConfig() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * Optional. The configuration for syncing MCP data in the API Hub instance
                      +     * to the Agent Registry.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The agentRegistrySyncConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + getAgentRegistrySyncConfig() { + return agentRegistrySyncConfig_ == null + ? com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + .getDefaultInstance() + : agentRegistrySyncConfig_; + } + + /** + * + * + *
                      +     * Optional. The configuration for syncing MCP data in the API Hub instance
                      +     * to the Agent Registry.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfigOrBuilder + getAgentRegistrySyncConfigOrBuilder() { + return agentRegistrySyncConfig_ == null + ? com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + .getDefaultInstance() + : agentRegistrySyncConfig_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -900,6 +1550,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io .getNumber()) { output.writeEnum(4, encryptionType_); } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getAgentRegistrySyncConfig()); + } getUnknownFields().writeTo(output); } @@ -924,6 +1577,11 @@ public int getSerializedSize() { .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, encryptionType_); } + if (((bitField0_ & 0x00000001) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, getAgentRegistrySyncConfig()); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -944,6 +1602,10 @@ public boolean equals(final java.lang.Object obj) { if (getDisableSearch() != other.getDisableSearch()) return false; if (!getVertexLocation().equals(other.getVertexLocation())) return false; if (encryptionType_ != other.encryptionType_) return false; + if (hasAgentRegistrySyncConfig() != other.hasAgentRegistrySyncConfig()) return false; + if (hasAgentRegistrySyncConfig()) { + if (!getAgentRegistrySyncConfig().equals(other.getAgentRegistrySyncConfig())) return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -963,6 +1625,10 @@ public int hashCode() { hash = (53 * hash) + getVertexLocation().hashCode(); hash = (37 * hash) + ENCRYPTION_TYPE_FIELD_NUMBER; hash = (53 * hash) + encryptionType_; + if (hasAgentRegistrySyncConfig()) { + hash = (37 * hash) + AGENT_REGISTRY_SYNC_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getAgentRegistrySyncConfig().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1093,10 +1759,19 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloud.apihub.v1.ApiHubInstance.Config.newBuilder() - private Builder() {} + private Builder() { + maybeForceBuilderInitialization(); + } private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetAgentRegistrySyncConfigFieldBuilder(); + } } @java.lang.Override @@ -1107,6 +1782,11 @@ public Builder clear() { disableSearch_ = false; vertexLocation_ = ""; encryptionType_ = 0; + agentRegistrySyncConfig_ = null; + if (agentRegistrySyncConfigBuilder_ != null) { + agentRegistrySyncConfigBuilder_.dispose(); + agentRegistrySyncConfigBuilder_ = null; + } return this; } @@ -1155,6 +1835,15 @@ private void buildPartial0(com.google.cloud.apihub.v1.ApiHubInstance.Config resu if (((from_bitField0_ & 0x00000008) != 0)) { result.encryptionType_ = encryptionType_; } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000010) != 0)) { + result.agentRegistrySyncConfig_ = + agentRegistrySyncConfigBuilder_ == null + ? agentRegistrySyncConfig_ + : agentRegistrySyncConfigBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; } @java.lang.Override @@ -1186,6 +1875,9 @@ public Builder mergeFrom(com.google.cloud.apihub.v1.ApiHubInstance.Config other) if (other.encryptionType_ != 0) { setEncryptionTypeValue(other.getEncryptionTypeValue()); } + if (other.hasAgentRegistrySyncConfig()) { + mergeAgentRegistrySyncConfig(other.getAgentRegistrySyncConfig()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1236,6 +1928,14 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 32 + case 42: + { + input.readMessage( + internalGetAgentRegistrySyncConfigFieldBuilder().getBuilder(), + extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -1680,6 +2380,240 @@ public Builder clearEncryptionType() { return this; } + private com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + agentRegistrySyncConfig_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig, + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig.Builder, + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfigOrBuilder> + agentRegistrySyncConfigBuilder_; + + /** + * + * + *
                      +       * Optional. The configuration for syncing MCP data in the API Hub instance
                      +       * to the Agent Registry.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the agentRegistrySyncConfig field is set. + */ + public boolean hasAgentRegistrySyncConfig() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
                      +       * Optional. The configuration for syncing MCP data in the API Hub instance
                      +       * to the Agent Registry.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The agentRegistrySyncConfig. + */ + public com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + getAgentRegistrySyncConfig() { + if (agentRegistrySyncConfigBuilder_ == null) { + return agentRegistrySyncConfig_ == null + ? com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + .getDefaultInstance() + : agentRegistrySyncConfig_; + } else { + return agentRegistrySyncConfigBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +       * Optional. The configuration for syncing MCP data in the API Hub instance
                      +       * to the Agent Registry.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setAgentRegistrySyncConfig( + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig value) { + if (agentRegistrySyncConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + agentRegistrySyncConfig_ = value; + } else { + agentRegistrySyncConfigBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Optional. The configuration for syncing MCP data in the API Hub instance
                      +       * to the Agent Registry.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setAgentRegistrySyncConfig( + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig.Builder + builderForValue) { + if (agentRegistrySyncConfigBuilder_ == null) { + agentRegistrySyncConfig_ = builderForValue.build(); + } else { + agentRegistrySyncConfigBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Optional. The configuration for syncing MCP data in the API Hub instance
                      +       * to the Agent Registry.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeAgentRegistrySyncConfig( + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig value) { + if (agentRegistrySyncConfigBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && agentRegistrySyncConfig_ != null + && agentRegistrySyncConfig_ + != com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + .getDefaultInstance()) { + getAgentRegistrySyncConfigBuilder().mergeFrom(value); + } else { + agentRegistrySyncConfig_ = value; + } + } else { + agentRegistrySyncConfigBuilder_.mergeFrom(value); + } + if (agentRegistrySyncConfig_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +       * Optional. The configuration for syncing MCP data in the API Hub instance
                      +       * to the Agent Registry.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearAgentRegistrySyncConfig() { + bitField0_ = (bitField0_ & ~0x00000010); + agentRegistrySyncConfig_ = null; + if (agentRegistrySyncConfigBuilder_ != null) { + agentRegistrySyncConfigBuilder_.dispose(); + agentRegistrySyncConfigBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Optional. The configuration for syncing MCP data in the API Hub instance
                      +       * to the Agent Registry.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig.Builder + getAgentRegistrySyncConfigBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetAgentRegistrySyncConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +       * Optional. The configuration for syncing MCP data in the API Hub instance
                      +       * to the Agent Registry.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfigOrBuilder + getAgentRegistrySyncConfigOrBuilder() { + if (agentRegistrySyncConfigBuilder_ != null) { + return agentRegistrySyncConfigBuilder_.getMessageOrBuilder(); + } else { + return agentRegistrySyncConfig_ == null + ? com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig + .getDefaultInstance() + : agentRegistrySyncConfig_; + } + } + + /** + * + * + *
                      +       * Optional. The configuration for syncing MCP data in the API Hub instance
                      +       * to the Agent Registry.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig agent_registry_sync_config = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig, + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig.Builder, + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfigOrBuilder> + internalGetAgentRegistrySyncConfigFieldBuilder() { + if (agentRegistrySyncConfigBuilder_ == null) { + agentRegistrySyncConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig, + com.google.cloud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfig.Builder, + com.google.cloud.apihub.v1.ApiHubInstance.Config + .AgentRegistrySyncConfigOrBuilder>( + getAgentRegistrySyncConfig(), getParentForChildren(), isClean()); + agentRegistrySyncConfig_ = null; + } + return agentRegistrySyncConfigBuilder_; + } + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ApiHubInstance.Config) } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiHubServiceProto.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiHubServiceProto.java index 168df597a180..862bbda2fb45 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiHubServiceProto.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiHubServiceProto.java @@ -116,6 +116,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_apihub_v1_GetSpecContentsRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_apihub_v1_GetSpecContentsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentResponse_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_apihub_v1_CreateApiOperationRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -256,6 +264,62 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_apihub_v1_ListExternalApisResponse_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_apihub_v1_ListExternalApisResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_RetrieveApiViewsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_RetrieveApiViewsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ApiView_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ApiView_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_FlattenedApiVersionDeploymentView_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_FlattenedApiVersionDeploymentView_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_FlattenedApiVersionOperationDeploymentView_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_FlattenedApiVersionOperationDeploymentView_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_RetrieveApiViewsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_RetrieveApiViewsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_McpServerConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_McpServerConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_McpServerConfig_McpToolConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_McpServerConfig_McpToolConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_MetaData_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_MetaData_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_OperationConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_OperationConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_OperationConfig_HttpOperationConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_OperationConfig_HttpOperationConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_McpServerDetails_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_McpServerDetails_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -270,8 +334,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "proto\022\026google.cloud.apihub.v1\032\034google/ap" + "i/annotations.proto\032\027google/api/client.p" + "roto\032\037google/api/field_behavior.proto\032\031g" - + "oogle/api/resource.proto\032*google/cloud/a" - + "pihub/v1/common_fields.proto\032\033google/protobuf/empty.proto\032" + + "oogle/api/resource.proto\032*google/cloud/apihub/v1/common_fields.proto\032#google/lon" + + "grunning/operations.proto\032\033google/protobuf/empty.proto\032" + " google/protobuf/field_mask.proto\"\214\001\n" + "\020CreateApiRequest\0222\n" + "\006parent\030\001 \001(" @@ -351,7 +415,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017next_page_token\030\002 \001(\t\"K\n" + "\026GetSpecContentsRequest\0221\n" + "\004name\030\001 \001(\tB#\342A\001\002\372A\034\n" - + "\032apihub.googleapis.com/Spec\"\273\001\n" + + "\032apihub.googleapis.com/Spec\"\240\001\n" + + "!FetchAdditionalSpecContentRequest\0221\n" + + "\004name\030\001 \001(\tB#\342A\001\002\372A\034\n" + + "\032apihub.googleapis.com/Spec\022H\n" + + "\021spec_content_type\030\002 \001(\0162\'.g" + + "oogle.cloud.apihub.v1.SpecContentTypeB\004\342A\001\001\"t\n" + + "\"FetchAdditionalSpecContentResponse\022N\n" + + "\027additional_spec_content\030\001 \001(\0132-.goo" + + "gle.cloud.apihub.v1.AdditionalSpecContent\"\273\001\n" + "\031CreateApiOperationRequest\022;\n" + "\006parent\030\001 \001(" + "\tB+\342A\001\002\372A$\022\"apihub.googleapis.com/ApiOperation\022\036\n" @@ -408,8 +480,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013deployments\030\001 \003(\0132\".google.cloud.apihub.v1.Deployment\022\027\n" + "\017next_page_token\030\002 \001(\t\"\252\001\n" + "\026CreateAttributeRequest\0228\n" - + "\006parent\030\001 \001(\tB(\342" - + "A\001\002\372A!\022\037apihub.googleapis.com/Attribute\022\032\n" + + "\006parent\030\001 \001(" + + "\tB(\342A\001\002\372A!\022\037apihub.googleapis.com/Attribute\022\032\n" + "\014attribute_id\030\002 \001(\tB\004\342A\001\001\022:\n" + "\tattribute\030\003" + " \001(\0132!.google.cloud.apihub.v1.AttributeB\004\342A\001\002\"M\n" @@ -463,8 +535,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004name\030\001 \001(\tB)\342A\001\002\372A\"\n" + " apihub.googleapis.com/Dependency\"\216\001\n" + "\027UpdateDependencyRequest\022<\n\n" - + "dependency\030\001 \001(\0132" - + "\".google.cloud.apihub.v1.DependencyB\004\342A\001\002\0225\n" + + "dependency\030\001 \001(\0132\"." + + "google.cloud.apihub.v1.DependencyB\004\342A\001\002\0225\n" + "\013update_mask\030\002" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\002\"R\n" + "\027DeleteDependencyRequest\0227\n" @@ -497,186 +569,298 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004name\030\001 \001(\tB*\342A\001\002\372A#\n" + "!apihub.googleapis.com/ExternalApi\"\210\001\n" + "\027ListExternalApisRequest\022:\n" - + "\006parent\030\001 \001(\tB*" - + "\342A\001\002\372A#\022!apihub.googleapis.com/ExternalApi\022\027\n" + + "\006parent\030\001 \001(\tB*\342A" + + "\001\002\372A#\022!apihub.googleapis.com/ExternalApi\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"o\n" + "\030ListExternalApisResponse\022:\n\r" + "external_apis\030\001 \003(\0132#.google.cloud.apihub.v1.ExternalApi\022\027\n" - + "\017next_page_token\030\002 \001(\t2\3226\n" + + "\017next_page_token\030\002 \001(\t\"\327\001\n" + + "\027RetrieveApiViewsRequest\022:\n" + + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + + "!locations.googleapis.com/Location\022\024\n" + + "\006filter\030\002 \001(\tB\004\342A\001\001\022\027\n" + + "\tpage_size\030\003 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\004 \001(\tB\004\342A\001\001\0227\n" + + "\004view\030\005" + + " \001(\0162#.google.cloud.apihub.v1.ApiViewTypeB\004\342A\001\002\"\304\001\n" + + "\007ApiView\022T\n" + + "\017mcp_server_view\030\001 \001(\01329.google.cloud.apihu" + + "b.v1.FlattenedApiVersionDeploymentViewH\000\022[\n\r" + + "mcp_tool_view\030\002 \001(\0132B.google.cloud.a" + + "pihub.v1.FlattenedApiVersionOperationDeploymentViewH\000B\006\n" + + "\004view\"\311\001\n" + + "!FlattenedApiVersionDeploymentView\022.\n" + + "\003api\030\001 \001(\0132\033.google.cloud.apihub.v1.ApiB\004\342A\001\001\0226\n" + + "\007version\030\002" + + " \001(\0132\037.google.cloud.apihub.v1.VersionB\004\342A\001\001\022<\n\n" + + "deployment\030\003" + + " \001(\0132\".google.cloud.apihub.v1.DeploymentB\004\342A\001\001\"\225\002\n" + + "*FlattenedApiVersionOperationDeploymentView\022.\n" + + "\003api\030\001 \001(\0132\033.google.cloud.apihub.v1.ApiB\004\342A\001\001\0226\n" + + "\007version\030\002" + + " \001(\0132\037.google.cloud.apihub.v1.VersionB\004\342A\001\001\022A\n\r" + + "api_operation\030\003 \001(\0132" + + "$.google.cloud.apihub.v1.ApiOperationB\004\342A\001\001\022<\n\n" + + "deployment\030\004" + + " \001(\0132\".google.cloud.apihub.v1.DeploymentB\004\342A\001\001\"m\n" + + "\030RetrieveApiViewsResponse\0228\n" + + "\tapi_views\030\001" + + " \003(\0132\037.google.cloud.apihub.v1.ApiViewB\004\342A\001\003\022\027\n" + + "\017next_page_token\030\002 \001(\t\"\264\001\n" + + "\037ConfigureAndDeployServerRequest\022D\n" + + "\021mcp_server_config\030\002 \001(\0132" + + "\'.google.cloud.apihub.v1.McpServerConfigH\000\022:\n" + + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + + "!locations.googleapis.com/LocationB\017\n\r" + + "server_config\"\304\002\n" + + "\017McpServerConfig\022U\n" + + "\027apigee_x_target_details\030\002" + + " \001(\0132,.google.cloud.apihub.v1.ApigeeXTargetDetailsB\004\342A\001\001H\000\022J\n" + + "\005tools\030\001 \003(" + + "\01325.google.cloud.apihub.v1.McpServerConfig.McpToolConfigB\004\342A\001\002\032\203\001\n\r" + + "McpToolConfig\022\025\n" + + "\007tool_id\030\001 \001(\tB\004\342A\001\002\022\031\n" + + "\013description\030\002 \001(\tB\004\342A\001\002\022@\n" + + "\toperation\030\003" + + " \001(\0132\'.google.cloud.apihub.v1.OperationConfigB\004\342A\001\002B\010\n" + + "\006target\"\227\002\n" + + "\024ApigeeXTargetDetails\022\031\n" + + "\013environment\030\002 \001(\tB\004\342A\001\002\022\023\n" + + "\005proxy\030\003 \001(\tB\004\342A\001\002\022\034\n" + + "\016target_project\030\004 \001(\tB\004\342A\001\002\022M\n" + + "\010metadata\030\005" + + " \001(\01325.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaDataB\004\342A\001\001\022\037\n" + + "\021deployed_revision\030\006 \001(\tB\004\342A\001\003\032A\n" + + "\010MetaData\022\032\n" + + "\014display_name\030\001 \001(\tB\004\342A\001\001\022\031\n" + + "\013description\030\002 \001(\tB\004\342A\001\001\"\327\002\n" + + "\017OperationConfig\022<\n" + + "\toperation\030\001 \001(\tB\'\372A$\n" + + "\"apihub.googleapis.com/ApiOperationH\000\022U\n" + + "\016http_operation\030\002 \001(\0132;.goo" + + "gle.cloud.apihub.v1.OperationConfig.HttpOperationConfigH\000\032\240\001\n" + + "\023HttpOperationConfig\0221\n" + + "\004spec\030\001 \001(\tB#\342A\001\002\372A\034\n" + + "\032apihub.googleapis.com/Spec\022\022\n" + + "\004path\030\002 \001(\tB\004\342A\001\002\022B\n" + + "\006method\030\003" + + " \001(\0162,.google.cloud.apihub.v1.HttpOperation.MethodB\004\342A\001\002B\014\n\n" + + "identifier\"|\n" + + " ConfigureAndDeployServerResponse\022F\n" + + "\022mcp_server_details\030\001" + + " \001(\0132(.google.cloud.apihub.v1.McpServerDetailsH\000B\020\n" + + "\016server_details\"g\n" + + "\020McpServerDetails\022H\n" + + "\020apigee_x_details\030\001" + + " \001(\0132,.google.cloud.apihub.v1.ApigeeXTargetDetailsH\000B\t\n" + + "\007details*J\n" + + "\013ApiViewType\022\035\n" + + "\031API_VIEW_TYPE_UNSPECIFIED\020\000\022\016\n\n" + + "MCP_SERVER\020\001\022\014\n" + + "\010MCP_TOOL\020\0022\242=\n" + "\006ApiHub\022\235\001\n" - + "\tCreateApi\022(.google.cloud.apihub.v1.CreateApiRequest\032\033.goog" - + "le.cloud.apihub.v1.Api\"I\332A\021parent,api,ap" - + "i_id\202\323\344\223\002/\"(/v1/{parent=projects/*/locations/*}/apis:\003api\022\205\001\n" - + "\006GetApi\022%.google.cloud.apihub.v1.GetApiRequest\032\033.google.clo" - + "ud.apihub.v1.Api\"7\332A\004name\202\323\344\223\002*\022(/v1/{name=projects/*/locations/*/apis/*}\022\230\001\n" - + "\010ListApis\022\'.google.cloud.apihub.v1.ListApis" - + "Request\032(.google.cloud.apihub.v1.ListApi" - + "sResponse\"9\332A\006parent\202\323\344\223\002*\022(/v1/{parent=projects/*/locations/*}/apis\022\237\001\n" - + "\tUpdateApi\022(.google.cloud.apihub.v1.UpdateApiReq" - + "uest\032\033.google.cloud.apihub.v1.Api\"K\332A\017ap" - + "i,update_mask\202\323\344\223\00232,/v1/{api.name=projects/*/locations/*/apis/*}:\003api\022\206\001\n" - + "\tDeleteApi\022(.google.cloud.apihub.v1.DeleteApiR" - + "equest\032\026.google.protobuf.Empty\"7\332A\004name\202" - + "\323\344\223\002**(/v1/{name=projects/*/locations/*/apis/*}\022\300\001\n\r" - + "CreateVersion\022,.google.cloud.apihub.v1.CreateVersionRequest\032\037.google" - + ".cloud.apihub.v1.Version\"`\332A\031parent,vers" - + "ion,version_id\202\323\344\223\002>\"3/v1/{parent=projec" - + "ts/*/locations/*/apis/*}/versions:\007version\022\234\001\n\n" - + "GetVersion\022).google.cloud.apihub.v1.GetVersionRequest\032\037.google.cloud.apih" - + "ub.v1.Version\"B\332A\004name\202\323\344\223\0025\0223/v1/{name=" - + "projects/*/locations/*/apis/*/versions/*}\022\257\001\n" - + "\014ListVersions\022+.google.cloud.apihub.v1.ListVersionsRequest\032,.google.cloud.a" - + "pihub.v1.ListVersionsResponse\"D\332A\006parent" - + "\202\323\344\223\0025\0223/v1/{parent=projects/*/locations/*/apis/*}/versions\022\302\001\n\r" - + "UpdateVersion\022,.google.cloud.apihub.v1.UpdateVersionRequ" - + "est\032\037.google.cloud.apihub.v1.Version\"b\332A" - + "\023version,update_mask\202\323\344\223\002F2;/v1/{version" - + ".name=projects/*/locations/*/apis/*/versions/*}:\007version\022\231\001\n\r" - + "DeleteVersion\022,.google.cloud.apihub.v1.DeleteVersionRequest" - + "\032\026.google.protobuf.Empty\"B\332A\004name\202\323\344\223\0025*" - + "3/v1/{name=projects/*/locations/*/apis/*/versions/*}\022\266\001\n\n" - + "CreateSpec\022).google.cloud.apihub.v1.CreateSpecRequest\032\034.google." - + "cloud.apihub.v1.Spec\"_\332A\023parent,spec,spe" - + "c_id\202\323\344\223\002C\";/v1/{parent=projects/*/locat" - + "ions/*/apis/*/versions/*}/specs:\004spec\022\233\001\n" - + "\007GetSpec\022&.google.cloud.apihub.v1.GetSp" - + "ecRequest\032\034.google.cloud.apihub.v1.Spec\"" - + "J\332A\004name\202\323\344\223\002=\022;/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}\022\274\001\n" - + "\017GetSpecContents\022..google.cloud.apihub.v1" - + ".GetSpecContentsRequest\032$.google.cloud.a" - + "pihub.v1.SpecContents\"S\332A\004name\202\323\344\223\002F\022D/v" - + "1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:contents\022\256\001\n" - + "\tListSpecs\022(.google.cloud.apihub.v1.ListSpecsReque" - + "st\032).google.cloud.apihub.v1.ListSpecsRes" - + "ponse\"L\332A\006parent\202\323\344\223\002=\022;/v1/{parent=proj" - + "ects/*/locations/*/apis/*/versions/*}/specs\022\270\001\n\n" - + "UpdateSpec\022).google.cloud.apihub.v1.UpdateSpecRequest\032\034.google.cloud.api" - + "hub.v1.Spec\"a\332A\020spec,update_mask\202\323\344\223\002H2@" - + "/v1/{spec.name=projects/*/locations/*/apis/*/versions/*/specs/*}:\004spec\022\233\001\n\n" - + "DeleteSpec\022).google.cloud.apihub.v1.DeleteSpe" - + "cRequest\032\026.google.protobuf.Empty\"J\332A\004nam" - + "e\202\323\344\223\002=*;/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}\022\356\001\n" - + "\022CreateApiOperation\0221.google.cloud.apihub.v1.Cre" - + "ateApiOperationRequest\032$.google.cloud.ap" - + "ihub.v1.ApiOperation\"\177\332A%parent,api_oper" - + "ation,api_operation_id\202\323\344\223\002Q\"@/v1/{paren" - + "t=projects/*/locations/*/apis/*/versions/*}/operations:\r" + + "\tCreateApi\022(.google.cloud.apihub.v1.CreateAp" + + "iRequest\032\033.google.cloud.apihub.v1.Api\"I\332" + + "A\021parent,api,api_id\202\323\344\223\002/\"(/v1/{parent=projects/*/locations/*}/apis:\003api\022\205\001\n" + + "\006GetApi\022%.google.cloud.apihub.v1.GetApiReque" + + "st\032\033.google.cloud.apihub.v1.Api\"7\332A\004name" + + "\202\323\344\223\002*\022(/v1/{name=projects/*/locations/*/apis/*}\022\230\001\n" + + "\010ListApis\022\'.google.cloud.apihub.v1.ListApisRequest\032(.google.cloud.ap" + + "ihub.v1.ListApisResponse\"9\332A\006parent\202\323\344\223\002" + + "*\022(/v1/{parent=projects/*/locations/*}/apis\022\237\001\n" + + "\tUpdateApi\022(.google.cloud.apihub.v1.UpdateApiRequest\032\033.google.cloud.apihu" + + "b.v1.Api\"K\332A\017api,update_mask\202\323\344\223\00232,/v1/" + + "{api.name=projects/*/locations/*/apis/*}:\003api\022\206\001\n" + + "\tDeleteApi\022(.google.cloud.apihub.v1.DeleteApiRequest\032\026.google.protobuf." + + "Empty\"7\332A\004name\202\323\344\223\002**(/v1/{name=projects/*/locations/*/apis/*}\022\300\001\n\r" + + "CreateVersion\022,.google.cloud.apihub.v1.CreateVersionR" + + "equest\032\037.google.cloud.apihub.v1.Version\"" + + "`\332A\031parent,version,version_id\202\323\344\223\002>\"3/v1" + + "/{parent=projects/*/locations/*/apis/*}/versions:\007version\022\234\001\n\n" + + "GetVersion\022).google.cloud.apihub.v1.GetVersionRequest\032\037.go" + + "ogle.cloud.apihub.v1.Version\"B\332A\004name\202\323\344" + + "\223\0025\0223/v1/{name=projects/*/locations/*/apis/*/versions/*}\022\257\001\n" + + "\014ListVersions\022+.google.cloud.apihub.v1.ListVersionsRequest\032," + + ".google.cloud.apihub.v1.ListVersionsResp" + + "onse\"D\332A\006parent\202\323\344\223\0025\0223/v1/{parent=projects/*/locations/*/apis/*}/versions\022\302\001\n\r" + + "UpdateVersion\022,.google.cloud.apihub.v1.Up" + + "dateVersionRequest\032\037.google.cloud.apihub" + + ".v1.Version\"b\332A\023version,update_mask\202\323\344\223\002" + + "F2;/v1/{version.name=projects/*/locations/*/apis/*/versions/*}:\007version\022\231\001\n\r" + + "DeleteVersion\022,.google.cloud.apihub.v1.Delet" + + "eVersionRequest\032\026.google.protobuf.Empty\"" + + "B\332A\004name\202\323\344\223\0025*3/v1/{name=projects/*/locations/*/apis/*/versions/*}\022\266\001\n\n" + + "CreateSpec\022).google.cloud.apihub.v1.CreateSpecRe" + + "quest\032\034.google.cloud.apihub.v1.Spec\"_\332A\023" + + "parent,spec,spec_id\202\323\344\223\002C\";/v1/{parent=p" + + "rojects/*/locations/*/apis/*/versions/*}/specs:\004spec\022\233\001\n" + + "\007GetSpec\022&.google.cloud.apihub.v1.GetSpecRequest\032\034.google.cloud." + + "apihub.v1.Spec\"J\332A\004name\202\323\344\223\002=\022;/v1/{name" + + "=projects/*/locations/*/apis/*/versions/*/specs/*}\022\274\001\n" + + "\017GetSpecContents\022..google.cloud.apihub.v1.GetSpecContentsRequest\032$" + + ".google.cloud.apihub.v1.SpecContents\"S\332A" + + "\004name\202\323\344\223\002F\022D/v1/{name=projects/*/locati" + + "ons/*/apis/*/versions/*/specs/*}:contents\022\214\002\n" + + "\032FetchAdditionalSpecContent\0229.google.cloud.apihub.v1.FetchAdditionalSpecCon" + + "tentRequest\032:.google.cloud.apihub.v1.Fet" + + "chAdditionalSpecContentResponse\"w\332A\026name" + + ",spec_content_type\202\323\344\223\002X\022V/v1/{name=proj" + + "ects/*/locations/*/apis/*/versions/*/specs/*}:fetchAdditionalSpecContent\022\256\001\n" + + "\tListSpecs\022(.google.cloud.apihub.v1.ListSpec" + + "sRequest\032).google.cloud.apihub.v1.ListSp" + + "ecsResponse\"L\332A\006parent\202\323\344\223\002=\022;/v1/{paren" + + "t=projects/*/locations/*/apis/*/versions/*}/specs\022\270\001\n\n" + + "UpdateSpec\022).google.cloud.apihub.v1.UpdateSpecRequest\032\034.google.clo" + + "ud.apihub.v1.Spec\"a\332A\020spec,update_mask\202\323" + + "\344\223\002H2@/v1/{spec.name=projects/*/locations/*/apis/*/versions/*/specs/*}:\004spec\022\233\001\n" + + "\n" + + "DeleteSpec\022).google.cloud.apihub.v1.Del" + + "eteSpecRequest\032\026.google.protobuf.Empty\"J" + + "\332A\004name\202\323\344\223\002=*;/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}\022\356\001\n" + + "\022CreateApiOperation\0221.google.cloud.apihub." + + "v1.CreateApiOperationRequest\032$.google.cl" + + "oud.apihub.v1.ApiOperation\"\177\332A%parent,ap" + + "i_operation,api_operation_id\202\323\344\223\002Q\"@/v1/" + + "{parent=projects/*/locations/*/apis/*/versions/*}/operations:\r" + "api_operation\022\270\001\n" - + "\017GetApiOperation\022..google.cloud.apihub.v1.GetAp" - + "iOperationRequest\032$.google.cloud.apihub." - + "v1.ApiOperation\"O\332A\004name\202\323\344\223\002B\022@/v1/{nam" - + "e=projects/*/locations/*/apis/*/versions/*/operations/*}\022\313\001\n" - + "\021ListApiOperations\0220.google.cloud.apihub.v1.ListApiOperation" - + "sRequest\0321.google.cloud.apihub.v1.ListAp" - + "iOperationsResponse\"Q\332A\006parent\202\323\344\223\002B\022@/v" - + "1/{parent=projects/*/locations/*/apis/*/versions/*}/operations\022\361\001\n" - + "\022UpdateApiOperation\0221.google.cloud.apihub.v1.UpdateApi" - + "OperationRequest\032$.google.cloud.apihub.v" - + "1.ApiOperation\"\201\001\332A\031api_operation,update" - + "_mask\202\323\344\223\002_2N/v1/{api_operation.name=pro" - + "jects/*/locations/*/apis/*/versions/*/operations/*}:\r" + + "\017GetApiOperation\022..google.cloud.apihub.v1" + + ".GetApiOperationRequest\032$.google.cloud.a" + + "pihub.v1.ApiOperation\"O\332A\004name\202\323\344\223\002B\022@/v" + + "1/{name=projects/*/locations/*/apis/*/versions/*/operations/*}\022\313\001\n" + + "\021ListApiOperations\0220.google.cloud.apihub.v1.ListApiOpe" + + "rationsRequest\0321.google.cloud.apihub.v1." + + "ListApiOperationsResponse\"Q\332A\006parent\202\323\344\223" + + "\002B\022@/v1/{parent=projects/*/locations/*/apis/*/versions/*}/operations\022\361\001\n" + + "\022UpdateApiOperation\0221.google.cloud.apihub.v1.Upd" + + "ateApiOperationRequest\032$.google.cloud.ap" + + "ihub.v1.ApiOperation\"\201\001\332A\031api_operation," + + "update_mask\202\323\344\223\002_2N/v1/{api_operation.na" + + "me=projects/*/locations/*/apis/*/versions/*/operations/*}:\r" + "api_operation\022\260\001\n" - + "\022DeleteApiOperation\0221.google.cloud.apihub.v1.Delet" - + "eApiOperationRequest\032\026.google.protobuf.E" - + "mpty\"O\332A\004name\202\323\344\223\002B*@/v1/{name=projects/" - + "*/locations/*/apis/*/versions/*/operations/*}\022\263\001\n\r" - + "GetDefinition\022,.google.cloud.apihub.v1.GetDefinitionRequest\032\".google.c" - + "loud.apihub.v1.Definition\"P\332A\004name\202\323\344\223\002C" - + "\022A/v1/{name=projects/*/locations/*/apis/*/versions/*/definitions/*}\022\316\001\n" - + "\020CreateDeployment\022/.google.cloud.apihub.v1.Create" - + "DeploymentRequest\032\".google.cloud.apihub." - + "v1.Deployment\"e\332A\037parent,deployment,depl" - + "oyment_id\202\323\344\223\002=\"//v1/{parent=projects/*/locations/*}/deployments:\n" - + "deployment\022\241\001\n" - + "\r" - + "GetDeployment\022,.google.cloud.apihub.v1.GetDeploymentRequest\032\".google.cloud.apih" - + "ub.v1.Deployment\">\332A\004name\202\323\344\223\0021\022//v1/{na" - + "me=projects/*/locations/*/deployments/*}\022\264\001\n" - + "\017ListDeployments\022..google.cloud.apihub.v1.ListDeploymentsRequest\032/.google.cl" - + "oud.apihub.v1.ListDeploymentsResponse\"@\332" - + "A\006parent\202\323\344\223\0021\022//v1/{parent=projects/*/locations/*}/deployments\022\320\001\n" - + "\020UpdateDeployment\022/.google.cloud.apihub.v1.UpdateDepl" - + "oymentRequest\032\".google.cloud.apihub.v1.D" - + "eployment\"g\332A\026deployment,update_mask\202\323\344\223" - + "\002H2:/v1/{deployment.name=projects/*/locations/*/deployments/*}:\n" + + "\022DeleteApiOperation\0221.google.cloud.apihub.v1" + + ".DeleteApiOperationRequest\032\026.google.prot" + + "obuf.Empty\"O\332A\004name\202\323\344\223\002B*@/v1/{name=pro" + + "jects/*/locations/*/apis/*/versions/*/operations/*}\022\263\001\n\r" + + "GetDefinition\022,.google.cloud.apihub.v1.GetDefinitionRequest\032\".go" + + "ogle.cloud.apihub.v1.Definition\"P\332A\004name" + + "\202\323\344\223\002C\022A/v1/{name=projects/*/locations/*/apis/*/versions/*/definitions/*}\022\316\001\n" + + "\020CreateDeployment\022/.google.cloud.apihub.v1." + + "CreateDeploymentRequest\032\".google.cloud.a" + + "pihub.v1.Deployment\"e\332A\037parent,deploymen" + + "t,deployment_id\202\323\344\223\002=\"//v1/{parent=projects/*/locations/*}/deployments:\n" + + "deployment\022\241\001\n\r" + + "GetDeployment\022,.google.cloud.apihub.v1.GetDeploymentRequest\032\".google.clou" + + "d.apihub.v1.Deployment\">\332A\004name\202\323\344\223\0021\022//" + + "v1/{name=projects/*/locations/*/deployments/*}\022\264\001\n" + + "\017ListDeployments\022..google.cloud.apihub.v1.ListDeploymentsRequest\032/.goo" + + "gle.cloud.apihub.v1.ListDeploymentsRespo" + + "nse\"@\332A\006parent\202\323\344\223\0021\022//v1/{parent=projects/*/locations/*}/deployments\022\320\001\n" + + "\020UpdateDeployment\022/.google.cloud.apihub.v1.Upda" + + "teDeploymentRequest\032\".google.cloud.apihu" + + "b.v1.Deployment\"g\332A\026deployment,update_ma" + + "sk\202\323\344\223\002H2:/v1/{deployment.name=projects/*/locations/*/deployments/*}:\n" + "deployment\022\233\001\n" - + "\020DeleteDeployment\022/.google.cloud.apihub.v1" - + ".DeleteDeploymentRequest\032\026.google.protob" - + "uf.Empty\">\332A\004name\202\323\344\223\0021*//v1/{name=projects/*/locations/*/deployments/*}\022\307\001\n" - + "\017CreateAttribute\022..google.cloud.apihub.v1.Cr" - + "eateAttributeRequest\032!.google.cloud.apih" - + "ub.v1.Attribute\"a\332A\035parent,attribute,att" - + "ribute_id\202\323\344\223\002;\"./v1/{parent=projects/*/locations/*}/attributes:" + + "\020DeleteDeployment\022/.google.cloud.api" + + "hub.v1.DeleteDeploymentRequest\032\026.google." + + "protobuf.Empty\">\332A\004name\202\323\344\223\0021*//v1/{name" + + "=projects/*/locations/*/deployments/*}\022\307\001\n" + + "\017CreateAttribute\022..google.cloud.apihub" + + ".v1.CreateAttributeRequest\032!.google.clou" + + "d.apihub.v1.Attribute\"a\332A\035parent,attribu" + + "te,attribute_id\202\323\344\223\002;\"./v1/{parent=projects/*/locations/*}/attributes:" + "\tattribute\022\235\001\n" - + "\014GetAttribute\022+.google.cloud.apihub.v1.Get" - + "AttributeRequest\032!.google.cloud.apihub.v" - + "1.Attribute\"=\332A\004name\202\323\344\223\0020\022./v1/{name=projects/*/locations/*/attributes/*}\022\311\001\n" - + "\017UpdateAttribute\022..google.cloud.apihub.v1." - + "UpdateAttributeRequest\032!.google.cloud.ap" - + "ihub.v1.Attribute\"c\332A\025attribute,update_m" - + "ask\202\323\344\223\002E28/v1/{attribute.name=projects/*/locations/*/attributes/*}:" + + "\014GetAttribute\022+.google.cloud.apihub.v1.GetAttributeRequest\032!.google.cloud.ap" + + "ihub.v1.Attribute\"=\332A\004name\202\323\344\223\0020\022./v1/{n" + + "ame=projects/*/locations/*/attributes/*}\022\311\001\n" + + "\017UpdateAttribute\022..google.cloud.apihub.v1.UpdateAttributeRequest\032!.google.cl" + + "oud.apihub.v1.Attribute\"c\332A\025attribute,up" + + "date_mask\202\323\344\223\002E28/v1/{attribute.name=projects/*/locations/*/attributes/*}:" + "\tattribute\022\230\001\n" - + "\017DeleteAttribute\022..google.cloud.apihub" - + ".v1.DeleteAttributeRequest\032\026.google.prot" - + "obuf.Empty\"=\332A\004name\202\323\344\223\0020*./v1/{name=projects/*/locations/*/attributes/*}\022\260\001\n" - + "\016ListAttributes\022-.google.cloud.apihub.v1.Li" - + "stAttributesRequest\032..google.cloud.apihu" - + "b.v1.ListAttributesResponse\"?\332A\006parent\202\323" - + "\344\223\0020\022./v1/{parent=projects/*/locations/*}/attributes\022\305\001\n" - + "\017SearchResources\022..google.cloud.apihub.v1.SearchResourcesRequest" - + "\032/.google.cloud.apihub.v1.SearchResource" - + "sResponse\"Q\332A\016location,query\202\323\344\223\002:\"5/v1/" - + "{location=projects/*/locations/*}:searchResources:\001*\022\330\001\n" - + "\021CreateExternalApi\0220.google.cloud.apihub.v1.CreateExternalApiReq" - + "uest\032#.google.cloud.apihub.v1.ExternalAp" - + "i\"l\332A#parent,external_api,external_api_i" - + "d\202\323\344\223\002@\"0/v1/{parent=projects/*/locations/*}/externalApis:\014external_api\022\245\001\n" - + "\016GetExternalApi\022-.google.cloud.apihub.v1.GetE" - + "xternalApiRequest\032#.google.cloud.apihub." - + "v1.ExternalApi\"?\332A\004name\202\323\344\223\0022\0220/v1/{name" - + "=projects/*/locations/*/externalApis/*}\022\332\001\n" - + "\021UpdateExternalApi\0220.google.cloud.apihub.v1.UpdateExternalApiRequest\032#.google" - + ".cloud.apihub.v1.ExternalApi\"n\332A\030externa" - + "l_api,update_mask\202\323\344\223\002M2=/v1/{external_a" - + "pi.name=projects/*/locations/*/externalApis/*}:\014external_api\022\236\001\n" - + "\021DeleteExternalApi\0220.google.cloud.apihub.v1.DeleteExtern" - + "alApiRequest\032\026.google.protobuf.Empty\"?\332A" - + "\004name\202\323\344\223\0022*0/v1/{name=projects/*/locations/*/externalApis/*}\022\270\001\n" - + "\020ListExternalApis\022/.google.cloud.apihub.v1.ListExternal" - + "ApisRequest\0320.google.cloud.apihub.v1.Lis" - + "tExternalApisResponse\"A\332A\006parent\202\323\344\223\0022\0220" - + "/v1/{parent=projects/*/locations/*}/exte" - + "rnalApis\032I\312A\025apihub.googleapis.com\322A.htt" - + "ps://www.googleapis.com/auth/cloud-platform2\204\010\n" - + "\022ApiHubDependencies\022\317\001\n" - + "\020CreateDependency\022/.google.cloud.apihub.v1.CreateD" - + "ependencyRequest\032\".google.cloud.apihub.v" - + "1.Dependency\"f\332A\037parent,dependency,depen" - + "dency_id\202\323\344\223\002>\"0/v1/{parent=projects/*/locations/*}/dependencies:\n" - + "dependency\022\242\001\n" - + "\r" - + "GetDependency\022,.google.cloud.apihub.v1.GetDependencyRequest\032\".google.cloud.apih" - + "ub.v1.Dependency\"?\332A\004name\202\323\344\223\0022\0220/v1/{na" - + "me=projects/*/locations/*/dependencies/*}\022\321\001\n" - + "\020UpdateDependency\022/.google.cloud.apihub.v1.UpdateDependencyRequest\032\".google" - + ".cloud.apihub.v1.Dependency\"h\332A\026dependen" - + "cy,update_mask\202\323\344\223\002I2;/v1/{dependency.na" - + "me=projects/*/locations/*/dependencies/*}:\n" - + "dependency\022\234\001\n" - + "\020DeleteDependency\022/.google.cloud.apihub.v1.DeleteDependencyRequ" - + "est\032\026.google.protobuf.Empty\"?\332A\004name\202\323\344\223" - + "\0022*0/v1/{name=projects/*/locations/*/dependencies/*}\022\270\001\n" - + "\020ListDependencies\022/.google.cloud.apihub.v1.ListDependenciesReque" - + "st\0320.google.cloud.apihub.v1.ListDependen" - + "ciesResponse\"A\332A\006parent\202\323\344\223\0022\0220/v1/{pare" - + "nt=projects/*/locations/*}/dependencies\032" - + "I\312A\025apihub.googleapis.com\322A.https://www.googleapis.com/auth/cloud-platformB\264\001\n" - + "\032com.google.cloud.apihub.v1B\022ApiHubService" - + "ProtoP\001Z2cloud.google.com/go/apihub/apiv" - + "1/apihubpb;apihubpb\252\002\026Google.Cloud.ApiHu" - + "b.V1\312\002\026Google\\Cloud\\ApiHub\\V1\352\002\031Google::" - + "Cloud::ApiHub::V1b\006proto3" + + "\017DeleteAttribute\022..google.cloud.apihub.v1.DeleteAttributeRequest\032\026.googl" + + "e.protobuf.Empty\"=\332A\004name\202\323\344\223\0020*./v1/{na" + + "me=projects/*/locations/*/attributes/*}\022\260\001\n" + + "\016ListAttributes\022-.google.cloud.apihub.v1.ListAttributesRequest\032..google.cloud" + + ".apihub.v1.ListAttributesResponse\"?\332A\006pa" + + "rent\202\323\344\223\0020\022./v1/{parent=projects/*/locations/*}/attributes\022\305\001\n" + + "\017SearchResources\022..google.cloud.apihub.v1.SearchResourcesR" + + "equest\032/.google.cloud.apihub.v1.SearchRe" + + "sourcesResponse\"Q\332A\016location,query\202\323\344\223\002:" + + "\"5/v1/{location=projects/*/locations/*}:", + "searchResources:\001*\022\330\001\n\021CreateExternalApi" + + "\0220.google.cloud.apihub.v1.CreateExternal" + + "ApiRequest\032#.google.cloud.apihub.v1.Exte" + + "rnalApi\"l\332A#parent,external_api,external" + + "_api_id\202\323\344\223\002@\"0/v1/{parent=projects/*/lo" + + "cations/*}/externalApis:\014external_api\022\245\001" + + "\n\016GetExternalApi\022-.google.cloud.apihub.v" + + "1.GetExternalApiRequest\032#.google.cloud.a" + + "pihub.v1.ExternalApi\"?\332A\004name\202\323\344\223\0022\0220/v1" + + "/{name=projects/*/locations/*/externalAp" + + "is/*}\022\332\001\n\021UpdateExternalApi\0220.google.clo" + + "ud.apihub.v1.UpdateExternalApiRequest\032#." + + "google.cloud.apihub.v1.ExternalApi\"n\332A\030e" + + "xternal_api,update_mask\202\323\344\223\002M2=/v1/{exte" + + "rnal_api.name=projects/*/locations/*/ext" + + "ernalApis/*}:\014external_api\022\236\001\n\021DeleteExt" + + "ernalApi\0220.google.cloud.apihub.v1.Delete" + + "ExternalApiRequest\032\026.google.protobuf.Emp" + + "ty\"?\332A\004name\202\323\344\223\0022*0/v1/{name=projects/*/" + + "locations/*/externalApis/*}\022\270\001\n\020ListExte" + + "rnalApis\022/.google.cloud.apihub.v1.ListEx" + + "ternalApisRequest\0320.google.cloud.apihub." + + "v1.ListExternalApisResponse\"A\332A\006parent\202\323" + + "\344\223\0022\0220/v1/{parent=projects/*/locations/*" + + "}/externalApis\022\301\001\n\020RetrieveApiViews\022/.go" + + "ogle.cloud.apihub.v1.RetrieveApiViewsReq" + + "uest\0320.google.cloud.apihub.v1.RetrieveAp" + + "iViewsResponse\"J\332A\013parent,view\202\323\344\223\0026\0224/v" + + "1/{parent=projects/*/locations/*}:retrie" + + "veApiViews\022\227\002\n\030ConfigureAndDeployServer\022" + + "7.google.cloud.apihub.v1.ConfigureAndDep" + + "loyServerRequest\032\035.google.longrunning.Op" + + "eration\"\242\001\312A5\n ConfigureAndDeployServerR" + + "esponse\022\021OperationMetadata\332A\030parent,mcp_" + + "server_config\202\323\344\223\002I\"D/v1/{parent=project" + + "s/*/locations/*}/servers:configureAndDep" + + "loyServer:\001*\032\253\001\312A\025apihub.googleapis.com\322" + + "A\217\001https://www.googleapis.com/auth/apihu" + + "b.readonly,https://www.googleapis.com/au" + + "th/apihub.readwrite,https://www.googleap" + + "is.com/auth/cloud-platform2\347\010\n\022ApiHubDep" + + "endencies\022\317\001\n\020CreateDependency\022/.google." + + "cloud.apihub.v1.CreateDependencyRequest\032" + + "\".google.cloud.apihub.v1.Dependency\"f\332A\037" + + "parent,dependency,dependency_id\202\323\344\223\002>\"0/" + + "v1/{parent=projects/*/locations/*}/depen" + + "dencies:\ndependency\022\242\001\n\rGetDependency\022,." + + "google.cloud.apihub.v1.GetDependencyRequ" + + "est\032\".google.cloud.apihub.v1.Dependency\"" + + "?\332A\004name\202\323\344\223\0022\0220/v1/{name=projects/*/loc" + + "ations/*/dependencies/*}\022\321\001\n\020UpdateDepen" + + "dency\022/.google.cloud.apihub.v1.UpdateDep" + + "endencyRequest\032\".google.cloud.apihub.v1." + + "Dependency\"h\332A\026dependency,update_mask\202\323\344" + + "\223\002I2;/v1/{dependency.name=projects/*/loc" + + "ations/*/dependencies/*}:\ndependency\022\234\001\n" + + "\020DeleteDependency\022/.google.cloud.apihub." + + "v1.DeleteDependencyRequest\032\026.google.prot" + + "obuf.Empty\"?\332A\004name\202\323\344\223\0022*0/v1/{name=pro" + + "jects/*/locations/*/dependencies/*}\022\270\001\n\020" + + "ListDependencies\022/.google.cloud.apihub.v" + + "1.ListDependenciesRequest\0320.google.cloud" + + ".apihub.v1.ListDependenciesResponse\"A\332A\006" + + "parent\202\323\344\223\0022\0220/v1/{parent=projects/*/loc" + + "ations/*}/dependencies\032\253\001\312A\025apihub.googl" + + "eapis.com\322A\217\001https://www.googleapis.com/" + + "auth/apihub.readonly,https://www.googlea" + + "pis.com/auth/apihub.readwrite,https://ww" + + "w.googleapis.com/auth/cloud-platformB\264\001\n" + + "\032com.google.cloud.apihub.v1B\022ApiHubServi" + + "ceProtoP\001Z2cloud.google.com/go/apihub/ap" + + "iv1/apihubpb;apihubpb\252\002\026Google.Cloud.Api" + + "Hub.V1\312\002\026Google\\Cloud\\ApiHub\\V1\352\002\031Google" + + "::Cloud::ApiHub::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -687,6 +871,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.FieldBehaviorProto.getDescriptor(), com.google.api.ResourceProto.getDescriptor(), com.google.cloud.apihub.v1.CommonFieldsProto.getDescriptor(), + com.google.longrunning.OperationsProto.getDescriptor(), com.google.protobuf.EmptyProto.getDescriptor(), com.google.protobuf.FieldMaskProto.getDescriptor(), }); @@ -842,8 +1027,24 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Name", }); - internal_static_google_cloud_apihub_v1_CreateApiOperationRequest_descriptor = + internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentRequest_descriptor = getDescriptor().getMessageType(19); + internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentRequest_descriptor, + new java.lang.String[] { + "Name", "SpecContentType", + }); + internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentResponse_descriptor = + getDescriptor().getMessageType(20); + internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentResponse_descriptor, + new java.lang.String[] { + "AdditionalSpecContent", + }); + internal_static_google_cloud_apihub_v1_CreateApiOperationRequest_descriptor = + getDescriptor().getMessageType(21); internal_static_google_cloud_apihub_v1_CreateApiOperationRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_CreateApiOperationRequest_descriptor, @@ -851,7 +1052,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "ApiOperationId", "ApiOperation", }); internal_static_google_cloud_apihub_v1_GetApiOperationRequest_descriptor = - getDescriptor().getMessageType(20); + getDescriptor().getMessageType(22); internal_static_google_cloud_apihub_v1_GetApiOperationRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_GetApiOperationRequest_descriptor, @@ -859,7 +1060,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_UpdateApiOperationRequest_descriptor = - getDescriptor().getMessageType(21); + getDescriptor().getMessageType(23); internal_static_google_cloud_apihub_v1_UpdateApiOperationRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_UpdateApiOperationRequest_descriptor, @@ -867,7 +1068,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ApiOperation", "UpdateMask", }); internal_static_google_cloud_apihub_v1_DeleteApiOperationRequest_descriptor = - getDescriptor().getMessageType(22); + getDescriptor().getMessageType(24); internal_static_google_cloud_apihub_v1_DeleteApiOperationRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DeleteApiOperationRequest_descriptor, @@ -875,7 +1076,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_ListApiOperationsRequest_descriptor = - getDescriptor().getMessageType(23); + getDescriptor().getMessageType(25); internal_static_google_cloud_apihub_v1_ListApiOperationsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListApiOperationsRequest_descriptor, @@ -883,7 +1084,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "Filter", "PageSize", "PageToken", }); internal_static_google_cloud_apihub_v1_ListApiOperationsResponse_descriptor = - getDescriptor().getMessageType(24); + getDescriptor().getMessageType(26); internal_static_google_cloud_apihub_v1_ListApiOperationsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListApiOperationsResponse_descriptor, @@ -891,7 +1092,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ApiOperations", "NextPageToken", }); internal_static_google_cloud_apihub_v1_GetDefinitionRequest_descriptor = - getDescriptor().getMessageType(25); + getDescriptor().getMessageType(27); internal_static_google_cloud_apihub_v1_GetDefinitionRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_GetDefinitionRequest_descriptor, @@ -899,7 +1100,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_CreateDeploymentRequest_descriptor = - getDescriptor().getMessageType(26); + getDescriptor().getMessageType(28); internal_static_google_cloud_apihub_v1_CreateDeploymentRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_CreateDeploymentRequest_descriptor, @@ -907,7 +1108,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "DeploymentId", "Deployment", }); internal_static_google_cloud_apihub_v1_GetDeploymentRequest_descriptor = - getDescriptor().getMessageType(27); + getDescriptor().getMessageType(29); internal_static_google_cloud_apihub_v1_GetDeploymentRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_GetDeploymentRequest_descriptor, @@ -915,7 +1116,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_UpdateDeploymentRequest_descriptor = - getDescriptor().getMessageType(28); + getDescriptor().getMessageType(30); internal_static_google_cloud_apihub_v1_UpdateDeploymentRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_UpdateDeploymentRequest_descriptor, @@ -923,7 +1124,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Deployment", "UpdateMask", }); internal_static_google_cloud_apihub_v1_DeleteDeploymentRequest_descriptor = - getDescriptor().getMessageType(29); + getDescriptor().getMessageType(31); internal_static_google_cloud_apihub_v1_DeleteDeploymentRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DeleteDeploymentRequest_descriptor, @@ -931,7 +1132,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_ListDeploymentsRequest_descriptor = - getDescriptor().getMessageType(30); + getDescriptor().getMessageType(32); internal_static_google_cloud_apihub_v1_ListDeploymentsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListDeploymentsRequest_descriptor, @@ -939,7 +1140,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "Filter", "PageSize", "PageToken", }); internal_static_google_cloud_apihub_v1_ListDeploymentsResponse_descriptor = - getDescriptor().getMessageType(31); + getDescriptor().getMessageType(33); internal_static_google_cloud_apihub_v1_ListDeploymentsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListDeploymentsResponse_descriptor, @@ -947,7 +1148,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Deployments", "NextPageToken", }); internal_static_google_cloud_apihub_v1_CreateAttributeRequest_descriptor = - getDescriptor().getMessageType(32); + getDescriptor().getMessageType(34); internal_static_google_cloud_apihub_v1_CreateAttributeRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_CreateAttributeRequest_descriptor, @@ -955,7 +1156,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "AttributeId", "Attribute", }); internal_static_google_cloud_apihub_v1_GetAttributeRequest_descriptor = - getDescriptor().getMessageType(33); + getDescriptor().getMessageType(35); internal_static_google_cloud_apihub_v1_GetAttributeRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_GetAttributeRequest_descriptor, @@ -963,7 +1164,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_UpdateAttributeRequest_descriptor = - getDescriptor().getMessageType(34); + getDescriptor().getMessageType(36); internal_static_google_cloud_apihub_v1_UpdateAttributeRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_UpdateAttributeRequest_descriptor, @@ -971,7 +1172,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Attribute", "UpdateMask", }); internal_static_google_cloud_apihub_v1_DeleteAttributeRequest_descriptor = - getDescriptor().getMessageType(35); + getDescriptor().getMessageType(37); internal_static_google_cloud_apihub_v1_DeleteAttributeRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DeleteAttributeRequest_descriptor, @@ -979,7 +1180,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_ListAttributesRequest_descriptor = - getDescriptor().getMessageType(36); + getDescriptor().getMessageType(38); internal_static_google_cloud_apihub_v1_ListAttributesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListAttributesRequest_descriptor, @@ -987,7 +1188,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "Filter", "PageSize", "PageToken", }); internal_static_google_cloud_apihub_v1_ListAttributesResponse_descriptor = - getDescriptor().getMessageType(37); + getDescriptor().getMessageType(39); internal_static_google_cloud_apihub_v1_ListAttributesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListAttributesResponse_descriptor, @@ -995,7 +1196,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Attributes", "NextPageToken", }); internal_static_google_cloud_apihub_v1_SearchResourcesRequest_descriptor = - getDescriptor().getMessageType(38); + getDescriptor().getMessageType(40); internal_static_google_cloud_apihub_v1_SearchResourcesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_SearchResourcesRequest_descriptor, @@ -1003,7 +1204,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Location", "Query", "Filter", "PageSize", "PageToken", }); internal_static_google_cloud_apihub_v1_ApiHubResource_descriptor = - getDescriptor().getMessageType(39); + getDescriptor().getMessageType(41); internal_static_google_cloud_apihub_v1_ApiHubResource_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ApiHubResource_descriptor, @@ -1011,7 +1212,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Api", "Operation", "Deployment", "Spec", "Definition", "Version", "Resource", }); internal_static_google_cloud_apihub_v1_SearchResult_descriptor = - getDescriptor().getMessageType(40); + getDescriptor().getMessageType(42); internal_static_google_cloud_apihub_v1_SearchResult_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_SearchResult_descriptor, @@ -1019,7 +1220,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Resource", }); internal_static_google_cloud_apihub_v1_SearchResourcesResponse_descriptor = - getDescriptor().getMessageType(41); + getDescriptor().getMessageType(43); internal_static_google_cloud_apihub_v1_SearchResourcesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_SearchResourcesResponse_descriptor, @@ -1027,7 +1228,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "SearchResults", "NextPageToken", }); internal_static_google_cloud_apihub_v1_CreateDependencyRequest_descriptor = - getDescriptor().getMessageType(42); + getDescriptor().getMessageType(44); internal_static_google_cloud_apihub_v1_CreateDependencyRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_CreateDependencyRequest_descriptor, @@ -1035,7 +1236,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "DependencyId", "Dependency", }); internal_static_google_cloud_apihub_v1_GetDependencyRequest_descriptor = - getDescriptor().getMessageType(43); + getDescriptor().getMessageType(45); internal_static_google_cloud_apihub_v1_GetDependencyRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_GetDependencyRequest_descriptor, @@ -1043,7 +1244,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_UpdateDependencyRequest_descriptor = - getDescriptor().getMessageType(44); + getDescriptor().getMessageType(46); internal_static_google_cloud_apihub_v1_UpdateDependencyRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_UpdateDependencyRequest_descriptor, @@ -1051,7 +1252,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Dependency", "UpdateMask", }); internal_static_google_cloud_apihub_v1_DeleteDependencyRequest_descriptor = - getDescriptor().getMessageType(45); + getDescriptor().getMessageType(47); internal_static_google_cloud_apihub_v1_DeleteDependencyRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DeleteDependencyRequest_descriptor, @@ -1059,7 +1260,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_ListDependenciesRequest_descriptor = - getDescriptor().getMessageType(46); + getDescriptor().getMessageType(48); internal_static_google_cloud_apihub_v1_ListDependenciesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListDependenciesRequest_descriptor, @@ -1067,7 +1268,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "Filter", "PageSize", "PageToken", }); internal_static_google_cloud_apihub_v1_ListDependenciesResponse_descriptor = - getDescriptor().getMessageType(47); + getDescriptor().getMessageType(49); internal_static_google_cloud_apihub_v1_ListDependenciesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListDependenciesResponse_descriptor, @@ -1075,7 +1276,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Dependencies", "NextPageToken", }); internal_static_google_cloud_apihub_v1_CreateExternalApiRequest_descriptor = - getDescriptor().getMessageType(48); + getDescriptor().getMessageType(50); internal_static_google_cloud_apihub_v1_CreateExternalApiRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_CreateExternalApiRequest_descriptor, @@ -1083,7 +1284,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "ExternalApiId", "ExternalApi", }); internal_static_google_cloud_apihub_v1_GetExternalApiRequest_descriptor = - getDescriptor().getMessageType(49); + getDescriptor().getMessageType(51); internal_static_google_cloud_apihub_v1_GetExternalApiRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_GetExternalApiRequest_descriptor, @@ -1091,7 +1292,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_UpdateExternalApiRequest_descriptor = - getDescriptor().getMessageType(50); + getDescriptor().getMessageType(52); internal_static_google_cloud_apihub_v1_UpdateExternalApiRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_UpdateExternalApiRequest_descriptor, @@ -1099,7 +1300,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ExternalApi", "UpdateMask", }); internal_static_google_cloud_apihub_v1_DeleteExternalApiRequest_descriptor = - getDescriptor().getMessageType(51); + getDescriptor().getMessageType(53); internal_static_google_cloud_apihub_v1_DeleteExternalApiRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DeleteExternalApiRequest_descriptor, @@ -1107,7 +1308,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_ListExternalApisRequest_descriptor = - getDescriptor().getMessageType(52); + getDescriptor().getMessageType(54); internal_static_google_cloud_apihub_v1_ListExternalApisRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListExternalApisRequest_descriptor, @@ -1115,19 +1316,131 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PageSize", "PageToken", }); internal_static_google_cloud_apihub_v1_ListExternalApisResponse_descriptor = - getDescriptor().getMessageType(53); + getDescriptor().getMessageType(55); internal_static_google_cloud_apihub_v1_ListExternalApisResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListExternalApisResponse_descriptor, new java.lang.String[] { "ExternalApis", "NextPageToken", }); + internal_static_google_cloud_apihub_v1_RetrieveApiViewsRequest_descriptor = + getDescriptor().getMessageType(56); + internal_static_google_cloud_apihub_v1_RetrieveApiViewsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_RetrieveApiViewsRequest_descriptor, + new java.lang.String[] { + "Parent", "Filter", "PageSize", "PageToken", "View", + }); + internal_static_google_cloud_apihub_v1_ApiView_descriptor = getDescriptor().getMessageType(57); + internal_static_google_cloud_apihub_v1_ApiView_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ApiView_descriptor, + new java.lang.String[] { + "McpServerView", "McpToolView", "View", + }); + internal_static_google_cloud_apihub_v1_FlattenedApiVersionDeploymentView_descriptor = + getDescriptor().getMessageType(58); + internal_static_google_cloud_apihub_v1_FlattenedApiVersionDeploymentView_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_FlattenedApiVersionDeploymentView_descriptor, + new java.lang.String[] { + "Api", "Version", "Deployment", + }); + internal_static_google_cloud_apihub_v1_FlattenedApiVersionOperationDeploymentView_descriptor = + getDescriptor().getMessageType(59); + internal_static_google_cloud_apihub_v1_FlattenedApiVersionOperationDeploymentView_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_FlattenedApiVersionOperationDeploymentView_descriptor, + new java.lang.String[] { + "Api", "Version", "ApiOperation", "Deployment", + }); + internal_static_google_cloud_apihub_v1_RetrieveApiViewsResponse_descriptor = + getDescriptor().getMessageType(60); + internal_static_google_cloud_apihub_v1_RetrieveApiViewsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_RetrieveApiViewsResponse_descriptor, + new java.lang.String[] { + "ApiViews", "NextPageToken", + }); + internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerRequest_descriptor = + getDescriptor().getMessageType(61); + internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerRequest_descriptor, + new java.lang.String[] { + "McpServerConfig", "Parent", "ServerConfig", + }); + internal_static_google_cloud_apihub_v1_McpServerConfig_descriptor = + getDescriptor().getMessageType(62); + internal_static_google_cloud_apihub_v1_McpServerConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_McpServerConfig_descriptor, + new java.lang.String[] { + "ApigeeXTargetDetails", "Tools", "Target", + }); + internal_static_google_cloud_apihub_v1_McpServerConfig_McpToolConfig_descriptor = + internal_static_google_cloud_apihub_v1_McpServerConfig_descriptor.getNestedType(0); + internal_static_google_cloud_apihub_v1_McpServerConfig_McpToolConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_McpServerConfig_McpToolConfig_descriptor, + new java.lang.String[] { + "ToolId", "Description", "Operation", + }); + internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_descriptor = + getDescriptor().getMessageType(63); + internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_descriptor, + new java.lang.String[] { + "Environment", "Proxy", "TargetProject", "Metadata", "DeployedRevision", + }); + internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_MetaData_descriptor = + internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_descriptor.getNestedType(0); + internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_MetaData_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_MetaData_descriptor, + new java.lang.String[] { + "DisplayName", "Description", + }); + internal_static_google_cloud_apihub_v1_OperationConfig_descriptor = + getDescriptor().getMessageType(64); + internal_static_google_cloud_apihub_v1_OperationConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_OperationConfig_descriptor, + new java.lang.String[] { + "Operation", "HttpOperation", "Identifier", + }); + internal_static_google_cloud_apihub_v1_OperationConfig_HttpOperationConfig_descriptor = + internal_static_google_cloud_apihub_v1_OperationConfig_descriptor.getNestedType(0); + internal_static_google_cloud_apihub_v1_OperationConfig_HttpOperationConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_OperationConfig_HttpOperationConfig_descriptor, + new java.lang.String[] { + "Spec", "Path", "Method", + }); + internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerResponse_descriptor = + getDescriptor().getMessageType(65); + internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerResponse_descriptor, + new java.lang.String[] { + "McpServerDetails", "ServerDetails", + }); + internal_static_google_cloud_apihub_v1_McpServerDetails_descriptor = + getDescriptor().getMessageType(66); + internal_static_google_cloud_apihub_v1_McpServerDetails_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_McpServerDetails_descriptor, + new java.lang.String[] { + "ApigeeXDetails", "Details", + }); descriptor.resolveAllFeaturesImmutable(); com.google.api.AnnotationsProto.getDescriptor(); com.google.api.ClientProto.getDescriptor(); com.google.api.FieldBehaviorProto.getDescriptor(); com.google.api.ResourceProto.getDescriptor(); com.google.cloud.apihub.v1.CommonFieldsProto.getDescriptor(); + com.google.longrunning.OperationsProto.getDescriptor(); com.google.protobuf.EmptyProto.getDescriptor(); com.google.protobuf.FieldMaskProto.getDescriptor(); com.google.protobuf.ExtensionRegistry registry = @@ -1138,6 +1451,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { registry.add(com.google.api.ClientProto.methodSignature); registry.add(com.google.api.ClientProto.oauthScopes); registry.add(com.google.api.ResourceProto.resourceReference); + registry.add(com.google.longrunning.OperationsProto.operationInfo); com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( descriptor, registry); } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOperation.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOperation.java index ac22681262ed..2ed7d4e8a5bb 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOperation.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOperation.java @@ -63,6 +63,7 @@ private ApiOperation() { name_ = ""; spec_ = ""; sourceMetadata_ = java.util.Collections.emptyList(); + deployments_ = com.google.protobuf.LazyStringArrayList.emptyList(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -614,6 +615,98 @@ public com.google.cloud.apihub.v1.SourceMetadataOrBuilder getSourceMetadataOrBui return sourceMetadata_.get(index); } + public static final int DEPLOYMENTS_FIELD_NUMBER = 8; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList deployments_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this API operation. For
                      +   * operations parsed from a spec, `UpdateApiOperation` returns
                      +   * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +   * `Spec.deployments` instead. Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the deployments. + */ + public com.google.protobuf.ProtocolStringList getDeploymentsList() { + return deployments_; + } + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this API operation. For
                      +   * operations parsed from a spec, `UpdateApiOperation` returns
                      +   * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +   * `Spec.deployments` instead. Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The count of deployments. + */ + public int getDeploymentsCount() { + return deployments_.size(); + } + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this API operation. For
                      +   * operations parsed from a spec, `UpdateApiOperation` returns
                      +   * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +   * `Spec.deployments` instead. Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The deployments at the given index. + */ + public java.lang.String getDeployments(int index) { + return deployments_.get(index); + } + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this API operation. For
                      +   * operations parsed from a spec, `UpdateApiOperation` returns
                      +   * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +   * `Spec.deployments` instead. Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the deployments at the given index. + */ + public com.google.protobuf.ByteString getDeploymentsBytes(int index) { + return deployments_.getByteString(index); + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -648,6 +741,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < sourceMetadata_.size(); i++) { output.writeMessage(7, sourceMetadata_.get(i)); } + for (int i = 0; i < deployments_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 8, deployments_.getRaw(i)); + } getUnknownFields().writeTo(output); } @@ -686,6 +782,14 @@ public int getSerializedSize() { for (int i = 0; i < sourceMetadata_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, sourceMetadata_.get(i)); } + { + int dataSize = 0; + for (int i = 0; i < deployments_.size(); i++) { + dataSize += computeStringSizeNoTag(deployments_.getRaw(i)); + } + size += dataSize; + size += 1 * getDeploymentsList().size(); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -717,6 +821,7 @@ public boolean equals(final java.lang.Object obj) { } if (!internalGetAttributes().equals(other.internalGetAttributes())) return false; if (!getSourceMetadataList().equals(other.getSourceMetadataList())) return false; + if (!getDeploymentsList().equals(other.getDeploymentsList())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -752,6 +857,10 @@ public int hashCode() { hash = (37 * hash) + SOURCE_METADATA_FIELD_NUMBER; hash = (53 * hash) + getSourceMetadataList().hashCode(); } + if (getDeploymentsCount() > 0) { + hash = (37 * hash) + DEPLOYMENTS_FIELD_NUMBER; + hash = (53 * hash) + getDeploymentsList().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -959,6 +1068,7 @@ public Builder clear() { sourceMetadataBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000040); + deployments_ = com.google.protobuf.LazyStringArrayList.emptyList(); return this; } @@ -1031,6 +1141,10 @@ private void buildPartial0(com.google.cloud.apihub.v1.ApiOperation result) { result.attributes_ = internalGetAttributes().build(AttributesDefaultEntryHolder.defaultEntry); } + if (((from_bitField0_ & 0x00000080) != 0)) { + deployments_.makeImmutable(); + result.deployments_ = deployments_; + } result.bitField0_ |= to_bitField0_; } @@ -1094,6 +1208,16 @@ public Builder mergeFrom(com.google.cloud.apihub.v1.ApiOperation other) { } } } + if (!other.deployments_.isEmpty()) { + if (deployments_.isEmpty()) { + deployments_ = other.deployments_; + bitField0_ |= 0x00000080; + } else { + ensureDeploymentsIsMutable(); + deployments_.addAll(other.deployments_); + } + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1179,6 +1303,13 @@ public Builder mergeFrom( } break; } // case 58 + case 66: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureDeploymentsIsMutable(); + deployments_.add(s); + break; + } // case 66 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -2835,6 +2966,243 @@ public com.google.cloud.apihub.v1.SourceMetadata.Builder addSourceMetadataBuilde return sourceMetadataBuilder_; } + private com.google.protobuf.LazyStringArrayList deployments_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureDeploymentsIsMutable() { + if (!deployments_.isModifiable()) { + deployments_ = new com.google.protobuf.LazyStringArrayList(deployments_); + } + bitField0_ |= 0x00000080; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this API operation. For
                      +     * operations parsed from a spec, `UpdateApiOperation` returns
                      +     * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +     * `Spec.deployments` instead. Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the deployments. + */ + public com.google.protobuf.ProtocolStringList getDeploymentsList() { + deployments_.makeImmutable(); + return deployments_; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this API operation. For
                      +     * operations parsed from a spec, `UpdateApiOperation` returns
                      +     * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +     * `Spec.deployments` instead. Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The count of deployments. + */ + public int getDeploymentsCount() { + return deployments_.size(); + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this API operation. For
                      +     * operations parsed from a spec, `UpdateApiOperation` returns
                      +     * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +     * `Spec.deployments` instead. Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The deployments at the given index. + */ + public java.lang.String getDeployments(int index) { + return deployments_.get(index); + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this API operation. For
                      +     * operations parsed from a spec, `UpdateApiOperation` returns
                      +     * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +     * `Spec.deployments` instead. Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the deployments at the given index. + */ + public com.google.protobuf.ByteString getDeploymentsBytes(int index) { + return deployments_.getByteString(index); + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this API operation. For
                      +     * operations parsed from a spec, `UpdateApiOperation` returns
                      +     * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +     * `Spec.deployments` instead. Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index to set the value at. + * @param value The deployments to set. + * @return This builder for chaining. + */ + public Builder setDeployments(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDeploymentsIsMutable(); + deployments_.set(index, value); + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this API operation. For
                      +     * operations parsed from a spec, `UpdateApiOperation` returns
                      +     * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +     * `Spec.deployments` instead. Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The deployments to add. + * @return This builder for chaining. + */ + public Builder addDeployments(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDeploymentsIsMutable(); + deployments_.add(value); + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this API operation. For
                      +     * operations parsed from a spec, `UpdateApiOperation` returns
                      +     * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +     * `Spec.deployments` instead. Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param values The deployments to add. + * @return This builder for chaining. + */ + public Builder addAllDeployments(java.lang.Iterable values) { + ensureDeploymentsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, deployments_); + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this API operation. For
                      +     * operations parsed from a spec, `UpdateApiOperation` returns
                      +     * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +     * `Spec.deployments` instead. Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearDeployments() { + deployments_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000080); + ; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this API operation. For
                      +     * operations parsed from a spec, `UpdateApiOperation` returns
                      +     * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +     * `Spec.deployments` instead. Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes of the deployments to add. + * @return This builder for chaining. + */ + public Builder addDeploymentsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureDeploymentsIsMutable(); + deployments_.add(value); + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ApiOperation) } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOperationOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOperationOrBuilder.java index 82d6e6112461..ba18aa728e41 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOperationOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOperationOrBuilder.java @@ -384,4 +384,82 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault( * */ com.google.cloud.apihub.v1.SourceMetadataOrBuilder getSourceMetadataOrBuilder(int index); + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this API operation. For
                      +   * operations parsed from a spec, `UpdateApiOperation` returns
                      +   * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +   * `Spec.deployments` instead. Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the deployments. + */ + java.util.List getDeploymentsList(); + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this API operation. For
                      +   * operations parsed from a spec, `UpdateApiOperation` returns
                      +   * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +   * `Spec.deployments` instead. Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The count of deployments. + */ + int getDeploymentsCount(); + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this API operation. For
                      +   * operations parsed from a spec, `UpdateApiOperation` returns
                      +   * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +   * `Spec.deployments` instead. Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The deployments at the given index. + */ + java.lang.String getDeployments(int index); + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this API operation. For
                      +   * operations parsed from a spec, `UpdateApiOperation` returns
                      +   * `FAILED_PRECONDITION`; link the parent spec to the deployment via
                      +   * `Spec.deployments` instead. Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 8 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the deployments at the given index. + */ + com.google.protobuf.ByteString getDeploymentsBytes(int index); } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOrBuilder.java index 575d7090c3f2..172ab885bf90 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiOrBuilder.java @@ -793,7 +793,7 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault( * *
                          * Optional. The api requirement doc associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -814,7 +814,7 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault(
                          *
                          * 
                          * Optional. The api requirement doc associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -835,7 +835,7 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault(
                          *
                          * 
                          * Optional. The api requirement doc associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -853,7 +853,9 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault(
                          *
                          *
                          * 
                      -   * Optional. Fingerprint of the API resource.
                      +   * Optional. Fingerprint of the API resource. This must be unique for each API
                      +   * resource. It can neither be unset nor be updated to an existing fingerprint
                      +   * of another API resource.
                          * 
                      * * string fingerprint = 17 [(.google.api.field_behavior) = OPTIONAL]; @@ -866,7 +868,9 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault( * * *
                      -   * Optional. Fingerprint of the API resource.
                      +   * Optional. Fingerprint of the API resource. This must be unique for each API
                      +   * resource. It can neither be unset nor be updated to an existing fingerprint
                      +   * of another API resource.
                          * 
                      * * string fingerprint = 17 [(.google.api.field_behavior) = OPTIONAL]; @@ -951,7 +955,7 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault( * *
                          * Optional. The api functional requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute.
                      +   * Cardinality is 1 for this attribute.
                          * This maps to the following system defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -972,7 +976,7 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault(
                          *
                          * 
                          * Optional. The api functional requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute.
                      +   * Cardinality is 1 for this attribute.
                          * This maps to the following system defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -993,7 +997,7 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault(
                          *
                          * 
                          * Optional. The api functional requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute.
                      +   * Cardinality is 1 for this attribute.
                          * This maps to the following system defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-functional-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1012,7 +1016,7 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault(
                          *
                          * 
                          * Optional. The api technical requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1033,7 +1037,7 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault(
                          *
                          * 
                          * Optional. The api technical requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1054,7 +1058,7 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault(
                          *
                          * 
                          * Optional. The api technical requirements associated with the API resource.
                      -   * Carinality is 1 for this attribute. This maps to the following system
                      +   * Cardinality is 1 for this attribute. This maps to the following system
                          * defined attribute:
                          * `projects/{project}/locations/{location}/attributes/system-api-technical-requirements`
                          * attribute. The value of the attribute should be a proper URI, and in case
                      @@ -1067,4 +1071,62 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault(
                          * 
                          */
                         com.google.cloud.apihub.v1.AttributeValuesOrBuilder getApiTechnicalRequirementsOrBuilder();
                      +
                      +  /**
                      +   *
                      +   *
                      +   * 
                      +   * Optional. The type of the service.
                      +   * This maps to the following system defined attribute:
                      +   * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +   * attribute.
                      +   * The cardinality of this attribute is 1. All values should be from the list
                      +   * of allowed values defined for the attribute.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the serviceType field is set. + */ + boolean hasServiceType(); + + /** + * + * + *
                      +   * Optional. The type of the service.
                      +   * This maps to the following system defined attribute:
                      +   * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +   * attribute.
                      +   * The cardinality of this attribute is 1. All values should be from the list
                      +   * of allowed values defined for the attribute.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The serviceType. + */ + com.google.cloud.apihub.v1.AttributeValues getServiceType(); + + /** + * + * + *
                      +   * Optional. The type of the service.
                      +   * This maps to the following system defined attribute:
                      +   * `projects/{project}/locations/{location}/attributes/system-service-type`
                      +   * attribute.
                      +   * The cardinality of this attribute is 1. All values should be from the list
                      +   * of allowed values defined for the attribute.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.AttributeValues service_type = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.AttributeValuesOrBuilder getServiceTypeOrBuilder(); } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiView.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiView.java new file mode 100644 index 000000000000..497bbb9d59f0 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiView.java @@ -0,0 +1,1134 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The view of an API.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApiView} + */ +@com.google.protobuf.Generated +public final class ApiView extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ApiView) + ApiViewOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ApiView"); + } + + // Use ApiView.newBuilder() to construct. + private ApiView(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ApiView() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApiView_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApiView_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApiView.class, + com.google.cloud.apihub.v1.ApiView.Builder.class); + } + + private int viewCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object view_; + + public enum ViewCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + MCP_SERVER_VIEW(1), + MCP_TOOL_VIEW(2), + VIEW_NOT_SET(0); + private final int value; + + private ViewCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ViewCase valueOf(int value) { + return forNumber(value); + } + + public static ViewCase forNumber(int value) { + switch (value) { + case 1: + return MCP_SERVER_VIEW; + case 2: + return MCP_TOOL_VIEW; + case 0: + return VIEW_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ViewCase getViewCase() { + return ViewCase.forNumber(viewCase_); + } + + public static final int MCP_SERVER_VIEW_FIELD_NUMBER = 1; + + /** + * + * + *
                      +   * MCP server view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + * + * @return Whether the mcpServerView field is set. + */ + @java.lang.Override + public boolean hasMcpServerView() { + return viewCase_ == 1; + } + + /** + * + * + *
                      +   * MCP server view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + * + * @return The mcpServerView. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView getMcpServerView() { + if (viewCase_ == 1) { + return (com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) view_; + } + return com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.getDefaultInstance(); + } + + /** + * + * + *
                      +   * MCP server view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentViewOrBuilder + getMcpServerViewOrBuilder() { + if (viewCase_ == 1) { + return (com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) view_; + } + return com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.getDefaultInstance(); + } + + public static final int MCP_TOOL_VIEW_FIELD_NUMBER = 2; + + /** + * + * + *
                      +   * MCP tools view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + * + * @return Whether the mcpToolView field is set. + */ + @java.lang.Override + public boolean hasMcpToolView() { + return viewCase_ == 2; + } + + /** + * + * + *
                      +   * MCP tools view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + * + * @return The mcpToolView. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView getMcpToolView() { + if (viewCase_ == 2) { + return (com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) view_; + } + return com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + .getDefaultInstance(); + } + + /** + * + * + *
                      +   * MCP tools view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentViewOrBuilder + getMcpToolViewOrBuilder() { + if (viewCase_ == 2) { + return (com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) view_; + } + return com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + .getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (viewCase_ == 1) { + output.writeMessage(1, (com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) view_); + } + if (viewCase_ == 2) { + output.writeMessage( + 2, (com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) view_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (viewCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) view_); + } + if (viewCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) view_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ApiView)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ApiView other = (com.google.cloud.apihub.v1.ApiView) obj; + + if (!getViewCase().equals(other.getViewCase())) return false; + switch (viewCase_) { + case 1: + if (!getMcpServerView().equals(other.getMcpServerView())) return false; + break; + case 2: + if (!getMcpToolView().equals(other.getMcpToolView())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (viewCase_) { + case 1: + hash = (37 * hash) + MCP_SERVER_VIEW_FIELD_NUMBER; + hash = (53 * hash) + getMcpServerView().hashCode(); + break; + case 2: + hash = (37 * hash) + MCP_TOOL_VIEW_FIELD_NUMBER; + hash = (53 * hash) + getMcpToolView().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ApiView parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApiView parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApiView parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApiView parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApiView parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApiView parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApiView parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApiView parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApiView parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApiView parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApiView parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApiView parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.ApiView prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The view of an API.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApiView} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ApiView) + com.google.cloud.apihub.v1.ApiViewOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApiView_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApiView_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApiView.class, + com.google.cloud.apihub.v1.ApiView.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ApiView.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (mcpServerViewBuilder_ != null) { + mcpServerViewBuilder_.clear(); + } + if (mcpToolViewBuilder_ != null) { + mcpToolViewBuilder_.clear(); + } + viewCase_ = 0; + view_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApiView_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApiView getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ApiView.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApiView build() { + com.google.cloud.apihub.v1.ApiView result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApiView buildPartial() { + com.google.cloud.apihub.v1.ApiView result = new com.google.cloud.apihub.v1.ApiView(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.ApiView result) { + int from_bitField0_ = bitField0_; + } + + private void buildPartialOneofs(com.google.cloud.apihub.v1.ApiView result) { + result.viewCase_ = viewCase_; + result.view_ = this.view_; + if (viewCase_ == 1 && mcpServerViewBuilder_ != null) { + result.view_ = mcpServerViewBuilder_.build(); + } + if (viewCase_ == 2 && mcpToolViewBuilder_ != null) { + result.view_ = mcpToolViewBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ApiView) { + return mergeFrom((com.google.cloud.apihub.v1.ApiView) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ApiView other) { + if (other == com.google.cloud.apihub.v1.ApiView.getDefaultInstance()) return this; + switch (other.getViewCase()) { + case MCP_SERVER_VIEW: + { + mergeMcpServerView(other.getMcpServerView()); + break; + } + case MCP_TOOL_VIEW: + { + mergeMcpToolView(other.getMcpToolView()); + break; + } + case VIEW_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetMcpServerViewFieldBuilder().getBuilder(), extensionRegistry); + viewCase_ = 1; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetMcpToolViewFieldBuilder().getBuilder(), extensionRegistry); + viewCase_ = 2; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int viewCase_ = 0; + private java.lang.Object view_; + + public ViewCase getViewCase() { + return ViewCase.forNumber(viewCase_); + } + + public Builder clearView() { + viewCase_ = 0; + view_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView, + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.Builder, + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentViewOrBuilder> + mcpServerViewBuilder_; + + /** + * + * + *
                      +     * MCP server view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + * + * @return Whether the mcpServerView field is set. + */ + @java.lang.Override + public boolean hasMcpServerView() { + return viewCase_ == 1; + } + + /** + * + * + *
                      +     * MCP server view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + * + * @return The mcpServerView. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView getMcpServerView() { + if (mcpServerViewBuilder_ == null) { + if (viewCase_ == 1) { + return (com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) view_; + } + return com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.getDefaultInstance(); + } else { + if (viewCase_ == 1) { + return mcpServerViewBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * MCP server view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + */ + public Builder setMcpServerView( + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView value) { + if (mcpServerViewBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + view_ = value; + onChanged(); + } else { + mcpServerViewBuilder_.setMessage(value); + } + viewCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * MCP server view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + */ + public Builder setMcpServerView( + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.Builder builderForValue) { + if (mcpServerViewBuilder_ == null) { + view_ = builderForValue.build(); + onChanged(); + } else { + mcpServerViewBuilder_.setMessage(builderForValue.build()); + } + viewCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * MCP server view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + */ + public Builder mergeMcpServerView( + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView value) { + if (mcpServerViewBuilder_ == null) { + if (viewCase_ == 1 + && view_ + != com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView + .getDefaultInstance()) { + view_ = + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.newBuilder( + (com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) view_) + .mergeFrom(value) + .buildPartial(); + } else { + view_ = value; + } + onChanged(); + } else { + if (viewCase_ == 1) { + mcpServerViewBuilder_.mergeFrom(value); + } else { + mcpServerViewBuilder_.setMessage(value); + } + } + viewCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * MCP server view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + */ + public Builder clearMcpServerView() { + if (mcpServerViewBuilder_ == null) { + if (viewCase_ == 1) { + viewCase_ = 0; + view_ = null; + onChanged(); + } + } else { + if (viewCase_ == 1) { + viewCase_ = 0; + view_ = null; + } + mcpServerViewBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * MCP server view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + */ + public com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.Builder + getMcpServerViewBuilder() { + return internalGetMcpServerViewFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * MCP server view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentViewOrBuilder + getMcpServerViewOrBuilder() { + if ((viewCase_ == 1) && (mcpServerViewBuilder_ != null)) { + return mcpServerViewBuilder_.getMessageOrBuilder(); + } else { + if (viewCase_ == 1) { + return (com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) view_; + } + return com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * MCP server view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView, + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.Builder, + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentViewOrBuilder> + internalGetMcpServerViewFieldBuilder() { + if (mcpServerViewBuilder_ == null) { + if (!(viewCase_ == 1)) { + view_ = com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.getDefaultInstance(); + } + mcpServerViewBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView, + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.Builder, + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentViewOrBuilder>( + (com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) view_, + getParentForChildren(), + isClean()); + view_ = null; + } + viewCase_ = 1; + onChanged(); + return mcpServerViewBuilder_; + } + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView, + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView.Builder, + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentViewOrBuilder> + mcpToolViewBuilder_; + + /** + * + * + *
                      +     * MCP tools view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + * + * @return Whether the mcpToolView field is set. + */ + @java.lang.Override + public boolean hasMcpToolView() { + return viewCase_ == 2; + } + + /** + * + * + *
                      +     * MCP tools view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + * + * @return The mcpToolView. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView getMcpToolView() { + if (mcpToolViewBuilder_ == null) { + if (viewCase_ == 2) { + return (com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) view_; + } + return com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + .getDefaultInstance(); + } else { + if (viewCase_ == 2) { + return mcpToolViewBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + .getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * MCP tools view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + */ + public Builder setMcpToolView( + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView value) { + if (mcpToolViewBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + view_ = value; + onChanged(); + } else { + mcpToolViewBuilder_.setMessage(value); + } + viewCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * MCP tools view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + */ + public Builder setMcpToolView( + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView.Builder + builderForValue) { + if (mcpToolViewBuilder_ == null) { + view_ = builderForValue.build(); + onChanged(); + } else { + mcpToolViewBuilder_.setMessage(builderForValue.build()); + } + viewCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * MCP tools view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + */ + public Builder mergeMcpToolView( + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView value) { + if (mcpToolViewBuilder_ == null) { + if (viewCase_ == 2 + && view_ + != com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + .getDefaultInstance()) { + view_ = + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView.newBuilder( + (com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) view_) + .mergeFrom(value) + .buildPartial(); + } else { + view_ = value; + } + onChanged(); + } else { + if (viewCase_ == 2) { + mcpToolViewBuilder_.mergeFrom(value); + } else { + mcpToolViewBuilder_.setMessage(value); + } + } + viewCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * MCP tools view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + */ + public Builder clearMcpToolView() { + if (mcpToolViewBuilder_ == null) { + if (viewCase_ == 2) { + viewCase_ = 0; + view_ = null; + onChanged(); + } + } else { + if (viewCase_ == 2) { + viewCase_ = 0; + view_ = null; + } + mcpToolViewBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * MCP tools view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + */ + public com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView.Builder + getMcpToolViewBuilder() { + return internalGetMcpToolViewFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * MCP tools view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentViewOrBuilder + getMcpToolViewOrBuilder() { + if ((viewCase_ == 2) && (mcpToolViewBuilder_ != null)) { + return mcpToolViewBuilder_.getMessageOrBuilder(); + } else { + if (viewCase_ == 2) { + return (com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) view_; + } + return com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + .getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * MCP tools view.
                      +     * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView, + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView.Builder, + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentViewOrBuilder> + internalGetMcpToolViewFieldBuilder() { + if (mcpToolViewBuilder_ == null) { + if (!(viewCase_ == 2)) { + view_ = + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + .getDefaultInstance(); + } + mcpToolViewBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView, + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView.Builder, + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentViewOrBuilder>( + (com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) view_, + getParentForChildren(), + isClean()); + view_ = null; + } + viewCase_ = 2; + onChanged(); + return mcpToolViewBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ApiView) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ApiView) + private static final com.google.cloud.apihub.v1.ApiView DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ApiView(); + } + + public static com.google.cloud.apihub.v1.ApiView getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ApiView parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApiView getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiViewOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiViewOrBuilder.java new file mode 100644 index 000000000000..46c4bdb7be06 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiViewOrBuilder.java @@ -0,0 +1,108 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ApiViewOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ApiView) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * MCP server view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + * + * @return Whether the mcpServerView field is set. + */ + boolean hasMcpServerView(); + + /** + * + * + *
                      +   * MCP server view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + * + * @return The mcpServerView. + */ + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView getMcpServerView(); + + /** + * + * + *
                      +   * MCP server view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionDeploymentView mcp_server_view = 1; + */ + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentViewOrBuilder getMcpServerViewOrBuilder(); + + /** + * + * + *
                      +   * MCP tools view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + * + * @return Whether the mcpToolView field is set. + */ + boolean hasMcpToolView(); + + /** + * + * + *
                      +   * MCP tools view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + * + * @return The mcpToolView. + */ + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView getMcpToolView(); + + /** + * + * + *
                      +   * MCP tools view.
                      +   * 
                      + * + * .google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + * + */ + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentViewOrBuilder + getMcpToolViewOrBuilder(); + + com.google.cloud.apihub.v1.ApiView.ViewCase getViewCase(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiViewType.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiViewType.java new file mode 100644 index 000000000000..20733197e218 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApiViewType.java @@ -0,0 +1,191 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The view type of API.
                      + * 
                      + * + * Protobuf enum {@code google.cloud.apihub.v1.ApiViewType} + */ +@com.google.protobuf.Generated +public enum ApiViewType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                      +   * The default view type.
                      +   * 
                      + * + * API_VIEW_TYPE_UNSPECIFIED = 0; + */ + API_VIEW_TYPE_UNSPECIFIED(0), + /** + * + * + *
                      +   * The MCP server view in API hub.
                      +   * 
                      + * + * MCP_SERVER = 1; + */ + MCP_SERVER(1), + /** + * + * + *
                      +   * The MCP tool view in API hub.
                      +   * 
                      + * + * MCP_TOOL = 2; + */ + MCP_TOOL(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ApiViewType"); + } + + /** + * + * + *
                      +   * The default view type.
                      +   * 
                      + * + * API_VIEW_TYPE_UNSPECIFIED = 0; + */ + public static final int API_VIEW_TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                      +   * The MCP server view in API hub.
                      +   * 
                      + * + * MCP_SERVER = 1; + */ + public static final int MCP_SERVER_VALUE = 1; + + /** + * + * + *
                      +   * The MCP tool view in API hub.
                      +   * 
                      + * + * MCP_TOOL = 2; + */ + public static final int MCP_TOOL_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ApiViewType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static ApiViewType forNumber(int value) { + switch (value) { + case 0: + return API_VIEW_TYPE_UNSPECIFIED; + case 1: + return MCP_SERVER; + case 2: + return MCP_TOOL; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public ApiViewType findValueByNumber(int number) { + return ApiViewType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto.getDescriptor().getEnumTypes().get(0); + } + + private static final ApiViewType[] VALUES = values(); + + public static ApiViewType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private ApiViewType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.apihub.v1.ApiViewType) +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeEdgeConfig.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeEdgeConfig.java new file mode 100644 index 000000000000..7115bb710587 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeEdgeConfig.java @@ -0,0 +1,756 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Configuration for Apigee Edge gateways. Applicability of a
                      + * filter is determined by the filter being provided. If none of the filters are
                      + * provided the addon will be enabled for all data brought in by the gateway
                      + * plugin instance.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApigeeEdgeConfig} + */ +@com.google.protobuf.Generated +public final class ApigeeEdgeConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ApigeeEdgeConfig) + ApigeeEdgeConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ApigeeEdgeConfig"); + } + + // Use ApigeeEdgeConfig.newBuilder() to construct. + private ApigeeEdgeConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ApigeeEdgeConfig() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeEdgeConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeEdgeConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApigeeEdgeConfig.class, + com.google.cloud.apihub.v1.ApigeeEdgeConfig.Builder.class); + } + + private int bitField0_; + public static final int ENVIRONMENT_FILTER_FIELD_NUMBER = 1; + private com.google.cloud.apihub.v1.EnvironmentFilter environmentFilter_; + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the environmentFilter field is set. + */ + @java.lang.Override + public boolean hasEnvironmentFilter() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The environmentFilter. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.EnvironmentFilter getEnvironmentFilter() { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder getEnvironmentFilterOrBuilder() { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getEnvironmentFilter()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getEnvironmentFilter()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ApigeeEdgeConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ApigeeEdgeConfig other = + (com.google.cloud.apihub.v1.ApigeeEdgeConfig) obj; + + if (hasEnvironmentFilter() != other.hasEnvironmentFilter()) return false; + if (hasEnvironmentFilter()) { + if (!getEnvironmentFilter().equals(other.getEnvironmentFilter())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasEnvironmentFilter()) { + hash = (37 * hash) + ENVIRONMENT_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getEnvironmentFilter().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.ApigeeEdgeConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Configuration for Apigee Edge gateways. Applicability of a
                      +   * filter is determined by the filter being provided. If none of the filters are
                      +   * provided the addon will be enabled for all data brought in by the gateway
                      +   * plugin instance.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApigeeEdgeConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ApigeeEdgeConfig) + com.google.cloud.apihub.v1.ApigeeEdgeConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeEdgeConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeEdgeConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApigeeEdgeConfig.class, + com.google.cloud.apihub.v1.ApigeeEdgeConfig.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ApigeeEdgeConfig.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetEnvironmentFilterFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + environmentFilter_ = null; + if (environmentFilterBuilder_ != null) { + environmentFilterBuilder_.dispose(); + environmentFilterBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeEdgeConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeEdgeConfig getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ApigeeEdgeConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeEdgeConfig build() { + com.google.cloud.apihub.v1.ApigeeEdgeConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeEdgeConfig buildPartial() { + com.google.cloud.apihub.v1.ApigeeEdgeConfig result = + new com.google.cloud.apihub.v1.ApigeeEdgeConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.ApigeeEdgeConfig result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.environmentFilter_ = + environmentFilterBuilder_ == null + ? environmentFilter_ + : environmentFilterBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ApigeeEdgeConfig) { + return mergeFrom((com.google.cloud.apihub.v1.ApigeeEdgeConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ApigeeEdgeConfig other) { + if (other == com.google.cloud.apihub.v1.ApigeeEdgeConfig.getDefaultInstance()) return this; + if (other.hasEnvironmentFilter()) { + mergeEnvironmentFilter(other.getEnvironmentFilter()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetEnvironmentFilterFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.apihub.v1.EnvironmentFilter environmentFilter_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.EnvironmentFilter, + com.google.cloud.apihub.v1.EnvironmentFilter.Builder, + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder> + environmentFilterBuilder_; + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the environmentFilter field is set. + */ + public boolean hasEnvironmentFilter() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The environmentFilter. + */ + public com.google.cloud.apihub.v1.EnvironmentFilter getEnvironmentFilter() { + if (environmentFilterBuilder_ == null) { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } else { + return environmentFilterBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setEnvironmentFilter(com.google.cloud.apihub.v1.EnvironmentFilter value) { + if (environmentFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + environmentFilter_ = value; + } else { + environmentFilterBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setEnvironmentFilter( + com.google.cloud.apihub.v1.EnvironmentFilter.Builder builderForValue) { + if (environmentFilterBuilder_ == null) { + environmentFilter_ = builderForValue.build(); + } else { + environmentFilterBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeEnvironmentFilter(com.google.cloud.apihub.v1.EnvironmentFilter value) { + if (environmentFilterBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && environmentFilter_ != null + && environmentFilter_ + != com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance()) { + getEnvironmentFilterBuilder().mergeFrom(value); + } else { + environmentFilter_ = value; + } + } else { + environmentFilterBuilder_.mergeFrom(value); + } + if (environmentFilter_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearEnvironmentFilter() { + bitField0_ = (bitField0_ & ~0x00000001); + environmentFilter_ = null; + if (environmentFilterBuilder_ != null) { + environmentFilterBuilder_.dispose(); + environmentFilterBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.EnvironmentFilter.Builder getEnvironmentFilterBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetEnvironmentFilterFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder getEnvironmentFilterOrBuilder() { + if (environmentFilterBuilder_ != null) { + return environmentFilterBuilder_.getMessageOrBuilder(); + } else { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.EnvironmentFilter, + com.google.cloud.apihub.v1.EnvironmentFilter.Builder, + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder> + internalGetEnvironmentFilterFieldBuilder() { + if (environmentFilterBuilder_ == null) { + environmentFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.EnvironmentFilter, + com.google.cloud.apihub.v1.EnvironmentFilter.Builder, + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder>( + getEnvironmentFilter(), getParentForChildren(), isClean()); + environmentFilter_ = null; + } + return environmentFilterBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ApigeeEdgeConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ApigeeEdgeConfig) + private static final com.google.cloud.apihub.v1.ApigeeEdgeConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ApigeeEdgeConfig(); + } + + public static com.google.cloud.apihub.v1.ApigeeEdgeConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ApigeeEdgeConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeEdgeConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeEdgeConfigOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeEdgeConfigOrBuilder.java new file mode 100644 index 000000000000..8efc4f050688 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeEdgeConfigOrBuilder.java @@ -0,0 +1,77 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ApigeeEdgeConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ApigeeEdgeConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the environmentFilter field is set. + */ + boolean hasEnvironmentFilter(); + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The environmentFilter. + */ + com.google.cloud.apihub.v1.EnvironmentFilter getEnvironmentFilter(); + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder getEnvironmentFilterOrBuilder(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeOPDKConfig.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeOPDKConfig.java new file mode 100644 index 000000000000..9bc9b658bd15 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeOPDKConfig.java @@ -0,0 +1,756 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Configuration for Apigee OPDK gateways. Applicability of a
                      + * filter is determined by the filter being provided. If none of the filters are
                      + * provided the addon will be enabled for all data brought in by the gateway
                      + * plugin instance.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApigeeOPDKConfig} + */ +@com.google.protobuf.Generated +public final class ApigeeOPDKConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ApigeeOPDKConfig) + ApigeeOPDKConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ApigeeOPDKConfig"); + } + + // Use ApigeeOPDKConfig.newBuilder() to construct. + private ApigeeOPDKConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ApigeeOPDKConfig() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeOPDKConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeOPDKConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApigeeOPDKConfig.class, + com.google.cloud.apihub.v1.ApigeeOPDKConfig.Builder.class); + } + + private int bitField0_; + public static final int ENVIRONMENT_FILTER_FIELD_NUMBER = 1; + private com.google.cloud.apihub.v1.EnvironmentFilter environmentFilter_; + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the environmentFilter field is set. + */ + @java.lang.Override + public boolean hasEnvironmentFilter() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The environmentFilter. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.EnvironmentFilter getEnvironmentFilter() { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder getEnvironmentFilterOrBuilder() { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getEnvironmentFilter()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getEnvironmentFilter()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ApigeeOPDKConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ApigeeOPDKConfig other = + (com.google.cloud.apihub.v1.ApigeeOPDKConfig) obj; + + if (hasEnvironmentFilter() != other.hasEnvironmentFilter()) return false; + if (hasEnvironmentFilter()) { + if (!getEnvironmentFilter().equals(other.getEnvironmentFilter())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasEnvironmentFilter()) { + hash = (37 * hash) + ENVIRONMENT_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getEnvironmentFilter().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.ApigeeOPDKConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Configuration for Apigee OPDK gateways. Applicability of a
                      +   * filter is determined by the filter being provided. If none of the filters are
                      +   * provided the addon will be enabled for all data brought in by the gateway
                      +   * plugin instance.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApigeeOPDKConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ApigeeOPDKConfig) + com.google.cloud.apihub.v1.ApigeeOPDKConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeOPDKConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeOPDKConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApigeeOPDKConfig.class, + com.google.cloud.apihub.v1.ApigeeOPDKConfig.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ApigeeOPDKConfig.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetEnvironmentFilterFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + environmentFilter_ = null; + if (environmentFilterBuilder_ != null) { + environmentFilterBuilder_.dispose(); + environmentFilterBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeOPDKConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeOPDKConfig getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ApigeeOPDKConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeOPDKConfig build() { + com.google.cloud.apihub.v1.ApigeeOPDKConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeOPDKConfig buildPartial() { + com.google.cloud.apihub.v1.ApigeeOPDKConfig result = + new com.google.cloud.apihub.v1.ApigeeOPDKConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.ApigeeOPDKConfig result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.environmentFilter_ = + environmentFilterBuilder_ == null + ? environmentFilter_ + : environmentFilterBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ApigeeOPDKConfig) { + return mergeFrom((com.google.cloud.apihub.v1.ApigeeOPDKConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ApigeeOPDKConfig other) { + if (other == com.google.cloud.apihub.v1.ApigeeOPDKConfig.getDefaultInstance()) return this; + if (other.hasEnvironmentFilter()) { + mergeEnvironmentFilter(other.getEnvironmentFilter()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetEnvironmentFilterFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.apihub.v1.EnvironmentFilter environmentFilter_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.EnvironmentFilter, + com.google.cloud.apihub.v1.EnvironmentFilter.Builder, + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder> + environmentFilterBuilder_; + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the environmentFilter field is set. + */ + public boolean hasEnvironmentFilter() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The environmentFilter. + */ + public com.google.cloud.apihub.v1.EnvironmentFilter getEnvironmentFilter() { + if (environmentFilterBuilder_ == null) { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } else { + return environmentFilterBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setEnvironmentFilter(com.google.cloud.apihub.v1.EnvironmentFilter value) { + if (environmentFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + environmentFilter_ = value; + } else { + environmentFilterBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setEnvironmentFilter( + com.google.cloud.apihub.v1.EnvironmentFilter.Builder builderForValue) { + if (environmentFilterBuilder_ == null) { + environmentFilter_ = builderForValue.build(); + } else { + environmentFilterBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeEnvironmentFilter(com.google.cloud.apihub.v1.EnvironmentFilter value) { + if (environmentFilterBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && environmentFilter_ != null + && environmentFilter_ + != com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance()) { + getEnvironmentFilterBuilder().mergeFrom(value); + } else { + environmentFilter_ = value; + } + } else { + environmentFilterBuilder_.mergeFrom(value); + } + if (environmentFilter_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearEnvironmentFilter() { + bitField0_ = (bitField0_ & ~0x00000001); + environmentFilter_ = null; + if (environmentFilterBuilder_ != null) { + environmentFilterBuilder_.dispose(); + environmentFilterBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.EnvironmentFilter.Builder getEnvironmentFilterBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetEnvironmentFilterFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder getEnvironmentFilterOrBuilder() { + if (environmentFilterBuilder_ != null) { + return environmentFilterBuilder_.getMessageOrBuilder(); + } else { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.EnvironmentFilter, + com.google.cloud.apihub.v1.EnvironmentFilter.Builder, + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder> + internalGetEnvironmentFilterFieldBuilder() { + if (environmentFilterBuilder_ == null) { + environmentFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.EnvironmentFilter, + com.google.cloud.apihub.v1.EnvironmentFilter.Builder, + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder>( + getEnvironmentFilter(), getParentForChildren(), isClean()); + environmentFilter_ = null; + } + return environmentFilterBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ApigeeOPDKConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ApigeeOPDKConfig) + private static final com.google.cloud.apihub.v1.ApigeeOPDKConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ApigeeOPDKConfig(); + } + + public static com.google.cloud.apihub.v1.ApigeeOPDKConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ApigeeOPDKConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeOPDKConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeOPDKConfigOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeOPDKConfigOrBuilder.java new file mode 100644 index 000000000000..deeeba4ab8d4 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeOPDKConfigOrBuilder.java @@ -0,0 +1,77 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ApigeeOPDKConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ApigeeOPDKConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the environmentFilter field is set. + */ + boolean hasEnvironmentFilter(); + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The environmentFilter. + */ + com.google.cloud.apihub.v1.EnvironmentFilter getEnvironmentFilter(); + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder getEnvironmentFilterOrBuilder(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXHybridConfig.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXHybridConfig.java new file mode 100644 index 000000000000..5ff4901cff7e --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXHybridConfig.java @@ -0,0 +1,756 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Configuration for Apigee X and Apigee Hybrid gateways. Applicability of a
                      + * filter is determined by the filter being provided. If none of the filters are
                      + * provided the addon will be enabled for all data brought in by the gateway
                      + * plugin instance.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApigeeXHybridConfig} + */ +@com.google.protobuf.Generated +public final class ApigeeXHybridConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ApigeeXHybridConfig) + ApigeeXHybridConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ApigeeXHybridConfig"); + } + + // Use ApigeeXHybridConfig.newBuilder() to construct. + private ApigeeXHybridConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ApigeeXHybridConfig() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXHybridConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXHybridConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApigeeXHybridConfig.class, + com.google.cloud.apihub.v1.ApigeeXHybridConfig.Builder.class); + } + + private int bitField0_; + public static final int ENVIRONMENT_FILTER_FIELD_NUMBER = 1; + private com.google.cloud.apihub.v1.EnvironmentFilter environmentFilter_; + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the environmentFilter field is set. + */ + @java.lang.Override + public boolean hasEnvironmentFilter() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The environmentFilter. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.EnvironmentFilter getEnvironmentFilter() { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder getEnvironmentFilterOrBuilder() { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getEnvironmentFilter()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getEnvironmentFilter()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ApigeeXHybridConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ApigeeXHybridConfig other = + (com.google.cloud.apihub.v1.ApigeeXHybridConfig) obj; + + if (hasEnvironmentFilter() != other.hasEnvironmentFilter()) return false; + if (hasEnvironmentFilter()) { + if (!getEnvironmentFilter().equals(other.getEnvironmentFilter())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasEnvironmentFilter()) { + hash = (37 * hash) + ENVIRONMENT_FILTER_FIELD_NUMBER; + hash = (53 * hash) + getEnvironmentFilter().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.ApigeeXHybridConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Configuration for Apigee X and Apigee Hybrid gateways. Applicability of a
                      +   * filter is determined by the filter being provided. If none of the filters are
                      +   * provided the addon will be enabled for all data brought in by the gateway
                      +   * plugin instance.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApigeeXHybridConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ApigeeXHybridConfig) + com.google.cloud.apihub.v1.ApigeeXHybridConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXHybridConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXHybridConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApigeeXHybridConfig.class, + com.google.cloud.apihub.v1.ApigeeXHybridConfig.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ApigeeXHybridConfig.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetEnvironmentFilterFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + environmentFilter_ = null; + if (environmentFilterBuilder_ != null) { + environmentFilterBuilder_.dispose(); + environmentFilterBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXHybridConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXHybridConfig getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ApigeeXHybridConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXHybridConfig build() { + com.google.cloud.apihub.v1.ApigeeXHybridConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXHybridConfig buildPartial() { + com.google.cloud.apihub.v1.ApigeeXHybridConfig result = + new com.google.cloud.apihub.v1.ApigeeXHybridConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.ApigeeXHybridConfig result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.environmentFilter_ = + environmentFilterBuilder_ == null + ? environmentFilter_ + : environmentFilterBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ApigeeXHybridConfig) { + return mergeFrom((com.google.cloud.apihub.v1.ApigeeXHybridConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ApigeeXHybridConfig other) { + if (other == com.google.cloud.apihub.v1.ApigeeXHybridConfig.getDefaultInstance()) return this; + if (other.hasEnvironmentFilter()) { + mergeEnvironmentFilter(other.getEnvironmentFilter()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetEnvironmentFilterFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.apihub.v1.EnvironmentFilter environmentFilter_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.EnvironmentFilter, + com.google.cloud.apihub.v1.EnvironmentFilter.Builder, + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder> + environmentFilterBuilder_; + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the environmentFilter field is set. + */ + public boolean hasEnvironmentFilter() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The environmentFilter. + */ + public com.google.cloud.apihub.v1.EnvironmentFilter getEnvironmentFilter() { + if (environmentFilterBuilder_ == null) { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } else { + return environmentFilterBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setEnvironmentFilter(com.google.cloud.apihub.v1.EnvironmentFilter value) { + if (environmentFilterBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + environmentFilter_ = value; + } else { + environmentFilterBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setEnvironmentFilter( + com.google.cloud.apihub.v1.EnvironmentFilter.Builder builderForValue) { + if (environmentFilterBuilder_ == null) { + environmentFilter_ = builderForValue.build(); + } else { + environmentFilterBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeEnvironmentFilter(com.google.cloud.apihub.v1.EnvironmentFilter value) { + if (environmentFilterBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && environmentFilter_ != null + && environmentFilter_ + != com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance()) { + getEnvironmentFilterBuilder().mergeFrom(value); + } else { + environmentFilter_ = value; + } + } else { + environmentFilterBuilder_.mergeFrom(value); + } + if (environmentFilter_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearEnvironmentFilter() { + bitField0_ = (bitField0_ & ~0x00000001); + environmentFilter_ = null; + if (environmentFilterBuilder_ != null) { + environmentFilterBuilder_.dispose(); + environmentFilterBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.EnvironmentFilter.Builder getEnvironmentFilterBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetEnvironmentFilterFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder getEnvironmentFilterOrBuilder() { + if (environmentFilterBuilder_ != null) { + return environmentFilterBuilder_.getMessageOrBuilder(); + } else { + return environmentFilter_ == null + ? com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance() + : environmentFilter_; + } + } + + /** + * + * + *
                      +     * Optional. The filter to apply on the resources managed by the gateway
                      +     * plugin instance. If provided this filter applies environment specific
                      +     * filtering.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.EnvironmentFilter, + com.google.cloud.apihub.v1.EnvironmentFilter.Builder, + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder> + internalGetEnvironmentFilterFieldBuilder() { + if (environmentFilterBuilder_ == null) { + environmentFilterBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.EnvironmentFilter, + com.google.cloud.apihub.v1.EnvironmentFilter.Builder, + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder>( + getEnvironmentFilter(), getParentForChildren(), isClean()); + environmentFilter_ = null; + } + return environmentFilterBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ApigeeXHybridConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ApigeeXHybridConfig) + private static final com.google.cloud.apihub.v1.ApigeeXHybridConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ApigeeXHybridConfig(); + } + + public static com.google.cloud.apihub.v1.ApigeeXHybridConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ApigeeXHybridConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXHybridConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXHybridConfigOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXHybridConfigOrBuilder.java new file mode 100644 index 000000000000..54725a05ebd0 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXHybridConfigOrBuilder.java @@ -0,0 +1,77 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ApigeeXHybridConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ApigeeXHybridConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the environmentFilter field is set. + */ + boolean hasEnvironmentFilter(); + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The environmentFilter. + */ + com.google.cloud.apihub.v1.EnvironmentFilter getEnvironmentFilter(); + + /** + * + * + *
                      +   * Optional. The filter to apply on the resources managed by the gateway
                      +   * plugin instance. If provided this filter applies environment specific
                      +   * filtering.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.EnvironmentFilter environment_filter = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder getEnvironmentFilterOrBuilder(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXTargetDetails.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXTargetDetails.java new file mode 100644 index 000000000000..cd263664a68b --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXTargetDetails.java @@ -0,0 +1,2350 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The target configuration for Apigee X.
                      + * Note: If this API is called while an earlier deployment is still in
                      + * progress, the earlier deployment will be aborted and a new deployment will
                      + * be triggered.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApigeeXTargetDetails} + */ +@com.google.protobuf.Generated +public final class ApigeeXTargetDetails extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ApigeeXTargetDetails) + ApigeeXTargetDetailsOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ApigeeXTargetDetails"); + } + + // Use ApigeeXTargetDetails.newBuilder() to construct. + private ApigeeXTargetDetails(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ApigeeXTargetDetails() { + environment_ = ""; + proxy_ = ""; + targetProject_ = ""; + deployedRevision_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApigeeXTargetDetails.class, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder.class); + } + + public interface MetaDataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +     * Optional. Display name for the server. For apigee target, this will be
                      +     * used as revision display name.
                      +     * 
                      + * + * string display_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
                      +     * Optional. Display name for the server. For apigee target, this will be
                      +     * used as revision display name.
                      +     * 
                      + * + * string display_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
                      +     * Optional. Description for the server. For apigee target, this will be
                      +     * used as revision description.
                      +     * 
                      + * + * string description = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
                      +     * Optional. Description for the server. For apigee target, this will be
                      +     * used as revision description.
                      +     * 
                      + * + * string description = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + } + + /** + * + * + *
                      +   * Metadata for the server configuration in Apigee X.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData} + */ + public static final class MetaData extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData) + MetaDataOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "MetaData"); + } + + // Use MetaData.newBuilder() to construct. + private MetaData(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private MetaData() { + displayName_ = ""; + description_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_MetaData_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_MetaData_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.class, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.Builder.class); + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object displayName_ = ""; + + /** + * + * + *
                      +     * Optional. Display name for the server. For apigee target, this will be
                      +     * used as revision display name.
                      +     * 
                      + * + * string display_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + + /** + * + * + *
                      +     * Optional. Display name for the server. For apigee target, this will be
                      +     * used as revision display name.
                      +     * 
                      + * + * string display_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object description_ = ""; + + /** + * + * + *
                      +     * Optional. Description for the server. For apigee target, this will be
                      +     * used as revision description.
                      +     * 
                      + * + * string description = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + + /** + * + * + *
                      +     * Optional. Description for the server. For apigee target, this will be
                      +     * used as revision description.
                      +     * 
                      + * + * string description = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, displayName_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, description_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, displayName_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, description_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData other = + (com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData) obj; + + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +     * Metadata for the server configuration in Apigee X.
                      +     * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData) + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaDataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_MetaData_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_MetaData_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.class, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + displayName_ = ""; + description_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_MetaData_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData build() { + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData buildPartial() { + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData result = + new com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.displayName_ = displayName_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.description_ = description_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData) { + return mergeFrom((com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData other) { + if (other == com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.getDefaultInstance()) + return this; + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object displayName_ = ""; + + /** + * + * + *
                      +       * Optional. Display name for the server. For apigee target, this will be
                      +       * used as revision display name.
                      +       * 
                      + * + * string display_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +       * Optional. Display name for the server. For apigee target, this will be
                      +       * used as revision display name.
                      +       * 
                      + * + * string display_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +       * Optional. Display name for the server. For apigee target, this will be
                      +       * used as revision display name.
                      +       * 
                      + * + * string display_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + displayName_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Optional. Display name for the server. For apigee target, this will be
                      +       * used as revision display name.
                      +       * 
                      + * + * string display_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + displayName_ = getDefaultInstance().getDisplayName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Optional. Display name for the server. For apigee target, this will be
                      +       * used as revision display name.
                      +       * 
                      + * + * string display_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + displayName_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + + /** + * + * + *
                      +       * Optional. Description for the server. For apigee target, this will be
                      +       * used as revision description.
                      +       * 
                      + * + * string description = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +       * Optional. Description for the server. For apigee target, this will be
                      +       * used as revision description.
                      +       * 
                      + * + * string description = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +       * Optional. Description for the server. For apigee target, this will be
                      +       * used as revision description.
                      +       * 
                      + * + * string description = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + description_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Optional. Description for the server. For apigee target, this will be
                      +       * used as revision description.
                      +       * 
                      + * + * string description = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + description_ = getDefaultInstance().getDescription(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Optional. Description for the server. For apigee target, this will be
                      +       * used as revision description.
                      +       * 
                      + * + * string description = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData) + private static final com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData(); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public MetaData parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int ENVIRONMENT_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object environment_ = ""; + + /** + * + * + *
                      +   * Required. The specific Apigee environment where the server will be
                      +   * deployed.
                      +   * 
                      + * + * string environment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The environment. + */ + @java.lang.Override + public java.lang.String getEnvironment() { + java.lang.Object ref = environment_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + environment_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The specific Apigee environment where the server will be
                      +   * deployed.
                      +   * 
                      + * + * string environment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for environment. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEnvironmentBytes() { + java.lang.Object ref = environment_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + environment_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PROXY_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object proxy_ = ""; + + /** + * + * + *
                      +   * Required. This name identifies the proxy resource in Apigee. It typically
                      +   * follows a standard alphanumeric format (e.g., "mcp-discovery-server").
                      +   * 
                      + * + * string proxy = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The proxy. + */ + @java.lang.Override + public java.lang.String getProxy() { + java.lang.Object ref = proxy_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + proxy_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. This name identifies the proxy resource in Apigee. It typically
                      +   * follows a standard alphanumeric format (e.g., "mcp-discovery-server").
                      +   * 
                      + * + * string proxy = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for proxy. + */ + @java.lang.Override + public com.google.protobuf.ByteString getProxyBytes() { + java.lang.Object ref = proxy_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + proxy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TARGET_PROJECT_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object targetProject_ = ""; + + /** + * + * + *
                      +   * Required. The runtime project that hosts the Apigee X organization. This
                      +   * must be one of the runtime projects attached to the API Hub host project.
                      +   * 
                      + * + * string target_project = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The targetProject. + */ + @java.lang.Override + public java.lang.String getTargetProject() { + java.lang.Object ref = targetProject_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + targetProject_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The runtime project that hosts the Apigee X organization. This
                      +   * must be one of the runtime projects attached to the API Hub host project.
                      +   * 
                      + * + * string target_project = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for targetProject. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTargetProjectBytes() { + java.lang.Object ref = targetProject_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + targetProject_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int METADATA_FIELD_NUMBER = 5; + private com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata_; + + /** + * + * + *
                      +   * Optional. Metadata for the proxy configuration in Apigee X.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the metadata field is set. + */ + @java.lang.Override + public boolean hasMetadata() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Optional. Metadata for the proxy configuration in Apigee X.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The metadata. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData getMetadata() { + return metadata_ == null + ? com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.getDefaultInstance() + : metadata_; + } + + /** + * + * + *
                      +   * Optional. Metadata for the proxy configuration in Apigee X.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaDataOrBuilder getMetadataOrBuilder() { + return metadata_ == null + ? com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.getDefaultInstance() + : metadata_; + } + + public static final int DEPLOYED_REVISION_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private volatile java.lang.Object deployedRevision_ = ""; + + /** + * + * + *
                      +   * Output only. The revision number of the Apigee proxy that was deployed.
                      +   * 
                      + * + * string deployed_revision = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The deployedRevision. + */ + @java.lang.Override + public java.lang.String getDeployedRevision() { + java.lang.Object ref = deployedRevision_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + deployedRevision_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Output only. The revision number of the Apigee proxy that was deployed.
                      +   * 
                      + * + * string deployed_revision = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for deployedRevision. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDeployedRevisionBytes() { + java.lang.Object ref = deployedRevision_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + deployedRevision_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(environment_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, environment_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(proxy_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, proxy_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(targetProject_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, targetProject_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getMetadata()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(deployedRevision_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, deployedRevision_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(environment_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, environment_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(proxy_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, proxy_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(targetProject_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, targetProject_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getMetadata()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(deployedRevision_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(6, deployedRevision_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ApigeeXTargetDetails)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ApigeeXTargetDetails other = + (com.google.cloud.apihub.v1.ApigeeXTargetDetails) obj; + + if (!getEnvironment().equals(other.getEnvironment())) return false; + if (!getProxy().equals(other.getProxy())) return false; + if (!getTargetProject().equals(other.getTargetProject())) return false; + if (hasMetadata() != other.hasMetadata()) return false; + if (hasMetadata()) { + if (!getMetadata().equals(other.getMetadata())) return false; + } + if (!getDeployedRevision().equals(other.getDeployedRevision())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ENVIRONMENT_FIELD_NUMBER; + hash = (53 * hash) + getEnvironment().hashCode(); + hash = (37 * hash) + PROXY_FIELD_NUMBER; + hash = (53 * hash) + getProxy().hashCode(); + hash = (37 * hash) + TARGET_PROJECT_FIELD_NUMBER; + hash = (53 * hash) + getTargetProject().hashCode(); + if (hasMetadata()) { + hash = (37 * hash) + METADATA_FIELD_NUMBER; + hash = (53 * hash) + getMetadata().hashCode(); + } + hash = (37 * hash) + DEPLOYED_REVISION_FIELD_NUMBER; + hash = (53 * hash) + getDeployedRevision().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.ApigeeXTargetDetails prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The target configuration for Apigee X.
                      +   * Note: If this API is called while an earlier deployment is still in
                      +   * progress, the earlier deployment will be aborted and a new deployment will
                      +   * be triggered.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ApigeeXTargetDetails} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ApigeeXTargetDetails) + com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ApigeeXTargetDetails.class, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ApigeeXTargetDetails.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetMetadataFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + environment_ = ""; + proxy_ = ""; + targetProject_ = ""; + metadata_ = null; + if (metadataBuilder_ != null) { + metadataBuilder_.dispose(); + metadataBuilder_ = null; + } + deployedRevision_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ApigeeXTargetDetails_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails build() { + com.google.cloud.apihub.v1.ApigeeXTargetDetails result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails buildPartial() { + com.google.cloud.apihub.v1.ApigeeXTargetDetails result = + new com.google.cloud.apihub.v1.ApigeeXTargetDetails(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.ApigeeXTargetDetails result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.environment_ = environment_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.proxy_ = proxy_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.targetProject_ = targetProject_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000008) != 0)) { + result.metadata_ = metadataBuilder_ == null ? metadata_ : metadataBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.deployedRevision_ = deployedRevision_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ApigeeXTargetDetails) { + return mergeFrom((com.google.cloud.apihub.v1.ApigeeXTargetDetails) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ApigeeXTargetDetails other) { + if (other == com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance()) + return this; + if (!other.getEnvironment().isEmpty()) { + environment_ = other.environment_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getProxy().isEmpty()) { + proxy_ = other.proxy_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getTargetProject().isEmpty()) { + targetProject_ = other.targetProject_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.hasMetadata()) { + mergeMetadata(other.getMetadata()); + } + if (!other.getDeployedRevision().isEmpty()) { + deployedRevision_ = other.deployedRevision_; + bitField0_ |= 0x00000010; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 18: + { + environment_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 18 + case 26: + { + proxy_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 26 + case 34: + { + targetProject_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 34 + case 42: + { + input.readMessage( + internalGetMetadataFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 42 + case 50: + { + deployedRevision_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 50 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object environment_ = ""; + + /** + * + * + *
                      +     * Required. The specific Apigee environment where the server will be
                      +     * deployed.
                      +     * 
                      + * + * string environment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The environment. + */ + public java.lang.String getEnvironment() { + java.lang.Object ref = environment_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + environment_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The specific Apigee environment where the server will be
                      +     * deployed.
                      +     * 
                      + * + * string environment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for environment. + */ + public com.google.protobuf.ByteString getEnvironmentBytes() { + java.lang.Object ref = environment_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + environment_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The specific Apigee environment where the server will be
                      +     * deployed.
                      +     * 
                      + * + * string environment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The environment to set. + * @return This builder for chaining. + */ + public Builder setEnvironment(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + environment_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The specific Apigee environment where the server will be
                      +     * deployed.
                      +     * 
                      + * + * string environment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearEnvironment() { + environment_ = getDefaultInstance().getEnvironment(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The specific Apigee environment where the server will be
                      +     * deployed.
                      +     * 
                      + * + * string environment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for environment to set. + * @return This builder for chaining. + */ + public Builder setEnvironmentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + environment_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object proxy_ = ""; + + /** + * + * + *
                      +     * Required. This name identifies the proxy resource in Apigee. It typically
                      +     * follows a standard alphanumeric format (e.g., "mcp-discovery-server").
                      +     * 
                      + * + * string proxy = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The proxy. + */ + public java.lang.String getProxy() { + java.lang.Object ref = proxy_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + proxy_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. This name identifies the proxy resource in Apigee. It typically
                      +     * follows a standard alphanumeric format (e.g., "mcp-discovery-server").
                      +     * 
                      + * + * string proxy = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for proxy. + */ + public com.google.protobuf.ByteString getProxyBytes() { + java.lang.Object ref = proxy_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + proxy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. This name identifies the proxy resource in Apigee. It typically
                      +     * follows a standard alphanumeric format (e.g., "mcp-discovery-server").
                      +     * 
                      + * + * string proxy = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The proxy to set. + * @return This builder for chaining. + */ + public Builder setProxy(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + proxy_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. This name identifies the proxy resource in Apigee. It typically
                      +     * follows a standard alphanumeric format (e.g., "mcp-discovery-server").
                      +     * 
                      + * + * string proxy = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearProxy() { + proxy_ = getDefaultInstance().getProxy(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. This name identifies the proxy resource in Apigee. It typically
                      +     * follows a standard alphanumeric format (e.g., "mcp-discovery-server").
                      +     * 
                      + * + * string proxy = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for proxy to set. + * @return This builder for chaining. + */ + public Builder setProxyBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + proxy_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object targetProject_ = ""; + + /** + * + * + *
                      +     * Required. The runtime project that hosts the Apigee X organization. This
                      +     * must be one of the runtime projects attached to the API Hub host project.
                      +     * 
                      + * + * string target_project = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The targetProject. + */ + public java.lang.String getTargetProject() { + java.lang.Object ref = targetProject_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + targetProject_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The runtime project that hosts the Apigee X organization. This
                      +     * must be one of the runtime projects attached to the API Hub host project.
                      +     * 
                      + * + * string target_project = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for targetProject. + */ + public com.google.protobuf.ByteString getTargetProjectBytes() { + java.lang.Object ref = targetProject_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + targetProject_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The runtime project that hosts the Apigee X organization. This
                      +     * must be one of the runtime projects attached to the API Hub host project.
                      +     * 
                      + * + * string target_project = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The targetProject to set. + * @return This builder for chaining. + */ + public Builder setTargetProject(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + targetProject_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The runtime project that hosts the Apigee X organization. This
                      +     * must be one of the runtime projects attached to the API Hub host project.
                      +     * 
                      + * + * string target_project = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearTargetProject() { + targetProject_ = getDefaultInstance().getTargetProject(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The runtime project that hosts the Apigee X organization. This
                      +     * must be one of the runtime projects attached to the API Hub host project.
                      +     * 
                      + * + * string target_project = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for targetProject to set. + * @return This builder for chaining. + */ + public Builder setTargetProjectBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + targetProject_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.Builder, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaDataOrBuilder> + metadataBuilder_; + + /** + * + * + *
                      +     * Optional. Metadata for the proxy configuration in Apigee X.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the metadata field is set. + */ + public boolean hasMetadata() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
                      +     * Optional. Metadata for the proxy configuration in Apigee X.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The metadata. + */ + public com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData getMetadata() { + if (metadataBuilder_ == null) { + return metadata_ == null + ? com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.getDefaultInstance() + : metadata_; + } else { + return metadataBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. Metadata for the proxy configuration in Apigee X.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setMetadata(com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData value) { + if (metadataBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + metadata_ = value; + } else { + metadataBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Metadata for the proxy configuration in Apigee X.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setMetadata( + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.Builder builderForValue) { + if (metadataBuilder_ == null) { + metadata_ = builderForValue.build(); + } else { + metadataBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Metadata for the proxy configuration in Apigee X.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeMetadata(com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData value) { + if (metadataBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && metadata_ != null + && metadata_ + != com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.getDefaultInstance()) { + getMetadataBuilder().mergeFrom(value); + } else { + metadata_ = value; + } + } else { + metadataBuilder_.mergeFrom(value); + } + if (metadata_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. Metadata for the proxy configuration in Apigee X.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearMetadata() { + bitField0_ = (bitField0_ & ~0x00000008); + metadata_ = null; + if (metadataBuilder_ != null) { + metadataBuilder_.dispose(); + metadataBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Metadata for the proxy configuration in Apigee X.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.Builder getMetadataBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetMetadataFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. Metadata for the proxy configuration in Apigee X.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaDataOrBuilder + getMetadataOrBuilder() { + if (metadataBuilder_ != null) { + return metadataBuilder_.getMessageOrBuilder(); + } else { + return metadata_ == null + ? com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.getDefaultInstance() + : metadata_; + } + } + + /** + * + * + *
                      +     * Optional. Metadata for the proxy configuration in Apigee X.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.Builder, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaDataOrBuilder> + internalGetMetadataFieldBuilder() { + if (metadataBuilder_ == null) { + metadataBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData.Builder, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaDataOrBuilder>( + getMetadata(), getParentForChildren(), isClean()); + metadata_ = null; + } + return metadataBuilder_; + } + + private java.lang.Object deployedRevision_ = ""; + + /** + * + * + *
                      +     * Output only. The revision number of the Apigee proxy that was deployed.
                      +     * 
                      + * + * string deployed_revision = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The deployedRevision. + */ + public java.lang.String getDeployedRevision() { + java.lang.Object ref = deployedRevision_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + deployedRevision_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Output only. The revision number of the Apigee proxy that was deployed.
                      +     * 
                      + * + * string deployed_revision = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for deployedRevision. + */ + public com.google.protobuf.ByteString getDeployedRevisionBytes() { + java.lang.Object ref = deployedRevision_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + deployedRevision_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Output only. The revision number of the Apigee proxy that was deployed.
                      +     * 
                      + * + * string deployed_revision = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The deployedRevision to set. + * @return This builder for chaining. + */ + public Builder setDeployedRevision(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + deployedRevision_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The revision number of the Apigee proxy that was deployed.
                      +     * 
                      + * + * string deployed_revision = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearDeployedRevision() { + deployedRevision_ = getDefaultInstance().getDeployedRevision(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The revision number of the Apigee proxy that was deployed.
                      +     * 
                      + * + * string deployed_revision = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for deployedRevision to set. + * @return This builder for chaining. + */ + public Builder setDeployedRevisionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + deployedRevision_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ApigeeXTargetDetails) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ApigeeXTargetDetails) + private static final com.google.cloud.apihub.v1.ApigeeXTargetDetails DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ApigeeXTargetDetails(); + } + + public static com.google.cloud.apihub.v1.ApigeeXTargetDetails getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ApigeeXTargetDetails parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXTargetDetailsOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXTargetDetailsOrBuilder.java new file mode 100644 index 000000000000..b2c1fc045bc6 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ApigeeXTargetDetailsOrBuilder.java @@ -0,0 +1,181 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ApigeeXTargetDetailsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ApigeeXTargetDetails) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The specific Apigee environment where the server will be
                      +   * deployed.
                      +   * 
                      + * + * string environment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The environment. + */ + java.lang.String getEnvironment(); + + /** + * + * + *
                      +   * Required. The specific Apigee environment where the server will be
                      +   * deployed.
                      +   * 
                      + * + * string environment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for environment. + */ + com.google.protobuf.ByteString getEnvironmentBytes(); + + /** + * + * + *
                      +   * Required. This name identifies the proxy resource in Apigee. It typically
                      +   * follows a standard alphanumeric format (e.g., "mcp-discovery-server").
                      +   * 
                      + * + * string proxy = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The proxy. + */ + java.lang.String getProxy(); + + /** + * + * + *
                      +   * Required. This name identifies the proxy resource in Apigee. It typically
                      +   * follows a standard alphanumeric format (e.g., "mcp-discovery-server").
                      +   * 
                      + * + * string proxy = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for proxy. + */ + com.google.protobuf.ByteString getProxyBytes(); + + /** + * + * + *
                      +   * Required. The runtime project that hosts the Apigee X organization. This
                      +   * must be one of the runtime projects attached to the API Hub host project.
                      +   * 
                      + * + * string target_project = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The targetProject. + */ + java.lang.String getTargetProject(); + + /** + * + * + *
                      +   * Required. The runtime project that hosts the Apigee X organization. This
                      +   * must be one of the runtime projects attached to the API Hub host project.
                      +   * 
                      + * + * string target_project = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for targetProject. + */ + com.google.protobuf.ByteString getTargetProjectBytes(); + + /** + * + * + *
                      +   * Optional. Metadata for the proxy configuration in Apigee X.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the metadata field is set. + */ + boolean hasMetadata(); + + /** + * + * + *
                      +   * Optional. Metadata for the proxy configuration in Apigee X.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The metadata. + */ + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData getMetadata(); + + /** + * + * + *
                      +   * Optional. Metadata for the proxy configuration in Apigee X.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails.MetaData metadata = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.ApigeeXTargetDetails.MetaDataOrBuilder getMetadataOrBuilder(); + + /** + * + * + *
                      +   * Output only. The revision number of the Apigee proxy that was deployed.
                      +   * 
                      + * + * string deployed_revision = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The deployedRevision. + */ + java.lang.String getDeployedRevision(); + + /** + * + * + *
                      +   * Output only. The revision number of the Apigee proxy that was deployed.
                      +   * 
                      + * + * string deployed_revision = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for deployedRevision. + */ + com.google.protobuf.ByteString getDeployedRevisionBytes(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Attribute.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Attribute.java index 360ea43721fa..cff969d16b31 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Attribute.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Attribute.java @@ -813,8 +813,8 @@ public interface AllowedValueOrBuilder * will be used. In this case, the service will handle conflict resolution * by adding a system generated suffix in case of duplicates. * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. + * This value should be 3-500 characters, and valid characters + * are /[a-z][A-Z][0-9]-_/. *
                      * * string id = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -835,8 +835,8 @@ public interface AllowedValueOrBuilder * will be used. In this case, the service will handle conflict resolution * by adding a system generated suffix in case of duplicates. * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. + * This value should be 3-500 characters, and valid characters + * are /[a-z][A-Z][0-9]-_/. *
                      * * string id = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -981,8 +981,8 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * will be used. In this case, the service will handle conflict resolution * by adding a system generated suffix in case of duplicates. * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. + * This value should be 3-500 characters, and valid characters + * are /[a-z][A-Z][0-9]-_/. *
                      * * string id = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -1014,8 +1014,8 @@ public java.lang.String getId() { * will be used. In this case, the service will handle conflict resolution * by adding a system generated suffix in case of duplicates. * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. + * This value should be 3-500 characters, and valid characters + * are /[a-z][A-Z][0-9]-_/. *
                      * * string id = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -1556,8 +1556,8 @@ public Builder mergeFrom( * will be used. In this case, the service will handle conflict resolution * by adding a system generated suffix in case of duplicates. * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. + * This value should be 3-500 characters, and valid characters + * are /[a-z][A-Z][0-9]-_/. *
                      * * string id = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -1588,8 +1588,8 @@ public java.lang.String getId() { * will be used. In this case, the service will handle conflict resolution * by adding a system generated suffix in case of duplicates. * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. + * This value should be 3-500 characters, and valid characters + * are /[a-z][A-Z][0-9]-_/. *
                      * * string id = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -1620,8 +1620,8 @@ public com.google.protobuf.ByteString getIdBytes() { * will be used. In this case, the service will handle conflict resolution * by adding a system generated suffix in case of duplicates. * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. + * This value should be 3-500 characters, and valid characters + * are /[a-z][A-Z][0-9]-_/. *
                      * * string id = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -1651,8 +1651,8 @@ public Builder setId(java.lang.String value) { * will be used. In this case, the service will handle conflict resolution * by adding a system generated suffix in case of duplicates. * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. + * This value should be 3-500 characters, and valid characters + * are /[a-z][A-Z][0-9]-_/. *
                      * * string id = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -1678,8 +1678,8 @@ public Builder clearId() { * will be used. In this case, the service will handle conflict resolution * by adding a system generated suffix in case of duplicates. * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. + * This value should be 3-500 characters, and valid characters + * are /[a-z][A-Z][0-9]-_/. *
                      * * string id = 1 [(.google.api.field_behavior) = REQUIRED]; diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CollectServiceProto.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CollectServiceProto.java index 6be736a4b4b0..e574258a5169 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CollectServiceProto.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CollectServiceProto.java @@ -116,13 +116,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\001\022\031\n\013original_id\030\005 \001(\tB\004\342A\001\001\022>\n\024original" + "_create_time\030\006 \001(\0132\032.google.protobuf.Tim" + "estampB\004\342A\001\001\022>\n\024original_update_time\030\007 \001" - + "(\0132\032.google.protobuf.TimestampB\004\342A\001\002\"\333\001\n" + + "(\0132\032.google.protobuf.TimestampB\004\342A\001\002\"\203\002\n" + "\014SpecMetadata\0220\n\004spec\030\001 \001(\0132\034.google.clo" + "ud.apihub.v1.SpecB\004\342A\001\002\022\031\n\013original_id\030\002" + " \001(\tB\004\342A\001\001\022>\n\024original_create_time\030\003 \001(\013" + "2\032.google.protobuf.TimestampB\004\342A\001\001\022>\n\024or" + "iginal_update_time\030\004 \001(\0132\032.google.protob" - + "uf.TimestampB\004\342A\001\002\"\355\001\n\022DeploymentMetadat" + + "uf.TimestampB\004\342A\001\002\022&\n\030deployment_resourc" + + "e_uris\030\005 \003(\tB\004\342A\001\001\"\355\001\n\022DeploymentMetadat" + "a\022<\n\ndeployment\030\001 \001(\0132\".google.cloud.api" + "hub.v1.DeploymentB\004\342A\001\002\022\031\n\013original_id\030\002" + " \001(\tB\004\342A\001\001\022>\n\024original_create_time\030\003 \001(\013" @@ -131,21 +132,22 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "uf.TimestampB\004\342A\001\002\"\030\n\026CollectApiDataResp" + "onse*i\n\016CollectionType\022\037\n\033COLLECTION_TYP" + "E_UNSPECIFIED\020\000\022\032\n\026COLLECTION_TYPE_UPSER" - + "T\020\001\022\032\n\026COLLECTION_TYPE_DELETE\020\0022\317\002\n\rApiH" + + "T\020\001\022\032\n\026COLLECTION_TYPE_DELETE\020\0022\200\003\n\rApiH" + "ubCollect\022\362\001\n\016CollectApiData\022-.google.cl" + "oud.apihub.v1.CollectApiDataRequest\032\035.go" + "ogle.longrunning.Operation\"\221\001\312A+\n\026Collec" + "tApiDataResponse\022\021OperationMetadata\332A!lo" + "cation,collection_type,api_data\202\323\344\223\0029\"4/" + "v1/{location=projects/*/locations/*}:col" - + "lectApiData:\001*\032I\312A\025apihub.googleapis.com" - + "\322A.https://www.googleapis.com/auth/cloud" - + "-platformB\265\001\n\032com.google.cloud.apihub.v1" - + "B\023CollectServiceProtoP\001Z2cloud.google.co" - + "m/go/apihub/apiv1/apihubpb;apihubpb\252\002\026Go" - + "ogle.Cloud.ApiHub.V1\312\002\026Google\\Cloud\\ApiH" - + "ub\\V1\352\002\031Google::Cloud::ApiHub::V1b\006proto" - + "3" + + "lectApiData:\001*\032z\312A\025apihub.googleapis.com" + + "\322A_https://www.googleapis.com/auth/apihu" + + "b.readwrite,https://www.googleapis.com/a" + + "uth/cloud-platformB\265\001\n\032com.google.cloud." + + "apihub.v1B\023CollectServiceProtoP\001Z2cloud." + + "google.com/go/apihub/apiv1/apihubpb;apih" + + "ubpb\252\002\026Google.Cloud.ApiHub.V1\312\002\026Google\\C" + + "loud\\ApiHub\\V1\352\002\031Google::Cloud::ApiHub::" + + "V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -209,7 +211,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_SpecMetadata_descriptor, new java.lang.String[] { - "Spec", "OriginalId", "OriginalCreateTime", "OriginalUpdateTime", + "Spec", + "OriginalId", + "OriginalCreateTime", + "OriginalUpdateTime", + "DeploymentResourceUris", }); internal_static_google_cloud_apihub_v1_DeploymentMetadata_descriptor = getDescriptor().getMessageType(6); diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CommonFieldsProto.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CommonFieldsProto.java index 102d18a5363a..93cb3c6a4ab0 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CommonFieldsProto.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CommonFieldsProto.java @@ -64,6 +64,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_apihub_v1_Spec_AttributesEntry_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_apihub_v1_Spec_AttributesEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_AdditionalSpecContent_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_AdditionalSpecContent_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_AdditionalSpecContent_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_AdditionalSpecContent_LabelsEntry_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_apihub_v1_Deployment_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -112,6 +120,22 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_apihub_v1_OperationDetails_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_apihub_v1_OperationDetails_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_OperationSchema_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_OperationSchema_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_McpTool_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_McpTool_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ToolAnnotations_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ToolAnnotations_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ToolAnnotations_AdditionalHintsEntry_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ToolAnnotations_AdditionalHintsEntry_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_apihub_v1_HttpOperation_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -192,6 +216,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_AgentRegistrySyncConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_AgentRegistrySyncConfig_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_apihub_v1_ApiHubInstance_LabelsEntry_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -325,7 +353,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "*google/cloud/apihub/v1/common_fields.p" + "roto\022\026google.cloud.apihub.v1\032\037google/api" + "/field_behavior.proto\032\031google/api/resour" - + "ce.proto\032\037google/protobuf/timestamp.proto\"\326\n\n" + + "ce.proto\032\034google/protobuf/struct.proto\032\037google/protobuf/timestamp.proto\"\233\013\n" + "\003Api\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + "\014display_name\030\002 \001(\tB\004\342A\001\002\022\031\n" @@ -339,41 +367,43 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\010" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022B\n" - + "\013target_user\030\t \001(\0132\'.goog" - + "le.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022;\n" + + "\013target_user\030\t" + + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022;\n" + "\004team\030\n" + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022D\n\r" - + "business_unit\030\013" - + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022E\n" - + "\016maturity_level\030\014 \001(\0132\'.go" - + "ogle.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022E\n\n" + + "business_unit\030\013 \001(\0132\'.goo" + + "gle.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022E\n" + + "\016maturity_level\030\014" + + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022E\n\n" + "attributes\030\r" + " \003(\0132+.google.cloud.apihub.v1.Api.AttributesEntryB\004\342A\001\001\022@\n" - + "\tapi_style\030\016" - + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022@\n" + + "\tapi_style\030\016 \001" + + "(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022@\n" + "\020selected_version\030\017 \001(\tB&\342A\001\001\372A\037\n" + "\035apihub.googleapis.com/Version\022G\n" - + "\020api_requirements\030\020 \001(\0132\'.google" - + ".cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022\031\n" + + "\020api_requirements\030\020" + + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022\031\n" + "\013fingerprint\030\021 \001(\tB\004\342A\001\001\022E\n" - + "\017source_metadata\030\022" - + " \003(\0132&.google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\022R\n" - + "\033api_functional_requirements\030\023" - + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022Q\n" + + "\017source_metadata\030\022 \003(\013" + + "2&.google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\022R\n" + + "\033api_functional_requirements\030\023 " + + "\001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022Q\n" + "\032api_technical_requirements\030\024" - + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\032Z\n" + + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022C\n" + + "\014service_type\030\025 \001(\0132\'.go" + + "ogle.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\032Z\n" + "\017AttributesEntry\022\013\n" + "\003key\030\001 \001(\t\0226\n" - + "\005value\030\002 \001(\0132\'.google." - + "cloud.apihub.v1.AttributeValues:\0028\001:]\352AZ\n" - + "\031apihub.googleapis.com/Api\0222projects/{p" - + "roject}/locations/{location}/apis/{api}*\004apis2\003api\"\376\010\n" + + "\005value\030\002" + + " \001(\0132\'.google.cloud.apihub.v1.AttributeValues:\0028\001:]\352AZ\n" + + "\031apihub.googleapis.c" + + "om/Api\0222projects/{project}/locations/{location}/apis/{api}*\004apis2\003api\"\376\010\n" + "\007Version\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + "\014display_name\030\002 \001(\tB\004\342A\001\002\022\031\n" + "\013description\030\003 \001(\tB\004\342A\001\001\022B\n\r" - + "documentation\030\004 \001(\013" - + "2%.google.cloud.apihub.v1.DocumentationB\004\342A\001\001\0222\n" + + "documentation\030\004" + + " \001(\0132%.google.cloud.apihub.v1.DocumentationB\004\342A\001\001\0222\n" + "\005specs\030\005 \003(\tB#\342A\001\003\372A\034\n" + "\032apihub.googleapis.com/Spec\022C\n" + "\016api_operations\030\006 \003(\tB+\342A\001\003\372A$\n" @@ -386,31 +416,31 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\n" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022@\n" - + "\tlifecycle\030\013" - + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022A\n\n" + + "\tlifecycle\030\013 \001" + + "(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022A\n\n" + "compliance\030\014" + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022D\n\r" + "accreditation\030\r" + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022I\n\n" - + "attributes\030\016 \003(\0132/.google.clo" - + "ud.apihub.v1.Version.AttributesEntryB\004\342A\001\001\022F\n" + + "attributes\030\016" + + " \003(\0132/.google.cloud.apihub.v1.Version.AttributesEntryB\004\342A\001\001\022F\n" + "\023selected_deployment\030\020 \001(\tB)\342A\001\001\372A\"\n" + " apihub.googleapis.com/Deployment\022E\n" - + "\017source_metadata\030\021" - + " \003(\0132&.google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\032Z\n" + + "\017source_metadata\030\021 \003(\0132&" + + ".google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\032Z\n" + "\017AttributesEntry\022\013\n" + "\003key\030\001 \001(\t\0226\n" - + "\005value\030\002 \001(\0132\'.googl" - + "e.cloud.apihub.v1.AttributeValues:\0028\001:|\352Ay\n" - + "\035apihub.googleapis.com/Version\022Eprojects/{project}/locations/{location}/apis/" - + "{api}/versions/{version}*\010versions2\007version\"\375\007\n" + + "\005value\030\002" + + " \001(\0132\'.google.cloud.apihub.v1.AttributeValues:\0028\001:|\352Ay\n" + + "\035apihub.googleapis.com/Version\022Eprojects/{project}/locatio" + + "ns/{location}/apis/{api}/versions/{version}*\010versions2\007version\"\224\t\n" + "\004Spec\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + "\014display_name\030\002 \001(\tB\004\342A\001\002\022@\n" - + "\tspec_type\030\003 \001(\0132" - + "\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\002\022=\n" - + "\010contents\030\004" - + " \001(\0132$.google.cloud.apihub.v1.SpecContentsB\005\342A\002\001\004\022:\n" + + "\tspec_type\030\003" + + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\002\022=\n" + + "\010contents\030\004 " + + "\001(\0132$.google.cloud.apihub.v1.SpecContentsB\005\342A\002\001\004\022:\n" + "\007details\030\005" + " \001(\0132#.google.cloud.apihub.v1.SpecDetailsB\004\342A\001\003\022\030\n\n" + "source_uri\030\006 \001(\tB\004\342A\001\001\0225\n" @@ -424,10 +454,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \003(\0132,.google.cloud.apihub.v1.Spec.AttributesEntryB\004\342A\001\001\022B\n\r" + "documentation\030\013" + " \001(\0132%.google.cloud.apihub.v1.DocumentationB\004\342A\001\001\022E\n" - + "\014parsing_mode\030\014" - + " \001(\0162(.google.cloud.apihub.v1.Spec.ParsingModeB\005\342A\002\001\004\022E\n" + + "\014parsing_mode\030\014 \001(\0162(.goog" + + "le.cloud.apihub.v1.Spec.ParsingModeB\005\342A\002\001\004\022E\n" + "\017source_metadata\030\r" - + " \003(\0132&.google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\032Z\n" + + " \003(\0132&.google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\022U\n" + + "\030additional_spec_contents\030\016 \003(\0132-.google.clo" + + "ud.apihub.v1.AdditionalSpecContentB\004\342A\001\003\022>\n" + + "\013deployments\030\017 \003(\tB)\342A\001\001\372A\"\n" + + " apihub.googleapis.com/Deployment\032Z\n" + "\017AttributesEntry\022\013\n" + "\003key\030\001 \001(\t\0226\n" + "\005value\030\002 \001(\0132\'.google.cloud.apihub.v1.AttributeValues:\0028\001\"D\n" @@ -435,15 +469,29 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\030PARSING_MODE_UNSPECIFIED\020\000\022\013\n" + "\007RELAXED\020\001\022\n\n" + "\006STRICT\020\002:\200\001\352A}\n" - + "\032apihub.googleapis.com/Spec\022Rprojects/{project}/locations" - + "/{location}/apis/{api}/versions/{version}/specs/{spec}*\005specs2\004spec\"\340\010\n\n" + + "\032apihub.googleapis.com/Spec\022Rprojects/{project}" + + "/locations/{location}/apis/{api}/version" + + "s/{version}/specs/{spec}*\005specs2\004spec\"\222\003\n" + + "\025AdditionalSpecContent\022H\n" + + "\021spec_content_type\030\001" + + " \001(\0162\'.google.cloud.apihub.v1.SpecContentTypeB\004\342A\001\002\022A\n\r" + + "spec_contents\030\002 \001(\013" + + "2$.google.cloud.apihub.v1.SpecContentsB\004\342A\001\001\0225\n" + + "\013create_time\030\003" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + + "\013update_time\030\004" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022O\n" + + "\006labels\030\005" + + " \003(\01329.google.cloud.apihub.v1.AdditionalSpecContent.LabelsEntryB\004\342A\001\001\032-\n" + + "\013LabelsEntry\022\013\n" + + "\003key\030\001 \001(\t\022\r\n" + + "\005value\030\002 \001(\t:\0028\001\"\370\t\n\n" + "Deployment\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + "\014display_name\030\002 \001(\tB\004\342A\001\002\022\031\n" - + "\013description\030\003 \001(\tB\004\342A\001\001\022B\n" - + "\r" - + "documentation\030\004" - + " \001(\0132%.google.cloud.apihub.v1.DocumentationB\004\342A\001\001\022F\n" + + "\013description\030\003 \001(\tB\004\342A\001\001\022B\n\r" + + "documentation\030\004 \001(\0132%.go" + + "ogle.cloud.apihub.v1.DocumentationB\004\342A\001\001\022F\n" + "\017deployment_type\030\005" + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\002\022\032\n" + "\014resource_uri\030\006 \001(\tB\004\342A\001\002\022\027\n" @@ -453,28 +501,32 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\n" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022:\n" - + "\003slo\030\013" - + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022B\n" + + "\003slo\030\013 \001(\0132\'.g" + + "oogle.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022B\n" + "\013environment\030\014" + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022L\n\n" + "attributes\030\r" - + " \003(\01322.g" - + "oogle.cloud.apihub.v1.Deployment.AttributesEntryB\004\342A\001\001\022E\n" - + "\017source_metadata\030\016 \003(\0132" - + "&.google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\022E\n" + + " \003(\01322.google.cloud.apihub.v1.Deployment.AttributesEntryB\004\342A\001\001\022E\n" + + "\017source_metadata\030\016" + + " \003(\0132&.google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\022E\n" + "\016management_url\030\017" + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022A\n\n" - + "source_uri\030\020" - + " \001(\0132\'.google.cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022\034\n" + + "source_uri\030\020 \001(\0132\'.google" + + ".cloud.apihub.v1.AttributeValuesB\004\342A\001\001\022\034\n" + "\016source_project\030\021 \001(\tB\004\342A\001\001\022 \n" - + "\022source_environment\030\022 \001(\tB\004\342A\001\001\032Z\n" + + "\022source_environment\030\022 \001(\tB\004\342A\001\001\0222\n" + + "\005specs\030\023 \003(\tB#\342A\001\003\372A\034\n" + + "\032apihub.googleapis.com/Spec\022C\n" + + "\016api_operations\030\024 \003(\tB+\342A\001\003\372A$\n" + + "\"apihub.googleapis.com/ApiOperation\022\035\n" + + "\017source_revision\030\025 \001(\tB\004\342A\001\001\032Z\n" + "\017AttributesEntry\022\013\n" + "\003key\030\001 \001(\t\0226\n" + "\005value\030\002" + " \001(\0132\'.google.cloud.apihub.v1.AttributeValues:\0028\001:\200\001\352A}\n" - + " apihub.googleapis.com/Deployment\022@projects/{project}/" - + "locations/{location}/deployments/{deployment}*\013deployments2\n" - + "deployment\"\235\005\n" + + " apihub.googleapis.com/Deployment\022@projects/{pr" + + "oject}/locations/{location}/deployments/{deployment}*\013deployments2\n" + + "deployment\"\335\005\n" + "\014ApiOperation\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\0221\n" + "\004spec\030\002 \001(\tB#\342A\001\003\372A\034\n" @@ -485,16 +537,18 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\005" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022N\n\n" - + "attributes\030\006 \003(\01324.goog" - + "le.cloud.apihub.v1.ApiOperation.AttributesEntryB\004\342A\001\001\022E\n" - + "\017source_metadata\030\007 \003(\0132&" - + ".google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\032Z\n" + + "attributes\030\006 \003(\013" + + "24.google.cloud.apihub.v1.ApiOperation.AttributesEntryB\004\342A\001\001\022E\n" + + "\017source_metadata\030\007" + + " \003(\0132&.google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\022>\n" + + "\013deployments\030\010 \003(\tB)\342A\001\001\372A\"\n" + + " apihub.googleapis.com/Deployment\032Z\n" + "\017AttributesEntry\022\013\n" + "\003key\030\001 \001(\t\0226\n" - + "\005value\030\002" - + " \001(\0132\'.google.cloud.apihub.v1.AttributeValues:\0028\001:\243\001\352A\237\001\n" - + "\"apihub.googleapis.com/ApiOperation\022\\projects/{project}/" - + "locations/{location}/apis/{api}/versions/{version}/operations/{operation}*\r" + + "\005value\030\002 \001" + + "(\0132\'.google.cloud.apihub.v1.AttributeValues:\0028\001:\243\001\352A\237\001\n" + + "\"apihub.googleapis.com/ApiOperation\022\\projects/{project}/locations" + + "/{location}/apis/{api}/versions/{version}/operations/{operation}*\r" + "apiOperations2\014apiOperation\"\265\005\n\n" + "Definition\0226\n" + "\006schema\030\004" @@ -508,31 +562,31 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\006" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022L\n\n" - + "attributes\030\007 \003(\01322.go" - + "ogle.cloud.apihub.v1.Definition.AttributesEntryB\004\342A\001\001\032Z\n" + + "attributes\030\007 \003(\01322.google.clou" + + "d.apihub.v1.Definition.AttributesEntryB\004\342A\001\001\032Z\n" + "\017AttributesEntry\022\013\n" + "\003key\030\001 \001(\t\0226\n" + "\005value\030\002 \001(\0132\'.google.cloud.apihub.v1.AttributeValues:\0028\001\"(\n" + "\004Type\022\024\n" + "\020TYPE_UNSPECIFIED\020\000\022\n\n" + "\006SCHEMA\020\001:\237\001\352A\233\001\n" - + " apihub.googleapis.com/Definition\022^projects/{" - + "project}/locations/{location}/apis/{api}" - + "/versions/{version}/definitions/{definition}*\013definitions2\n" + + " apihub.googleapis.com/Definition\022^projects/{project}/" + + "locations/{location}/apis/{api}/versions" + + "/{version}/definitions/{definition}*\013definitions2\n" + "definitionB\007\n" + "\005value\"\324\010\n" + "\tAttribute\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + "\014display_name\030\002 \001(\tB\004\342A\001\002\022\031\n" + "\013description\030\003 \001(\tB\004\342A\001\001\022O\n" - + "\017definition_type\030\004 \001(\01620.googl" - + "e.cloud.apihub.v1.Attribute.DefinitionTypeB\004\342A\001\003\022<\n" + + "\017definition_type\030\004 \001(\01620.google.cloud.a" + + "pihub.v1.Attribute.DefinitionTypeB\004\342A\001\003\022<\n" + "\005scope\030\005" + " \001(\0162\'.google.cloud.apihub.v1.Attribute.ScopeB\004\342A\001\002\022C\n" - + "\tdata_type\030\006" - + " \001(\0162*.google.cloud.apihub.v1.Attribute.DataTypeB\004\342A\001\002\022L\n" - + "\016allowed_values\030\007 " - + "\003(\0132..google.cloud.apihub.v1.Attribute.AllowedValueB\004\342A\001\001\022\031\n" + + "\tdata_type\030\006 \001(\016" + + "2*.google.cloud.apihub.v1.Attribute.DataTypeB\004\342A\001\002\022L\n" + + "\016allowed_values\030\007 \003(\0132..goo" + + "gle.cloud.apihub.v1.Attribute.AllowedValueB\004\342A\001\001\022\031\n" + "\013cardinality\030\010 \001(\005B\004\342A\001\001\022\027\n" + "\tmandatory\030\t \001(\010B\004\342A\001\003\0225\n" + "\013create_time\030\n" @@ -565,8 +619,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004JSON\020\002\022\n\n" + "\006STRING\020\003\022\007\n" + "\003URI\020\004:{\352Ax\n" - + "\037apihub.googleapis.com/Attribute\022>projects/{projec" - + "t}/locations/{location}/attributes/{attribute}*\n" + + "\037apihub.googleapis." + + "com/Attribute\022>projects/{project}/locations/{location}/attributes/{attribute}*\n" + "attributes2\tattribute\"?\n" + "\014SpecContents\022\026\n" + "\010contents\030\001 \001(\014B\004\342A\001\002\022\027\n" @@ -577,27 +631,56 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013description\030\001 \001(\tB\004\342A\001\003B\t\n" + "\007details\"\217\002\n" + "\022OpenApiSpecDetails\022G\n" - + "\006format\030\001 \001(\01621.google." - + "cloud.apihub.v1.OpenApiSpecDetails.FormatB\004\342A\001\003\022\025\n" + + "\006format\030\001 \001(\01621.google.cloud.api" + + "hub.v1.OpenApiSpecDetails.FormatB\004\342A\001\003\022\025\n" + "\007version\030\002 \001(\tB\004\342A\001\003\0222\n" + "\005owner\030\003 \001(\0132\035.google.cloud.apihub.v1.OwnerB\004\342A\001\003\"e\n" + "\006Format\022\026\n" + "\022FORMAT_UNSPECIFIED\020\000\022\025\n" + "\021OPEN_API_SPEC_2_0\020\001\022\025\n" + "\021OPEN_API_SPEC_3_0\020\002\022\025\n" - + "\021OPEN_API_SPEC_3_1\020\003\"\331\001\n" + + "\021OPEN_API_SPEC_3_1\020\003\"\216\002\n" + "\020OperationDetails\022?\n" + "\016http_operation\030\004" - + " \001(\0132%.google.cloud.apihub.v1.HttpOperationH\000\022\031\n" + + " \001(\0132%.google.cloud.apihub.v1.HttpOperationH\000\0223\n" + + "\010mcp_tool\030\005 \001(\0132\037.google.cloud.apihub.v1.McpToolH\000\022\031\n" + "\013description\030\001 \001(\tB\004\342A\001\001\022B\n\r" - + "documentation\030\002 \001(" - + "\0132%.google.cloud.apihub.v1.DocumentationB\004\342A\001\001\022\030\n\n" + + "documentation\030\002" + + " \001(\0132%.google.cloud.apihub.v1.DocumentationB\004\342A\001\001\022\030\n\n" + "deprecated\030\003 \001(\010B\004\342A\001\001B\013\n" - + "\toperation\"\374\001\n\r" + + "\toperation\"J\n" + + "\017OperationSchema\022.\n" + + "\013json_schema\030\001 \001(\0132\027.google.protobuf.StructH\000B\007\n" + + "\005value\"\234\002\n" + + "\007McpTool\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\002\022\023\n" + + "\005title\030\002 \001(\tB\004\342A\001\001\022\031\n" + + "\013description\030\003 \001(\tB\004\342A\001\001\022B\n" + + "\013annotations\030\004" + + " \001(\0132\'.google.cloud.apihub.v1.ToolAnnotationsB\004\342A\001\001\022C\n" + + "\014input_schema\030\005" + + " \001(\0132\'.google.cloud.apihub.v1.OperationSchemaB\004\342A\001\001\022D\n\r" + + "output_schema\030\006" + + " \001(\0132\'.google.cloud.apihub.v1.OperationSchemaB\004\342A\001\001\"\234\003\n" + + "\017ToolAnnotations\022\023\n" + + "\005title\030\001 \001(\tB\004\342A\001\001\022!\n" + + "\016read_only_hint\030\002 \001(\010B\004\342A\001\001H\000\210\001\001\022#\n" + + "\020destructive_hint\030\003 \001(\010B\004\342A\001\001H\001\210\001\001\022\"\n" + + "\017idempotent_hint\030\004 \001(\010B\004\342A\001\001H\002\210\001\001\022\"\n" + + "\017open_world_hint\030\005 \001(\010B\004\342A\001\001H\003\210\001\001\022\\\n" + + "\020additional_hints\030\006 \003(\0132<.google.cloud.a" + + "pihub.v1.ToolAnnotations.AdditionalHintsEntryB\004\342A\001\001\0326\n" + + "\024AdditionalHintsEntry\022\013\n" + + "\003key\030\001 \001(\t\022\r\n" + + "\005value\030\002 \001(\t:\0028\001B\021\n" + + "\017_read_only_hintB\023\n" + + "\021_destructive_hintB\022\n" + + "\020_idempotent_hintB\022\n" + + "\020_open_world_hint\"\374\001\n\r" + "HttpOperation\0220\n" + "\004path\030\001 \001(\0132\034.google.cloud.apihub.v1.PathB\004\342A\001\001\022B\n" - + "\006method\030\002" - + " \001(\0162,.google.cloud.apihub.v1.HttpOperation.MethodB\004\342A\001\001\"u\n" + + "\006method\030\002 \001(\0162,.google" + + ".cloud.apihub.v1.HttpOperation.MethodB\004\342A\001\001\"u\n" + "\006Method\022\026\n" + "\022METHOD_UNSPECIFIED\020\000\022\007\n" + "\003GET\020\001\022\007\n" @@ -620,41 +703,43 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "Documentation\022\032\n" + "\014external_uri\030\001 \001(\tB\004\342A\001\001\"\272\004\n" + "\017AttributeValues\022R\n" - + "\013enum_values\030\002 \001" - + "(\0132;.google.cloud.apihub.v1.AttributeValues.EnumAttributeValuesH\000\022V\n\r" - + "string_values\030\003" - + " \001(\0132=.google.cloud.apihub.v1.AttributeValues.StringAttributeValuesH\000\022T\n" - + "\013json_values\030\004 \001(\0132=.google.cloud.apihub.v1." - + "AttributeValues.StringAttributeValuesH\000\022S\n\n" - + "uri_values\030\005 \001(\0132=.google.cloud.apihu" - + "b.v1.AttributeValues.StringAttributeValuesH\000\022;\n" + + "\013enum_values\030\002 \001(\0132;.google.cloud." + + "apihub.v1.AttributeValues.EnumAttributeValuesH\000\022V\n\r" + + "string_values\030\003 \001(\0132=.google." + + "cloud.apihub.v1.AttributeValues.StringAttributeValuesH\000\022T\n" + + "\013json_values\030\004 \001(\0132=.g" + + "oogle.cloud.apihub.v1.AttributeValues.StringAttributeValuesH\000\022S\n\n" + + "uri_values\030\005 \001(" + + "\0132=.google.cloud.apihub.v1.AttributeValues.StringAttributeValuesH\000\022;\n" + "\tattribute\030\001 \001(\tB(\342A\001\003\372A!\n" + "\037apihub.googleapis.com/Attribute\032[\n" + "\023EnumAttributeValues\022D\n" - + "\006values\030\001 \003(\0132..google.cloud." - + "apihub.v1.Attribute.AllowedValueB\004\342A\001\002\032-\n" + + "\006values\030\001" + + " \003(\0132..google.cloud.apihub.v1.Attribute.AllowedValueB\004\342A\001\002\032-\n" + "\025StringAttributeValues\022\024\n" + "\006values\030\001 \003(\tB\004\342A\001\002B\007\n" - + "\005Value\"\304\007\n\n" + + "\005Value\"\304\007\n" + + "\n" + "Dependency\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022J\n" - + "\010consumer\030\002 \001(\01321.google.clo" - + "ud.apihub.v1.DependencyEntityReferenceB\005\342A\002\005\002\022J\n" - + "\010supplier\030\003 \001(\01321.google.cloud.a" - + "pihub.v1.DependencyEntityReferenceB\005\342A\002\005\002\022=\n" - + "\005state\030\004" - + " \001(\0162(.google.cloud.apihub.v1.Dependency.StateB\004\342A\001\003\022\031\n" + + "\010consumer\030\002" + + " \001(\01321.google.cloud.apihub.v1.DependencyEntityReferenceB\005\342A\002\005\002\022J\n" + + "\010supplier\030\003" + + " \001(\01321.google.cloud.apihub.v1.DependencyEntityReferenceB\005\342A\002\005\002\022=\n" + + "\005state\030\004 \001(\0162(" + + ".google.cloud.apihub.v1.Dependency.StateB\004\342A\001\003\022\031\n" + "\013description\030\005 \001(\tB\004\342A\001\001\022N\n" - + "\016discovery_mode\030\006 \001(\01620.go" - + "ogle.cloud.apihub.v1.Dependency.DiscoveryModeB\004\342A\001\003\022I\n" - + "\014error_detail\030\007 \001(\0132-.goog" - + "le.cloud.apihub.v1.DependencyErrorDetailB\004\342A\001\003\0225\n" + + "\016discovery_mode\030\006" + + " \001(\01620.google.cloud.apihub.v1.Dependency.DiscoveryModeB\004\342A\001\003\022I\n" + + "\014error_detail\030\007" + + " \001(\0132-.google.cloud.apihub.v1.DependencyErrorDetailB\004\342A\001\003\0225\n" + "\013create_time\030\010" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\t" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022L\n\n" + "attributes\030\n" - + " \003(\01322.google.cloud.apihub.v1.Dependency.AttributesEntryB\004\342A\001\001\032Z\n" + + " \003(\01322" + + ".google.cloud.apihub.v1.Dependency.AttributesEntryB\004\342A\001\001\032Z\n" + "\017AttributesEntry\022\013\n" + "\003key\030\001 \001(\t\0226\n" + "\005value\030\002 \001(\0132\'.google.cloud.apihub.v1.AttributeValues:\0028\001\";\n" @@ -665,8 +750,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "DiscoveryMode\022\036\n" + "\032DISCOVERY_MODE_UNSPECIFIED\020\000\022\n\n" + "\006MANUAL\020\001:\202\001\352A\177\n" - + " apihub.googleapis.com/Dependency\022Aprojects/{project}/locations/{" - + "location}/dependencies/{dependency}*\014dependencies2\n" + + " apihub.googleapis.com/Dependency\022Aprojects" + + "/{project}/locations/{location}/dependencies/{dependency}*\014dependencies2\n" + "dependency\"\216\001\n" + "\031DependencyEntityReference\022!\n" + "\027operation_resource_name\030\002 \001(\tH\000\022$\n" @@ -674,8 +759,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\014display_name\030\001 \001(\tB\004\342A\001\003B\014\n\n" + "identifier\"\347\001\n" + "\025DependencyErrorDetail\022H\n" - + "\005error\030\001" - + " \001(\01623.google.cloud.apihub.v1.DependencyErrorDetail.ErrorB\004\342A\001\001\0224\n\n" + + "\005error\030\001 \001(\01623.google.c" + + "loud.apihub.v1.DependencyErrorDetail.ErrorB\004\342A\001\001\0224\n\n" + "error_time\030\002 \001(\0132\032.google.protobuf.TimestampB\004\342A\001\001\"N\n" + "\005Error\022\025\n" + "\021ERROR_UNSPECIFIED\020\000\022\026\n" @@ -684,10 +769,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\014LintResponse\0223\n" + "\006issues\030\001" + " \003(\0132\035.google.cloud.apihub.v1.IssueB\004\342A\001\001\022H\n" - + "\007summary\030\002" - + " \003(\01321.google.cloud.apihub.v1.LintResponse.SummaryEntryB\004\342A\001\001\0226\n" - + "\005state\030\003 \001(\0162" - + "!.google.cloud.apihub.v1.LintStateB\004\342A\001\002\022\024\n" + + "\007summary\030\002 \003(\01321.google.c" + + "loud.apihub.v1.LintResponse.SummaryEntryB\004\342A\001\001\0226\n" + + "\005state\030\003" + + " \001(\0162!.google.cloud.apihub.v1.LintStateB\004\342A\001\002\022\024\n" + "\006source\030\004 \001(\tB\004\342A\001\002\0224\n" + "\006linter\030\005" + " \001(\0162\036.google.cloud.apihub.v1.LinterB\004\342A\001\002\0225\n" @@ -719,27 +804,31 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004verb\030\004 \001(\tB\004\342A\001\003\022\034\n" + "\016status_message\030\005 \001(\tB\004\342A\001\003\022$\n" + "\026requested_cancellation\030\006 \001(\010B\004\342A\001\003\022\031\n" - + "\013api_version\030\007 \001(\tB\004\342A\001\003\"\336\007\n" + + "\013api_version\030\007 \001(\tB\004\342A\001\003\"\202\t\n" + "\016ApiHubInstance\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\0225\n" + "\013create_time\030\002" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\003" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022A\n" - + "\005state\030\004" - + " \001(\0162,.google.cloud.apihub.v1.ApiHubInstance.StateB\004\342A\001\003\022\033\n\r" + + "\005state\030\004 \001(\0162,.google.clou" + + "d.apihub.v1.ApiHubInstance.StateB\004\342A\001\003\022\033\n\r" + "state_message\030\005 \001(\tB\004\342A\001\003\022C\n" - + "\006config\030\006" - + " \001(\0132-.google.cloud.apihub.v1.ApiHubInstance.ConfigB\004\342A\001\002\022H\n" - + "\006labels\030\007" - + " \003(\01322.google.cloud.apihub.v1.ApiHubInstance.LabelsEntryB\004\342A\001\001\022\031\n" - + "\013description\030\010 \001(\tB\004\342A\001\001\032\206\002\n" + + "\006config\030\006 " + + "\001(\0132-.google.cloud.apihub.v1.ApiHubInstance.ConfigB\004\342A\001\002\022H\n" + + "\006labels\030\007 \003(\01322.googl" + + "e.cloud.apihub.v1.ApiHubInstance.LabelsEntryB\004\342A\001\001\022\031\n" + + "\013description\030\010 \001(\tB\004\342A\001\001\032\252\003\n" + "\006Config\022\033\n\r" + "cmek_key_name\030\001 \001(\tB\004\342A\001\001\022\034\n" + "\016disable_search\030\002 \001(\010B\004\342A\001\001\022\035\n" + "\017vertex_location\030\003 \001(\tB\004\342A\001\001\022[\n" - + "\017encryption_type\030\004 \001(\0162<.google.cloud.api" - + "hub.v1.ApiHubInstance.Config.EncryptionTypeB\004\342A\001\001\"E\n" + + "\017encryption_type\030\004 " + + "\001(\0162<.google.cloud.apihub.v1.ApiHubInstance.Config.EncryptionTypeB\004\342A\001\001\022o\n" + + "\032agent_registry_sync_config\030\005 \001(\0132E.google.clo" + + "ud.apihub.v1.ApiHubInstance.Config.AgentRegistrySyncConfigB\004\342A\001\001\0321\n" + + "\027AgentRegistrySyncConfig\022\026\n" + + "\010disabled\030\001 \001(\010B\004\342A\001\001\"E\n" + "\016EncryptionType\022\037\n" + "\033ENCRYPTION_TYPE_UNSPECIFIED\020\000\022\010\n" + "\004GMEK\020\001\022\010\n" @@ -755,16 +844,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010UPDATING\020\004\022\014\n" + "\010DELETING\020\005\022\n\n" + "\006FAILED\020\006:\227\001\352A\223\001\n" - + "$apihub.googleapis.com/ApiHubInstance\022Jprojects/{project}/locations/{loca" - + "tion}/apiHubInstances/{api_hub_instance}*\017apiHubInstances2\016apiHubInstance\"\355\004\n" + + "$apihub.googleapis.com/ApiHubInstance\022Jprojects" + + "/{project}/locations/{location}/apiHubIn" + + "stances/{api_hub_instance}*\017apiHubInstances2\016apiHubInstance\"\355\004\n" + "\013ExternalApi\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + "\014display_name\030\002 \001(\tB\004\342A\001\002\022\031\n" + "\013description\030\003 \001(\tB\004\342A\001\001\022\027\n" + "\tendpoints\030\004 \003(\tB\004\342A\001\001\022\023\n" + "\005paths\030\005 \003(\tB\004\342A\001\001\022B\n\r" - + "documentation\030\006 \001(\0132%.goog" - + "le.cloud.apihub.v1.DocumentationB\004\342A\001\001\022M\n\n" + + "documentation\030\006" + + " \001(\0132%.google.cloud.apihub.v1.DocumentationB\004\342A\001\001\022M\n\n" + "attributes\030\007" + " \003(\01323.google.cloud.apihub.v1.ExternalApi.AttributesEntryB\004\342A\001\001\0225\n" + "\013create_time\030\010" @@ -773,10 +863,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\032Z\n" + "\017AttributesEntry\022\013\n" + "\003key\030\001 \001(\t\0226\n" - + "\005value\030\002 \001(\0132\'.goo" - + "gle.cloud.apihub.v1.AttributeValues:\0028\001:\207\001\352A\203\001\n" - + "!apihub.googleapis.com/ExternalApi\022Cprojects/{project}/locations/{locatio" - + "n}/externalApis/{external_api}*\014externalApis2\013externalApi\"\\\n" + + "\005value\030\002" + + " \001(\0132\'.google.cloud.apihub.v1.AttributeValues:\0028\001:\207\001\352A\203\001\n" + + "!apihub.googleapis.com/ExternalApi\022Cprojects/{p" + + "roject}/locations/{location}/externalApi" + + "s/{external_api}*\014externalApis2\013externalApi\"\\\n" + "\021ConfigValueOption\022\020\n" + "\002id\030\001 \001(\tB\004\342A\001\002\022\032\n" + "\014display_name\030\002 \001(\tB\004\342A\001\002\022\031\n" @@ -785,8 +876,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016secret_version\030\001 \001(\tB\004\342A\001\002\"\371\003\n" + "\026ConfigVariableTemplate\022\020\n" + "\002id\030\001 \001(\tB\004\342A\001\002\022R\n\n" - + "value_type\030\002 \001(\01628.google.cloud.apihub.v" - + "1.ConfigVariableTemplate.ValueTypeB\004\342A\001\002\022\031\n" + + "value_type\030\002 \001" + + "(\01628.google.cloud.apihub.v1.ConfigVariableTemplate.ValueTypeB\004\342A\001\002\022\031\n" + "\013description\030\003 \001(\tB\004\342A\001\001\022\036\n" + "\020validation_regex\030\004 \001(\tB\004\342A\001\001\022\026\n" + "\010required\030\005 \001(\010B\004\342A\001\001\022E\n" @@ -810,18 +901,19 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "bool_value\030\004 \001(\010B\004\342A\001\001H\000\022<\n" + "\014secret_value\030\005" + " \001(\0132\036.google.cloud.apihub.v1.SecretB\004\342A\001\001H\000\022E\n\n" - + "enum_value\030\006" - + " \001(\0132).google.cloud.apihub.v1.ConfigValueOptionB\004\342A\001\001H\000\022]\n" - + "\023multi_select_values\030\007" - + " \001(\01328.google.cloud.apihub.v1.ConfigVariable.MultiSelectValuesB\004\342A\001\001H\000\022]\n" - + "\023multi_string_values\030\010 \001(\01328.google.cloud.apih" - + "ub.v1.ConfigVariable.MultiStringValuesB\004\342A\001\001H\000\022W\n" - + "\020multi_int_values\030\t \001(\01325.googl" - + "e.cloud.apihub.v1.ConfigVariable.MultiIntValuesB\004\342A\001\001H\000\022\021\n" + + "enum_value\030\006 \001(\0132).google" + + ".cloud.apihub.v1.ConfigValueOptionB\004\342A\001\001H\000\022]\n" + + "\023multi_select_values\030\007 \001(\01328.google" + + ".cloud.apihub.v1.ConfigVariable.MultiSelectValuesB\004\342A\001\001H\000\022]\n" + + "\023multi_string_values\030\010" + + " \001(\01328.google.cloud.apihub.v1.ConfigVariable.MultiStringValuesB\004\342A\001\001H\000\022W\n" + + "\020mult", + "i_int_values\030\t \001(\01325.google.cloud.apihub" + + ".v1.ConfigVariable.MultiIntValuesB\004\342A\001\001H\000\022\021\n" + "\003key\030\001 \001(\tB\004\342A\001\003\032T\n" + "\021MultiSelectValues\022?\n" - + "\006values\030\001 \003(\0132).google" - + ".cloud.apihub.v1.ConfigValueOptionB\004\342A\001\001\032)\n" + + "\006values\030\001" + + " \003(\0132).google.cloud.apihub.v1.ConfigValueOptionB\004\342A\001\001\032)\n" + "\021MultiStringValues\022\024\n" + "\006values\030\001 \003(\tB\004\342A\001\001\032&\n" + "\016MultiIntValues\022\024\n" @@ -831,30 +923,30 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017service_account\030\001 \001(\tB*\342A\001\002\372A#\n" + "!iam.googleapis.com/ServiceAccount\"\326\007\n\n" + "AuthConfig\022[\n" - + "\035google_service_account_config\030\002" - + " \001(\01322.google.cloud.apihub.v1.GoogleServiceAccountConfigH\000\022U\n" - + "\024user_password_config\030\003" - + " \001(\01325.google.cloud.apihub.v1.AuthConfig.UserPasswordConfigH\000\022I\n" - + "\016api_key_config\030\004" - + " \001(\0132/.google.cloud.apihub.v1.AuthConfig.ApiKeyConfigH\000\022l\n" - + " oauth2_client_credentials_config\030\005 \001(\0132@.google.cloud.a" - + "pihub.v1.AuthConfig.Oauth2ClientCredentialsConfigH\000\0229\n" + + "\035google_service_account_config\030\002 \001(\01322.google" + + ".cloud.apihub.v1.GoogleServiceAccountConfigH\000\022U\n" + + "\024user_password_config\030\003 \001(\01325.go" + + "ogle.cloud.apihub.v1.AuthConfig.UserPasswordConfigH\000\022I\n" + + "\016api_key_config\030\004 \001(\0132/.g" + + "oogle.cloud.apihub.v1.AuthConfig.ApiKeyConfigH\000\022l\n" + + " oauth2_client_credentials_config\030\005" + + " \001(\0132@.google.cloud.apihub.v1.AuthConfig.Oauth2ClientCredentialsConfigH\000\0229\n" + "\tauth_type\030\001 \001(\0162" + " .google.cloud.apihub.v1.AuthTypeB\004\342A\001\002\032d\n" + "\022UserPasswordConfig\022\026\n" + "\010username\030\001 \001(\tB\004\342A\001\002\0226\n" - + "\010password\030\002" - + " \001(\0132\036.google.cloud.apihub.v1.SecretB\004\342A\001\002\032u\n" + + "\010password\030\002 \001(\013" + + "2\036.google.cloud.apihub.v1.SecretB\004\342A\001\002\032u\n" + "\035Oauth2ClientCredentialsConfig\022\027\n" + "\tclient_id\030\001 \001(\tB\004\342A\001\002\022;\n\r" - + "client_secret\030\002" - + " \001(\0132\036.google.cloud.apihub.v1.SecretB\004\342A\001\002\032\270\002\n" + + "client_secret\030\002 \001(\0132" + + "\036.google.cloud.apihub.v1.SecretB\004\342A\001\002\032\270\002\n" + "\014ApiKeyConfig\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\002\0225\n" + "\007api_key\030\002" + " \001(\0132\036.google.cloud.apihub.v1.SecretB\004\342A\001\002\022h\n" - + "\025http_element_location\030\003 \001(\0162C.google.cloud.apihub.v1." - + "AuthConfig.ApiKeyConfig.HttpElementLocationB\004\342A\001\002\"s\n" + + "\025http_element_location\030\003 \001(\016" + + "2C.google.cloud.apihub.v1.AuthConfig.ApiKeyConfig.HttpElementLocationB\004\342A\001\002\"s\n" + "\023HttpElementLocation\022%\n" + "!HTTP_ELEMENT_LOCATION_UNSPECIFIED\020\000\022\t\n" + "\005QUERY\020\001\022\n\n" @@ -864,10 +956,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006COOKIE\020\005B\010\n" + "\006config\"\306\004\n" + "\016SourceMetadata\022p\n" - + "\035plugin_instance_action_source\030\001 \001(\0132A.goo" - + "gle.cloud.apihub.v1.SourceMetadata.PluginInstanceActionSourceB\004\342A\001\003H\000\022L\n" - + "\013source_type\030\002" - + " \001(\01621.google.cloud.apihub.v1.SourceMetadata.SourceTypeB\004\342A\001\003\022\"\n" + + "\035plugin_instance_action_source\030\001 \001(\0132A.google.cloud.apih" + + "ub.v1.SourceMetadata.PluginInstanceActionSourceB\004\342A\001\003H\000\022L\n" + + "\013source_type\030\002 \001(\01621.g" + + "oogle.cloud.apihub.v1.SourceMetadata.SourceTypeB\004\342A\001\003\022\"\n" + "\024original_resource_id\030\003 \001(\tB\004\342A\001\003\022G\n" + "\035original_resource_create_time\030\004" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022G\n" @@ -876,16 +968,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\032PluginInstanceActionSource\022F\n" + "\017plugin_instance\030\001 \001(\tB-\342A\001\003\372A&\n" + "$apihub.googleapis.com/PluginInstance\022\027\n" - + "\tactio", - "n_id\030\002 \001(\tB\004\342A\001\003\"5\n\n" + + "\taction_id\030\002 \001(\tB\004\342A\001\003\"5\n\n" + "SourceType\022\033\n" + "\027SOURCE_TYPE_UNSPECIFIED\020\000\022\n\n" + "\006PLUGIN\020\001B\010\n" + "\006source\"\236\010\n" + "\030DiscoveredApiObservation\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022K\n" - + "\005style\030\002 \001(\01626.google.cloud" - + ".apihub.v1.DiscoveredApiObservation.StyleB\004\342A\001\001\022\030\n\n" + + "\005style\030\002" + + " \001(\01626.google.cloud.apihub.v1.DiscoveredApiObservation.StyleB\004\342A\001\001\022\030\n\n" + "server_ips\030\003 \003(\tB\004\342A\001\001\022\026\n" + "\010hostname\030\004 \001(\tB\004\342A\001\001\022B\n" + "\030last_event_detected_time\030\005" @@ -894,8 +985,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "!locations.googleapis.com/Location\022!\n" + "\023api_operation_count\030\007 \001(\003B\004\342A\001\001\022\024\n" + "\006origin\030\010 \001(\tB\004\342A\001\001\022W\n" - + "\014source_types\030\t \003(\0162;.goo" - + "gle.cloud.apihub.v1.DiscoveredApiObservation.SourceTypeB\004\342A\001\001\022$\n" + + "\014source_types\030\t \003(\0162;.google.cloud.apih" + + "ub.v1.DiscoveredApiObservation.SourceTypeB\004\342A\001\001\022$\n" + "\026known_operations_count\030\n" + " \001(\003B\004\342A\001\003\022&\n" + "\030unknown_operations_count\030\013 \001(\003B\004\342A\001\003\0225\n" @@ -903,8 +994,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\r" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022E\n" - + "\017source_metadata\030\016 \001(\0132&.goo" - + "gle.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\"?\n" + + "\017source_metadata\030\016" + + " \001(\0132&.google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\"?\n" + "\005Style\022\025\n" + "\021STYLE_UNSPECIFIED\020\000\022\010\n" + "\004REST\020\001\022\010\n" @@ -914,24 +1005,24 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\027SOURCE_TYPE_UNSPECIFIED\020\000\022\013\n" + "\007GCP_XLB\020\001\022\013\n" + "\007GCP_ILB\020\002:\311\001\352A\305\001\n" - + ".apihub.googleapis.com/DiscoveredApiObservation\022^projects/" - + "{project}/locations/{location}/discoveredApiObservations/{discovered_api_observa" - + "tion}*\031discoveredApiObservations2\030discoveredApiObservation\"\343\007\n" + + ".apihub.googleapis.com/DiscoveredApiObservation\022^projects/{project}/loca" + + "tions/{location}/discoveredApiObservations/{discovered_api_observation}*\031discove" + + "redApiObservations2\030discoveredApiObservation\"\343\007\n" + "\026DiscoveredApiOperation\022L\n" - + "\016http_operation\030\002 \001(\0132,.google.c" - + "loud.apihub.v1.HttpOperationDetailsB\004\342A\001\001H\000\022\022\n" + + "\016http_operation\030\002" + + " \001(\0132,.google.cloud.apihub.v1.HttpOperationDetailsB\004\342A\001\001H\000\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\0229\n" + "\017first_seen_time\030\003" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\001\0228\n" + "\016last_seen_time\030\004" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\001\022\023\n" + "\005count\030\005 \001(\003B\004\342A\001\001\022[\n" - + "\016classification\030\006 \001(\0162=.google.cloud" - + ".apihub.v1.DiscoveredApiOperation.ClassificationB\004\342A\001\003\022W\n\r" - + "match_results\030\007 \003(\0132:." - + "google.cloud.apihub.v1.DiscoveredApiOperation.MatchResultB\004\342A\001\003\022E\n" - + "\017source_metadata\030\010" - + " \001(\0132&.google.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\0225\n" + + "\016classification\030\006 \001(\0162=.google.cloud.apihub.v1.Dis" + + "coveredApiOperation.ClassificationB\004\342A\001\003\022W\n\r" + + "match_results\030\007 \003(\0132:.google.cloud.a" + + "pihub.v1.DiscoveredApiOperation.MatchResultB\004\342A\001\003\022E\n" + + "\017source_metadata\030\010 \001(\0132&.goo" + + "gle.cloud.apihub.v1.SourceMetadataB\004\342A\001\003\0225\n" + "\013create_time\030\t" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\n" @@ -942,60 +1033,59 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\032CLASSIFICATION_UNSPECIFIED\020\000\022\t\n" + "\005KNOWN\020\001\022\013\n" + "\007UNKNOWN\020\002:\367\001\352A\363\001\n" - + ",apihub.googleapis.com/DiscoveredApiOpe" - + "ration\022\221\001projects/{project}/locations/{l" - + "ocation}/discoveredApiObservations/{discovered_api_observation}/discoveredApiOpe" - + "rations/{discovered_api_operation}*\027disc" - + "overedApiOperations2\026discoveredApiOperationB\013\n" + + ",apihub.googleapis.com/DiscoveredApiOperation\022\221\001proje" + + "cts/{project}/locations/{location}/discoveredApiObservations/{discovered_api_obs" + + "ervation}/discoveredApiOperations/{disco" + + "vered_api_operation}*\027discoveredApiOperations2\026discoveredApiOperationB\013\n" + "\toperation\"\261\014\n" + "\024HttpOperationDetails\022C\n" + "\016http_operation\030\001" + " \001(\0132%.google.cloud.apihub.v1.HttpOperationB\004\342A\001\002\022Q\n" - + "\013path_params\030\002" - + " \003(\01326.google.cloud.apihub.v1.HttpOperationDetails.PathParamB\004\342A\001\001\022Y\n" - + "\014query_params\030\003 \003(\0132=.google.cloud.apihub.v1" - + ".HttpOperationDetails.QueryParamsEntryB\004\342A\001\001\022O\n" - + "\007request\030\004 \001(\01328.google.cloud.api" - + "hub.v1.HttpOperationDetails.HttpRequestB\004\342A\001\001\022Q\n" - + "\010response\030\005 \001(\01329.google.cloud.a" - + "pihub.v1.HttpOperationDetails.HttpResponseB\004\342A\001\001\032s\n" + + "\013path_params\030\002 \003(\01326." + + "google.cloud.apihub.v1.HttpOperationDetails.PathParamB\004\342A\001\001\022Y\n" + + "\014query_params\030\003 \003(" + + "\0132=.google.cloud.apihub.v1.HttpOperationDetails.QueryParamsEntryB\004\342A\001\001\022O\n" + + "\007request\030\004" + + " \001(\01328.google.cloud.apihub.v1.HttpOperationDetails.HttpRequestB\004\342A\001\001\022Q\n" + + "\010response\030\005" + + " \001(\01329.google.cloud.apihub.v1.HttpOperationDetails.HttpResponseB\004\342A\001\001\032s\n" + "\tPathParam\022\026\n" + "\010position\030\001 \001(\005B\004\342A\001\001\022N\n" - + "\tdata_type\030\002 \001(\01625.google.cloud." - + "apihub.v1.HttpOperationDetails.DataTypeB\004\342A\001\001\032\205\001\n\n" + + "\tdata_type\030\002" + + " \001(\01625.google.cloud.apihub.v1.HttpOperationDetails.DataTypeB\004\342A\001\001\032\205\001\n\n" + "QueryParam\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\002\022\023\n" + "\005count\030\002 \001(\003B\004\342A\001\001\022N\n" - + "\tdata_type\030\003 \001(\016" - + "25.google.cloud.apihub.v1.HttpOperationDetails.DataTypeB\004\342A\001\001\032o\n" + + "\tdata_type\030\003 \001(\01625.google.clou" + + "d.apihub.v1.HttpOperationDetails.DataTypeB\004\342A\001\001\032o\n" + "\006Header\022\014\n" + "\004name\030\001 \001(\t\022\r\n" + "\005count\030\002 \001(\003\022H\n" - + "\tdata_type\030\003 \001(\0162" - + "5.google.cloud.apihub.v1.HttpOperationDetails.DataType\032\320\001\n" + + "\tdata_type\030\003 \001(\01625.google.cloud" + + ".apihub.v1.HttpOperationDetails.DataType\032\320\001\n" + "\013HttpRequest\022\\\n" - + "\007headers\030\001 \003(\0132E.google.cloud.apihub.v1.HttpOpe" - + "rationDetails.HttpRequest.HeadersEntryB\004\342A\001\001\032c\n" + + "\007headers\030\001 \003(\0132E.goog" + + "le.cloud.apihub.v1.HttpOperationDetails.HttpRequest.HeadersEntryB\004\342A\001\001\032c\n" + "\014HeadersEntry\022\013\n" + "\003key\030\001 \001(\t\022B\n" - + "\005value\030\002" - + " \001(\01323.google.cloud.apihub.v1.HttpOperationDetails.Header:\0028\001\032\364\002\n" + + "\005value\030\002 \001(\01323.goo" + + "gle.cloud.apihub.v1.HttpOperationDetails.Header:\0028\001\032\364\002\n" + "\014HttpResponse\022]\n" - + "\007headers\030\001 \003(\0132F.google.cloud.apihu" - + "b.v1.HttpOperationDetails.HttpResponse.HeadersEntryB\004\342A\001\001\022j\n" - + "\016response_codes\030\002 \003(\0132L.google.cloud.apihub.v1.HttpOperation" - + "Details.HttpResponse.ResponseCodesEntryB\004\342A\001\001\032c\n" + + "\007headers\030\001 \003(\0132F.google.cloud.apihub.v1.HttpOpera" + + "tionDetails.HttpResponse.HeadersEntryB\004\342A\001\001\022j\n" + + "\016response_codes\030\002 \003(\0132L.google.clo" + + "ud.apihub.v1.HttpOperationDetails.HttpResponse.ResponseCodesEntryB\004\342A\001\001\032c\n" + "\014HeadersEntry\022\013\n" + "\003key\030\001 \001(\t\022B\n" - + "\005value\030\002" - + " \001(\01323.google.cloud.apihub.v1.HttpOperationDetails.Header:\0028\001\0324\n" + + "\005value\030\002 \001(\01323.go" + + "ogle.cloud.apihub.v1.HttpOperationDetails.Header:\0028\001\0324\n" + "\022ResponseCodesEntry\022\013\n" + "\003key\030\001 \001(\005\022\r\n" + "\005value\030\002 \001(\003:\0028\001\032k\n" + "\020QueryParamsEntry\022\013\n" + "\003key\030\001 \001(\t\022F\n" - + "\005value\030\002" - + " \001(\01327.google.cloud.apihub.v1.HttpOperationDetails.QueryParam:\0028\001\"]\n" + + "\005value\030\002 \001(\01327.goo" + + "gle.cloud.apihub.v1.HttpOperationDetails.QueryParam:\0028\001\"]\n" + "\010DataType\022\031\n" + "\025DATA_TYPE_UNSPECIFIED\020\000\022\010\n" + "\004BOOL\020\001\022\013\n" @@ -1023,19 +1113,32 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\026GOOGLE_SERVICE_ACCOUNT\020\002\022\021\n\r" + "USER_PASSWORD\020\003\022\013\n" + "\007API_KEY\020\004\022\035\n" - + "\031OAUTH2_CLIENT_CREDENTIALS\020\005*T\n" + + "\031OAUTH2_CLIENT_CREDENTIALS\020\005*L\n\n" + + "DataSource\022\033\n" + + "\027DATA_SOURCE_UNSPECIFIED\020\000\022\023\n" + + "\017PLUGIN_INSTANCE\020\001\022\014\n" + + "\010ALL_DATA\020\002*\\\n\n" + + "AddonState\022\033\n" + + "\027ADDON_STATE_UNSPECIFIED\020\000\022\n\n" + + "\006ACTIVE\020\001\022\014\n" + + "\010UPDATING\020\002\022\t\n" + + "\005ERROR\020\003\022\014\n" + + "\010INACTIVE\020\004*T\n" + "\016PluginCategory\022\037\n" + "\033PLUGIN_CATEGORY_UNSPECIFIED\020\000\022\017\n" + "\013API_GATEWAY\020\001\022\020\n" - + "\014API_PRODUCER\020\002B\367\002\n" - + "\032com.google.cloud.apihub.v1B\021CommonFieldsProtoP\001Z2cloud.go" - + "ogle.com/go/apihub/apiv1/apihubpb;apihub" - + "pb\252\002\026Google.Cloud.ApiHub.V1\312\002\026Google\\Clo" - + "ud\\ApiHub\\V1\352\002\031Google::Cloud::ApiHub::V1\352Ae\n" - + "#aiplatform.googleapis.com/Extension" - + "\022>projects/{project}/locations/{location}/extensions/{extension}\352AY\n" - + "!iam.googleapis.com/ServiceAccount\0224projects/{projec" - + "t}/serviceAccounts/{service_account}b\006proto3" + + "\014API_PRODUCER\020\002*i\n" + + "\017SpecContentType\022!\n" + + "\035SPEC_CONTENT_TYPE_UNSPECIFIED\020\000\022\030\n" + + "\024BOOSTED_SPEC_CONTENT\020\001\022\031\n" + + "\025GATEWAY_OPEN_API_SPEC\020\002B\367\002\n" + + "\032com.google.cloud.apihub.v1B\021CommonFieldsProtoP\001Z2cloud.google.com/go/api" + + "hub/apiv1/apihubpb;apihubpb\252\002\026Google.Clo" + + "ud.ApiHub.V1\312\002\026Google\\Cloud\\ApiHub\\V1\352\002\031Google::Cloud::ApiHub::V1\352Ae\n" + + "#aiplatform.googleapis.com/Extension\022>projects/{pro" + + "ject}/locations/{location}/extensions/{extension}\352AY\n" + + "!iam.googleapis.com/ServiceAccount\0224projects/{project}/serviceAccou" + + "nts/{service_account}b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -1043,6 +1146,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.Descriptors.FileDescriptor[] { com.google.api.FieldBehaviorProto.getDescriptor(), com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.StructProto.getDescriptor(), com.google.protobuf.TimestampProto.getDescriptor(), }); internal_static_google_cloud_apihub_v1_Api_descriptor = getDescriptor().getMessageType(0); @@ -1070,6 +1174,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "SourceMetadata", "ApiFunctionalRequirements", "ApiTechnicalRequirements", + "ServiceType", }); internal_static_google_cloud_apihub_v1_Api_AttributesEntry_descriptor = internal_static_google_cloud_apihub_v1_Api_descriptor.getNestedType(0); @@ -1127,6 +1232,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Documentation", "ParsingMode", "SourceMetadata", + "AdditionalSpecContents", + "Deployments", }); internal_static_google_cloud_apihub_v1_Spec_AttributesEntry_descriptor = internal_static_google_cloud_apihub_v1_Spec_descriptor.getNestedType(0); @@ -1136,8 +1243,24 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Key", "Value", }); - internal_static_google_cloud_apihub_v1_Deployment_descriptor = + internal_static_google_cloud_apihub_v1_AdditionalSpecContent_descriptor = getDescriptor().getMessageType(3); + internal_static_google_cloud_apihub_v1_AdditionalSpecContent_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_AdditionalSpecContent_descriptor, + new java.lang.String[] { + "SpecContentType", "SpecContents", "CreateTime", "UpdateTime", "Labels", + }); + internal_static_google_cloud_apihub_v1_AdditionalSpecContent_LabelsEntry_descriptor = + internal_static_google_cloud_apihub_v1_AdditionalSpecContent_descriptor.getNestedType(0); + internal_static_google_cloud_apihub_v1_AdditionalSpecContent_LabelsEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_AdditionalSpecContent_LabelsEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_apihub_v1_Deployment_descriptor = + getDescriptor().getMessageType(4); internal_static_google_cloud_apihub_v1_Deployment_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Deployment_descriptor, @@ -1160,6 +1283,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "SourceUri", "SourceProject", "SourceEnvironment", + "Specs", + "ApiOperations", + "SourceRevision", }); internal_static_google_cloud_apihub_v1_Deployment_AttributesEntry_descriptor = internal_static_google_cloud_apihub_v1_Deployment_descriptor.getNestedType(0); @@ -1170,12 +1296,19 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Key", "Value", }); internal_static_google_cloud_apihub_v1_ApiOperation_descriptor = - getDescriptor().getMessageType(4); + getDescriptor().getMessageType(5); internal_static_google_cloud_apihub_v1_ApiOperation_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ApiOperation_descriptor, new java.lang.String[] { - "Name", "Spec", "Details", "CreateTime", "UpdateTime", "Attributes", "SourceMetadata", + "Name", + "Spec", + "Details", + "CreateTime", + "UpdateTime", + "Attributes", + "SourceMetadata", + "Deployments", }); internal_static_google_cloud_apihub_v1_ApiOperation_AttributesEntry_descriptor = internal_static_google_cloud_apihub_v1_ApiOperation_descriptor.getNestedType(0); @@ -1186,7 +1319,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Key", "Value", }); internal_static_google_cloud_apihub_v1_Definition_descriptor = - getDescriptor().getMessageType(5); + getDescriptor().getMessageType(6); internal_static_google_cloud_apihub_v1_Definition_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Definition_descriptor, @@ -1201,7 +1334,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Key", "Value", }); - internal_static_google_cloud_apihub_v1_Attribute_descriptor = getDescriptor().getMessageType(6); + internal_static_google_cloud_apihub_v1_Attribute_descriptor = getDescriptor().getMessageType(7); internal_static_google_cloud_apihub_v1_Attribute_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Attribute_descriptor, @@ -1227,7 +1360,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Id", "DisplayName", "Description", "Immutable", }); internal_static_google_cloud_apihub_v1_SpecContents_descriptor = - getDescriptor().getMessageType(7); + getDescriptor().getMessageType(8); internal_static_google_cloud_apihub_v1_SpecContents_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_SpecContents_descriptor, @@ -1235,7 +1368,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Contents", "MimeType", }); internal_static_google_cloud_apihub_v1_SpecDetails_descriptor = - getDescriptor().getMessageType(8); + getDescriptor().getMessageType(9); internal_static_google_cloud_apihub_v1_SpecDetails_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_SpecDetails_descriptor, @@ -1243,7 +1376,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "OpenApiSpecDetails", "Description", "Details", }); internal_static_google_cloud_apihub_v1_OpenApiSpecDetails_descriptor = - getDescriptor().getMessageType(9); + getDescriptor().getMessageType(10); internal_static_google_cloud_apihub_v1_OpenApiSpecDetails_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_OpenApiSpecDetails_descriptor, @@ -1251,36 +1384,72 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Format", "Version", "Owner", }); internal_static_google_cloud_apihub_v1_OperationDetails_descriptor = - getDescriptor().getMessageType(10); + getDescriptor().getMessageType(11); internal_static_google_cloud_apihub_v1_OperationDetails_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_OperationDetails_descriptor, new java.lang.String[] { - "HttpOperation", "Description", "Documentation", "Deprecated", "Operation", + "HttpOperation", "McpTool", "Description", "Documentation", "Deprecated", "Operation", + }); + internal_static_google_cloud_apihub_v1_OperationSchema_descriptor = + getDescriptor().getMessageType(12); + internal_static_google_cloud_apihub_v1_OperationSchema_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_OperationSchema_descriptor, + new java.lang.String[] { + "JsonSchema", "Value", + }); + internal_static_google_cloud_apihub_v1_McpTool_descriptor = getDescriptor().getMessageType(13); + internal_static_google_cloud_apihub_v1_McpTool_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_McpTool_descriptor, + new java.lang.String[] { + "Name", "Title", "Description", "Annotations", "InputSchema", "OutputSchema", + }); + internal_static_google_cloud_apihub_v1_ToolAnnotations_descriptor = + getDescriptor().getMessageType(14); + internal_static_google_cloud_apihub_v1_ToolAnnotations_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ToolAnnotations_descriptor, + new java.lang.String[] { + "Title", + "ReadOnlyHint", + "DestructiveHint", + "IdempotentHint", + "OpenWorldHint", + "AdditionalHints", + }); + internal_static_google_cloud_apihub_v1_ToolAnnotations_AdditionalHintsEntry_descriptor = + internal_static_google_cloud_apihub_v1_ToolAnnotations_descriptor.getNestedType(0); + internal_static_google_cloud_apihub_v1_ToolAnnotations_AdditionalHintsEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ToolAnnotations_AdditionalHintsEntry_descriptor, + new java.lang.String[] { + "Key", "Value", }); internal_static_google_cloud_apihub_v1_HttpOperation_descriptor = - getDescriptor().getMessageType(11); + getDescriptor().getMessageType(15); internal_static_google_cloud_apihub_v1_HttpOperation_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_HttpOperation_descriptor, new java.lang.String[] { "Path", "Method", }); - internal_static_google_cloud_apihub_v1_Path_descriptor = getDescriptor().getMessageType(12); + internal_static_google_cloud_apihub_v1_Path_descriptor = getDescriptor().getMessageType(16); internal_static_google_cloud_apihub_v1_Path_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Path_descriptor, new java.lang.String[] { "Path", "Description", }); - internal_static_google_cloud_apihub_v1_Schema_descriptor = getDescriptor().getMessageType(13); + internal_static_google_cloud_apihub_v1_Schema_descriptor = getDescriptor().getMessageType(17); internal_static_google_cloud_apihub_v1_Schema_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Schema_descriptor, new java.lang.String[] { "DisplayName", "RawValue", }); - internal_static_google_cloud_apihub_v1_Owner_descriptor = getDescriptor().getMessageType(14); + internal_static_google_cloud_apihub_v1_Owner_descriptor = getDescriptor().getMessageType(18); internal_static_google_cloud_apihub_v1_Owner_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Owner_descriptor, @@ -1288,7 +1457,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "DisplayName", "Email", }); internal_static_google_cloud_apihub_v1_Documentation_descriptor = - getDescriptor().getMessageType(15); + getDescriptor().getMessageType(19); internal_static_google_cloud_apihub_v1_Documentation_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Documentation_descriptor, @@ -1296,7 +1465,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ExternalUri", }); internal_static_google_cloud_apihub_v1_AttributeValues_descriptor = - getDescriptor().getMessageType(16); + getDescriptor().getMessageType(20); internal_static_google_cloud_apihub_v1_AttributeValues_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_AttributeValues_descriptor, @@ -1320,7 +1489,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Values", }); internal_static_google_cloud_apihub_v1_Dependency_descriptor = - getDescriptor().getMessageType(17); + getDescriptor().getMessageType(21); internal_static_google_cloud_apihub_v1_Dependency_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Dependency_descriptor, @@ -1345,7 +1514,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Key", "Value", }); internal_static_google_cloud_apihub_v1_DependencyEntityReference_descriptor = - getDescriptor().getMessageType(18); + getDescriptor().getMessageType(22); internal_static_google_cloud_apihub_v1_DependencyEntityReference_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DependencyEntityReference_descriptor, @@ -1353,7 +1522,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "OperationResourceName", "ExternalApiResourceName", "DisplayName", "Identifier", }); internal_static_google_cloud_apihub_v1_DependencyErrorDetail_descriptor = - getDescriptor().getMessageType(19); + getDescriptor().getMessageType(23); internal_static_google_cloud_apihub_v1_DependencyErrorDetail_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DependencyErrorDetail_descriptor, @@ -1361,7 +1530,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Error", "ErrorTime", }); internal_static_google_cloud_apihub_v1_LintResponse_descriptor = - getDescriptor().getMessageType(20); + getDescriptor().getMessageType(24); internal_static_google_cloud_apihub_v1_LintResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_LintResponse_descriptor, @@ -1376,21 +1545,21 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Severity", "Count", }); - internal_static_google_cloud_apihub_v1_Issue_descriptor = getDescriptor().getMessageType(21); + internal_static_google_cloud_apihub_v1_Issue_descriptor = getDescriptor().getMessageType(25); internal_static_google_cloud_apihub_v1_Issue_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Issue_descriptor, new java.lang.String[] { "Code", "Path", "Message", "Severity", "Range", }); - internal_static_google_cloud_apihub_v1_Range_descriptor = getDescriptor().getMessageType(22); + internal_static_google_cloud_apihub_v1_Range_descriptor = getDescriptor().getMessageType(26); internal_static_google_cloud_apihub_v1_Range_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Range_descriptor, new java.lang.String[] { "Start", "End", }); - internal_static_google_cloud_apihub_v1_Point_descriptor = getDescriptor().getMessageType(23); + internal_static_google_cloud_apihub_v1_Point_descriptor = getDescriptor().getMessageType(27); internal_static_google_cloud_apihub_v1_Point_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Point_descriptor, @@ -1398,7 +1567,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Line", "Character", }); internal_static_google_cloud_apihub_v1_OperationMetadata_descriptor = - getDescriptor().getMessageType(24); + getDescriptor().getMessageType(28); internal_static_google_cloud_apihub_v1_OperationMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_OperationMetadata_descriptor, @@ -1412,7 +1581,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ApiVersion", }); internal_static_google_cloud_apihub_v1_ApiHubInstance_descriptor = - getDescriptor().getMessageType(25); + getDescriptor().getMessageType(29); internal_static_google_cloud_apihub_v1_ApiHubInstance_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ApiHubInstance_descriptor, @@ -1432,7 +1601,19 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_descriptor, new java.lang.String[] { - "CmekKeyName", "DisableSearch", "VertexLocation", "EncryptionType", + "CmekKeyName", + "DisableSearch", + "VertexLocation", + "EncryptionType", + "AgentRegistrySyncConfig", + }); + internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_AgentRegistrySyncConfig_descriptor = + internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_descriptor.getNestedType(0); + internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_AgentRegistrySyncConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ApiHubInstance_Config_AgentRegistrySyncConfig_descriptor, + new java.lang.String[] { + "Disabled", }); internal_static_google_cloud_apihub_v1_ApiHubInstance_LabelsEntry_descriptor = internal_static_google_cloud_apihub_v1_ApiHubInstance_descriptor.getNestedType(1); @@ -1443,7 +1624,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Key", "Value", }); internal_static_google_cloud_apihub_v1_ExternalApi_descriptor = - getDescriptor().getMessageType(26); + getDescriptor().getMessageType(30); internal_static_google_cloud_apihub_v1_ExternalApi_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ExternalApi_descriptor, @@ -1467,14 +1648,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Key", "Value", }); internal_static_google_cloud_apihub_v1_ConfigValueOption_descriptor = - getDescriptor().getMessageType(27); + getDescriptor().getMessageType(31); internal_static_google_cloud_apihub_v1_ConfigValueOption_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ConfigValueOption_descriptor, new java.lang.String[] { "Id", "DisplayName", "Description", }); - internal_static_google_cloud_apihub_v1_Secret_descriptor = getDescriptor().getMessageType(28); + internal_static_google_cloud_apihub_v1_Secret_descriptor = getDescriptor().getMessageType(32); internal_static_google_cloud_apihub_v1_Secret_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_Secret_descriptor, @@ -1482,7 +1663,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "SecretVersion", }); internal_static_google_cloud_apihub_v1_ConfigVariableTemplate_descriptor = - getDescriptor().getMessageType(29); + getDescriptor().getMessageType(33); internal_static_google_cloud_apihub_v1_ConfigVariableTemplate_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ConfigVariableTemplate_descriptor, @@ -1496,7 +1677,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "MultiSelectOptions", }); internal_static_google_cloud_apihub_v1_ConfigVariable_descriptor = - getDescriptor().getMessageType(30); + getDescriptor().getMessageType(34); internal_static_google_cloud_apihub_v1_ConfigVariable_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ConfigVariable_descriptor, @@ -1537,7 +1718,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Values", }); internal_static_google_cloud_apihub_v1_GoogleServiceAccountConfig_descriptor = - getDescriptor().getMessageType(31); + getDescriptor().getMessageType(35); internal_static_google_cloud_apihub_v1_GoogleServiceAccountConfig_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_GoogleServiceAccountConfig_descriptor, @@ -1545,7 +1726,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ServiceAccount", }); internal_static_google_cloud_apihub_v1_AuthConfig_descriptor = - getDescriptor().getMessageType(32); + getDescriptor().getMessageType(36); internal_static_google_cloud_apihub_v1_AuthConfig_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_AuthConfig_descriptor, @@ -1582,7 +1763,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "ApiKey", "HttpElementLocation", }); internal_static_google_cloud_apihub_v1_SourceMetadata_descriptor = - getDescriptor().getMessageType(33); + getDescriptor().getMessageType(37); internal_static_google_cloud_apihub_v1_SourceMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_SourceMetadata_descriptor, @@ -1603,7 +1784,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "PluginInstance", "ActionId", }); internal_static_google_cloud_apihub_v1_DiscoveredApiObservation_descriptor = - getDescriptor().getMessageType(34); + getDescriptor().getMessageType(38); internal_static_google_cloud_apihub_v1_DiscoveredApiObservation_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DiscoveredApiObservation_descriptor, @@ -1624,7 +1805,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "SourceMetadata", }); internal_static_google_cloud_apihub_v1_DiscoveredApiOperation_descriptor = - getDescriptor().getMessageType(35); + getDescriptor().getMessageType(39); internal_static_google_cloud_apihub_v1_DiscoveredApiOperation_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DiscoveredApiOperation_descriptor, @@ -1650,7 +1831,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_HttpOperationDetails_descriptor = - getDescriptor().getMessageType(36); + getDescriptor().getMessageType(40); internal_static_google_cloud_apihub_v1_HttpOperationDetails_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_HttpOperationDetails_descriptor, @@ -1735,6 +1916,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { descriptor.resolveAllFeaturesImmutable(); com.google.api.FieldBehaviorProto.getDescriptor(); com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.StructProto.getDescriptor(); com.google.protobuf.TimestampProto.getDescriptor(); com.google.protobuf.ExtensionRegistry registry = com.google.protobuf.ExtensionRegistry.newInstance(); diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerRequest.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerRequest.java new file mode 100644 index 000000000000..0764e7558fc3 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerRequest.java @@ -0,0 +1,1003 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Request message for
                      + * [ApiHub.ConfigureAndDeployServer][google.cloud.apihub.v1.ApiHub.ConfigureAndDeployServer].
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ConfigureAndDeployServerRequest} + */ +@com.google.protobuf.Generated +public final class ConfigureAndDeployServerRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ConfigureAndDeployServerRequest) + ConfigureAndDeployServerRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ConfigureAndDeployServerRequest"); + } + + // Use ConfigureAndDeployServerRequest.newBuilder() to construct. + private ConfigureAndDeployServerRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ConfigureAndDeployServerRequest() { + parent_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest.class, + com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest.Builder.class); + } + + private int serverConfigCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object serverConfig_; + + public enum ServerConfigCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + MCP_SERVER_CONFIG(2), + SERVERCONFIG_NOT_SET(0); + private final int value; + + private ServerConfigCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ServerConfigCase valueOf(int value) { + return forNumber(value); + } + + public static ServerConfigCase forNumber(int value) { + switch (value) { + case 2: + return MCP_SERVER_CONFIG; + case 0: + return SERVERCONFIG_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ServerConfigCase getServerConfigCase() { + return ServerConfigCase.forNumber(serverConfigCase_); + } + + public static final int MCP_SERVER_CONFIG_FIELD_NUMBER = 2; + + /** + * + * + *
                      +   * MCP (Model Context Protocol) server configuration.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + * + * @return Whether the mcpServerConfig field is set. + */ + @java.lang.Override + public boolean hasMcpServerConfig() { + return serverConfigCase_ == 2; + } + + /** + * + * + *
                      +   * MCP (Model Context Protocol) server configuration.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + * + * @return The mcpServerConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig getMcpServerConfig() { + if (serverConfigCase_ == 2) { + return (com.google.cloud.apihub.v1.McpServerConfig) serverConfig_; + } + return com.google.cloud.apihub.v1.McpServerConfig.getDefaultInstance(); + } + + /** + * + * + *
                      +   * MCP (Model Context Protocol) server configuration.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfigOrBuilder getMcpServerConfigOrBuilder() { + if (serverConfigCase_ == 2) { + return (com.google.cloud.apihub.v1.McpServerConfig) serverConfig_; + } + return com.google.cloud.apihub.v1.McpServerConfig.getDefaultInstance(); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
                      +   * Required. Format: `projects/{project}/locations/{location}`
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. Format: `projects/{project}/locations/{location}`
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (serverConfigCase_ == 2) { + output.writeMessage(2, (com.google.cloud.apihub.v1.McpServerConfig) serverConfig_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (serverConfigCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.apihub.v1.McpServerConfig) serverConfig_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest other = + (com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (!getServerConfigCase().equals(other.getServerConfigCase())) return false; + switch (serverConfigCase_) { + case 2: + if (!getMcpServerConfig().equals(other.getMcpServerConfig())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + switch (serverConfigCase_) { + case 2: + hash = (37 * hash) + MCP_SERVER_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getMcpServerConfig().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Request message for
                      +   * [ApiHub.ConfigureAndDeployServer][google.cloud.apihub.v1.ApiHub.ConfigureAndDeployServer].
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ConfigureAndDeployServerRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ConfigureAndDeployServerRequest) + com.google.cloud.apihub.v1.ConfigureAndDeployServerRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest.class, + com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (mcpServerConfigBuilder_ != null) { + mcpServerConfigBuilder_.clear(); + } + parent_ = ""; + serverConfigCase_ = 0; + serverConfig_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest build() { + com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest buildPartial() { + com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest result = + new com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.parent_ = parent_; + } + } + + private void buildPartialOneofs( + com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest result) { + result.serverConfigCase_ = serverConfigCase_; + result.serverConfig_ = this.serverConfig_; + if (serverConfigCase_ == 2 && mcpServerConfigBuilder_ != null) { + result.serverConfig_ = mcpServerConfigBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest) { + return mergeFrom((com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest other) { + if (other == com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000002; + onChanged(); + } + switch (other.getServerConfigCase()) { + case MCP_SERVER_CONFIG: + { + mergeMcpServerConfig(other.getMcpServerConfig()); + break; + } + case SERVERCONFIG_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetMcpServerConfigFieldBuilder().getBuilder(), extensionRegistry); + serverConfigCase_ = 2; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int serverConfigCase_ = 0; + private java.lang.Object serverConfig_; + + public ServerConfigCase getServerConfigCase() { + return ServerConfigCase.forNumber(serverConfigCase_); + } + + public Builder clearServerConfig() { + serverConfigCase_ = 0; + serverConfig_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.McpServerConfig, + com.google.cloud.apihub.v1.McpServerConfig.Builder, + com.google.cloud.apihub.v1.McpServerConfigOrBuilder> + mcpServerConfigBuilder_; + + /** + * + * + *
                      +     * MCP (Model Context Protocol) server configuration.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + * + * @return Whether the mcpServerConfig field is set. + */ + @java.lang.Override + public boolean hasMcpServerConfig() { + return serverConfigCase_ == 2; + } + + /** + * + * + *
                      +     * MCP (Model Context Protocol) server configuration.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + * + * @return The mcpServerConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig getMcpServerConfig() { + if (mcpServerConfigBuilder_ == null) { + if (serverConfigCase_ == 2) { + return (com.google.cloud.apihub.v1.McpServerConfig) serverConfig_; + } + return com.google.cloud.apihub.v1.McpServerConfig.getDefaultInstance(); + } else { + if (serverConfigCase_ == 2) { + return mcpServerConfigBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.McpServerConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * MCP (Model Context Protocol) server configuration.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + */ + public Builder setMcpServerConfig(com.google.cloud.apihub.v1.McpServerConfig value) { + if (mcpServerConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + serverConfig_ = value; + onChanged(); + } else { + mcpServerConfigBuilder_.setMessage(value); + } + serverConfigCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * MCP (Model Context Protocol) server configuration.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + */ + public Builder setMcpServerConfig( + com.google.cloud.apihub.v1.McpServerConfig.Builder builderForValue) { + if (mcpServerConfigBuilder_ == null) { + serverConfig_ = builderForValue.build(); + onChanged(); + } else { + mcpServerConfigBuilder_.setMessage(builderForValue.build()); + } + serverConfigCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * MCP (Model Context Protocol) server configuration.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + */ + public Builder mergeMcpServerConfig(com.google.cloud.apihub.v1.McpServerConfig value) { + if (mcpServerConfigBuilder_ == null) { + if (serverConfigCase_ == 2 + && serverConfig_ != com.google.cloud.apihub.v1.McpServerConfig.getDefaultInstance()) { + serverConfig_ = + com.google.cloud.apihub.v1.McpServerConfig.newBuilder( + (com.google.cloud.apihub.v1.McpServerConfig) serverConfig_) + .mergeFrom(value) + .buildPartial(); + } else { + serverConfig_ = value; + } + onChanged(); + } else { + if (serverConfigCase_ == 2) { + mcpServerConfigBuilder_.mergeFrom(value); + } else { + mcpServerConfigBuilder_.setMessage(value); + } + } + serverConfigCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * MCP (Model Context Protocol) server configuration.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + */ + public Builder clearMcpServerConfig() { + if (mcpServerConfigBuilder_ == null) { + if (serverConfigCase_ == 2) { + serverConfigCase_ = 0; + serverConfig_ = null; + onChanged(); + } + } else { + if (serverConfigCase_ == 2) { + serverConfigCase_ = 0; + serverConfig_ = null; + } + mcpServerConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * MCP (Model Context Protocol) server configuration.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + */ + public com.google.cloud.apihub.v1.McpServerConfig.Builder getMcpServerConfigBuilder() { + return internalGetMcpServerConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * MCP (Model Context Protocol) server configuration.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfigOrBuilder getMcpServerConfigOrBuilder() { + if ((serverConfigCase_ == 2) && (mcpServerConfigBuilder_ != null)) { + return mcpServerConfigBuilder_.getMessageOrBuilder(); + } else { + if (serverConfigCase_ == 2) { + return (com.google.cloud.apihub.v1.McpServerConfig) serverConfig_; + } + return com.google.cloud.apihub.v1.McpServerConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * MCP (Model Context Protocol) server configuration.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.McpServerConfig, + com.google.cloud.apihub.v1.McpServerConfig.Builder, + com.google.cloud.apihub.v1.McpServerConfigOrBuilder> + internalGetMcpServerConfigFieldBuilder() { + if (mcpServerConfigBuilder_ == null) { + if (!(serverConfigCase_ == 2)) { + serverConfig_ = com.google.cloud.apihub.v1.McpServerConfig.getDefaultInstance(); + } + mcpServerConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.McpServerConfig, + com.google.cloud.apihub.v1.McpServerConfig.Builder, + com.google.cloud.apihub.v1.McpServerConfigOrBuilder>( + (com.google.cloud.apihub.v1.McpServerConfig) serverConfig_, + getParentForChildren(), + isClean()); + serverConfig_ = null; + } + serverConfigCase_ = 2; + onChanged(); + return mcpServerConfigBuilder_; + } + + private java.lang.Object parent_ = ""; + + /** + * + * + *
                      +     * Required. Format: `projects/{project}/locations/{location}`
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. Format: `projects/{project}/locations/{location}`
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. Format: `projects/{project}/locations/{location}`
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. Format: `projects/{project}/locations/{location}`
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. Format: `projects/{project}/locations/{location}`
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ConfigureAndDeployServerRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ConfigureAndDeployServerRequest) + private static final com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest(); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ConfigureAndDeployServerRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerRequestOrBuilder.java new file mode 100644 index 000000000000..931b585d954d --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerRequestOrBuilder.java @@ -0,0 +1,97 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ConfigureAndDeployServerRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ConfigureAndDeployServerRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * MCP (Model Context Protocol) server configuration.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + * + * @return Whether the mcpServerConfig field is set. + */ + boolean hasMcpServerConfig(); + + /** + * + * + *
                      +   * MCP (Model Context Protocol) server configuration.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + * + * @return The mcpServerConfig. + */ + com.google.cloud.apihub.v1.McpServerConfig getMcpServerConfig(); + + /** + * + * + *
                      +   * MCP (Model Context Protocol) server configuration.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerConfig mcp_server_config = 2; + */ + com.google.cloud.apihub.v1.McpServerConfigOrBuilder getMcpServerConfigOrBuilder(); + + /** + * + * + *
                      +   * Required. Format: `projects/{project}/locations/{location}`
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
                      +   * Required. Format: `projects/{project}/locations/{location}`
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest.ServerConfigCase getServerConfigCase(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerResponse.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerResponse.java new file mode 100644 index 000000000000..a3341d269042 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerResponse.java @@ -0,0 +1,800 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Response message for
                      + * [ApiHub.ConfigureAndDeployServer][google.cloud.apihub.v1.ApiHub.ConfigureAndDeployServer].
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ConfigureAndDeployServerResponse} + */ +@com.google.protobuf.Generated +public final class ConfigureAndDeployServerResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ConfigureAndDeployServerResponse) + ConfigureAndDeployServerResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ConfigureAndDeployServerResponse"); + } + + // Use ConfigureAndDeployServerResponse.newBuilder() to construct. + private ConfigureAndDeployServerResponse( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ConfigureAndDeployServerResponse() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse.class, + com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse.Builder.class); + } + + private int serverDetailsCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object serverDetails_; + + public enum ServerDetailsCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + MCP_SERVER_DETAILS(1), + SERVERDETAILS_NOT_SET(0); + private final int value; + + private ServerDetailsCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ServerDetailsCase valueOf(int value) { + return forNumber(value); + } + + public static ServerDetailsCase forNumber(int value) { + switch (value) { + case 1: + return MCP_SERVER_DETAILS; + case 0: + return SERVERDETAILS_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ServerDetailsCase getServerDetailsCase() { + return ServerDetailsCase.forNumber(serverDetailsCase_); + } + + public static final int MCP_SERVER_DETAILS_FIELD_NUMBER = 1; + + /** + * + * + *
                      +   * MCP server result.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + * + * @return Whether the mcpServerDetails field is set. + */ + @java.lang.Override + public boolean hasMcpServerDetails() { + return serverDetailsCase_ == 1; + } + + /** + * + * + *
                      +   * MCP server result.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + * + * @return The mcpServerDetails. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerDetails getMcpServerDetails() { + if (serverDetailsCase_ == 1) { + return (com.google.cloud.apihub.v1.McpServerDetails) serverDetails_; + } + return com.google.cloud.apihub.v1.McpServerDetails.getDefaultInstance(); + } + + /** + * + * + *
                      +   * MCP server result.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerDetailsOrBuilder getMcpServerDetailsOrBuilder() { + if (serverDetailsCase_ == 1) { + return (com.google.cloud.apihub.v1.McpServerDetails) serverDetails_; + } + return com.google.cloud.apihub.v1.McpServerDetails.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (serverDetailsCase_ == 1) { + output.writeMessage(1, (com.google.cloud.apihub.v1.McpServerDetails) serverDetails_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (serverDetailsCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.cloud.apihub.v1.McpServerDetails) serverDetails_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse other = + (com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse) obj; + + if (!getServerDetailsCase().equals(other.getServerDetailsCase())) return false; + switch (serverDetailsCase_) { + case 1: + if (!getMcpServerDetails().equals(other.getMcpServerDetails())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (serverDetailsCase_) { + case 1: + hash = (37 * hash) + MCP_SERVER_DETAILS_FIELD_NUMBER; + hash = (53 * hash) + getMcpServerDetails().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Response message for
                      +   * [ApiHub.ConfigureAndDeployServer][google.cloud.apihub.v1.ApiHub.ConfigureAndDeployServer].
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ConfigureAndDeployServerResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ConfigureAndDeployServerResponse) + com.google.cloud.apihub.v1.ConfigureAndDeployServerResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse.class, + com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (mcpServerDetailsBuilder_ != null) { + mcpServerDetailsBuilder_.clear(); + } + serverDetailsCase_ = 0; + serverDetails_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_ConfigureAndDeployServerResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse build() { + com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse buildPartial() { + com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse result = + new com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse result) { + int from_bitField0_ = bitField0_; + } + + private void buildPartialOneofs( + com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse result) { + result.serverDetailsCase_ = serverDetailsCase_; + result.serverDetails_ = this.serverDetails_; + if (serverDetailsCase_ == 1 && mcpServerDetailsBuilder_ != null) { + result.serverDetails_ = mcpServerDetailsBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse) { + return mergeFrom((com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse other) { + if (other == com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse.getDefaultInstance()) + return this; + switch (other.getServerDetailsCase()) { + case MCP_SERVER_DETAILS: + { + mergeMcpServerDetails(other.getMcpServerDetails()); + break; + } + case SERVERDETAILS_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetMcpServerDetailsFieldBuilder().getBuilder(), extensionRegistry); + serverDetailsCase_ = 1; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int serverDetailsCase_ = 0; + private java.lang.Object serverDetails_; + + public ServerDetailsCase getServerDetailsCase() { + return ServerDetailsCase.forNumber(serverDetailsCase_); + } + + public Builder clearServerDetails() { + serverDetailsCase_ = 0; + serverDetails_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.McpServerDetails, + com.google.cloud.apihub.v1.McpServerDetails.Builder, + com.google.cloud.apihub.v1.McpServerDetailsOrBuilder> + mcpServerDetailsBuilder_; + + /** + * + * + *
                      +     * MCP server result.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + * + * @return Whether the mcpServerDetails field is set. + */ + @java.lang.Override + public boolean hasMcpServerDetails() { + return serverDetailsCase_ == 1; + } + + /** + * + * + *
                      +     * MCP server result.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + * + * @return The mcpServerDetails. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerDetails getMcpServerDetails() { + if (mcpServerDetailsBuilder_ == null) { + if (serverDetailsCase_ == 1) { + return (com.google.cloud.apihub.v1.McpServerDetails) serverDetails_; + } + return com.google.cloud.apihub.v1.McpServerDetails.getDefaultInstance(); + } else { + if (serverDetailsCase_ == 1) { + return mcpServerDetailsBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.McpServerDetails.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * MCP server result.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + */ + public Builder setMcpServerDetails(com.google.cloud.apihub.v1.McpServerDetails value) { + if (mcpServerDetailsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + serverDetails_ = value; + onChanged(); + } else { + mcpServerDetailsBuilder_.setMessage(value); + } + serverDetailsCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * MCP server result.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + */ + public Builder setMcpServerDetails( + com.google.cloud.apihub.v1.McpServerDetails.Builder builderForValue) { + if (mcpServerDetailsBuilder_ == null) { + serverDetails_ = builderForValue.build(); + onChanged(); + } else { + mcpServerDetailsBuilder_.setMessage(builderForValue.build()); + } + serverDetailsCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * MCP server result.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + */ + public Builder mergeMcpServerDetails(com.google.cloud.apihub.v1.McpServerDetails value) { + if (mcpServerDetailsBuilder_ == null) { + if (serverDetailsCase_ == 1 + && serverDetails_ != com.google.cloud.apihub.v1.McpServerDetails.getDefaultInstance()) { + serverDetails_ = + com.google.cloud.apihub.v1.McpServerDetails.newBuilder( + (com.google.cloud.apihub.v1.McpServerDetails) serverDetails_) + .mergeFrom(value) + .buildPartial(); + } else { + serverDetails_ = value; + } + onChanged(); + } else { + if (serverDetailsCase_ == 1) { + mcpServerDetailsBuilder_.mergeFrom(value); + } else { + mcpServerDetailsBuilder_.setMessage(value); + } + } + serverDetailsCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * MCP server result.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + */ + public Builder clearMcpServerDetails() { + if (mcpServerDetailsBuilder_ == null) { + if (serverDetailsCase_ == 1) { + serverDetailsCase_ = 0; + serverDetails_ = null; + onChanged(); + } + } else { + if (serverDetailsCase_ == 1) { + serverDetailsCase_ = 0; + serverDetails_ = null; + } + mcpServerDetailsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * MCP server result.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + */ + public com.google.cloud.apihub.v1.McpServerDetails.Builder getMcpServerDetailsBuilder() { + return internalGetMcpServerDetailsFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * MCP server result.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerDetailsOrBuilder getMcpServerDetailsOrBuilder() { + if ((serverDetailsCase_ == 1) && (mcpServerDetailsBuilder_ != null)) { + return mcpServerDetailsBuilder_.getMessageOrBuilder(); + } else { + if (serverDetailsCase_ == 1) { + return (com.google.cloud.apihub.v1.McpServerDetails) serverDetails_; + } + return com.google.cloud.apihub.v1.McpServerDetails.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * MCP server result.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.McpServerDetails, + com.google.cloud.apihub.v1.McpServerDetails.Builder, + com.google.cloud.apihub.v1.McpServerDetailsOrBuilder> + internalGetMcpServerDetailsFieldBuilder() { + if (mcpServerDetailsBuilder_ == null) { + if (!(serverDetailsCase_ == 1)) { + serverDetails_ = com.google.cloud.apihub.v1.McpServerDetails.getDefaultInstance(); + } + mcpServerDetailsBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.McpServerDetails, + com.google.cloud.apihub.v1.McpServerDetails.Builder, + com.google.cloud.apihub.v1.McpServerDetailsOrBuilder>( + (com.google.cloud.apihub.v1.McpServerDetails) serverDetails_, + getParentForChildren(), + isClean()); + serverDetails_ = null; + } + serverDetailsCase_ = 1; + onChanged(); + return mcpServerDetailsBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ConfigureAndDeployServerResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ConfigureAndDeployServerResponse) + private static final com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse(); + } + + public static com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ConfigureAndDeployServerResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerResponseOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerResponseOrBuilder.java new file mode 100644 index 000000000000..a15c1e68bea1 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ConfigureAndDeployServerResponseOrBuilder.java @@ -0,0 +1,68 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ConfigureAndDeployServerResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ConfigureAndDeployServerResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * MCP server result.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + * + * @return Whether the mcpServerDetails field is set. + */ + boolean hasMcpServerDetails(); + + /** + * + * + *
                      +   * MCP server result.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + * + * @return The mcpServerDetails. + */ + com.google.cloud.apihub.v1.McpServerDetails getMcpServerDetails(); + + /** + * + * + *
                      +   * MCP server result.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpServerDetails mcp_server_details = 1; + */ + com.google.cloud.apihub.v1.McpServerDetailsOrBuilder getMcpServerDetailsOrBuilder(); + + com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse.ServerDetailsCase + getServerDetailsCase(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CreateApiOperationRequest.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CreateApiOperationRequest.java index a793f456397e..e719e2a16c67 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CreateApiOperationRequest.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CreateApiOperationRequest.java @@ -154,7 +154,7 @@ public com.google.protobuf.ByteString getParentBytes() { * This value should be 4-500 characters, overall resource name which * will be of format * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - * its length is limited to 700 characters, and valid characters are + * its length is limited to 1000 characters, and valid characters are * /[a-z][A-Z][0-9]-_/. *
                      * @@ -190,7 +190,7 @@ public java.lang.String getApiOperationId() { * This value should be 4-500 characters, overall resource name which * will be of format * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - * its length is limited to 700 characters, and valid characters are + * its length is limited to 1000 characters, and valid characters are * /[a-z][A-Z][0-9]-_/. *
                      * @@ -798,7 +798,7 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) { * This value should be 4-500 characters, overall resource name which * will be of format * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - * its length is limited to 700 characters, and valid characters are + * its length is limited to 1000 characters, and valid characters are * /[a-z][A-Z][0-9]-_/. *
                      * @@ -833,7 +833,7 @@ public java.lang.String getApiOperationId() { * This value should be 4-500 characters, overall resource name which * will be of format * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - * its length is limited to 700 characters, and valid characters are + * its length is limited to 1000 characters, and valid characters are * /[a-z][A-Z][0-9]-_/. *
                      * @@ -868,7 +868,7 @@ public com.google.protobuf.ByteString getApiOperationIdBytes() { * This value should be 4-500 characters, overall resource name which * will be of format * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - * its length is limited to 700 characters, and valid characters are + * its length is limited to 1000 characters, and valid characters are * /[a-z][A-Z][0-9]-_/. *
                      * @@ -902,7 +902,7 @@ public Builder setApiOperationId(java.lang.String value) { * This value should be 4-500 characters, overall resource name which * will be of format * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - * its length is limited to 700 characters, and valid characters are + * its length is limited to 1000 characters, and valid characters are * /[a-z][A-Z][0-9]-_/. *
                      * @@ -932,7 +932,7 @@ public Builder clearApiOperationId() { * This value should be 4-500 characters, overall resource name which * will be of format * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - * its length is limited to 700 characters, and valid characters are + * its length is limited to 1000 characters, and valid characters are * /[a-z][A-Z][0-9]-_/. *
                      * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CreateApiOperationRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CreateApiOperationRequestOrBuilder.java index b2da7f3980db..ae6d104cf425 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CreateApiOperationRequestOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CreateApiOperationRequestOrBuilder.java @@ -75,7 +75,7 @@ public interface CreateApiOperationRequestOrBuilder * This value should be 4-500 characters, overall resource name which * will be of format * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - * its length is limited to 700 characters, and valid characters are + * its length is limited to 1000 characters, and valid characters are * /[a-z][A-Z][0-9]-_/. *
                      * @@ -100,7 +100,7 @@ public interface CreateApiOperationRequestOrBuilder * This value should be 4-500 characters, overall resource name which * will be of format * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - * its length is limited to 700 characters, and valid characters are + * its length is limited to 1000 characters, and valid characters are * /[a-z][A-Z][0-9]-_/. *
                      * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CurateServiceProto.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CurateServiceProto.java index 1851d950fcb3..05a4ed7ad09b 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CurateServiceProto.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/CurateServiceProto.java @@ -159,7 +159,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\020endpoint_details\"T\n" + "%ApplicationIntegrationEndpointDetails\022\021\n" + "\003uri\030\001 \001(\tB\004\342A\001\002\022\030\n\n" - + "trigger_id\030\002 \001(\tB\004\342A\001\0022\304\007\n" + + "trigger_id\030\002 \001(\tB\004\342A\001\0022\247\010\n" + "\014ApiHubCurate\022\300\001\n" + "\016CreateCuration\022-.google.cloud.apihub.v1.CreateCurationRequest\032" + " .google.cloud.apihub.v1.Curation\"]\332A\033parent,curation,c" @@ -178,12 +178,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016DeleteCuration\022-.google.cloud.apih" + "ub.v1.DeleteCurationRequest\032\026.google.pro" + "tobuf.Empty\"<\332A\004name\202\323\344\223\002/*-/v1/{name=pr" - + "ojects/*/locations/*/curations/*}\032I\312A\025ap" - + "ihub.googleapis.com\322A.https://www.googleapis.com/auth/cloud-platformB\264\001\n" - + "\032com.google.cloud.apihub.v1B\022CurateServiceProtoP" - + "\001Z2cloud.google.com/go/apihub/apiv1/apih" - + "ubpb;apihubpb\252\002\026Google.Cloud.ApiHub.V1\312\002" - + "\026Google\\Cloud\\ApiHub\\V1\352\002\031Google::Cloud::ApiHub::V1b\006proto3" + + "ojects/*/locations/*/curations/*}\032\253\001\312A\025a" + + "pihub.googleapis.com\322A\217\001https://www.goog" + + "leapis.com/auth/apihub.readonly,https://www.googleapis.com/auth/apihub.readwrite" + + ",https://www.googleapis.com/auth/cloud-platformB\264\001\n" + + "\032com.google.cloud.apihub.v1B\022CurateServiceProtoP\001Z2cloud.google.com/g" + + "o/apihub/apiv1/apihubpb;apihubpb\252\002\026Googl" + + "e.Cloud.ApiHub.V1\312\002\026Google\\Cloud\\ApiHub\\" + + "V1\352\002\031Google::Cloud::ApiHub::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DataSource.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DataSource.java new file mode 100644 index 000000000000..aec3eff8b2b9 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DataSource.java @@ -0,0 +1,191 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/common_fields.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The data source on which the addon operates.
                      + * 
                      + * + * Protobuf enum {@code google.cloud.apihub.v1.DataSource} + */ +@com.google.protobuf.Generated +public enum DataSource implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                      +   * The data source of the addon is not specified.
                      +   * 
                      + * + * DATA_SOURCE_UNSPECIFIED = 0; + */ + DATA_SOURCE_UNSPECIFIED(0), + /** + * + * + *
                      +   * Addon operates on data collected from specific plugin instances.
                      +   * 
                      + * + * PLUGIN_INSTANCE = 1; + */ + PLUGIN_INSTANCE(1), + /** + * + * + *
                      +   * Addon operates on all data in the API hub.
                      +   * 
                      + * + * ALL_DATA = 2; + */ + ALL_DATA(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DataSource"); + } + + /** + * + * + *
                      +   * The data source of the addon is not specified.
                      +   * 
                      + * + * DATA_SOURCE_UNSPECIFIED = 0; + */ + public static final int DATA_SOURCE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                      +   * Addon operates on data collected from specific plugin instances.
                      +   * 
                      + * + * PLUGIN_INSTANCE = 1; + */ + public static final int PLUGIN_INSTANCE_VALUE = 1; + + /** + * + * + *
                      +   * Addon operates on all data in the API hub.
                      +   * 
                      + * + * ALL_DATA = 2; + */ + public static final int ALL_DATA_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static DataSource valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static DataSource forNumber(int value) { + switch (value) { + case 0: + return DATA_SOURCE_UNSPECIFIED; + case 1: + return PLUGIN_INSTANCE; + case 2: + return ALL_DATA; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public DataSource findValueByNumber(int number) { + return DataSource.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto.getDescriptor().getEnumTypes().get(4); + } + + private static final DataSource[] VALUES = values(); + + public static DataSource valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private DataSource(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.apihub.v1.DataSource) +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Deployment.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Deployment.java index 27e8dc708615..452beb1d0e4d 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Deployment.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Deployment.java @@ -64,6 +64,9 @@ private Deployment() { sourceMetadata_ = java.util.Collections.emptyList(); sourceProject_ = ""; sourceEnvironment_ = ""; + specs_ = com.google.protobuf.LazyStringArrayList.emptyList(); + apiOperations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + sourceRevision_ = ""; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -1267,7 +1270,7 @@ public com.google.cloud.apihub.v1.AttributeValuesOrBuilder getSourceUriOrBuilder * *
                          * Optional. The project to which the deployment belongs.
                      -   * For GCP gateways, this will refer to the project identifier.
                      +   * For Google Cloud gateways, this will refer to the project identifier.
                          * For others like Edge/OPDK, this will refer to the org identifier.
                          * 
                      * @@ -1293,7 +1296,7 @@ public java.lang.String getSourceProject() { * *
                          * Optional. The project to which the deployment belongs.
                      -   * For GCP gateways, this will refer to the project identifier.
                      +   * For Google Cloud gateways, this will refer to the project identifier.
                          * For others like Edge/OPDK, this will refer to the org identifier.
                          * 
                      * @@ -1369,6 +1372,225 @@ public com.google.protobuf.ByteString getSourceEnvironmentBytes() { } } + public static final int SPECS_FIELD_NUMBER = 19; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList specs_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
                      +   * Output only. The specs linked directly to this deployment.
                      +   * Note: a deployment could serve multiple specs (e.g., across different
                      +   * revisions of the same underlying gateway configuration).
                      +   * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the specs. + */ + public com.google.protobuf.ProtocolStringList getSpecsList() { + return specs_; + } + + /** + * + * + *
                      +   * Output only. The specs linked directly to this deployment.
                      +   * Note: a deployment could serve multiple specs (e.g., across different
                      +   * revisions of the same underlying gateway configuration).
                      +   * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The count of specs. + */ + public int getSpecsCount() { + return specs_.size(); + } + + /** + * + * + *
                      +   * Output only. The specs linked directly to this deployment.
                      +   * Note: a deployment could serve multiple specs (e.g., across different
                      +   * revisions of the same underlying gateway configuration).
                      +   * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The specs at the given index. + */ + public java.lang.String getSpecs(int index) { + return specs_.get(index); + } + + /** + * + * + *
                      +   * Output only. The specs linked directly to this deployment.
                      +   * Note: a deployment could serve multiple specs (e.g., across different
                      +   * revisions of the same underlying gateway configuration).
                      +   * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the specs at the given index. + */ + public com.google.protobuf.ByteString getSpecsBytes(int index) { + return specs_.getByteString(index); + } + + public static final int API_OPERATIONS_FIELD_NUMBER = 20; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList apiOperations_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
                      +   * Output only. The API operations linked directly to this deployment.
                      +   * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the apiOperations. + */ + public com.google.protobuf.ProtocolStringList getApiOperationsList() { + return apiOperations_; + } + + /** + * + * + *
                      +   * Output only. The API operations linked directly to this deployment.
                      +   * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The count of apiOperations. + */ + public int getApiOperationsCount() { + return apiOperations_.size(); + } + + /** + * + * + *
                      +   * Output only. The API operations linked directly to this deployment.
                      +   * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The apiOperations at the given index. + */ + public java.lang.String getApiOperations(int index) { + return apiOperations_.get(index); + } + + /** + * + * + *
                      +   * Output only. The API operations linked directly to this deployment.
                      +   * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the apiOperations at the given index. + */ + public com.google.protobuf.ByteString getApiOperationsBytes(int index) { + return apiOperations_.getByteString(index); + } + + public static final int SOURCE_REVISION_FIELD_NUMBER = 21; + + @SuppressWarnings("serial") + private volatile java.lang.Object sourceRevision_ = ""; + + /** + * + * + *
                      +   * Optional. A revision identifier for the underlying gateway configuration
                      +   * that this deployment serves. For Apigee gateway variants, this is typically
                      +   * the proxy revision number populated automatically when the deployment is
                      +   * discovered.
                      +   * 
                      + * + * string source_revision = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The sourceRevision. + */ + @java.lang.Override + public java.lang.String getSourceRevision() { + java.lang.Object ref = sourceRevision_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sourceRevision_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Optional. A revision identifier for the underlying gateway configuration
                      +   * that this deployment serves. For Apigee gateway variants, this is typically
                      +   * the proxy revision number populated automatically when the deployment is
                      +   * discovered.
                      +   * 
                      + * + * string source_revision = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for sourceRevision. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSourceRevisionBytes() { + java.lang.Object ref = sourceRevision_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sourceRevision_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -1436,6 +1658,15 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceEnvironment_)) { com.google.protobuf.GeneratedMessage.writeString(output, 18, sourceEnvironment_); } + for (int i = 0; i < specs_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 19, specs_.getRaw(i)); + } + for (int i = 0; i < apiOperations_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 20, apiOperations_.getRaw(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceRevision_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 21, sourceRevision_); + } getUnknownFields().writeTo(output); } @@ -1517,6 +1748,25 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceEnvironment_)) { size += com.google.protobuf.GeneratedMessage.computeStringSize(18, sourceEnvironment_); } + { + int dataSize = 0; + for (int i = 0; i < specs_.size(); i++) { + dataSize += computeStringSizeNoTag(specs_.getRaw(i)); + } + size += dataSize; + size += 2 * getSpecsList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < apiOperations_.size(); i++) { + dataSize += computeStringSizeNoTag(apiOperations_.getRaw(i)); + } + size += dataSize; + size += 2 * getApiOperationsList().size(); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceRevision_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(21, sourceRevision_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1574,6 +1824,9 @@ public boolean equals(final java.lang.Object obj) { } if (!getSourceProject().equals(other.getSourceProject())) return false; if (!getSourceEnvironment().equals(other.getSourceEnvironment())) return false; + if (!getSpecsList().equals(other.getSpecsList())) return false; + if (!getApiOperationsList().equals(other.getApiOperationsList())) return false; + if (!getSourceRevision().equals(other.getSourceRevision())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1645,6 +1898,16 @@ public int hashCode() { hash = (53 * hash) + getSourceProject().hashCode(); hash = (37 * hash) + SOURCE_ENVIRONMENT_FIELD_NUMBER; hash = (53 * hash) + getSourceEnvironment().hashCode(); + if (getSpecsCount() > 0) { + hash = (37 * hash) + SPECS_FIELD_NUMBER; + hash = (53 * hash) + getSpecsList().hashCode(); + } + if (getApiOperationsCount() > 0) { + hash = (37 * hash) + API_OPERATIONS_FIELD_NUMBER; + hash = (53 * hash) + getApiOperationsList().hashCode(); + } + hash = (37 * hash) + SOURCE_REVISION_FIELD_NUMBER; + hash = (53 * hash) + getSourceRevision().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1882,6 +2145,9 @@ public Builder clear() { } sourceProject_ = ""; sourceEnvironment_ = ""; + specs_ = com.google.protobuf.LazyStringArrayList.emptyList(); + apiOperations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + sourceRevision_ = ""; return this; } @@ -1998,6 +2264,17 @@ private void buildPartial0(com.google.cloud.apihub.v1.Deployment result) { if (((from_bitField0_ & 0x00020000) != 0)) { result.sourceEnvironment_ = sourceEnvironment_; } + if (((from_bitField0_ & 0x00040000) != 0)) { + specs_.makeImmutable(); + result.specs_ = specs_; + } + if (((from_bitField0_ & 0x00080000) != 0)) { + apiOperations_.makeImmutable(); + result.apiOperations_ = apiOperations_; + } + if (((from_bitField0_ & 0x00100000) != 0)) { + result.sourceRevision_ = sourceRevision_; + } result.bitField0_ |= to_bitField0_; } @@ -2116,6 +2393,31 @@ public Builder mergeFrom(com.google.cloud.apihub.v1.Deployment other) { bitField0_ |= 0x00020000; onChanged(); } + if (!other.specs_.isEmpty()) { + if (specs_.isEmpty()) { + specs_ = other.specs_; + bitField0_ |= 0x00040000; + } else { + ensureSpecsIsMutable(); + specs_.addAll(other.specs_); + } + onChanged(); + } + if (!other.apiOperations_.isEmpty()) { + if (apiOperations_.isEmpty()) { + apiOperations_ = other.apiOperations_; + bitField0_ |= 0x00080000; + } else { + ensureApiOperationsIsMutable(); + apiOperations_.addAll(other.apiOperations_); + } + onChanged(); + } + if (!other.getSourceRevision().isEmpty()) { + sourceRevision_ = other.sourceRevision_; + bitField0_ |= 0x00100000; + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -2274,6 +2576,26 @@ public Builder mergeFrom( bitField0_ |= 0x00020000; break; } // case 146 + case 154: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureSpecsIsMutable(); + specs_.add(s); + break; + } // case 154 + case 162: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureApiOperationsIsMutable(); + apiOperations_.add(s); + break; + } // case 162 + case 170: + { + sourceRevision_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00100000; + break; + } // case 170 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -5905,7 +6227,7 @@ public com.google.cloud.apihub.v1.AttributeValuesOrBuilder getSourceUriOrBuilder * *
                            * Optional. The project to which the deployment belongs.
                      -     * For GCP gateways, this will refer to the project identifier.
                      +     * For Google Cloud gateways, this will refer to the project identifier.
                            * For others like Edge/OPDK, this will refer to the org identifier.
                            * 
                      * @@ -5930,7 +6252,7 @@ public java.lang.String getSourceProject() { * *
                            * Optional. The project to which the deployment belongs.
                      -     * For GCP gateways, this will refer to the project identifier.
                      +     * For Google Cloud gateways, this will refer to the project identifier.
                            * For others like Edge/OPDK, this will refer to the org identifier.
                            * 
                      * @@ -5955,7 +6277,7 @@ public com.google.protobuf.ByteString getSourceProjectBytes() { * *
                            * Optional. The project to which the deployment belongs.
                      -     * For GCP gateways, this will refer to the project identifier.
                      +     * For Google Cloud gateways, this will refer to the project identifier.
                            * For others like Edge/OPDK, this will refer to the org identifier.
                            * 
                      * @@ -5979,7 +6301,7 @@ public Builder setSourceProject(java.lang.String value) { * *
                            * Optional. The project to which the deployment belongs.
                      -     * For GCP gateways, this will refer to the project identifier.
                      +     * For Google Cloud gateways, this will refer to the project identifier.
                            * For others like Edge/OPDK, this will refer to the org identifier.
                            * 
                      * @@ -5999,7 +6321,7 @@ public Builder clearSourceProject() { * *
                            * Optional. The project to which the deployment belongs.
                      -     * For GCP gateways, this will refer to the project identifier.
                      +     * For Google Cloud gateways, this will refer to the project identifier.
                            * For others like Edge/OPDK, this will refer to the org identifier.
                            * 
                      * @@ -6135,6 +6457,552 @@ public Builder setSourceEnvironmentBytes(com.google.protobuf.ByteString value) { return this; } + private com.google.protobuf.LazyStringArrayList specs_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureSpecsIsMutable() { + if (!specs_.isModifiable()) { + specs_ = new com.google.protobuf.LazyStringArrayList(specs_); + } + bitField0_ |= 0x00040000; + } + + /** + * + * + *
                      +     * Output only. The specs linked directly to this deployment.
                      +     * Note: a deployment could serve multiple specs (e.g., across different
                      +     * revisions of the same underlying gateway configuration).
                      +     * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the specs. + */ + public com.google.protobuf.ProtocolStringList getSpecsList() { + specs_.makeImmutable(); + return specs_; + } + + /** + * + * + *
                      +     * Output only. The specs linked directly to this deployment.
                      +     * Note: a deployment could serve multiple specs (e.g., across different
                      +     * revisions of the same underlying gateway configuration).
                      +     * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The count of specs. + */ + public int getSpecsCount() { + return specs_.size(); + } + + /** + * + * + *
                      +     * Output only. The specs linked directly to this deployment.
                      +     * Note: a deployment could serve multiple specs (e.g., across different
                      +     * revisions of the same underlying gateway configuration).
                      +     * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The specs at the given index. + */ + public java.lang.String getSpecs(int index) { + return specs_.get(index); + } + + /** + * + * + *
                      +     * Output only. The specs linked directly to this deployment.
                      +     * Note: a deployment could serve multiple specs (e.g., across different
                      +     * revisions of the same underlying gateway configuration).
                      +     * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the specs at the given index. + */ + public com.google.protobuf.ByteString getSpecsBytes(int index) { + return specs_.getByteString(index); + } + + /** + * + * + *
                      +     * Output only. The specs linked directly to this deployment.
                      +     * Note: a deployment could serve multiple specs (e.g., across different
                      +     * revisions of the same underlying gateway configuration).
                      +     * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index to set the value at. + * @param value The specs to set. + * @return This builder for chaining. + */ + public Builder setSpecs(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSpecsIsMutable(); + specs_.set(index, value); + bitField0_ |= 0x00040000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The specs linked directly to this deployment.
                      +     * Note: a deployment could serve multiple specs (e.g., across different
                      +     * revisions of the same underlying gateway configuration).
                      +     * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The specs to add. + * @return This builder for chaining. + */ + public Builder addSpecs(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSpecsIsMutable(); + specs_.add(value); + bitField0_ |= 0x00040000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The specs linked directly to this deployment.
                      +     * Note: a deployment could serve multiple specs (e.g., across different
                      +     * revisions of the same underlying gateway configuration).
                      +     * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param values The specs to add. + * @return This builder for chaining. + */ + public Builder addAllSpecs(java.lang.Iterable values) { + ensureSpecsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, specs_); + bitField0_ |= 0x00040000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The specs linked directly to this deployment.
                      +     * Note: a deployment could serve multiple specs (e.g., across different
                      +     * revisions of the same underlying gateway configuration).
                      +     * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearSpecs() { + specs_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00040000); + ; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The specs linked directly to this deployment.
                      +     * Note: a deployment could serve multiple specs (e.g., across different
                      +     * revisions of the same underlying gateway configuration).
                      +     * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes of the specs to add. + * @return This builder for chaining. + */ + public Builder addSpecsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureSpecsIsMutable(); + specs_.add(value); + bitField0_ |= 0x00040000; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList apiOperations_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureApiOperationsIsMutable() { + if (!apiOperations_.isModifiable()) { + apiOperations_ = new com.google.protobuf.LazyStringArrayList(apiOperations_); + } + bitField0_ |= 0x00080000; + } + + /** + * + * + *
                      +     * Output only. The API operations linked directly to this deployment.
                      +     * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the apiOperations. + */ + public com.google.protobuf.ProtocolStringList getApiOperationsList() { + apiOperations_.makeImmutable(); + return apiOperations_; + } + + /** + * + * + *
                      +     * Output only. The API operations linked directly to this deployment.
                      +     * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The count of apiOperations. + */ + public int getApiOperationsCount() { + return apiOperations_.size(); + } + + /** + * + * + *
                      +     * Output only. The API operations linked directly to this deployment.
                      +     * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The apiOperations at the given index. + */ + public java.lang.String getApiOperations(int index) { + return apiOperations_.get(index); + } + + /** + * + * + *
                      +     * Output only. The API operations linked directly to this deployment.
                      +     * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the apiOperations at the given index. + */ + public com.google.protobuf.ByteString getApiOperationsBytes(int index) { + return apiOperations_.getByteString(index); + } + + /** + * + * + *
                      +     * Output only. The API operations linked directly to this deployment.
                      +     * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index to set the value at. + * @param value The apiOperations to set. + * @return This builder for chaining. + */ + public Builder setApiOperations(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureApiOperationsIsMutable(); + apiOperations_.set(index, value); + bitField0_ |= 0x00080000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The API operations linked directly to this deployment.
                      +     * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The apiOperations to add. + * @return This builder for chaining. + */ + public Builder addApiOperations(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureApiOperationsIsMutable(); + apiOperations_.add(value); + bitField0_ |= 0x00080000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The API operations linked directly to this deployment.
                      +     * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param values The apiOperations to add. + * @return This builder for chaining. + */ + public Builder addAllApiOperations(java.lang.Iterable values) { + ensureApiOperationsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, apiOperations_); + bitField0_ |= 0x00080000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The API operations linked directly to this deployment.
                      +     * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearApiOperations() { + apiOperations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00080000); + ; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The API operations linked directly to this deployment.
                      +     * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes of the apiOperations to add. + * @return This builder for chaining. + */ + public Builder addApiOperationsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureApiOperationsIsMutable(); + apiOperations_.add(value); + bitField0_ |= 0x00080000; + onChanged(); + return this; + } + + private java.lang.Object sourceRevision_ = ""; + + /** + * + * + *
                      +     * Optional. A revision identifier for the underlying gateway configuration
                      +     * that this deployment serves. For Apigee gateway variants, this is typically
                      +     * the proxy revision number populated automatically when the deployment is
                      +     * discovered.
                      +     * 
                      + * + * string source_revision = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The sourceRevision. + */ + public java.lang.String getSourceRevision() { + java.lang.Object ref = sourceRevision_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sourceRevision_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Optional. A revision identifier for the underlying gateway configuration
                      +     * that this deployment serves. For Apigee gateway variants, this is typically
                      +     * the proxy revision number populated automatically when the deployment is
                      +     * discovered.
                      +     * 
                      + * + * string source_revision = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for sourceRevision. + */ + public com.google.protobuf.ByteString getSourceRevisionBytes() { + java.lang.Object ref = sourceRevision_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sourceRevision_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Optional. A revision identifier for the underlying gateway configuration
                      +     * that this deployment serves. For Apigee gateway variants, this is typically
                      +     * the proxy revision number populated automatically when the deployment is
                      +     * discovered.
                      +     * 
                      + * + * string source_revision = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The sourceRevision to set. + * @return This builder for chaining. + */ + public Builder setSourceRevision(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sourceRevision_ = value; + bitField0_ |= 0x00100000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. A revision identifier for the underlying gateway configuration
                      +     * that this deployment serves. For Apigee gateway variants, this is typically
                      +     * the proxy revision number populated automatically when the deployment is
                      +     * discovered.
                      +     * 
                      + * + * string source_revision = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearSourceRevision() { + sourceRevision_ = getDefaultInstance().getSourceRevision(); + bitField0_ = (bitField0_ & ~0x00100000); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. A revision identifier for the underlying gateway configuration
                      +     * that this deployment serves. For Apigee gateway variants, this is typically
                      +     * the proxy revision number populated automatically when the deployment is
                      +     * discovered.
                      +     * 
                      + * + * string source_revision = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for sourceRevision to set. + * @return This builder for chaining. + */ + public Builder setSourceRevisionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sourceRevision_ = value; + bitField0_ |= 0x00100000; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.Deployment) } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DeploymentOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DeploymentOrBuilder.java index f7e27a9bc083..874afd265b1a 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DeploymentOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DeploymentOrBuilder.java @@ -874,7 +874,7 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault( * *
                          * Optional. The project to which the deployment belongs.
                      -   * For GCP gateways, this will refer to the project identifier.
                      +   * For Google Cloud gateways, this will refer to the project identifier.
                          * For others like Edge/OPDK, this will refer to the org identifier.
                          * 
                      * @@ -889,7 +889,7 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault( * *
                          * Optional. The project to which the deployment belongs.
                      -   * For GCP gateways, this will refer to the project identifier.
                      +   * For Google Cloud gateways, this will refer to the project identifier.
                          * For others like Edge/OPDK, this will refer to the org identifier.
                          * 
                      * @@ -926,4 +926,168 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault( * @return The bytes for sourceEnvironment. */ com.google.protobuf.ByteString getSourceEnvironmentBytes(); + + /** + * + * + *
                      +   * Output only. The specs linked directly to this deployment.
                      +   * Note: a deployment could serve multiple specs (e.g., across different
                      +   * revisions of the same underlying gateway configuration).
                      +   * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the specs. + */ + java.util.List getSpecsList(); + + /** + * + * + *
                      +   * Output only. The specs linked directly to this deployment.
                      +   * Note: a deployment could serve multiple specs (e.g., across different
                      +   * revisions of the same underlying gateway configuration).
                      +   * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The count of specs. + */ + int getSpecsCount(); + + /** + * + * + *
                      +   * Output only. The specs linked directly to this deployment.
                      +   * Note: a deployment could serve multiple specs (e.g., across different
                      +   * revisions of the same underlying gateway configuration).
                      +   * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The specs at the given index. + */ + java.lang.String getSpecs(int index); + + /** + * + * + *
                      +   * Output only. The specs linked directly to this deployment.
                      +   * Note: a deployment could serve multiple specs (e.g., across different
                      +   * revisions of the same underlying gateway configuration).
                      +   * 
                      + * + * + * repeated string specs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the specs at the given index. + */ + com.google.protobuf.ByteString getSpecsBytes(int index); + + /** + * + * + *
                      +   * Output only. The API operations linked directly to this deployment.
                      +   * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the apiOperations. + */ + java.util.List getApiOperationsList(); + + /** + * + * + *
                      +   * Output only. The API operations linked directly to this deployment.
                      +   * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The count of apiOperations. + */ + int getApiOperationsCount(); + + /** + * + * + *
                      +   * Output only. The API operations linked directly to this deployment.
                      +   * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The apiOperations at the given index. + */ + java.lang.String getApiOperations(int index); + + /** + * + * + *
                      +   * Output only. The API operations linked directly to this deployment.
                      +   * 
                      + * + * + * repeated string api_operations = 20 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the apiOperations at the given index. + */ + com.google.protobuf.ByteString getApiOperationsBytes(int index); + + /** + * + * + *
                      +   * Optional. A revision identifier for the underlying gateway configuration
                      +   * that this deployment serves. For Apigee gateway variants, this is typically
                      +   * the proxy revision number populated automatically when the deployment is
                      +   * discovered.
                      +   * 
                      + * + * string source_revision = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The sourceRevision. + */ + java.lang.String getSourceRevision(); + + /** + * + * + *
                      +   * Optional. A revision identifier for the underlying gateway configuration
                      +   * that this deployment serves. For Apigee gateway variants, this is typically
                      +   * the proxy revision number populated automatically when the deployment is
                      +   * discovered.
                      +   * 
                      + * + * string source_revision = 21 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for sourceRevision. + */ + com.google.protobuf.ByteString getSourceRevisionBytes(); } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveredApiObservation.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveredApiObservation.java index 4217d52bae57..230603fe7f81 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveredApiObservation.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveredApiObservation.java @@ -294,7 +294,7 @@ public enum SourceType implements com.google.protobuf.ProtocolMessageEnum { * * *
                      -     * GCP external load balancer.
                      +     * Google Cloud external load balancer.
                            * 
                      * * GCP_XLB = 1; @@ -304,7 +304,7 @@ public enum SourceType implements com.google.protobuf.ProtocolMessageEnum { * * *
                      -     * GCP internal load balancer.
                      +     * Google Cloud internal load balancer.
                            * 
                      * * GCP_ILB = 2; @@ -338,7 +338,7 @@ public enum SourceType implements com.google.protobuf.ProtocolMessageEnum { * * *
                      -     * GCP external load balancer.
                      +     * Google Cloud external load balancer.
                            * 
                      * * GCP_XLB = 1; @@ -349,7 +349,7 @@ public enum SourceType implements com.google.protobuf.ProtocolMessageEnum { * * *
                      -     * GCP internal load balancer.
                      +     * Google Cloud internal load balancer.
                            * 
                      * * GCP_ILB = 2; @@ -836,8 +836,8 @@ public long getApiOperationCount() { * * *
                      -   * Optional. For an observation pushed from a gcp resource, this would be the
                      -   * gcp project id.
                      +   * Optional. For an observation pushed from a Google Cloud resource, this
                      +   * would be the Google Cloud project id.
                          * 
                      * * string origin = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -861,8 +861,8 @@ public java.lang.String getOrigin() { * * *
                      -   * Optional. For an observation pushed from a gcp resource, this would be the
                      -   * gcp project id.
                      +   * Optional. For an observation pushed from a Google Cloud resource, this
                      +   * would be the Google Cloud project id.
                          * 
                      * * string origin = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -2960,8 +2960,8 @@ public Builder clearApiOperationCount() { * * *
                      -     * Optional. For an observation pushed from a gcp resource, this would be the
                      -     * gcp project id.
                      +     * Optional. For an observation pushed from a Google Cloud resource, this
                      +     * would be the Google Cloud project id.
                            * 
                      * * string origin = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -2984,8 +2984,8 @@ public java.lang.String getOrigin() { * * *
                      -     * Optional. For an observation pushed from a gcp resource, this would be the
                      -     * gcp project id.
                      +     * Optional. For an observation pushed from a Google Cloud resource, this
                      +     * would be the Google Cloud project id.
                            * 
                      * * string origin = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -3008,8 +3008,8 @@ public com.google.protobuf.ByteString getOriginBytes() { * * *
                      -     * Optional. For an observation pushed from a gcp resource, this would be the
                      -     * gcp project id.
                      +     * Optional. For an observation pushed from a Google Cloud resource, this
                      +     * would be the Google Cloud project id.
                            * 
                      * * string origin = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -3031,8 +3031,8 @@ public Builder setOrigin(java.lang.String value) { * * *
                      -     * Optional. For an observation pushed from a gcp resource, this would be the
                      -     * gcp project id.
                      +     * Optional. For an observation pushed from a Google Cloud resource, this
                      +     * would be the Google Cloud project id.
                            * 
                      * * string origin = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -3050,8 +3050,8 @@ public Builder clearOrigin() { * * *
                      -     * Optional. For an observation pushed from a gcp resource, this would be the
                      -     * gcp project id.
                      +     * Optional. For an observation pushed from a Google Cloud resource, this
                      +     * would be the Google Cloud project id.
                            * 
                      * * string origin = 8 [(.google.api.field_behavior) = OPTIONAL]; diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveredApiObservationOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveredApiObservationOrBuilder.java index 5202077828f2..4c31b9b85bd1 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveredApiObservationOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveredApiObservationOrBuilder.java @@ -298,8 +298,8 @@ public interface DiscoveredApiObservationOrBuilder * * *
                      -   * Optional. For an observation pushed from a gcp resource, this would be the
                      -   * gcp project id.
                      +   * Optional. For an observation pushed from a Google Cloud resource, this
                      +   * would be the Google Cloud project id.
                          * 
                      * * string origin = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -312,8 +312,8 @@ public interface DiscoveredApiObservationOrBuilder * * *
                      -   * Optional. For an observation pushed from a gcp resource, this would be the
                      -   * gcp project id.
                      +   * Optional. For an observation pushed from a Google Cloud resource, this
                      +   * would be the Google Cloud project id.
                          * 
                      * * string origin = 8 [(.google.api.field_behavior) = OPTIONAL]; diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveryServiceProto.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveryServiceProto.java index 888ff3ea66fc..93cf7a341366 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveryServiceProto.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/DiscoveryServiceProto.java @@ -102,7 +102,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + ".apihub.googleapis.com/DiscoveredApiObservation\"g\n" + " GetDiscoveredApiOperationRequest\022C\n" + "\004name\030\001 \001(\tB5\342A\001\002\372A.\n" - + ",apihub.googleapis.com/DiscoveredApiOperation2\232\010\n" + + ",apihub.googleapis.com/DiscoveredApiOperation2\375\010\n" + "\017ApiHubDiscovery\022\354\001\n" + "\035ListDiscoveredApiObservations\022<.google.cloud.apihub.v1.ListDis" + "coveredApiObservationsRequest\032=.google.cloud.apihub.v1.ListDiscoveredApiObservat" @@ -121,12 +121,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ApiOperationRequest\032..google.cloud.apihu" + "b.v1.DiscoveredApiOperation\"f\332A\004name\202\323\344\223" + "\002Y\022W/v1/{name=projects/*/locations/*/discoveredApiObservations/*/discoveredApiOp" - + "erations/*}\032I\312A\025apihub.googleapis.com\322A." - + "https://www.googleapis.com/auth/cloud-platformB\267\001\n" - + "\032com.google.cloud.apihub.v1B\025DiscoveryServiceProtoP\001Z2cloud.google.com" - + "/go/apihub/apiv1/apihubpb;apihubpb\252\002\026Goo" - + "gle.Cloud.ApiHub.V1\312\002\026Google\\Cloud\\ApiHu" - + "b\\V1\352\002\031Google::Cloud::ApiHub::V1b\006proto3" + + "erations/*}\032\253\001\312A\025apihub.googleapis.com\322A" + + "\217\001https://www.googleapis.com/auth/apihub.readonly,https://www.googleapis.com/aut" + + "h/apihub.readwrite,https://www.googleapis.com/auth/cloud-platformB\267\001\n" + + "\032com.google.cloud.apihub.v1B\025DiscoveryServiceProtoP" + + "\001Z2cloud.google.com/go/apihub/apiv1/apih" + + "ubpb;apihubpb\252\002\026Google.Cloud.ApiHub.V1\312\002" + + "\026Google\\Cloud\\ApiHub\\V1\352\002\031Google::Cloud::ApiHub::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/EnvironmentFilter.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/EnvironmentFilter.java new file mode 100644 index 000000000000..43c3321ce81f --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/EnvironmentFilter.java @@ -0,0 +1,814 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Filter for environments.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.EnvironmentFilter} + */ +@com.google.protobuf.Generated +public final class EnvironmentFilter extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.EnvironmentFilter) + EnvironmentFilterOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "EnvironmentFilter"); + } + + // Use EnvironmentFilter.newBuilder() to construct. + private EnvironmentFilter(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private EnvironmentFilter() { + environments_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_EnvironmentFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_EnvironmentFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.EnvironmentFilter.class, + com.google.cloud.apihub.v1.EnvironmentFilter.Builder.class); + } + + public static final int ALL_ENVIRONMENTS_FIELD_NUMBER = 2; + private boolean allEnvironments_ = false; + + /** + * + * + *
                      +   * Optional. Indicates if this filter should match all environments or only
                      +   * a subset of environments.
                      +   * If set to true, all environments are matched.
                      +   * 
                      + * + * bool all_environments = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The allEnvironments. + */ + @java.lang.Override + public boolean getAllEnvironments() { + return allEnvironments_; + } + + public static final int ENVIRONMENTS_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList environments_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
                      +   * Optional. If provided, only environments in this list are matched. This
                      +   * field is ignored if `all_environments` is true.
                      +   * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return A list containing the environments. + */ + public com.google.protobuf.ProtocolStringList getEnvironmentsList() { + return environments_; + } + + /** + * + * + *
                      +   * Optional. If provided, only environments in this list are matched. This
                      +   * field is ignored if `all_environments` is true.
                      +   * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The count of environments. + */ + public int getEnvironmentsCount() { + return environments_.size(); + } + + /** + * + * + *
                      +   * Optional. If provided, only environments in this list are matched. This
                      +   * field is ignored if `all_environments` is true.
                      +   * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the element to return. + * @return The environments at the given index. + */ + public java.lang.String getEnvironments(int index) { + return environments_.get(index); + } + + /** + * + * + *
                      +   * Optional. If provided, only environments in this list are matched. This
                      +   * field is ignored if `all_environments` is true.
                      +   * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the value to return. + * @return The bytes of the environments at the given index. + */ + public com.google.protobuf.ByteString getEnvironmentsBytes(int index) { + return environments_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (allEnvironments_ != false) { + output.writeBool(2, allEnvironments_); + } + for (int i = 0; i < environments_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, environments_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (allEnvironments_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, allEnvironments_); + } + { + int dataSize = 0; + for (int i = 0; i < environments_.size(); i++) { + dataSize += computeStringSizeNoTag(environments_.getRaw(i)); + } + size += dataSize; + size += 1 * getEnvironmentsList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.EnvironmentFilter)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.EnvironmentFilter other = + (com.google.cloud.apihub.v1.EnvironmentFilter) obj; + + if (getAllEnvironments() != other.getAllEnvironments()) return false; + if (!getEnvironmentsList().equals(other.getEnvironmentsList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ALL_ENVIRONMENTS_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllEnvironments()); + if (getEnvironmentsCount() > 0) { + hash = (37 * hash) + ENVIRONMENTS_FIELD_NUMBER; + hash = (53 * hash) + getEnvironmentsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.EnvironmentFilter prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Filter for environments.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.EnvironmentFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.EnvironmentFilter) + com.google.cloud.apihub.v1.EnvironmentFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_EnvironmentFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_EnvironmentFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.EnvironmentFilter.class, + com.google.cloud.apihub.v1.EnvironmentFilter.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.EnvironmentFilter.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + allEnvironments_ = false; + environments_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_EnvironmentFilter_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.EnvironmentFilter getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.EnvironmentFilter build() { + com.google.cloud.apihub.v1.EnvironmentFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.EnvironmentFilter buildPartial() { + com.google.cloud.apihub.v1.EnvironmentFilter result = + new com.google.cloud.apihub.v1.EnvironmentFilter(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.EnvironmentFilter result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.allEnvironments_ = allEnvironments_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + environments_.makeImmutable(); + result.environments_ = environments_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.EnvironmentFilter) { + return mergeFrom((com.google.cloud.apihub.v1.EnvironmentFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.EnvironmentFilter other) { + if (other == com.google.cloud.apihub.v1.EnvironmentFilter.getDefaultInstance()) return this; + if (other.getAllEnvironments() != false) { + setAllEnvironments(other.getAllEnvironments()); + } + if (!other.environments_.isEmpty()) { + if (environments_.isEmpty()) { + environments_ = other.environments_; + bitField0_ |= 0x00000002; + } else { + ensureEnvironmentsIsMutable(); + environments_.addAll(other.environments_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 16: + { + allEnvironments_ = input.readBool(); + bitField0_ |= 0x00000001; + break; + } // case 16 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureEnvironmentsIsMutable(); + environments_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private boolean allEnvironments_; + + /** + * + * + *
                      +     * Optional. Indicates if this filter should match all environments or only
                      +     * a subset of environments.
                      +     * If set to true, all environments are matched.
                      +     * 
                      + * + * bool all_environments = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The allEnvironments. + */ + @java.lang.Override + public boolean getAllEnvironments() { + return allEnvironments_; + } + + /** + * + * + *
                      +     * Optional. Indicates if this filter should match all environments or only
                      +     * a subset of environments.
                      +     * If set to true, all environments are matched.
                      +     * 
                      + * + * bool all_environments = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The allEnvironments to set. + * @return This builder for chaining. + */ + public Builder setAllEnvironments(boolean value) { + + allEnvironments_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Indicates if this filter should match all environments or only
                      +     * a subset of environments.
                      +     * If set to true, all environments are matched.
                      +     * 
                      + * + * bool all_environments = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearAllEnvironments() { + bitField0_ = (bitField0_ & ~0x00000001); + allEnvironments_ = false; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList environments_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureEnvironmentsIsMutable() { + if (!environments_.isModifiable()) { + environments_ = new com.google.protobuf.LazyStringArrayList(environments_); + } + bitField0_ |= 0x00000002; + } + + /** + * + * + *
                      +     * Optional. If provided, only environments in this list are matched. This
                      +     * field is ignored if `all_environments` is true.
                      +     * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return A list containing the environments. + */ + public com.google.protobuf.ProtocolStringList getEnvironmentsList() { + environments_.makeImmutable(); + return environments_; + } + + /** + * + * + *
                      +     * Optional. If provided, only environments in this list are matched. This
                      +     * field is ignored if `all_environments` is true.
                      +     * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The count of environments. + */ + public int getEnvironmentsCount() { + return environments_.size(); + } + + /** + * + * + *
                      +     * Optional. If provided, only environments in this list are matched. This
                      +     * field is ignored if `all_environments` is true.
                      +     * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the element to return. + * @return The environments at the given index. + */ + public java.lang.String getEnvironments(int index) { + return environments_.get(index); + } + + /** + * + * + *
                      +     * Optional. If provided, only environments in this list are matched. This
                      +     * field is ignored if `all_environments` is true.
                      +     * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the value to return. + * @return The bytes of the environments at the given index. + */ + public com.google.protobuf.ByteString getEnvironmentsBytes(int index) { + return environments_.getByteString(index); + } + + /** + * + * + *
                      +     * Optional. If provided, only environments in this list are matched. This
                      +     * field is ignored if `all_environments` is true.
                      +     * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index to set the value at. + * @param value The environments to set. + * @return This builder for chaining. + */ + public Builder setEnvironments(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureEnvironmentsIsMutable(); + environments_.set(index, value); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. If provided, only environments in this list are matched. This
                      +     * field is ignored if `all_environments` is true.
                      +     * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The environments to add. + * @return This builder for chaining. + */ + public Builder addEnvironments(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureEnvironmentsIsMutable(); + environments_.add(value); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. If provided, only environments in this list are matched. This
                      +     * field is ignored if `all_environments` is true.
                      +     * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param values The environments to add. + * @return This builder for chaining. + */ + public Builder addAllEnvironments(java.lang.Iterable values) { + ensureEnvironmentsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, environments_); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. If provided, only environments in this list are matched. This
                      +     * field is ignored if `all_environments` is true.
                      +     * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearEnvironments() { + environments_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + ; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. If provided, only environments in this list are matched. This
                      +     * field is ignored if `all_environments` is true.
                      +     * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes of the environments to add. + * @return This builder for chaining. + */ + public Builder addEnvironmentsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureEnvironmentsIsMutable(); + environments_.add(value); + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.EnvironmentFilter) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.EnvironmentFilter) + private static final com.google.cloud.apihub.v1.EnvironmentFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.EnvironmentFilter(); + } + + public static com.google.cloud.apihub.v1.EnvironmentFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EnvironmentFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.EnvironmentFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/EnvironmentFilterOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/EnvironmentFilterOrBuilder.java new file mode 100644 index 000000000000..b1ead69b34ba --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/EnvironmentFilterOrBuilder.java @@ -0,0 +1,101 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface EnvironmentFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.EnvironmentFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Optional. Indicates if this filter should match all environments or only
                      +   * a subset of environments.
                      +   * If set to true, all environments are matched.
                      +   * 
                      + * + * bool all_environments = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The allEnvironments. + */ + boolean getAllEnvironments(); + + /** + * + * + *
                      +   * Optional. If provided, only environments in this list are matched. This
                      +   * field is ignored if `all_environments` is true.
                      +   * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return A list containing the environments. + */ + java.util.List getEnvironmentsList(); + + /** + * + * + *
                      +   * Optional. If provided, only environments in this list are matched. This
                      +   * field is ignored if `all_environments` is true.
                      +   * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The count of environments. + */ + int getEnvironmentsCount(); + + /** + * + * + *
                      +   * Optional. If provided, only environments in this list are matched. This
                      +   * field is ignored if `all_environments` is true.
                      +   * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the element to return. + * @return The environments at the given index. + */ + java.lang.String getEnvironments(int index); + + /** + * + * + *
                      +   * Optional. If provided, only environments in this list are matched. This
                      +   * field is ignored if `all_environments` is true.
                      +   * 
                      + * + * repeated string environments = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the value to return. + * @return The bytes of the environments at the given index. + */ + com.google.protobuf.ByteString getEnvironmentsBytes(int index); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExecutionStatus.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExecutionStatus.java index 5c703f9ec23e..3564b871b40d 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExecutionStatus.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExecutionStatus.java @@ -384,6 +384,36 @@ public interface LastExecutionOrBuilder * */ com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder(); + + /** + * + * + *
                      +     * Output only. The result metadata of the last execution of the plugin
                      +     * instance. This will be a string representation of a JSON object and will
                      +     * be available on successful execution.
                      +     * 
                      + * + * string result_metadata = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The resultMetadata. + */ + java.lang.String getResultMetadata(); + + /** + * + * + *
                      +     * Output only. The result metadata of the last execution of the plugin
                      +     * instance. This will be a string representation of a JSON object and will
                      +     * be available on successful execution.
                      +     * 
                      + * + * string result_metadata = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for resultMetadata. + */ + com.google.protobuf.ByteString getResultMetadataBytes(); } /** @@ -419,6 +449,7 @@ private LastExecution(com.google.protobuf.GeneratedMessage.Builder builder) { private LastExecution() { result_ = 0; errorMessage_ = ""; + resultMetadata_ = ""; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -810,6 +841,63 @@ public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; } + public static final int RESULT_METADATA_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object resultMetadata_ = ""; + + /** + * + * + *
                      +     * Output only. The result metadata of the last execution of the plugin
                      +     * instance. This will be a string representation of a JSON object and will
                      +     * be available on successful execution.
                      +     * 
                      + * + * string result_metadata = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The resultMetadata. + */ + @java.lang.Override + public java.lang.String getResultMetadata() { + java.lang.Object ref = resultMetadata_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + resultMetadata_ = s; + return s; + } + } + + /** + * + * + *
                      +     * Output only. The result metadata of the last execution of the plugin
                      +     * instance. This will be a string representation of a JSON object and will
                      +     * be available on successful execution.
                      +     * 
                      + * + * string result_metadata = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for resultMetadata. + */ + @java.lang.Override + public com.google.protobuf.ByteString getResultMetadataBytes() { + java.lang.Object ref = resultMetadata_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + resultMetadata_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -838,6 +926,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000002) != 0)) { output.writeMessage(4, getEndTime()); } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(resultMetadata_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, resultMetadata_); + } getUnknownFields().writeTo(output); } @@ -861,6 +952,9 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000002) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getEndTime()); } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(resultMetadata_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, resultMetadata_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -887,6 +981,7 @@ public boolean equals(final java.lang.Object obj) { if (hasEndTime()) { if (!getEndTime().equals(other.getEndTime())) return false; } + if (!getResultMetadata().equals(other.getResultMetadata())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -910,6 +1005,8 @@ public int hashCode() { hash = (37 * hash) + END_TIME_FIELD_NUMBER; hash = (53 * hash) + getEndTime().hashCode(); } + hash = (37 * hash) + RESULT_METADATA_FIELD_NUMBER; + hash = (53 * hash) + getResultMetadata().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1073,6 +1170,7 @@ public Builder clear() { endTimeBuilder_.dispose(); endTimeBuilder_ = null; } + resultMetadata_ = ""; return this; } @@ -1124,6 +1222,9 @@ private void buildPartial0(com.google.cloud.apihub.v1.ExecutionStatus.LastExecut result.endTime_ = endTimeBuilder_ == null ? endTime_ : endTimeBuilder_.build(); to_bitField0_ |= 0x00000002; } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.resultMetadata_ = resultMetadata_; + } result.bitField0_ |= to_bitField0_; } @@ -1154,6 +1255,11 @@ public Builder mergeFrom(com.google.cloud.apihub.v1.ExecutionStatus.LastExecutio if (other.hasEndTime()) { mergeEndTime(other.getEndTime()); } + if (!other.getResultMetadata().isEmpty()) { + resultMetadata_ = other.resultMetadata_; + bitField0_ |= 0x00000010; + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1206,6 +1312,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 34 + case 42: + { + resultMetadata_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -1860,6 +1972,127 @@ public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { return endTimeBuilder_; } + private java.lang.Object resultMetadata_ = ""; + + /** + * + * + *
                      +       * Output only. The result metadata of the last execution of the plugin
                      +       * instance. This will be a string representation of a JSON object and will
                      +       * be available on successful execution.
                      +       * 
                      + * + * string result_metadata = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The resultMetadata. + */ + public java.lang.String getResultMetadata() { + java.lang.Object ref = resultMetadata_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + resultMetadata_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +       * Output only. The result metadata of the last execution of the plugin
                      +       * instance. This will be a string representation of a JSON object and will
                      +       * be available on successful execution.
                      +       * 
                      + * + * string result_metadata = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for resultMetadata. + */ + public com.google.protobuf.ByteString getResultMetadataBytes() { + java.lang.Object ref = resultMetadata_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + resultMetadata_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +       * Output only. The result metadata of the last execution of the plugin
                      +       * instance. This will be a string representation of a JSON object and will
                      +       * be available on successful execution.
                      +       * 
                      + * + * string result_metadata = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The resultMetadata to set. + * @return This builder for chaining. + */ + public Builder setResultMetadata(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + resultMetadata_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Output only. The result metadata of the last execution of the plugin
                      +       * instance. This will be a string representation of a JSON object and will
                      +       * be available on successful execution.
                      +       * 
                      + * + * string result_metadata = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearResultMetadata() { + resultMetadata_ = getDefaultInstance().getResultMetadata(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Output only. The result metadata of the last execution of the plugin
                      +       * instance. This will be a string representation of a JSON object and will
                      +       * be available on successful execution.
                      +       * 
                      + * + * string result_metadata = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for resultMetadata to set. + * @return This builder for chaining. + */ + public Builder setResultMetadataBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + resultMetadata_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ExecutionStatus.LastExecution) } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExternalApi.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExternalApi.java index 30709ef81948..7b076b089eb9 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExternalApi.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExternalApi.java @@ -152,7 +152,7 @@ public com.google.protobuf.ByteString getNameBytes() { * * *
                      -   * Required. Display name of the external API. Max length is 63 characters
                      +   * Required. Display name of the external API. Max length is 500 characters
                          * (Unicode Code Points).
                          * 
                      * @@ -177,7 +177,7 @@ public java.lang.String getDisplayName() { * * *
                      -   * Required. Display name of the external API. Max length is 63 characters
                      +   * Required. Display name of the external API. Max length is 500 characters
                          * (Unicode Code Points).
                          * 
                      * @@ -207,7 +207,7 @@ public com.google.protobuf.ByteString getDisplayNameBytes() { * * *
                      -   * Optional. Description of the external API. Max length is 2000 characters
                      +   * Optional. Description of the external API. Max length is 500000 characters
                          * (Unicode Code Points).
                          * 
                      * @@ -232,7 +232,7 @@ public java.lang.String getDescription() { * * *
                      -   * Optional. Description of the external API. Max length is 2000 characters
                      +   * Optional. Description of the external API. Max length is 500000 characters
                          * (Unicode Code Points).
                          * 
                      * @@ -1417,7 +1417,7 @@ public Builder setNameBytes(com.google.protobuf.ByteString value) { * * *
                      -     * Required. Display name of the external API. Max length is 63 characters
                      +     * Required. Display name of the external API. Max length is 500 characters
                            * (Unicode Code Points).
                            * 
                      * @@ -1441,7 +1441,7 @@ public java.lang.String getDisplayName() { * * *
                      -     * Required. Display name of the external API. Max length is 63 characters
                      +     * Required. Display name of the external API. Max length is 500 characters
                            * (Unicode Code Points).
                            * 
                      * @@ -1465,7 +1465,7 @@ public com.google.protobuf.ByteString getDisplayNameBytes() { * * *
                      -     * Required. Display name of the external API. Max length is 63 characters
                      +     * Required. Display name of the external API. Max length is 500 characters
                            * (Unicode Code Points).
                            * 
                      * @@ -1488,7 +1488,7 @@ public Builder setDisplayName(java.lang.String value) { * * *
                      -     * Required. Display name of the external API. Max length is 63 characters
                      +     * Required. Display name of the external API. Max length is 500 characters
                            * (Unicode Code Points).
                            * 
                      * @@ -1507,7 +1507,7 @@ public Builder clearDisplayName() { * * *
                      -     * Required. Display name of the external API. Max length is 63 characters
                      +     * Required. Display name of the external API. Max length is 500 characters
                            * (Unicode Code Points).
                            * 
                      * @@ -1533,7 +1533,7 @@ public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { * * *
                      -     * Optional. Description of the external API. Max length is 2000 characters
                      +     * Optional. Description of the external API. Max length is 500000 characters
                            * (Unicode Code Points).
                            * 
                      * @@ -1557,7 +1557,7 @@ public java.lang.String getDescription() { * * *
                      -     * Optional. Description of the external API. Max length is 2000 characters
                      +     * Optional. Description of the external API. Max length is 500000 characters
                            * (Unicode Code Points).
                            * 
                      * @@ -1581,7 +1581,7 @@ public com.google.protobuf.ByteString getDescriptionBytes() { * * *
                      -     * Optional. Description of the external API. Max length is 2000 characters
                      +     * Optional. Description of the external API. Max length is 500000 characters
                            * (Unicode Code Points).
                            * 
                      * @@ -1604,7 +1604,7 @@ public Builder setDescription(java.lang.String value) { * * *
                      -     * Optional. Description of the external API. Max length is 2000 characters
                      +     * Optional. Description of the external API. Max length is 500000 characters
                            * (Unicode Code Points).
                            * 
                      * @@ -1623,7 +1623,7 @@ public Builder clearDescription() { * * *
                      -     * Optional. Description of the external API. Max length is 2000 characters
                      +     * Optional. Description of the external API. Max length is 500000 characters
                            * (Unicode Code Points).
                            * 
                      * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExternalApiOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExternalApiOrBuilder.java index 6f776a8f4ff5..aac932bbcc0b 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExternalApiOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ExternalApiOrBuilder.java @@ -58,7 +58,7 @@ public interface ExternalApiOrBuilder * * *
                      -   * Required. Display name of the external API. Max length is 63 characters
                      +   * Required. Display name of the external API. Max length is 500 characters
                          * (Unicode Code Points).
                          * 
                      * @@ -72,7 +72,7 @@ public interface ExternalApiOrBuilder * * *
                      -   * Required. Display name of the external API. Max length is 63 characters
                      +   * Required. Display name of the external API. Max length is 500 characters
                          * (Unicode Code Points).
                          * 
                      * @@ -86,7 +86,7 @@ public interface ExternalApiOrBuilder * * *
                      -   * Optional. Description of the external API. Max length is 2000 characters
                      +   * Optional. Description of the external API. Max length is 500000 characters
                          * (Unicode Code Points).
                          * 
                      * @@ -100,7 +100,7 @@ public interface ExternalApiOrBuilder * * *
                      -   * Optional. Description of the external API. Max length is 2000 characters
                      +   * Optional. Description of the external API. Max length is 500000 characters
                          * (Unicode Code Points).
                          * 
                      * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentRequest.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentRequest.java new file mode 100644 index 000000000000..d9b2e0d33ab6 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentRequest.java @@ -0,0 +1,805 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The
                      + * [FetchAdditionalSpecContent][google.cloud.apihub.v1.ApiHub.FetchAdditionalSpecContent]
                      + * method's request.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.FetchAdditionalSpecContentRequest} + */ +@com.google.protobuf.Generated +public final class FetchAdditionalSpecContentRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.FetchAdditionalSpecContentRequest) + FetchAdditionalSpecContentRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "FetchAdditionalSpecContentRequest"); + } + + // Use FetchAdditionalSpecContentRequest.newBuilder() to construct. + private FetchAdditionalSpecContentRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private FetchAdditionalSpecContentRequest() { + name_ = ""; + specContentType_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest.class, + com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
                      +   * Required. The name of the spec whose contents need to be retrieved.
                      +   * Format:
                      +   * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The name of the spec whose contents need to be retrieved.
                      +   * Format:
                      +   * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SPEC_CONTENT_TYPE_FIELD_NUMBER = 2; + private int specContentType_ = 0; + + /** + * + * + *
                      +   * Optional. The type of the spec contents to be retrieved.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for specContentType. + */ + @java.lang.Override + public int getSpecContentTypeValue() { + return specContentType_; + } + + /** + * + * + *
                      +   * Optional. The type of the spec contents to be retrieved.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The specContentType. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.SpecContentType getSpecContentType() { + com.google.cloud.apihub.v1.SpecContentType result = + com.google.cloud.apihub.v1.SpecContentType.forNumber(specContentType_); + return result == null ? com.google.cloud.apihub.v1.SpecContentType.UNRECOGNIZED : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (specContentType_ + != com.google.cloud.apihub.v1.SpecContentType.SPEC_CONTENT_TYPE_UNSPECIFIED.getNumber()) { + output.writeEnum(2, specContentType_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (specContentType_ + != com.google.cloud.apihub.v1.SpecContentType.SPEC_CONTENT_TYPE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, specContentType_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest other = + (com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (specContentType_ != other.specContentType_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + SPEC_CONTENT_TYPE_FIELD_NUMBER; + hash = (53 * hash) + specContentType_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The
                      +   * [FetchAdditionalSpecContent][google.cloud.apihub.v1.ApiHub.FetchAdditionalSpecContent]
                      +   * method's request.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.FetchAdditionalSpecContentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.FetchAdditionalSpecContentRequest) + com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest.class, + com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + specContentType_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest + getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest build() { + com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest buildPartial() { + com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest result = + new com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.specContentType_ = specContentType_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest) { + return mergeFrom((com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest other) { + if (other + == com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.specContentType_ != 0) { + setSpecContentTypeValue(other.getSpecContentTypeValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + specContentType_ = input.readEnum(); + bitField0_ |= 0x00000002; + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
                      +     * Required. The name of the spec whose contents need to be retrieved.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the spec whose contents need to be retrieved.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the spec whose contents need to be retrieved.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the spec whose contents need to be retrieved.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the spec whose contents need to be retrieved.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int specContentType_ = 0; + + /** + * + * + *
                      +     * Optional. The type of the spec contents to be retrieved.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for specContentType. + */ + @java.lang.Override + public int getSpecContentTypeValue() { + return specContentType_; + } + + /** + * + * + *
                      +     * Optional. The type of the spec contents to be retrieved.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for specContentType to set. + * @return This builder for chaining. + */ + public Builder setSpecContentTypeValue(int value) { + specContentType_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The type of the spec contents to be retrieved.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The specContentType. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.SpecContentType getSpecContentType() { + com.google.cloud.apihub.v1.SpecContentType result = + com.google.cloud.apihub.v1.SpecContentType.forNumber(specContentType_); + return result == null ? com.google.cloud.apihub.v1.SpecContentType.UNRECOGNIZED : result; + } + + /** + * + * + *
                      +     * Optional. The type of the spec contents to be retrieved.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The specContentType to set. + * @return This builder for chaining. + */ + public Builder setSpecContentType(com.google.cloud.apihub.v1.SpecContentType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000002; + specContentType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The type of the spec contents to be retrieved.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearSpecContentType() { + bitField0_ = (bitField0_ & ~0x00000002); + specContentType_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.FetchAdditionalSpecContentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.FetchAdditionalSpecContentRequest) + private static final com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest(); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FetchAdditionalSpecContentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentRequestOrBuilder.java new file mode 100644 index 000000000000..fff451b134f7 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentRequestOrBuilder.java @@ -0,0 +1,92 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface FetchAdditionalSpecContentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.FetchAdditionalSpecContentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The name of the spec whose contents need to be retrieved.
                      +   * Format:
                      +   * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
                      +   * Required. The name of the spec whose contents need to be retrieved.
                      +   * Format:
                      +   * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
                      +   * Optional. The type of the spec contents to be retrieved.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for specContentType. + */ + int getSpecContentTypeValue(); + + /** + * + * + *
                      +   * Optional. The type of the spec contents to be retrieved.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.SpecContentType spec_content_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The specContentType. + */ + com.google.cloud.apihub.v1.SpecContentType getSpecContentType(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentResponse.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentResponse.java new file mode 100644 index 000000000000..a6853903a36e --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentResponse.java @@ -0,0 +1,719 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The
                      + * [FetchAdditionalSpecContent][google.cloud.apihub.v1.ApiHub.FetchAdditionalSpecContent]
                      + * method's response.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.FetchAdditionalSpecContentResponse} + */ +@com.google.protobuf.Generated +public final class FetchAdditionalSpecContentResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.FetchAdditionalSpecContentResponse) + FetchAdditionalSpecContentResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "FetchAdditionalSpecContentResponse"); + } + + // Use FetchAdditionalSpecContentResponse.newBuilder() to construct. + private FetchAdditionalSpecContentResponse( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private FetchAdditionalSpecContentResponse() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse.class, + com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse.Builder.class); + } + + private int bitField0_; + public static final int ADDITIONAL_SPEC_CONTENT_FIELD_NUMBER = 1; + private com.google.cloud.apihub.v1.AdditionalSpecContent additionalSpecContent_; + + /** + * + * + *
                      +   * The additional spec content.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + * + * @return Whether the additionalSpecContent field is set. + */ + @java.lang.Override + public boolean hasAdditionalSpecContent() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * The additional spec content.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + * + * @return The additionalSpecContent. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AdditionalSpecContent getAdditionalSpecContent() { + return additionalSpecContent_ == null + ? com.google.cloud.apihub.v1.AdditionalSpecContent.getDefaultInstance() + : additionalSpecContent_; + } + + /** + * + * + *
                      +   * The additional spec content.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder + getAdditionalSpecContentOrBuilder() { + return additionalSpecContent_ == null + ? com.google.cloud.apihub.v1.AdditionalSpecContent.getDefaultInstance() + : additionalSpecContent_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getAdditionalSpecContent()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, getAdditionalSpecContent()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse other = + (com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse) obj; + + if (hasAdditionalSpecContent() != other.hasAdditionalSpecContent()) return false; + if (hasAdditionalSpecContent()) { + if (!getAdditionalSpecContent().equals(other.getAdditionalSpecContent())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasAdditionalSpecContent()) { + hash = (37 * hash) + ADDITIONAL_SPEC_CONTENT_FIELD_NUMBER; + hash = (53 * hash) + getAdditionalSpecContent().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The
                      +   * [FetchAdditionalSpecContent][google.cloud.apihub.v1.ApiHub.FetchAdditionalSpecContent]
                      +   * method's response.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.FetchAdditionalSpecContentResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.FetchAdditionalSpecContentResponse) + com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse.class, + com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetAdditionalSpecContentFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + additionalSpecContent_ = null; + if (additionalSpecContentBuilder_ != null) { + additionalSpecContentBuilder_.dispose(); + additionalSpecContentBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FetchAdditionalSpecContentResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse + getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse build() { + com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse buildPartial() { + com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse result = + new com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.additionalSpecContent_ = + additionalSpecContentBuilder_ == null + ? additionalSpecContent_ + : additionalSpecContentBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse) { + return mergeFrom((com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse other) { + if (other + == com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse.getDefaultInstance()) + return this; + if (other.hasAdditionalSpecContent()) { + mergeAdditionalSpecContent(other.getAdditionalSpecContent()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetAdditionalSpecContentFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.apihub.v1.AdditionalSpecContent additionalSpecContent_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AdditionalSpecContent, + com.google.cloud.apihub.v1.AdditionalSpecContent.Builder, + com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder> + additionalSpecContentBuilder_; + + /** + * + * + *
                      +     * The additional spec content.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + * + * @return Whether the additionalSpecContent field is set. + */ + public boolean hasAdditionalSpecContent() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * The additional spec content.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + * + * @return The additionalSpecContent. + */ + public com.google.cloud.apihub.v1.AdditionalSpecContent getAdditionalSpecContent() { + if (additionalSpecContentBuilder_ == null) { + return additionalSpecContent_ == null + ? com.google.cloud.apihub.v1.AdditionalSpecContent.getDefaultInstance() + : additionalSpecContent_; + } else { + return additionalSpecContentBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * The additional spec content.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + */ + public Builder setAdditionalSpecContent( + com.google.cloud.apihub.v1.AdditionalSpecContent value) { + if (additionalSpecContentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + additionalSpecContent_ = value; + } else { + additionalSpecContentBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * The additional spec content.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + */ + public Builder setAdditionalSpecContent( + com.google.cloud.apihub.v1.AdditionalSpecContent.Builder builderForValue) { + if (additionalSpecContentBuilder_ == null) { + additionalSpecContent_ = builderForValue.build(); + } else { + additionalSpecContentBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * The additional spec content.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + */ + public Builder mergeAdditionalSpecContent( + com.google.cloud.apihub.v1.AdditionalSpecContent value) { + if (additionalSpecContentBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && additionalSpecContent_ != null + && additionalSpecContent_ + != com.google.cloud.apihub.v1.AdditionalSpecContent.getDefaultInstance()) { + getAdditionalSpecContentBuilder().mergeFrom(value); + } else { + additionalSpecContent_ = value; + } + } else { + additionalSpecContentBuilder_.mergeFrom(value); + } + if (additionalSpecContent_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * The additional spec content.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + */ + public Builder clearAdditionalSpecContent() { + bitField0_ = (bitField0_ & ~0x00000001); + additionalSpecContent_ = null; + if (additionalSpecContentBuilder_ != null) { + additionalSpecContentBuilder_.dispose(); + additionalSpecContentBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * The additional spec content.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + */ + public com.google.cloud.apihub.v1.AdditionalSpecContent.Builder + getAdditionalSpecContentBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetAdditionalSpecContentFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * The additional spec content.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + */ + public com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder + getAdditionalSpecContentOrBuilder() { + if (additionalSpecContentBuilder_ != null) { + return additionalSpecContentBuilder_.getMessageOrBuilder(); + } else { + return additionalSpecContent_ == null + ? com.google.cloud.apihub.v1.AdditionalSpecContent.getDefaultInstance() + : additionalSpecContent_; + } + } + + /** + * + * + *
                      +     * The additional spec content.
                      +     * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AdditionalSpecContent, + com.google.cloud.apihub.v1.AdditionalSpecContent.Builder, + com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder> + internalGetAdditionalSpecContentFieldBuilder() { + if (additionalSpecContentBuilder_ == null) { + additionalSpecContentBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AdditionalSpecContent, + com.google.cloud.apihub.v1.AdditionalSpecContent.Builder, + com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder>( + getAdditionalSpecContent(), getParentForChildren(), isClean()); + additionalSpecContent_ = null; + } + return additionalSpecContentBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.FetchAdditionalSpecContentResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.FetchAdditionalSpecContentResponse) + private static final com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse(); + } + + public static com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FetchAdditionalSpecContentResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentResponseOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentResponseOrBuilder.java new file mode 100644 index 000000000000..93d901840077 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FetchAdditionalSpecContentResponseOrBuilder.java @@ -0,0 +1,65 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface FetchAdditionalSpecContentResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.FetchAdditionalSpecContentResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * The additional spec content.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + * + * @return Whether the additionalSpecContent field is set. + */ + boolean hasAdditionalSpecContent(); + + /** + * + * + *
                      +   * The additional spec content.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + * + * @return The additionalSpecContent. + */ + com.google.cloud.apihub.v1.AdditionalSpecContent getAdditionalSpecContent(); + + /** + * + * + *
                      +   * The additional spec content.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_content = 1; + */ + com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder getAdditionalSpecContentOrBuilder(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionDeploymentView.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionDeploymentView.java new file mode 100644 index 000000000000..23dd97ef89d2 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionDeploymentView.java @@ -0,0 +1,1288 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * A flattened view of an API, its version and one of the linked deployments.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.FlattenedApiVersionDeploymentView} + */ +@com.google.protobuf.Generated +public final class FlattenedApiVersionDeploymentView extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) + FlattenedApiVersionDeploymentViewOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "FlattenedApiVersionDeploymentView"); + } + + // Use FlattenedApiVersionDeploymentView.newBuilder() to construct. + private FlattenedApiVersionDeploymentView( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private FlattenedApiVersionDeploymentView() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FlattenedApiVersionDeploymentView_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FlattenedApiVersionDeploymentView_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.class, + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.Builder.class); + } + + private int bitField0_; + public static final int API_FIELD_NUMBER = 1; + private com.google.cloud.apihub.v1.Api api_; + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the api field is set. + */ + @java.lang.Override + public boolean hasApi() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The api. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.Api getApi() { + return api_ == null ? com.google.cloud.apihub.v1.Api.getDefaultInstance() : api_; + } + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiOrBuilder getApiOrBuilder() { + return api_ == null ? com.google.cloud.apihub.v1.Api.getDefaultInstance() : api_; + } + + public static final int VERSION_FIELD_NUMBER = 2; + private com.google.cloud.apihub.v1.Version version_; + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the version field is set. + */ + @java.lang.Override + public boolean hasVersion() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The version. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.Version getVersion() { + return version_ == null ? com.google.cloud.apihub.v1.Version.getDefaultInstance() : version_; + } + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.VersionOrBuilder getVersionOrBuilder() { + return version_ == null ? com.google.cloud.apihub.v1.Version.getDefaultInstance() : version_; + } + + public static final int DEPLOYMENT_FIELD_NUMBER = 3; + private com.google.cloud.apihub.v1.Deployment deployment_; + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the deployment field is set. + */ + @java.lang.Override + public boolean hasDeployment() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The deployment. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.Deployment getDeployment() { + return deployment_ == null + ? com.google.cloud.apihub.v1.Deployment.getDefaultInstance() + : deployment_; + } + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.DeploymentOrBuilder getDeploymentOrBuilder() { + return deployment_ == null + ? com.google.cloud.apihub.v1.Deployment.getDefaultInstance() + : deployment_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getApi()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getVersion()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(3, getDeployment()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getApi()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getVersion()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getDeployment()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView other = + (com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) obj; + + if (hasApi() != other.hasApi()) return false; + if (hasApi()) { + if (!getApi().equals(other.getApi())) return false; + } + if (hasVersion() != other.hasVersion()) return false; + if (hasVersion()) { + if (!getVersion().equals(other.getVersion())) return false; + } + if (hasDeployment() != other.hasDeployment()) return false; + if (hasDeployment()) { + if (!getDeployment().equals(other.getDeployment())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasApi()) { + hash = (37 * hash) + API_FIELD_NUMBER; + hash = (53 * hash) + getApi().hashCode(); + } + if (hasVersion()) { + hash = (37 * hash) + VERSION_FIELD_NUMBER; + hash = (53 * hash) + getVersion().hashCode(); + } + if (hasDeployment()) { + hash = (37 * hash) + DEPLOYMENT_FIELD_NUMBER; + hash = (53 * hash) + getDeployment().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * A flattened view of an API, its version and one of the linked deployments.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.FlattenedApiVersionDeploymentView} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentViewOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FlattenedApiVersionDeploymentView_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FlattenedApiVersionDeploymentView_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.class, + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetApiFieldBuilder(); + internalGetVersionFieldBuilder(); + internalGetDeploymentFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + api_ = null; + if (apiBuilder_ != null) { + apiBuilder_.dispose(); + apiBuilder_ = null; + } + version_ = null; + if (versionBuilder_ != null) { + versionBuilder_.dispose(); + versionBuilder_ = null; + } + deployment_ = null; + if (deploymentBuilder_ != null) { + deploymentBuilder_.dispose(); + deploymentBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FlattenedApiVersionDeploymentView_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView + getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView build() { + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView buildPartial() { + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView result = + new com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.api_ = apiBuilder_ == null ? api_ : apiBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.version_ = versionBuilder_ == null ? version_ : versionBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.deployment_ = deploymentBuilder_ == null ? deployment_ : deploymentBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) { + return mergeFrom((com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView other) { + if (other + == com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView.getDefaultInstance()) + return this; + if (other.hasApi()) { + mergeApi(other.getApi()); + } + if (other.hasVersion()) { + mergeVersion(other.getVersion()); + } + if (other.hasDeployment()) { + mergeDeployment(other.getDeployment()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(internalGetApiFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage(internalGetVersionFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetDeploymentFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.apihub.v1.Api api_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Api, + com.google.cloud.apihub.v1.Api.Builder, + com.google.cloud.apihub.v1.ApiOrBuilder> + apiBuilder_; + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the api field is set. + */ + public boolean hasApi() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The api. + */ + public com.google.cloud.apihub.v1.Api getApi() { + if (apiBuilder_ == null) { + return api_ == null ? com.google.cloud.apihub.v1.Api.getDefaultInstance() : api_; + } else { + return apiBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder setApi(com.google.cloud.apihub.v1.Api value) { + if (apiBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + api_ = value; + } else { + apiBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder setApi(com.google.cloud.apihub.v1.Api.Builder builderForValue) { + if (apiBuilder_ == null) { + api_ = builderForValue.build(); + } else { + apiBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder mergeApi(com.google.cloud.apihub.v1.Api value) { + if (apiBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && api_ != null + && api_ != com.google.cloud.apihub.v1.Api.getDefaultInstance()) { + getApiBuilder().mergeFrom(value); + } else { + api_ = value; + } + } else { + apiBuilder_.mergeFrom(value); + } + if (api_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder clearApi() { + bitField0_ = (bitField0_ & ~0x00000001); + api_ = null; + if (apiBuilder_ != null) { + apiBuilder_.dispose(); + apiBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public com.google.cloud.apihub.v1.Api.Builder getApiBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetApiFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public com.google.cloud.apihub.v1.ApiOrBuilder getApiOrBuilder() { + if (apiBuilder_ != null) { + return apiBuilder_.getMessageOrBuilder(); + } else { + return api_ == null ? com.google.cloud.apihub.v1.Api.getDefaultInstance() : api_; + } + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Api, + com.google.cloud.apihub.v1.Api.Builder, + com.google.cloud.apihub.v1.ApiOrBuilder> + internalGetApiFieldBuilder() { + if (apiBuilder_ == null) { + apiBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Api, + com.google.cloud.apihub.v1.Api.Builder, + com.google.cloud.apihub.v1.ApiOrBuilder>( + getApi(), getParentForChildren(), isClean()); + api_ = null; + } + return apiBuilder_; + } + + private com.google.cloud.apihub.v1.Version version_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Version, + com.google.cloud.apihub.v1.Version.Builder, + com.google.cloud.apihub.v1.VersionOrBuilder> + versionBuilder_; + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the version field is set. + */ + public boolean hasVersion() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The version. + */ + public com.google.cloud.apihub.v1.Version getVersion() { + if (versionBuilder_ == null) { + return version_ == null + ? com.google.cloud.apihub.v1.Version.getDefaultInstance() + : version_; + } else { + return versionBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setVersion(com.google.cloud.apihub.v1.Version value) { + if (versionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + version_ = value; + } else { + versionBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setVersion(com.google.cloud.apihub.v1.Version.Builder builderForValue) { + if (versionBuilder_ == null) { + version_ = builderForValue.build(); + } else { + versionBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeVersion(com.google.cloud.apihub.v1.Version value) { + if (versionBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && version_ != null + && version_ != com.google.cloud.apihub.v1.Version.getDefaultInstance()) { + getVersionBuilder().mergeFrom(value); + } else { + version_ = value; + } + } else { + versionBuilder_.mergeFrom(value); + } + if (version_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearVersion() { + bitField0_ = (bitField0_ & ~0x00000002); + version_ = null; + if (versionBuilder_ != null) { + versionBuilder_.dispose(); + versionBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.Version.Builder getVersionBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetVersionFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.VersionOrBuilder getVersionOrBuilder() { + if (versionBuilder_ != null) { + return versionBuilder_.getMessageOrBuilder(); + } else { + return version_ == null + ? com.google.cloud.apihub.v1.Version.getDefaultInstance() + : version_; + } + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Version, + com.google.cloud.apihub.v1.Version.Builder, + com.google.cloud.apihub.v1.VersionOrBuilder> + internalGetVersionFieldBuilder() { + if (versionBuilder_ == null) { + versionBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Version, + com.google.cloud.apihub.v1.Version.Builder, + com.google.cloud.apihub.v1.VersionOrBuilder>( + getVersion(), getParentForChildren(), isClean()); + version_ = null; + } + return versionBuilder_; + } + + private com.google.cloud.apihub.v1.Deployment deployment_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Deployment, + com.google.cloud.apihub.v1.Deployment.Builder, + com.google.cloud.apihub.v1.DeploymentOrBuilder> + deploymentBuilder_; + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the deployment field is set. + */ + public boolean hasDeployment() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The deployment. + */ + public com.google.cloud.apihub.v1.Deployment getDeployment() { + if (deploymentBuilder_ == null) { + return deployment_ == null + ? com.google.cloud.apihub.v1.Deployment.getDefaultInstance() + : deployment_; + } else { + return deploymentBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setDeployment(com.google.cloud.apihub.v1.Deployment value) { + if (deploymentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + deployment_ = value; + } else { + deploymentBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setDeployment(com.google.cloud.apihub.v1.Deployment.Builder builderForValue) { + if (deploymentBuilder_ == null) { + deployment_ = builderForValue.build(); + } else { + deploymentBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeDeployment(com.google.cloud.apihub.v1.Deployment value) { + if (deploymentBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && deployment_ != null + && deployment_ != com.google.cloud.apihub.v1.Deployment.getDefaultInstance()) { + getDeploymentBuilder().mergeFrom(value); + } else { + deployment_ = value; + } + } else { + deploymentBuilder_.mergeFrom(value); + } + if (deployment_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearDeployment() { + bitField0_ = (bitField0_ & ~0x00000004); + deployment_ = null; + if (deploymentBuilder_ != null) { + deploymentBuilder_.dispose(); + deploymentBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.Deployment.Builder getDeploymentBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetDeploymentFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.DeploymentOrBuilder getDeploymentOrBuilder() { + if (deploymentBuilder_ != null) { + return deploymentBuilder_.getMessageOrBuilder(); + } else { + return deployment_ == null + ? com.google.cloud.apihub.v1.Deployment.getDefaultInstance() + : deployment_; + } + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Deployment, + com.google.cloud.apihub.v1.Deployment.Builder, + com.google.cloud.apihub.v1.DeploymentOrBuilder> + internalGetDeploymentFieldBuilder() { + if (deploymentBuilder_ == null) { + deploymentBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Deployment, + com.google.cloud.apihub.v1.Deployment.Builder, + com.google.cloud.apihub.v1.DeploymentOrBuilder>( + getDeployment(), getParentForChildren(), isClean()); + deployment_ = null; + } + return deploymentBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) + private static final com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView(); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FlattenedApiVersionDeploymentView parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionDeploymentView getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionDeploymentViewOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionDeploymentViewOrBuilder.java new file mode 100644 index 000000000000..7920b318f0eb --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionDeploymentViewOrBuilder.java @@ -0,0 +1,148 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface FlattenedApiVersionDeploymentViewOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.FlattenedApiVersionDeploymentView) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the api field is set. + */ + boolean hasApi(); + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The api. + */ + com.google.cloud.apihub.v1.Api getApi(); + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + com.google.cloud.apihub.v1.ApiOrBuilder getApiOrBuilder(); + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the version field is set. + */ + boolean hasVersion(); + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The version. + */ + com.google.cloud.apihub.v1.Version getVersion(); + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.VersionOrBuilder getVersionOrBuilder(); + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the deployment field is set. + */ + boolean hasDeployment(); + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The deployment. + */ + com.google.cloud.apihub.v1.Deployment getDeployment(); + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.DeploymentOrBuilder getDeploymentOrBuilder(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionOperationDeploymentView.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionOperationDeploymentView.java new file mode 100644 index 000000000000..206d2c7d1955 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionOperationDeploymentView.java @@ -0,0 +1,1609 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * A flattened view of an API, its version, one of its operations and one of the
                      + * linked deployments. If there are no deployments linked to the operation then
                      + * the result will be empty.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView} + */ +@com.google.protobuf.Generated +public final class FlattenedApiVersionOperationDeploymentView + extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) + FlattenedApiVersionOperationDeploymentViewOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "FlattenedApiVersionOperationDeploymentView"); + } + + // Use FlattenedApiVersionOperationDeploymentView.newBuilder() to construct. + private FlattenedApiVersionOperationDeploymentView( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private FlattenedApiVersionOperationDeploymentView() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FlattenedApiVersionOperationDeploymentView_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FlattenedApiVersionOperationDeploymentView_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView.class, + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView.Builder.class); + } + + private int bitField0_; + public static final int API_FIELD_NUMBER = 1; + private com.google.cloud.apihub.v1.Api api_; + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the api field is set. + */ + @java.lang.Override + public boolean hasApi() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The api. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.Api getApi() { + return api_ == null ? com.google.cloud.apihub.v1.Api.getDefaultInstance() : api_; + } + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiOrBuilder getApiOrBuilder() { + return api_ == null ? com.google.cloud.apihub.v1.Api.getDefaultInstance() : api_; + } + + public static final int VERSION_FIELD_NUMBER = 2; + private com.google.cloud.apihub.v1.Version version_; + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the version field is set. + */ + @java.lang.Override + public boolean hasVersion() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The version. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.Version getVersion() { + return version_ == null ? com.google.cloud.apihub.v1.Version.getDefaultInstance() : version_; + } + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.VersionOrBuilder getVersionOrBuilder() { + return version_ == null ? com.google.cloud.apihub.v1.Version.getDefaultInstance() : version_; + } + + public static final int API_OPERATION_FIELD_NUMBER = 3; + private com.google.cloud.apihub.v1.ApiOperation apiOperation_; + + /** + * + * + *
                      +   * Optional. The API operation.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the apiOperation field is set. + */ + @java.lang.Override + public boolean hasApiOperation() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +   * Optional. The API operation.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The apiOperation. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiOperation getApiOperation() { + return apiOperation_ == null + ? com.google.cloud.apihub.v1.ApiOperation.getDefaultInstance() + : apiOperation_; + } + + /** + * + * + *
                      +   * Optional. The API operation.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiOperationOrBuilder getApiOperationOrBuilder() { + return apiOperation_ == null + ? com.google.cloud.apihub.v1.ApiOperation.getDefaultInstance() + : apiOperation_; + } + + public static final int DEPLOYMENT_FIELD_NUMBER = 4; + private com.google.cloud.apihub.v1.Deployment deployment_; + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the deployment field is set. + */ + @java.lang.Override + public boolean hasDeployment() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The deployment. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.Deployment getDeployment() { + return deployment_ == null + ? com.google.cloud.apihub.v1.Deployment.getDefaultInstance() + : deployment_; + } + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.DeploymentOrBuilder getDeploymentOrBuilder() { + return deployment_ == null + ? com.google.cloud.apihub.v1.Deployment.getDefaultInstance() + : deployment_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getApi()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getVersion()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(3, getApiOperation()); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeMessage(4, getDeployment()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getApi()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getVersion()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getApiOperation()); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getDeployment()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView other = + (com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) obj; + + if (hasApi() != other.hasApi()) return false; + if (hasApi()) { + if (!getApi().equals(other.getApi())) return false; + } + if (hasVersion() != other.hasVersion()) return false; + if (hasVersion()) { + if (!getVersion().equals(other.getVersion())) return false; + } + if (hasApiOperation() != other.hasApiOperation()) return false; + if (hasApiOperation()) { + if (!getApiOperation().equals(other.getApiOperation())) return false; + } + if (hasDeployment() != other.hasDeployment()) return false; + if (hasDeployment()) { + if (!getDeployment().equals(other.getDeployment())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasApi()) { + hash = (37 * hash) + API_FIELD_NUMBER; + hash = (53 * hash) + getApi().hashCode(); + } + if (hasVersion()) { + hash = (37 * hash) + VERSION_FIELD_NUMBER; + hash = (53 * hash) + getVersion().hashCode(); + } + if (hasApiOperation()) { + hash = (37 * hash) + API_OPERATION_FIELD_NUMBER; + hash = (53 * hash) + getApiOperation().hashCode(); + } + if (hasDeployment()) { + hash = (37 * hash) + DEPLOYMENT_FIELD_NUMBER; + hash = (53 * hash) + getDeployment().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * A flattened view of an API, its version, one of its operations and one of the
                      +   * linked deployments. If there are no deployments linked to the operation then
                      +   * the result will be empty.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentViewOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FlattenedApiVersionOperationDeploymentView_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FlattenedApiVersionOperationDeploymentView_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView.class, + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView.Builder.class); + } + + // Construct using + // com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetApiFieldBuilder(); + internalGetVersionFieldBuilder(); + internalGetApiOperationFieldBuilder(); + internalGetDeploymentFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + api_ = null; + if (apiBuilder_ != null) { + apiBuilder_.dispose(); + apiBuilder_ = null; + } + version_ = null; + if (versionBuilder_ != null) { + versionBuilder_.dispose(); + versionBuilder_ = null; + } + apiOperation_ = null; + if (apiOperationBuilder_ != null) { + apiOperationBuilder_.dispose(); + apiOperationBuilder_ = null; + } + deployment_ = null; + if (deploymentBuilder_ != null) { + deploymentBuilder_.dispose(); + deploymentBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_FlattenedApiVersionOperationDeploymentView_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView build() { + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView buildPartial() { + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView result = + new com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.api_ = apiBuilder_ == null ? api_ : apiBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.version_ = versionBuilder_ == null ? version_ : versionBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.apiOperation_ = + apiOperationBuilder_ == null ? apiOperation_ : apiOperationBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.deployment_ = deploymentBuilder_ == null ? deployment_ : deploymentBuilder_.build(); + to_bitField0_ |= 0x00000008; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) { + return mergeFrom( + (com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView other) { + if (other + == com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + .getDefaultInstance()) return this; + if (other.hasApi()) { + mergeApi(other.getApi()); + } + if (other.hasVersion()) { + mergeVersion(other.getVersion()); + } + if (other.hasApiOperation()) { + mergeApiOperation(other.getApiOperation()); + } + if (other.hasDeployment()) { + mergeDeployment(other.getDeployment()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(internalGetApiFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage(internalGetVersionFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetApiOperationFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetDeploymentFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.apihub.v1.Api api_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Api, + com.google.cloud.apihub.v1.Api.Builder, + com.google.cloud.apihub.v1.ApiOrBuilder> + apiBuilder_; + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the api field is set. + */ + public boolean hasApi() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The api. + */ + public com.google.cloud.apihub.v1.Api getApi() { + if (apiBuilder_ == null) { + return api_ == null ? com.google.cloud.apihub.v1.Api.getDefaultInstance() : api_; + } else { + return apiBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder setApi(com.google.cloud.apihub.v1.Api value) { + if (apiBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + api_ = value; + } else { + apiBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder setApi(com.google.cloud.apihub.v1.Api.Builder builderForValue) { + if (apiBuilder_ == null) { + api_ = builderForValue.build(); + } else { + apiBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder mergeApi(com.google.cloud.apihub.v1.Api value) { + if (apiBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && api_ != null + && api_ != com.google.cloud.apihub.v1.Api.getDefaultInstance()) { + getApiBuilder().mergeFrom(value); + } else { + api_ = value; + } + } else { + apiBuilder_.mergeFrom(value); + } + if (api_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder clearApi() { + bitField0_ = (bitField0_ & ~0x00000001); + api_ = null; + if (apiBuilder_ != null) { + apiBuilder_.dispose(); + apiBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public com.google.cloud.apihub.v1.Api.Builder getApiBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetApiFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + public com.google.cloud.apihub.v1.ApiOrBuilder getApiOrBuilder() { + if (apiBuilder_ != null) { + return apiBuilder_.getMessageOrBuilder(); + } else { + return api_ == null ? com.google.cloud.apihub.v1.Api.getDefaultInstance() : api_; + } + } + + /** + * + * + *
                      +     * Optional. The API.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Api, + com.google.cloud.apihub.v1.Api.Builder, + com.google.cloud.apihub.v1.ApiOrBuilder> + internalGetApiFieldBuilder() { + if (apiBuilder_ == null) { + apiBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Api, + com.google.cloud.apihub.v1.Api.Builder, + com.google.cloud.apihub.v1.ApiOrBuilder>( + getApi(), getParentForChildren(), isClean()); + api_ = null; + } + return apiBuilder_; + } + + private com.google.cloud.apihub.v1.Version version_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Version, + com.google.cloud.apihub.v1.Version.Builder, + com.google.cloud.apihub.v1.VersionOrBuilder> + versionBuilder_; + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the version field is set. + */ + public boolean hasVersion() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The version. + */ + public com.google.cloud.apihub.v1.Version getVersion() { + if (versionBuilder_ == null) { + return version_ == null + ? com.google.cloud.apihub.v1.Version.getDefaultInstance() + : version_; + } else { + return versionBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setVersion(com.google.cloud.apihub.v1.Version value) { + if (versionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + version_ = value; + } else { + versionBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setVersion(com.google.cloud.apihub.v1.Version.Builder builderForValue) { + if (versionBuilder_ == null) { + version_ = builderForValue.build(); + } else { + versionBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeVersion(com.google.cloud.apihub.v1.Version value) { + if (versionBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && version_ != null + && version_ != com.google.cloud.apihub.v1.Version.getDefaultInstance()) { + getVersionBuilder().mergeFrom(value); + } else { + version_ = value; + } + } else { + versionBuilder_.mergeFrom(value); + } + if (version_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearVersion() { + bitField0_ = (bitField0_ & ~0x00000002); + version_ = null; + if (versionBuilder_ != null) { + versionBuilder_.dispose(); + versionBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.Version.Builder getVersionBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetVersionFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.VersionOrBuilder getVersionOrBuilder() { + if (versionBuilder_ != null) { + return versionBuilder_.getMessageOrBuilder(); + } else { + return version_ == null + ? com.google.cloud.apihub.v1.Version.getDefaultInstance() + : version_; + } + } + + /** + * + * + *
                      +     * Optional. The version.
                      +     * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Version, + com.google.cloud.apihub.v1.Version.Builder, + com.google.cloud.apihub.v1.VersionOrBuilder> + internalGetVersionFieldBuilder() { + if (versionBuilder_ == null) { + versionBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Version, + com.google.cloud.apihub.v1.Version.Builder, + com.google.cloud.apihub.v1.VersionOrBuilder>( + getVersion(), getParentForChildren(), isClean()); + version_ = null; + } + return versionBuilder_; + } + + private com.google.cloud.apihub.v1.ApiOperation apiOperation_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApiOperation, + com.google.cloud.apihub.v1.ApiOperation.Builder, + com.google.cloud.apihub.v1.ApiOperationOrBuilder> + apiOperationBuilder_; + + /** + * + * + *
                      +     * Optional. The API operation.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the apiOperation field is set. + */ + public boolean hasApiOperation() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +     * Optional. The API operation.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The apiOperation. + */ + public com.google.cloud.apihub.v1.ApiOperation getApiOperation() { + if (apiOperationBuilder_ == null) { + return apiOperation_ == null + ? com.google.cloud.apihub.v1.ApiOperation.getDefaultInstance() + : apiOperation_; + } else { + return apiOperationBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The API operation.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setApiOperation(com.google.cloud.apihub.v1.ApiOperation value) { + if (apiOperationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + apiOperation_ = value; + } else { + apiOperationBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The API operation.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setApiOperation( + com.google.cloud.apihub.v1.ApiOperation.Builder builderForValue) { + if (apiOperationBuilder_ == null) { + apiOperation_ = builderForValue.build(); + } else { + apiOperationBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The API operation.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeApiOperation(com.google.cloud.apihub.v1.ApiOperation value) { + if (apiOperationBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && apiOperation_ != null + && apiOperation_ != com.google.cloud.apihub.v1.ApiOperation.getDefaultInstance()) { + getApiOperationBuilder().mergeFrom(value); + } else { + apiOperation_ = value; + } + } else { + apiOperationBuilder_.mergeFrom(value); + } + if (apiOperation_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The API operation.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearApiOperation() { + bitField0_ = (bitField0_ & ~0x00000004); + apiOperation_ = null; + if (apiOperationBuilder_ != null) { + apiOperationBuilder_.dispose(); + apiOperationBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The API operation.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.ApiOperation.Builder getApiOperationBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetApiOperationFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The API operation.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.ApiOperationOrBuilder getApiOperationOrBuilder() { + if (apiOperationBuilder_ != null) { + return apiOperationBuilder_.getMessageOrBuilder(); + } else { + return apiOperation_ == null + ? com.google.cloud.apihub.v1.ApiOperation.getDefaultInstance() + : apiOperation_; + } + } + + /** + * + * + *
                      +     * Optional. The API operation.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApiOperation, + com.google.cloud.apihub.v1.ApiOperation.Builder, + com.google.cloud.apihub.v1.ApiOperationOrBuilder> + internalGetApiOperationFieldBuilder() { + if (apiOperationBuilder_ == null) { + apiOperationBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApiOperation, + com.google.cloud.apihub.v1.ApiOperation.Builder, + com.google.cloud.apihub.v1.ApiOperationOrBuilder>( + getApiOperation(), getParentForChildren(), isClean()); + apiOperation_ = null; + } + return apiOperationBuilder_; + } + + private com.google.cloud.apihub.v1.Deployment deployment_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Deployment, + com.google.cloud.apihub.v1.Deployment.Builder, + com.google.cloud.apihub.v1.DeploymentOrBuilder> + deploymentBuilder_; + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the deployment field is set. + */ + public boolean hasDeployment() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The deployment. + */ + public com.google.cloud.apihub.v1.Deployment getDeployment() { + if (deploymentBuilder_ == null) { + return deployment_ == null + ? com.google.cloud.apihub.v1.Deployment.getDefaultInstance() + : deployment_; + } else { + return deploymentBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setDeployment(com.google.cloud.apihub.v1.Deployment value) { + if (deploymentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + deployment_ = value; + } else { + deploymentBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setDeployment(com.google.cloud.apihub.v1.Deployment.Builder builderForValue) { + if (deploymentBuilder_ == null) { + deployment_ = builderForValue.build(); + } else { + deploymentBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeDeployment(com.google.cloud.apihub.v1.Deployment value) { + if (deploymentBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && deployment_ != null + && deployment_ != com.google.cloud.apihub.v1.Deployment.getDefaultInstance()) { + getDeploymentBuilder().mergeFrom(value); + } else { + deployment_ = value; + } + } else { + deploymentBuilder_.mergeFrom(value); + } + if (deployment_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearDeployment() { + bitField0_ = (bitField0_ & ~0x00000008); + deployment_ = null; + if (deploymentBuilder_ != null) { + deploymentBuilder_.dispose(); + deploymentBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.Deployment.Builder getDeploymentBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetDeploymentFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.DeploymentOrBuilder getDeploymentOrBuilder() { + if (deploymentBuilder_ != null) { + return deploymentBuilder_.getMessageOrBuilder(); + } else { + return deployment_ == null + ? com.google.cloud.apihub.v1.Deployment.getDefaultInstance() + : deployment_; + } + } + + /** + * + * + *
                      +     * Optional. The deployment.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Deployment, + com.google.cloud.apihub.v1.Deployment.Builder, + com.google.cloud.apihub.v1.DeploymentOrBuilder> + internalGetDeploymentFieldBuilder() { + if (deploymentBuilder_ == null) { + deploymentBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.Deployment, + com.google.cloud.apihub.v1.Deployment.Builder, + com.google.cloud.apihub.v1.DeploymentOrBuilder>( + getDeployment(), getParentForChildren(), isClean()); + deployment_ = null; + } + return deploymentBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) + private static final com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView(); + } + + public static com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FlattenedApiVersionOperationDeploymentView parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionOperationDeploymentViewOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionOperationDeploymentViewOrBuilder.java new file mode 100644 index 000000000000..d32523d9ee73 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/FlattenedApiVersionOperationDeploymentViewOrBuilder.java @@ -0,0 +1,191 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface FlattenedApiVersionOperationDeploymentViewOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.FlattenedApiVersionOperationDeploymentView) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the api field is set. + */ + boolean hasApi(); + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The api. + */ + com.google.cloud.apihub.v1.Api getApi(); + + /** + * + * + *
                      +   * Optional. The API.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Api api = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + com.google.cloud.apihub.v1.ApiOrBuilder getApiOrBuilder(); + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the version field is set. + */ + boolean hasVersion(); + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The version. + */ + com.google.cloud.apihub.v1.Version getVersion(); + + /** + * + * + *
                      +   * Optional. The version.
                      +   * 
                      + * + * .google.cloud.apihub.v1.Version version = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.VersionOrBuilder getVersionOrBuilder(); + + /** + * + * + *
                      +   * Optional. The API operation.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the apiOperation field is set. + */ + boolean hasApiOperation(); + + /** + * + * + *
                      +   * Optional. The API operation.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The apiOperation. + */ + com.google.cloud.apihub.v1.ApiOperation getApiOperation(); + + /** + * + * + *
                      +   * Optional. The API operation.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiOperation api_operation = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.ApiOperationOrBuilder getApiOperationOrBuilder(); + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the deployment field is set. + */ + boolean hasDeployment(); + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The deployment. + */ + com.google.cloud.apihub.v1.Deployment getDeployment(); + + /** + * + * + *
                      +   * Optional. The deployment.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.Deployment deployment = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.DeploymentOrBuilder getDeploymentOrBuilder(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginAddonConfig.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginAddonConfig.java new file mode 100644 index 000000000000..63f8cbed6b36 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginAddonConfig.java @@ -0,0 +1,1010 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Configuration for gateway plugin addons.
                      + * This is used to specify the list of gateway plugin configs for which the
                      + * addon is enabled.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.GatewayPluginAddonConfig} + */ +@com.google.protobuf.Generated +public final class GatewayPluginAddonConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.GatewayPluginAddonConfig) + GatewayPluginAddonConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GatewayPluginAddonConfig"); + } + + // Use GatewayPluginAddonConfig.newBuilder() to construct. + private GatewayPluginAddonConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GatewayPluginAddonConfig() { + gatewayPluginConfigs_ = java.util.Collections.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GatewayPluginAddonConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GatewayPluginAddonConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.GatewayPluginAddonConfig.class, + com.google.cloud.apihub.v1.GatewayPluginAddonConfig.Builder.class); + } + + public static final int GATEWAY_PLUGIN_CONFIGS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List gatewayPluginConfigs_; + + /** + * + * + *
                      +   * Required. The list of gateway plugin configs for which the addon is
                      +   * enabled. Each gateway plugin config should have a unique plugin instance.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public java.util.List + getGatewayPluginConfigsList() { + return gatewayPluginConfigs_; + } + + /** + * + * + *
                      +   * Required. The list of gateway plugin configs for which the addon is
                      +   * enabled. Each gateway plugin config should have a unique plugin instance.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public java.util.List + getGatewayPluginConfigsOrBuilderList() { + return gatewayPluginConfigs_; + } + + /** + * + * + *
                      +   * Required. The list of gateway plugin configs for which the addon is
                      +   * enabled. Each gateway plugin config should have a unique plugin instance.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public int getGatewayPluginConfigsCount() { + return gatewayPluginConfigs_.size(); + } + + /** + * + * + *
                      +   * Required. The list of gateway plugin configs for which the addon is
                      +   * enabled. Each gateway plugin config should have a unique plugin instance.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginConfig getGatewayPluginConfigs(int index) { + return gatewayPluginConfigs_.get(index); + } + + /** + * + * + *
                      +   * Required. The list of gateway plugin configs for which the addon is
                      +   * enabled. Each gateway plugin config should have a unique plugin instance.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginConfigOrBuilder getGatewayPluginConfigsOrBuilder( + int index) { + return gatewayPluginConfigs_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < gatewayPluginConfigs_.size(); i++) { + output.writeMessage(1, gatewayPluginConfigs_.get(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < gatewayPluginConfigs_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, gatewayPluginConfigs_.get(i)); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.GatewayPluginAddonConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.GatewayPluginAddonConfig other = + (com.google.cloud.apihub.v1.GatewayPluginAddonConfig) obj; + + if (!getGatewayPluginConfigsList().equals(other.getGatewayPluginConfigsList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getGatewayPluginConfigsCount() > 0) { + hash = (37 * hash) + GATEWAY_PLUGIN_CONFIGS_FIELD_NUMBER; + hash = (53 * hash) + getGatewayPluginConfigsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.GatewayPluginAddonConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Configuration for gateway plugin addons.
                      +   * This is used to specify the list of gateway plugin configs for which the
                      +   * addon is enabled.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.GatewayPluginAddonConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.GatewayPluginAddonConfig) + com.google.cloud.apihub.v1.GatewayPluginAddonConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GatewayPluginAddonConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GatewayPluginAddonConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.GatewayPluginAddonConfig.class, + com.google.cloud.apihub.v1.GatewayPluginAddonConfig.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.GatewayPluginAddonConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (gatewayPluginConfigsBuilder_ == null) { + gatewayPluginConfigs_ = java.util.Collections.emptyList(); + } else { + gatewayPluginConfigs_ = null; + gatewayPluginConfigsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GatewayPluginAddonConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginAddonConfig getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.GatewayPluginAddonConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginAddonConfig build() { + com.google.cloud.apihub.v1.GatewayPluginAddonConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginAddonConfig buildPartial() { + com.google.cloud.apihub.v1.GatewayPluginAddonConfig result = + new com.google.cloud.apihub.v1.GatewayPluginAddonConfig(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.apihub.v1.GatewayPluginAddonConfig result) { + if (gatewayPluginConfigsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + gatewayPluginConfigs_ = java.util.Collections.unmodifiableList(gatewayPluginConfigs_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.gatewayPluginConfigs_ = gatewayPluginConfigs_; + } else { + result.gatewayPluginConfigs_ = gatewayPluginConfigsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.apihub.v1.GatewayPluginAddonConfig result) { + int from_bitField0_ = bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.GatewayPluginAddonConfig) { + return mergeFrom((com.google.cloud.apihub.v1.GatewayPluginAddonConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.GatewayPluginAddonConfig other) { + if (other == com.google.cloud.apihub.v1.GatewayPluginAddonConfig.getDefaultInstance()) + return this; + if (gatewayPluginConfigsBuilder_ == null) { + if (!other.gatewayPluginConfigs_.isEmpty()) { + if (gatewayPluginConfigs_.isEmpty()) { + gatewayPluginConfigs_ = other.gatewayPluginConfigs_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureGatewayPluginConfigsIsMutable(); + gatewayPluginConfigs_.addAll(other.gatewayPluginConfigs_); + } + onChanged(); + } + } else { + if (!other.gatewayPluginConfigs_.isEmpty()) { + if (gatewayPluginConfigsBuilder_.isEmpty()) { + gatewayPluginConfigsBuilder_.dispose(); + gatewayPluginConfigsBuilder_ = null; + gatewayPluginConfigs_ = other.gatewayPluginConfigs_; + bitField0_ = (bitField0_ & ~0x00000001); + gatewayPluginConfigsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetGatewayPluginConfigsFieldBuilder() + : null; + } else { + gatewayPluginConfigsBuilder_.addAllMessages(other.gatewayPluginConfigs_); + } + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.apihub.v1.GatewayPluginConfig m = + input.readMessage( + com.google.cloud.apihub.v1.GatewayPluginConfig.parser(), extensionRegistry); + if (gatewayPluginConfigsBuilder_ == null) { + ensureGatewayPluginConfigsIsMutable(); + gatewayPluginConfigs_.add(m); + } else { + gatewayPluginConfigsBuilder_.addMessage(m); + } + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List gatewayPluginConfigs_ = + java.util.Collections.emptyList(); + + private void ensureGatewayPluginConfigsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + gatewayPluginConfigs_ = + new java.util.ArrayList( + gatewayPluginConfigs_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.GatewayPluginConfig, + com.google.cloud.apihub.v1.GatewayPluginConfig.Builder, + com.google.cloud.apihub.v1.GatewayPluginConfigOrBuilder> + gatewayPluginConfigsBuilder_; + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List + getGatewayPluginConfigsList() { + if (gatewayPluginConfigsBuilder_ == null) { + return java.util.Collections.unmodifiableList(gatewayPluginConfigs_); + } else { + return gatewayPluginConfigsBuilder_.getMessageList(); + } + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public int getGatewayPluginConfigsCount() { + if (gatewayPluginConfigsBuilder_ == null) { + return gatewayPluginConfigs_.size(); + } else { + return gatewayPluginConfigsBuilder_.getCount(); + } + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.GatewayPluginConfig getGatewayPluginConfigs(int index) { + if (gatewayPluginConfigsBuilder_ == null) { + return gatewayPluginConfigs_.get(index); + } else { + return gatewayPluginConfigsBuilder_.getMessage(index); + } + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGatewayPluginConfigs( + int index, com.google.cloud.apihub.v1.GatewayPluginConfig value) { + if (gatewayPluginConfigsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureGatewayPluginConfigsIsMutable(); + gatewayPluginConfigs_.set(index, value); + onChanged(); + } else { + gatewayPluginConfigsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGatewayPluginConfigs( + int index, com.google.cloud.apihub.v1.GatewayPluginConfig.Builder builderForValue) { + if (gatewayPluginConfigsBuilder_ == null) { + ensureGatewayPluginConfigsIsMutable(); + gatewayPluginConfigs_.set(index, builderForValue.build()); + onChanged(); + } else { + gatewayPluginConfigsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addGatewayPluginConfigs(com.google.cloud.apihub.v1.GatewayPluginConfig value) { + if (gatewayPluginConfigsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureGatewayPluginConfigsIsMutable(); + gatewayPluginConfigs_.add(value); + onChanged(); + } else { + gatewayPluginConfigsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addGatewayPluginConfigs( + int index, com.google.cloud.apihub.v1.GatewayPluginConfig value) { + if (gatewayPluginConfigsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureGatewayPluginConfigsIsMutable(); + gatewayPluginConfigs_.add(index, value); + onChanged(); + } else { + gatewayPluginConfigsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addGatewayPluginConfigs( + com.google.cloud.apihub.v1.GatewayPluginConfig.Builder builderForValue) { + if (gatewayPluginConfigsBuilder_ == null) { + ensureGatewayPluginConfigsIsMutable(); + gatewayPluginConfigs_.add(builderForValue.build()); + onChanged(); + } else { + gatewayPluginConfigsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addGatewayPluginConfigs( + int index, com.google.cloud.apihub.v1.GatewayPluginConfig.Builder builderForValue) { + if (gatewayPluginConfigsBuilder_ == null) { + ensureGatewayPluginConfigsIsMutable(); + gatewayPluginConfigs_.add(index, builderForValue.build()); + onChanged(); + } else { + gatewayPluginConfigsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addAllGatewayPluginConfigs( + java.lang.Iterable values) { + if (gatewayPluginConfigsBuilder_ == null) { + ensureGatewayPluginConfigsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, gatewayPluginConfigs_); + onChanged(); + } else { + gatewayPluginConfigsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearGatewayPluginConfigs() { + if (gatewayPluginConfigsBuilder_ == null) { + gatewayPluginConfigs_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + gatewayPluginConfigsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder removeGatewayPluginConfigs(int index) { + if (gatewayPluginConfigsBuilder_ == null) { + ensureGatewayPluginConfigsIsMutable(); + gatewayPluginConfigs_.remove(index); + onChanged(); + } else { + gatewayPluginConfigsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.GatewayPluginConfig.Builder getGatewayPluginConfigsBuilder( + int index) { + return internalGetGatewayPluginConfigsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.GatewayPluginConfigOrBuilder getGatewayPluginConfigsOrBuilder( + int index) { + if (gatewayPluginConfigsBuilder_ == null) { + return gatewayPluginConfigs_.get(index); + } else { + return gatewayPluginConfigsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List + getGatewayPluginConfigsOrBuilderList() { + if (gatewayPluginConfigsBuilder_ != null) { + return gatewayPluginConfigsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(gatewayPluginConfigs_); + } + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.GatewayPluginConfig.Builder addGatewayPluginConfigsBuilder() { + return internalGetGatewayPluginConfigsFieldBuilder() + .addBuilder(com.google.cloud.apihub.v1.GatewayPluginConfig.getDefaultInstance()); + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.GatewayPluginConfig.Builder addGatewayPluginConfigsBuilder( + int index) { + return internalGetGatewayPluginConfigsFieldBuilder() + .addBuilder(index, com.google.cloud.apihub.v1.GatewayPluginConfig.getDefaultInstance()); + } + + /** + * + * + *
                      +     * Required. The list of gateway plugin configs for which the addon is
                      +     * enabled. Each gateway plugin config should have a unique plugin instance.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List + getGatewayPluginConfigsBuilderList() { + return internalGetGatewayPluginConfigsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.GatewayPluginConfig, + com.google.cloud.apihub.v1.GatewayPluginConfig.Builder, + com.google.cloud.apihub.v1.GatewayPluginConfigOrBuilder> + internalGetGatewayPluginConfigsFieldBuilder() { + if (gatewayPluginConfigsBuilder_ == null) { + gatewayPluginConfigsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.GatewayPluginConfig, + com.google.cloud.apihub.v1.GatewayPluginConfig.Builder, + com.google.cloud.apihub.v1.GatewayPluginConfigOrBuilder>( + gatewayPluginConfigs_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + gatewayPluginConfigs_ = null; + } + return gatewayPluginConfigsBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.GatewayPluginAddonConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.GatewayPluginAddonConfig) + private static final com.google.cloud.apihub.v1.GatewayPluginAddonConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.GatewayPluginAddonConfig(); + } + + public static com.google.cloud.apihub.v1.GatewayPluginAddonConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GatewayPluginAddonConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginAddonConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginAddonConfigOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginAddonConfigOrBuilder.java new file mode 100644 index 000000000000..f286bfa5556c --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginAddonConfigOrBuilder.java @@ -0,0 +1,100 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface GatewayPluginAddonConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.GatewayPluginAddonConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The list of gateway plugin configs for which the addon is
                      +   * enabled. Each gateway plugin config should have a unique plugin instance.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + java.util.List getGatewayPluginConfigsList(); + + /** + * + * + *
                      +   * Required. The list of gateway plugin configs for which the addon is
                      +   * enabled. Each gateway plugin config should have a unique plugin instance.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.apihub.v1.GatewayPluginConfig getGatewayPluginConfigs(int index); + + /** + * + * + *
                      +   * Required. The list of gateway plugin configs for which the addon is
                      +   * enabled. Each gateway plugin config should have a unique plugin instance.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + int getGatewayPluginConfigsCount(); + + /** + * + * + *
                      +   * Required. The list of gateway plugin configs for which the addon is
                      +   * enabled. Each gateway plugin config should have a unique plugin instance.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + java.util.List + getGatewayPluginConfigsOrBuilderList(); + + /** + * + * + *
                      +   * Required. The list of gateway plugin configs for which the addon is
                      +   * enabled. Each gateway plugin config should have a unique plugin instance.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.GatewayPluginConfig gateway_plugin_configs = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.apihub.v1.GatewayPluginConfigOrBuilder getGatewayPluginConfigsOrBuilder( + int index); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginConfig.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginConfig.java new file mode 100644 index 000000000000..c6d7392635bb --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginConfig.java @@ -0,0 +1,1617 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Configuration for a gateway plugin.
                      + * This is used to specify configs for different gateways.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.GatewayPluginConfig} + */ +@com.google.protobuf.Generated +public final class GatewayPluginConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.GatewayPluginConfig) + GatewayPluginConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GatewayPluginConfig"); + } + + // Use GatewayPluginConfig.newBuilder() to construct. + private GatewayPluginConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GatewayPluginConfig() { + pluginInstance_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GatewayPluginConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GatewayPluginConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.GatewayPluginConfig.class, + com.google.cloud.apihub.v1.GatewayPluginConfig.Builder.class); + } + + private int configCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object config_; + + public enum ConfigCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + APIGEE_X_HYBRID_CONFIG(2), + APIGEE_EDGE_CONFIG(3), + APIGEE_OPDK_CONFIG(4), + CONFIG_NOT_SET(0); + private final int value; + + private ConfigCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ConfigCase valueOf(int value) { + return forNumber(value); + } + + public static ConfigCase forNumber(int value) { + switch (value) { + case 2: + return APIGEE_X_HYBRID_CONFIG; + case 3: + return APIGEE_EDGE_CONFIG; + case 4: + return APIGEE_OPDK_CONFIG; + case 0: + return CONFIG_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ConfigCase getConfigCase() { + return ConfigCase.forNumber(configCase_); + } + + public static final int APIGEE_X_HYBRID_CONFIG_FIELD_NUMBER = 2; + + /** + * + * + *
                      +   * Configuration for Apigee X and Apigee Hybrid gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + * + * @return Whether the apigeeXHybridConfig field is set. + */ + @java.lang.Override + public boolean hasApigeeXHybridConfig() { + return configCase_ == 2; + } + + /** + * + * + *
                      +   * Configuration for Apigee X and Apigee Hybrid gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + * + * @return The apigeeXHybridConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXHybridConfig getApigeeXHybridConfig() { + if (configCase_ == 2) { + return (com.google.cloud.apihub.v1.ApigeeXHybridConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeXHybridConfig.getDefaultInstance(); + } + + /** + * + * + *
                      +   * Configuration for Apigee X and Apigee Hybrid gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXHybridConfigOrBuilder getApigeeXHybridConfigOrBuilder() { + if (configCase_ == 2) { + return (com.google.cloud.apihub.v1.ApigeeXHybridConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeXHybridConfig.getDefaultInstance(); + } + + public static final int APIGEE_EDGE_CONFIG_FIELD_NUMBER = 3; + + /** + * + * + *
                      +   * Configuration for Apigee Edge gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + * + * @return Whether the apigeeEdgeConfig field is set. + */ + @java.lang.Override + public boolean hasApigeeEdgeConfig() { + return configCase_ == 3; + } + + /** + * + * + *
                      +   * Configuration for Apigee Edge gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + * + * @return The apigeeEdgeConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeEdgeConfig getApigeeEdgeConfig() { + if (configCase_ == 3) { + return (com.google.cloud.apihub.v1.ApigeeEdgeConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeEdgeConfig.getDefaultInstance(); + } + + /** + * + * + *
                      +   * Configuration for Apigee Edge gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeEdgeConfigOrBuilder getApigeeEdgeConfigOrBuilder() { + if (configCase_ == 3) { + return (com.google.cloud.apihub.v1.ApigeeEdgeConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeEdgeConfig.getDefaultInstance(); + } + + public static final int APIGEE_OPDK_CONFIG_FIELD_NUMBER = 4; + + /** + * + * + *
                      +   * Configuration for Apigee OPDK gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + * + * @return Whether the apigeeOpdkConfig field is set. + */ + @java.lang.Override + public boolean hasApigeeOpdkConfig() { + return configCase_ == 4; + } + + /** + * + * + *
                      +   * Configuration for Apigee OPDK gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + * + * @return The apigeeOpdkConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeOPDKConfig getApigeeOpdkConfig() { + if (configCase_ == 4) { + return (com.google.cloud.apihub.v1.ApigeeOPDKConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeOPDKConfig.getDefaultInstance(); + } + + /** + * + * + *
                      +   * Configuration for Apigee OPDK gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeOPDKConfigOrBuilder getApigeeOpdkConfigOrBuilder() { + if (configCase_ == 4) { + return (com.google.cloud.apihub.v1.ApigeeOPDKConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeOPDKConfig.getDefaultInstance(); + } + + public static final int PLUGIN_INSTANCE_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object pluginInstance_ = ""; + + /** + * + * + *
                      +   * Required. The name of the gateway plugin instance for which the config is
                      +   * to be specified. Format:
                      +   * projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}
                      +   * 
                      + * + * string plugin_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The pluginInstance. + */ + @java.lang.Override + public java.lang.String getPluginInstance() { + java.lang.Object ref = pluginInstance_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pluginInstance_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The name of the gateway plugin instance for which the config is
                      +   * to be specified. Format:
                      +   * projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}
                      +   * 
                      + * + * string plugin_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for pluginInstance. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPluginInstanceBytes() { + java.lang.Object ref = pluginInstance_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pluginInstance_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pluginInstance_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, pluginInstance_); + } + if (configCase_ == 2) { + output.writeMessage(2, (com.google.cloud.apihub.v1.ApigeeXHybridConfig) config_); + } + if (configCase_ == 3) { + output.writeMessage(3, (com.google.cloud.apihub.v1.ApigeeEdgeConfig) config_); + } + if (configCase_ == 4) { + output.writeMessage(4, (com.google.cloud.apihub.v1.ApigeeOPDKConfig) config_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pluginInstance_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, pluginInstance_); + } + if (configCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.apihub.v1.ApigeeXHybridConfig) config_); + } + if (configCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.cloud.apihub.v1.ApigeeEdgeConfig) config_); + } + if (configCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.cloud.apihub.v1.ApigeeOPDKConfig) config_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.GatewayPluginConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.GatewayPluginConfig other = + (com.google.cloud.apihub.v1.GatewayPluginConfig) obj; + + if (!getPluginInstance().equals(other.getPluginInstance())) return false; + if (!getConfigCase().equals(other.getConfigCase())) return false; + switch (configCase_) { + case 2: + if (!getApigeeXHybridConfig().equals(other.getApigeeXHybridConfig())) return false; + break; + case 3: + if (!getApigeeEdgeConfig().equals(other.getApigeeEdgeConfig())) return false; + break; + case 4: + if (!getApigeeOpdkConfig().equals(other.getApigeeOpdkConfig())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PLUGIN_INSTANCE_FIELD_NUMBER; + hash = (53 * hash) + getPluginInstance().hashCode(); + switch (configCase_) { + case 2: + hash = (37 * hash) + APIGEE_X_HYBRID_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getApigeeXHybridConfig().hashCode(); + break; + case 3: + hash = (37 * hash) + APIGEE_EDGE_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getApigeeEdgeConfig().hashCode(); + break; + case 4: + hash = (37 * hash) + APIGEE_OPDK_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getApigeeOpdkConfig().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.GatewayPluginConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Configuration for a gateway plugin.
                      +   * This is used to specify configs for different gateways.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.GatewayPluginConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.GatewayPluginConfig) + com.google.cloud.apihub.v1.GatewayPluginConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GatewayPluginConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GatewayPluginConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.GatewayPluginConfig.class, + com.google.cloud.apihub.v1.GatewayPluginConfig.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.GatewayPluginConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (apigeeXHybridConfigBuilder_ != null) { + apigeeXHybridConfigBuilder_.clear(); + } + if (apigeeEdgeConfigBuilder_ != null) { + apigeeEdgeConfigBuilder_.clear(); + } + if (apigeeOpdkConfigBuilder_ != null) { + apigeeOpdkConfigBuilder_.clear(); + } + pluginInstance_ = ""; + configCase_ = 0; + config_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GatewayPluginConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginConfig getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.GatewayPluginConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginConfig build() { + com.google.cloud.apihub.v1.GatewayPluginConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginConfig buildPartial() { + com.google.cloud.apihub.v1.GatewayPluginConfig result = + new com.google.cloud.apihub.v1.GatewayPluginConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.GatewayPluginConfig result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000008) != 0)) { + result.pluginInstance_ = pluginInstance_; + } + } + + private void buildPartialOneofs(com.google.cloud.apihub.v1.GatewayPluginConfig result) { + result.configCase_ = configCase_; + result.config_ = this.config_; + if (configCase_ == 2 && apigeeXHybridConfigBuilder_ != null) { + result.config_ = apigeeXHybridConfigBuilder_.build(); + } + if (configCase_ == 3 && apigeeEdgeConfigBuilder_ != null) { + result.config_ = apigeeEdgeConfigBuilder_.build(); + } + if (configCase_ == 4 && apigeeOpdkConfigBuilder_ != null) { + result.config_ = apigeeOpdkConfigBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.GatewayPluginConfig) { + return mergeFrom((com.google.cloud.apihub.v1.GatewayPluginConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.GatewayPluginConfig other) { + if (other == com.google.cloud.apihub.v1.GatewayPluginConfig.getDefaultInstance()) return this; + if (!other.getPluginInstance().isEmpty()) { + pluginInstance_ = other.pluginInstance_; + bitField0_ |= 0x00000008; + onChanged(); + } + switch (other.getConfigCase()) { + case APIGEE_X_HYBRID_CONFIG: + { + mergeApigeeXHybridConfig(other.getApigeeXHybridConfig()); + break; + } + case APIGEE_EDGE_CONFIG: + { + mergeApigeeEdgeConfig(other.getApigeeEdgeConfig()); + break; + } + case APIGEE_OPDK_CONFIG: + { + mergeApigeeOpdkConfig(other.getApigeeOpdkConfig()); + break; + } + case CONFIG_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + pluginInstance_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetApigeeXHybridConfigFieldBuilder().getBuilder(), extensionRegistry); + configCase_ = 2; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetApigeeEdgeConfigFieldBuilder().getBuilder(), extensionRegistry); + configCase_ = 3; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetApigeeOpdkConfigFieldBuilder().getBuilder(), extensionRegistry); + configCase_ = 4; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int configCase_ = 0; + private java.lang.Object config_; + + public ConfigCase getConfigCase() { + return ConfigCase.forNumber(configCase_); + } + + public Builder clearConfig() { + configCase_ = 0; + config_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXHybridConfig, + com.google.cloud.apihub.v1.ApigeeXHybridConfig.Builder, + com.google.cloud.apihub.v1.ApigeeXHybridConfigOrBuilder> + apigeeXHybridConfigBuilder_; + + /** + * + * + *
                      +     * Configuration for Apigee X and Apigee Hybrid gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + * + * @return Whether the apigeeXHybridConfig field is set. + */ + @java.lang.Override + public boolean hasApigeeXHybridConfig() { + return configCase_ == 2; + } + + /** + * + * + *
                      +     * Configuration for Apigee X and Apigee Hybrid gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + * + * @return The apigeeXHybridConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXHybridConfig getApigeeXHybridConfig() { + if (apigeeXHybridConfigBuilder_ == null) { + if (configCase_ == 2) { + return (com.google.cloud.apihub.v1.ApigeeXHybridConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeXHybridConfig.getDefaultInstance(); + } else { + if (configCase_ == 2) { + return apigeeXHybridConfigBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.ApigeeXHybridConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Configuration for Apigee X and Apigee Hybrid gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + */ + public Builder setApigeeXHybridConfig(com.google.cloud.apihub.v1.ApigeeXHybridConfig value) { + if (apigeeXHybridConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + apigeeXHybridConfigBuilder_.setMessage(value); + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee X and Apigee Hybrid gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + */ + public Builder setApigeeXHybridConfig( + com.google.cloud.apihub.v1.ApigeeXHybridConfig.Builder builderForValue) { + if (apigeeXHybridConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + apigeeXHybridConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee X and Apigee Hybrid gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + */ + public Builder mergeApigeeXHybridConfig(com.google.cloud.apihub.v1.ApigeeXHybridConfig value) { + if (apigeeXHybridConfigBuilder_ == null) { + if (configCase_ == 2 + && config_ != com.google.cloud.apihub.v1.ApigeeXHybridConfig.getDefaultInstance()) { + config_ = + com.google.cloud.apihub.v1.ApigeeXHybridConfig.newBuilder( + (com.google.cloud.apihub.v1.ApigeeXHybridConfig) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 2) { + apigeeXHybridConfigBuilder_.mergeFrom(value); + } else { + apigeeXHybridConfigBuilder_.setMessage(value); + } + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee X and Apigee Hybrid gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + */ + public Builder clearApigeeXHybridConfig() { + if (apigeeXHybridConfigBuilder_ == null) { + if (configCase_ == 2) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 2) { + configCase_ = 0; + config_ = null; + } + apigeeXHybridConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee X and Apigee Hybrid gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + */ + public com.google.cloud.apihub.v1.ApigeeXHybridConfig.Builder getApigeeXHybridConfigBuilder() { + return internalGetApigeeXHybridConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Configuration for Apigee X and Apigee Hybrid gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXHybridConfigOrBuilder + getApigeeXHybridConfigOrBuilder() { + if ((configCase_ == 2) && (apigeeXHybridConfigBuilder_ != null)) { + return apigeeXHybridConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 2) { + return (com.google.cloud.apihub.v1.ApigeeXHybridConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeXHybridConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Configuration for Apigee X and Apigee Hybrid gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXHybridConfig, + com.google.cloud.apihub.v1.ApigeeXHybridConfig.Builder, + com.google.cloud.apihub.v1.ApigeeXHybridConfigOrBuilder> + internalGetApigeeXHybridConfigFieldBuilder() { + if (apigeeXHybridConfigBuilder_ == null) { + if (!(configCase_ == 2)) { + config_ = com.google.cloud.apihub.v1.ApigeeXHybridConfig.getDefaultInstance(); + } + apigeeXHybridConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXHybridConfig, + com.google.cloud.apihub.v1.ApigeeXHybridConfig.Builder, + com.google.cloud.apihub.v1.ApigeeXHybridConfigOrBuilder>( + (com.google.cloud.apihub.v1.ApigeeXHybridConfig) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 2; + onChanged(); + return apigeeXHybridConfigBuilder_; + } + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeEdgeConfig, + com.google.cloud.apihub.v1.ApigeeEdgeConfig.Builder, + com.google.cloud.apihub.v1.ApigeeEdgeConfigOrBuilder> + apigeeEdgeConfigBuilder_; + + /** + * + * + *
                      +     * Configuration for Apigee Edge gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + * + * @return Whether the apigeeEdgeConfig field is set. + */ + @java.lang.Override + public boolean hasApigeeEdgeConfig() { + return configCase_ == 3; + } + + /** + * + * + *
                      +     * Configuration for Apigee Edge gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + * + * @return The apigeeEdgeConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeEdgeConfig getApigeeEdgeConfig() { + if (apigeeEdgeConfigBuilder_ == null) { + if (configCase_ == 3) { + return (com.google.cloud.apihub.v1.ApigeeEdgeConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeEdgeConfig.getDefaultInstance(); + } else { + if (configCase_ == 3) { + return apigeeEdgeConfigBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.ApigeeEdgeConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Configuration for Apigee Edge gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + */ + public Builder setApigeeEdgeConfig(com.google.cloud.apihub.v1.ApigeeEdgeConfig value) { + if (apigeeEdgeConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + apigeeEdgeConfigBuilder_.setMessage(value); + } + configCase_ = 3; + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee Edge gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + */ + public Builder setApigeeEdgeConfig( + com.google.cloud.apihub.v1.ApigeeEdgeConfig.Builder builderForValue) { + if (apigeeEdgeConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + apigeeEdgeConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 3; + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee Edge gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + */ + public Builder mergeApigeeEdgeConfig(com.google.cloud.apihub.v1.ApigeeEdgeConfig value) { + if (apigeeEdgeConfigBuilder_ == null) { + if (configCase_ == 3 + && config_ != com.google.cloud.apihub.v1.ApigeeEdgeConfig.getDefaultInstance()) { + config_ = + com.google.cloud.apihub.v1.ApigeeEdgeConfig.newBuilder( + (com.google.cloud.apihub.v1.ApigeeEdgeConfig) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 3) { + apigeeEdgeConfigBuilder_.mergeFrom(value); + } else { + apigeeEdgeConfigBuilder_.setMessage(value); + } + } + configCase_ = 3; + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee Edge gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + */ + public Builder clearApigeeEdgeConfig() { + if (apigeeEdgeConfigBuilder_ == null) { + if (configCase_ == 3) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 3) { + configCase_ = 0; + config_ = null; + } + apigeeEdgeConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee Edge gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + */ + public com.google.cloud.apihub.v1.ApigeeEdgeConfig.Builder getApigeeEdgeConfigBuilder() { + return internalGetApigeeEdgeConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Configuration for Apigee Edge gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeEdgeConfigOrBuilder getApigeeEdgeConfigOrBuilder() { + if ((configCase_ == 3) && (apigeeEdgeConfigBuilder_ != null)) { + return apigeeEdgeConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 3) { + return (com.google.cloud.apihub.v1.ApigeeEdgeConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeEdgeConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Configuration for Apigee Edge gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeEdgeConfig, + com.google.cloud.apihub.v1.ApigeeEdgeConfig.Builder, + com.google.cloud.apihub.v1.ApigeeEdgeConfigOrBuilder> + internalGetApigeeEdgeConfigFieldBuilder() { + if (apigeeEdgeConfigBuilder_ == null) { + if (!(configCase_ == 3)) { + config_ = com.google.cloud.apihub.v1.ApigeeEdgeConfig.getDefaultInstance(); + } + apigeeEdgeConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeEdgeConfig, + com.google.cloud.apihub.v1.ApigeeEdgeConfig.Builder, + com.google.cloud.apihub.v1.ApigeeEdgeConfigOrBuilder>( + (com.google.cloud.apihub.v1.ApigeeEdgeConfig) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 3; + onChanged(); + return apigeeEdgeConfigBuilder_; + } + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeOPDKConfig, + com.google.cloud.apihub.v1.ApigeeOPDKConfig.Builder, + com.google.cloud.apihub.v1.ApigeeOPDKConfigOrBuilder> + apigeeOpdkConfigBuilder_; + + /** + * + * + *
                      +     * Configuration for Apigee OPDK gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + * + * @return Whether the apigeeOpdkConfig field is set. + */ + @java.lang.Override + public boolean hasApigeeOpdkConfig() { + return configCase_ == 4; + } + + /** + * + * + *
                      +     * Configuration for Apigee OPDK gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + * + * @return The apigeeOpdkConfig. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeOPDKConfig getApigeeOpdkConfig() { + if (apigeeOpdkConfigBuilder_ == null) { + if (configCase_ == 4) { + return (com.google.cloud.apihub.v1.ApigeeOPDKConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeOPDKConfig.getDefaultInstance(); + } else { + if (configCase_ == 4) { + return apigeeOpdkConfigBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.ApigeeOPDKConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Configuration for Apigee OPDK gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + */ + public Builder setApigeeOpdkConfig(com.google.cloud.apihub.v1.ApigeeOPDKConfig value) { + if (apigeeOpdkConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + apigeeOpdkConfigBuilder_.setMessage(value); + } + configCase_ = 4; + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee OPDK gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + */ + public Builder setApigeeOpdkConfig( + com.google.cloud.apihub.v1.ApigeeOPDKConfig.Builder builderForValue) { + if (apigeeOpdkConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + apigeeOpdkConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 4; + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee OPDK gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + */ + public Builder mergeApigeeOpdkConfig(com.google.cloud.apihub.v1.ApigeeOPDKConfig value) { + if (apigeeOpdkConfigBuilder_ == null) { + if (configCase_ == 4 + && config_ != com.google.cloud.apihub.v1.ApigeeOPDKConfig.getDefaultInstance()) { + config_ = + com.google.cloud.apihub.v1.ApigeeOPDKConfig.newBuilder( + (com.google.cloud.apihub.v1.ApigeeOPDKConfig) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 4) { + apigeeOpdkConfigBuilder_.mergeFrom(value); + } else { + apigeeOpdkConfigBuilder_.setMessage(value); + } + } + configCase_ = 4; + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee OPDK gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + */ + public Builder clearApigeeOpdkConfig() { + if (apigeeOpdkConfigBuilder_ == null) { + if (configCase_ == 4) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 4) { + configCase_ = 0; + config_ = null; + } + apigeeOpdkConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Configuration for Apigee OPDK gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + */ + public com.google.cloud.apihub.v1.ApigeeOPDKConfig.Builder getApigeeOpdkConfigBuilder() { + return internalGetApigeeOpdkConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Configuration for Apigee OPDK gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeOPDKConfigOrBuilder getApigeeOpdkConfigOrBuilder() { + if ((configCase_ == 4) && (apigeeOpdkConfigBuilder_ != null)) { + return apigeeOpdkConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 4) { + return (com.google.cloud.apihub.v1.ApigeeOPDKConfig) config_; + } + return com.google.cloud.apihub.v1.ApigeeOPDKConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Configuration for Apigee OPDK gateways.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeOPDKConfig, + com.google.cloud.apihub.v1.ApigeeOPDKConfig.Builder, + com.google.cloud.apihub.v1.ApigeeOPDKConfigOrBuilder> + internalGetApigeeOpdkConfigFieldBuilder() { + if (apigeeOpdkConfigBuilder_ == null) { + if (!(configCase_ == 4)) { + config_ = com.google.cloud.apihub.v1.ApigeeOPDKConfig.getDefaultInstance(); + } + apigeeOpdkConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeOPDKConfig, + com.google.cloud.apihub.v1.ApigeeOPDKConfig.Builder, + com.google.cloud.apihub.v1.ApigeeOPDKConfigOrBuilder>( + (com.google.cloud.apihub.v1.ApigeeOPDKConfig) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 4; + onChanged(); + return apigeeOpdkConfigBuilder_; + } + + private java.lang.Object pluginInstance_ = ""; + + /** + * + * + *
                      +     * Required. The name of the gateway plugin instance for which the config is
                      +     * to be specified. Format:
                      +     * projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}
                      +     * 
                      + * + * string plugin_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The pluginInstance. + */ + public java.lang.String getPluginInstance() { + java.lang.Object ref = pluginInstance_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pluginInstance_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the gateway plugin instance for which the config is
                      +     * to be specified. Format:
                      +     * projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}
                      +     * 
                      + * + * string plugin_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for pluginInstance. + */ + public com.google.protobuf.ByteString getPluginInstanceBytes() { + java.lang.Object ref = pluginInstance_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pluginInstance_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the gateway plugin instance for which the config is
                      +     * to be specified. Format:
                      +     * projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}
                      +     * 
                      + * + * string plugin_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The pluginInstance to set. + * @return This builder for chaining. + */ + public Builder setPluginInstance(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pluginInstance_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the gateway plugin instance for which the config is
                      +     * to be specified. Format:
                      +     * projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}
                      +     * 
                      + * + * string plugin_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearPluginInstance() { + pluginInstance_ = getDefaultInstance().getPluginInstance(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the gateway plugin instance for which the config is
                      +     * to be specified. Format:
                      +     * projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}
                      +     * 
                      + * + * string plugin_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for pluginInstance to set. + * @return This builder for chaining. + */ + public Builder setPluginInstanceBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pluginInstance_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.GatewayPluginConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.GatewayPluginConfig) + private static final com.google.cloud.apihub.v1.GatewayPluginConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.GatewayPluginConfig(); + } + + public static com.google.cloud.apihub.v1.GatewayPluginConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GatewayPluginConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GatewayPluginConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginConfigOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginConfigOrBuilder.java new file mode 100644 index 000000000000..2ee9abf22983 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayPluginConfigOrBuilder.java @@ -0,0 +1,171 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface GatewayPluginConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.GatewayPluginConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Configuration for Apigee X and Apigee Hybrid gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + * + * @return Whether the apigeeXHybridConfig field is set. + */ + boolean hasApigeeXHybridConfig(); + + /** + * + * + *
                      +   * Configuration for Apigee X and Apigee Hybrid gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + * + * @return The apigeeXHybridConfig. + */ + com.google.cloud.apihub.v1.ApigeeXHybridConfig getApigeeXHybridConfig(); + + /** + * + * + *
                      +   * Configuration for Apigee X and Apigee Hybrid gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXHybridConfig apigee_x_hybrid_config = 2; + */ + com.google.cloud.apihub.v1.ApigeeXHybridConfigOrBuilder getApigeeXHybridConfigOrBuilder(); + + /** + * + * + *
                      +   * Configuration for Apigee Edge gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + * + * @return Whether the apigeeEdgeConfig field is set. + */ + boolean hasApigeeEdgeConfig(); + + /** + * + * + *
                      +   * Configuration for Apigee Edge gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + * + * @return The apigeeEdgeConfig. + */ + com.google.cloud.apihub.v1.ApigeeEdgeConfig getApigeeEdgeConfig(); + + /** + * + * + *
                      +   * Configuration for Apigee Edge gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeEdgeConfig apigee_edge_config = 3; + */ + com.google.cloud.apihub.v1.ApigeeEdgeConfigOrBuilder getApigeeEdgeConfigOrBuilder(); + + /** + * + * + *
                      +   * Configuration for Apigee OPDK gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + * + * @return Whether the apigeeOpdkConfig field is set. + */ + boolean hasApigeeOpdkConfig(); + + /** + * + * + *
                      +   * Configuration for Apigee OPDK gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + * + * @return The apigeeOpdkConfig. + */ + com.google.cloud.apihub.v1.ApigeeOPDKConfig getApigeeOpdkConfig(); + + /** + * + * + *
                      +   * Configuration for Apigee OPDK gateways.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeOPDKConfig apigee_opdk_config = 4; + */ + com.google.cloud.apihub.v1.ApigeeOPDKConfigOrBuilder getApigeeOpdkConfigOrBuilder(); + + /** + * + * + *
                      +   * Required. The name of the gateway plugin instance for which the config is
                      +   * to be specified. Format:
                      +   * projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}
                      +   * 
                      + * + * string plugin_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The pluginInstance. + */ + java.lang.String getPluginInstance(); + + /** + * + * + *
                      +   * Required. The name of the gateway plugin instance for which the config is
                      +   * to be specified. Format:
                      +   * projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}
                      +   * 
                      + * + * string plugin_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for pluginInstance. + */ + com.google.protobuf.ByteString getPluginInstanceBytes(); + + com.google.cloud.apihub.v1.GatewayPluginConfig.ConfigCase getConfigCase(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayType.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayType.java index cb37e7848a83..b5d0d5abf15a 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayType.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GatewayType.java @@ -111,6 +111,26 @@ public enum GatewayType implements com.google.protobuf.ProtocolMessageEnum { * OTHERS = 7; */ OTHERS(7), + /** + * + * + *
                      +   * The gateway type is AWS API Gateway.
                      +   * 
                      + * + * AWS_API_GATEWAY = 8; + */ + AWS_API_GATEWAY(8), + /** + * + * + *
                      +   * The gateway type is Azure API Management.
                      +   * 
                      + * + * AZURE_API_MANAGEMENT = 9; + */ + AZURE_API_MANAGEMENT(9), UNRECOGNIZED(-1), ; @@ -212,6 +232,28 @@ public enum GatewayType implements com.google.protobuf.ProtocolMessageEnum { */ public static final int OTHERS_VALUE = 7; + /** + * + * + *
                      +   * The gateway type is AWS API Gateway.
                      +   * 
                      + * + * AWS_API_GATEWAY = 8; + */ + public static final int AWS_API_GATEWAY_VALUE = 8; + + /** + * + * + *
                      +   * The gateway type is Azure API Management.
                      +   * 
                      + * + * AZURE_API_MANAGEMENT = 9; + */ + public static final int AZURE_API_MANAGEMENT_VALUE = 9; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -252,6 +294,10 @@ public static GatewayType forNumber(int value) { return API_DISCOVERY; case 7: return OTHERS; + case 8: + return AWS_API_GATEWAY; + case 9: + return AZURE_API_MANAGEMENT; default: return null; } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GetAddonRequest.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GetAddonRequest.java new file mode 100644 index 000000000000..9b70647ed696 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GetAddonRequest.java @@ -0,0 +1,616 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The [GetAddon][google.cloud.apihub.v1.ApiHubAddon.GetAddon] method's request.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.GetAddonRequest} + */ +@com.google.protobuf.Generated +public final class GetAddonRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.GetAddonRequest) + GetAddonRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetAddonRequest"); + } + + // Use GetAddonRequest.newBuilder() to construct. + private GetAddonRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetAddonRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GetAddonRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GetAddonRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.GetAddonRequest.class, + com.google.cloud.apihub.v1.GetAddonRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
                      +   * Required. The name of the addon to get.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The name of the addon to get.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.GetAddonRequest)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.GetAddonRequest other = + (com.google.cloud.apihub.v1.GetAddonRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.GetAddonRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The [GetAddon][google.cloud.apihub.v1.ApiHubAddon.GetAddon] method's request.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.GetAddonRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.GetAddonRequest) + com.google.cloud.apihub.v1.GetAddonRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GetAddonRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GetAddonRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.GetAddonRequest.class, + com.google.cloud.apihub.v1.GetAddonRequest.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.GetAddonRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_GetAddonRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GetAddonRequest getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.GetAddonRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GetAddonRequest build() { + com.google.cloud.apihub.v1.GetAddonRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GetAddonRequest buildPartial() { + com.google.cloud.apihub.v1.GetAddonRequest result = + new com.google.cloud.apihub.v1.GetAddonRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.GetAddonRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.GetAddonRequest) { + return mergeFrom((com.google.cloud.apihub.v1.GetAddonRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.GetAddonRequest other) { + if (other == com.google.cloud.apihub.v1.GetAddonRequest.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
                      +     * Required. The name of the addon to get.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the addon to get.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the addon to get.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the addon to get.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the addon to get.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.GetAddonRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.GetAddonRequest) + private static final com.google.cloud.apihub.v1.GetAddonRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.GetAddonRequest(); + } + + public static com.google.cloud.apihub.v1.GetAddonRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetAddonRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.GetAddonRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GetAddonRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GetAddonRequestOrBuilder.java new file mode 100644 index 000000000000..20892761f4b1 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/GetAddonRequestOrBuilder.java @@ -0,0 +1,60 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface GetAddonRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.GetAddonRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The name of the addon to get.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
                      +   * Required. The name of the addon to get.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/HostProjectRegistrationServiceProto.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/HostProjectRegistrationServiceProto.java index 9be4e6c1b7f6..ded84333a56f 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/HostProjectRegistrationServiceProto.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/HostProjectRegistrationServiceProto.java @@ -102,7 +102,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003:\304\001\352A\300\001\n" + "-apihub.googleapis.com/HostProjectRegistration\022\\projects/{proje" + "ct}/locations/{location}/hostProjectRegistrations/{host_project_registration}*\030h" - + "ostProjectRegistrations2\027hostProjectRegistration2\341\006\n" + + "ostProjectRegistrations2\027hostProjectRegistration2\304\007\n" + "\036HostProjectRegistrationService\022\260\002\n" + "\035CreateHostProjectRegistration\022<.google.cloud.apihub.v1.CreateHostProject" + "RegistrationRequest\032/.google.cloud.apihu" @@ -118,11 +118,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "RegistrationsRequest\032<.google.cloud.apihub.v1.ListHostProjectRegistrationsRespon" + "se\"M\332A\006parent\202\323\344\223\002>\022 + * The [ListAddons][google.cloud.apihub.v1.ApiHubAddon.ListAddons] method's + * request. + *
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ListAddonsRequest} + */ +@com.google.protobuf.Generated +public final class ListAddonsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ListAddonsRequest) + ListAddonsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAddonsRequest"); + } + + // Use ListAddonsRequest.newBuilder() to construct. + private ListAddonsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAddonsRequest() { + parent_ = ""; + filter_ = ""; + pageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ListAddonsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ListAddonsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ListAddonsRequest.class, + com.google.cloud.apihub.v1.ListAddonsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
                      +   * Required. The parent resource where this addon will be created.
                      +   * Format: `projects/{project}/locations/{location}`.
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The parent resource where this addon will be created.
                      +   * Format: `projects/{project}/locations/{location}`.
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object filter_ = ""; + + /** + * + * + *
                      +   * Optional. An expression that filters the list of addons.
                      +   * The only supported filter is `plugin_instance_name`. It can be used to
                      +   * filter addons that are enabled for a given plugin instance.
                      +   * The format of the filter is `plugin_instance_name =
                      +   * "projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}"`.
                      +   * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Optional. An expression that filters the list of addons.
                      +   * The only supported filter is `plugin_instance_name`. It can be used to
                      +   * filter addons that are enabled for a given plugin instance.
                      +   * The format of the filter is `plugin_instance_name =
                      +   * "projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}"`.
                      +   * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 3; + private int pageSize_ = 0; + + /** + * + * + *
                      +   * Optional. The maximum number of hub addons to return. The service may
                      +   * return fewer than this value. If unspecified, at most 50 hub addons will be
                      +   * returned. The maximum value is 1000; values above 1000 will be coerced to
                      +   * 1000.
                      +   * 
                      + * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
                      +   * Optional. A page token, received from a previous `ListAddons` call.
                      +   * Provide this to retrieve the subsequent page.
                      +   *
                      +   * When paginating, all other parameters (except page_size) provided to
                      +   * `ListAddons` must match the call that provided the page token.
                      +   * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Optional. A page token, received from a previous `ListAddons` call.
                      +   * Provide this to retrieve the subsequent page.
                      +   *
                      +   * When paginating, all other parameters (except page_size) provided to
                      +   * `ListAddons` must match the call that provided the page token.
                      +   * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, filter_); + } + if (pageSize_ != 0) { + output.writeInt32(3, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, pageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, filter_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, pageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ListAddonsRequest)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ListAddonsRequest other = + (com.google.cloud.apihub.v1.ListAddonsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.ListAddonsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The [ListAddons][google.cloud.apihub.v1.ApiHubAddon.ListAddons] method's
                      +   * request.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ListAddonsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ListAddonsRequest) + com.google.cloud.apihub.v1.ListAddonsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ListAddonsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ListAddonsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ListAddonsRequest.class, + com.google.cloud.apihub.v1.ListAddonsRequest.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ListAddonsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + filter_ = ""; + pageSize_ = 0; + pageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ListAddonsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ListAddonsRequest getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ListAddonsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ListAddonsRequest build() { + com.google.cloud.apihub.v1.ListAddonsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ListAddonsRequest buildPartial() { + com.google.cloud.apihub.v1.ListAddonsRequest result = + new com.google.cloud.apihub.v1.ListAddonsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.ListAddonsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.filter_ = filter_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.pageToken_ = pageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ListAddonsRequest) { + return mergeFrom((com.google.cloud.apihub.v1.ListAddonsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ListAddonsRequest other) { + if (other == com.google.cloud.apihub.v1.ListAddonsRequest.getDefaultInstance()) return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + filter_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 24: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000004; + break; + } // case 24 + case 34: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
                      +     * Required. The parent resource where this addon will be created.
                      +     * Format: `projects/{project}/locations/{location}`.
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The parent resource where this addon will be created.
                      +     * Format: `projects/{project}/locations/{location}`.
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The parent resource where this addon will be created.
                      +     * Format: `projects/{project}/locations/{location}`.
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The parent resource where this addon will be created.
                      +     * Format: `projects/{project}/locations/{location}`.
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The parent resource where this addon will be created.
                      +     * Format: `projects/{project}/locations/{location}`.
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + + /** + * + * + *
                      +     * Optional. An expression that filters the list of addons.
                      +     * The only supported filter is `plugin_instance_name`. It can be used to
                      +     * filter addons that are enabled for a given plugin instance.
                      +     * The format of the filter is `plugin_instance_name =
                      +     * "projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}"`.
                      +     * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Optional. An expression that filters the list of addons.
                      +     * The only supported filter is `plugin_instance_name`. It can be used to
                      +     * filter addons that are enabled for a given plugin instance.
                      +     * The format of the filter is `plugin_instance_name =
                      +     * "projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}"`.
                      +     * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Optional. An expression that filters the list of addons.
                      +     * The only supported filter is `plugin_instance_name`. It can be used to
                      +     * filter addons that are enabled for a given plugin instance.
                      +     * The format of the filter is `plugin_instance_name =
                      +     * "projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}"`.
                      +     * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + filter_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. An expression that filters the list of addons.
                      +     * The only supported filter is `plugin_instance_name`. It can be used to
                      +     * filter addons that are enabled for a given plugin instance.
                      +     * The format of the filter is `plugin_instance_name =
                      +     * "projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}"`.
                      +     * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + filter_ = getDefaultInstance().getFilter(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. An expression that filters the list of addons.
                      +     * The only supported filter is `plugin_instance_name`. It can be used to
                      +     * filter addons that are enabled for a given plugin instance.
                      +     * The format of the filter is `plugin_instance_name =
                      +     * "projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}"`.
                      +     * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
                      +     * Optional. The maximum number of hub addons to return. The service may
                      +     * return fewer than this value. If unspecified, at most 50 hub addons will be
                      +     * returned. The maximum value is 1000; values above 1000 will be coerced to
                      +     * 1000.
                      +     * 
                      + * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
                      +     * Optional. The maximum number of hub addons to return. The service may
                      +     * return fewer than this value. If unspecified, at most 50 hub addons will be
                      +     * returned. The maximum value is 1000; values above 1000 will be coerced to
                      +     * 1000.
                      +     * 
                      + * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The maximum number of hub addons to return. The service may
                      +     * return fewer than this value. If unspecified, at most 50 hub addons will be
                      +     * returned. The maximum value is 1000; values above 1000 will be coerced to
                      +     * 1000.
                      +     * 
                      + * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000004); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
                      +     * Optional. A page token, received from a previous `ListAddons` call.
                      +     * Provide this to retrieve the subsequent page.
                      +     *
                      +     * When paginating, all other parameters (except page_size) provided to
                      +     * `ListAddons` must match the call that provided the page token.
                      +     * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Optional. A page token, received from a previous `ListAddons` call.
                      +     * Provide this to retrieve the subsequent page.
                      +     *
                      +     * When paginating, all other parameters (except page_size) provided to
                      +     * `ListAddons` must match the call that provided the page token.
                      +     * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Optional. A page token, received from a previous `ListAddons` call.
                      +     * Provide this to retrieve the subsequent page.
                      +     *
                      +     * When paginating, all other parameters (except page_size) provided to
                      +     * `ListAddons` must match the call that provided the page token.
                      +     * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. A page token, received from a previous `ListAddons` call.
                      +     * Provide this to retrieve the subsequent page.
                      +     *
                      +     * When paginating, all other parameters (except page_size) provided to
                      +     * `ListAddons` must match the call that provided the page token.
                      +     * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. A page token, received from a previous `ListAddons` call.
                      +     * Provide this to retrieve the subsequent page.
                      +     *
                      +     * When paginating, all other parameters (except page_size) provided to
                      +     * `ListAddons` must match the call that provided the page token.
                      +     * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ListAddonsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ListAddonsRequest) + private static final com.google.cloud.apihub.v1.ListAddonsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ListAddonsRequest(); + } + + public static com.google.cloud.apihub.v1.ListAddonsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAddonsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ListAddonsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListAddonsRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListAddonsRequestOrBuilder.java new file mode 100644 index 000000000000..0b674242e09e --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListAddonsRequestOrBuilder.java @@ -0,0 +1,144 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ListAddonsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ListAddonsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The parent resource where this addon will be created.
                      +   * Format: `projects/{project}/locations/{location}`.
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
                      +   * Required. The parent resource where this addon will be created.
                      +   * Format: `projects/{project}/locations/{location}`.
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
                      +   * Optional. An expression that filters the list of addons.
                      +   * The only supported filter is `plugin_instance_name`. It can be used to
                      +   * filter addons that are enabled for a given plugin instance.
                      +   * The format of the filter is `plugin_instance_name =
                      +   * "projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}"`.
                      +   * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
                      +   * Optional. An expression that filters the list of addons.
                      +   * The only supported filter is `plugin_instance_name`. It can be used to
                      +   * filter addons that are enabled for a given plugin instance.
                      +   * The format of the filter is `plugin_instance_name =
                      +   * "projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}"`.
                      +   * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
                      +   * Optional. The maximum number of hub addons to return. The service may
                      +   * return fewer than this value. If unspecified, at most 50 hub addons will be
                      +   * returned. The maximum value is 1000; values above 1000 will be coerced to
                      +   * 1000.
                      +   * 
                      + * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
                      +   * Optional. A page token, received from a previous `ListAddons` call.
                      +   * Provide this to retrieve the subsequent page.
                      +   *
                      +   * When paginating, all other parameters (except page_size) provided to
                      +   * `ListAddons` must match the call that provided the page token.
                      +   * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
                      +   * Optional. A page token, received from a previous `ListAddons` call.
                      +   * Provide this to retrieve the subsequent page.
                      +   *
                      +   * When paginating, all other parameters (except page_size) provided to
                      +   * `ListAddons` must match the call that provided the page token.
                      +   * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListAddonsResponse.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListAddonsResponse.java new file mode 100644 index 000000000000..6f0c4309bfdf --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListAddonsResponse.java @@ -0,0 +1,1114 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The [ListAddons][google.cloud.apihub.v1.ApiHubAddon.ListAddons] method's
                      + * response.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ListAddonsResponse} + */ +@com.google.protobuf.Generated +public final class ListAddonsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ListAddonsResponse) + ListAddonsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListAddonsResponse"); + } + + // Use ListAddonsResponse.newBuilder() to construct. + private ListAddonsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListAddonsResponse() { + addons_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ListAddonsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ListAddonsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ListAddonsResponse.class, + com.google.cloud.apihub.v1.ListAddonsResponse.Builder.class); + } + + public static final int ADDONS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List addons_; + + /** + * + * + *
                      +   * The list of addons.
                      +   * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + @java.lang.Override + public java.util.List getAddonsList() { + return addons_; + } + + /** + * + * + *
                      +   * The list of addons.
                      +   * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + @java.lang.Override + public java.util.List + getAddonsOrBuilderList() { + return addons_; + } + + /** + * + * + *
                      +   * The list of addons.
                      +   * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + @java.lang.Override + public int getAddonsCount() { + return addons_.size(); + } + + /** + * + * + *
                      +   * The list of addons.
                      +   * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.Addon getAddons(int index) { + return addons_.get(index); + } + + /** + * + * + *
                      +   * The list of addons.
                      +   * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AddonOrBuilder getAddonsOrBuilder(int index) { + return addons_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
                      +   * A token to retrieve the next page of results, or empty if there are no
                      +   * more results in the list.
                      +   * 
                      + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
                      +   * A token to retrieve the next page of results, or empty if there are no
                      +   * more results in the list.
                      +   * 
                      + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < addons_.size(); i++) { + output.writeMessage(1, addons_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < addons_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, addons_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ListAddonsResponse)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ListAddonsResponse other = + (com.google.cloud.apihub.v1.ListAddonsResponse) obj; + + if (!getAddonsList().equals(other.getAddonsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getAddonsCount() > 0) { + hash = (37 * hash) + ADDONS_FIELD_NUMBER; + hash = (53 * hash) + getAddonsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.ListAddonsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The [ListAddons][google.cloud.apihub.v1.ApiHubAddon.ListAddons] method's
                      +   * response.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ListAddonsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ListAddonsResponse) + com.google.cloud.apihub.v1.ListAddonsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ListAddonsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ListAddonsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ListAddonsResponse.class, + com.google.cloud.apihub.v1.ListAddonsResponse.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ListAddonsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (addonsBuilder_ == null) { + addons_ = java.util.Collections.emptyList(); + } else { + addons_ = null; + addonsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ListAddonsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ListAddonsResponse getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ListAddonsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ListAddonsResponse build() { + com.google.cloud.apihub.v1.ListAddonsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ListAddonsResponse buildPartial() { + com.google.cloud.apihub.v1.ListAddonsResponse result = + new com.google.cloud.apihub.v1.ListAddonsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.cloud.apihub.v1.ListAddonsResponse result) { + if (addonsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + addons_ = java.util.Collections.unmodifiableList(addons_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.addons_ = addons_; + } else { + result.addons_ = addonsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.apihub.v1.ListAddonsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ListAddonsResponse) { + return mergeFrom((com.google.cloud.apihub.v1.ListAddonsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ListAddonsResponse other) { + if (other == com.google.cloud.apihub.v1.ListAddonsResponse.getDefaultInstance()) return this; + if (addonsBuilder_ == null) { + if (!other.addons_.isEmpty()) { + if (addons_.isEmpty()) { + addons_ = other.addons_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureAddonsIsMutable(); + addons_.addAll(other.addons_); + } + onChanged(); + } + } else { + if (!other.addons_.isEmpty()) { + if (addonsBuilder_.isEmpty()) { + addonsBuilder_.dispose(); + addonsBuilder_ = null; + addons_ = other.addons_; + bitField0_ = (bitField0_ & ~0x00000001); + addonsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetAddonsFieldBuilder() + : null; + } else { + addonsBuilder_.addAllMessages(other.addons_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.apihub.v1.Addon m = + input.readMessage(com.google.cloud.apihub.v1.Addon.parser(), extensionRegistry); + if (addonsBuilder_ == null) { + ensureAddonsIsMutable(); + addons_.add(m); + } else { + addonsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List addons_ = + java.util.Collections.emptyList(); + + private void ensureAddonsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + addons_ = new java.util.ArrayList(addons_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.Addon, + com.google.cloud.apihub.v1.Addon.Builder, + com.google.cloud.apihub.v1.AddonOrBuilder> + addonsBuilder_; + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public java.util.List getAddonsList() { + if (addonsBuilder_ == null) { + return java.util.Collections.unmodifiableList(addons_); + } else { + return addonsBuilder_.getMessageList(); + } + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public int getAddonsCount() { + if (addonsBuilder_ == null) { + return addons_.size(); + } else { + return addonsBuilder_.getCount(); + } + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public com.google.cloud.apihub.v1.Addon getAddons(int index) { + if (addonsBuilder_ == null) { + return addons_.get(index); + } else { + return addonsBuilder_.getMessage(index); + } + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public Builder setAddons(int index, com.google.cloud.apihub.v1.Addon value) { + if (addonsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAddonsIsMutable(); + addons_.set(index, value); + onChanged(); + } else { + addonsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public Builder setAddons(int index, com.google.cloud.apihub.v1.Addon.Builder builderForValue) { + if (addonsBuilder_ == null) { + ensureAddonsIsMutable(); + addons_.set(index, builderForValue.build()); + onChanged(); + } else { + addonsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public Builder addAddons(com.google.cloud.apihub.v1.Addon value) { + if (addonsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAddonsIsMutable(); + addons_.add(value); + onChanged(); + } else { + addonsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public Builder addAddons(int index, com.google.cloud.apihub.v1.Addon value) { + if (addonsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAddonsIsMutable(); + addons_.add(index, value); + onChanged(); + } else { + addonsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public Builder addAddons(com.google.cloud.apihub.v1.Addon.Builder builderForValue) { + if (addonsBuilder_ == null) { + ensureAddonsIsMutable(); + addons_.add(builderForValue.build()); + onChanged(); + } else { + addonsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public Builder addAddons(int index, com.google.cloud.apihub.v1.Addon.Builder builderForValue) { + if (addonsBuilder_ == null) { + ensureAddonsIsMutable(); + addons_.add(index, builderForValue.build()); + onChanged(); + } else { + addonsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public Builder addAllAddons( + java.lang.Iterable values) { + if (addonsBuilder_ == null) { + ensureAddonsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, addons_); + onChanged(); + } else { + addonsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public Builder clearAddons() { + if (addonsBuilder_ == null) { + addons_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + addonsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public Builder removeAddons(int index) { + if (addonsBuilder_ == null) { + ensureAddonsIsMutable(); + addons_.remove(index); + onChanged(); + } else { + addonsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public com.google.cloud.apihub.v1.Addon.Builder getAddonsBuilder(int index) { + return internalGetAddonsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public com.google.cloud.apihub.v1.AddonOrBuilder getAddonsOrBuilder(int index) { + if (addonsBuilder_ == null) { + return addons_.get(index); + } else { + return addonsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public java.util.List + getAddonsOrBuilderList() { + if (addonsBuilder_ != null) { + return addonsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(addons_); + } + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public com.google.cloud.apihub.v1.Addon.Builder addAddonsBuilder() { + return internalGetAddonsFieldBuilder() + .addBuilder(com.google.cloud.apihub.v1.Addon.getDefaultInstance()); + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public com.google.cloud.apihub.v1.Addon.Builder addAddonsBuilder(int index) { + return internalGetAddonsFieldBuilder() + .addBuilder(index, com.google.cloud.apihub.v1.Addon.getDefaultInstance()); + } + + /** + * + * + *
                      +     * The list of addons.
                      +     * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + public java.util.List getAddonsBuilderList() { + return internalGetAddonsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.Addon, + com.google.cloud.apihub.v1.Addon.Builder, + com.google.cloud.apihub.v1.AddonOrBuilder> + internalGetAddonsFieldBuilder() { + if (addonsBuilder_ == null) { + addonsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.Addon, + com.google.cloud.apihub.v1.Addon.Builder, + com.google.cloud.apihub.v1.AddonOrBuilder>( + addons_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + addons_ = null; + } + return addonsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
                      +     * A token to retrieve the next page of results, or empty if there are no
                      +     * more results in the list.
                      +     * 
                      + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * A token to retrieve the next page of results, or empty if there are no
                      +     * more results in the list.
                      +     * 
                      + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * A token to retrieve the next page of results, or empty if there are no
                      +     * more results in the list.
                      +     * 
                      + * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * A token to retrieve the next page of results, or empty if there are no
                      +     * more results in the list.
                      +     * 
                      + * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * A token to retrieve the next page of results, or empty if there are no
                      +     * more results in the list.
                      +     * 
                      + * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ListAddonsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ListAddonsResponse) + private static final com.google.cloud.apihub.v1.ListAddonsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ListAddonsResponse(); + } + + public static com.google.cloud.apihub.v1.ListAddonsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListAddonsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ListAddonsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListAddonsResponseOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListAddonsResponseOrBuilder.java new file mode 100644 index 000000000000..180b71a66c6e --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListAddonsResponseOrBuilder.java @@ -0,0 +1,111 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ListAddonsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ListAddonsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * The list of addons.
                      +   * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + java.util.List getAddonsList(); + + /** + * + * + *
                      +   * The list of addons.
                      +   * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + com.google.cloud.apihub.v1.Addon getAddons(int index); + + /** + * + * + *
                      +   * The list of addons.
                      +   * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + int getAddonsCount(); + + /** + * + * + *
                      +   * The list of addons.
                      +   * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + java.util.List getAddonsOrBuilderList(); + + /** + * + * + *
                      +   * The list of addons.
                      +   * 
                      + * + * repeated .google.cloud.apihub.v1.Addon addons = 1; + */ + com.google.cloud.apihub.v1.AddonOrBuilder getAddonsOrBuilder(int index); + + /** + * + * + *
                      +   * A token to retrieve the next page of results, or empty if there are no
                      +   * more results in the list.
                      +   * 
                      + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
                      +   * A token to retrieve the next page of results, or empty if there are no
                      +   * more results in the list.
                      +   * 
                      + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListApisRequest.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListApisRequest.java index 165a7a33fff4..29f0841acf08 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListApisRequest.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListApisRequest.java @@ -218,6 +218,12 @@ public com.google.protobuf.ByteString getParentBytes() { * provided the parent is * `projects/test-project-id/locations/test-location-id`. * + * Another supported filter function is `plugins(source_metadata)`. This + * function filters for resources that are associated with a specific plugin. + * For example, `plugins(source_metadata) : + * "projects/test-project-id/locations/test-location-id/plugins/test-plugin-id"` + * will return resources sourced from the given plugin. + * * Expressions are combined with either `AND` logic operator or `OR` logical * operator but not both of them together i.e. only one of the `AND` or `OR` * operator can be used throughout the filter string and both the operators @@ -353,6 +359,12 @@ public java.lang.String getFilter() { * provided the parent is * `projects/test-project-id/locations/test-location-id`. * + * Another supported filter function is `plugins(source_metadata)`. This + * function filters for resources that are associated with a specific plugin. + * For example, `plugins(source_metadata) : + * "projects/test-project-id/locations/test-location-id/plugins/test-plugin-id"` + * will return resources sourced from the given plugin. + * * Expressions are combined with either `AND` logic operator or `OR` logical * operator but not both of them together i.e. only one of the `AND` or `OR` * operator can be used throughout the filter string and both the operators @@ -1078,6 +1090,12 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) { * provided the parent is * `projects/test-project-id/locations/test-location-id`. * + * Another supported filter function is `plugins(source_metadata)`. This + * function filters for resources that are associated with a specific plugin. + * For example, `plugins(source_metadata) : + * "projects/test-project-id/locations/test-location-id/plugins/test-plugin-id"` + * will return resources sourced from the given plugin. + * * Expressions are combined with either `AND` logic operator or `OR` logical * operator but not both of them together i.e. only one of the `AND` or `OR` * operator can be used throughout the filter string and both the operators @@ -1212,6 +1230,12 @@ public java.lang.String getFilter() { * provided the parent is * `projects/test-project-id/locations/test-location-id`. * + * Another supported filter function is `plugins(source_metadata)`. This + * function filters for resources that are associated with a specific plugin. + * For example, `plugins(source_metadata) : + * "projects/test-project-id/locations/test-location-id/plugins/test-plugin-id"` + * will return resources sourced from the given plugin. + * * Expressions are combined with either `AND` logic operator or `OR` logical * operator but not both of them together i.e. only one of the `AND` or `OR` * operator can be used throughout the filter string and both the operators @@ -1346,6 +1370,12 @@ public com.google.protobuf.ByteString getFilterBytes() { * provided the parent is * `projects/test-project-id/locations/test-location-id`. * + * Another supported filter function is `plugins(source_metadata)`. This + * function filters for resources that are associated with a specific plugin. + * For example, `plugins(source_metadata) : + * "projects/test-project-id/locations/test-location-id/plugins/test-plugin-id"` + * will return resources sourced from the given plugin. + * * Expressions are combined with either `AND` logic operator or `OR` logical * operator but not both of them together i.e. only one of the `AND` or `OR` * operator can be used throughout the filter string and both the operators @@ -1479,6 +1509,12 @@ public Builder setFilter(java.lang.String value) { * provided the parent is * `projects/test-project-id/locations/test-location-id`. * + * Another supported filter function is `plugins(source_metadata)`. This + * function filters for resources that are associated with a specific plugin. + * For example, `plugins(source_metadata) : + * "projects/test-project-id/locations/test-location-id/plugins/test-plugin-id"` + * will return resources sourced from the given plugin. + * * Expressions are combined with either `AND` logic operator or `OR` logical * operator but not both of them together i.e. only one of the `AND` or `OR` * operator can be used throughout the filter string and both the operators @@ -1608,6 +1644,12 @@ public Builder clearFilter() { * provided the parent is * `projects/test-project-id/locations/test-location-id`. * + * Another supported filter function is `plugins(source_metadata)`. This + * function filters for resources that are associated with a specific plugin. + * For example, `plugins(source_metadata) : + * "projects/test-project-id/locations/test-location-id/plugins/test-plugin-id"` + * will return resources sourced from the given plugin. + * * Expressions are combined with either `AND` logic operator or `OR` logical * operator but not both of them together i.e. only one of the `AND` or `OR` * operator can be used throughout the filter string and both the operators diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListApisRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListApisRequestOrBuilder.java index 82598e1c62da..d7e260bf2b78 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListApisRequestOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListApisRequestOrBuilder.java @@ -140,6 +140,12 @@ public interface ListApisRequestOrBuilder * provided the parent is * `projects/test-project-id/locations/test-location-id`. * + * Another supported filter function is `plugins(source_metadata)`. This + * function filters for resources that are associated with a specific plugin. + * For example, `plugins(source_metadata) : + * "projects/test-project-id/locations/test-location-id/plugins/test-plugin-id"` + * will return resources sourced from the given plugin. + * * Expressions are combined with either `AND` logic operator or `OR` logical * operator but not both of them together i.e. only one of the `AND` or `OR` * operator can be used throughout the filter string and both the operators @@ -264,6 +270,12 @@ public interface ListApisRequestOrBuilder * provided the parent is * `projects/test-project-id/locations/test-location-id`. * + * Another supported filter function is `plugins(source_metadata)`. This + * function filters for resources that are associated with a specific plugin. + * For example, `plugins(source_metadata) : + * "projects/test-project-id/locations/test-location-id/plugins/test-plugin-id"` + * will return resources sourced from the given plugin. + * * Expressions are combined with either `AND` logic operator or `OR` logical * operator but not both of them together i.e. only one of the `AND` or `OR` * operator can be used throughout the filter string and both the operators diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListPluginInstancesRequest.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListPluginInstancesRequest.java index 8d533c08f2b3..798ce5912390 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListPluginInstancesRequest.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListPluginInstancesRequest.java @@ -157,6 +157,8 @@ public com.google.protobuf.ByteString getParentBytes() { * * * `state` - The state of the Plugin Instance. Allowed * comparison operators: `=`. + * * `source_project_id` - The source project id of the Plugin Instance. + * Allowed comparison operators: `=`. * * A filter function is also supported in the filter string. The filter * function is `id(name)`. The `id(name)` function returns the id of the @@ -210,6 +212,8 @@ public java.lang.String getFilter() { * * * `state` - The state of the Plugin Instance. Allowed * comparison operators: `=`. + * * `source_project_id` - The source project id of the Plugin Instance. + * Allowed comparison operators: `=`. * * A filter function is also supported in the filter string. The filter * function is `id(name)`. The `id(name)` function returns the id of the @@ -867,6 +871,8 @@ public Builder setParentBytes(com.google.protobuf.ByteString value) { * * * `state` - The state of the Plugin Instance. Allowed * comparison operators: `=`. + * * `source_project_id` - The source project id of the Plugin Instance. + * Allowed comparison operators: `=`. * * A filter function is also supported in the filter string. The filter * function is `id(name)`. The `id(name)` function returns the id of the @@ -919,6 +925,8 @@ public java.lang.String getFilter() { * * * `state` - The state of the Plugin Instance. Allowed * comparison operators: `=`. + * * `source_project_id` - The source project id of the Plugin Instance. + * Allowed comparison operators: `=`. * * A filter function is also supported in the filter string. The filter * function is `id(name)`. The `id(name)` function returns the id of the @@ -971,6 +979,8 @@ public com.google.protobuf.ByteString getFilterBytes() { * * * `state` - The state of the Plugin Instance. Allowed * comparison operators: `=`. + * * `source_project_id` - The source project id of the Plugin Instance. + * Allowed comparison operators: `=`. * * A filter function is also supported in the filter string. The filter * function is `id(name)`. The `id(name)` function returns the id of the @@ -1022,6 +1032,8 @@ public Builder setFilter(java.lang.String value) { * * * `state` - The state of the Plugin Instance. Allowed * comparison operators: `=`. + * * `source_project_id` - The source project id of the Plugin Instance. + * Allowed comparison operators: `=`. * * A filter function is also supported in the filter string. The filter * function is `id(name)`. The `id(name)` function returns the id of the @@ -1069,6 +1081,8 @@ public Builder clearFilter() { * * * `state` - The state of the Plugin Instance. Allowed * comparison operators: `=`. + * * `source_project_id` - The source project id of the Plugin Instance. + * Allowed comparison operators: `=`. * * A filter function is also supported in the filter string. The filter * function is `id(name)`. The `id(name)` function returns the id of the diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListPluginInstancesRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListPluginInstancesRequestOrBuilder.java index 0e1fc45172f0..05f72a854557 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListPluginInstancesRequestOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ListPluginInstancesRequestOrBuilder.java @@ -77,6 +77,8 @@ public interface ListPluginInstancesRequestOrBuilder * * * `state` - The state of the Plugin Instance. Allowed * comparison operators: `=`. + * * `source_project_id` - The source project id of the Plugin Instance. + * Allowed comparison operators: `=`. * * A filter function is also supported in the filter string. The filter * function is `id(name)`. The `id(name)` function returns the id of the @@ -119,6 +121,8 @@ public interface ListPluginInstancesRequestOrBuilder * * * `state` - The state of the Plugin Instance. Allowed * comparison operators: `=`. + * * `source_project_id` - The source project id of the Plugin Instance. + * Allowed comparison operators: `=`. * * A filter function is also supported in the filter string. The filter * function is `id(name)`. The `id(name)` function returns the id of the diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/LookupApiHubInstanceRequest.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/LookupApiHubInstanceRequest.java index 62703442649a..23e9718158c9 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/LookupApiHubInstanceRequest.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/LookupApiHubInstanceRequest.java @@ -81,10 +81,9 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
                      -   * Required. There will always be only one Api Hub instance for a GCP project
                      -   * across all locations.
                      -   * The parent resource for the Api Hub instance resource.
                      -   * Format: `projects/{project}/locations/{location}`
                      +   * Required. There will always be only one Api Hub instance for a Google Cloud
                      +   * project across all locations. The parent resource for the Api Hub instance
                      +   * resource. Format: `projects/{project}/locations/{location}`
                          * 
                      * * @@ -110,10 +109,9 @@ public java.lang.String getParent() { * * *
                      -   * Required. There will always be only one Api Hub instance for a GCP project
                      -   * across all locations.
                      -   * The parent resource for the Api Hub instance resource.
                      -   * Format: `projects/{project}/locations/{location}`
                      +   * Required. There will always be only one Api Hub instance for a Google Cloud
                      +   * project across all locations. The parent resource for the Api Hub instance
                      +   * resource. Format: `projects/{project}/locations/{location}`
                          * 
                      * * @@ -454,10 +452,9 @@ public Builder mergeFrom( * * *
                      -     * Required. There will always be only one Api Hub instance for a GCP project
                      -     * across all locations.
                      -     * The parent resource for the Api Hub instance resource.
                      -     * Format: `projects/{project}/locations/{location}`
                      +     * Required. There will always be only one Api Hub instance for a Google Cloud
                      +     * project across all locations. The parent resource for the Api Hub instance
                      +     * resource. Format: `projects/{project}/locations/{location}`
                            * 
                      * * @@ -482,10 +479,9 @@ public java.lang.String getParent() { * * *
                      -     * Required. There will always be only one Api Hub instance for a GCP project
                      -     * across all locations.
                      -     * The parent resource for the Api Hub instance resource.
                      -     * Format: `projects/{project}/locations/{location}`
                      +     * Required. There will always be only one Api Hub instance for a Google Cloud
                      +     * project across all locations. The parent resource for the Api Hub instance
                      +     * resource. Format: `projects/{project}/locations/{location}`
                            * 
                      * * @@ -510,10 +506,9 @@ public com.google.protobuf.ByteString getParentBytes() { * * *
                      -     * Required. There will always be only one Api Hub instance for a GCP project
                      -     * across all locations.
                      -     * The parent resource for the Api Hub instance resource.
                      -     * Format: `projects/{project}/locations/{location}`
                      +     * Required. There will always be only one Api Hub instance for a Google Cloud
                      +     * project across all locations. The parent resource for the Api Hub instance
                      +     * resource. Format: `projects/{project}/locations/{location}`
                            * 
                      * * @@ -537,10 +532,9 @@ public Builder setParent(java.lang.String value) { * * *
                      -     * Required. There will always be only one Api Hub instance for a GCP project
                      -     * across all locations.
                      -     * The parent resource for the Api Hub instance resource.
                      -     * Format: `projects/{project}/locations/{location}`
                      +     * Required. There will always be only one Api Hub instance for a Google Cloud
                      +     * project across all locations. The parent resource for the Api Hub instance
                      +     * resource. Format: `projects/{project}/locations/{location}`
                            * 
                      * * @@ -560,10 +554,9 @@ public Builder clearParent() { * * *
                      -     * Required. There will always be only one Api Hub instance for a GCP project
                      -     * across all locations.
                      -     * The parent resource for the Api Hub instance resource.
                      -     * Format: `projects/{project}/locations/{location}`
                      +     * Required. There will always be only one Api Hub instance for a Google Cloud
                      +     * project across all locations. The parent resource for the Api Hub instance
                      +     * resource. Format: `projects/{project}/locations/{location}`
                            * 
                      * * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/LookupApiHubInstanceRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/LookupApiHubInstanceRequestOrBuilder.java index 36420eaabbd2..92744d34cd07 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/LookupApiHubInstanceRequestOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/LookupApiHubInstanceRequestOrBuilder.java @@ -30,10 +30,9 @@ public interface LookupApiHubInstanceRequestOrBuilder * * *
                      -   * Required. There will always be only one Api Hub instance for a GCP project
                      -   * across all locations.
                      -   * The parent resource for the Api Hub instance resource.
                      -   * Format: `projects/{project}/locations/{location}`
                      +   * Required. There will always be only one Api Hub instance for a Google Cloud
                      +   * project across all locations. The parent resource for the Api Hub instance
                      +   * resource. Format: `projects/{project}/locations/{location}`
                          * 
                      * * @@ -48,10 +47,9 @@ public interface LookupApiHubInstanceRequestOrBuilder * * *
                      -   * Required. There will always be only one Api Hub instance for a GCP project
                      -   * across all locations.
                      -   * The parent resource for the Api Hub instance resource.
                      -   * Format: `projects/{project}/locations/{location}`
                      +   * Required. There will always be only one Api Hub instance for a Google Cloud
                      +   * project across all locations. The parent resource for the Api Hub instance
                      +   * resource. Format: `projects/{project}/locations/{location}`
                          * 
                      * * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManageAddonConfigRequest.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManageAddonConfigRequest.java new file mode 100644 index 000000000000..9c941b8b7069 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManageAddonConfigRequest.java @@ -0,0 +1,951 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The [ManageAddonConfig][google.cloud.apihub.v1.ApiHubAddon.ManageAddonConfig]
                      + * method's request.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ManageAddonConfigRequest} + */ +@com.google.protobuf.Generated +public final class ManageAddonConfigRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ManageAddonConfigRequest) + ManageAddonConfigRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ManageAddonConfigRequest"); + } + + // Use ManageAddonConfigRequest.newBuilder() to construct. + private ManageAddonConfigRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ManageAddonConfigRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ManageAddonConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ManageAddonConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ManageAddonConfigRequest.class, + com.google.cloud.apihub.v1.ManageAddonConfigRequest.Builder.class); + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
                      +   * Required. The name of the addon for which the config is to be managed.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The name of the addon for which the config is to be managed.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CONFIG_FIELD_NUMBER = 2; + private com.google.cloud.apihub.v1.AddonConfig config_; + + /** + * + * + *
                      +   * Required. The config of the addon to be managed. This config will replace
                      +   * the config present in the addon. The type of the config should match the
                      +   * config type already present in the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the config field is set. + */ + @java.lang.Override + public boolean hasConfig() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Required. The config of the addon to be managed. This config will replace
                      +   * the config present in the addon. The type of the config should match the
                      +   * config type already present in the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The config. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AddonConfig getConfig() { + return config_ == null ? com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance() : config_; + } + + /** + * + * + *
                      +   * Required. The config of the addon to be managed. This config will replace
                      +   * the config present in the addon. The type of the config should match the
                      +   * config type already present in the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AddonConfigOrBuilder getConfigOrBuilder() { + return config_ == null ? com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance() : config_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getConfig()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getConfig()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ManageAddonConfigRequest)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ManageAddonConfigRequest other = + (com.google.cloud.apihub.v1.ManageAddonConfigRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (hasConfig() != other.hasConfig()) return false; + if (hasConfig()) { + if (!getConfig().equals(other.getConfig())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + if (hasConfig()) { + hash = (37 * hash) + CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getConfig().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.ManageAddonConfigRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The [ManageAddonConfig][google.cloud.apihub.v1.ApiHubAddon.ManageAddonConfig]
                      +   * method's request.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ManageAddonConfigRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ManageAddonConfigRequest) + com.google.cloud.apihub.v1.ManageAddonConfigRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ManageAddonConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ManageAddonConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ManageAddonConfigRequest.class, + com.google.cloud.apihub.v1.ManageAddonConfigRequest.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ManageAddonConfigRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetConfigFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + config_ = null; + if (configBuilder_ != null) { + configBuilder_.dispose(); + configBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.AddonServiceProto + .internal_static_google_cloud_apihub_v1_ManageAddonConfigRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManageAddonConfigRequest getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ManageAddonConfigRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManageAddonConfigRequest build() { + com.google.cloud.apihub.v1.ManageAddonConfigRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManageAddonConfigRequest buildPartial() { + com.google.cloud.apihub.v1.ManageAddonConfigRequest result = + new com.google.cloud.apihub.v1.ManageAddonConfigRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.ManageAddonConfigRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.config_ = configBuilder_ == null ? config_ : configBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ManageAddonConfigRequest) { + return mergeFrom((com.google.cloud.apihub.v1.ManageAddonConfigRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ManageAddonConfigRequest other) { + if (other == com.google.cloud.apihub.v1.ManageAddonConfigRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.hasConfig()) { + mergeConfig(other.getConfig()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage(internalGetConfigFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
                      +     * Required. The name of the addon for which the config is to be managed.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the addon for which the config is to be managed.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the addon for which the config is to be managed.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the addon for which the config is to be managed.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the addon for which the config is to be managed.
                      +     * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private com.google.cloud.apihub.v1.AddonConfig config_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AddonConfig, + com.google.cloud.apihub.v1.AddonConfig.Builder, + com.google.cloud.apihub.v1.AddonConfigOrBuilder> + configBuilder_; + + /** + * + * + *
                      +     * Required. The config of the addon to be managed. This config will replace
                      +     * the config present in the addon. The type of the config should match the
                      +     * config type already present in the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the config field is set. + */ + public boolean hasConfig() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +     * Required. The config of the addon to be managed. This config will replace
                      +     * the config present in the addon. The type of the config should match the
                      +     * config type already present in the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The config. + */ + public com.google.cloud.apihub.v1.AddonConfig getConfig() { + if (configBuilder_ == null) { + return config_ == null + ? com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance() + : config_; + } else { + return configBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Required. The config of the addon to be managed. This config will replace
                      +     * the config present in the addon. The type of the config should match the
                      +     * config type already present in the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setConfig(com.google.cloud.apihub.v1.AddonConfig value) { + if (configBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + } else { + configBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The config of the addon to be managed. This config will replace
                      +     * the config present in the addon. The type of the config should match the
                      +     * config type already present in the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setConfig(com.google.cloud.apihub.v1.AddonConfig.Builder builderForValue) { + if (configBuilder_ == null) { + config_ = builderForValue.build(); + } else { + configBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The config of the addon to be managed. This config will replace
                      +     * the config present in the addon. The type of the config should match the
                      +     * config type already present in the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeConfig(com.google.cloud.apihub.v1.AddonConfig value) { + if (configBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && config_ != null + && config_ != com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance()) { + getConfigBuilder().mergeFrom(value); + } else { + config_ = value; + } + } else { + configBuilder_.mergeFrom(value); + } + if (config_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Required. The config of the addon to be managed. This config will replace
                      +     * the config present in the addon. The type of the config should match the
                      +     * config type already present in the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearConfig() { + bitField0_ = (bitField0_ & ~0x00000002); + config_ = null; + if (configBuilder_ != null) { + configBuilder_.dispose(); + configBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The config of the addon to be managed. This config will replace
                      +     * the config present in the addon. The type of the config should match the
                      +     * config type already present in the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.AddonConfig.Builder getConfigBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Required. The config of the addon to be managed. This config will replace
                      +     * the config present in the addon. The type of the config should match the
                      +     * config type already present in the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.AddonConfigOrBuilder getConfigOrBuilder() { + if (configBuilder_ != null) { + return configBuilder_.getMessageOrBuilder(); + } else { + return config_ == null + ? com.google.cloud.apihub.v1.AddonConfig.getDefaultInstance() + : config_; + } + } + + /** + * + * + *
                      +     * Required. The config of the addon to be managed. This config will replace
                      +     * the config present in the addon. The type of the config should match the
                      +     * config type already present in the addon.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AddonConfig, + com.google.cloud.apihub.v1.AddonConfig.Builder, + com.google.cloud.apihub.v1.AddonConfigOrBuilder> + internalGetConfigFieldBuilder() { + if (configBuilder_ == null) { + configBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.AddonConfig, + com.google.cloud.apihub.v1.AddonConfig.Builder, + com.google.cloud.apihub.v1.AddonConfigOrBuilder>( + getConfig(), getParentForChildren(), isClean()); + config_ = null; + } + return configBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ManageAddonConfigRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ManageAddonConfigRequest) + private static final com.google.cloud.apihub.v1.ManageAddonConfigRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ManageAddonConfigRequest(); + } + + public static com.google.cloud.apihub.v1.ManageAddonConfigRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ManageAddonConfigRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManageAddonConfigRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManageAddonConfigRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManageAddonConfigRequestOrBuilder.java new file mode 100644 index 000000000000..0fdec98af7e2 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManageAddonConfigRequestOrBuilder.java @@ -0,0 +1,106 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/addon_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ManageAddonConfigRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ManageAddonConfigRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The name of the addon for which the config is to be managed.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
                      +   * Required. The name of the addon for which the config is to be managed.
                      +   * Format: `projects/{project}/locations/{location}/addons/{addon}`.
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
                      +   * Required. The config of the addon to be managed. This config will replace
                      +   * the config present in the addon. The type of the config should match the
                      +   * config type already present in the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the config field is set. + */ + boolean hasConfig(); + + /** + * + * + *
                      +   * Required. The config of the addon to be managed. This config will replace
                      +   * the config present in the addon. The type of the config should match the
                      +   * config type already present in the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The config. + */ + com.google.cloud.apihub.v1.AddonConfig getConfig(); + + /** + * + * + *
                      +   * Required. The config of the addon to be managed. This config will replace
                      +   * the config present in the addon. The type of the config should match the
                      +   * config type already present in the addon.
                      +   * 
                      + * + * .google.cloud.apihub.v1.AddonConfig config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.apihub.v1.AddonConfigOrBuilder getConfigOrBuilder(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataRequest.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataRequest.java new file mode 100644 index 000000000000..a5e3500478e2 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataRequest.java @@ -0,0 +1,1678 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/plugin_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The
                      + * [ManagePluginInstanceSourceData][google.cloud.apihub.v1.ApiHubPlugin.ManagePluginInstanceSourceData]
                      + * method's request.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest} + */ +@com.google.protobuf.Generated +public final class ManagePluginInstanceSourceDataRequest + extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest) + ManagePluginInstanceSourceDataRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ManagePluginInstanceSourceDataRequest"); + } + + // Use ManagePluginInstanceSourceDataRequest.newBuilder() to construct. + private ManagePluginInstanceSourceDataRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ManagePluginInstanceSourceDataRequest() { + name_ = ""; + dataType_ = 0; + action_ = 0; + relativePath_ = ""; + data_ = com.google.protobuf.ByteString.EMPTY; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.class, + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Builder.class); + } + + /** + * + * + *
                      +   * Type of data to be managed.
                      +   * 
                      + * + * Protobuf enum {@code google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType} + */ + public enum DataType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                      +     * Default unspecified type.
                      +     * 
                      + * + * DATA_TYPE_UNSPECIFIED = 0; + */ + DATA_TYPE_UNSPECIFIED(0), + /** + * + * + *
                      +     * Proxy deployment manifest.
                      +     * 
                      + * + * PROXY_DEPLOYMENT_MANIFEST = 1; + */ + PROXY_DEPLOYMENT_MANIFEST(1), + /** + * + * + *
                      +     * Environment manifest.
                      +     * 
                      + * + * ENVIRONMENT_MANIFEST = 2; + */ + ENVIRONMENT_MANIFEST(2), + /** + * + * + *
                      +     * Proxy bundle.
                      +     * 
                      + * + * PROXY_BUNDLE = 3; + */ + PROXY_BUNDLE(3), + /** + * + * + *
                      +     * Shared flow bundle.
                      +     * 
                      + * + * SHARED_FLOW_BUNDLE = 4; + */ + SHARED_FLOW_BUNDLE(4), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DataType"); + } + + /** + * + * + *
                      +     * Default unspecified type.
                      +     * 
                      + * + * DATA_TYPE_UNSPECIFIED = 0; + */ + public static final int DATA_TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                      +     * Proxy deployment manifest.
                      +     * 
                      + * + * PROXY_DEPLOYMENT_MANIFEST = 1; + */ + public static final int PROXY_DEPLOYMENT_MANIFEST_VALUE = 1; + + /** + * + * + *
                      +     * Environment manifest.
                      +     * 
                      + * + * ENVIRONMENT_MANIFEST = 2; + */ + public static final int ENVIRONMENT_MANIFEST_VALUE = 2; + + /** + * + * + *
                      +     * Proxy bundle.
                      +     * 
                      + * + * PROXY_BUNDLE = 3; + */ + public static final int PROXY_BUNDLE_VALUE = 3; + + /** + * + * + *
                      +     * Shared flow bundle.
                      +     * 
                      + * + * SHARED_FLOW_BUNDLE = 4; + */ + public static final int SHARED_FLOW_BUNDLE_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static DataType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static DataType forNumber(int value) { + switch (value) { + case 0: + return DATA_TYPE_UNSPECIFIED; + case 1: + return PROXY_DEPLOYMENT_MANIFEST; + case 2: + return ENVIRONMENT_MANIFEST; + case 3: + return PROXY_BUNDLE; + case 4: + return SHARED_FLOW_BUNDLE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public DataType findValueByNumber(int number) { + return DataType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final DataType[] VALUES = values(); + + public static DataType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private DataType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType) + } + + /** + * + * + *
                      +   * Action to be performed.
                      +   * 
                      + * + * Protobuf enum {@code google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action} + */ + public enum Action implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                      +     * Default unspecified action.
                      +     * 
                      + * + * ACTION_UNSPECIFIED = 0; + */ + ACTION_UNSPECIFIED(0), + /** + * + * + *
                      +     * Upload or upsert data.
                      +     * 
                      + * + * UPLOAD = 1; + */ + UPLOAD(1), + /** + * + * + *
                      +     * Delete data.
                      +     * 
                      + * + * DELETE = 2; + */ + DELETE(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Action"); + } + + /** + * + * + *
                      +     * Default unspecified action.
                      +     * 
                      + * + * ACTION_UNSPECIFIED = 0; + */ + public static final int ACTION_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                      +     * Upload or upsert data.
                      +     * 
                      + * + * UPLOAD = 1; + */ + public static final int UPLOAD_VALUE = 1; + + /** + * + * + *
                      +     * Delete data.
                      +     * 
                      + * + * DELETE = 2; + */ + public static final int DELETE_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Action valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static Action forNumber(int value) { + switch (value) { + case 0: + return ACTION_UNSPECIFIED; + case 1: + return UPLOAD; + case 2: + return DELETE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Action findValueByNumber(int number) { + return Action.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.getDescriptor() + .getEnumTypes() + .get(1); + } + + private static final Action[] VALUES = values(); + + public static Action valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Action(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action) + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
                      +   * Required. The name of the plugin instance for which data needs to be
                      +   * managed. Format:
                      +   * `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}`
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The name of the plugin instance for which data needs to be
                      +   * managed. Format:
                      +   * `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}`
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DATA_TYPE_FIELD_NUMBER = 2; + private int dataType_ = 0; + + /** + * + * + *
                      +   * Required. Type of data to be managed.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType data_type = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for dataType. + */ + @java.lang.Override + public int getDataTypeValue() { + return dataType_; + } + + /** + * + * + *
                      +   * Required. Type of data to be managed.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType data_type = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The dataType. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType getDataType() { + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType result = + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType.forNumber( + dataType_); + return result == null + ? com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType.UNRECOGNIZED + : result; + } + + public static final int ACTION_FIELD_NUMBER = 3; + private int action_ = 0; + + /** + * + * + *
                      +   * Required. Action to be performed.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action action = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for action. + */ + @java.lang.Override + public int getActionValue() { + return action_; + } + + /** + * + * + *
                      +   * Required. Action to be performed.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action action = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The action. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action getAction() { + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action result = + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action.forNumber(action_); + return result == null + ? com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action.UNRECOGNIZED + : result; + } + + public static final int RELATIVE_PATH_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object relativePath_ = ""; + + /** + * + * + *
                      +   * Required. Relative path of data being managed for a given plugin instance.
                      +   * 
                      + * + * string relative_path = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The relativePath. + */ + @java.lang.Override + public java.lang.String getRelativePath() { + java.lang.Object ref = relativePath_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + relativePath_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. Relative path of data being managed for a given plugin instance.
                      +   * 
                      + * + * string relative_path = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for relativePath. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRelativePathBytes() { + java.lang.Object ref = relativePath_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + relativePath_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DATA_FIELD_NUMBER = 5; + private com.google.protobuf.ByteString data_ = com.google.protobuf.ByteString.EMPTY; + + /** + * + * + *
                      +   * Required. Data to be managed.
                      +   * 
                      + * + * bytes data = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The data. + */ + @java.lang.Override + public com.google.protobuf.ByteString getData() { + return data_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (dataType_ + != com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType + .DATA_TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(2, dataType_); + } + if (action_ + != com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action + .ACTION_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, action_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(relativePath_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, relativePath_); + } + if (!data_.isEmpty()) { + output.writeBytes(5, data_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (dataType_ + != com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType + .DATA_TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, dataType_); + } + if (action_ + != com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action + .ACTION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, action_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(relativePath_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, relativePath_); + } + if (!data_.isEmpty()) { + size += com.google.protobuf.CodedOutputStream.computeBytesSize(5, data_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest other = + (com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (dataType_ != other.dataType_) return false; + if (action_ != other.action_) return false; + if (!getRelativePath().equals(other.getRelativePath())) return false; + if (!getData().equals(other.getData())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DATA_TYPE_FIELD_NUMBER; + hash = (53 * hash) + dataType_; + hash = (37 * hash) + ACTION_FIELD_NUMBER; + hash = (53 * hash) + action_; + hash = (37 * hash) + RELATIVE_PATH_FIELD_NUMBER; + hash = (53 * hash) + getRelativePath().hashCode(); + hash = (37 * hash) + DATA_FIELD_NUMBER; + hash = (53 * hash) + getData().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The
                      +   * [ManagePluginInstanceSourceData][google.cloud.apihub.v1.ApiHubPlugin.ManagePluginInstanceSourceData]
                      +   * method's request.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest) + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.class, + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + dataType_ = 0; + action_ = 0; + relativePath_ = ""; + data_ = com.google.protobuf.ByteString.EMPTY; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest + getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest build() { + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest buildPartial() { + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest result = + new com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.dataType_ = dataType_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.action_ = action_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.relativePath_ = relativePath_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.data_ = data_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest) { + return mergeFrom((com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest other) { + if (other + == com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.dataType_ != 0) { + setDataTypeValue(other.getDataTypeValue()); + } + if (other.action_ != 0) { + setActionValue(other.getActionValue()); + } + if (!other.getRelativePath().isEmpty()) { + relativePath_ = other.relativePath_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (!other.getData().isEmpty()) { + setData(other.getData()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + dataType_ = input.readEnum(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 24: + { + action_ = input.readEnum(); + bitField0_ |= 0x00000004; + break; + } // case 24 + case 34: + { + relativePath_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + data_ = input.readBytes(); + bitField0_ |= 0x00000010; + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
                      +     * Required. The name of the plugin instance for which data needs to be
                      +     * managed. Format:
                      +     * `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}`
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the plugin instance for which data needs to be
                      +     * managed. Format:
                      +     * `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}`
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the plugin instance for which data needs to be
                      +     * managed. Format:
                      +     * `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}`
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the plugin instance for which data needs to be
                      +     * managed. Format:
                      +     * `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}`
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the plugin instance for which data needs to be
                      +     * managed. Format:
                      +     * `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}`
                      +     * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int dataType_ = 0; + + /** + * + * + *
                      +     * Required. Type of data to be managed.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType data_type = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for dataType. + */ + @java.lang.Override + public int getDataTypeValue() { + return dataType_; + } + + /** + * + * + *
                      +     * Required. Type of data to be managed.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType data_type = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The enum numeric value on the wire for dataType to set. + * @return This builder for chaining. + */ + public Builder setDataTypeValue(int value) { + dataType_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. Type of data to be managed.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType data_type = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The dataType. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType getDataType() { + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType result = + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType.forNumber( + dataType_); + return result == null + ? com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType.UNRECOGNIZED + : result; + } + + /** + * + * + *
                      +     * Required. Type of data to be managed.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType data_type = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The dataType to set. + * @return This builder for chaining. + */ + public Builder setDataType( + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000002; + dataType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. Type of data to be managed.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType data_type = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearDataType() { + bitField0_ = (bitField0_ & ~0x00000002); + dataType_ = 0; + onChanged(); + return this; + } + + private int action_ = 0; + + /** + * + * + *
                      +     * Required. Action to be performed.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action action = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for action. + */ + @java.lang.Override + public int getActionValue() { + return action_; + } + + /** + * + * + *
                      +     * Required. Action to be performed.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action action = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The enum numeric value on the wire for action to set. + * @return This builder for chaining. + */ + public Builder setActionValue(int value) { + action_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. Action to be performed.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action action = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The action. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action getAction() { + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action result = + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action.forNumber( + action_); + return result == null + ? com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action.UNRECOGNIZED + : result; + } + + /** + * + * + *
                      +     * Required. Action to be performed.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action action = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The action to set. + * @return This builder for chaining. + */ + public Builder setAction( + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000004; + action_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. Action to be performed.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action action = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearAction() { + bitField0_ = (bitField0_ & ~0x00000004); + action_ = 0; + onChanged(); + return this; + } + + private java.lang.Object relativePath_ = ""; + + /** + * + * + *
                      +     * Required. Relative path of data being managed for a given plugin instance.
                      +     * 
                      + * + * string relative_path = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The relativePath. + */ + public java.lang.String getRelativePath() { + java.lang.Object ref = relativePath_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + relativePath_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. Relative path of data being managed for a given plugin instance.
                      +     * 
                      + * + * string relative_path = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for relativePath. + */ + public com.google.protobuf.ByteString getRelativePathBytes() { + java.lang.Object ref = relativePath_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + relativePath_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. Relative path of data being managed for a given plugin instance.
                      +     * 
                      + * + * string relative_path = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The relativePath to set. + * @return This builder for chaining. + */ + public Builder setRelativePath(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + relativePath_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. Relative path of data being managed for a given plugin instance.
                      +     * 
                      + * + * string relative_path = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearRelativePath() { + relativePath_ = getDefaultInstance().getRelativePath(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. Relative path of data being managed for a given plugin instance.
                      +     * 
                      + * + * string relative_path = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for relativePath to set. + * @return This builder for chaining. + */ + public Builder setRelativePathBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + relativePath_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private com.google.protobuf.ByteString data_ = com.google.protobuf.ByteString.EMPTY; + + /** + * + * + *
                      +     * Required. Data to be managed.
                      +     * 
                      + * + * bytes data = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The data. + */ + @java.lang.Override + public com.google.protobuf.ByteString getData() { + return data_; + } + + /** + * + * + *
                      +     * Required. Data to be managed.
                      +     * 
                      + * + * bytes data = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The data to set. + * @return This builder for chaining. + */ + public Builder setData(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + data_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. Data to be managed.
                      +     * 
                      + * + * bytes data = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearData() { + bitField0_ = (bitField0_ & ~0x00000010); + data_ = getDefaultInstance().getData(); + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest) + private static final com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest(); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ManagePluginInstanceSourceDataRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataRequestOrBuilder.java new file mode 100644 index 000000000000..38d1a64813a4 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataRequestOrBuilder.java @@ -0,0 +1,161 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/plugin_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ManagePluginInstanceSourceDataRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The name of the plugin instance for which data needs to be
                      +   * managed. Format:
                      +   * `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}`
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
                      +   * Required. The name of the plugin instance for which data needs to be
                      +   * managed. Format:
                      +   * `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}`
                      +   * 
                      + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
                      +   * Required. Type of data to be managed.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType data_type = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for dataType. + */ + int getDataTypeValue(); + + /** + * + * + *
                      +   * Required. Type of data to be managed.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType data_type = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The dataType. + */ + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataType getDataType(); + + /** + * + * + *
                      +   * Required. Action to be performed.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action action = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for action. + */ + int getActionValue(); + + /** + * + * + *
                      +   * Required. Action to be performed.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action action = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The action. + */ + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.Action getAction(); + + /** + * + * + *
                      +   * Required. Relative path of data being managed for a given plugin instance.
                      +   * 
                      + * + * string relative_path = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The relativePath. + */ + java.lang.String getRelativePath(); + + /** + * + * + *
                      +   * Required. Relative path of data being managed for a given plugin instance.
                      +   * 
                      + * + * string relative_path = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for relativePath. + */ + com.google.protobuf.ByteString getRelativePathBytes(); + + /** + * + * + *
                      +   * Required. Data to be managed.
                      +   * 
                      + * + * bytes data = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The data. + */ + com.google.protobuf.ByteString getData(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataResponse.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataResponse.java new file mode 100644 index 000000000000..3c1b072426dc --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataResponse.java @@ -0,0 +1,411 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/plugin_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The
                      + * [ManagePluginInstanceSourceData][google.cloud.apihub.v1.ApiHubPlugin.ManagePluginInstanceSourceData]
                      + * method's response.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse} + */ +@com.google.protobuf.Generated +public final class ManagePluginInstanceSourceDataResponse + extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse) + ManagePluginInstanceSourceDataResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ManagePluginInstanceSourceDataResponse"); + } + + // Use ManagePluginInstanceSourceDataResponse.newBuilder() to construct. + private ManagePluginInstanceSourceDataResponse( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ManagePluginInstanceSourceDataResponse() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse.class, + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse.Builder.class); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse other = + (com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse) obj; + + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The
                      +   * [ManagePluginInstanceSourceData][google.cloud.apihub.v1.ApiHubPlugin.ManagePluginInstanceSourceData]
                      +   * method's response.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse) + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse.class, + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse.Builder.class); + } + + // Construct using + // com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse + getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse build() { + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse buildPartial() { + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse result = + new com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse(this); + onBuilt(); + return result; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse) { + return mergeFrom((com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse other) { + if (other + == com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse.getDefaultInstance()) + return this; + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse) + private static final com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse(); + } + + public static com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ManagePluginInstanceSourceDataResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataResponseOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataResponseOrBuilder.java new file mode 100644 index 000000000000..a7a8bf65ff9d --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ManagePluginInstanceSourceDataResponseOrBuilder.java @@ -0,0 +1,27 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/plugin_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ManagePluginInstanceSourceDataResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse) + com.google.protobuf.MessageOrBuilder {} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerConfig.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerConfig.java new file mode 100644 index 000000000000..0ee211221d50 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerConfig.java @@ -0,0 +1,2659 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * MCP-specific server configuration.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.McpServerConfig} + */ +@com.google.protobuf.Generated +public final class McpServerConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.McpServerConfig) + McpServerConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "McpServerConfig"); + } + + // Use McpServerConfig.newBuilder() to construct. + private McpServerConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private McpServerConfig() { + tools_ = java.util.Collections.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.McpServerConfig.class, + com.google.cloud.apihub.v1.McpServerConfig.Builder.class); + } + + public interface McpToolConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.McpServerConfig.McpToolConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +     * Required. Caller-supplied identifier for the tool; each tool must have a
                      +     * unique identifier. This will be by used by agents to invoke the tool.
                      +     * Tool ID must be unique across all tools in the given MCP server
                      +     * configuration.
                      +     * 
                      + * + * string tool_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The toolId. + */ + java.lang.String getToolId(); + + /** + * + * + *
                      +     * Required. Caller-supplied identifier for the tool; each tool must have a
                      +     * unique identifier. This will be by used by agents to invoke the tool.
                      +     * Tool ID must be unique across all tools in the given MCP server
                      +     * configuration.
                      +     * 
                      + * + * string tool_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for toolId. + */ + com.google.protobuf.ByteString getToolIdBytes(); + + /** + * + * + *
                      +     * Required. Description of what the tool does and how it is used.
                      +     * Description serves as key reference for the agent to know about the tool
                      +     * capabilities.
                      +     * 
                      + * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
                      +     * Required. Description of what the tool does and how it is used.
                      +     * Description serves as key reference for the agent to know about the tool
                      +     * capabilities.
                      +     * 
                      + * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
                      +     * Required. The API Hub operation this tool exposes. Each tool
                      +     * wraps exactly one operation; callers that want to expose multiple
                      +     * operations should declare multiple tools.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the operation field is set. + */ + boolean hasOperation(); + + /** + * + * + *
                      +     * Required. The API Hub operation this tool exposes. Each tool
                      +     * wraps exactly one operation; callers that want to expose multiple
                      +     * operations should declare multiple tools.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The operation. + */ + com.google.cloud.apihub.v1.OperationConfig getOperation(); + + /** + * + * + *
                      +     * Required. The API Hub operation this tool exposes. Each tool
                      +     * wraps exactly one operation; callers that want to expose multiple
                      +     * operations should declare multiple tools.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.apihub.v1.OperationConfigOrBuilder getOperationOrBuilder(); + } + + /** + * + * + *
                      +   * A tool exposed by the MCP server. Each tool wraps exactly one API
                      +   * Hub operation under a caller-supplied identifier.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.McpServerConfig.McpToolConfig} + */ + public static final class McpToolConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.McpServerConfig.McpToolConfig) + McpToolConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "McpToolConfig"); + } + + // Use McpToolConfig.newBuilder() to construct. + private McpToolConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private McpToolConfig() { + toolId_ = ""; + description_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerConfig_McpToolConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerConfig_McpToolConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.class, + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.Builder.class); + } + + private int bitField0_; + public static final int TOOL_ID_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object toolId_ = ""; + + /** + * + * + *
                      +     * Required. Caller-supplied identifier for the tool; each tool must have a
                      +     * unique identifier. This will be by used by agents to invoke the tool.
                      +     * Tool ID must be unique across all tools in the given MCP server
                      +     * configuration.
                      +     * 
                      + * + * string tool_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The toolId. + */ + @java.lang.Override + public java.lang.String getToolId() { + java.lang.Object ref = toolId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + toolId_ = s; + return s; + } + } + + /** + * + * + *
                      +     * Required. Caller-supplied identifier for the tool; each tool must have a
                      +     * unique identifier. This will be by used by agents to invoke the tool.
                      +     * Tool ID must be unique across all tools in the given MCP server
                      +     * configuration.
                      +     * 
                      + * + * string tool_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for toolId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getToolIdBytes() { + java.lang.Object ref = toolId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + toolId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object description_ = ""; + + /** + * + * + *
                      +     * Required. Description of what the tool does and how it is used.
                      +     * Description serves as key reference for the agent to know about the tool
                      +     * capabilities.
                      +     * 
                      + * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + + /** + * + * + *
                      +     * Required. Description of what the tool does and how it is used.
                      +     * Description serves as key reference for the agent to know about the tool
                      +     * capabilities.
                      +     * 
                      + * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int OPERATION_FIELD_NUMBER = 3; + private com.google.cloud.apihub.v1.OperationConfig operation_; + + /** + * + * + *
                      +     * Required. The API Hub operation this tool exposes. Each tool
                      +     * wraps exactly one operation; callers that want to expose multiple
                      +     * operations should declare multiple tools.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the operation field is set. + */ + @java.lang.Override + public boolean hasOperation() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * Required. The API Hub operation this tool exposes. Each tool
                      +     * wraps exactly one operation; callers that want to expose multiple
                      +     * operations should declare multiple tools.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The operation. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig getOperation() { + return operation_ == null + ? com.google.cloud.apihub.v1.OperationConfig.getDefaultInstance() + : operation_; + } + + /** + * + * + *
                      +     * Required. The API Hub operation this tool exposes. Each tool
                      +     * wraps exactly one operation; callers that want to expose multiple
                      +     * operations should declare multiple tools.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfigOrBuilder getOperationOrBuilder() { + return operation_ == null + ? com.google.cloud.apihub.v1.OperationConfig.getDefaultInstance() + : operation_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(toolId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, toolId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, description_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getOperation()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(toolId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, toolId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, description_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getOperation()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig other = + (com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig) obj; + + if (!getToolId().equals(other.getToolId())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (hasOperation() != other.hasOperation()) return false; + if (hasOperation()) { + if (!getOperation().equals(other.getOperation())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TOOL_ID_FIELD_NUMBER; + hash = (53 * hash) + getToolId().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + if (hasOperation()) { + hash = (37 * hash) + OPERATION_FIELD_NUMBER; + hash = (53 * hash) + getOperation().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +     * A tool exposed by the MCP server. Each tool wraps exactly one API
                      +     * Hub operation under a caller-supplied identifier.
                      +     * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.McpServerConfig.McpToolConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.McpServerConfig.McpToolConfig) + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerConfig_McpToolConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerConfig_McpToolConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.class, + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetOperationFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + toolId_ = ""; + description_ = ""; + operation_ = null; + if (operationBuilder_ != null) { + operationBuilder_.dispose(); + operationBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerConfig_McpToolConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig build() { + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig buildPartial() { + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig result = + new com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.toolId_ = toolId_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.description_ = description_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.operation_ = operationBuilder_ == null ? operation_ : operationBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig) { + return mergeFrom((com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig other) { + if (other == com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.getDefaultInstance()) + return this; + if (!other.getToolId().isEmpty()) { + toolId_ = other.toolId_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasOperation()) { + mergeOperation(other.getOperation()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + toolId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetOperationFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object toolId_ = ""; + + /** + * + * + *
                      +       * Required. Caller-supplied identifier for the tool; each tool must have a
                      +       * unique identifier. This will be by used by agents to invoke the tool.
                      +       * Tool ID must be unique across all tools in the given MCP server
                      +       * configuration.
                      +       * 
                      + * + * string tool_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The toolId. + */ + public java.lang.String getToolId() { + java.lang.Object ref = toolId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + toolId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +       * Required. Caller-supplied identifier for the tool; each tool must have a
                      +       * unique identifier. This will be by used by agents to invoke the tool.
                      +       * Tool ID must be unique across all tools in the given MCP server
                      +       * configuration.
                      +       * 
                      + * + * string tool_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for toolId. + */ + public com.google.protobuf.ByteString getToolIdBytes() { + java.lang.Object ref = toolId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + toolId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +       * Required. Caller-supplied identifier for the tool; each tool must have a
                      +       * unique identifier. This will be by used by agents to invoke the tool.
                      +       * Tool ID must be unique across all tools in the given MCP server
                      +       * configuration.
                      +       * 
                      + * + * string tool_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The toolId to set. + * @return This builder for chaining. + */ + public Builder setToolId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + toolId_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. Caller-supplied identifier for the tool; each tool must have a
                      +       * unique identifier. This will be by used by agents to invoke the tool.
                      +       * Tool ID must be unique across all tools in the given MCP server
                      +       * configuration.
                      +       * 
                      + * + * string tool_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearToolId() { + toolId_ = getDefaultInstance().getToolId(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. Caller-supplied identifier for the tool; each tool must have a
                      +       * unique identifier. This will be by used by agents to invoke the tool.
                      +       * Tool ID must be unique across all tools in the given MCP server
                      +       * configuration.
                      +       * 
                      + * + * string tool_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for toolId to set. + * @return This builder for chaining. + */ + public Builder setToolIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + toolId_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + + /** + * + * + *
                      +       * Required. Description of what the tool does and how it is used.
                      +       * Description serves as key reference for the agent to know about the tool
                      +       * capabilities.
                      +       * 
                      + * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +       * Required. Description of what the tool does and how it is used.
                      +       * Description serves as key reference for the agent to know about the tool
                      +       * capabilities.
                      +       * 
                      + * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +       * Required. Description of what the tool does and how it is used.
                      +       * Description serves as key reference for the agent to know about the tool
                      +       * capabilities.
                      +       * 
                      + * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + description_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. Description of what the tool does and how it is used.
                      +       * Description serves as key reference for the agent to know about the tool
                      +       * capabilities.
                      +       * 
                      + * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + description_ = getDefaultInstance().getDescription(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. Description of what the tool does and how it is used.
                      +       * Description serves as key reference for the agent to know about the tool
                      +       * capabilities.
                      +       * 
                      + * + * string description = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.cloud.apihub.v1.OperationConfig operation_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationConfig, + com.google.cloud.apihub.v1.OperationConfig.Builder, + com.google.cloud.apihub.v1.OperationConfigOrBuilder> + operationBuilder_; + + /** + * + * + *
                      +       * Required. The API Hub operation this tool exposes. Each tool
                      +       * wraps exactly one operation; callers that want to expose multiple
                      +       * operations should declare multiple tools.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the operation field is set. + */ + public boolean hasOperation() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +       * Required. The API Hub operation this tool exposes. Each tool
                      +       * wraps exactly one operation; callers that want to expose multiple
                      +       * operations should declare multiple tools.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The operation. + */ + public com.google.cloud.apihub.v1.OperationConfig getOperation() { + if (operationBuilder_ == null) { + return operation_ == null + ? com.google.cloud.apihub.v1.OperationConfig.getDefaultInstance() + : operation_; + } else { + return operationBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +       * Required. The API Hub operation this tool exposes. Each tool
                      +       * wraps exactly one operation; callers that want to expose multiple
                      +       * operations should declare multiple tools.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setOperation(com.google.cloud.apihub.v1.OperationConfig value) { + if (operationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + operation_ = value; + } else { + operationBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. The API Hub operation this tool exposes. Each tool
                      +       * wraps exactly one operation; callers that want to expose multiple
                      +       * operations should declare multiple tools.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setOperation( + com.google.cloud.apihub.v1.OperationConfig.Builder builderForValue) { + if (operationBuilder_ == null) { + operation_ = builderForValue.build(); + } else { + operationBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. The API Hub operation this tool exposes. Each tool
                      +       * wraps exactly one operation; callers that want to expose multiple
                      +       * operations should declare multiple tools.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeOperation(com.google.cloud.apihub.v1.OperationConfig value) { + if (operationBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && operation_ != null + && operation_ != com.google.cloud.apihub.v1.OperationConfig.getDefaultInstance()) { + getOperationBuilder().mergeFrom(value); + } else { + operation_ = value; + } + } else { + operationBuilder_.mergeFrom(value); + } + if (operation_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +       * Required. The API Hub operation this tool exposes. Each tool
                      +       * wraps exactly one operation; callers that want to expose multiple
                      +       * operations should declare multiple tools.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearOperation() { + bitField0_ = (bitField0_ & ~0x00000004); + operation_ = null; + if (operationBuilder_ != null) { + operationBuilder_.dispose(); + operationBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. The API Hub operation this tool exposes. Each tool
                      +       * wraps exactly one operation; callers that want to expose multiple
                      +       * operations should declare multiple tools.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.OperationConfig.Builder getOperationBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetOperationFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +       * Required. The API Hub operation this tool exposes. Each tool
                      +       * wraps exactly one operation; callers that want to expose multiple
                      +       * operations should declare multiple tools.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.OperationConfigOrBuilder getOperationOrBuilder() { + if (operationBuilder_ != null) { + return operationBuilder_.getMessageOrBuilder(); + } else { + return operation_ == null + ? com.google.cloud.apihub.v1.OperationConfig.getDefaultInstance() + : operation_; + } + } + + /** + * + * + *
                      +       * Required. The API Hub operation this tool exposes. Each tool
                      +       * wraps exactly one operation; callers that want to expose multiple
                      +       * operations should declare multiple tools.
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.OperationConfig operation = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationConfig, + com.google.cloud.apihub.v1.OperationConfig.Builder, + com.google.cloud.apihub.v1.OperationConfigOrBuilder> + internalGetOperationFieldBuilder() { + if (operationBuilder_ == null) { + operationBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationConfig, + com.google.cloud.apihub.v1.OperationConfig.Builder, + com.google.cloud.apihub.v1.OperationConfigOrBuilder>( + getOperation(), getParentForChildren(), isClean()); + operation_ = null; + } + return operationBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.McpServerConfig.McpToolConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.McpServerConfig.McpToolConfig) + private static final com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig(); + } + + public static com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public McpToolConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int targetCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object target_; + + public enum TargetCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + APIGEE_X_TARGET_DETAILS(2), + TARGET_NOT_SET(0); + private final int value; + + private TargetCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static TargetCase valueOf(int value) { + return forNumber(value); + } + + public static TargetCase forNumber(int value) { + switch (value) { + case 2: + return APIGEE_X_TARGET_DETAILS; + case 0: + return TARGET_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public TargetCase getTargetCase() { + return TargetCase.forNumber(targetCase_); + } + + public static final int APIGEE_X_TARGET_DETAILS_FIELD_NUMBER = 2; + + /** + * + * + *
                      +   * Optional. The target Apigee X configuration.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the apigeeXTargetDetails field is set. + */ + @java.lang.Override + public boolean hasApigeeXTargetDetails() { + return targetCase_ == 2; + } + + /** + * + * + *
                      +   * Optional. The target Apigee X configuration.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The apigeeXTargetDetails. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails getApigeeXTargetDetails() { + if (targetCase_ == 2) { + return (com.google.cloud.apihub.v1.ApigeeXTargetDetails) target_; + } + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } + + /** + * + * + *
                      +   * Optional. The target Apigee X configuration.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder + getApigeeXTargetDetailsOrBuilder() { + if (targetCase_ == 2) { + return (com.google.cloud.apihub.v1.ApigeeXTargetDetails) target_; + } + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } + + public static final int TOOLS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List tools_; + + /** + * + * + *
                      +   * Required. The tools to expose on the MCP server.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public java.util.List getToolsList() { + return tools_; + } + + /** + * + * + *
                      +   * Required. The tools to expose on the MCP server.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public java.util.List + getToolsOrBuilderList() { + return tools_; + } + + /** + * + * + *
                      +   * Required. The tools to expose on the MCP server.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public int getToolsCount() { + return tools_.size(); + } + + /** + * + * + *
                      +   * Required. The tools to expose on the MCP server.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig getTools(int index) { + return tools_.get(index); + } + + /** + * + * + *
                      +   * Required. The tools to expose on the MCP server.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig.McpToolConfigOrBuilder getToolsOrBuilder( + int index) { + return tools_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < tools_.size(); i++) { + output.writeMessage(1, tools_.get(i)); + } + if (targetCase_ == 2) { + output.writeMessage(2, (com.google.cloud.apihub.v1.ApigeeXTargetDetails) target_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < tools_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, tools_.get(i)); + } + if (targetCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.apihub.v1.ApigeeXTargetDetails) target_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.McpServerConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.McpServerConfig other = + (com.google.cloud.apihub.v1.McpServerConfig) obj; + + if (!getToolsList().equals(other.getToolsList())) return false; + if (!getTargetCase().equals(other.getTargetCase())) return false; + switch (targetCase_) { + case 2: + if (!getApigeeXTargetDetails().equals(other.getApigeeXTargetDetails())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getToolsCount() > 0) { + hash = (37 * hash) + TOOLS_FIELD_NUMBER; + hash = (53 * hash) + getToolsList().hashCode(); + } + switch (targetCase_) { + case 2: + hash = (37 * hash) + APIGEE_X_TARGET_DETAILS_FIELD_NUMBER; + hash = (53 * hash) + getApigeeXTargetDetails().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpServerConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.McpServerConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * MCP-specific server configuration.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.McpServerConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.McpServerConfig) + com.google.cloud.apihub.v1.McpServerConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.McpServerConfig.class, + com.google.cloud.apihub.v1.McpServerConfig.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.McpServerConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (apigeeXTargetDetailsBuilder_ != null) { + apigeeXTargetDetailsBuilder_.clear(); + } + if (toolsBuilder_ == null) { + tools_ = java.util.Collections.emptyList(); + } else { + tools_ = null; + toolsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000002); + targetCase_ = 0; + target_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.McpServerConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig build() { + com.google.cloud.apihub.v1.McpServerConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig buildPartial() { + com.google.cloud.apihub.v1.McpServerConfig result = + new com.google.cloud.apihub.v1.McpServerConfig(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.cloud.apihub.v1.McpServerConfig result) { + if (toolsBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0)) { + tools_ = java.util.Collections.unmodifiableList(tools_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.tools_ = tools_; + } else { + result.tools_ = toolsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.apihub.v1.McpServerConfig result) { + int from_bitField0_ = bitField0_; + } + + private void buildPartialOneofs(com.google.cloud.apihub.v1.McpServerConfig result) { + result.targetCase_ = targetCase_; + result.target_ = this.target_; + if (targetCase_ == 2 && apigeeXTargetDetailsBuilder_ != null) { + result.target_ = apigeeXTargetDetailsBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.McpServerConfig) { + return mergeFrom((com.google.cloud.apihub.v1.McpServerConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.McpServerConfig other) { + if (other == com.google.cloud.apihub.v1.McpServerConfig.getDefaultInstance()) return this; + if (toolsBuilder_ == null) { + if (!other.tools_.isEmpty()) { + if (tools_.isEmpty()) { + tools_ = other.tools_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureToolsIsMutable(); + tools_.addAll(other.tools_); + } + onChanged(); + } + } else { + if (!other.tools_.isEmpty()) { + if (toolsBuilder_.isEmpty()) { + toolsBuilder_.dispose(); + toolsBuilder_ = null; + tools_ = other.tools_; + bitField0_ = (bitField0_ & ~0x00000002); + toolsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetToolsFieldBuilder() + : null; + } else { + toolsBuilder_.addAllMessages(other.tools_); + } + } + } + switch (other.getTargetCase()) { + case APIGEE_X_TARGET_DETAILS: + { + mergeApigeeXTargetDetails(other.getApigeeXTargetDetails()); + break; + } + case TARGET_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig m = + input.readMessage( + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.parser(), + extensionRegistry); + if (toolsBuilder_ == null) { + ensureToolsIsMutable(); + tools_.add(m); + } else { + toolsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetApigeeXTargetDetailsFieldBuilder().getBuilder(), extensionRegistry); + targetCase_ = 2; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int targetCase_ = 0; + private java.lang.Object target_; + + public TargetCase getTargetCase() { + return TargetCase.forNumber(targetCase_); + } + + public Builder clearTarget() { + targetCase_ = 0; + target_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXTargetDetails, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder, + com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder> + apigeeXTargetDetailsBuilder_; + + /** + * + * + *
                      +     * Optional. The target Apigee X configuration.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the apigeeXTargetDetails field is set. + */ + @java.lang.Override + public boolean hasApigeeXTargetDetails() { + return targetCase_ == 2; + } + + /** + * + * + *
                      +     * Optional. The target Apigee X configuration.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The apigeeXTargetDetails. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails getApigeeXTargetDetails() { + if (apigeeXTargetDetailsBuilder_ == null) { + if (targetCase_ == 2) { + return (com.google.cloud.apihub.v1.ApigeeXTargetDetails) target_; + } + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } else { + if (targetCase_ == 2) { + return apigeeXTargetDetailsBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Optional. The target Apigee X configuration.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setApigeeXTargetDetails(com.google.cloud.apihub.v1.ApigeeXTargetDetails value) { + if (apigeeXTargetDetailsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + target_ = value; + onChanged(); + } else { + apigeeXTargetDetailsBuilder_.setMessage(value); + } + targetCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * Optional. The target Apigee X configuration.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setApigeeXTargetDetails( + com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder builderForValue) { + if (apigeeXTargetDetailsBuilder_ == null) { + target_ = builderForValue.build(); + onChanged(); + } else { + apigeeXTargetDetailsBuilder_.setMessage(builderForValue.build()); + } + targetCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * Optional. The target Apigee X configuration.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeApigeeXTargetDetails( + com.google.cloud.apihub.v1.ApigeeXTargetDetails value) { + if (apigeeXTargetDetailsBuilder_ == null) { + if (targetCase_ == 2 + && target_ != com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance()) { + target_ = + com.google.cloud.apihub.v1.ApigeeXTargetDetails.newBuilder( + (com.google.cloud.apihub.v1.ApigeeXTargetDetails) target_) + .mergeFrom(value) + .buildPartial(); + } else { + target_ = value; + } + onChanged(); + } else { + if (targetCase_ == 2) { + apigeeXTargetDetailsBuilder_.mergeFrom(value); + } else { + apigeeXTargetDetailsBuilder_.setMessage(value); + } + } + targetCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * Optional. The target Apigee X configuration.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearApigeeXTargetDetails() { + if (apigeeXTargetDetailsBuilder_ == null) { + if (targetCase_ == 2) { + targetCase_ = 0; + target_ = null; + onChanged(); + } + } else { + if (targetCase_ == 2) { + targetCase_ = 0; + target_ = null; + } + apigeeXTargetDetailsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The target Apigee X configuration.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder + getApigeeXTargetDetailsBuilder() { + return internalGetApigeeXTargetDetailsFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The target Apigee X configuration.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder + getApigeeXTargetDetailsOrBuilder() { + if ((targetCase_ == 2) && (apigeeXTargetDetailsBuilder_ != null)) { + return apigeeXTargetDetailsBuilder_.getMessageOrBuilder(); + } else { + if (targetCase_ == 2) { + return (com.google.cloud.apihub.v1.ApigeeXTargetDetails) target_; + } + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Optional. The target Apigee X configuration.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXTargetDetails, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder, + com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder> + internalGetApigeeXTargetDetailsFieldBuilder() { + if (apigeeXTargetDetailsBuilder_ == null) { + if (!(targetCase_ == 2)) { + target_ = com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } + apigeeXTargetDetailsBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXTargetDetails, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder, + com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder>( + (com.google.cloud.apihub.v1.ApigeeXTargetDetails) target_, + getParentForChildren(), + isClean()); + target_ = null; + } + targetCase_ = 2; + onChanged(); + return apigeeXTargetDetailsBuilder_; + } + + private java.util.List tools_ = + java.util.Collections.emptyList(); + + private void ensureToolsIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + tools_ = + new java.util.ArrayList( + tools_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig, + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.Builder, + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfigOrBuilder> + toolsBuilder_; + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List getToolsList() { + if (toolsBuilder_ == null) { + return java.util.Collections.unmodifiableList(tools_); + } else { + return toolsBuilder_.getMessageList(); + } + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public int getToolsCount() { + if (toolsBuilder_ == null) { + return tools_.size(); + } else { + return toolsBuilder_.getCount(); + } + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig getTools(int index) { + if (toolsBuilder_ == null) { + return tools_.get(index); + } else { + return toolsBuilder_.getMessage(index); + } + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setTools( + int index, com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig value) { + if (toolsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureToolsIsMutable(); + tools_.set(index, value); + onChanged(); + } else { + toolsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setTools( + int index, + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.Builder builderForValue) { + if (toolsBuilder_ == null) { + ensureToolsIsMutable(); + tools_.set(index, builderForValue.build()); + onChanged(); + } else { + toolsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addTools(com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig value) { + if (toolsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureToolsIsMutable(); + tools_.add(value); + onChanged(); + } else { + toolsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addTools( + int index, com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig value) { + if (toolsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureToolsIsMutable(); + tools_.add(index, value); + onChanged(); + } else { + toolsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addTools( + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.Builder builderForValue) { + if (toolsBuilder_ == null) { + ensureToolsIsMutable(); + tools_.add(builderForValue.build()); + onChanged(); + } else { + toolsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addTools( + int index, + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.Builder builderForValue) { + if (toolsBuilder_ == null) { + ensureToolsIsMutable(); + tools_.add(index, builderForValue.build()); + onChanged(); + } else { + toolsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addAllTools( + java.lang.Iterable + values) { + if (toolsBuilder_ == null) { + ensureToolsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, tools_); + onChanged(); + } else { + toolsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearTools() { + if (toolsBuilder_ == null) { + tools_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + toolsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder removeTools(int index) { + if (toolsBuilder_ == null) { + ensureToolsIsMutable(); + tools_.remove(index); + onChanged(); + } else { + toolsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.Builder getToolsBuilder( + int index) { + return internalGetToolsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.McpServerConfig.McpToolConfigOrBuilder getToolsOrBuilder( + int index) { + if (toolsBuilder_ == null) { + return tools_.get(index); + } else { + return toolsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List< + ? extends com.google.cloud.apihub.v1.McpServerConfig.McpToolConfigOrBuilder> + getToolsOrBuilderList() { + if (toolsBuilder_ != null) { + return toolsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(tools_); + } + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.Builder addToolsBuilder() { + return internalGetToolsFieldBuilder() + .addBuilder( + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.getDefaultInstance()); + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.Builder addToolsBuilder( + int index) { + return internalGetToolsFieldBuilder() + .addBuilder( + index, com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.getDefaultInstance()); + } + + /** + * + * + *
                      +     * Required. The tools to expose on the MCP server.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List + getToolsBuilderList() { + return internalGetToolsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig, + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.Builder, + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfigOrBuilder> + internalGetToolsFieldBuilder() { + if (toolsBuilder_ == null) { + toolsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig, + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig.Builder, + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfigOrBuilder>( + tools_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); + tools_ = null; + } + return toolsBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.McpServerConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.McpServerConfig) + private static final com.google.cloud.apihub.v1.McpServerConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.McpServerConfig(); + } + + public static com.google.cloud.apihub.v1.McpServerConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public McpServerConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerConfigOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerConfigOrBuilder.java new file mode 100644 index 000000000000..f9648848b145 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerConfigOrBuilder.java @@ -0,0 +1,139 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface McpServerConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.McpServerConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Optional. The target Apigee X configuration.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the apigeeXTargetDetails field is set. + */ + boolean hasApigeeXTargetDetails(); + + /** + * + * + *
                      +   * Optional. The target Apigee X configuration.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The apigeeXTargetDetails. + */ + com.google.cloud.apihub.v1.ApigeeXTargetDetails getApigeeXTargetDetails(); + + /** + * + * + *
                      +   * Optional. The target Apigee X configuration.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_target_details = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder getApigeeXTargetDetailsOrBuilder(); + + /** + * + * + *
                      +   * Required. The tools to expose on the MCP server.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + java.util.List getToolsList(); + + /** + * + * + *
                      +   * Required. The tools to expose on the MCP server.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfig getTools(int index); + + /** + * + * + *
                      +   * Required. The tools to expose on the MCP server.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + int getToolsCount(); + + /** + * + * + *
                      +   * Required. The tools to expose on the MCP server.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + java.util.List + getToolsOrBuilderList(); + + /** + * + * + *
                      +   * Required. The tools to expose on the MCP server.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.McpServerConfig.McpToolConfig tools = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.apihub.v1.McpServerConfig.McpToolConfigOrBuilder getToolsOrBuilder(int index); + + com.google.cloud.apihub.v1.McpServerConfig.TargetCase getTargetCase(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerDetails.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerDetails.java new file mode 100644 index 000000000000..8d4c476c9395 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerDetails.java @@ -0,0 +1,798 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Result of the
                      + * [ApiHub.ConfigureAndDeployServer][google.cloud.apihub.v1.ApiHub.ConfigureAndDeployServer]
                      + * method for MCP servers.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.McpServerDetails} + */ +@com.google.protobuf.Generated +public final class McpServerDetails extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.McpServerDetails) + McpServerDetailsOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "McpServerDetails"); + } + + // Use McpServerDetails.newBuilder() to construct. + private McpServerDetails(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private McpServerDetails() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerDetails_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerDetails_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.McpServerDetails.class, + com.google.cloud.apihub.v1.McpServerDetails.Builder.class); + } + + private int detailsCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object details_; + + public enum DetailsCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + APIGEE_X_DETAILS(1), + DETAILS_NOT_SET(0); + private final int value; + + private DetailsCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static DetailsCase valueOf(int value) { + return forNumber(value); + } + + public static DetailsCase forNumber(int value) { + switch (value) { + case 1: + return APIGEE_X_DETAILS; + case 0: + return DETAILS_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public DetailsCase getDetailsCase() { + return DetailsCase.forNumber(detailsCase_); + } + + public static final int APIGEE_X_DETAILS_FIELD_NUMBER = 1; + + /** + * + * + *
                      +   * Details of the Apigee X deployment.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + * + * @return Whether the apigeeXDetails field is set. + */ + @java.lang.Override + public boolean hasApigeeXDetails() { + return detailsCase_ == 1; + } + + /** + * + * + *
                      +   * Details of the Apigee X deployment.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + * + * @return The apigeeXDetails. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails getApigeeXDetails() { + if (detailsCase_ == 1) { + return (com.google.cloud.apihub.v1.ApigeeXTargetDetails) details_; + } + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } + + /** + * + * + *
                      +   * Details of the Apigee X deployment.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder getApigeeXDetailsOrBuilder() { + if (detailsCase_ == 1) { + return (com.google.cloud.apihub.v1.ApigeeXTargetDetails) details_; + } + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (detailsCase_ == 1) { + output.writeMessage(1, (com.google.cloud.apihub.v1.ApigeeXTargetDetails) details_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (detailsCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.cloud.apihub.v1.ApigeeXTargetDetails) details_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.McpServerDetails)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.McpServerDetails other = + (com.google.cloud.apihub.v1.McpServerDetails) obj; + + if (!getDetailsCase().equals(other.getDetailsCase())) return false; + switch (detailsCase_) { + case 1: + if (!getApigeeXDetails().equals(other.getApigeeXDetails())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (detailsCase_) { + case 1: + hash = (37 * hash) + APIGEE_X_DETAILS_FIELD_NUMBER; + hash = (53 * hash) + getApigeeXDetails().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpServerDetails parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.McpServerDetails prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Result of the
                      +   * [ApiHub.ConfigureAndDeployServer][google.cloud.apihub.v1.ApiHub.ConfigureAndDeployServer]
                      +   * method for MCP servers.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.McpServerDetails} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.McpServerDetails) + com.google.cloud.apihub.v1.McpServerDetailsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerDetails_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerDetails_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.McpServerDetails.class, + com.google.cloud.apihub.v1.McpServerDetails.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.McpServerDetails.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (apigeeXDetailsBuilder_ != null) { + apigeeXDetailsBuilder_.clear(); + } + detailsCase_ = 0; + details_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_McpServerDetails_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerDetails getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.McpServerDetails.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerDetails build() { + com.google.cloud.apihub.v1.McpServerDetails result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerDetails buildPartial() { + com.google.cloud.apihub.v1.McpServerDetails result = + new com.google.cloud.apihub.v1.McpServerDetails(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.McpServerDetails result) { + int from_bitField0_ = bitField0_; + } + + private void buildPartialOneofs(com.google.cloud.apihub.v1.McpServerDetails result) { + result.detailsCase_ = detailsCase_; + result.details_ = this.details_; + if (detailsCase_ == 1 && apigeeXDetailsBuilder_ != null) { + result.details_ = apigeeXDetailsBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.McpServerDetails) { + return mergeFrom((com.google.cloud.apihub.v1.McpServerDetails) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.McpServerDetails other) { + if (other == com.google.cloud.apihub.v1.McpServerDetails.getDefaultInstance()) return this; + switch (other.getDetailsCase()) { + case APIGEE_X_DETAILS: + { + mergeApigeeXDetails(other.getApigeeXDetails()); + break; + } + case DETAILS_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetApigeeXDetailsFieldBuilder().getBuilder(), extensionRegistry); + detailsCase_ = 1; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int detailsCase_ = 0; + private java.lang.Object details_; + + public DetailsCase getDetailsCase() { + return DetailsCase.forNumber(detailsCase_); + } + + public Builder clearDetails() { + detailsCase_ = 0; + details_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXTargetDetails, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder, + com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder> + apigeeXDetailsBuilder_; + + /** + * + * + *
                      +     * Details of the Apigee X deployment.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + * + * @return Whether the apigeeXDetails field is set. + */ + @java.lang.Override + public boolean hasApigeeXDetails() { + return detailsCase_ == 1; + } + + /** + * + * + *
                      +     * Details of the Apigee X deployment.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + * + * @return The apigeeXDetails. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetails getApigeeXDetails() { + if (apigeeXDetailsBuilder_ == null) { + if (detailsCase_ == 1) { + return (com.google.cloud.apihub.v1.ApigeeXTargetDetails) details_; + } + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } else { + if (detailsCase_ == 1) { + return apigeeXDetailsBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Details of the Apigee X deployment.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + */ + public Builder setApigeeXDetails(com.google.cloud.apihub.v1.ApigeeXTargetDetails value) { + if (apigeeXDetailsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + details_ = value; + onChanged(); + } else { + apigeeXDetailsBuilder_.setMessage(value); + } + detailsCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * Details of the Apigee X deployment.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + */ + public Builder setApigeeXDetails( + com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder builderForValue) { + if (apigeeXDetailsBuilder_ == null) { + details_ = builderForValue.build(); + onChanged(); + } else { + apigeeXDetailsBuilder_.setMessage(builderForValue.build()); + } + detailsCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * Details of the Apigee X deployment.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + */ + public Builder mergeApigeeXDetails(com.google.cloud.apihub.v1.ApigeeXTargetDetails value) { + if (apigeeXDetailsBuilder_ == null) { + if (detailsCase_ == 1 + && details_ != com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance()) { + details_ = + com.google.cloud.apihub.v1.ApigeeXTargetDetails.newBuilder( + (com.google.cloud.apihub.v1.ApigeeXTargetDetails) details_) + .mergeFrom(value) + .buildPartial(); + } else { + details_ = value; + } + onChanged(); + } else { + if (detailsCase_ == 1) { + apigeeXDetailsBuilder_.mergeFrom(value); + } else { + apigeeXDetailsBuilder_.setMessage(value); + } + } + detailsCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * Details of the Apigee X deployment.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + */ + public Builder clearApigeeXDetails() { + if (apigeeXDetailsBuilder_ == null) { + if (detailsCase_ == 1) { + detailsCase_ = 0; + details_ = null; + onChanged(); + } + } else { + if (detailsCase_ == 1) { + detailsCase_ = 0; + details_ = null; + } + apigeeXDetailsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Details of the Apigee X deployment.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + */ + public com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder getApigeeXDetailsBuilder() { + return internalGetApigeeXDetailsFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Details of the Apigee X deployment.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder getApigeeXDetailsOrBuilder() { + if ((detailsCase_ == 1) && (apigeeXDetailsBuilder_ != null)) { + return apigeeXDetailsBuilder_.getMessageOrBuilder(); + } else { + if (detailsCase_ == 1) { + return (com.google.cloud.apihub.v1.ApigeeXTargetDetails) details_; + } + return com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Details of the Apigee X deployment.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXTargetDetails, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder, + com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder> + internalGetApigeeXDetailsFieldBuilder() { + if (apigeeXDetailsBuilder_ == null) { + if (!(detailsCase_ == 1)) { + details_ = com.google.cloud.apihub.v1.ApigeeXTargetDetails.getDefaultInstance(); + } + apigeeXDetailsBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApigeeXTargetDetails, + com.google.cloud.apihub.v1.ApigeeXTargetDetails.Builder, + com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder>( + (com.google.cloud.apihub.v1.ApigeeXTargetDetails) details_, + getParentForChildren(), + isClean()); + details_ = null; + } + detailsCase_ = 1; + onChanged(); + return apigeeXDetailsBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.McpServerDetails) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.McpServerDetails) + private static final com.google.cloud.apihub.v1.McpServerDetails DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.McpServerDetails(); + } + + public static com.google.cloud.apihub.v1.McpServerDetails getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public McpServerDetails parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpServerDetails getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerDetailsOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerDetailsOrBuilder.java new file mode 100644 index 000000000000..2301576a5ad4 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpServerDetailsOrBuilder.java @@ -0,0 +1,67 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface McpServerDetailsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.McpServerDetails) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Details of the Apigee X deployment.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + * + * @return Whether the apigeeXDetails field is set. + */ + boolean hasApigeeXDetails(); + + /** + * + * + *
                      +   * Details of the Apigee X deployment.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + * + * @return The apigeeXDetails. + */ + com.google.cloud.apihub.v1.ApigeeXTargetDetails getApigeeXDetails(); + + /** + * + * + *
                      +   * Details of the Apigee X deployment.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApigeeXTargetDetails apigee_x_details = 1; + */ + com.google.cloud.apihub.v1.ApigeeXTargetDetailsOrBuilder getApigeeXDetailsOrBuilder(); + + com.google.cloud.apihub.v1.McpServerDetails.DetailsCase getDetailsCase(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpTool.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpTool.java new file mode 100644 index 000000000000..6bb08de23840 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpTool.java @@ -0,0 +1,1926 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/common_fields.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Details describing an MCP Tool.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.McpTool} + */ +@com.google.protobuf.Generated +public final class McpTool extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.McpTool) + McpToolOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "McpTool"); + } + + // Use McpTool.newBuilder() to construct. + private McpTool(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private McpTool() { + name_ = ""; + title_ = ""; + description_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_McpTool_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_McpTool_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.McpTool.class, + com.google.cloud.apihub.v1.McpTool.Builder.class); + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
                      +   * Required. The name of the tool, unique within its parent scope (version).
                      +   * 
                      + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The name of the tool, unique within its parent scope (version).
                      +   * 
                      + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TITLE_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object title_ = ""; + + /** + * + * + *
                      +   * Optional. Optional title for the tool.
                      +   * 
                      + * + * string title = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The title. + */ + @java.lang.Override + public java.lang.String getTitle() { + java.lang.Object ref = title_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + title_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Optional. Optional title for the tool.
                      +   * 
                      + * + * string title = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for title. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTitleBytes() { + java.lang.Object ref = title_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + title_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object description_ = ""; + + /** + * + * + *
                      +   * Optional. Description of what the tool does.
                      +   * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Optional. Description of what the tool does.
                      +   * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ANNOTATIONS_FIELD_NUMBER = 4; + private com.google.cloud.apihub.v1.ToolAnnotations annotations_; + + /** + * + * + *
                      +   * Optional. Optional annotations for the tool.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the annotations field is set. + */ + @java.lang.Override + public boolean hasAnnotations() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Optional. Optional annotations for the tool.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The annotations. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ToolAnnotations getAnnotations() { + return annotations_ == null + ? com.google.cloud.apihub.v1.ToolAnnotations.getDefaultInstance() + : annotations_; + } + + /** + * + * + *
                      +   * Optional. Optional annotations for the tool.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ToolAnnotationsOrBuilder getAnnotationsOrBuilder() { + return annotations_ == null + ? com.google.cloud.apihub.v1.ToolAnnotations.getDefaultInstance() + : annotations_; + } + + public static final int INPUT_SCHEMA_FIELD_NUMBER = 5; + private com.google.cloud.apihub.v1.OperationSchema inputSchema_; + + /** + * + * + *
                      +   * Optional. Input schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the inputSchema field is set. + */ + @java.lang.Override + public boolean hasInputSchema() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Optional. Input schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The inputSchema. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.OperationSchema getInputSchema() { + return inputSchema_ == null + ? com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance() + : inputSchema_; + } + + /** + * + * + *
                      +   * Optional. Input schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.OperationSchemaOrBuilder getInputSchemaOrBuilder() { + return inputSchema_ == null + ? com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance() + : inputSchema_; + } + + public static final int OUTPUT_SCHEMA_FIELD_NUMBER = 6; + private com.google.cloud.apihub.v1.OperationSchema outputSchema_; + + /** + * + * + *
                      +   * Optional. Output schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the outputSchema field is set. + */ + @java.lang.Override + public boolean hasOutputSchema() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +   * Optional. Output schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The outputSchema. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.OperationSchema getOutputSchema() { + return outputSchema_ == null + ? com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance() + : outputSchema_; + } + + /** + * + * + *
                      +   * Optional. Output schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.OperationSchemaOrBuilder getOutputSchemaOrBuilder() { + return outputSchema_ == null + ? com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance() + : outputSchema_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(title_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, title_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, description_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(4, getAnnotations()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(5, getInputSchema()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(6, getOutputSchema()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(title_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, title_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, description_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getAnnotations()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getInputSchema()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getOutputSchema()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.McpTool)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.McpTool other = (com.google.cloud.apihub.v1.McpTool) obj; + + if (!getName().equals(other.getName())) return false; + if (!getTitle().equals(other.getTitle())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (hasAnnotations() != other.hasAnnotations()) return false; + if (hasAnnotations()) { + if (!getAnnotations().equals(other.getAnnotations())) return false; + } + if (hasInputSchema() != other.hasInputSchema()) return false; + if (hasInputSchema()) { + if (!getInputSchema().equals(other.getInputSchema())) return false; + } + if (hasOutputSchema() != other.hasOutputSchema()) return false; + if (hasOutputSchema()) { + if (!getOutputSchema().equals(other.getOutputSchema())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + TITLE_FIELD_NUMBER; + hash = (53 * hash) + getTitle().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + if (hasAnnotations()) { + hash = (37 * hash) + ANNOTATIONS_FIELD_NUMBER; + hash = (53 * hash) + getAnnotations().hashCode(); + } + if (hasInputSchema()) { + hash = (37 * hash) + INPUT_SCHEMA_FIELD_NUMBER; + hash = (53 * hash) + getInputSchema().hashCode(); + } + if (hasOutputSchema()) { + hash = (37 * hash) + OUTPUT_SCHEMA_FIELD_NUMBER; + hash = (53 * hash) + getOutputSchema().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.McpTool parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpTool parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpTool parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpTool parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpTool parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.McpTool parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpTool parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpTool parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpTool parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpTool parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.McpTool parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.McpTool parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.McpTool prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Details describing an MCP Tool.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.McpTool} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.McpTool) + com.google.cloud.apihub.v1.McpToolOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_McpTool_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_McpTool_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.McpTool.class, + com.google.cloud.apihub.v1.McpTool.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.McpTool.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetAnnotationsFieldBuilder(); + internalGetInputSchemaFieldBuilder(); + internalGetOutputSchemaFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + title_ = ""; + description_ = ""; + annotations_ = null; + if (annotationsBuilder_ != null) { + annotationsBuilder_.dispose(); + annotationsBuilder_ = null; + } + inputSchema_ = null; + if (inputSchemaBuilder_ != null) { + inputSchemaBuilder_.dispose(); + inputSchemaBuilder_ = null; + } + outputSchema_ = null; + if (outputSchemaBuilder_ != null) { + outputSchemaBuilder_.dispose(); + outputSchemaBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_McpTool_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpTool getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.McpTool.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpTool build() { + com.google.cloud.apihub.v1.McpTool result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpTool buildPartial() { + com.google.cloud.apihub.v1.McpTool result = new com.google.cloud.apihub.v1.McpTool(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.McpTool result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.title_ = title_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.description_ = description_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000008) != 0)) { + result.annotations_ = + annotationsBuilder_ == null ? annotations_ : annotationsBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.inputSchema_ = + inputSchemaBuilder_ == null ? inputSchema_ : inputSchemaBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.outputSchema_ = + outputSchemaBuilder_ == null ? outputSchema_ : outputSchemaBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.McpTool) { + return mergeFrom((com.google.cloud.apihub.v1.McpTool) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.McpTool other) { + if (other == com.google.cloud.apihub.v1.McpTool.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getTitle().isEmpty()) { + title_ = other.title_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.hasAnnotations()) { + mergeAnnotations(other.getAnnotations()); + } + if (other.hasInputSchema()) { + mergeInputSchema(other.getInputSchema()); + } + if (other.hasOutputSchema()) { + mergeOutputSchema(other.getOutputSchema()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + title_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetAnnotationsFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + input.readMessage( + internalGetInputSchemaFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + input.readMessage( + internalGetOutputSchemaFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
                      +     * Required. The name of the tool, unique within its parent scope (version).
                      +     * 
                      + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the tool, unique within its parent scope (version).
                      +     * 
                      + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the tool, unique within its parent scope (version).
                      +     * 
                      + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the tool, unique within its parent scope (version).
                      +     * 
                      + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the tool, unique within its parent scope (version).
                      +     * 
                      + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object title_ = ""; + + /** + * + * + *
                      +     * Optional. Optional title for the tool.
                      +     * 
                      + * + * string title = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The title. + */ + public java.lang.String getTitle() { + java.lang.Object ref = title_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + title_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Optional. Optional title for the tool.
                      +     * 
                      + * + * string title = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for title. + */ + public com.google.protobuf.ByteString getTitleBytes() { + java.lang.Object ref = title_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + title_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Optional. Optional title for the tool.
                      +     * 
                      + * + * string title = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The title to set. + * @return This builder for chaining. + */ + public Builder setTitle(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + title_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Optional title for the tool.
                      +     * 
                      + * + * string title = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearTitle() { + title_ = getDefaultInstance().getTitle(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Optional title for the tool.
                      +     * 
                      + * + * string title = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for title to set. + * @return This builder for chaining. + */ + public Builder setTitleBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + title_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + + /** + * + * + *
                      +     * Optional. Description of what the tool does.
                      +     * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Optional. Description of what the tool does.
                      +     * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Optional. Description of what the tool does.
                      +     * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + description_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Description of what the tool does.
                      +     * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + description_ = getDefaultInstance().getDescription(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Description of what the tool does.
                      +     * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private com.google.cloud.apihub.v1.ToolAnnotations annotations_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ToolAnnotations, + com.google.cloud.apihub.v1.ToolAnnotations.Builder, + com.google.cloud.apihub.v1.ToolAnnotationsOrBuilder> + annotationsBuilder_; + + /** + * + * + *
                      +     * Optional. Optional annotations for the tool.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the annotations field is set. + */ + public boolean hasAnnotations() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
                      +     * Optional. Optional annotations for the tool.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The annotations. + */ + public com.google.cloud.apihub.v1.ToolAnnotations getAnnotations() { + if (annotationsBuilder_ == null) { + return annotations_ == null + ? com.google.cloud.apihub.v1.ToolAnnotations.getDefaultInstance() + : annotations_; + } else { + return annotationsBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. Optional annotations for the tool.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setAnnotations(com.google.cloud.apihub.v1.ToolAnnotations value) { + if (annotationsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + annotations_ = value; + } else { + annotationsBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Optional annotations for the tool.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setAnnotations( + com.google.cloud.apihub.v1.ToolAnnotations.Builder builderForValue) { + if (annotationsBuilder_ == null) { + annotations_ = builderForValue.build(); + } else { + annotationsBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Optional annotations for the tool.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeAnnotations(com.google.cloud.apihub.v1.ToolAnnotations value) { + if (annotationsBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && annotations_ != null + && annotations_ != com.google.cloud.apihub.v1.ToolAnnotations.getDefaultInstance()) { + getAnnotationsBuilder().mergeFrom(value); + } else { + annotations_ = value; + } + } else { + annotationsBuilder_.mergeFrom(value); + } + if (annotations_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. Optional annotations for the tool.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearAnnotations() { + bitField0_ = (bitField0_ & ~0x00000008); + annotations_ = null; + if (annotationsBuilder_ != null) { + annotationsBuilder_.dispose(); + annotationsBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Optional annotations for the tool.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.ToolAnnotations.Builder getAnnotationsBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetAnnotationsFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. Optional annotations for the tool.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.ToolAnnotationsOrBuilder getAnnotationsOrBuilder() { + if (annotationsBuilder_ != null) { + return annotationsBuilder_.getMessageOrBuilder(); + } else { + return annotations_ == null + ? com.google.cloud.apihub.v1.ToolAnnotations.getDefaultInstance() + : annotations_; + } + } + + /** + * + * + *
                      +     * Optional. Optional annotations for the tool.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ToolAnnotations, + com.google.cloud.apihub.v1.ToolAnnotations.Builder, + com.google.cloud.apihub.v1.ToolAnnotationsOrBuilder> + internalGetAnnotationsFieldBuilder() { + if (annotationsBuilder_ == null) { + annotationsBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ToolAnnotations, + com.google.cloud.apihub.v1.ToolAnnotations.Builder, + com.google.cloud.apihub.v1.ToolAnnotationsOrBuilder>( + getAnnotations(), getParentForChildren(), isClean()); + annotations_ = null; + } + return annotationsBuilder_; + } + + private com.google.cloud.apihub.v1.OperationSchema inputSchema_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationSchema, + com.google.cloud.apihub.v1.OperationSchema.Builder, + com.google.cloud.apihub.v1.OperationSchemaOrBuilder> + inputSchemaBuilder_; + + /** + * + * + *
                      +     * Optional. Input schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the inputSchema field is set. + */ + public boolean hasInputSchema() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
                      +     * Optional. Input schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The inputSchema. + */ + public com.google.cloud.apihub.v1.OperationSchema getInputSchema() { + if (inputSchemaBuilder_ == null) { + return inputSchema_ == null + ? com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance() + : inputSchema_; + } else { + return inputSchemaBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. Input schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setInputSchema(com.google.cloud.apihub.v1.OperationSchema value) { + if (inputSchemaBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + inputSchema_ = value; + } else { + inputSchemaBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Input schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setInputSchema( + com.google.cloud.apihub.v1.OperationSchema.Builder builderForValue) { + if (inputSchemaBuilder_ == null) { + inputSchema_ = builderForValue.build(); + } else { + inputSchemaBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Input schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeInputSchema(com.google.cloud.apihub.v1.OperationSchema value) { + if (inputSchemaBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && inputSchema_ != null + && inputSchema_ != com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance()) { + getInputSchemaBuilder().mergeFrom(value); + } else { + inputSchema_ = value; + } + } else { + inputSchemaBuilder_.mergeFrom(value); + } + if (inputSchema_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. Input schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearInputSchema() { + bitField0_ = (bitField0_ & ~0x00000010); + inputSchema_ = null; + if (inputSchemaBuilder_ != null) { + inputSchemaBuilder_.dispose(); + inputSchemaBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Input schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.OperationSchema.Builder getInputSchemaBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetInputSchemaFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. Input schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.OperationSchemaOrBuilder getInputSchemaOrBuilder() { + if (inputSchemaBuilder_ != null) { + return inputSchemaBuilder_.getMessageOrBuilder(); + } else { + return inputSchema_ == null + ? com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance() + : inputSchema_; + } + } + + /** + * + * + *
                      +     * Optional. Input schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationSchema, + com.google.cloud.apihub.v1.OperationSchema.Builder, + com.google.cloud.apihub.v1.OperationSchemaOrBuilder> + internalGetInputSchemaFieldBuilder() { + if (inputSchemaBuilder_ == null) { + inputSchemaBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationSchema, + com.google.cloud.apihub.v1.OperationSchema.Builder, + com.google.cloud.apihub.v1.OperationSchemaOrBuilder>( + getInputSchema(), getParentForChildren(), isClean()); + inputSchema_ = null; + } + return inputSchemaBuilder_; + } + + private com.google.cloud.apihub.v1.OperationSchema outputSchema_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationSchema, + com.google.cloud.apihub.v1.OperationSchema.Builder, + com.google.cloud.apihub.v1.OperationSchemaOrBuilder> + outputSchemaBuilder_; + + /** + * + * + *
                      +     * Optional. Output schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the outputSchema field is set. + */ + public boolean hasOutputSchema() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
                      +     * Optional. Output schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The outputSchema. + */ + public com.google.cloud.apihub.v1.OperationSchema getOutputSchema() { + if (outputSchemaBuilder_ == null) { + return outputSchema_ == null + ? com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance() + : outputSchema_; + } else { + return outputSchemaBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. Output schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setOutputSchema(com.google.cloud.apihub.v1.OperationSchema value) { + if (outputSchemaBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + outputSchema_ = value; + } else { + outputSchemaBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Output schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setOutputSchema( + com.google.cloud.apihub.v1.OperationSchema.Builder builderForValue) { + if (outputSchemaBuilder_ == null) { + outputSchema_ = builderForValue.build(); + } else { + outputSchemaBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Output schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeOutputSchema(com.google.cloud.apihub.v1.OperationSchema value) { + if (outputSchemaBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && outputSchema_ != null + && outputSchema_ != com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance()) { + getOutputSchemaBuilder().mergeFrom(value); + } else { + outputSchema_ = value; + } + } else { + outputSchemaBuilder_.mergeFrom(value); + } + if (outputSchema_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. Output schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearOutputSchema() { + bitField0_ = (bitField0_ & ~0x00000020); + outputSchema_ = null; + if (outputSchemaBuilder_ != null) { + outputSchemaBuilder_.dispose(); + outputSchemaBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Output schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.OperationSchema.Builder getOutputSchemaBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetOutputSchemaFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. Output schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.OperationSchemaOrBuilder getOutputSchemaOrBuilder() { + if (outputSchemaBuilder_ != null) { + return outputSchemaBuilder_.getMessageOrBuilder(); + } else { + return outputSchema_ == null + ? com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance() + : outputSchema_; + } + } + + /** + * + * + *
                      +     * Optional. Output schema for the operation. This can be parsed only from MCP
                      +     * schema type.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationSchema, + com.google.cloud.apihub.v1.OperationSchema.Builder, + com.google.cloud.apihub.v1.OperationSchemaOrBuilder> + internalGetOutputSchemaFieldBuilder() { + if (outputSchemaBuilder_ == null) { + outputSchemaBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationSchema, + com.google.cloud.apihub.v1.OperationSchema.Builder, + com.google.cloud.apihub.v1.OperationSchemaOrBuilder>( + getOutputSchema(), getParentForChildren(), isClean()); + outputSchema_ = null; + } + return outputSchemaBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.McpTool) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.McpTool) + private static final com.google.cloud.apihub.v1.McpTool DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.McpTool(); + } + + public static com.google.cloud.apihub.v1.McpTool getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public McpTool parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.McpTool getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpToolOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpToolOrBuilder.java new file mode 100644 index 000000000000..63b5e356a2a9 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/McpToolOrBuilder.java @@ -0,0 +1,241 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/common_fields.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface McpToolOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.McpTool) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The name of the tool, unique within its parent scope (version).
                      +   * 
                      + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
                      +   * Required. The name of the tool, unique within its parent scope (version).
                      +   * 
                      + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
                      +   * Optional. Optional title for the tool.
                      +   * 
                      + * + * string title = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The title. + */ + java.lang.String getTitle(); + + /** + * + * + *
                      +   * Optional. Optional title for the tool.
                      +   * 
                      + * + * string title = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for title. + */ + com.google.protobuf.ByteString getTitleBytes(); + + /** + * + * + *
                      +   * Optional. Description of what the tool does.
                      +   * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
                      +   * Optional. Description of what the tool does.
                      +   * 
                      + * + * string description = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
                      +   * Optional. Optional annotations for the tool.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the annotations field is set. + */ + boolean hasAnnotations(); + + /** + * + * + *
                      +   * Optional. Optional annotations for the tool.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The annotations. + */ + com.google.cloud.apihub.v1.ToolAnnotations getAnnotations(); + + /** + * + * + *
                      +   * Optional. Optional annotations for the tool.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ToolAnnotations annotations = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.ToolAnnotationsOrBuilder getAnnotationsOrBuilder(); + + /** + * + * + *
                      +   * Optional. Input schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the inputSchema field is set. + */ + boolean hasInputSchema(); + + /** + * + * + *
                      +   * Optional. Input schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The inputSchema. + */ + com.google.cloud.apihub.v1.OperationSchema getInputSchema(); + + /** + * + * + *
                      +   * Optional. Input schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema input_schema = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.OperationSchemaOrBuilder getInputSchemaOrBuilder(); + + /** + * + * + *
                      +   * Optional. Output schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the outputSchema field is set. + */ + boolean hasOutputSchema(); + + /** + * + * + *
                      +   * Optional. Output schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The outputSchema. + */ + com.google.cloud.apihub.v1.OperationSchema getOutputSchema(); + + /** + * + * + *
                      +   * Optional. Output schema for the operation. This can be parsed only from MCP
                      +   * schema type.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.OperationSchema output_schema = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.OperationSchemaOrBuilder getOutputSchemaOrBuilder(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationConfig.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationConfig.java new file mode 100644 index 000000000000..9f63aa01c1e0 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationConfig.java @@ -0,0 +1,2143 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * API hub Operation config.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.OperationConfig} + */ +@com.google.protobuf.Generated +public final class OperationConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.OperationConfig) + OperationConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "OperationConfig"); + } + + // Use OperationConfig.newBuilder() to construct. + private OperationConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private OperationConfig() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_OperationConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_OperationConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.OperationConfig.class, + com.google.cloud.apihub.v1.OperationConfig.Builder.class); + } + + public interface HttpOperationConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +     * Required. Spec resource name:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +     * 
                      + * + * + * string spec = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The spec. + */ + java.lang.String getSpec(); + + /** + * + * + *
                      +     * Required. Spec resource name:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +     * 
                      + * + * + * string spec = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for spec. + */ + com.google.protobuf.ByteString getSpecBytes(); + + /** + * + * + *
                      +     * Required. HTTP path of the operation within the referenced spec.
                      +     * Match is exact (no template substitution): the path here must
                      +     * appear verbatim on an APIOperationRevision belonging to the spec.
                      +     * 
                      + * + * string path = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The path. + */ + java.lang.String getPath(); + + /** + * + * + *
                      +     * Required. HTTP path of the operation within the referenced spec.
                      +     * Match is exact (no template substitution): the path here must
                      +     * appear verbatim on an APIOperationRevision belonging to the spec.
                      +     * 
                      + * + * string path = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for path. + */ + com.google.protobuf.ByteString getPathBytes(); + + /** + * + * + *
                      +     * Required. HTTP method of the operation within the referenced spec.
                      +     * (GET / PUT / POST / DELETE / OPTIONS / HEAD / PATCH / TRACE).
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.HttpOperation.Method method = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for method. + */ + int getMethodValue(); + + /** + * + * + *
                      +     * Required. HTTP method of the operation within the referenced spec.
                      +     * (GET / PUT / POST / DELETE / OPTIONS / HEAD / PATCH / TRACE).
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.HttpOperation.Method method = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The method. + */ + com.google.cloud.apihub.v1.HttpOperation.Method getMethod(); + } + + /** + * + * + *
                      +   * Identifies a single API Hub operation by spec resource name + HTTP
                      +   * path + HTTP method.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.OperationConfig.HttpOperationConfig} + */ + public static final class HttpOperationConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) + HttpOperationConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "HttpOperationConfig"); + } + + // Use HttpOperationConfig.newBuilder() to construct. + private HttpOperationConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private HttpOperationConfig() { + spec_ = ""; + path_ = ""; + method_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_OperationConfig_HttpOperationConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_OperationConfig_HttpOperationConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.class, + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.Builder.class); + } + + public static final int SPEC_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object spec_ = ""; + + /** + * + * + *
                      +     * Required. Spec resource name:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +     * 
                      + * + * + * string spec = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The spec. + */ + @java.lang.Override + public java.lang.String getSpec() { + java.lang.Object ref = spec_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + spec_ = s; + return s; + } + } + + /** + * + * + *
                      +     * Required. Spec resource name:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +     * 
                      + * + * + * string spec = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for spec. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSpecBytes() { + java.lang.Object ref = spec_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + spec_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PATH_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object path_ = ""; + + /** + * + * + *
                      +     * Required. HTTP path of the operation within the referenced spec.
                      +     * Match is exact (no template substitution): the path here must
                      +     * appear verbatim on an APIOperationRevision belonging to the spec.
                      +     * 
                      + * + * string path = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The path. + */ + @java.lang.Override + public java.lang.String getPath() { + java.lang.Object ref = path_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + path_ = s; + return s; + } + } + + /** + * + * + *
                      +     * Required. HTTP path of the operation within the referenced spec.
                      +     * Match is exact (no template substitution): the path here must
                      +     * appear verbatim on an APIOperationRevision belonging to the spec.
                      +     * 
                      + * + * string path = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for path. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPathBytes() { + java.lang.Object ref = path_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + path_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int METHOD_FIELD_NUMBER = 3; + private int method_ = 0; + + /** + * + * + *
                      +     * Required. HTTP method of the operation within the referenced spec.
                      +     * (GET / PUT / POST / DELETE / OPTIONS / HEAD / PATCH / TRACE).
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.HttpOperation.Method method = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for method. + */ + @java.lang.Override + public int getMethodValue() { + return method_; + } + + /** + * + * + *
                      +     * Required. HTTP method of the operation within the referenced spec.
                      +     * (GET / PUT / POST / DELETE / OPTIONS / HEAD / PATCH / TRACE).
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.HttpOperation.Method method = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The method. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.HttpOperation.Method getMethod() { + com.google.cloud.apihub.v1.HttpOperation.Method result = + com.google.cloud.apihub.v1.HttpOperation.Method.forNumber(method_); + return result == null ? com.google.cloud.apihub.v1.HttpOperation.Method.UNRECOGNIZED : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(spec_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, spec_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(path_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, path_); + } + if (method_ + != com.google.cloud.apihub.v1.HttpOperation.Method.METHOD_UNSPECIFIED.getNumber()) { + output.writeEnum(3, method_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(spec_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, spec_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(path_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, path_); + } + if (method_ + != com.google.cloud.apihub.v1.HttpOperation.Method.METHOD_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, method_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig other = + (com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) obj; + + if (!getSpec().equals(other.getSpec())) return false; + if (!getPath().equals(other.getPath())) return false; + if (method_ != other.method_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + SPEC_FIELD_NUMBER; + hash = (53 * hash) + getSpec().hashCode(); + hash = (37 * hash) + PATH_FIELD_NUMBER; + hash = (53 * hash) + getPath().hashCode(); + hash = (37 * hash) + METHOD_FIELD_NUMBER; + hash = (53 * hash) + method_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +     * Identifies a single API Hub operation by spec resource name + HTTP
                      +     * path + HTTP method.
                      +     * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.OperationConfig.HttpOperationConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_OperationConfig_HttpOperationConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_OperationConfig_HttpOperationConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.class, + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + spec_ = ""; + path_ = ""; + method_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_OperationConfig_HttpOperationConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig + getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig build() { + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig buildPartial() { + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig result = + new com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.spec_ = spec_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.path_ = path_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.method_ = method_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) { + return mergeFrom((com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig other) { + if (other + == com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.getDefaultInstance()) + return this; + if (!other.getSpec().isEmpty()) { + spec_ = other.spec_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getPath().isEmpty()) { + path_ = other.path_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.method_ != 0) { + setMethodValue(other.getMethodValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + spec_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + path_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 24: + { + method_ = input.readEnum(); + bitField0_ |= 0x00000004; + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object spec_ = ""; + + /** + * + * + *
                      +       * Required. Spec resource name:
                      +       * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +       * 
                      + * + * + * string spec = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The spec. + */ + public java.lang.String getSpec() { + java.lang.Object ref = spec_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + spec_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +       * Required. Spec resource name:
                      +       * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +       * 
                      + * + * + * string spec = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for spec. + */ + public com.google.protobuf.ByteString getSpecBytes() { + java.lang.Object ref = spec_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + spec_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +       * Required. Spec resource name:
                      +       * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +       * 
                      + * + * + * string spec = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The spec to set. + * @return This builder for chaining. + */ + public Builder setSpec(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + spec_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. Spec resource name:
                      +       * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +       * 
                      + * + * + * string spec = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearSpec() { + spec_ = getDefaultInstance().getSpec(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. Spec resource name:
                      +       * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}`
                      +       * 
                      + * + * + * string spec = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for spec to set. + * @return This builder for chaining. + */ + public Builder setSpecBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + spec_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object path_ = ""; + + /** + * + * + *
                      +       * Required. HTTP path of the operation within the referenced spec.
                      +       * Match is exact (no template substitution): the path here must
                      +       * appear verbatim on an APIOperationRevision belonging to the spec.
                      +       * 
                      + * + * string path = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The path. + */ + public java.lang.String getPath() { + java.lang.Object ref = path_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + path_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +       * Required. HTTP path of the operation within the referenced spec.
                      +       * Match is exact (no template substitution): the path here must
                      +       * appear verbatim on an APIOperationRevision belonging to the spec.
                      +       * 
                      + * + * string path = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for path. + */ + public com.google.protobuf.ByteString getPathBytes() { + java.lang.Object ref = path_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + path_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +       * Required. HTTP path of the operation within the referenced spec.
                      +       * Match is exact (no template substitution): the path here must
                      +       * appear verbatim on an APIOperationRevision belonging to the spec.
                      +       * 
                      + * + * string path = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The path to set. + * @return This builder for chaining. + */ + public Builder setPath(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + path_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. HTTP path of the operation within the referenced spec.
                      +       * Match is exact (no template substitution): the path here must
                      +       * appear verbatim on an APIOperationRevision belonging to the spec.
                      +       * 
                      + * + * string path = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearPath() { + path_ = getDefaultInstance().getPath(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. HTTP path of the operation within the referenced spec.
                      +       * Match is exact (no template substitution): the path here must
                      +       * appear verbatim on an APIOperationRevision belonging to the spec.
                      +       * 
                      + * + * string path = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for path to set. + * @return This builder for chaining. + */ + public Builder setPathBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + path_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private int method_ = 0; + + /** + * + * + *
                      +       * Required. HTTP method of the operation within the referenced spec.
                      +       * (GET / PUT / POST / DELETE / OPTIONS / HEAD / PATCH / TRACE).
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.HttpOperation.Method method = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for method. + */ + @java.lang.Override + public int getMethodValue() { + return method_; + } + + /** + * + * + *
                      +       * Required. HTTP method of the operation within the referenced spec.
                      +       * (GET / PUT / POST / DELETE / OPTIONS / HEAD / PATCH / TRACE).
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.HttpOperation.Method method = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The enum numeric value on the wire for method to set. + * @return This builder for chaining. + */ + public Builder setMethodValue(int value) { + method_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. HTTP method of the operation within the referenced spec.
                      +       * (GET / PUT / POST / DELETE / OPTIONS / HEAD / PATCH / TRACE).
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.HttpOperation.Method method = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The method. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.HttpOperation.Method getMethod() { + com.google.cloud.apihub.v1.HttpOperation.Method result = + com.google.cloud.apihub.v1.HttpOperation.Method.forNumber(method_); + return result == null + ? com.google.cloud.apihub.v1.HttpOperation.Method.UNRECOGNIZED + : result; + } + + /** + * + * + *
                      +       * Required. HTTP method of the operation within the referenced spec.
                      +       * (GET / PUT / POST / DELETE / OPTIONS / HEAD / PATCH / TRACE).
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.HttpOperation.Method method = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The method to set. + * @return This builder for chaining. + */ + public Builder setMethod(com.google.cloud.apihub.v1.HttpOperation.Method value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000004; + method_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. HTTP method of the operation within the referenced spec.
                      +       * (GET / PUT / POST / DELETE / OPTIONS / HEAD / PATCH / TRACE).
                      +       * 
                      + * + * + * .google.cloud.apihub.v1.HttpOperation.Method method = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearMethod() { + bitField0_ = (bitField0_ & ~0x00000004); + method_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) + private static final com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig(); + } + + public static com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public HttpOperationConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int identifierCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object identifier_; + + public enum IdentifierCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + OPERATION(1), + HTTP_OPERATION(2), + IDENTIFIER_NOT_SET(0); + private final int value; + + private IdentifierCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static IdentifierCase valueOf(int value) { + return forNumber(value); + } + + public static IdentifierCase forNumber(int value) { + switch (value) { + case 1: + return OPERATION; + case 2: + return HTTP_OPERATION; + case 0: + return IDENTIFIER_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public IdentifierCase getIdentifierCase() { + return IdentifierCase.forNumber(identifierCase_); + } + + public static final int OPERATION_FIELD_NUMBER = 1; + + /** + * + * + *
                      +   * Full API Hub operation resource name:
                      +   * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +   * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @return Whether the operation field is set. + */ + public boolean hasOperation() { + return identifierCase_ == 1; + } + + /** + * + * + *
                      +   * Full API Hub operation resource name:
                      +   * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +   * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @return The operation. + */ + public java.lang.String getOperation() { + java.lang.Object ref = ""; + if (identifierCase_ == 1) { + ref = identifier_; + } + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (identifierCase_ == 1) { + identifier_ = s; + } + return s; + } + } + + /** + * + * + *
                      +   * Full API Hub operation resource name:
                      +   * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +   * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for operation. + */ + public com.google.protobuf.ByteString getOperationBytes() { + java.lang.Object ref = ""; + if (identifierCase_ == 1) { + ref = identifier_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (identifierCase_ == 1) { + identifier_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int HTTP_OPERATION_FIELD_NUMBER = 2; + + /** + * + * + *
                      +   * The HTTP operation config.
                      +   * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + * + * @return Whether the httpOperation field is set. + */ + @java.lang.Override + public boolean hasHttpOperation() { + return identifierCase_ == 2; + } + + /** + * + * + *
                      +   * The HTTP operation config.
                      +   * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + * + * @return The httpOperation. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig getHttpOperation() { + if (identifierCase_ == 2) { + return (com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) identifier_; + } + return com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.getDefaultInstance(); + } + + /** + * + * + *
                      +   * The HTTP operation config.
                      +   * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfigOrBuilder + getHttpOperationOrBuilder() { + if (identifierCase_ == 2) { + return (com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) identifier_; + } + return com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (identifierCase_ == 1) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, identifier_); + } + if (identifierCase_ == 2) { + output.writeMessage( + 2, (com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) identifier_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (identifierCase_ == 1) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, identifier_); + } + if (identifierCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) identifier_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.OperationConfig)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.OperationConfig other = + (com.google.cloud.apihub.v1.OperationConfig) obj; + + if (!getIdentifierCase().equals(other.getIdentifierCase())) return false; + switch (identifierCase_) { + case 1: + if (!getOperation().equals(other.getOperation())) return false; + break; + case 2: + if (!getHttpOperation().equals(other.getHttpOperation())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (identifierCase_) { + case 1: + hash = (37 * hash) + OPERATION_FIELD_NUMBER; + hash = (53 * hash) + getOperation().hashCode(); + break; + case 2: + hash = (37 * hash) + HTTP_OPERATION_FIELD_NUMBER; + hash = (53 * hash) + getHttpOperation().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.OperationConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.OperationConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.OperationConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.OperationConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.OperationConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.OperationConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.OperationConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.OperationConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * API hub Operation config.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.OperationConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.OperationConfig) + com.google.cloud.apihub.v1.OperationConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_OperationConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_OperationConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.OperationConfig.class, + com.google.cloud.apihub.v1.OperationConfig.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.OperationConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (httpOperationBuilder_ != null) { + httpOperationBuilder_.clear(); + } + identifierCase_ = 0; + identifier_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_OperationConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.OperationConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig build() { + com.google.cloud.apihub.v1.OperationConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig buildPartial() { + com.google.cloud.apihub.v1.OperationConfig result = + new com.google.cloud.apihub.v1.OperationConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.OperationConfig result) { + int from_bitField0_ = bitField0_; + } + + private void buildPartialOneofs(com.google.cloud.apihub.v1.OperationConfig result) { + result.identifierCase_ = identifierCase_; + result.identifier_ = this.identifier_; + if (identifierCase_ == 2 && httpOperationBuilder_ != null) { + result.identifier_ = httpOperationBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.OperationConfig) { + return mergeFrom((com.google.cloud.apihub.v1.OperationConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.OperationConfig other) { + if (other == com.google.cloud.apihub.v1.OperationConfig.getDefaultInstance()) return this; + switch (other.getIdentifierCase()) { + case OPERATION: + { + identifierCase_ = 1; + identifier_ = other.identifier_; + onChanged(); + break; + } + case HTTP_OPERATION: + { + mergeHttpOperation(other.getHttpOperation()); + break; + } + case IDENTIFIER_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + identifierCase_ = 1; + identifier_ = s; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetHttpOperationFieldBuilder().getBuilder(), extensionRegistry); + identifierCase_ = 2; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int identifierCase_ = 0; + private java.lang.Object identifier_; + + public IdentifierCase getIdentifierCase() { + return IdentifierCase.forNumber(identifierCase_); + } + + public Builder clearIdentifier() { + identifierCase_ = 0; + identifier_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + /** + * + * + *
                      +     * Full API Hub operation resource name:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +     * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @return Whether the operation field is set. + */ + @java.lang.Override + public boolean hasOperation() { + return identifierCase_ == 1; + } + + /** + * + * + *
                      +     * Full API Hub operation resource name:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +     * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @return The operation. + */ + @java.lang.Override + public java.lang.String getOperation() { + java.lang.Object ref = ""; + if (identifierCase_ == 1) { + ref = identifier_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (identifierCase_ == 1) { + identifier_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Full API Hub operation resource name:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +     * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for operation. + */ + @java.lang.Override + public com.google.protobuf.ByteString getOperationBytes() { + java.lang.Object ref = ""; + if (identifierCase_ == 1) { + ref = identifier_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (identifierCase_ == 1) { + identifier_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Full API Hub operation resource name:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +     * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The operation to set. + * @return This builder for chaining. + */ + public Builder setOperation(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + identifierCase_ = 1; + identifier_ = value; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Full API Hub operation resource name:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +     * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @return This builder for chaining. + */ + public Builder clearOperation() { + if (identifierCase_ == 1) { + identifierCase_ = 0; + identifier_ = null; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Full API Hub operation resource name:
                      +     * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +     * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The bytes for operation to set. + * @return This builder for chaining. + */ + public Builder setOperationBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + identifierCase_ = 1; + identifier_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig, + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.Builder, + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfigOrBuilder> + httpOperationBuilder_; + + /** + * + * + *
                      +     * The HTTP operation config.
                      +     * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + * + * @return Whether the httpOperation field is set. + */ + @java.lang.Override + public boolean hasHttpOperation() { + return identifierCase_ == 2; + } + + /** + * + * + *
                      +     * The HTTP operation config.
                      +     * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + * + * @return The httpOperation. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig getHttpOperation() { + if (httpOperationBuilder_ == null) { + if (identifierCase_ == 2) { + return (com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) identifier_; + } + return com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.getDefaultInstance(); + } else { + if (identifierCase_ == 2) { + return httpOperationBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * The HTTP operation config.
                      +     * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + */ + public Builder setHttpOperation( + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig value) { + if (httpOperationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + identifier_ = value; + onChanged(); + } else { + httpOperationBuilder_.setMessage(value); + } + identifierCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * The HTTP operation config.
                      +     * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + */ + public Builder setHttpOperation( + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.Builder builderForValue) { + if (httpOperationBuilder_ == null) { + identifier_ = builderForValue.build(); + onChanged(); + } else { + httpOperationBuilder_.setMessage(builderForValue.build()); + } + identifierCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * The HTTP operation config.
                      +     * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + */ + public Builder mergeHttpOperation( + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig value) { + if (httpOperationBuilder_ == null) { + if (identifierCase_ == 2 + && identifier_ + != com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig + .getDefaultInstance()) { + identifier_ = + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.newBuilder( + (com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) identifier_) + .mergeFrom(value) + .buildPartial(); + } else { + identifier_ = value; + } + onChanged(); + } else { + if (identifierCase_ == 2) { + httpOperationBuilder_.mergeFrom(value); + } else { + httpOperationBuilder_.setMessage(value); + } + } + identifierCase_ = 2; + return this; + } + + /** + * + * + *
                      +     * The HTTP operation config.
                      +     * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + */ + public Builder clearHttpOperation() { + if (httpOperationBuilder_ == null) { + if (identifierCase_ == 2) { + identifierCase_ = 0; + identifier_ = null; + onChanged(); + } + } else { + if (identifierCase_ == 2) { + identifierCase_ = 0; + identifier_ = null; + } + httpOperationBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * The HTTP operation config.
                      +     * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + */ + public com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.Builder + getHttpOperationBuilder() { + return internalGetHttpOperationFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * The HTTP operation config.
                      +     * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfigOrBuilder + getHttpOperationOrBuilder() { + if ((identifierCase_ == 2) && (httpOperationBuilder_ != null)) { + return httpOperationBuilder_.getMessageOrBuilder(); + } else { + if (identifierCase_ == 2) { + return (com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) identifier_; + } + return com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * The HTTP operation config.
                      +     * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig, + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.Builder, + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfigOrBuilder> + internalGetHttpOperationFieldBuilder() { + if (httpOperationBuilder_ == null) { + if (!(identifierCase_ == 2)) { + identifier_ = + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.getDefaultInstance(); + } + httpOperationBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig, + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig.Builder, + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfigOrBuilder>( + (com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig) identifier_, + getParentForChildren(), + isClean()); + identifier_ = null; + } + identifierCase_ = 2; + onChanged(); + return httpOperationBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.OperationConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.OperationConfig) + private static final com.google.cloud.apihub.v1.OperationConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.OperationConfig(); + } + + public static com.google.cloud.apihub.v1.OperationConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public OperationConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationConfigOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationConfigOrBuilder.java new file mode 100644 index 000000000000..0c4ddd18e3e3 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationConfigOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface OperationConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.OperationConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Full API Hub operation resource name:
                      +   * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +   * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @return Whether the operation field is set. + */ + boolean hasOperation(); + + /** + * + * + *
                      +   * Full API Hub operation resource name:
                      +   * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +   * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @return The operation. + */ + java.lang.String getOperation(); + + /** + * + * + *
                      +   * Full API Hub operation resource name:
                      +   * `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`
                      +   * 
                      + * + * string operation = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for operation. + */ + com.google.protobuf.ByteString getOperationBytes(); + + /** + * + * + *
                      +   * The HTTP operation config.
                      +   * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + * + * @return Whether the httpOperation field is set. + */ + boolean hasHttpOperation(); + + /** + * + * + *
                      +   * The HTTP operation config.
                      +   * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + * + * @return The httpOperation. + */ + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfig getHttpOperation(); + + /** + * + * + *
                      +   * The HTTP operation config.
                      +   * 
                      + * + * .google.cloud.apihub.v1.OperationConfig.HttpOperationConfig http_operation = 2; + */ + com.google.cloud.apihub.v1.OperationConfig.HttpOperationConfigOrBuilder + getHttpOperationOrBuilder(); + + com.google.cloud.apihub.v1.OperationConfig.IdentifierCase getIdentifierCase(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationDetails.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationDetails.java index 29408a27b09d..44ea15a75dfe 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationDetails.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationDetails.java @@ -81,6 +81,7 @@ public enum OperationCase com.google.protobuf.Internal.EnumLite, com.google.protobuf.AbstractMessage.InternalOneOfEnum { HTTP_OPERATION(4), + MCP_TOOL(5), OPERATION_NOT_SET(0); private final int value; @@ -102,6 +103,8 @@ public static OperationCase forNumber(int value) { switch (value) { case 4: return HTTP_OPERATION; + case 5: + return MCP_TOOL; case 0: return OPERATION_NOT_SET; default: @@ -172,6 +175,60 @@ public com.google.cloud.apihub.v1.HttpOperationOrBuilder getHttpOperationOrBuild return com.google.cloud.apihub.v1.HttpOperation.getDefaultInstance(); } + public static final int MCP_TOOL_FIELD_NUMBER = 5; + + /** + * + * + *
                      +   * The MCP Tool Operation.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + * + * @return Whether the mcpTool field is set. + */ + @java.lang.Override + public boolean hasMcpTool() { + return operationCase_ == 5; + } + + /** + * + * + *
                      +   * The MCP Tool Operation.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + * + * @return The mcpTool. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpTool getMcpTool() { + if (operationCase_ == 5) { + return (com.google.cloud.apihub.v1.McpTool) operation_; + } + return com.google.cloud.apihub.v1.McpTool.getDefaultInstance(); + } + + /** + * + * + *
                      +   * The MCP Tool Operation.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpToolOrBuilder getMcpToolOrBuilder() { + if (operationCase_ == 5) { + return (com.google.cloud.apihub.v1.McpTool) operation_; + } + return com.google.cloud.apihub.v1.McpTool.getDefaultInstance(); + } + public static final int DESCRIPTION_FIELD_NUMBER = 1; @SuppressWarnings("serial") @@ -337,6 +394,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (operationCase_ == 4) { output.writeMessage(4, (com.google.cloud.apihub.v1.HttpOperation) operation_); } + if (operationCase_ == 5) { + output.writeMessage(5, (com.google.cloud.apihub.v1.McpTool) operation_); + } getUnknownFields().writeTo(output); } @@ -360,6 +420,11 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 4, (com.google.cloud.apihub.v1.HttpOperation) operation_); } + if (operationCase_ == 5) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, (com.google.cloud.apihub.v1.McpTool) operation_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -387,6 +452,9 @@ public boolean equals(final java.lang.Object obj) { case 4: if (!getHttpOperation().equals(other.getHttpOperation())) return false; break; + case 5: + if (!getMcpTool().equals(other.getMcpTool())) return false; + break; case 0: default: } @@ -414,6 +482,10 @@ public int hashCode() { hash = (37 * hash) + HTTP_OPERATION_FIELD_NUMBER; hash = (53 * hash) + getHttpOperation().hashCode(); break; + case 5: + hash = (37 * hash) + MCP_TOOL_FIELD_NUMBER; + hash = (53 * hash) + getMcpTool().hashCode(); + break; case 0: default: } @@ -569,6 +641,9 @@ public Builder clear() { if (httpOperationBuilder_ != null) { httpOperationBuilder_.clear(); } + if (mcpToolBuilder_ != null) { + mcpToolBuilder_.clear(); + } description_ = ""; documentation_ = null; if (documentationBuilder_ != null) { @@ -615,16 +690,16 @@ public com.google.cloud.apihub.v1.OperationDetails buildPartial() { private void buildPartial0(com.google.cloud.apihub.v1.OperationDetails result) { int from_bitField0_ = bitField0_; - if (((from_bitField0_ & 0x00000002) != 0)) { + if (((from_bitField0_ & 0x00000004) != 0)) { result.description_ = description_; } int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000004) != 0)) { + if (((from_bitField0_ & 0x00000008) != 0)) { result.documentation_ = documentationBuilder_ == null ? documentation_ : documentationBuilder_.build(); to_bitField0_ |= 0x00000001; } - if (((from_bitField0_ & 0x00000008) != 0)) { + if (((from_bitField0_ & 0x00000010) != 0)) { result.deprecated_ = deprecated_; } result.bitField0_ |= to_bitField0_; @@ -636,6 +711,9 @@ private void buildPartialOneofs(com.google.cloud.apihub.v1.OperationDetails resu if (operationCase_ == 4 && httpOperationBuilder_ != null) { result.operation_ = httpOperationBuilder_.build(); } + if (operationCase_ == 5 && mcpToolBuilder_ != null) { + result.operation_ = mcpToolBuilder_.build(); + } } @java.lang.Override @@ -652,7 +730,7 @@ public Builder mergeFrom(com.google.cloud.apihub.v1.OperationDetails other) { if (other == com.google.cloud.apihub.v1.OperationDetails.getDefaultInstance()) return this; if (!other.getDescription().isEmpty()) { description_ = other.description_; - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; onChanged(); } if (other.hasDocumentation()) { @@ -667,6 +745,11 @@ public Builder mergeFrom(com.google.cloud.apihub.v1.OperationDetails other) { mergeHttpOperation(other.getHttpOperation()); break; } + case MCP_TOOL: + { + mergeMcpTool(other.getMcpTool()); + break; + } case OPERATION_NOT_SET: { break; @@ -701,20 +784,20 @@ public Builder mergeFrom( case 10: { description_ = input.readStringRequireUtf8(); - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; break; } // case 10 case 18: { input.readMessage( internalGetDocumentationFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; break; } // case 18 case 24: { deprecated_ = input.readBool(); - bitField0_ |= 0x00000008; + bitField0_ |= 0x00000010; break; } // case 24 case 34: @@ -724,6 +807,12 @@ public Builder mergeFrom( operationCase_ = 4; break; } // case 34 + case 42: + { + input.readMessage(internalGetMcpToolFieldBuilder().getBuilder(), extensionRegistry); + operationCase_ = 5; + break; + } // case 42 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -975,6 +1064,221 @@ public com.google.cloud.apihub.v1.HttpOperationOrBuilder getHttpOperationOrBuild return httpOperationBuilder_; } + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.McpTool, + com.google.cloud.apihub.v1.McpTool.Builder, + com.google.cloud.apihub.v1.McpToolOrBuilder> + mcpToolBuilder_; + + /** + * + * + *
                      +     * The MCP Tool Operation.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + * + * @return Whether the mcpTool field is set. + */ + @java.lang.Override + public boolean hasMcpTool() { + return operationCase_ == 5; + } + + /** + * + * + *
                      +     * The MCP Tool Operation.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + * + * @return The mcpTool. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpTool getMcpTool() { + if (mcpToolBuilder_ == null) { + if (operationCase_ == 5) { + return (com.google.cloud.apihub.v1.McpTool) operation_; + } + return com.google.cloud.apihub.v1.McpTool.getDefaultInstance(); + } else { + if (operationCase_ == 5) { + return mcpToolBuilder_.getMessage(); + } + return com.google.cloud.apihub.v1.McpTool.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * The MCP Tool Operation.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + */ + public Builder setMcpTool(com.google.cloud.apihub.v1.McpTool value) { + if (mcpToolBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + operation_ = value; + onChanged(); + } else { + mcpToolBuilder_.setMessage(value); + } + operationCase_ = 5; + return this; + } + + /** + * + * + *
                      +     * The MCP Tool Operation.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + */ + public Builder setMcpTool(com.google.cloud.apihub.v1.McpTool.Builder builderForValue) { + if (mcpToolBuilder_ == null) { + operation_ = builderForValue.build(); + onChanged(); + } else { + mcpToolBuilder_.setMessage(builderForValue.build()); + } + operationCase_ = 5; + return this; + } + + /** + * + * + *
                      +     * The MCP Tool Operation.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + */ + public Builder mergeMcpTool(com.google.cloud.apihub.v1.McpTool value) { + if (mcpToolBuilder_ == null) { + if (operationCase_ == 5 + && operation_ != com.google.cloud.apihub.v1.McpTool.getDefaultInstance()) { + operation_ = + com.google.cloud.apihub.v1.McpTool.newBuilder( + (com.google.cloud.apihub.v1.McpTool) operation_) + .mergeFrom(value) + .buildPartial(); + } else { + operation_ = value; + } + onChanged(); + } else { + if (operationCase_ == 5) { + mcpToolBuilder_.mergeFrom(value); + } else { + mcpToolBuilder_.setMessage(value); + } + } + operationCase_ = 5; + return this; + } + + /** + * + * + *
                      +     * The MCP Tool Operation.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + */ + public Builder clearMcpTool() { + if (mcpToolBuilder_ == null) { + if (operationCase_ == 5) { + operationCase_ = 0; + operation_ = null; + onChanged(); + } + } else { + if (operationCase_ == 5) { + operationCase_ = 0; + operation_ = null; + } + mcpToolBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * The MCP Tool Operation.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + */ + public com.google.cloud.apihub.v1.McpTool.Builder getMcpToolBuilder() { + return internalGetMcpToolFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * The MCP Tool Operation.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + */ + @java.lang.Override + public com.google.cloud.apihub.v1.McpToolOrBuilder getMcpToolOrBuilder() { + if ((operationCase_ == 5) && (mcpToolBuilder_ != null)) { + return mcpToolBuilder_.getMessageOrBuilder(); + } else { + if (operationCase_ == 5) { + return (com.google.cloud.apihub.v1.McpTool) operation_; + } + return com.google.cloud.apihub.v1.McpTool.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * The MCP Tool Operation.
                      +     * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.McpTool, + com.google.cloud.apihub.v1.McpTool.Builder, + com.google.cloud.apihub.v1.McpToolOrBuilder> + internalGetMcpToolFieldBuilder() { + if (mcpToolBuilder_ == null) { + if (!(operationCase_ == 5)) { + operation_ = com.google.cloud.apihub.v1.McpTool.getDefaultInstance(); + } + mcpToolBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.McpTool, + com.google.cloud.apihub.v1.McpTool.Builder, + com.google.cloud.apihub.v1.McpToolOrBuilder>( + (com.google.cloud.apihub.v1.McpTool) operation_, getParentForChildren(), isClean()); + operation_ = null; + } + operationCase_ = 5; + onChanged(); + return mcpToolBuilder_; + } + private java.lang.Object description_ = ""; /** @@ -1046,7 +1350,7 @@ public Builder setDescription(java.lang.String value) { throw new NullPointerException(); } description_ = value; - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; onChanged(); return this; } @@ -1066,7 +1370,7 @@ public Builder setDescription(java.lang.String value) { */ public Builder clearDescription() { description_ = getDefaultInstance().getDescription(); - bitField0_ = (bitField0_ & ~0x00000002); + bitField0_ = (bitField0_ & ~0x00000004); onChanged(); return this; } @@ -1091,7 +1395,7 @@ public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { } checkByteStringIsUtf8(value); description_ = value; - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; onChanged(); return this; } @@ -1118,7 +1422,7 @@ public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { * @return Whether the documentation field is set. */ public boolean hasDocumentation() { - return ((bitField0_ & 0x00000004) != 0); + return ((bitField0_ & 0x00000008) != 0); } /** @@ -1166,7 +1470,7 @@ public Builder setDocumentation(com.google.cloud.apihub.v1.Documentation value) } else { documentationBuilder_.setMessage(value); } - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; onChanged(); return this; } @@ -1190,7 +1494,7 @@ public Builder setDocumentation( } else { documentationBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; onChanged(); return this; } @@ -1209,7 +1513,7 @@ public Builder setDocumentation( */ public Builder mergeDocumentation(com.google.cloud.apihub.v1.Documentation value) { if (documentationBuilder_ == null) { - if (((bitField0_ & 0x00000004) != 0) + if (((bitField0_ & 0x00000008) != 0) && documentation_ != null && documentation_ != com.google.cloud.apihub.v1.Documentation.getDefaultInstance()) { getDocumentationBuilder().mergeFrom(value); @@ -1220,7 +1524,7 @@ public Builder mergeDocumentation(com.google.cloud.apihub.v1.Documentation value documentationBuilder_.mergeFrom(value); } if (documentation_ != null) { - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; onChanged(); } return this; @@ -1239,7 +1543,7 @@ public Builder mergeDocumentation(com.google.cloud.apihub.v1.Documentation value *
                      */ public Builder clearDocumentation() { - bitField0_ = (bitField0_ & ~0x00000004); + bitField0_ = (bitField0_ & ~0x00000008); documentation_ = null; if (documentationBuilder_ != null) { documentationBuilder_.dispose(); @@ -1262,7 +1566,7 @@ public Builder clearDocumentation() { *
                      */ public com.google.cloud.apihub.v1.Documentation.Builder getDocumentationBuilder() { - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; onChanged(); return internalGetDocumentationFieldBuilder().getBuilder(); } @@ -1353,7 +1657,7 @@ public boolean getDeprecated() { public Builder setDeprecated(boolean value) { deprecated_ = value; - bitField0_ |= 0x00000008; + bitField0_ |= 0x00000010; onChanged(); return this; } @@ -1371,7 +1675,7 @@ public Builder setDeprecated(boolean value) { * @return This builder for chaining. */ public Builder clearDeprecated() { - bitField0_ = (bitField0_ & ~0x00000008); + bitField0_ = (bitField0_ & ~0x00000010); deprecated_ = false; onChanged(); return this; diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationDetailsOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationDetailsOrBuilder.java index 6fd66843c467..1d48fad0935a 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationDetailsOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationDetailsOrBuilder.java @@ -63,6 +63,43 @@ public interface OperationDetailsOrBuilder */ com.google.cloud.apihub.v1.HttpOperationOrBuilder getHttpOperationOrBuilder(); + /** + * + * + *
                      +   * The MCP Tool Operation.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + * + * @return Whether the mcpTool field is set. + */ + boolean hasMcpTool(); + + /** + * + * + *
                      +   * The MCP Tool Operation.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + * + * @return The mcpTool. + */ + com.google.cloud.apihub.v1.McpTool getMcpTool(); + + /** + * + * + *
                      +   * The MCP Tool Operation.
                      +   * 
                      + * + * .google.cloud.apihub.v1.McpTool mcp_tool = 5; + */ + com.google.cloud.apihub.v1.McpToolOrBuilder getMcpToolOrBuilder(); + /** * * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationSchema.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationSchema.java new file mode 100644 index 000000000000..6e2d0ca066bf --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationSchema.java @@ -0,0 +1,801 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/common_fields.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The operation schema needed for an operation.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.OperationSchema} + */ +@com.google.protobuf.Generated +public final class OperationSchema extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.OperationSchema) + OperationSchemaOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "OperationSchema"); + } + + // Use OperationSchema.newBuilder() to construct. + private OperationSchema(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private OperationSchema() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_OperationSchema_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_OperationSchema_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.OperationSchema.class, + com.google.cloud.apihub.v1.OperationSchema.Builder.class); + } + + private int valueCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object value_; + + public enum ValueCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + JSON_SCHEMA(1), + VALUE_NOT_SET(0); + private final int value; + + private ValueCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ValueCase valueOf(int value) { + return forNumber(value); + } + + public static ValueCase forNumber(int value) { + switch (value) { + case 1: + return JSON_SCHEMA; + case 0: + return VALUE_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ValueCase getValueCase() { + return ValueCase.forNumber(valueCase_); + } + + public static final int JSON_SCHEMA_FIELD_NUMBER = 1; + + /** + * + * + *
                      +   * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +   * schema is not supported right now.
                      +   * 
                      + * + * .google.protobuf.Struct json_schema = 1; + * + * @return Whether the jsonSchema field is set. + */ + @java.lang.Override + public boolean hasJsonSchema() { + return valueCase_ == 1; + } + + /** + * + * + *
                      +   * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +   * schema is not supported right now.
                      +   * 
                      + * + * .google.protobuf.Struct json_schema = 1; + * + * @return The jsonSchema. + */ + @java.lang.Override + public com.google.protobuf.Struct getJsonSchema() { + if (valueCase_ == 1) { + return (com.google.protobuf.Struct) value_; + } + return com.google.protobuf.Struct.getDefaultInstance(); + } + + /** + * + * + *
                      +   * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +   * schema is not supported right now.
                      +   * 
                      + * + * .google.protobuf.Struct json_schema = 1; + */ + @java.lang.Override + public com.google.protobuf.StructOrBuilder getJsonSchemaOrBuilder() { + if (valueCase_ == 1) { + return (com.google.protobuf.Struct) value_; + } + return com.google.protobuf.Struct.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (valueCase_ == 1) { + output.writeMessage(1, (com.google.protobuf.Struct) value_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (valueCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.protobuf.Struct) value_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.OperationSchema)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.OperationSchema other = + (com.google.cloud.apihub.v1.OperationSchema) obj; + + if (!getValueCase().equals(other.getValueCase())) return false; + switch (valueCase_) { + case 1: + if (!getJsonSchema().equals(other.getJsonSchema())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (valueCase_) { + case 1: + hash = (37 * hash) + JSON_SCHEMA_FIELD_NUMBER; + hash = (53 * hash) + getJsonSchema().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.OperationSchema parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.OperationSchema parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationSchema parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.OperationSchema parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationSchema parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.OperationSchema parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationSchema parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.OperationSchema parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationSchema parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.OperationSchema parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.OperationSchema parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.OperationSchema parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.OperationSchema prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The operation schema needed for an operation.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.OperationSchema} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.OperationSchema) + com.google.cloud.apihub.v1.OperationSchemaOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_OperationSchema_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_OperationSchema_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.OperationSchema.class, + com.google.cloud.apihub.v1.OperationSchema.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.OperationSchema.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (jsonSchemaBuilder_ != null) { + jsonSchemaBuilder_.clear(); + } + valueCase_ = 0; + value_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_OperationSchema_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationSchema getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationSchema build() { + com.google.cloud.apihub.v1.OperationSchema result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationSchema buildPartial() { + com.google.cloud.apihub.v1.OperationSchema result = + new com.google.cloud.apihub.v1.OperationSchema(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.OperationSchema result) { + int from_bitField0_ = bitField0_; + } + + private void buildPartialOneofs(com.google.cloud.apihub.v1.OperationSchema result) { + result.valueCase_ = valueCase_; + result.value_ = this.value_; + if (valueCase_ == 1 && jsonSchemaBuilder_ != null) { + result.value_ = jsonSchemaBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.OperationSchema) { + return mergeFrom((com.google.cloud.apihub.v1.OperationSchema) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.OperationSchema other) { + if (other == com.google.cloud.apihub.v1.OperationSchema.getDefaultInstance()) return this; + switch (other.getValueCase()) { + case JSON_SCHEMA: + { + mergeJsonSchema(other.getJsonSchema()); + break; + } + case VALUE_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetJsonSchemaFieldBuilder().getBuilder(), extensionRegistry); + valueCase_ = 1; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int valueCase_ = 0; + private java.lang.Object value_; + + public ValueCase getValueCase() { + return ValueCase.forNumber(valueCase_); + } + + public Builder clearValue() { + valueCase_ = 0; + value_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Struct, + com.google.protobuf.Struct.Builder, + com.google.protobuf.StructOrBuilder> + jsonSchemaBuilder_; + + /** + * + * + *
                      +     * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +     * schema is not supported right now.
                      +     * 
                      + * + * .google.protobuf.Struct json_schema = 1; + * + * @return Whether the jsonSchema field is set. + */ + @java.lang.Override + public boolean hasJsonSchema() { + return valueCase_ == 1; + } + + /** + * + * + *
                      +     * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +     * schema is not supported right now.
                      +     * 
                      + * + * .google.protobuf.Struct json_schema = 1; + * + * @return The jsonSchema. + */ + @java.lang.Override + public com.google.protobuf.Struct getJsonSchema() { + if (jsonSchemaBuilder_ == null) { + if (valueCase_ == 1) { + return (com.google.protobuf.Struct) value_; + } + return com.google.protobuf.Struct.getDefaultInstance(); + } else { + if (valueCase_ == 1) { + return jsonSchemaBuilder_.getMessage(); + } + return com.google.protobuf.Struct.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +     * schema is not supported right now.
                      +     * 
                      + * + * .google.protobuf.Struct json_schema = 1; + */ + public Builder setJsonSchema(com.google.protobuf.Struct value) { + if (jsonSchemaBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + value_ = value; + onChanged(); + } else { + jsonSchemaBuilder_.setMessage(value); + } + valueCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +     * schema is not supported right now.
                      +     * 
                      + * + * .google.protobuf.Struct json_schema = 1; + */ + public Builder setJsonSchema(com.google.protobuf.Struct.Builder builderForValue) { + if (jsonSchemaBuilder_ == null) { + value_ = builderForValue.build(); + onChanged(); + } else { + jsonSchemaBuilder_.setMessage(builderForValue.build()); + } + valueCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +     * schema is not supported right now.
                      +     * 
                      + * + * .google.protobuf.Struct json_schema = 1; + */ + public Builder mergeJsonSchema(com.google.protobuf.Struct value) { + if (jsonSchemaBuilder_ == null) { + if (valueCase_ == 1 && value_ != com.google.protobuf.Struct.getDefaultInstance()) { + value_ = + com.google.protobuf.Struct.newBuilder((com.google.protobuf.Struct) value_) + .mergeFrom(value) + .buildPartial(); + } else { + value_ = value; + } + onChanged(); + } else { + if (valueCase_ == 1) { + jsonSchemaBuilder_.mergeFrom(value); + } else { + jsonSchemaBuilder_.setMessage(value); + } + } + valueCase_ = 1; + return this; + } + + /** + * + * + *
                      +     * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +     * schema is not supported right now.
                      +     * 
                      + * + * .google.protobuf.Struct json_schema = 1; + */ + public Builder clearJsonSchema() { + if (jsonSchemaBuilder_ == null) { + if (valueCase_ == 1) { + valueCase_ = 0; + value_ = null; + onChanged(); + } + } else { + if (valueCase_ == 1) { + valueCase_ = 0; + value_ = null; + } + jsonSchemaBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +     * schema is not supported right now.
                      +     * 
                      + * + * .google.protobuf.Struct json_schema = 1; + */ + public com.google.protobuf.Struct.Builder getJsonSchemaBuilder() { + return internalGetJsonSchemaFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +     * schema is not supported right now.
                      +     * 
                      + * + * .google.protobuf.Struct json_schema = 1; + */ + @java.lang.Override + public com.google.protobuf.StructOrBuilder getJsonSchemaOrBuilder() { + if ((valueCase_ == 1) && (jsonSchemaBuilder_ != null)) { + return jsonSchemaBuilder_.getMessageOrBuilder(); + } else { + if (valueCase_ == 1) { + return (com.google.protobuf.Struct) value_; + } + return com.google.protobuf.Struct.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +     * schema is not supported right now.
                      +     * 
                      + * + * .google.protobuf.Struct json_schema = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Struct, + com.google.protobuf.Struct.Builder, + com.google.protobuf.StructOrBuilder> + internalGetJsonSchemaFieldBuilder() { + if (jsonSchemaBuilder_ == null) { + if (!(valueCase_ == 1)) { + value_ = com.google.protobuf.Struct.getDefaultInstance(); + } + jsonSchemaBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Struct, + com.google.protobuf.Struct.Builder, + com.google.protobuf.StructOrBuilder>( + (com.google.protobuf.Struct) value_, getParentForChildren(), isClean()); + value_ = null; + } + valueCase_ = 1; + onChanged(); + return jsonSchemaBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.OperationSchema) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.OperationSchema) + private static final com.google.cloud.apihub.v1.OperationSchema DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.OperationSchema(); + } + + public static com.google.cloud.apihub.v1.OperationSchema getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public OperationSchema parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.OperationSchema getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationSchemaOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationSchemaOrBuilder.java new file mode 100644 index 000000000000..e030b27d832a --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/OperationSchemaOrBuilder.java @@ -0,0 +1,70 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/common_fields.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface OperationSchemaOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.OperationSchema) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +   * schema is not supported right now.
                      +   * 
                      + * + * .google.protobuf.Struct json_schema = 1; + * + * @return Whether the jsonSchema field is set. + */ + boolean hasJsonSchema(); + + /** + * + * + *
                      +   * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +   * schema is not supported right now.
                      +   * 
                      + * + * .google.protobuf.Struct json_schema = 1; + * + * @return The jsonSchema. + */ + com.google.protobuf.Struct getJsonSchema(); + + /** + * + * + *
                      +   * The JSON schema. Only valid JSON is accepted but semantic validation of
                      +   * schema is not supported right now.
                      +   * 
                      + * + * .google.protobuf.Struct json_schema = 1; + */ + com.google.protobuf.StructOrBuilder getJsonSchemaOrBuilder(); + + com.google.cloud.apihub.v1.OperationSchema.ValueCase getValueCase(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Plugin.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Plugin.java index f7a40d2e8ab9..f1df1ee24ae0 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Plugin.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Plugin.java @@ -4020,7 +4020,7 @@ public com.google.protobuf.ByteString getNameBytes() { * * *
                      -   * Required. The display name of the plugin. Max length is 50 characters
                      +   * Required. The display name of the plugin. Max length is 500 characters
                          * (Unicode code points).
                          * 
                      * @@ -4045,7 +4045,7 @@ public java.lang.String getDisplayName() { * * *
                      -   * Required. The display name of the plugin. Max length is 50 characters
                      +   * Required. The display name of the plugin. Max length is 500 characters
                          * (Unicode code points).
                          * 
                      * @@ -4154,7 +4154,7 @@ public com.google.cloud.apihub.v1.AttributeValuesOrBuilder getTypeOrBuilder() { * * *
                      -   * Optional. The plugin description. Max length is 2000 characters (Unicode
                      +   * Optional. The plugin description. Max length is 500000 characters (Unicode
                          * code points).
                          * 
                      * @@ -4179,7 +4179,7 @@ public java.lang.String getDescription() { * * *
                      -   * Optional. The plugin description. Max length is 2000 characters (Unicode
                      +   * Optional. The plugin description. Max length is 500000 characters (Unicode
                          * code points).
                          * 
                      * @@ -5650,7 +5650,7 @@ public Builder setNameBytes(com.google.protobuf.ByteString value) { * * *
                      -     * Required. The display name of the plugin. Max length is 50 characters
                      +     * Required. The display name of the plugin. Max length is 500 characters
                            * (Unicode code points).
                            * 
                      * @@ -5674,7 +5674,7 @@ public java.lang.String getDisplayName() { * * *
                      -     * Required. The display name of the plugin. Max length is 50 characters
                      +     * Required. The display name of the plugin. Max length is 500 characters
                            * (Unicode code points).
                            * 
                      * @@ -5698,7 +5698,7 @@ public com.google.protobuf.ByteString getDisplayNameBytes() { * * *
                      -     * Required. The display name of the plugin. Max length is 50 characters
                      +     * Required. The display name of the plugin. Max length is 500 characters
                            * (Unicode code points).
                            * 
                      * @@ -5721,7 +5721,7 @@ public Builder setDisplayName(java.lang.String value) { * * *
                      -     * Required. The display name of the plugin. Max length is 50 characters
                      +     * Required. The display name of the plugin. Max length is 500 characters
                            * (Unicode code points).
                            * 
                      * @@ -5740,7 +5740,7 @@ public Builder clearDisplayName() { * * *
                      -     * Required. The display name of the plugin. Max length is 50 characters
                      +     * Required. The display name of the plugin. Max length is 500 characters
                            * (Unicode code points).
                            * 
                      * @@ -6050,7 +6050,7 @@ public com.google.cloud.apihub.v1.AttributeValuesOrBuilder getTypeOrBuilder() { * * *
                      -     * Optional. The plugin description. Max length is 2000 characters (Unicode
                      +     * Optional. The plugin description. Max length is 500000 characters (Unicode
                            * code points).
                            * 
                      * @@ -6074,7 +6074,7 @@ public java.lang.String getDescription() { * * *
                      -     * Optional. The plugin description. Max length is 2000 characters (Unicode
                      +     * Optional. The plugin description. Max length is 500000 characters (Unicode
                            * code points).
                            * 
                      * @@ -6098,7 +6098,7 @@ public com.google.protobuf.ByteString getDescriptionBytes() { * * *
                      -     * Optional. The plugin description. Max length is 2000 characters (Unicode
                      +     * Optional. The plugin description. Max length is 500000 characters (Unicode
                            * code points).
                            * 
                      * @@ -6121,7 +6121,7 @@ public Builder setDescription(java.lang.String value) { * * *
                      -     * Optional. The plugin description. Max length is 2000 characters (Unicode
                      +     * Optional. The plugin description. Max length is 500000 characters (Unicode
                            * code points).
                            * 
                      * @@ -6140,7 +6140,7 @@ public Builder clearDescription() { * * *
                      -     * Optional. The plugin description. Max length is 2000 characters (Unicode
                      +     * Optional. The plugin description. Max length is 500000 characters (Unicode
                            * code points).
                            * 
                      * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginCategory.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginCategory.java index 325dcaa03cb8..c3873c05184f 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginCategory.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginCategory.java @@ -168,7 +168,7 @@ public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType } public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.apihub.v1.CommonFieldsProto.getDescriptor().getEnumTypes().get(4); + return com.google.cloud.apihub.v1.CommonFieldsProto.getDescriptor().getEnumTypes().get(6); } private static final PluginCategory[] VALUES = values(); diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstance.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstance.java index e039624b53c3..91fb0fcc5aa3 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstance.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstance.java @@ -74,6 +74,8 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldRefl switch (number) { case 4: return internalGetAdditionalConfig(); + case 12: + return internalGetSourceEnvironmentsConfig(); default: throw new RuntimeException("Invalid map field number: " + number); } @@ -447,7 +449,7 @@ public com.google.protobuf.ByteString getNameBytes() { * * *
                      -   * Required. The display name for this plugin instance. Max length is 255
                      +   * Required. The display name for this plugin instance. Max length is 500
                          * characters.
                          * 
                      * @@ -472,7 +474,7 @@ public java.lang.String getDisplayName() { * * *
                      -   * Required. The display name for this plugin instance. Max length is 255
                      +   * Required. The display name for this plugin instance. Max length is 500
                          * characters.
                          * 
                      * @@ -999,9 +1001,9 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { * *
                          * Optional. The source project id of the plugin instance. This will be the id
                      -   * of runtime project in case of gcp based plugins and org id in case of non
                      -   * gcp based plugins. This field will be a required field for Google provided
                      -   * on-ramp plugins.
                      +   * of runtime project in case of Google Cloud based plugins and org id in case
                      +   * of non-Google Cloud based plugins. This field will be a required field for
                      +   * Google provided on-ramp plugins.
                          * 
                      * * string source_project_id = 11 [(.google.api.field_behavior) = OPTIONAL]; @@ -1026,9 +1028,9 @@ public java.lang.String getSourceProjectId() { * *
                          * Optional. The source project id of the plugin instance. This will be the id
                      -   * of runtime project in case of gcp based plugins and org id in case of non
                      -   * gcp based plugins. This field will be a required field for Google provided
                      -   * on-ramp plugins.
                      +   * of runtime project in case of Google Cloud based plugins and org id in case
                      +   * of non-Google Cloud based plugins. This field will be a required field for
                      +   * Google provided on-ramp plugins.
                          * 
                      * * string source_project_id = 11 [(.google.api.field_behavior) = OPTIONAL]; @@ -1048,6 +1050,143 @@ public com.google.protobuf.ByteString getSourceProjectIdBytes() { } } + public static final int SOURCE_ENVIRONMENTS_CONFIG_FIELD_NUMBER = 12; + + private static final class SourceEnvironmentsConfigDefaultEntryHolder { + static final com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.apihub.v1.SourceEnvironment> + defaultEntry = + com.google.protobuf.MapEntry + .newDefaultInstance( + com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_PluginInstance_SourceEnvironmentsConfigEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.MESSAGE, + com.google.cloud.apihub.v1.SourceEnvironment.getDefaultInstance()); + } + + @SuppressWarnings("serial") + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.apihub.v1.SourceEnvironment> + sourceEnvironmentsConfig_; + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.apihub.v1.SourceEnvironment> + internalGetSourceEnvironmentsConfig() { + if (sourceEnvironmentsConfig_ == null) { + return com.google.protobuf.MapField.emptyMapField( + SourceEnvironmentsConfigDefaultEntryHolder.defaultEntry); + } + return sourceEnvironmentsConfig_; + } + + public int getSourceEnvironmentsConfigCount() { + return internalGetSourceEnvironmentsConfig().getMap().size(); + } + + /** + * + * + *
                      +   * Optional. The source environment's config present in the gateway instance
                      +   * linked to the plugin instance. The key is the `source_environment` name
                      +   * from the SourceEnvironment message.
                      +   * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public boolean containsSourceEnvironmentsConfig(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetSourceEnvironmentsConfig().getMap().containsKey(key); + } + + /** Use {@link #getSourceEnvironmentsConfigMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map + getSourceEnvironmentsConfig() { + return getSourceEnvironmentsConfigMap(); + } + + /** + * + * + *
                      +   * Optional. The source environment's config present in the gateway instance
                      +   * linked to the plugin instance. The key is the `source_environment` name
                      +   * from the SourceEnvironment message.
                      +   * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.Map + getSourceEnvironmentsConfigMap() { + return internalGetSourceEnvironmentsConfig().getMap(); + } + + /** + * + * + *
                      +   * Optional. The source environment's config present in the gateway instance
                      +   * linked to the plugin instance. The key is the `source_environment` name
                      +   * from the SourceEnvironment message.
                      +   * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public /* nullable */ com.google.cloud.apihub.v1.SourceEnvironment + getSourceEnvironmentsConfigOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.apihub.v1.SourceEnvironment defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = + internalGetSourceEnvironmentsConfig().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
                      +   * Optional. The source environment's config present in the gateway instance
                      +   * linked to the plugin instance. The key is the `source_environment` name
                      +   * from the SourceEnvironment message.
                      +   * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.SourceEnvironment getSourceEnvironmentsConfigOrThrow( + java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = + internalGetSourceEnvironmentsConfig().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -1091,6 +1230,11 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceProjectId_)) { com.google.protobuf.GeneratedMessage.writeString(output, 11, sourceProjectId_); } + com.google.protobuf.GeneratedMessage.serializeStringMapTo( + output, + internalGetSourceEnvironmentsConfig(), + SourceEnvironmentsConfigDefaultEntryHolder.defaultEntry, + 12); getUnknownFields().writeTo(output); } @@ -1138,6 +1282,18 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceProjectId_)) { size += com.google.protobuf.GeneratedMessage.computeStringSize(11, sourceProjectId_); } + for (java.util.Map.Entry entry : + internalGetSourceEnvironmentsConfig().getMap().entrySet()) { + com.google.protobuf.MapEntry + sourceEnvironmentsConfig__ = + SourceEnvironmentsConfigDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(12, sourceEnvironmentsConfig__); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1173,6 +1329,8 @@ public boolean equals(final java.lang.Object obj) { if (!getUpdateTime().equals(other.getUpdateTime())) return false; } if (!getSourceProjectId().equals(other.getSourceProjectId())) return false; + if (!internalGetSourceEnvironmentsConfig().equals(other.internalGetSourceEnvironmentsConfig())) + return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1214,6 +1372,10 @@ public int hashCode() { } hash = (37 * hash) + SOURCE_PROJECT_ID_FIELD_NUMBER; hash = (53 * hash) + getSourceProjectId().hashCode(); + if (!internalGetSourceEnvironmentsConfig().getMap().isEmpty()) { + hash = (37 * hash) + SOURCE_ENVIRONMENTS_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + internalGetSourceEnvironmentsConfig().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1341,6 +1503,8 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldRefl switch (number) { case 4: return internalGetAdditionalConfig(); + case 12: + return internalGetSourceEnvironmentsConfig(); default: throw new RuntimeException("Invalid map field number: " + number); } @@ -1352,6 +1516,8 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFi switch (number) { case 4: return internalGetMutableAdditionalConfig(); + case 12: + return internalGetMutableSourceEnvironmentsConfig(); default: throw new RuntimeException("Invalid map field number: " + number); } @@ -1418,6 +1584,7 @@ public Builder clear() { updateTimeBuilder_ = null; } sourceProjectId_ = ""; + internalGetMutableSourceEnvironmentsConfig().clear(); return this; } @@ -1499,6 +1666,11 @@ private void buildPartial0(com.google.cloud.apihub.v1.PluginInstance result) { if (((from_bitField0_ & 0x00000200) != 0)) { result.sourceProjectId_ = sourceProjectId_; } + if (((from_bitField0_ & 0x00000400) != 0)) { + result.sourceEnvironmentsConfig_ = + internalGetSourceEnvironmentsConfig() + .build(SourceEnvironmentsConfigDefaultEntryHolder.defaultEntry); + } result.bitField0_ |= to_bitField0_; } @@ -1575,6 +1747,9 @@ public Builder mergeFrom(com.google.cloud.apihub.v1.PluginInstance other) { bitField0_ |= 0x00000200; onChanged(); } + internalGetMutableSourceEnvironmentsConfig() + .mergeFrom(other.internalGetSourceEnvironmentsConfig()); + bitField0_ |= 0x00000400; this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1680,6 +1855,22 @@ public Builder mergeFrom( bitField0_ |= 0x00000200; break; } // case 90 + case 98: + { + com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.apihub.v1.SourceEnvironment> + sourceEnvironmentsConfig__ = + input.readMessage( + SourceEnvironmentsConfigDefaultEntryHolder.defaultEntry + .getParserForType(), + extensionRegistry); + internalGetMutableSourceEnvironmentsConfig() + .ensureBuilderMap() + .put( + sourceEnvironmentsConfig__.getKey(), sourceEnvironmentsConfig__.getValue()); + bitField0_ |= 0x00000400; + break; + } // case 98 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -1826,7 +2017,7 @@ public Builder setNameBytes(com.google.protobuf.ByteString value) { * * *
                      -     * Required. The display name for this plugin instance. Max length is 255
                      +     * Required. The display name for this plugin instance. Max length is 500
                            * characters.
                            * 
                      * @@ -1850,7 +2041,7 @@ public java.lang.String getDisplayName() { * * *
                      -     * Required. The display name for this plugin instance. Max length is 255
                      +     * Required. The display name for this plugin instance. Max length is 500
                            * characters.
                            * 
                      * @@ -1874,7 +2065,7 @@ public com.google.protobuf.ByteString getDisplayNameBytes() { * * *
                      -     * Required. The display name for this plugin instance. Max length is 255
                      +     * Required. The display name for this plugin instance. Max length is 500
                            * characters.
                            * 
                      * @@ -1897,7 +2088,7 @@ public Builder setDisplayName(java.lang.String value) { * * *
                      -     * Required. The display name for this plugin instance. Max length is 255
                      +     * Required. The display name for this plugin instance. Max length is 500
                            * characters.
                            * 
                      * @@ -1916,7 +2107,7 @@ public Builder clearDisplayName() { * * *
                      -     * Required. The display name for this plugin instance. Max length is 255
                      +     * Required. The display name for this plugin instance. Max length is 500
                            * characters.
                            * 
                      * @@ -3524,9 +3715,9 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { * *
                            * Optional. The source project id of the plugin instance. This will be the id
                      -     * of runtime project in case of gcp based plugins and org id in case of non
                      -     * gcp based plugins. This field will be a required field for Google provided
                      -     * on-ramp plugins.
                      +     * of runtime project in case of Google Cloud based plugins and org id in case
                      +     * of non-Google Cloud based plugins. This field will be a required field for
                      +     * Google provided on-ramp plugins.
                            * 
                      * * string source_project_id = 11 [(.google.api.field_behavior) = OPTIONAL]; @@ -3550,9 +3741,9 @@ public java.lang.String getSourceProjectId() { * *
                            * Optional. The source project id of the plugin instance. This will be the id
                      -     * of runtime project in case of gcp based plugins and org id in case of non
                      -     * gcp based plugins. This field will be a required field for Google provided
                      -     * on-ramp plugins.
                      +     * of runtime project in case of Google Cloud based plugins and org id in case
                      +     * of non-Google Cloud based plugins. This field will be a required field for
                      +     * Google provided on-ramp plugins.
                            * 
                      * * string source_project_id = 11 [(.google.api.field_behavior) = OPTIONAL]; @@ -3576,9 +3767,9 @@ public com.google.protobuf.ByteString getSourceProjectIdBytes() { * *
                            * Optional. The source project id of the plugin instance. This will be the id
                      -     * of runtime project in case of gcp based plugins and org id in case of non
                      -     * gcp based plugins. This field will be a required field for Google provided
                      -     * on-ramp plugins.
                      +     * of runtime project in case of Google Cloud based plugins and org id in case
                      +     * of non-Google Cloud based plugins. This field will be a required field for
                      +     * Google provided on-ramp plugins.
                            * 
                      * * string source_project_id = 11 [(.google.api.field_behavior) = OPTIONAL]; @@ -3601,9 +3792,9 @@ public Builder setSourceProjectId(java.lang.String value) { * *
                            * Optional. The source project id of the plugin instance. This will be the id
                      -     * of runtime project in case of gcp based plugins and org id in case of non
                      -     * gcp based plugins. This field will be a required field for Google provided
                      -     * on-ramp plugins.
                      +     * of runtime project in case of Google Cloud based plugins and org id in case
                      +     * of non-Google Cloud based plugins. This field will be a required field for
                      +     * Google provided on-ramp plugins.
                            * 
                      * * string source_project_id = 11 [(.google.api.field_behavior) = OPTIONAL]; @@ -3622,9 +3813,9 @@ public Builder clearSourceProjectId() { * *
                            * Optional. The source project id of the plugin instance. This will be the id
                      -     * of runtime project in case of gcp based plugins and org id in case of non
                      -     * gcp based plugins. This field will be a required field for Google provided
                      -     * on-ramp plugins.
                      +     * of runtime project in case of Google Cloud based plugins and org id in case
                      +     * of non-Google Cloud based plugins. This field will be a required field for
                      +     * Google provided on-ramp plugins.
                            * 
                      * * string source_project_id = 11 [(.google.api.field_behavior) = OPTIONAL]; @@ -3643,6 +3834,290 @@ public Builder setSourceProjectIdBytes(com.google.protobuf.ByteString value) { return this; } + private static final class SourceEnvironmentsConfigConverter + implements com.google.protobuf.MapFieldBuilder.Converter< + java.lang.String, + com.google.cloud.apihub.v1.SourceEnvironmentOrBuilder, + com.google.cloud.apihub.v1.SourceEnvironment> { + @java.lang.Override + public com.google.cloud.apihub.v1.SourceEnvironment build( + com.google.cloud.apihub.v1.SourceEnvironmentOrBuilder val) { + if (val instanceof com.google.cloud.apihub.v1.SourceEnvironment) { + return (com.google.cloud.apihub.v1.SourceEnvironment) val; + } + return ((com.google.cloud.apihub.v1.SourceEnvironment.Builder) val).build(); + } + + @java.lang.Override + public com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.apihub.v1.SourceEnvironment> + defaultEntry() { + return SourceEnvironmentsConfigDefaultEntryHolder.defaultEntry; + } + } + ; + + private static final SourceEnvironmentsConfigConverter sourceEnvironmentsConfigConverter = + new SourceEnvironmentsConfigConverter(); + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.apihub.v1.SourceEnvironmentOrBuilder, + com.google.cloud.apihub.v1.SourceEnvironment, + com.google.cloud.apihub.v1.SourceEnvironment.Builder> + sourceEnvironmentsConfig_; + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.apihub.v1.SourceEnvironmentOrBuilder, + com.google.cloud.apihub.v1.SourceEnvironment, + com.google.cloud.apihub.v1.SourceEnvironment.Builder> + internalGetSourceEnvironmentsConfig() { + if (sourceEnvironmentsConfig_ == null) { + return new com.google.protobuf.MapFieldBuilder<>(sourceEnvironmentsConfigConverter); + } + return sourceEnvironmentsConfig_; + } + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.apihub.v1.SourceEnvironmentOrBuilder, + com.google.cloud.apihub.v1.SourceEnvironment, + com.google.cloud.apihub.v1.SourceEnvironment.Builder> + internalGetMutableSourceEnvironmentsConfig() { + if (sourceEnvironmentsConfig_ == null) { + sourceEnvironmentsConfig_ = + new com.google.protobuf.MapFieldBuilder<>(sourceEnvironmentsConfigConverter); + } + bitField0_ |= 0x00000400; + onChanged(); + return sourceEnvironmentsConfig_; + } + + public int getSourceEnvironmentsConfigCount() { + return internalGetSourceEnvironmentsConfig().ensureBuilderMap().size(); + } + + /** + * + * + *
                      +     * Optional. The source environment's config present in the gateway instance
                      +     * linked to the plugin instance. The key is the `source_environment` name
                      +     * from the SourceEnvironment message.
                      +     * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public boolean containsSourceEnvironmentsConfig(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetSourceEnvironmentsConfig().ensureBuilderMap().containsKey(key); + } + + /** Use {@link #getSourceEnvironmentsConfigMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map + getSourceEnvironmentsConfig() { + return getSourceEnvironmentsConfigMap(); + } + + /** + * + * + *
                      +     * Optional. The source environment's config present in the gateway instance
                      +     * linked to the plugin instance. The key is the `source_environment` name
                      +     * from the SourceEnvironment message.
                      +     * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.Map + getSourceEnvironmentsConfigMap() { + return internalGetSourceEnvironmentsConfig().getImmutableMap(); + } + + /** + * + * + *
                      +     * Optional. The source environment's config present in the gateway instance
                      +     * linked to the plugin instance. The key is the `source_environment` name
                      +     * from the SourceEnvironment message.
                      +     * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public /* nullable */ com.google.cloud.apihub.v1.SourceEnvironment + getSourceEnvironmentsConfigOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.apihub.v1.SourceEnvironment defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = + internalGetMutableSourceEnvironmentsConfig().ensureBuilderMap(); + return map.containsKey(key) + ? sourceEnvironmentsConfigConverter.build(map.get(key)) + : defaultValue; + } + + /** + * + * + *
                      +     * Optional. The source environment's config present in the gateway instance
                      +     * linked to the plugin instance. The key is the `source_environment` name
                      +     * from the SourceEnvironment message.
                      +     * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.SourceEnvironment getSourceEnvironmentsConfigOrThrow( + java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = + internalGetMutableSourceEnvironmentsConfig().ensureBuilderMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return sourceEnvironmentsConfigConverter.build(map.get(key)); + } + + public Builder clearSourceEnvironmentsConfig() { + bitField0_ = (bitField0_ & ~0x00000400); + internalGetMutableSourceEnvironmentsConfig().clear(); + return this; + } + + /** + * + * + *
                      +     * Optional. The source environment's config present in the gateway instance
                      +     * linked to the plugin instance. The key is the `source_environment` name
                      +     * from the SourceEnvironment message.
                      +     * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeSourceEnvironmentsConfig(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableSourceEnvironmentsConfig().ensureBuilderMap().remove(key); + return this; + } + + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map + getMutableSourceEnvironmentsConfig() { + bitField0_ |= 0x00000400; + return internalGetMutableSourceEnvironmentsConfig().ensureMessageMap(); + } + + /** + * + * + *
                      +     * Optional. The source environment's config present in the gateway instance
                      +     * linked to the plugin instance. The key is the `source_environment` name
                      +     * from the SourceEnvironment message.
                      +     * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder putSourceEnvironmentsConfig( + java.lang.String key, com.google.cloud.apihub.v1.SourceEnvironment value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + internalGetMutableSourceEnvironmentsConfig().ensureBuilderMap().put(key, value); + bitField0_ |= 0x00000400; + return this; + } + + /** + * + * + *
                      +     * Optional. The source environment's config present in the gateway instance
                      +     * linked to the plugin instance. The key is the `source_environment` name
                      +     * from the SourceEnvironment message.
                      +     * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder putAllSourceEnvironmentsConfig( + java.util.Map values) { + for (java.util.Map.Entry e : + values.entrySet()) { + if (e.getKey() == null || e.getValue() == null) { + throw new NullPointerException(); + } + } + internalGetMutableSourceEnvironmentsConfig().ensureBuilderMap().putAll(values); + bitField0_ |= 0x00000400; + return this; + } + + /** + * + * + *
                      +     * Optional. The source environment's config present in the gateway instance
                      +     * linked to the plugin instance. The key is the `source_environment` name
                      +     * from the SourceEnvironment message.
                      +     * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.apihub.v1.SourceEnvironment.Builder + putSourceEnvironmentsConfigBuilderIfAbsent(java.lang.String key) { + java.util.Map + builderMap = internalGetMutableSourceEnvironmentsConfig().ensureBuilderMap(); + com.google.cloud.apihub.v1.SourceEnvironmentOrBuilder entry = builderMap.get(key); + if (entry == null) { + entry = com.google.cloud.apihub.v1.SourceEnvironment.newBuilder(); + builderMap.put(key, entry); + } + if (entry instanceof com.google.cloud.apihub.v1.SourceEnvironment) { + entry = ((com.google.cloud.apihub.v1.SourceEnvironment) entry).toBuilder(); + builderMap.put(key, entry); + } + return (com.google.cloud.apihub.v1.SourceEnvironment.Builder) entry; + } + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.PluginInstance) } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceAction.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceAction.java index 6829c65c7e7a..6be442131153 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceAction.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceAction.java @@ -1553,7 +1553,7 @@ public com.google.protobuf.ByteString getScheduleTimeZoneBytes() { * *
                          * Optional. The service account used to publish data. Note, the service
                      -   * account will only be accepted for non GCP plugins like OPDK.
                      +   * account will only be accepted for non-Google Cloud plugins like OPDK.
                          * 
                      * * string service_account = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -1578,7 +1578,7 @@ public java.lang.String getServiceAccount() { * *
                          * Optional. The service account used to publish data. Note, the service
                      -   * account will only be accepted for non GCP plugins like OPDK.
                      +   * account will only be accepted for non-Google Cloud plugins like OPDK.
                          * 
                      * * string service_account = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -1606,8 +1606,8 @@ public com.google.protobuf.ByteString getServiceAccountBytes() { * *
                          * Output only. The configuration of resources created for a given plugin
                      -   * instance action. Note these will be returned only in case of Non-GCP
                      -   * plugins like OPDK.
                      +   * instance action. Note these will be returned only in case of non-Google
                      +   * Cloud plugins like OPDK.
                          * 
                      * * @@ -1626,8 +1626,8 @@ public boolean hasResourceConfig() { * *
                          * Output only. The configuration of resources created for a given plugin
                      -   * instance action. Note these will be returned only in case of Non-GCP
                      -   * plugins like OPDK.
                      +   * instance action. Note these will be returned only in case of non-Google
                      +   * Cloud plugins like OPDK.
                          * 
                      * * @@ -1648,8 +1648,8 @@ public com.google.cloud.apihub.v1.PluginInstanceAction.ResourceConfig getResourc * *
                          * Output only. The configuration of resources created for a given plugin
                      -   * instance action. Note these will be returned only in case of Non-GCP
                      -   * plugins like OPDK.
                      +   * instance action. Note these will be returned only in case of non-Google
                      +   * Cloud plugins like OPDK.
                          * 
                      * * @@ -3160,7 +3160,7 @@ public Builder setScheduleTimeZoneBytes(com.google.protobuf.ByteString value) { * *
                            * Optional. The service account used to publish data. Note, the service
                      -     * account will only be accepted for non GCP plugins like OPDK.
                      +     * account will only be accepted for non-Google Cloud plugins like OPDK.
                            * 
                      * * string service_account = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -3184,7 +3184,7 @@ public java.lang.String getServiceAccount() { * *
                            * Optional. The service account used to publish data. Note, the service
                      -     * account will only be accepted for non GCP plugins like OPDK.
                      +     * account will only be accepted for non-Google Cloud plugins like OPDK.
                            * 
                      * * string service_account = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -3208,7 +3208,7 @@ public com.google.protobuf.ByteString getServiceAccountBytes() { * *
                            * Optional. The service account used to publish data. Note, the service
                      -     * account will only be accepted for non GCP plugins like OPDK.
                      +     * account will only be accepted for non-Google Cloud plugins like OPDK.
                            * 
                      * * string service_account = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -3231,7 +3231,7 @@ public Builder setServiceAccount(java.lang.String value) { * *
                            * Optional. The service account used to publish data. Note, the service
                      -     * account will only be accepted for non GCP plugins like OPDK.
                      +     * account will only be accepted for non-Google Cloud plugins like OPDK.
                            * 
                      * * string service_account = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -3250,7 +3250,7 @@ public Builder clearServiceAccount() { * *
                            * Optional. The service account used to publish data. Note, the service
                      -     * account will only be accepted for non GCP plugins like OPDK.
                      +     * account will only be accepted for non-Google Cloud plugins like OPDK.
                            * 
                      * * string service_account = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -3281,8 +3281,8 @@ public Builder setServiceAccountBytes(com.google.protobuf.ByteString value) { * *
                            * Output only. The configuration of resources created for a given plugin
                      -     * instance action. Note these will be returned only in case of Non-GCP
                      -     * plugins like OPDK.
                      +     * instance action. Note these will be returned only in case of non-Google
                      +     * Cloud plugins like OPDK.
                            * 
                      * * @@ -3300,8 +3300,8 @@ public boolean hasResourceConfig() { * *
                            * Output only. The configuration of resources created for a given plugin
                      -     * instance action. Note these will be returned only in case of Non-GCP
                      -     * plugins like OPDK.
                      +     * instance action. Note these will be returned only in case of non-Google
                      +     * Cloud plugins like OPDK.
                            * 
                      * * @@ -3325,8 +3325,8 @@ public com.google.cloud.apihub.v1.PluginInstanceAction.ResourceConfig getResourc * *
                            * Output only. The configuration of resources created for a given plugin
                      -     * instance action. Note these will be returned only in case of Non-GCP
                      -     * plugins like OPDK.
                      +     * instance action. Note these will be returned only in case of non-Google
                      +     * Cloud plugins like OPDK.
                            * 
                      * * @@ -3353,8 +3353,8 @@ public Builder setResourceConfig( * *
                            * Output only. The configuration of resources created for a given plugin
                      -     * instance action. Note these will be returned only in case of Non-GCP
                      -     * plugins like OPDK.
                      +     * instance action. Note these will be returned only in case of non-Google
                      +     * Cloud plugins like OPDK.
                            * 
                      * * @@ -3378,8 +3378,8 @@ public Builder setResourceConfig( * *
                            * Output only. The configuration of resources created for a given plugin
                      -     * instance action. Note these will be returned only in case of Non-GCP
                      -     * plugins like OPDK.
                      +     * instance action. Note these will be returned only in case of non-Google
                      +     * Cloud plugins like OPDK.
                            * 
                      * * @@ -3413,8 +3413,8 @@ public Builder mergeResourceConfig( * *
                            * Output only. The configuration of resources created for a given plugin
                      -     * instance action. Note these will be returned only in case of Non-GCP
                      -     * plugins like OPDK.
                      +     * instance action. Note these will be returned only in case of non-Google
                      +     * Cloud plugins like OPDK.
                            * 
                      * * @@ -3437,8 +3437,8 @@ public Builder clearResourceConfig() { * *
                            * Output only. The configuration of resources created for a given plugin
                      -     * instance action. Note these will be returned only in case of Non-GCP
                      -     * plugins like OPDK.
                      +     * instance action. Note these will be returned only in case of non-Google
                      +     * Cloud plugins like OPDK.
                            * 
                      * * @@ -3457,8 +3457,8 @@ public Builder clearResourceConfig() { * *
                            * Output only. The configuration of resources created for a given plugin
                      -     * instance action. Note these will be returned only in case of Non-GCP
                      -     * plugins like OPDK.
                      +     * instance action. Note these will be returned only in case of non-Google
                      +     * Cloud plugins like OPDK.
                            * 
                      * * @@ -3481,8 +3481,8 @@ public Builder clearResourceConfig() { * *
                            * Output only. The configuration of resources created for a given plugin
                      -     * instance action. Note these will be returned only in case of Non-GCP
                      -     * plugins like OPDK.
                      +     * instance action. Note these will be returned only in case of non-Google
                      +     * Cloud plugins like OPDK.
                            * 
                      * * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceActionOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceActionOrBuilder.java index 8e96b7fa3431..1b14adede9f6 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceActionOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceActionOrBuilder.java @@ -241,7 +241,7 @@ public interface PluginInstanceActionOrBuilder * *
                          * Optional. The service account used to publish data. Note, the service
                      -   * account will only be accepted for non GCP plugins like OPDK.
                      +   * account will only be accepted for non-Google Cloud plugins like OPDK.
                          * 
                      * * string service_account = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -255,7 +255,7 @@ public interface PluginInstanceActionOrBuilder * *
                          * Optional. The service account used to publish data. Note, the service
                      -   * account will only be accepted for non GCP plugins like OPDK.
                      +   * account will only be accepted for non-Google Cloud plugins like OPDK.
                          * 
                      * * string service_account = 8 [(.google.api.field_behavior) = OPTIONAL]; @@ -269,8 +269,8 @@ public interface PluginInstanceActionOrBuilder * *
                          * Output only. The configuration of resources created for a given plugin
                      -   * instance action. Note these will be returned only in case of Non-GCP
                      -   * plugins like OPDK.
                      +   * instance action. Note these will be returned only in case of non-Google
                      +   * Cloud plugins like OPDK.
                          * 
                      * * @@ -286,8 +286,8 @@ public interface PluginInstanceActionOrBuilder * *
                          * Output only. The configuration of resources created for a given plugin
                      -   * instance action. Note these will be returned only in case of Non-GCP
                      -   * plugins like OPDK.
                      +   * instance action. Note these will be returned only in case of non-Google
                      +   * Cloud plugins like OPDK.
                          * 
                      * * @@ -303,8 +303,8 @@ public interface PluginInstanceActionOrBuilder * *
                          * Output only. The configuration of resources created for a given plugin
                      -   * instance action. Note these will be returned only in case of Non-GCP
                      -   * plugins like OPDK.
                      +   * instance action. Note these will be returned only in case of non-Google
                      +   * Cloud plugins like OPDK.
                          * 
                      * * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceOrBuilder.java index 98f2ed25441a..7128adba9880 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginInstanceOrBuilder.java @@ -60,7 +60,7 @@ public interface PluginInstanceOrBuilder * * *
                      -   * Required. The display name for this plugin instance. Max length is 255
                      +   * Required. The display name for this plugin instance. Max length is 500
                          * characters.
                          * 
                      * @@ -74,7 +74,7 @@ public interface PluginInstanceOrBuilder * * *
                      -   * Required. The display name for this plugin instance. Max length is 255
                      +   * Required. The display name for this plugin instance. Max length is 500
                          * characters.
                          * 
                      * @@ -439,9 +439,9 @@ com.google.cloud.apihub.v1.ConfigVariable getAdditionalConfigOrDefault( * *
                          * Optional. The source project id of the plugin instance. This will be the id
                      -   * of runtime project in case of gcp based plugins and org id in case of non
                      -   * gcp based plugins. This field will be a required field for Google provided
                      -   * on-ramp plugins.
                      +   * of runtime project in case of Google Cloud based plugins and org id in case
                      +   * of non-Google Cloud based plugins. This field will be a required field for
                      +   * Google provided on-ramp plugins.
                          * 
                      * * string source_project_id = 11 [(.google.api.field_behavior) = OPTIONAL]; @@ -455,9 +455,9 @@ com.google.cloud.apihub.v1.ConfigVariable getAdditionalConfigOrDefault( * *
                          * Optional. The source project id of the plugin instance. This will be the id
                      -   * of runtime project in case of gcp based plugins and org id in case of non
                      -   * gcp based plugins. This field will be a required field for Google provided
                      -   * on-ramp plugins.
                      +   * of runtime project in case of Google Cloud based plugins and org id in case
                      +   * of non-Google Cloud based plugins. This field will be a required field for
                      +   * Google provided on-ramp plugins.
                          * 
                      * * string source_project_id = 11 [(.google.api.field_behavior) = OPTIONAL]; @@ -465,4 +465,90 @@ com.google.cloud.apihub.v1.ConfigVariable getAdditionalConfigOrDefault( * @return The bytes for sourceProjectId. */ com.google.protobuf.ByteString getSourceProjectIdBytes(); + + /** + * + * + *
                      +   * Optional. The source environment's config present in the gateway instance
                      +   * linked to the plugin instance. The key is the `source_environment` name
                      +   * from the SourceEnvironment message.
                      +   * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + int getSourceEnvironmentsConfigCount(); + + /** + * + * + *
                      +   * Optional. The source environment's config present in the gateway instance
                      +   * linked to the plugin instance. The key is the `source_environment` name
                      +   * from the SourceEnvironment message.
                      +   * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + boolean containsSourceEnvironmentsConfig(java.lang.String key); + + /** Use {@link #getSourceEnvironmentsConfigMap()} instead. */ + @java.lang.Deprecated + java.util.Map + getSourceEnvironmentsConfig(); + + /** + * + * + *
                      +   * Optional. The source environment's config present in the gateway instance
                      +   * linked to the plugin instance. The key is the `source_environment` name
                      +   * from the SourceEnvironment message.
                      +   * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.Map + getSourceEnvironmentsConfigMap(); + + /** + * + * + *
                      +   * Optional. The source environment's config present in the gateway instance
                      +   * linked to the plugin instance. The key is the `source_environment` name
                      +   * from the SourceEnvironment message.
                      +   * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + /* nullable */ + com.google.cloud.apihub.v1.SourceEnvironment getSourceEnvironmentsConfigOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.apihub.v1.SourceEnvironment defaultValue); + + /** + * + * + *
                      +   * Optional. The source environment's config present in the gateway instance
                      +   * linked to the plugin instance. The key is the `source_environment` name
                      +   * from the SourceEnvironment message.
                      +   * 
                      + * + * + * map<string, .google.cloud.apihub.v1.SourceEnvironment> source_environments_config = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.apihub.v1.SourceEnvironment getSourceEnvironmentsConfigOrThrow( + java.lang.String key); } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginOrBuilder.java index 0bd0e92beed6..63f385f13930 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginOrBuilder.java @@ -58,7 +58,7 @@ public interface PluginOrBuilder * * *
                      -   * Required. The display name of the plugin. Max length is 50 characters
                      +   * Required. The display name of the plugin. Max length is 500 characters
                          * (Unicode code points).
                          * 
                      * @@ -72,7 +72,7 @@ public interface PluginOrBuilder * * *
                      -   * Required. The display name of the plugin. Max length is 50 characters
                      +   * Required. The display name of the plugin. Max length is 500 characters
                          * (Unicode code points).
                          * 
                      * @@ -153,7 +153,7 @@ public interface PluginOrBuilder * * *
                      -   * Optional. The plugin description. Max length is 2000 characters (Unicode
                      +   * Optional. The plugin description. Max length is 500000 characters (Unicode
                          * code points).
                          * 
                      * @@ -167,7 +167,7 @@ public interface PluginOrBuilder * * *
                      -   * Optional. The plugin description. Max length is 2000 characters (Unicode
                      +   * Optional. The plugin description. Max length is 500000 characters (Unicode
                          * code points).
                          * 
                      * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginServiceProto.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginServiceProto.java index 36cabfbe0aa0..8caeeb83cc57 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginServiceProto.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/PluginServiceProto.java @@ -88,6 +88,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_apihub_v1_PluginInstance_AdditionalConfigEntry_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_apihub_v1_PluginInstance_AdditionalConfigEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_PluginInstance_SourceEnvironmentsConfigEntry_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_PluginInstance_SourceEnvironmentsConfigEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_SourceEnvironment_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_SourceEnvironment_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_apihub_v1_CurationConfig_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -172,6 +180,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_apihub_v1_DeletePluginInstanceRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_apihub_v1_DeletePluginInstanceRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataResponse_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -281,7 +297,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010ENABLING\020\003\022\r\n" + "\tDISABLING\020\004\022\t\n" + "\005ERROR\020\005B\017\n\r" - + "action_status\"\204\007\n" + + "action_status\"\340\010\n" + "\016PluginInstance\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + "\014display_name\030\002 \001(\tB\004\342A\001\002\022=\n" @@ -298,10 +314,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\n" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022\037\n" - + "\021source_project_id\030\013 \001(\tB\004\342A\001\001\032_\n" + + "\021source_project_id\030\013 \001(\tB\004\342A\001\001\022n\n" + + "\032source_environments_config\030\014 \003(\0132D.googl" + + "e.cloud.apihub.v1.PluginInstance.SourceEnvironmentsConfigEntryB\004\342A\001\001\032_\n" + "\025AdditionalConfigEntry\022\013\n" + "\003key\030\001 \001(\t\0225\n" - + "\005value\030\002 \001(\0132&.google.cloud.apihub.v1.ConfigVariable:\0028\001\"r\n" + + "\005value\030\002 \001(\0132&.google.cloud.apihub.v1.ConfigVariable:\0028\001\032j\n" + + "\035SourceEnvironmentsConfigEntry\022\013\n" + + "\003key\030\001 \001(\t\0228\n" + + "\005value\030\002 \001(\0132).google.cloud.apihub.v1.SourceEnvironment:\0028\001\"r\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\014\n" + "\010CREATING\020\001\022\n\n" @@ -310,28 +331,37 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005ERROR\020\004\022\n\n" + "\006FAILED\020\005\022\014\n" + "\010DELETING\020\006:\232\001\352A\226\001\n" - + "$apihub.googleapis.com/PluginInstance\022Mprojects/{project}/locat" - + "ions/{location}/plugins/{plugin}/instanc" - + "es/{instance}*\017pluginInstances2\016pluginInstance\"\350\001\n" + + "$apihub.googleapis.com/PluginInstance\022Mprojects/{project}/locations/{location}/plug" + + "ins/{plugin}/instances/{instance}*\017pluginInstances2\016pluginInstance\"\303\001\n" + + "\021SourceEnvironment\022 \n" + + "\022source_environment\030\001 \001(\tB\004\342A\001\002\022\036\n" + + "\026source_environment_uri\030\003 \001(\t\0225\n" + + "\013create_time\030\004" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\001\0225\n" + + "\013update_time\030\005" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\001\"\350\001\n" + "\016CurationConfig\022V\n" - + "\017custom_curation\030\002" - + " \001(\01325.google.cloud.apihub.v1.CurationConfig.CustomCurationB\004\342A\001\001H\000\022A\n\r" - + "curation_type\030\001" - + " \001(\0162$.google.cloud.apihub.v1.CurationTypeB\004\342A\001\002\032(\n" + + "\017custom_curation\030\002 \001(\01325.google.cl" + + "oud.apihub.v1.CurationConfig.CustomCurationB\004\342A\001\001H\000\022A\n\r" + + "curation_type\030\001 \001(\0162$.goo" + + "gle.cloud.apihub.v1.CurationTypeB\004\342A\001\002\032(\n" + "\016CustomCuration\022\026\n" + "\010curation\030\001 \001(\tB\004\342A\001\002B\021\n" - + "\017curation_config\"\326\004\n" + + "\017curation_config\"\365\004\n" + "\017ExecutionStatus\022d\n" - + "\027current_execution_state\030\001 \001(\0162=.google.cloud.apihub.v1." - + "ExecutionStatus.CurrentExecutionStateB\004\342A\001\003\022S\n" - + "\016last_execution\030\002 \001(\01325.google.clo" - + "ud.apihub.v1.ExecutionStatus.LastExecutionB\004\342A\001\003\032\247\002\n\r" + + "\027current_execution_state\030\001 \001(\0162=.googl" + + "e.cloud.apihub.v1.ExecutionStatus.CurrentExecutionStateB\004\342A\001\003\022S\n" + + "\016last_execution\030\002" + + " \001(\01325.google.cloud.apihub.v1.ExecutionStatus.LastExecutionB\004\342A\001\003\032\306\002\n\r" + "LastExecution\022R\n" - + "\006result\030\001 \001" - + "(\0162<.google.cloud.apihub.v1.ExecutionStatus.LastExecution.ResultB\004\342A\001\003\022\033\n\r" - + "error_message\030\002 \001(\tB\004\342A\001\003\0224\n\n" + + "\006result\030\001 \001(\0162<.google.cloud.apih" + + "ub.v1.ExecutionStatus.LastExecution.ResultB\004\342A\001\003\022\033\n\r" + + "error_message\030\002 \001(\tB\004\342A\001\003\0224\n" + + "\n" + "start_time\030\003 \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0222\n" - + "\010end_time\030\004 \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\";\n" + + "\010end_time\030\004" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022\035\n" + + "\017result_metadata\030\005 \001(\tB\004\342A\001\003\";\n" + "\006Result\022\026\n" + "\022RESULT_UNSPECIFIED\020\000\022\r\n" + "\tSUCCEEDED\020\001\022\n\n" @@ -361,8 +391,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006parent\030\001 \001(\tB%\342A\001\002\372A\036\n" + "\034apihub.googleapis.com/Plugin\022 \n" + "\022plugin_instance_id\030\002 \001(\tB\004\342A\001\001\022E\n" - + "\017plugin_instance\030\003" - + " \001(\0132&.google.cloud.apihub.v1.PluginInstanceB\004\342A\001\002\"\267\001\n" + + "\017plugin_instance\030\003 \001(\0132" + + "&.google.cloud.apihub.v1.PluginInstanceB\004\342A\001\002\"\267\001\n" + "\"ExecutePluginInstanceActionRequest\022;\n" + "\004name\030\001 \001(\tB-\342A\001\002\372A&\n" + "$apihub.googleapis.com/PluginInstance\022T\n" @@ -395,17 +425,38 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\taction_id\030\002 \001(\tB\004\342A\001\002\"%\n" + "#DisablePluginInstanceActionResponse\"\233\001\n" + "\033UpdatePluginInstanceRequest\022E\n" - + "\017plugin_instance\030\001" - + " \001(\0132&.google.cloud.apihub.v1.PluginInstanceB\004\342A\001\002\0225\n" + + "\017plugin_instance\030\001 \001(\0132" + + "&.google.cloud.apihub.v1.PluginInstanceB\004\342A\001\002\0225\n" + "\013update_mask\030\002" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\"Z\n" + "\033DeletePluginInstanceRequest\022;\n" + "\004name\030\001 \001(\tB-\342A\001\002\372A&\n" - + "$apihub.googleapis.com/PluginInstance*S\n\n" + + "$apihub.googleapis.com/PluginInstance\"\227\004\n" + + "%ManagePluginInstanceSourceDataRequest\022;\n" + + "\004name\030\001 \001(\tB-\342A\001\002\372A&\n" + + "$apihub.googleapis.com/PluginInstance\022_\n" + + "\tdata_type\030\002 \001(\0162F.goo" + + "gle.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest.DataTypeB\004\342A\001\002\022Z\n" + + "\006action\030\003 \001(\0162D.google.cloud.apihub.v1.Manage" + + "PluginInstanceSourceDataRequest.ActionB\004\342A\001\002\022\033\n\r" + + "relative_path\030\004 \001(\tB\004\342A\001\002\022\022\n" + + "\004data\030\005 \001(\014B\004\342A\001\002\"\210\001\n" + + "\010DataType\022\031\n" + + "\025DATA_TYPE_UNSPECIFIED\020\000\022\035\n" + + "\031PROXY_DEPLOYMENT_MANIFEST\020\001\022\030\n" + + "\024ENVIRONMENT_MANIFEST\020\002\022\020\n" + + "\014PROXY_BUNDLE\020\003\022\026\n" + + "\022SHARED_FLOW_BUNDLE\020\004\"8\n" + + "\006Action\022\026\n" + + "\022ACTION_UNSPECIFIED\020\000\022\n\n" + + "\006UPLOAD\020\001\022\n" + + "\n" + + "\006DELETE\020\002\"(\n" + + "&ManagePluginInstanceSourceDataResponse*S\n\n" + "ActionType\022\033\n" + "\027ACTION_TYPE_UNSPECIFIED\020\000\022\021\n\r" + "SYNC_METADATA\020\001\022\025\n" - + "\021SYNC_RUNTIME_DATA\020\002*\314\001\n" + + "\021SYNC_RUNTIME_DATA\020\002*\373\001\n" + "\013GatewayType\022\034\n" + "\030GATEWAY_TYPE_UNSPECIFIED\020\000\022\027\n" + "\023APIGEE_X_AND_HYBRID\020\001\022\034\n" @@ -414,79 +465,89 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\021CLOUD_API_GATEWAY\020\004\022\023\n" + "\017CLOUD_ENDPOINTS\020\005\022\021\n\r" + "API_DISCOVERY\020\006\022\n\n" - + "\006OTHERS\020\007*z\n" + + "\006OTHERS\020\007\022\023\n" + + "\017AWS_API_GATEWAY\020\010\022\030\n" + + "\024AZURE_API_MANAGEMENT\020\t*z\n" + "\014CurationType\022\035\n" + "\031CURATION_TYPE_UNSPECIFIED\020\000\022%\n" + "!DEFAULT_CURATION_FOR_API_METADATA\020\001\022$\n" - + " CUSTOM_CURATION_FOR_API_METADATA\020\0022\237\030\n" + + " CUSTOM_CURATION_FOR_API_METADATA\020\0022\244\033\n" + "\014ApiHubPlugin\022\221\001\n" - + "\tGetPlugin\022(.google.cloud.apihub.v1.GetPluginRequest\032\036.googl" - + "e.cloud.apihub.v1.Plugin\":\332A\004name\202\323\344\223\002-\022" - + "+/v1/{name=projects/*/locations/*/plugins/*}\022\241\001\n" - + "\014EnablePlugin\022+.google.cloud.apihub.v1.EnablePluginRequest\032\036.google.clou" - + "d.apihub.v1.Plugin\"D\332A\004name\202\323\344\223\0027\"2/v1/{" - + "name=projects/*/locations/*/plugins/*}:enable:\001*\022\244\001\n\r" - + "DisablePlugin\022,.google.cloud.apihub.v1.DisablePluginRequest\032\036.googl" - + "e.cloud.apihub.v1.Plugin\"E\332A\004name\202\323\344\223\0028\"" - + "3/v1/{name=projects/*/locations/*/plugins/*}:disable:\001*\022\262\001\n" - + "\014CreatePlugin\022+.google.cloud.apihub.v1.CreatePluginRequest\032\036." - + "google.cloud.apihub.v1.Plugin\"U\332A\027parent" - + ",plugin,plugin_id\202\323\344\223\0025\"+/v1/{parent=projects/*/locations/*}/plugins:\006plugin\022\244\001\n" - + "\013ListPlugins\022*.google.cloud.apihub.v1.Li" - + "stPluginsRequest\032+.google.cloud.apihub.v" - + "1.ListPluginsResponse\"<\332A\006parent\202\323\344\223\002-\022+" - + "/v1/{parent=projects/*/locations/*}/plugins\022\303\001\n" - + "\014DeletePlugin\022+.google.cloud.apih" - + "ub.v1.DeletePluginRequest\032\035.google.longrunning.Operation\"g\312A*\n" - + "\025google.protobuf.E" - + "mpty\022\021OperationMetadata\332A\004name\202\323\344\223\002-*+/v" - + "1/{name=projects/*/locations/*/plugins/*}\022\217\002\n" - + "\024CreatePluginInstance\0223.google.clou" - + "d.apihub.v1.CreatePluginInstanceRequest\032\035.google.longrunning.Operation\"\242\001\312A#\n" - + "\016PluginInstance\022\021OperationMetadata\332A)parent" - + ",plugin_instance,plugin_instance_id\202\323\344\223\002" - + "J\"7/v1/{parent=projects/*/locations/*/plugins/*}/instances:\017plugin_instance\022\245\002\n" - + "\033ExecutePluginInstanceAction\022:.google.clo" - + "ud.apihub.v1.ExecutePluginInstanceAction" - + "Request\032\035.google.longrunning.Operation\"\252\001\312A8\n" - + "#ExecutePluginInstanceActionRespons" - + "e\022\021OperationMetadata\332A\034name,action_execu" - + "tion_detail\202\323\344\223\002J\"E/v1/{name=projects/*/" - + "locations/*/plugins/*/instances/*}:executeAction:\001*\022\265\001\n" - + "\021GetPluginInstance\0220.google.cloud.apihub.v1.GetPluginInstanceRequ" - + "est\032&.google.cloud.apihub.v1.PluginInsta" - + "nce\"F\332A\004name\202\323\344\223\0029\0227/v1/{name=projects/*/locations/*/plugins/*/instances/*}\022\310\001\n" - + "\023ListPluginInstances\0222.google.cloud.apihu" - + "b.v1.ListPluginInstancesRequest\0323.google.cloud.apihub.v1.ListPluginInstancesResp" - + "onse\"H\332A\006parent\202\323\344\223\0029\0227/v1/{parent=proje" - + "cts/*/locations/*/plugins/*}/instances\022\223\002\n" - + "\032EnablePluginInstanceAction\0229.google.cloud.apihub.v1.EnablePluginInstanceActio" - + "nRequest\032\035.google.longrunning.Operation\"\232\001\312A7\n" - + "\"EnablePluginInstanceActionRespons" - + "e\022\021OperationMetadata\332A\016name,action_id\202\323\344" - + "\223\002I\"D/v1/{name=projects/*/locations/*/plugins/*/instances/*}:enableAction:\001*\022\227\002\n" - + "\033DisablePluginInstanceAction\022:.google.cloud.apihub.v1.DisablePluginInstanceActio" - + "nRequest\032\035.google.longrunning.Operation\"\234\001\312A8\n" - + "#DisablePluginInstanceActionRespon" - + "se\022\021OperationMetadata\332A\016name,action_id\202\323" - + "\344\223\002J\"E/v1/{name=projects/*/locations/*/p" - + "lugins/*/instances/*}:disableAction:\001*\022\363\001\n" - + "\024UpdatePluginInstance\0223.google.cloud.a" - + "pihub.v1.UpdatePluginInstanceRequest\032&.g" - + "oogle.cloud.apihub.v1.PluginInstance\"~\332A" - + "\033plugin_instance,update_mask\202\323\344\223\002Z2G/v1/" - + "{plugin_instance.name=projects/*/locatio" - + "ns/*/plugins/*/instances/*}:\017plugin_instance\022\337\001\n" - + "\024DeletePluginInstance\0223.google.c" - + "loud.apihub.v1.DeletePluginInstanceRequest\032\035.google.longrunning.Operation\"s\312A*\n" - + "\025google.protobuf.Empty\022\021OperationMetadata" - + "\332A\004name\202\323\344\223\0029*7/v1/{name=projects/*/loca" - + "tions/*/plugins/*/instances/*}\032I\312A\025apihu" - + "b.googleapis.com\322A.https://www.googleapis.com/auth/cloud-platformB\264\001\n" - + "\032com.google.cloud.apihub.v1B\022PluginServiceProtoP\001Z2" - + "cloud.google.com/go/apihub/apiv1/apihubp" - + "b;apihubpb\252\002\026Google.Cloud.ApiHub.V1\312\002\026Go" - + "ogle\\Cloud\\ApiHub\\V1\352\002\031Google::Cloud::ApiHub::V1b\006proto3" + + "\tGetPlugin\022(.google.cloud.apihub.v1.GetPluginRequest\032\036.google.cl" + + "oud.apihub.v1.Plugin\":\332A\004name\202\323\344\223\002-\022+/v1" + + "/{name=projects/*/locations/*/plugins/*}\022\241\001\n" + + "\014EnablePlugin\022+.google.cloud.apihub." + + "v1.EnablePluginRequest\032\036.google.cloud.ap" + + "ihub.v1.Plugin\"D\332A\004name\202\323\344\223\0027\"2/v1/{name" + + "=projects/*/locations/*/plugins/*}:enable:\001*\022\244\001\n\r" + + "DisablePlugin\022,.google.cloud.apihub.v1.DisablePluginRequest\032\036.google.cl" + + "oud.apihub.v1.Plugin\"E\332A\004name\202\323\344\223\0028\"3/v1" + + "/{name=projects/*/locations/*/plugins/*}:disable:\001*\022\262\001\n" + + "\014CreatePlugin\022+.google.cloud.apihub.v1.CreatePluginRequest\032\036.goog" + + "le.cloud.apihub.v1.Plugin\"U\332A\027parent,plu" + + "gin,plugin_id\202\323\344\223\0025\"+/v1/{parent=projects/*/locations/*}/plugins:\006plugin\022\244\001\n" + + "\013ListPlugins\022*.google.cloud.apihub.v1.ListPl" + + "uginsRequest\032+.google.cloud.apihub.v1.Li" + + "stPluginsResponse\"<\332A\006parent\202\323\344\223\002-\022+/v1/" + + "{parent=projects/*/locations/*}/plugins\022\303\001\n" + + "\014DeletePlugin\022+.google.cloud.apihub.v" + + "1.DeletePluginRequest\032\035.google.longrunning.Operation\"g\312A*\n" + + "\025google.protobuf.Empty" + + "\022\021OperationMetadata\332A\004name\202\323\344\223\002-*+/v1/{n" + + "ame=projects/*/locations/*/plugins/*}\022\217\002\n" + + "\024CreatePluginInstance\0223.google.cloud.ap" + + "ihub.v1.CreatePluginInstanceRequest\032\035.google.longrunning.Operation\"\242\001\312A#\n" + + "\016PluginInstance\022\021OperationMetadata\332A)parent,plu" + + "gin_instance,plugin_instance_id\202\323\344\223\002J\"7/" + + "v1/{parent=projects/*/locations/*/plugins/*}/instances:\017plugin_instance\022\245\002\n" + + "\033ExecutePluginInstanceAction\022:.google.cloud.a" + + "pihub.v1.ExecutePluginInstanceActionRequ" + + "est\032\035.google.longrunning.Operation\"\252\001\312A8\n" + + "#ExecutePluginInstanceActionResponse\022\021O" + + "perationMetadata\332A\034name,action_execution" + + "_detail\202\323\344\223\002J\"E/v1/{name=projects/*/loca" + + "tions/*/plugins/*/instances/*}:executeAction:\001*\022\265\001\n" + + "\021GetPluginInstance\0220.google.cloud.apihub.v1.GetPluginInstanceRequest\032" + + "&.google.cloud.apihub.v1.PluginInstance\"" + + "F\332A\004name\202\323\344\223\0029\0227/v1/{name=projects/*/locations/*/plugins/*/instances/*}\022\310\001\n" + + "\023ListPluginInstances\0222.google.cloud.apihub.v1" + + ".ListPluginInstancesRequest\0323.google.cloud.apihub.v1.ListPluginInstancesResponse" + + "\"H\332A\006parent\202\323\344\223\0029\0227/v1/{parent=projects/*/locations/*/plugins/*}/instances\022\223\002\n" + + "\032EnablePluginInstanceAction\0229.google.cloud" + + ".apihub.v1.EnablePluginInstanceActionReq" + + "uest\032\035.google.longrunning.Operation\"\232\001\312A7\n" + + "\"EnablePluginInstanceActionResponse\022\021O" + + "perationMetadata\332A\016name,action_id\202\323\344\223\002I\"" + + "D/v1/{name=projects/*/locations/*/plugins/*/instances/*}:enableAction:\001*\022\227\002\n" + + "\033DisablePluginInstanceAction\022:.google.cloud." + + "apihub.v1.DisablePluginInstanceActionReq" + + "uest\032\035.google.longrunning.Operation\"\234\001\312A8\n" + + "#DisablePluginInstanceActionResponse\022\021" + + "OperationMetadata\332A\016name,action_id\202\323\344\223\002J" + + "\"E/v1/{name=projects/*/locations/*/plugins/*/instances/*}:disableAction:\001*\022\363\001\n" + + "\024UpdatePluginInstance\0223.google.cloud.apihu" + + "b.v1.UpdatePluginInstanceRequest\032&.googl" + + "e.cloud.apihub.v1.PluginInstance\"~\332A\033plu" + + "gin_instance,update_mask\202\323\344\223\002Z2G/v1/{plu" + + "gin_instance.name=projects/*/locations/*" + + "/plugins/*/instances/*}:\017plugin_instance\022\337\001\n" + + "\024DeletePluginInstance\0223.google.cloud" + + ".apihub.v1.DeletePluginInstanceRequest\032\035.google.longrunning.Operation\"s\312A*\n" + + "\025google.protobuf.Empty\022\021OperationMetadata\332A\004n" + + "ame\202\323\344\223\0029*7/v1/{name=projects/*/locations/*/plugins/*/instances/*}\022\237\002\n" + + "\036ManagePluginInstanceSourceData\022=.google.cloud.api" + + "hub.v1.ManagePluginInstanceSourceDataRequest\032>.google.cloud.apihub.v1.ManagePlug" + + "inInstanceSourceDataResponse\"~\332A(name,da" + + "ta_type,action,relative_path,data\202\323\344\223\002M\"" + + "H/v1/{name=projects/*/locations/*/plugin" + + "s/*/instances/*}:manageSourceData:\001*\032\253\001\312" + + "A\025apihub.googleapis.com\322A\217\001https://www.g" + + "oogleapis.com/auth/apihub.readonly,https://www.googleapis.com/auth/apihub.readwr" + + "ite,https://www.googleapis.com/auth/cloud-platformB\264\001\n" + + "\032com.google.cloud.apihub.v1B\022PluginServiceProtoP\001Z2cloud.google.co" + + "m/go/apihub/apiv1/apihubpb;apihubpb\252\002\026Go" + + "ogle.Cloud.ApiHub.V1\312\002\026Google\\Cloud\\ApiH" + + "ub\\V1\352\002\031Google::Cloud::ApiHub::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -618,6 +679,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CreateTime", "UpdateTime", "SourceProjectId", + "SourceEnvironmentsConfig", }); internal_static_google_cloud_apihub_v1_PluginInstance_AdditionalConfigEntry_descriptor = internal_static_google_cloud_apihub_v1_PluginInstance_descriptor.getNestedType(0); @@ -627,8 +689,24 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Key", "Value", }); - internal_static_google_cloud_apihub_v1_CurationConfig_descriptor = + internal_static_google_cloud_apihub_v1_PluginInstance_SourceEnvironmentsConfigEntry_descriptor = + internal_static_google_cloud_apihub_v1_PluginInstance_descriptor.getNestedType(1); + internal_static_google_cloud_apihub_v1_PluginInstance_SourceEnvironmentsConfigEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_PluginInstance_SourceEnvironmentsConfigEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_apihub_v1_SourceEnvironment_descriptor = getDescriptor().getMessageType(7); + internal_static_google_cloud_apihub_v1_SourceEnvironment_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_SourceEnvironment_descriptor, + new java.lang.String[] { + "SourceEnvironment", "SourceEnvironmentUri", "CreateTime", "UpdateTime", + }); + internal_static_google_cloud_apihub_v1_CurationConfig_descriptor = + getDescriptor().getMessageType(8); internal_static_google_cloud_apihub_v1_CurationConfig_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_CurationConfig_descriptor, @@ -644,7 +722,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Curation", }); internal_static_google_cloud_apihub_v1_ExecutionStatus_descriptor = - getDescriptor().getMessageType(8); + getDescriptor().getMessageType(9); internal_static_google_cloud_apihub_v1_ExecutionStatus_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ExecutionStatus_descriptor, @@ -657,10 +735,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ExecutionStatus_LastExecution_descriptor, new java.lang.String[] { - "Result", "ErrorMessage", "StartTime", "EndTime", + "Result", "ErrorMessage", "StartTime", "EndTime", "ResultMetadata", }); internal_static_google_cloud_apihub_v1_CreatePluginRequest_descriptor = - getDescriptor().getMessageType(9); + getDescriptor().getMessageType(10); internal_static_google_cloud_apihub_v1_CreatePluginRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_CreatePluginRequest_descriptor, @@ -668,7 +746,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PluginId", "Plugin", }); internal_static_google_cloud_apihub_v1_DeletePluginRequest_descriptor = - getDescriptor().getMessageType(10); + getDescriptor().getMessageType(11); internal_static_google_cloud_apihub_v1_DeletePluginRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DeletePluginRequest_descriptor, @@ -676,7 +754,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_ListPluginsRequest_descriptor = - getDescriptor().getMessageType(11); + getDescriptor().getMessageType(12); internal_static_google_cloud_apihub_v1_ListPluginsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListPluginsRequest_descriptor, @@ -684,7 +762,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "Filter", "PageSize", "PageToken", }); internal_static_google_cloud_apihub_v1_ListPluginsResponse_descriptor = - getDescriptor().getMessageType(12); + getDescriptor().getMessageType(13); internal_static_google_cloud_apihub_v1_ListPluginsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListPluginsResponse_descriptor, @@ -692,7 +770,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Plugins", "NextPageToken", }); internal_static_google_cloud_apihub_v1_CreatePluginInstanceRequest_descriptor = - getDescriptor().getMessageType(13); + getDescriptor().getMessageType(14); internal_static_google_cloud_apihub_v1_CreatePluginInstanceRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_CreatePluginInstanceRequest_descriptor, @@ -700,7 +778,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PluginInstanceId", "PluginInstance", }); internal_static_google_cloud_apihub_v1_ExecutePluginInstanceActionRequest_descriptor = - getDescriptor().getMessageType(14); + getDescriptor().getMessageType(15); internal_static_google_cloud_apihub_v1_ExecutePluginInstanceActionRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ExecutePluginInstanceActionRequest_descriptor, @@ -708,7 +786,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "ActionExecutionDetail", }); internal_static_google_cloud_apihub_v1_ActionExecutionDetail_descriptor = - getDescriptor().getMessageType(15); + getDescriptor().getMessageType(16); internal_static_google_cloud_apihub_v1_ActionExecutionDetail_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ActionExecutionDetail_descriptor, @@ -716,13 +794,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ActionId", }); internal_static_google_cloud_apihub_v1_ExecutePluginInstanceActionResponse_descriptor = - getDescriptor().getMessageType(16); + getDescriptor().getMessageType(17); internal_static_google_cloud_apihub_v1_ExecutePluginInstanceActionResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ExecutePluginInstanceActionResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_apihub_v1_GetPluginInstanceRequest_descriptor = - getDescriptor().getMessageType(17); + getDescriptor().getMessageType(18); internal_static_google_cloud_apihub_v1_GetPluginInstanceRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_GetPluginInstanceRequest_descriptor, @@ -730,7 +808,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_apihub_v1_ListPluginInstancesRequest_descriptor = - getDescriptor().getMessageType(18); + getDescriptor().getMessageType(19); internal_static_google_cloud_apihub_v1_ListPluginInstancesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListPluginInstancesRequest_descriptor, @@ -738,7 +816,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "Filter", "PageSize", "PageToken", }); internal_static_google_cloud_apihub_v1_ListPluginInstancesResponse_descriptor = - getDescriptor().getMessageType(19); + getDescriptor().getMessageType(20); internal_static_google_cloud_apihub_v1_ListPluginInstancesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_ListPluginInstancesResponse_descriptor, @@ -746,7 +824,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "PluginInstances", "NextPageToken", }); internal_static_google_cloud_apihub_v1_EnablePluginInstanceActionRequest_descriptor = - getDescriptor().getMessageType(20); + getDescriptor().getMessageType(21); internal_static_google_cloud_apihub_v1_EnablePluginInstanceActionRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_EnablePluginInstanceActionRequest_descriptor, @@ -754,13 +832,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "ActionId", }); internal_static_google_cloud_apihub_v1_EnablePluginInstanceActionResponse_descriptor = - getDescriptor().getMessageType(21); + getDescriptor().getMessageType(22); internal_static_google_cloud_apihub_v1_EnablePluginInstanceActionResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_EnablePluginInstanceActionResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_apihub_v1_DisablePluginInstanceActionRequest_descriptor = - getDescriptor().getMessageType(22); + getDescriptor().getMessageType(23); internal_static_google_cloud_apihub_v1_DisablePluginInstanceActionRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DisablePluginInstanceActionRequest_descriptor, @@ -768,13 +846,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "ActionId", }); internal_static_google_cloud_apihub_v1_DisablePluginInstanceActionResponse_descriptor = - getDescriptor().getMessageType(23); + getDescriptor().getMessageType(24); internal_static_google_cloud_apihub_v1_DisablePluginInstanceActionResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DisablePluginInstanceActionResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_apihub_v1_UpdatePluginInstanceRequest_descriptor = - getDescriptor().getMessageType(24); + getDescriptor().getMessageType(25); internal_static_google_cloud_apihub_v1_UpdatePluginInstanceRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_UpdatePluginInstanceRequest_descriptor, @@ -782,13 +860,27 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "PluginInstance", "UpdateMask", }); internal_static_google_cloud_apihub_v1_DeletePluginInstanceRequest_descriptor = - getDescriptor().getMessageType(25); + getDescriptor().getMessageType(26); internal_static_google_cloud_apihub_v1_DeletePluginInstanceRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_apihub_v1_DeletePluginInstanceRequest_descriptor, new java.lang.String[] { "Name", }); + internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataRequest_descriptor = + getDescriptor().getMessageType(27); + internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataRequest_descriptor, + new java.lang.String[] { + "Name", "DataType", "Action", "RelativePath", "Data", + }); + internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataResponse_descriptor = + getDescriptor().getMessageType(28); + internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_ManagePluginInstanceSourceDataResponse_descriptor, + new java.lang.String[] {}); descriptor.resolveAllFeaturesImmutable(); com.google.api.AnnotationsProto.getDescriptor(); com.google.api.ClientProto.getDescriptor(); diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ProvisioningServiceProto.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ProvisioningServiceProto.java index e2b5d0695b15..72ae81d1a247 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ProvisioningServiceProto.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ProvisioningServiceProto.java @@ -60,6 +60,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_apihub_v1_LookupApiHubInstanceResponse_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_apihub_v1_LookupApiHubInstanceResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_apihub_v1_UpdateApiHubInstanceRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_apihub_v1_UpdateApiHubInstanceRequest_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -76,51 +80,65 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "oto\032\031google/api/resource.proto\032*google/c" + "loud/apihub/v1/common_fields.proto\032#goog" + "le/longrunning/operations.proto\032\033google/" - + "protobuf/empty.proto\"\304\001\n\033CreateApiHubIns" - + "tanceRequest\022:\n\006parent\030\001 \001(\tB*\342A\001\002\372A#\n!l" - + "ocations.googleapis.com/Location\022!\n\023api_" - + "hub_instance_id\030\002 \001(\tB\004\342A\001\001\022F\n\020api_hub_i" - + "nstance\030\003 \001(\0132&.google.cloud.apihub.v1.A" - + "piHubInstanceB\004\342A\001\002\"Z\n\033DeleteApiHubInsta" - + "nceRequest\022;\n\004name\030\001 \001(\tB-\342A\001\002\372A&\n$apihu" - + "b.googleapis.com/ApiHubInstance\"W\n\030GetAp" - + "iHubInstanceRequest\022;\n\004name\030\001 \001(\tB-\342A\001\002\372" - + "A&\n$apihub.googleapis.com/ApiHubInstance" - + "\"\\\n\033LookupApiHubInstanceRequest\022=\n\006paren" - + "t\030\001 \001(\tB-\342A\001\002\372A&\022$apihub.googleapis.com/" - + "ApiHubInstance\"`\n\034LookupApiHubInstanceRe" - + "sponse\022@\n\020api_hub_instance\030\001 \001(\0132&.googl" - + "e.cloud.apihub.v1.ApiHubInstance2\315\007\n\014Pro" - + "visioning\022\216\002\n\024CreateApiHubInstance\0223.goo" - + "gle.cloud.apihub.v1.CreateApiHubInstance" - + "Request\032\035.google.longrunning.Operation\"\241" - + "\001\312A#\n\016ApiHubInstance\022\021OperationMetadata\332" - + "A+parent,api_hub_instance,api_hub_instan" - + "ce_id\202\323\344\223\002G\"3/v1/{parent=projects/*/loca" - + "tions/*}/apiHubInstances:\020api_hub_instan" - + "ce\022\333\001\n\024DeleteApiHubInstance\0223.google.clo" - + "ud.apihub.v1.DeleteApiHubInstanceRequest" - + "\032\035.google.longrunning.Operation\"o\312A*\n\025go" - + "ogle.protobuf.Empty\022\021OperationMetadata\332A" - + "\004name\202\323\344\223\0025*3/v1/{name=projects/*/locati" - + "ons/*/apiHubInstances/*}\022\261\001\n\021GetApiHubIn" - + "stance\0220.google.cloud.apihub.v1.GetApiHu" - + "bInstanceRequest\032&.google.cloud.apihub.v" - + "1.ApiHubInstance\"B\332A\004name\202\323\344\223\0025\0223/v1/{na" - + "me=projects/*/locations/*/apiHubInstance" - + "s/*}\022\316\001\n\024LookupApiHubInstance\0223.google.c" - + "loud.apihub.v1.LookupApiHubInstanceReque" - + "st\0324.google.cloud.apihub.v1.LookupApiHub" - + "InstanceResponse\"K\332A\006parent\202\323\344\223\002<\022:/v1/{" - + "parent=projects/*/locations/*}/apiHubIns" - + "tances:lookup\032I\312A\025apihub.googleapis.com\322" - + "A.https://www.googleapis.com/auth/cloud-" - + "platformB\272\001\n\032com.google.cloud.apihub.v1B" - + "\030ProvisioningServiceProtoP\001Z2cloud.googl" - + "e.com/go/apihub/apiv1/apihubpb;apihubpb\252" - + "\002\026Google.Cloud.ApiHub.V1\312\002\026Google\\Cloud\\" - + "ApiHub\\V1\352\002\031Google::Cloud::ApiHub::V1b\006p" - + "roto3" + + "protobuf/empty.proto\032 google/protobuf/fi" + + "eld_mask.proto\"\304\001\n\033CreateApiHubInstanceR" + + "equest\022:\n\006parent\030\001 \001(\tB*\342A\001\002\372A#\n!locatio" + + "ns.googleapis.com/Location\022!\n\023api_hub_in" + + "stance_id\030\002 \001(\tB\004\342A\001\001\022F\n\020api_hub_instanc" + + "e\030\003 \001(\0132&.google.cloud.apihub.v1.ApiHubI" + + "nstanceB\004\342A\001\002\"Z\n\033DeleteApiHubInstanceReq" + + "uest\022;\n\004name\030\001 \001(\tB-\342A\001\002\372A&\n$apihub.goog" + + "leapis.com/ApiHubInstance\"W\n\030GetApiHubIn" + + "stanceRequest\022;\n\004name\030\001 \001(\tB-\342A\001\002\372A&\n$ap" + + "ihub.googleapis.com/ApiHubInstance\"\\\n\033Lo" + + "okupApiHubInstanceRequest\022=\n\006parent\030\001 \001(" + + "\tB-\342A\001\002\372A&\022$apihub.googleapis.com/ApiHub" + + "Instance\"`\n\034LookupApiHubInstanceResponse" + + "\022@\n\020api_hub_instance\030\001 \001(\0132&.google.clou" + + "d.apihub.v1.ApiHubInstance\"\234\001\n\033UpdateApi" + + "HubInstanceRequest\022F\n\020api_hub_instance\030\001" + + " \001(\0132&.google.cloud.apihub.v1.ApiHubInst" + + "anceB\004\342A\001\002\0225\n\013update_mask\030\002 \001(\0132\032.google" + + ".protobuf.FieldMaskB\004\342A\001\0022\303\n\n\014Provisioni" + + "ng\022\216\002\n\024CreateApiHubInstance\0223.google.clo" + + "ud.apihub.v1.CreateApiHubInstanceRequest" + + "\032\035.google.longrunning.Operation\"\241\001\312A#\n\016A" + + "piHubInstance\022\021OperationMetadata\332A+paren" + + "t,api_hub_instance,api_hub_instance_id\202\323" + + "\344\223\002G\"3/v1/{parent=projects/*/locations/*" + + "}/apiHubInstances:\020api_hub_instance\022\333\001\n\024" + + "DeleteApiHubInstance\0223.google.cloud.apih" + + "ub.v1.DeleteApiHubInstanceRequest\032\035.goog" + + "le.longrunning.Operation\"o\312A*\n\025google.pr" + + "otobuf.Empty\022\021OperationMetadata\332A\004name\202\323" + + "\344\223\0025*3/v1/{name=projects/*/locations/*/a" + + "piHubInstances/*}\022\261\001\n\021GetApiHubInstance\022" + + "0.google.cloud.apihub.v1.GetApiHubInstan" + + "ceRequest\032&.google.cloud.apihub.v1.ApiHu" + + "bInstance\"B\332A\004name\202\323\344\223\0025\0223/v1/{name=proj" + + "ects/*/locations/*/apiHubInstances/*}\022\220\002" + + "\n\024UpdateApiHubInstance\0223.google.cloud.ap" + + "ihub.v1.UpdateApiHubInstanceRequest\032\035.go" + + "ogle.longrunning.Operation\"\243\001\312A#\n\016ApiHub" + + "Instance\022\021OperationMetadata\332A\034api_hub_in" + + "stance,update_mask\202\323\344\223\002X2D/v1/{api_hub_i" + + "nstance.name=projects/*/locations/*/apiH" + + "ubInstances/*}:\020api_hub_instance\022\316\001\n\024Loo" + + "kupApiHubInstance\0223.google.cloud.apihub." + + "v1.LookupApiHubInstanceRequest\0324.google." + + "cloud.apihub.v1.LookupApiHubInstanceResp" + + "onse\"K\332A\006parent\202\323\344\223\002<\022:/v1/{parent=proje" + + "cts/*/locations/*}/apiHubInstances:looku" + + "p\032\253\001\312A\025apihub.googleapis.com\322A\217\001https://" + + "www.googleapis.com/auth/apihub.readonly," + + "https://www.googleapis.com/auth/apihub.r" + + "eadwrite,https://www.googleapis.com/auth" + + "/cloud-platformB\272\001\n\032com.google.cloud.api" + + "hub.v1B\030ProvisioningServiceProtoP\001Z2clou" + + "d.google.com/go/apihub/apiv1/apihubpb;ap" + + "ihubpb\252\002\026Google.Cloud.ApiHub.V1\312\002\026Google" + + "\\Cloud\\ApiHub\\V1\352\002\031Google::Cloud::ApiHub" + + "::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -133,6 +151,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.cloud.apihub.v1.CommonFieldsProto.getDescriptor(), com.google.longrunning.OperationsProto.getDescriptor(), com.google.protobuf.EmptyProto.getDescriptor(), + com.google.protobuf.FieldMaskProto.getDescriptor(), }); internal_static_google_cloud_apihub_v1_CreateApiHubInstanceRequest_descriptor = getDescriptor().getMessageType(0); @@ -174,6 +193,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "ApiHubInstance", }); + internal_static_google_cloud_apihub_v1_UpdateApiHubInstanceRequest_descriptor = + getDescriptor().getMessageType(5); + internal_static_google_cloud_apihub_v1_UpdateApiHubInstanceRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_apihub_v1_UpdateApiHubInstanceRequest_descriptor, + new java.lang.String[] { + "ApiHubInstance", "UpdateMask", + }); descriptor.resolveAllFeaturesImmutable(); com.google.api.AnnotationsProto.getDescriptor(); com.google.api.ClientProto.getDescriptor(); @@ -182,6 +209,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.cloud.apihub.v1.CommonFieldsProto.getDescriptor(); com.google.longrunning.OperationsProto.getDescriptor(); com.google.protobuf.EmptyProto.getDescriptor(); + com.google.protobuf.FieldMaskProto.getDescriptor(); com.google.protobuf.ExtensionRegistry registry = com.google.protobuf.ExtensionRegistry.newInstance(); registry.add(com.google.api.ClientProto.defaultHost); diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsRequest.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsRequest.java new file mode 100644 index 000000000000..c5d0a10fcb57 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsRequest.java @@ -0,0 +1,1265 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The
                      + * [RetrieveApiViews][google.cloud.apihub.v1.ApiHub.RetrieveApiViews]
                      + * method's request.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.RetrieveApiViewsRequest} + */ +@com.google.protobuf.Generated +public final class RetrieveApiViewsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.RetrieveApiViewsRequest) + RetrieveApiViewsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "RetrieveApiViewsRequest"); + } + + // Use RetrieveApiViewsRequest.newBuilder() to construct. + private RetrieveApiViewsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private RetrieveApiViewsRequest() { + parent_ = ""; + filter_ = ""; + pageToken_ = ""; + view_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_RetrieveApiViewsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_RetrieveApiViewsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.RetrieveApiViewsRequest.class, + com.google.cloud.apihub.v1.RetrieveApiViewsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
                      +   * Required. The parent resource name.
                      +   * Format: `projects/{project}/locations/{location}`.
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The parent resource name.
                      +   * Format: `projects/{project}/locations/{location}`.
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object filter_ = ""; + + /** + * + * + *
                      +   * Optional. The filter expression.
                      +   * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Optional. The filter expression.
                      +   * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 3; + private int pageSize_ = 0; + + /** + * + * + *
                      +   * Optional. The maximum number of results to return. Default to 100.
                      +   * 
                      + * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
                      +   * Optional. A page token, received from a previous `RetrieveApiViews`
                      +   * call. Provide this to retrieve the subsequent page.
                      +   * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Optional. A page token, received from a previous `RetrieveApiViews`
                      +   * call. Provide this to retrieve the subsequent page.
                      +   * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VIEW_FIELD_NUMBER = 5; + private int view_ = 0; + + /** + * + * + *
                      +   * Required. The view type to return.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApiViewType view = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for view. + */ + @java.lang.Override + public int getViewValue() { + return view_; + } + + /** + * + * + *
                      +   * Required. The view type to return.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApiViewType view = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The view. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiViewType getView() { + com.google.cloud.apihub.v1.ApiViewType result = + com.google.cloud.apihub.v1.ApiViewType.forNumber(view_); + return result == null ? com.google.cloud.apihub.v1.ApiViewType.UNRECOGNIZED : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, filter_); + } + if (pageSize_ != 0) { + output.writeInt32(3, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, pageToken_); + } + if (view_ != com.google.cloud.apihub.v1.ApiViewType.API_VIEW_TYPE_UNSPECIFIED.getNumber()) { + output.writeEnum(5, view_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, filter_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, pageToken_); + } + if (view_ != com.google.cloud.apihub.v1.ApiViewType.API_VIEW_TYPE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, view_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.RetrieveApiViewsRequest)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.RetrieveApiViewsRequest other = + (com.google.cloud.apihub.v1.RetrieveApiViewsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (view_ != other.view_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + VIEW_FIELD_NUMBER; + hash = (53 * hash) + view_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.RetrieveApiViewsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The
                      +   * [RetrieveApiViews][google.cloud.apihub.v1.ApiHub.RetrieveApiViews]
                      +   * method's request.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.RetrieveApiViewsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.RetrieveApiViewsRequest) + com.google.cloud.apihub.v1.RetrieveApiViewsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_RetrieveApiViewsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_RetrieveApiViewsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.RetrieveApiViewsRequest.class, + com.google.cloud.apihub.v1.RetrieveApiViewsRequest.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.RetrieveApiViewsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + filter_ = ""; + pageSize_ = 0; + pageToken_ = ""; + view_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_RetrieveApiViewsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.RetrieveApiViewsRequest getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.RetrieveApiViewsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.RetrieveApiViewsRequest build() { + com.google.cloud.apihub.v1.RetrieveApiViewsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.RetrieveApiViewsRequest buildPartial() { + com.google.cloud.apihub.v1.RetrieveApiViewsRequest result = + new com.google.cloud.apihub.v1.RetrieveApiViewsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.RetrieveApiViewsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.filter_ = filter_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.pageToken_ = pageToken_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.view_ = view_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.RetrieveApiViewsRequest) { + return mergeFrom((com.google.cloud.apihub.v1.RetrieveApiViewsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.RetrieveApiViewsRequest other) { + if (other == com.google.cloud.apihub.v1.RetrieveApiViewsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (other.view_ != 0) { + setViewValue(other.getViewValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + filter_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 24: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000004; + break; + } // case 24 + case 34: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 40: + { + view_ = input.readEnum(); + bitField0_ |= 0x00000010; + break; + } // case 40 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
                      +     * Required. The parent resource name.
                      +     * Format: `projects/{project}/locations/{location}`.
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The parent resource name.
                      +     * Format: `projects/{project}/locations/{location}`.
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The parent resource name.
                      +     * Format: `projects/{project}/locations/{location}`.
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The parent resource name.
                      +     * Format: `projects/{project}/locations/{location}`.
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The parent resource name.
                      +     * Format: `projects/{project}/locations/{location}`.
                      +     * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + + /** + * + * + *
                      +     * Optional. The filter expression.
                      +     * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Optional. The filter expression.
                      +     * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Optional. The filter expression.
                      +     * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + filter_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The filter expression.
                      +     * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + filter_ = getDefaultInstance().getFilter(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The filter expression.
                      +     * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
                      +     * Optional. The maximum number of results to return. Default to 100.
                      +     * 
                      + * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
                      +     * Optional. The maximum number of results to return. Default to 100.
                      +     * 
                      + * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The maximum number of results to return. Default to 100.
                      +     * 
                      + * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000004); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
                      +     * Optional. A page token, received from a previous `RetrieveApiViews`
                      +     * call. Provide this to retrieve the subsequent page.
                      +     * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Optional. A page token, received from a previous `RetrieveApiViews`
                      +     * call. Provide this to retrieve the subsequent page.
                      +     * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Optional. A page token, received from a previous `RetrieveApiViews`
                      +     * call. Provide this to retrieve the subsequent page.
                      +     * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. A page token, received from a previous `RetrieveApiViews`
                      +     * call. Provide this to retrieve the subsequent page.
                      +     * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. A page token, received from a previous `RetrieveApiViews`
                      +     * call. Provide this to retrieve the subsequent page.
                      +     * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private int view_ = 0; + + /** + * + * + *
                      +     * Required. The view type to return.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApiViewType view = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for view. + */ + @java.lang.Override + public int getViewValue() { + return view_; + } + + /** + * + * + *
                      +     * Required. The view type to return.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApiViewType view = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The enum numeric value on the wire for view to set. + * @return This builder for chaining. + */ + public Builder setViewValue(int value) { + view_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The view type to return.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApiViewType view = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The view. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiViewType getView() { + com.google.cloud.apihub.v1.ApiViewType result = + com.google.cloud.apihub.v1.ApiViewType.forNumber(view_); + return result == null ? com.google.cloud.apihub.v1.ApiViewType.UNRECOGNIZED : result; + } + + /** + * + * + *
                      +     * Required. The view type to return.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApiViewType view = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The view to set. + * @return This builder for chaining. + */ + public Builder setView(com.google.cloud.apihub.v1.ApiViewType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000010; + view_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The view type to return.
                      +     * 
                      + * + * .google.cloud.apihub.v1.ApiViewType view = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearView() { + bitField0_ = (bitField0_ & ~0x00000010); + view_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.RetrieveApiViewsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.RetrieveApiViewsRequest) + private static final com.google.cloud.apihub.v1.RetrieveApiViewsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.RetrieveApiViewsRequest(); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RetrieveApiViewsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.RetrieveApiViewsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsRequestOrBuilder.java new file mode 100644 index 000000000000..76b9d9da14c8 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsRequestOrBuilder.java @@ -0,0 +1,155 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface RetrieveApiViewsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.RetrieveApiViewsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The parent resource name.
                      +   * Format: `projects/{project}/locations/{location}`.
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
                      +   * Required. The parent resource name.
                      +   * Format: `projects/{project}/locations/{location}`.
                      +   * 
                      + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
                      +   * Optional. The filter expression.
                      +   * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
                      +   * Optional. The filter expression.
                      +   * 
                      + * + * string filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
                      +   * Optional. The maximum number of results to return. Default to 100.
                      +   * 
                      + * + * int32 page_size = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
                      +   * Optional. A page token, received from a previous `RetrieveApiViews`
                      +   * call. Provide this to retrieve the subsequent page.
                      +   * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
                      +   * Optional. A page token, received from a previous `RetrieveApiViews`
                      +   * call. Provide this to retrieve the subsequent page.
                      +   * 
                      + * + * string page_token = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
                      +   * Required. The view type to return.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApiViewType view = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for view. + */ + int getViewValue(); + + /** + * + * + *
                      +   * Required. The view type to return.
                      +   * 
                      + * + * .google.cloud.apihub.v1.ApiViewType view = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The view. + */ + com.google.cloud.apihub.v1.ApiViewType getView(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsResponse.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsResponse.java new file mode 100644 index 000000000000..bdae3ca727ca --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsResponse.java @@ -0,0 +1,1160 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The
                      + * [RetrieveApiViews][google.cloud.apihub.v1.ApiHub.RetrieveApiViews]
                      + * method's response.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.RetrieveApiViewsResponse} + */ +@com.google.protobuf.Generated +public final class RetrieveApiViewsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.RetrieveApiViewsResponse) + RetrieveApiViewsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "RetrieveApiViewsResponse"); + } + + // Use RetrieveApiViewsResponse.newBuilder() to construct. + private RetrieveApiViewsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private RetrieveApiViewsResponse() { + apiViews_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_RetrieveApiViewsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_RetrieveApiViewsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.RetrieveApiViewsResponse.class, + com.google.cloud.apihub.v1.RetrieveApiViewsResponse.Builder.class); + } + + public static final int API_VIEWS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List apiViews_; + + /** + * + * + *
                      +   * Output only. The list of API views.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.List getApiViewsList() { + return apiViews_; + } + + /** + * + * + *
                      +   * Output only. The list of API views.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.List + getApiViewsOrBuilderList() { + return apiViews_; + } + + /** + * + * + *
                      +   * Output only. The list of API views.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public int getApiViewsCount() { + return apiViews_.size(); + } + + /** + * + * + *
                      +   * Output only. The list of API views.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiView getApiViews(int index) { + return apiViews_.get(index); + } + + /** + * + * + *
                      +   * Output only. The list of API views.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiViewOrBuilder getApiViewsOrBuilder(int index) { + return apiViews_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
                      +   * Next page token.
                      +   * 
                      + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Next page token.
                      +   * 
                      + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < apiViews_.size(); i++) { + output.writeMessage(1, apiViews_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < apiViews_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, apiViews_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.RetrieveApiViewsResponse)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.RetrieveApiViewsResponse other = + (com.google.cloud.apihub.v1.RetrieveApiViewsResponse) obj; + + if (!getApiViewsList().equals(other.getApiViewsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getApiViewsCount() > 0) { + hash = (37 * hash) + API_VIEWS_FIELD_NUMBER; + hash = (53 * hash) + getApiViewsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.RetrieveApiViewsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The
                      +   * [RetrieveApiViews][google.cloud.apihub.v1.ApiHub.RetrieveApiViews]
                      +   * method's response.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.RetrieveApiViewsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.RetrieveApiViewsResponse) + com.google.cloud.apihub.v1.RetrieveApiViewsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_RetrieveApiViewsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_RetrieveApiViewsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.RetrieveApiViewsResponse.class, + com.google.cloud.apihub.v1.RetrieveApiViewsResponse.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.RetrieveApiViewsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (apiViewsBuilder_ == null) { + apiViews_ = java.util.Collections.emptyList(); + } else { + apiViews_ = null; + apiViewsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ApiHubServiceProto + .internal_static_google_cloud_apihub_v1_RetrieveApiViewsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.RetrieveApiViewsResponse getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.RetrieveApiViewsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.RetrieveApiViewsResponse build() { + com.google.cloud.apihub.v1.RetrieveApiViewsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.RetrieveApiViewsResponse buildPartial() { + com.google.cloud.apihub.v1.RetrieveApiViewsResponse result = + new com.google.cloud.apihub.v1.RetrieveApiViewsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.apihub.v1.RetrieveApiViewsResponse result) { + if (apiViewsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + apiViews_ = java.util.Collections.unmodifiableList(apiViews_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.apiViews_ = apiViews_; + } else { + result.apiViews_ = apiViewsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.apihub.v1.RetrieveApiViewsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.RetrieveApiViewsResponse) { + return mergeFrom((com.google.cloud.apihub.v1.RetrieveApiViewsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.RetrieveApiViewsResponse other) { + if (other == com.google.cloud.apihub.v1.RetrieveApiViewsResponse.getDefaultInstance()) + return this; + if (apiViewsBuilder_ == null) { + if (!other.apiViews_.isEmpty()) { + if (apiViews_.isEmpty()) { + apiViews_ = other.apiViews_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureApiViewsIsMutable(); + apiViews_.addAll(other.apiViews_); + } + onChanged(); + } + } else { + if (!other.apiViews_.isEmpty()) { + if (apiViewsBuilder_.isEmpty()) { + apiViewsBuilder_.dispose(); + apiViewsBuilder_ = null; + apiViews_ = other.apiViews_; + bitField0_ = (bitField0_ & ~0x00000001); + apiViewsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetApiViewsFieldBuilder() + : null; + } else { + apiViewsBuilder_.addAllMessages(other.apiViews_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.apihub.v1.ApiView m = + input.readMessage( + com.google.cloud.apihub.v1.ApiView.parser(), extensionRegistry); + if (apiViewsBuilder_ == null) { + ensureApiViewsIsMutable(); + apiViews_.add(m); + } else { + apiViewsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List apiViews_ = + java.util.Collections.emptyList(); + + private void ensureApiViewsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + apiViews_ = new java.util.ArrayList(apiViews_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.ApiView, + com.google.cloud.apihub.v1.ApiView.Builder, + com.google.cloud.apihub.v1.ApiViewOrBuilder> + apiViewsBuilder_; + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List getApiViewsList() { + if (apiViewsBuilder_ == null) { + return java.util.Collections.unmodifiableList(apiViews_); + } else { + return apiViewsBuilder_.getMessageList(); + } + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public int getApiViewsCount() { + if (apiViewsBuilder_ == null) { + return apiViews_.size(); + } else { + return apiViewsBuilder_.getCount(); + } + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apihub.v1.ApiView getApiViews(int index) { + if (apiViewsBuilder_ == null) { + return apiViews_.get(index); + } else { + return apiViewsBuilder_.getMessage(index); + } + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setApiViews(int index, com.google.cloud.apihub.v1.ApiView value) { + if (apiViewsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureApiViewsIsMutable(); + apiViews_.set(index, value); + onChanged(); + } else { + apiViewsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setApiViews( + int index, com.google.cloud.apihub.v1.ApiView.Builder builderForValue) { + if (apiViewsBuilder_ == null) { + ensureApiViewsIsMutable(); + apiViews_.set(index, builderForValue.build()); + onChanged(); + } else { + apiViewsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addApiViews(com.google.cloud.apihub.v1.ApiView value) { + if (apiViewsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureApiViewsIsMutable(); + apiViews_.add(value); + onChanged(); + } else { + apiViewsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addApiViews(int index, com.google.cloud.apihub.v1.ApiView value) { + if (apiViewsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureApiViewsIsMutable(); + apiViews_.add(index, value); + onChanged(); + } else { + apiViewsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addApiViews(com.google.cloud.apihub.v1.ApiView.Builder builderForValue) { + if (apiViewsBuilder_ == null) { + ensureApiViewsIsMutable(); + apiViews_.add(builderForValue.build()); + onChanged(); + } else { + apiViewsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addApiViews( + int index, com.google.cloud.apihub.v1.ApiView.Builder builderForValue) { + if (apiViewsBuilder_ == null) { + ensureApiViewsIsMutable(); + apiViews_.add(index, builderForValue.build()); + onChanged(); + } else { + apiViewsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addAllApiViews( + java.lang.Iterable values) { + if (apiViewsBuilder_ == null) { + ensureApiViewsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, apiViews_); + onChanged(); + } else { + apiViewsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearApiViews() { + if (apiViewsBuilder_ == null) { + apiViews_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + apiViewsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder removeApiViews(int index) { + if (apiViewsBuilder_ == null) { + ensureApiViewsIsMutable(); + apiViews_.remove(index); + onChanged(); + } else { + apiViewsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apihub.v1.ApiView.Builder getApiViewsBuilder(int index) { + return internalGetApiViewsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apihub.v1.ApiViewOrBuilder getApiViewsOrBuilder(int index) { + if (apiViewsBuilder_ == null) { + return apiViews_.get(index); + } else { + return apiViewsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List + getApiViewsOrBuilderList() { + if (apiViewsBuilder_ != null) { + return apiViewsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(apiViews_); + } + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apihub.v1.ApiView.Builder addApiViewsBuilder() { + return internalGetApiViewsFieldBuilder() + .addBuilder(com.google.cloud.apihub.v1.ApiView.getDefaultInstance()); + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apihub.v1.ApiView.Builder addApiViewsBuilder(int index) { + return internalGetApiViewsFieldBuilder() + .addBuilder(index, com.google.cloud.apihub.v1.ApiView.getDefaultInstance()); + } + + /** + * + * + *
                      +     * Output only. The list of API views.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List getApiViewsBuilderList() { + return internalGetApiViewsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.ApiView, + com.google.cloud.apihub.v1.ApiView.Builder, + com.google.cloud.apihub.v1.ApiViewOrBuilder> + internalGetApiViewsFieldBuilder() { + if (apiViewsBuilder_ == null) { + apiViewsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.ApiView, + com.google.cloud.apihub.v1.ApiView.Builder, + com.google.cloud.apihub.v1.ApiViewOrBuilder>( + apiViews_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + apiViews_ = null; + } + return apiViewsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
                      +     * Next page token.
                      +     * 
                      + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Next page token.
                      +     * 
                      + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Next page token.
                      +     * 
                      + * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Next page token.
                      +     * 
                      + * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Next page token.
                      +     * 
                      + * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.RetrieveApiViewsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.RetrieveApiViewsResponse) + private static final com.google.cloud.apihub.v1.RetrieveApiViewsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.RetrieveApiViewsResponse(); + } + + public static com.google.cloud.apihub.v1.RetrieveApiViewsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RetrieveApiViewsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.RetrieveApiViewsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsResponseOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsResponseOrBuilder.java new file mode 100644 index 000000000000..a00f51814c91 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RetrieveApiViewsResponseOrBuilder.java @@ -0,0 +1,119 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/apihub_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface RetrieveApiViewsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.RetrieveApiViewsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Output only. The list of API views.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.List getApiViewsList(); + + /** + * + * + *
                      +   * Output only. The list of API views.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.apihub.v1.ApiView getApiViews(int index); + + /** + * + * + *
                      +   * Output only. The list of API views.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + int getApiViewsCount(); + + /** + * + * + *
                      +   * Output only. The list of API views.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.List getApiViewsOrBuilderList(); + + /** + * + * + *
                      +   * Output only. The list of API views.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.ApiView api_views = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.apihub.v1.ApiViewOrBuilder getApiViewsOrBuilder(int index); + + /** + * + * + *
                      +   * Next page token.
                      +   * 
                      + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
                      +   * Next page token.
                      +   * 
                      + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RuntimeProjectAttachmentServiceProto.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RuntimeProjectAttachmentServiceProto.java index ccbe60cd2c33..7b5d1b095e5e 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RuntimeProjectAttachmentServiceProto.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/RuntimeProjectAttachmentServiceProto.java @@ -124,7 +124,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\0132\032.google.protobuf.TimestampB\004\342A\001\003:\311\001\352A\305\001\n" + ".apihub.googleapis.com/RuntimeProjectAttachment\022^projects/{project}/locations" + "/{location}/runtimeProjectAttachments/{runtime_project_attachment}*\031runtimeProje" - + "ctAttachments2\030runtimeProjectAttachment2\254\n\n" + + "ctAttachments2\030runtimeProjectAttachment2\217\013\n" + "\037RuntimeProjectAttachmentService\022\267\002\n" + "\036CreateRuntimeProjectAttachment\022=.google." + "cloud.apihub.v1.CreateRuntimeProjectAttachmentRequest\0320.google.cloud.apihub.v1.R" @@ -148,12 +148,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "meProjectAttachmentRequest\032>.google.cloud.apihub.v1.LookupRuntimeProjectAttachme" + "ntResponse\"O\332A\004name\202\323\344\223\002B\022@/v1/{name=pro" + "jects/*/locations/*}:lookupRuntimeProjec" - + "tAttachment\032I\312A\025apihub.googleapis.com\322A." - + "https://www.googleapis.com/auth/cloud-platformB\306\001\n" - + "\032com.google.cloud.apihub.v1B$RuntimeProjectAttachmentServiceProtoP\001Z2c" - + "loud.google.com/go/apihub/apiv1/apihubpb" - + ";apihubpb\252\002\026Google.Cloud.ApiHub.V1\312\002\026Goo" - + "gle\\Cloud\\ApiHub\\V1\352\002\031Google::Cloud::ApiHub::V1b\006proto3" + + "tAttachment\032\253\001\312A\025apihub.googleapis.com\322A" + + "\217\001https://www.googleapis.com/auth/apihub.readonly,https://www.googleapis.com/aut" + + "h/apihub.readwrite,https://www.googleapis.com/auth/cloud-platformB\306\001\n" + + "\032com.google.cloud.apihub.v1B$RuntimeProjectAttachme" + + "ntServiceProtoP\001Z2cloud.google.com/go/ap" + + "ihub/apiv1/apihubpb;apihubpb\252\002\026Google.Cl" + + "oud.ApiHub.V1\312\002\026Google\\Cloud\\ApiHub\\V1\352\002" + + "\031Google::Cloud::ApiHub::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SourceEnvironment.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SourceEnvironment.java new file mode 100644 index 000000000000..9b91c09a3940 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SourceEnvironment.java @@ -0,0 +1,1394 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/plugin_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Message representing the source environment details.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.SourceEnvironment} + */ +@com.google.protobuf.Generated +public final class SourceEnvironment extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.SourceEnvironment) + SourceEnvironmentOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SourceEnvironment"); + } + + // Use SourceEnvironment.newBuilder() to construct. + private SourceEnvironment(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private SourceEnvironment() { + sourceEnvironment_ = ""; + sourceEnvironmentUri_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_SourceEnvironment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_SourceEnvironment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.SourceEnvironment.class, + com.google.cloud.apihub.v1.SourceEnvironment.Builder.class); + } + + private int bitField0_; + public static final int SOURCE_ENVIRONMENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object sourceEnvironment_ = ""; + + /** + * + * + *
                      +   * Required. The name of the environment at the source. This should map to
                      +   * [Deployment][google.cloud.apihub.v1.SourceEnvironment.source_environment].
                      +   * 
                      + * + * string source_environment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The sourceEnvironment. + */ + @java.lang.Override + public java.lang.String getSourceEnvironment() { + java.lang.Object ref = sourceEnvironment_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sourceEnvironment_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Required. The name of the environment at the source. This should map to
                      +   * [Deployment][google.cloud.apihub.v1.SourceEnvironment.source_environment].
                      +   * 
                      + * + * string source_environment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for sourceEnvironment. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSourceEnvironmentBytes() { + java.lang.Object ref = sourceEnvironment_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sourceEnvironment_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SOURCE_ENVIRONMENT_URI_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object sourceEnvironmentUri_ = ""; + + /** + * + * + *
                      +   * The location where additional information about source environments can be
                      +   * found. The location should be relative path of the environment manifest
                      +   * with respect to a plugin instance.
                      +   * 
                      + * + * string source_environment_uri = 3; + * + * @return The sourceEnvironmentUri. + */ + @java.lang.Override + public java.lang.String getSourceEnvironmentUri() { + java.lang.Object ref = sourceEnvironmentUri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sourceEnvironmentUri_ = s; + return s; + } + } + + /** + * + * + *
                      +   * The location where additional information about source environments can be
                      +   * found. The location should be relative path of the environment manifest
                      +   * with respect to a plugin instance.
                      +   * 
                      + * + * string source_environment_uri = 3; + * + * @return The bytes for sourceEnvironmentUri. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSourceEnvironmentUriBytes() { + java.lang.Object ref = sourceEnvironmentUri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sourceEnvironmentUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 4; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
                      +   * Optional. The time at which the environment was created at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Optional. The time at which the environment was created at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
                      +   * Optional. The time at which the environment was created at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp updateTime_; + + /** + * + * + *
                      +   * Optional. The time at which the environment was last updated at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Optional. The time at which the environment was last updated at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + /** + * + * + *
                      +   * Optional. The time at which the environment was last updated at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceEnvironment_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, sourceEnvironment_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceEnvironmentUri_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, sourceEnvironmentUri_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(4, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(5, getUpdateTime()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceEnvironment_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, sourceEnvironment_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceEnvironmentUri_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, sourceEnvironmentUri_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getUpdateTime()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.SourceEnvironment)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.SourceEnvironment other = + (com.google.cloud.apihub.v1.SourceEnvironment) obj; + + if (!getSourceEnvironment().equals(other.getSourceEnvironment())) return false; + if (!getSourceEnvironmentUri().equals(other.getSourceEnvironmentUri())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + SOURCE_ENVIRONMENT_FIELD_NUMBER; + hash = (53 * hash) + getSourceEnvironment().hashCode(); + hash = (37 * hash) + SOURCE_ENVIRONMENT_URI_FIELD_NUMBER; + hash = (53 * hash) + getSourceEnvironmentUri().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.SourceEnvironment prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Message representing the source environment details.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.SourceEnvironment} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.SourceEnvironment) + com.google.cloud.apihub.v1.SourceEnvironmentOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_SourceEnvironment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_SourceEnvironment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.SourceEnvironment.class, + com.google.cloud.apihub.v1.SourceEnvironment.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.SourceEnvironment.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetCreateTimeFieldBuilder(); + internalGetUpdateTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + sourceEnvironment_ = ""; + sourceEnvironmentUri_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.PluginServiceProto + .internal_static_google_cloud_apihub_v1_SourceEnvironment_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.SourceEnvironment getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.SourceEnvironment.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.SourceEnvironment build() { + com.google.cloud.apihub.v1.SourceEnvironment result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.SourceEnvironment buildPartial() { + com.google.cloud.apihub.v1.SourceEnvironment result = + new com.google.cloud.apihub.v1.SourceEnvironment(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.SourceEnvironment result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.sourceEnvironment_ = sourceEnvironment_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.sourceEnvironmentUri_ = sourceEnvironmentUri_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.SourceEnvironment) { + return mergeFrom((com.google.cloud.apihub.v1.SourceEnvironment) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.SourceEnvironment other) { + if (other == com.google.cloud.apihub.v1.SourceEnvironment.getDefaultInstance()) return this; + if (!other.getSourceEnvironment().isEmpty()) { + sourceEnvironment_ = other.sourceEnvironment_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getSourceEnvironmentUri().isEmpty()) { + sourceEnvironmentUri_ = other.sourceEnvironmentUri_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + sourceEnvironment_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 26: + { + sourceEnvironmentUri_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 34 + case 42: + { + input.readMessage( + internalGetUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object sourceEnvironment_ = ""; + + /** + * + * + *
                      +     * Required. The name of the environment at the source. This should map to
                      +     * [Deployment][google.cloud.apihub.v1.SourceEnvironment.source_environment].
                      +     * 
                      + * + * string source_environment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The sourceEnvironment. + */ + public java.lang.String getSourceEnvironment() { + java.lang.Object ref = sourceEnvironment_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sourceEnvironment_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the environment at the source. This should map to
                      +     * [Deployment][google.cloud.apihub.v1.SourceEnvironment.source_environment].
                      +     * 
                      + * + * string source_environment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for sourceEnvironment. + */ + public com.google.protobuf.ByteString getSourceEnvironmentBytes() { + java.lang.Object ref = sourceEnvironment_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sourceEnvironment_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Required. The name of the environment at the source. This should map to
                      +     * [Deployment][google.cloud.apihub.v1.SourceEnvironment.source_environment].
                      +     * 
                      + * + * string source_environment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The sourceEnvironment to set. + * @return This builder for chaining. + */ + public Builder setSourceEnvironment(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sourceEnvironment_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the environment at the source. This should map to
                      +     * [Deployment][google.cloud.apihub.v1.SourceEnvironment.source_environment].
                      +     * 
                      + * + * string source_environment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearSourceEnvironment() { + sourceEnvironment_ = getDefaultInstance().getSourceEnvironment(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The name of the environment at the source. This should map to
                      +     * [Deployment][google.cloud.apihub.v1.SourceEnvironment.source_environment].
                      +     * 
                      + * + * string source_environment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for sourceEnvironment to set. + * @return This builder for chaining. + */ + public Builder setSourceEnvironmentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sourceEnvironment_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object sourceEnvironmentUri_ = ""; + + /** + * + * + *
                      +     * The location where additional information about source environments can be
                      +     * found. The location should be relative path of the environment manifest
                      +     * with respect to a plugin instance.
                      +     * 
                      + * + * string source_environment_uri = 3; + * + * @return The sourceEnvironmentUri. + */ + public java.lang.String getSourceEnvironmentUri() { + java.lang.Object ref = sourceEnvironmentUri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sourceEnvironmentUri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * The location where additional information about source environments can be
                      +     * found. The location should be relative path of the environment manifest
                      +     * with respect to a plugin instance.
                      +     * 
                      + * + * string source_environment_uri = 3; + * + * @return The bytes for sourceEnvironmentUri. + */ + public com.google.protobuf.ByteString getSourceEnvironmentUriBytes() { + java.lang.Object ref = sourceEnvironmentUri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sourceEnvironmentUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * The location where additional information about source environments can be
                      +     * found. The location should be relative path of the environment manifest
                      +     * with respect to a plugin instance.
                      +     * 
                      + * + * string source_environment_uri = 3; + * + * @param value The sourceEnvironmentUri to set. + * @return This builder for chaining. + */ + public Builder setSourceEnvironmentUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sourceEnvironmentUri_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * The location where additional information about source environments can be
                      +     * found. The location should be relative path of the environment manifest
                      +     * with respect to a plugin instance.
                      +     * 
                      + * + * string source_environment_uri = 3; + * + * @return This builder for chaining. + */ + public Builder clearSourceEnvironmentUri() { + sourceEnvironmentUri_ = getDefaultInstance().getSourceEnvironmentUri(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * The location where additional information about source environments can be
                      +     * found. The location should be relative path of the environment manifest
                      +     * with respect to a plugin instance.
                      +     * 
                      + * + * string source_environment_uri = 3; + * + * @param value The bytes for sourceEnvironmentUri to set. + * @return This builder for chaining. + */ + public Builder setSourceEnvironmentUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sourceEnvironmentUri_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
                      +     * Optional. The time at which the environment was created at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was created at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was created at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was created at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was created at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was created at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000004); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was created at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was created at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was created at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
                      +     * Optional. The time at which the environment was last updated at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was last updated at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was last updated at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + } else { + updateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was last updated at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was last updated at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && updateTime_ != null + && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getUpdateTimeBuilder().mergeFrom(value); + } else { + updateTime_ = value; + } + } else { + updateTimeBuilder_.mergeFrom(value); + } + if (updateTime_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was last updated at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000008); + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was last updated at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was last updated at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + + /** + * + * + *
                      +     * Optional. The time at which the environment was last updated at the source.
                      +     * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.SourceEnvironment) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.SourceEnvironment) + private static final com.google.cloud.apihub.v1.SourceEnvironment DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.SourceEnvironment(); + } + + public static com.google.cloud.apihub.v1.SourceEnvironment getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SourceEnvironment parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.SourceEnvironment getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SourceEnvironmentOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SourceEnvironmentOrBuilder.java new file mode 100644 index 000000000000..59ff599ef141 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SourceEnvironmentOrBuilder.java @@ -0,0 +1,166 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/plugin_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface SourceEnvironmentOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.SourceEnvironment) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The name of the environment at the source. This should map to
                      +   * [Deployment][google.cloud.apihub.v1.SourceEnvironment.source_environment].
                      +   * 
                      + * + * string source_environment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The sourceEnvironment. + */ + java.lang.String getSourceEnvironment(); + + /** + * + * + *
                      +   * Required. The name of the environment at the source. This should map to
                      +   * [Deployment][google.cloud.apihub.v1.SourceEnvironment.source_environment].
                      +   * 
                      + * + * string source_environment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for sourceEnvironment. + */ + com.google.protobuf.ByteString getSourceEnvironmentBytes(); + + /** + * + * + *
                      +   * The location where additional information about source environments can be
                      +   * found. The location should be relative path of the environment manifest
                      +   * with respect to a plugin instance.
                      +   * 
                      + * + * string source_environment_uri = 3; + * + * @return The sourceEnvironmentUri. + */ + java.lang.String getSourceEnvironmentUri(); + + /** + * + * + *
                      +   * The location where additional information about source environments can be
                      +   * found. The location should be relative path of the environment manifest
                      +   * with respect to a plugin instance.
                      +   * 
                      + * + * string source_environment_uri = 3; + * + * @return The bytes for sourceEnvironmentUri. + */ + com.google.protobuf.ByteString getSourceEnvironmentUriBytes(); + + /** + * + * + *
                      +   * Optional. The time at which the environment was created at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
                      +   * Optional. The time at which the environment was created at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
                      +   * Optional. The time at which the environment was created at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
                      +   * Optional. The time at which the environment was last updated at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + + /** + * + * + *
                      +   * Optional. The time at which the environment was last updated at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + + /** + * + * + *
                      +   * Optional. The time at which the environment was last updated at the source.
                      +   * 
                      + * + * .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Spec.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Spec.java index f8610c823c66..3bad26980857 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Spec.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Spec.java @@ -59,6 +59,8 @@ private Spec() { sourceUri_ = ""; parsingMode_ = 0; sourceMetadata_ = java.util.Collections.emptyList(); + additionalSpecContents_ = java.util.Collections.emptyList(); + deployments_ = com.google.protobuf.LazyStringArrayList.emptyList(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -1130,6 +1132,178 @@ public com.google.cloud.apihub.v1.SourceMetadataOrBuilder getSourceMetadataOrBui return sourceMetadata_.get(index); } + public static final int ADDITIONAL_SPEC_CONTENTS_FIELD_NUMBER = 14; + + @SuppressWarnings("serial") + private java.util.List additionalSpecContents_; + + /** + * + * + *
                      +   * Output only. The additional spec contents for the spec.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.List + getAdditionalSpecContentsList() { + return additionalSpecContents_; + } + + /** + * + * + *
                      +   * Output only. The additional spec contents for the spec.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.List + getAdditionalSpecContentsOrBuilderList() { + return additionalSpecContents_; + } + + /** + * + * + *
                      +   * Output only. The additional spec contents for the spec.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public int getAdditionalSpecContentsCount() { + return additionalSpecContents_.size(); + } + + /** + * + * + *
                      +   * Output only. The additional spec contents for the spec.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AdditionalSpecContent getAdditionalSpecContents(int index) { + return additionalSpecContents_.get(index); + } + + /** + * + * + *
                      +   * Output only. The additional spec contents for the spec.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder + getAdditionalSpecContentsOrBuilder(int index) { + return additionalSpecContents_.get(index); + } + + public static final int DEPLOYMENTS_FIELD_NUMBER = 15; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList deployments_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this spec.
                      +   * Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the deployments. + */ + public com.google.protobuf.ProtocolStringList getDeploymentsList() { + return deployments_; + } + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this spec.
                      +   * Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The count of deployments. + */ + public int getDeploymentsCount() { + return deployments_.size(); + } + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this spec.
                      +   * Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The deployments at the given index. + */ + public java.lang.String getDeployments(int index) { + return deployments_.get(index); + } + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this spec.
                      +   * Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the deployments at the given index. + */ + public com.google.protobuf.ByteString getDeploymentsBytes(int index) { + return deployments_.getByteString(index); + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -1183,6 +1357,12 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < sourceMetadata_.size(); i++) { output.writeMessage(13, sourceMetadata_.get(i)); } + for (int i = 0; i < additionalSpecContents_.size(); i++) { + output.writeMessage(14, additionalSpecContents_.get(i)); + } + for (int i = 0; i < deployments_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 15, deployments_.getRaw(i)); + } getUnknownFields().writeTo(output); } @@ -1240,6 +1420,19 @@ public int getSerializedSize() { for (int i = 0; i < sourceMetadata_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(13, sourceMetadata_.get(i)); } + for (int i = 0; i < additionalSpecContents_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 14, additionalSpecContents_.get(i)); + } + { + int dataSize = 0; + for (int i = 0; i < deployments_.size(); i++) { + dataSize += computeStringSizeNoTag(deployments_.getRaw(i)); + } + size += dataSize; + size += 1 * getDeploymentsList().size(); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1289,6 +1482,9 @@ public boolean equals(final java.lang.Object obj) { } if (parsingMode_ != other.parsingMode_) return false; if (!getSourceMetadataList().equals(other.getSourceMetadataList())) return false; + if (!getAdditionalSpecContentsList().equals(other.getAdditionalSpecContentsList())) + return false; + if (!getDeploymentsList().equals(other.getDeploymentsList())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1344,6 +1540,14 @@ public int hashCode() { hash = (37 * hash) + SOURCE_METADATA_FIELD_NUMBER; hash = (53 * hash) + getSourceMetadataList().hashCode(); } + if (getAdditionalSpecContentsCount() > 0) { + hash = (37 * hash) + ADDITIONAL_SPEC_CONTENTS_FIELD_NUMBER; + hash = (53 * hash) + getAdditionalSpecContentsList().hashCode(); + } + if (getDeploymentsCount() > 0) { + hash = (37 * hash) + DEPLOYMENTS_FIELD_NUMBER; + hash = (53 * hash) + getDeploymentsList().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1515,6 +1719,7 @@ private void maybeForceBuilderInitialization() { internalGetLintResponseFieldBuilder(); internalGetDocumentationFieldBuilder(); internalGetSourceMetadataFieldBuilder(); + internalGetAdditionalSpecContentsFieldBuilder(); } } @@ -1569,6 +1774,14 @@ public Builder clear() { sourceMetadataBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00001000); + if (additionalSpecContentsBuilder_ == null) { + additionalSpecContents_ = java.util.Collections.emptyList(); + } else { + additionalSpecContents_ = null; + additionalSpecContentsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00002000); + deployments_ = com.google.protobuf.LazyStringArrayList.emptyList(); return this; } @@ -1613,6 +1826,15 @@ private void buildPartialRepeatedFields(com.google.cloud.apihub.v1.Spec result) } else { result.sourceMetadata_ = sourceMetadataBuilder_.build(); } + if (additionalSpecContentsBuilder_ == null) { + if (((bitField0_ & 0x00002000) != 0)) { + additionalSpecContents_ = java.util.Collections.unmodifiableList(additionalSpecContents_); + bitField0_ = (bitField0_ & ~0x00002000); + } + result.additionalSpecContents_ = additionalSpecContents_; + } else { + result.additionalSpecContents_ = additionalSpecContentsBuilder_.build(); + } } private void buildPartial0(com.google.cloud.apihub.v1.Spec result) { @@ -1664,6 +1886,10 @@ private void buildPartial0(com.google.cloud.apihub.v1.Spec result) { if (((from_bitField0_ & 0x00000800) != 0)) { result.parsingMode_ = parsingMode_; } + if (((from_bitField0_ & 0x00004000) != 0)) { + deployments_.makeImmutable(); + result.deployments_ = deployments_; + } result.bitField0_ |= to_bitField0_; } @@ -1747,6 +1973,43 @@ public Builder mergeFrom(com.google.cloud.apihub.v1.Spec other) { } } } + if (additionalSpecContentsBuilder_ == null) { + if (!other.additionalSpecContents_.isEmpty()) { + if (additionalSpecContents_.isEmpty()) { + additionalSpecContents_ = other.additionalSpecContents_; + bitField0_ = (bitField0_ & ~0x00002000); + } else { + ensureAdditionalSpecContentsIsMutable(); + additionalSpecContents_.addAll(other.additionalSpecContents_); + } + onChanged(); + } + } else { + if (!other.additionalSpecContents_.isEmpty()) { + if (additionalSpecContentsBuilder_.isEmpty()) { + additionalSpecContentsBuilder_.dispose(); + additionalSpecContentsBuilder_ = null; + additionalSpecContents_ = other.additionalSpecContents_; + bitField0_ = (bitField0_ & ~0x00002000); + additionalSpecContentsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetAdditionalSpecContentsFieldBuilder() + : null; + } else { + additionalSpecContentsBuilder_.addAllMessages(other.additionalSpecContents_); + } + } + } + if (!other.deployments_.isEmpty()) { + if (deployments_.isEmpty()) { + deployments_ = other.deployments_; + bitField0_ |= 0x00004000; + } else { + ensureDeploymentsIsMutable(); + deployments_.addAll(other.deployments_); + } + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1872,6 +2135,27 @@ public Builder mergeFrom( } break; } // case 106 + case 114: + { + com.google.cloud.apihub.v1.AdditionalSpecContent m = + input.readMessage( + com.google.cloud.apihub.v1.AdditionalSpecContent.parser(), + extensionRegistry); + if (additionalSpecContentsBuilder_ == null) { + ensureAdditionalSpecContentsIsMutable(); + additionalSpecContents_.add(m); + } else { + additionalSpecContentsBuilder_.addMessage(m); + } + break; + } // case 114 + case 122: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureDeploymentsIsMutable(); + deployments_.add(s); + break; + } // case 122 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -4629,6 +4913,641 @@ public com.google.cloud.apihub.v1.SourceMetadata.Builder addSourceMetadataBuilde return sourceMetadataBuilder_; } + private java.util.List + additionalSpecContents_ = java.util.Collections.emptyList(); + + private void ensureAdditionalSpecContentsIsMutable() { + if (!((bitField0_ & 0x00002000) != 0)) { + additionalSpecContents_ = + new java.util.ArrayList( + additionalSpecContents_); + bitField0_ |= 0x00002000; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.AdditionalSpecContent, + com.google.cloud.apihub.v1.AdditionalSpecContent.Builder, + com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder> + additionalSpecContentsBuilder_; + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List + getAdditionalSpecContentsList() { + if (additionalSpecContentsBuilder_ == null) { + return java.util.Collections.unmodifiableList(additionalSpecContents_); + } else { + return additionalSpecContentsBuilder_.getMessageList(); + } + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public int getAdditionalSpecContentsCount() { + if (additionalSpecContentsBuilder_ == null) { + return additionalSpecContents_.size(); + } else { + return additionalSpecContentsBuilder_.getCount(); + } + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apihub.v1.AdditionalSpecContent getAdditionalSpecContents(int index) { + if (additionalSpecContentsBuilder_ == null) { + return additionalSpecContents_.get(index); + } else { + return additionalSpecContentsBuilder_.getMessage(index); + } + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setAdditionalSpecContents( + int index, com.google.cloud.apihub.v1.AdditionalSpecContent value) { + if (additionalSpecContentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAdditionalSpecContentsIsMutable(); + additionalSpecContents_.set(index, value); + onChanged(); + } else { + additionalSpecContentsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setAdditionalSpecContents( + int index, com.google.cloud.apihub.v1.AdditionalSpecContent.Builder builderForValue) { + if (additionalSpecContentsBuilder_ == null) { + ensureAdditionalSpecContentsIsMutable(); + additionalSpecContents_.set(index, builderForValue.build()); + onChanged(); + } else { + additionalSpecContentsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addAdditionalSpecContents( + com.google.cloud.apihub.v1.AdditionalSpecContent value) { + if (additionalSpecContentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAdditionalSpecContentsIsMutable(); + additionalSpecContents_.add(value); + onChanged(); + } else { + additionalSpecContentsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addAdditionalSpecContents( + int index, com.google.cloud.apihub.v1.AdditionalSpecContent value) { + if (additionalSpecContentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAdditionalSpecContentsIsMutable(); + additionalSpecContents_.add(index, value); + onChanged(); + } else { + additionalSpecContentsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addAdditionalSpecContents( + com.google.cloud.apihub.v1.AdditionalSpecContent.Builder builderForValue) { + if (additionalSpecContentsBuilder_ == null) { + ensureAdditionalSpecContentsIsMutable(); + additionalSpecContents_.add(builderForValue.build()); + onChanged(); + } else { + additionalSpecContentsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addAdditionalSpecContents( + int index, com.google.cloud.apihub.v1.AdditionalSpecContent.Builder builderForValue) { + if (additionalSpecContentsBuilder_ == null) { + ensureAdditionalSpecContentsIsMutable(); + additionalSpecContents_.add(index, builderForValue.build()); + onChanged(); + } else { + additionalSpecContentsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addAllAdditionalSpecContents( + java.lang.Iterable values) { + if (additionalSpecContentsBuilder_ == null) { + ensureAdditionalSpecContentsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, additionalSpecContents_); + onChanged(); + } else { + additionalSpecContentsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearAdditionalSpecContents() { + if (additionalSpecContentsBuilder_ == null) { + additionalSpecContents_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00002000); + onChanged(); + } else { + additionalSpecContentsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder removeAdditionalSpecContents(int index) { + if (additionalSpecContentsBuilder_ == null) { + ensureAdditionalSpecContentsIsMutable(); + additionalSpecContents_.remove(index); + onChanged(); + } else { + additionalSpecContentsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apihub.v1.AdditionalSpecContent.Builder + getAdditionalSpecContentsBuilder(int index) { + return internalGetAdditionalSpecContentsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder + getAdditionalSpecContentsOrBuilder(int index) { + if (additionalSpecContentsBuilder_ == null) { + return additionalSpecContents_.get(index); + } else { + return additionalSpecContentsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List + getAdditionalSpecContentsOrBuilderList() { + if (additionalSpecContentsBuilder_ != null) { + return additionalSpecContentsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(additionalSpecContents_); + } + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apihub.v1.AdditionalSpecContent.Builder + addAdditionalSpecContentsBuilder() { + return internalGetAdditionalSpecContentsFieldBuilder() + .addBuilder(com.google.cloud.apihub.v1.AdditionalSpecContent.getDefaultInstance()); + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.apihub.v1.AdditionalSpecContent.Builder + addAdditionalSpecContentsBuilder(int index) { + return internalGetAdditionalSpecContentsFieldBuilder() + .addBuilder(index, com.google.cloud.apihub.v1.AdditionalSpecContent.getDefaultInstance()); + } + + /** + * + * + *
                      +     * Output only. The additional spec contents for the spec.
                      +     * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List + getAdditionalSpecContentsBuilderList() { + return internalGetAdditionalSpecContentsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.AdditionalSpecContent, + com.google.cloud.apihub.v1.AdditionalSpecContent.Builder, + com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder> + internalGetAdditionalSpecContentsFieldBuilder() { + if (additionalSpecContentsBuilder_ == null) { + additionalSpecContentsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.apihub.v1.AdditionalSpecContent, + com.google.cloud.apihub.v1.AdditionalSpecContent.Builder, + com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder>( + additionalSpecContents_, + ((bitField0_ & 0x00002000) != 0), + getParentForChildren(), + isClean()); + additionalSpecContents_ = null; + } + return additionalSpecContentsBuilder_; + } + + private com.google.protobuf.LazyStringArrayList deployments_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureDeploymentsIsMutable() { + if (!deployments_.isModifiable()) { + deployments_ = new com.google.protobuf.LazyStringArrayList(deployments_); + } + bitField0_ |= 0x00004000; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this spec.
                      +     * Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the deployments. + */ + public com.google.protobuf.ProtocolStringList getDeploymentsList() { + deployments_.makeImmutable(); + return deployments_; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this spec.
                      +     * Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The count of deployments. + */ + public int getDeploymentsCount() { + return deployments_.size(); + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this spec.
                      +     * Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The deployments at the given index. + */ + public java.lang.String getDeployments(int index) { + return deployments_.get(index); + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this spec.
                      +     * Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the deployments at the given index. + */ + public com.google.protobuf.ByteString getDeploymentsBytes(int index) { + return deployments_.getByteString(index); + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this spec.
                      +     * Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index to set the value at. + * @param value The deployments to set. + * @return This builder for chaining. + */ + public Builder setDeployments(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDeploymentsIsMutable(); + deployments_.set(index, value); + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this spec.
                      +     * Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The deployments to add. + * @return This builder for chaining. + */ + public Builder addDeployments(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDeploymentsIsMutable(); + deployments_.add(value); + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this spec.
                      +     * Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param values The deployments to add. + * @return This builder for chaining. + */ + public Builder addAllDeployments(java.lang.Iterable values) { + ensureDeploymentsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, deployments_); + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this spec.
                      +     * Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearDeployments() { + deployments_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00004000); + ; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The deployments linked directly to this spec.
                      +     * Format is
                      +     * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +     * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes of the deployments to add. + * @return This builder for chaining. + */ + public Builder addDeploymentsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureDeploymentsIsMutable(); + deployments_.add(value); + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.Spec) } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecContentType.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecContentType.java new file mode 100644 index 000000000000..00a1a01b149b --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecContentType.java @@ -0,0 +1,196 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/common_fields.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Enumerations of the spec content types.
                      + * More values may be added in the future.
                      + * 
                      + * + * Protobuf enum {@code google.cloud.apihub.v1.SpecContentType} + */ +@com.google.protobuf.Generated +public enum SpecContentType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                      +   * Unspecified spec content type.
                      +   * Defaults to spec content uploaded by the user.
                      +   * 
                      + * + * SPEC_CONTENT_TYPE_UNSPECIFIED = 0; + */ + SPEC_CONTENT_TYPE_UNSPECIFIED(0), + /** + * + * + *
                      +   * The spec content type for boosted spec.
                      +   * 
                      + * + * BOOSTED_SPEC_CONTENT = 1; + */ + BOOSTED_SPEC_CONTENT(1), + /** + * + * + *
                      +   * The spec content type for OpenAPI spec. This enum is used for OpenAPI specs
                      +   * ingested via APIGEE X Gateway.
                      +   * 
                      + * + * GATEWAY_OPEN_API_SPEC = 2; + */ + GATEWAY_OPEN_API_SPEC(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SpecContentType"); + } + + /** + * + * + *
                      +   * Unspecified spec content type.
                      +   * Defaults to spec content uploaded by the user.
                      +   * 
                      + * + * SPEC_CONTENT_TYPE_UNSPECIFIED = 0; + */ + public static final int SPEC_CONTENT_TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                      +   * The spec content type for boosted spec.
                      +   * 
                      + * + * BOOSTED_SPEC_CONTENT = 1; + */ + public static final int BOOSTED_SPEC_CONTENT_VALUE = 1; + + /** + * + * + *
                      +   * The spec content type for OpenAPI spec. This enum is used for OpenAPI specs
                      +   * ingested via APIGEE X Gateway.
                      +   * 
                      + * + * GATEWAY_OPEN_API_SPEC = 2; + */ + public static final int GATEWAY_OPEN_API_SPEC_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static SpecContentType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static SpecContentType forNumber(int value) { + switch (value) { + case 0: + return SPEC_CONTENT_TYPE_UNSPECIFIED; + case 1: + return BOOSTED_SPEC_CONTENT; + case 2: + return GATEWAY_OPEN_API_SPEC; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public SpecContentType findValueByNumber(int number) { + return SpecContentType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto.getDescriptor().getEnumTypes().get(7); + } + + private static final SpecContentType[] VALUES = values(); + + public static SpecContentType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private SpecContentType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.apihub.v1.SpecContentType) +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecContents.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecContents.java index 07bb7425d768..160472098d3d 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecContents.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecContents.java @@ -78,7 +78,8 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
                      -   * Required. The contents of the spec.
                      +   * Required. The contents of the spec. The contents should be base64 encoded
                      +   * when calling methods such as CreateSpec, UpdateSpec and CollectApiData.
                          * 
                      * * bytes contents = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -481,7 +482,8 @@ public Builder mergeFrom( * * *
                      -     * Required. The contents of the spec.
                      +     * Required. The contents of the spec. The contents should be base64 encoded
                      +     * when calling methods such as CreateSpec, UpdateSpec and CollectApiData.
                            * 
                      * * bytes contents = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -497,7 +499,8 @@ public com.google.protobuf.ByteString getContents() { * * *
                      -     * Required. The contents of the spec.
                      +     * Required. The contents of the spec. The contents should be base64 encoded
                      +     * when calling methods such as CreateSpec, UpdateSpec and CollectApiData.
                            * 
                      * * bytes contents = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -519,7 +522,8 @@ public Builder setContents(com.google.protobuf.ByteString value) { * * *
                      -     * Required. The contents of the spec.
                      +     * Required. The contents of the spec. The contents should be base64 encoded
                      +     * when calling methods such as CreateSpec, UpdateSpec and CollectApiData.
                            * 
                      * * bytes contents = 1 [(.google.api.field_behavior) = REQUIRED]; diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecContentsOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecContentsOrBuilder.java index e06155cf2422..7c2faad5cdb2 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecContentsOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecContentsOrBuilder.java @@ -30,7 +30,8 @@ public interface SpecContentsOrBuilder * * *
                      -   * Required. The contents of the spec.
                      +   * Required. The contents of the spec. The contents should be base64 encoded
                      +   * when calling methods such as CreateSpec, UpdateSpec and CollectApiData.
                          * 
                      * * bytes contents = 1 [(.google.api.field_behavior) = REQUIRED]; diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecMetadata.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecMetadata.java index 70b175ae356e..72b8c008c78b 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecMetadata.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecMetadata.java @@ -53,6 +53,7 @@ private SpecMetadata(com.google.protobuf.GeneratedMessage.Builder builder) { private SpecMetadata() { originalId_ = ""; + deploymentResourceUris_ = com.google.protobuf.LazyStringArrayList.emptyList(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -299,6 +300,98 @@ public com.google.protobuf.TimestampOrBuilder getOriginalUpdateTimeOrBuilder() { : originalUpdateTime_; } + public static final int DEPLOYMENT_RESOURCE_URIS_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList deploymentResourceUris_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
                      +   * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +   * provided, the API Hub service creates links between this spec and the
                      +   * deployments identified by these URIs. URIs that don't match any known
                      +   * deployment are ignored; a subsequent ingestion cycle that includes the
                      +   * missing deployment will re-establish the link. The maximum number of URIs
                      +   * allowed is 100.
                      +   * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the deploymentResourceUris. + */ + public com.google.protobuf.ProtocolStringList getDeploymentResourceUrisList() { + return deploymentResourceUris_; + } + + /** + * + * + *
                      +   * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +   * provided, the API Hub service creates links between this spec and the
                      +   * deployments identified by these URIs. URIs that don't match any known
                      +   * deployment are ignored; a subsequent ingestion cycle that includes the
                      +   * missing deployment will re-establish the link. The maximum number of URIs
                      +   * allowed is 100.
                      +   * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of deploymentResourceUris. + */ + public int getDeploymentResourceUrisCount() { + return deploymentResourceUris_.size(); + } + + /** + * + * + *
                      +   * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +   * provided, the API Hub service creates links between this spec and the
                      +   * deployments identified by these URIs. URIs that don't match any known
                      +   * deployment are ignored; a subsequent ingestion cycle that includes the
                      +   * missing deployment will re-establish the link. The maximum number of URIs
                      +   * allowed is 100.
                      +   * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The deploymentResourceUris at the given index. + */ + public java.lang.String getDeploymentResourceUris(int index) { + return deploymentResourceUris_.get(index); + } + + /** + * + * + *
                      +   * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +   * provided, the API Hub service creates links between this spec and the
                      +   * deployments identified by these URIs. URIs that don't match any known
                      +   * deployment are ignored; a subsequent ingestion cycle that includes the
                      +   * missing deployment will re-establish the link. The maximum number of URIs
                      +   * allowed is 100.
                      +   * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the deploymentResourceUris at the given index. + */ + public com.google.protobuf.ByteString getDeploymentResourceUrisBytes(int index) { + return deploymentResourceUris_.getByteString(index); + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -325,6 +418,10 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000004) != 0)) { output.writeMessage(4, getOriginalUpdateTime()); } + for (int i = 0; i < deploymentResourceUris_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 5, deploymentResourceUris_.getRaw(i)); + } getUnknownFields().writeTo(output); } @@ -346,6 +443,14 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000004) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getOriginalUpdateTime()); } + { + int dataSize = 0; + for (int i = 0; i < deploymentResourceUris_.size(); i++) { + dataSize += computeStringSizeNoTag(deploymentResourceUris_.getRaw(i)); + } + size += dataSize; + size += 1 * getDeploymentResourceUrisList().size(); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -374,6 +479,8 @@ public boolean equals(final java.lang.Object obj) { if (hasOriginalUpdateTime()) { if (!getOriginalUpdateTime().equals(other.getOriginalUpdateTime())) return false; } + if (!getDeploymentResourceUrisList().equals(other.getDeploymentResourceUrisList())) + return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -399,6 +506,10 @@ public int hashCode() { hash = (37 * hash) + ORIGINAL_UPDATE_TIME_FIELD_NUMBER; hash = (53 * hash) + getOriginalUpdateTime().hashCode(); } + if (getDeploymentResourceUrisCount() > 0) { + hash = (37 * hash) + DEPLOYMENT_RESOURCE_URIS_FIELD_NUMBER; + hash = (53 * hash) + getDeploymentResourceUrisList().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -566,6 +677,7 @@ public Builder clear() { originalUpdateTimeBuilder_.dispose(); originalUpdateTimeBuilder_ = null; } + deploymentResourceUris_ = com.google.protobuf.LazyStringArrayList.emptyList(); return this; } @@ -624,6 +736,10 @@ private void buildPartial0(com.google.cloud.apihub.v1.SpecMetadata result) { : originalUpdateTimeBuilder_.build(); to_bitField0_ |= 0x00000004; } + if (((from_bitField0_ & 0x00000010) != 0)) { + deploymentResourceUris_.makeImmutable(); + result.deploymentResourceUris_ = deploymentResourceUris_; + } result.bitField0_ |= to_bitField0_; } @@ -653,6 +769,16 @@ public Builder mergeFrom(com.google.cloud.apihub.v1.SpecMetadata other) { if (other.hasOriginalUpdateTime()) { mergeOriginalUpdateTime(other.getOriginalUpdateTime()); } + if (!other.deploymentResourceUris_.isEmpty()) { + if (deploymentResourceUris_.isEmpty()) { + deploymentResourceUris_ = other.deploymentResourceUris_; + bitField0_ |= 0x00000010; + } else { + ensureDeploymentResourceUrisIsMutable(); + deploymentResourceUris_.addAll(other.deploymentResourceUris_); + } + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -705,6 +831,13 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 34 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureDeploymentResourceUrisIsMutable(); + deploymentResourceUris_.add(s); + break; + } // case 42 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -1472,6 +1605,244 @@ public com.google.protobuf.TimestampOrBuilder getOriginalUpdateTimeOrBuilder() { return originalUpdateTimeBuilder_; } + private com.google.protobuf.LazyStringArrayList deploymentResourceUris_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureDeploymentResourceUrisIsMutable() { + if (!deploymentResourceUris_.isModifiable()) { + deploymentResourceUris_ = + new com.google.protobuf.LazyStringArrayList(deploymentResourceUris_); + } + bitField0_ |= 0x00000010; + } + + /** + * + * + *
                      +     * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +     * provided, the API Hub service creates links between this spec and the
                      +     * deployments identified by these URIs. URIs that don't match any known
                      +     * deployment are ignored; a subsequent ingestion cycle that includes the
                      +     * missing deployment will re-establish the link. The maximum number of URIs
                      +     * allowed is 100.
                      +     * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the deploymentResourceUris. + */ + public com.google.protobuf.ProtocolStringList getDeploymentResourceUrisList() { + deploymentResourceUris_.makeImmutable(); + return deploymentResourceUris_; + } + + /** + * + * + *
                      +     * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +     * provided, the API Hub service creates links between this spec and the
                      +     * deployments identified by these URIs. URIs that don't match any known
                      +     * deployment are ignored; a subsequent ingestion cycle that includes the
                      +     * missing deployment will re-establish the link. The maximum number of URIs
                      +     * allowed is 100.
                      +     * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of deploymentResourceUris. + */ + public int getDeploymentResourceUrisCount() { + return deploymentResourceUris_.size(); + } + + /** + * + * + *
                      +     * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +     * provided, the API Hub service creates links between this spec and the
                      +     * deployments identified by these URIs. URIs that don't match any known
                      +     * deployment are ignored; a subsequent ingestion cycle that includes the
                      +     * missing deployment will re-establish the link. The maximum number of URIs
                      +     * allowed is 100.
                      +     * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The deploymentResourceUris at the given index. + */ + public java.lang.String getDeploymentResourceUris(int index) { + return deploymentResourceUris_.get(index); + } + + /** + * + * + *
                      +     * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +     * provided, the API Hub service creates links between this spec and the
                      +     * deployments identified by these URIs. URIs that don't match any known
                      +     * deployment are ignored; a subsequent ingestion cycle that includes the
                      +     * missing deployment will re-establish the link. The maximum number of URIs
                      +     * allowed is 100.
                      +     * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the deploymentResourceUris at the given index. + */ + public com.google.protobuf.ByteString getDeploymentResourceUrisBytes(int index) { + return deploymentResourceUris_.getByteString(index); + } + + /** + * + * + *
                      +     * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +     * provided, the API Hub service creates links between this spec and the
                      +     * deployments identified by these URIs. URIs that don't match any known
                      +     * deployment are ignored; a subsequent ingestion cycle that includes the
                      +     * missing deployment will re-establish the link. The maximum number of URIs
                      +     * allowed is 100.
                      +     * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The deploymentResourceUris to set. + * @return This builder for chaining. + */ + public Builder setDeploymentResourceUris(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDeploymentResourceUrisIsMutable(); + deploymentResourceUris_.set(index, value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +     * provided, the API Hub service creates links between this spec and the
                      +     * deployments identified by these URIs. URIs that don't match any known
                      +     * deployment are ignored; a subsequent ingestion cycle that includes the
                      +     * missing deployment will re-establish the link. The maximum number of URIs
                      +     * allowed is 100.
                      +     * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The deploymentResourceUris to add. + * @return This builder for chaining. + */ + public Builder addDeploymentResourceUris(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDeploymentResourceUrisIsMutable(); + deploymentResourceUris_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +     * provided, the API Hub service creates links between this spec and the
                      +     * deployments identified by these URIs. URIs that don't match any known
                      +     * deployment are ignored; a subsequent ingestion cycle that includes the
                      +     * missing deployment will re-establish the link. The maximum number of URIs
                      +     * allowed is 100.
                      +     * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The deploymentResourceUris to add. + * @return This builder for chaining. + */ + public Builder addAllDeploymentResourceUris(java.lang.Iterable values) { + ensureDeploymentResourceUrisIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, deploymentResourceUris_); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +     * provided, the API Hub service creates links between this spec and the
                      +     * deployments identified by these URIs. URIs that don't match any known
                      +     * deployment are ignored; a subsequent ingestion cycle that includes the
                      +     * missing deployment will re-establish the link. The maximum number of URIs
                      +     * allowed is 100.
                      +     * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearDeploymentResourceUris() { + deploymentResourceUris_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000010); + ; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +     * provided, the API Hub service creates links between this spec and the
                      +     * deployments identified by these URIs. URIs that don't match any known
                      +     * deployment are ignored; a subsequent ingestion cycle that includes the
                      +     * missing deployment will re-establish the link. The maximum number of URIs
                      +     * allowed is 100.
                      +     * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the deploymentResourceUris to add. + * @return This builder for chaining. + */ + public Builder addDeploymentResourceUrisBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureDeploymentResourceUrisIsMutable(); + deploymentResourceUris_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.SpecMetadata) } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecMetadataOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecMetadataOrBuilder.java index a89935ab0f8f..e7f21f89aa60 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecMetadataOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecMetadataOrBuilder.java @@ -182,4 +182,82 @@ public interface SpecMetadataOrBuilder *
                      */ com.google.protobuf.TimestampOrBuilder getOriginalUpdateTimeOrBuilder(); + + /** + * + * + *
                      +   * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +   * provided, the API Hub service creates links between this spec and the
                      +   * deployments identified by these URIs. URIs that don't match any known
                      +   * deployment are ignored; a subsequent ingestion cycle that includes the
                      +   * missing deployment will re-establish the link. The maximum number of URIs
                      +   * allowed is 100.
                      +   * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the deploymentResourceUris. + */ + java.util.List getDeploymentResourceUrisList(); + + /** + * + * + *
                      +   * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +   * provided, the API Hub service creates links between this spec and the
                      +   * deployments identified by these URIs. URIs that don't match any known
                      +   * deployment are ignored; a subsequent ingestion cycle that includes the
                      +   * missing deployment will re-establish the link. The maximum number of URIs
                      +   * allowed is 100.
                      +   * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of deploymentResourceUris. + */ + int getDeploymentResourceUrisCount(); + + /** + * + * + *
                      +   * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +   * provided, the API Hub service creates links between this spec and the
                      +   * deployments identified by these URIs. URIs that don't match any known
                      +   * deployment are ignored; a subsequent ingestion cycle that includes the
                      +   * missing deployment will re-establish the link. The maximum number of URIs
                      +   * allowed is 100.
                      +   * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The deploymentResourceUris at the given index. + */ + java.lang.String getDeploymentResourceUris(int index); + + /** + * + * + *
                      +   * Optional. The gateway-side URIs of deployments that serve this spec. If
                      +   * provided, the API Hub service creates links between this spec and the
                      +   * deployments identified by these URIs. URIs that don't match any known
                      +   * deployment are ignored; a subsequent ingestion cycle that includes the
                      +   * missing deployment will re-establish the link. The maximum number of URIs
                      +   * allowed is 100.
                      +   * 
                      + * + * repeated string deployment_resource_uris = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the deploymentResourceUris at the given index. + */ + com.google.protobuf.ByteString getDeploymentResourceUrisBytes(int index); } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecOrBuilder.java index b47835edb19a..703736daa988 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/SpecOrBuilder.java @@ -624,4 +624,141 @@ com.google.cloud.apihub.v1.AttributeValues getAttributesOrDefault( *
                      */ com.google.cloud.apihub.v1.SourceMetadataOrBuilder getSourceMetadataOrBuilder(int index); + + /** + * + * + *
                      +   * Output only. The additional spec contents for the spec.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.List getAdditionalSpecContentsList(); + + /** + * + * + *
                      +   * Output only. The additional spec contents for the spec.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.apihub.v1.AdditionalSpecContent getAdditionalSpecContents(int index); + + /** + * + * + *
                      +   * Output only. The additional spec contents for the spec.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + int getAdditionalSpecContentsCount(); + + /** + * + * + *
                      +   * Output only. The additional spec contents for the spec.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.List + getAdditionalSpecContentsOrBuilderList(); + + /** + * + * + *
                      +   * Output only. The additional spec contents for the spec.
                      +   * 
                      + * + * + * repeated .google.cloud.apihub.v1.AdditionalSpecContent additional_spec_contents = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.apihub.v1.AdditionalSpecContentOrBuilder getAdditionalSpecContentsOrBuilder( + int index); + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this spec.
                      +   * Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the deployments. + */ + java.util.List getDeploymentsList(); + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this spec.
                      +   * Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The count of deployments. + */ + int getDeploymentsCount(); + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this spec.
                      +   * Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The deployments at the given index. + */ + java.lang.String getDeployments(int index); + + /** + * + * + *
                      +   * Optional. The deployments linked directly to this spec.
                      +   * Format is
                      +   * `projects/{project}/locations/{location}/deployments/{deployment}`
                      +   * 
                      + * + * + * repeated string deployments = 15 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the deployments at the given index. + */ + com.google.protobuf.ByteString getDeploymentsBytes(int index); } diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ToolAnnotations.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ToolAnnotations.java new file mode 100644 index 000000000000..5b90300b57d1 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ToolAnnotations.java @@ -0,0 +1,1535 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/common_fields.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * Annotations for a Tool.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ToolAnnotations} + */ +@com.google.protobuf.Generated +public final class ToolAnnotations extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.ToolAnnotations) + ToolAnnotationsOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ToolAnnotations"); + } + + // Use ToolAnnotations.newBuilder() to construct. + private ToolAnnotations(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ToolAnnotations() { + title_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_ToolAnnotations_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 6: + return internalGetAdditionalHints(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_ToolAnnotations_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ToolAnnotations.class, + com.google.cloud.apihub.v1.ToolAnnotations.Builder.class); + } + + private int bitField0_; + public static final int TITLE_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object title_ = ""; + + /** + * + * + *
                      +   * Optional. A human-readable title for the tool (if different from
                      +   * Tool.title).
                      +   * 
                      + * + * string title = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The title. + */ + @java.lang.Override + public java.lang.String getTitle() { + java.lang.Object ref = title_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + title_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Optional. A human-readable title for the tool (if different from
                      +   * Tool.title).
                      +   * 
                      + * + * string title = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for title. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTitleBytes() { + java.lang.Object ref = title_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + title_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int READ_ONLY_HINT_FIELD_NUMBER = 2; + private boolean readOnlyHint_ = false; + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool is read-only.
                      +   * 
                      + * + * optional bool read_only_hint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the readOnlyHint field is set. + */ + @java.lang.Override + public boolean hasReadOnlyHint() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool is read-only.
                      +   * 
                      + * + * optional bool read_only_hint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The readOnlyHint. + */ + @java.lang.Override + public boolean getReadOnlyHint() { + return readOnlyHint_; + } + + public static final int DESTRUCTIVE_HINT_FIELD_NUMBER = 3; + private boolean destructiveHint_ = false; + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool may have destructive side effects.
                      +   * 
                      + * + * optional bool destructive_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the destructiveHint field is set. + */ + @java.lang.Override + public boolean hasDestructiveHint() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool may have destructive side effects.
                      +   * 
                      + * + * optional bool destructive_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The destructiveHint. + */ + @java.lang.Override + public boolean getDestructiveHint() { + return destructiveHint_; + } + + public static final int IDEMPOTENT_HINT_FIELD_NUMBER = 4; + private boolean idempotentHint_ = false; + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool is idempotent.
                      +   * 
                      + * + * optional bool idempotent_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the idempotentHint field is set. + */ + @java.lang.Override + public boolean hasIdempotentHint() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool is idempotent.
                      +   * 
                      + * + * optional bool idempotent_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The idempotentHint. + */ + @java.lang.Override + public boolean getIdempotentHint() { + return idempotentHint_; + } + + public static final int OPEN_WORLD_HINT_FIELD_NUMBER = 5; + private boolean openWorldHint_ = false; + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool interacts with the open world (e.g.,
                      +   * internet).
                      +   * 
                      + * + * optional bool open_world_hint = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the openWorldHint field is set. + */ + @java.lang.Override + public boolean hasOpenWorldHint() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool interacts with the open world (e.g.,
                      +   * internet).
                      +   * 
                      + * + * optional bool open_world_hint = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The openWorldHint. + */ + @java.lang.Override + public boolean getOpenWorldHint() { + return openWorldHint_; + } + + public static final int ADDITIONAL_HINTS_FIELD_NUMBER = 6; + + private static final class AdditionalHintsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_ToolAnnotations_AdditionalHintsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + + @SuppressWarnings("serial") + private com.google.protobuf.MapField additionalHints_; + + private com.google.protobuf.MapField + internalGetAdditionalHints() { + if (additionalHints_ == null) { + return com.google.protobuf.MapField.emptyMapField( + AdditionalHintsDefaultEntryHolder.defaultEntry); + } + return additionalHints_; + } + + public int getAdditionalHintsCount() { + return internalGetAdditionalHints().getMap().size(); + } + + /** + * + * + *
                      +   * Optional. Additional hints which may help tools and not covered in
                      +   * defaults.
                      +   * 
                      + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public boolean containsAdditionalHints(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetAdditionalHints().getMap().containsKey(key); + } + + /** Use {@link #getAdditionalHintsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getAdditionalHints() { + return getAdditionalHintsMap(); + } + + /** + * + * + *
                      +   * Optional. Additional hints which may help tools and not covered in
                      +   * defaults.
                      +   * 
                      + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.Map getAdditionalHintsMap() { + return internalGetAdditionalHints().getMap(); + } + + /** + * + * + *
                      +   * Optional. Additional hints which may help tools and not covered in
                      +   * defaults.
                      +   * 
                      + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public /* nullable */ java.lang.String getAdditionalHintsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetAdditionalHints().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
                      +   * Optional. Additional hints which may help tools and not covered in
                      +   * defaults.
                      +   * 
                      + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.lang.String getAdditionalHintsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetAdditionalHints().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(title_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, title_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeBool(2, readOnlyHint_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeBool(3, destructiveHint_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeBool(4, idempotentHint_); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeBool(5, openWorldHint_); + } + com.google.protobuf.GeneratedMessage.serializeStringMapTo( + output, internalGetAdditionalHints(), AdditionalHintsDefaultEntryHolder.defaultEntry, 6); + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(title_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, title_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, readOnlyHint_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, destructiveHint_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, idempotentHint_); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(5, openWorldHint_); + } + for (java.util.Map.Entry entry : + internalGetAdditionalHints().getMap().entrySet()) { + com.google.protobuf.MapEntry additionalHints__ = + AdditionalHintsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, additionalHints__); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.ToolAnnotations)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.ToolAnnotations other = + (com.google.cloud.apihub.v1.ToolAnnotations) obj; + + if (!getTitle().equals(other.getTitle())) return false; + if (hasReadOnlyHint() != other.hasReadOnlyHint()) return false; + if (hasReadOnlyHint()) { + if (getReadOnlyHint() != other.getReadOnlyHint()) return false; + } + if (hasDestructiveHint() != other.hasDestructiveHint()) return false; + if (hasDestructiveHint()) { + if (getDestructiveHint() != other.getDestructiveHint()) return false; + } + if (hasIdempotentHint() != other.hasIdempotentHint()) return false; + if (hasIdempotentHint()) { + if (getIdempotentHint() != other.getIdempotentHint()) return false; + } + if (hasOpenWorldHint() != other.hasOpenWorldHint()) return false; + if (hasOpenWorldHint()) { + if (getOpenWorldHint() != other.getOpenWorldHint()) return false; + } + if (!internalGetAdditionalHints().equals(other.internalGetAdditionalHints())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TITLE_FIELD_NUMBER; + hash = (53 * hash) + getTitle().hashCode(); + if (hasReadOnlyHint()) { + hash = (37 * hash) + READ_ONLY_HINT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getReadOnlyHint()); + } + if (hasDestructiveHint()) { + hash = (37 * hash) + DESTRUCTIVE_HINT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getDestructiveHint()); + } + if (hasIdempotentHint()) { + hash = (37 * hash) + IDEMPOTENT_HINT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getIdempotentHint()); + } + if (hasOpenWorldHint()) { + hash = (37 * hash) + OPEN_WORLD_HINT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getOpenWorldHint()); + } + if (!internalGetAdditionalHints().getMap().isEmpty()) { + hash = (37 * hash) + ADDITIONAL_HINTS_FIELD_NUMBER; + hash = (53 * hash) + internalGetAdditionalHints().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.apihub.v1.ToolAnnotations prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Annotations for a Tool.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.ToolAnnotations} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.ToolAnnotations) + com.google.cloud.apihub.v1.ToolAnnotationsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_ToolAnnotations_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 6: + return internalGetAdditionalHints(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( + int number) { + switch (number) { + case 6: + return internalGetMutableAdditionalHints(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_ToolAnnotations_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.ToolAnnotations.class, + com.google.cloud.apihub.v1.ToolAnnotations.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.ToolAnnotations.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + title_ = ""; + readOnlyHint_ = false; + destructiveHint_ = false; + idempotentHint_ = false; + openWorldHint_ = false; + internalGetMutableAdditionalHints().clear(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.CommonFieldsProto + .internal_static_google_cloud_apihub_v1_ToolAnnotations_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ToolAnnotations getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.ToolAnnotations.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ToolAnnotations build() { + com.google.cloud.apihub.v1.ToolAnnotations result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ToolAnnotations buildPartial() { + com.google.cloud.apihub.v1.ToolAnnotations result = + new com.google.cloud.apihub.v1.ToolAnnotations(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.ToolAnnotations result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.title_ = title_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.readOnlyHint_ = readOnlyHint_; + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.destructiveHint_ = destructiveHint_; + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.idempotentHint_ = idempotentHint_; + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.openWorldHint_ = openWorldHint_; + to_bitField0_ |= 0x00000008; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.additionalHints_ = internalGetAdditionalHints(); + result.additionalHints_.makeImmutable(); + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.ToolAnnotations) { + return mergeFrom((com.google.cloud.apihub.v1.ToolAnnotations) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.ToolAnnotations other) { + if (other == com.google.cloud.apihub.v1.ToolAnnotations.getDefaultInstance()) return this; + if (!other.getTitle().isEmpty()) { + title_ = other.title_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.hasReadOnlyHint()) { + setReadOnlyHint(other.getReadOnlyHint()); + } + if (other.hasDestructiveHint()) { + setDestructiveHint(other.getDestructiveHint()); + } + if (other.hasIdempotentHint()) { + setIdempotentHint(other.getIdempotentHint()); + } + if (other.hasOpenWorldHint()) { + setOpenWorldHint(other.getOpenWorldHint()); + } + internalGetMutableAdditionalHints().mergeFrom(other.internalGetAdditionalHints()); + bitField0_ |= 0x00000020; + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + title_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + readOnlyHint_ = input.readBool(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 24: + { + destructiveHint_ = input.readBool(); + bitField0_ |= 0x00000004; + break; + } // case 24 + case 32: + { + idempotentHint_ = input.readBool(); + bitField0_ |= 0x00000008; + break; + } // case 32 + case 40: + { + openWorldHint_ = input.readBool(); + bitField0_ |= 0x00000010; + break; + } // case 40 + case 50: + { + com.google.protobuf.MapEntry additionalHints__ = + input.readMessage( + AdditionalHintsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableAdditionalHints() + .getMutableMap() + .put(additionalHints__.getKey(), additionalHints__.getValue()); + bitField0_ |= 0x00000020; + break; + } // case 50 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object title_ = ""; + + /** + * + * + *
                      +     * Optional. A human-readable title for the tool (if different from
                      +     * Tool.title).
                      +     * 
                      + * + * string title = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The title. + */ + public java.lang.String getTitle() { + java.lang.Object ref = title_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + title_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Optional. A human-readable title for the tool (if different from
                      +     * Tool.title).
                      +     * 
                      + * + * string title = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for title. + */ + public com.google.protobuf.ByteString getTitleBytes() { + java.lang.Object ref = title_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + title_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Optional. A human-readable title for the tool (if different from
                      +     * Tool.title).
                      +     * 
                      + * + * string title = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The title to set. + * @return This builder for chaining. + */ + public Builder setTitle(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + title_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. A human-readable title for the tool (if different from
                      +     * Tool.title).
                      +     * 
                      + * + * string title = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearTitle() { + title_ = getDefaultInstance().getTitle(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. A human-readable title for the tool (if different from
                      +     * Tool.title).
                      +     * 
                      + * + * string title = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for title to set. + * @return This builder for chaining. + */ + public Builder setTitleBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + title_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private boolean readOnlyHint_; + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool is read-only.
                      +     * 
                      + * + * optional bool read_only_hint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the readOnlyHint field is set. + */ + @java.lang.Override + public boolean hasReadOnlyHint() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool is read-only.
                      +     * 
                      + * + * optional bool read_only_hint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The readOnlyHint. + */ + @java.lang.Override + public boolean getReadOnlyHint() { + return readOnlyHint_; + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool is read-only.
                      +     * 
                      + * + * optional bool read_only_hint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The readOnlyHint to set. + * @return This builder for chaining. + */ + public Builder setReadOnlyHint(boolean value) { + + readOnlyHint_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool is read-only.
                      +     * 
                      + * + * optional bool read_only_hint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearReadOnlyHint() { + bitField0_ = (bitField0_ & ~0x00000002); + readOnlyHint_ = false; + onChanged(); + return this; + } + + private boolean destructiveHint_; + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool may have destructive side effects.
                      +     * 
                      + * + * optional bool destructive_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the destructiveHint field is set. + */ + @java.lang.Override + public boolean hasDestructiveHint() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool may have destructive side effects.
                      +     * 
                      + * + * optional bool destructive_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The destructiveHint. + */ + @java.lang.Override + public boolean getDestructiveHint() { + return destructiveHint_; + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool may have destructive side effects.
                      +     * 
                      + * + * optional bool destructive_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The destructiveHint to set. + * @return This builder for chaining. + */ + public Builder setDestructiveHint(boolean value) { + + destructiveHint_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool may have destructive side effects.
                      +     * 
                      + * + * optional bool destructive_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDestructiveHint() { + bitField0_ = (bitField0_ & ~0x00000004); + destructiveHint_ = false; + onChanged(); + return this; + } + + private boolean idempotentHint_; + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool is idempotent.
                      +     * 
                      + * + * optional bool idempotent_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the idempotentHint field is set. + */ + @java.lang.Override + public boolean hasIdempotentHint() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool is idempotent.
                      +     * 
                      + * + * optional bool idempotent_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The idempotentHint. + */ + @java.lang.Override + public boolean getIdempotentHint() { + return idempotentHint_; + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool is idempotent.
                      +     * 
                      + * + * optional bool idempotent_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The idempotentHint to set. + * @return This builder for chaining. + */ + public Builder setIdempotentHint(boolean value) { + + idempotentHint_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool is idempotent.
                      +     * 
                      + * + * optional bool idempotent_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearIdempotentHint() { + bitField0_ = (bitField0_ & ~0x00000008); + idempotentHint_ = false; + onChanged(); + return this; + } + + private boolean openWorldHint_; + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool interacts with the open world (e.g.,
                      +     * internet).
                      +     * 
                      + * + * optional bool open_world_hint = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the openWorldHint field is set. + */ + @java.lang.Override + public boolean hasOpenWorldHint() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool interacts with the open world (e.g.,
                      +     * internet).
                      +     * 
                      + * + * optional bool open_world_hint = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The openWorldHint. + */ + @java.lang.Override + public boolean getOpenWorldHint() { + return openWorldHint_; + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool interacts with the open world (e.g.,
                      +     * internet).
                      +     * 
                      + * + * optional bool open_world_hint = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The openWorldHint to set. + * @return This builder for chaining. + */ + public Builder setOpenWorldHint(boolean value) { + + openWorldHint_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Hint indicating if the tool interacts with the open world (e.g.,
                      +     * internet).
                      +     * 
                      + * + * optional bool open_world_hint = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearOpenWorldHint() { + bitField0_ = (bitField0_ & ~0x00000010); + openWorldHint_ = false; + onChanged(); + return this; + } + + private com.google.protobuf.MapField additionalHints_; + + private com.google.protobuf.MapField + internalGetAdditionalHints() { + if (additionalHints_ == null) { + return com.google.protobuf.MapField.emptyMapField( + AdditionalHintsDefaultEntryHolder.defaultEntry); + } + return additionalHints_; + } + + private com.google.protobuf.MapField + internalGetMutableAdditionalHints() { + if (additionalHints_ == null) { + additionalHints_ = + com.google.protobuf.MapField.newMapField( + AdditionalHintsDefaultEntryHolder.defaultEntry); + } + if (!additionalHints_.isMutable()) { + additionalHints_ = additionalHints_.copy(); + } + bitField0_ |= 0x00000020; + onChanged(); + return additionalHints_; + } + + public int getAdditionalHintsCount() { + return internalGetAdditionalHints().getMap().size(); + } + + /** + * + * + *
                      +     * Optional. Additional hints which may help tools and not covered in
                      +     * defaults.
                      +     * 
                      + * + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public boolean containsAdditionalHints(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetAdditionalHints().getMap().containsKey(key); + } + + /** Use {@link #getAdditionalHintsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getAdditionalHints() { + return getAdditionalHintsMap(); + } + + /** + * + * + *
                      +     * Optional. Additional hints which may help tools and not covered in
                      +     * defaults.
                      +     * 
                      + * + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.Map getAdditionalHintsMap() { + return internalGetAdditionalHints().getMap(); + } + + /** + * + * + *
                      +     * Optional. Additional hints which may help tools and not covered in
                      +     * defaults.
                      +     * 
                      + * + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public /* nullable */ java.lang.String getAdditionalHintsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetAdditionalHints().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
                      +     * Optional. Additional hints which may help tools and not covered in
                      +     * defaults.
                      +     * 
                      + * + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.lang.String getAdditionalHintsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetAdditionalHints().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearAdditionalHints() { + bitField0_ = (bitField0_ & ~0x00000020); + internalGetMutableAdditionalHints().getMutableMap().clear(); + return this; + } + + /** + * + * + *
                      +     * Optional. Additional hints which may help tools and not covered in
                      +     * defaults.
                      +     * 
                      + * + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeAdditionalHints(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableAdditionalHints().getMutableMap().remove(key); + return this; + } + + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableAdditionalHints() { + bitField0_ |= 0x00000020; + return internalGetMutableAdditionalHints().getMutableMap(); + } + + /** + * + * + *
                      +     * Optional. Additional hints which may help tools and not covered in
                      +     * defaults.
                      +     * 
                      + * + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder putAdditionalHints(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + internalGetMutableAdditionalHints().getMutableMap().put(key, value); + bitField0_ |= 0x00000020; + return this; + } + + /** + * + * + *
                      +     * Optional. Additional hints which may help tools and not covered in
                      +     * defaults.
                      +     * 
                      + * + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder putAllAdditionalHints(java.util.Map values) { + internalGetMutableAdditionalHints().getMutableMap().putAll(values); + bitField0_ |= 0x00000020; + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.ToolAnnotations) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.ToolAnnotations) + private static final com.google.cloud.apihub.v1.ToolAnnotations DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.ToolAnnotations(); + } + + public static com.google.cloud.apihub.v1.ToolAnnotations getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ToolAnnotations parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.ToolAnnotations getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ToolAnnotationsOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ToolAnnotationsOrBuilder.java new file mode 100644 index 000000000000..d538db26a227 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/ToolAnnotationsOrBuilder.java @@ -0,0 +1,235 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/common_fields.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface ToolAnnotationsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.ToolAnnotations) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Optional. A human-readable title for the tool (if different from
                      +   * Tool.title).
                      +   * 
                      + * + * string title = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The title. + */ + java.lang.String getTitle(); + + /** + * + * + *
                      +   * Optional. A human-readable title for the tool (if different from
                      +   * Tool.title).
                      +   * 
                      + * + * string title = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for title. + */ + com.google.protobuf.ByteString getTitleBytes(); + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool is read-only.
                      +   * 
                      + * + * optional bool read_only_hint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the readOnlyHint field is set. + */ + boolean hasReadOnlyHint(); + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool is read-only.
                      +   * 
                      + * + * optional bool read_only_hint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The readOnlyHint. + */ + boolean getReadOnlyHint(); + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool may have destructive side effects.
                      +   * 
                      + * + * optional bool destructive_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the destructiveHint field is set. + */ + boolean hasDestructiveHint(); + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool may have destructive side effects.
                      +   * 
                      + * + * optional bool destructive_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The destructiveHint. + */ + boolean getDestructiveHint(); + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool is idempotent.
                      +   * 
                      + * + * optional bool idempotent_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the idempotentHint field is set. + */ + boolean hasIdempotentHint(); + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool is idempotent.
                      +   * 
                      + * + * optional bool idempotent_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The idempotentHint. + */ + boolean getIdempotentHint(); + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool interacts with the open world (e.g.,
                      +   * internet).
                      +   * 
                      + * + * optional bool open_world_hint = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the openWorldHint field is set. + */ + boolean hasOpenWorldHint(); + + /** + * + * + *
                      +   * Optional. Hint indicating if the tool interacts with the open world (e.g.,
                      +   * internet).
                      +   * 
                      + * + * optional bool open_world_hint = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The openWorldHint. + */ + boolean getOpenWorldHint(); + + /** + * + * + *
                      +   * Optional. Additional hints which may help tools and not covered in
                      +   * defaults.
                      +   * 
                      + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + int getAdditionalHintsCount(); + + /** + * + * + *
                      +   * Optional. Additional hints which may help tools and not covered in
                      +   * defaults.
                      +   * 
                      + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + boolean containsAdditionalHints(java.lang.String key); + + /** Use {@link #getAdditionalHintsMap()} instead. */ + @java.lang.Deprecated + java.util.Map getAdditionalHints(); + + /** + * + * + *
                      +   * Optional. Additional hints which may help tools and not covered in
                      +   * defaults.
                      +   * 
                      + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.Map getAdditionalHintsMap(); + + /** + * + * + *
                      +   * Optional. Additional hints which may help tools and not covered in
                      +   * defaults.
                      +   * 
                      + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + /* nullable */ + java.lang.String getAdditionalHintsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue); + + /** + * + * + *
                      +   * Optional. Additional hints which may help tools and not covered in
                      +   * defaults.
                      +   * 
                      + * + * map<string, string> additional_hints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.lang.String getAdditionalHintsOrThrow(java.lang.String key); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/UpdateApiHubInstanceRequest.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/UpdateApiHubInstanceRequest.java new file mode 100644 index 000000000000..d66e760f8132 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/UpdateApiHubInstanceRequest.java @@ -0,0 +1,1078 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/provisioning_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +/** + * + * + *
                      + * The
                      + * [UpdateApiHubInstance][google.cloud.apihub.v1.Provisioning.UpdateApiHubInstance]
                      + * method's request.
                      + * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.UpdateApiHubInstanceRequest} + */ +@com.google.protobuf.Generated +public final class UpdateApiHubInstanceRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.apihub.v1.UpdateApiHubInstanceRequest) + UpdateApiHubInstanceRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "UpdateApiHubInstanceRequest"); + } + + // Use UpdateApiHubInstanceRequest.newBuilder() to construct. + private UpdateApiHubInstanceRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private UpdateApiHubInstanceRequest() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ProvisioningServiceProto + .internal_static_google_cloud_apihub_v1_UpdateApiHubInstanceRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ProvisioningServiceProto + .internal_static_google_cloud_apihub_v1_UpdateApiHubInstanceRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest.class, + com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest.Builder.class); + } + + private int bitField0_; + public static final int API_HUB_INSTANCE_FIELD_NUMBER = 1; + private com.google.cloud.apihub.v1.ApiHubInstance apiHubInstance_; + + /** + * + * + *
                      +   * Required. The ApiHub instance to update.
                      +   *
                      +   * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +   * to update.
                      +   * Format:
                      +   * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the apiHubInstance field is set. + */ + @java.lang.Override + public boolean hasApiHubInstance() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Required. The ApiHub instance to update.
                      +   *
                      +   * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +   * to update.
                      +   * Format:
                      +   * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The apiHubInstance. + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiHubInstance getApiHubInstance() { + return apiHubInstance_ == null + ? com.google.cloud.apihub.v1.ApiHubInstance.getDefaultInstance() + : apiHubInstance_; + } + + /** + * + * + *
                      +   * Required. The ApiHub instance to update.
                      +   *
                      +   * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +   * to update.
                      +   * Format:
                      +   * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.apihub.v1.ApiHubInstanceOrBuilder getApiHubInstanceOrBuilder() { + return apiHubInstance_ == null + ? com.google.cloud.apihub.v1.ApiHubInstance.getDefaultInstance() + : apiHubInstance_; + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + + /** + * + * + *
                      +   * Required. The list of fields to update.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Required. The list of fields to update.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + /** + * + * + *
                      +   * Required. The list of fields to update.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getApiHubInstance()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getUpdateMask()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getApiHubInstance()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest)) { + return super.equals(obj); + } + com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest other = + (com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest) obj; + + if (hasApiHubInstance() != other.hasApiHubInstance()) return false; + if (hasApiHubInstance()) { + if (!getApiHubInstance().equals(other.getApiHubInstance())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasApiHubInstance()) { + hash = (37 * hash) + API_HUB_INSTANCE_FIELD_NUMBER; + hash = (53 * hash) + getApiHubInstance().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * The
                      +   * [UpdateApiHubInstance][google.cloud.apihub.v1.Provisioning.UpdateApiHubInstance]
                      +   * method's request.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.apihub.v1.UpdateApiHubInstanceRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.apihub.v1.UpdateApiHubInstanceRequest) + com.google.cloud.apihub.v1.UpdateApiHubInstanceRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.apihub.v1.ProvisioningServiceProto + .internal_static_google_cloud_apihub_v1_UpdateApiHubInstanceRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.apihub.v1.ProvisioningServiceProto + .internal_static_google_cloud_apihub_v1_UpdateApiHubInstanceRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest.class, + com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest.Builder.class); + } + + // Construct using com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetApiHubInstanceFieldBuilder(); + internalGetUpdateMaskFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + apiHubInstance_ = null; + if (apiHubInstanceBuilder_ != null) { + apiHubInstanceBuilder_.dispose(); + apiHubInstanceBuilder_ = null; + } + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.apihub.v1.ProvisioningServiceProto + .internal_static_google_cloud_apihub_v1_UpdateApiHubInstanceRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest getDefaultInstanceForType() { + return com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest build() { + com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest buildPartial() { + com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest result = + new com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.apiHubInstance_ = + apiHubInstanceBuilder_ == null ? apiHubInstance_ : apiHubInstanceBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.updateMask_ = updateMaskBuilder_ == null ? updateMask_ : updateMaskBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest) { + return mergeFrom((com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest other) { + if (other == com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest.getDefaultInstance()) + return this; + if (other.hasApiHubInstance()) { + mergeApiHubInstance(other.getApiHubInstance()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetApiHubInstanceFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.apihub.v1.ApiHubInstance apiHubInstance_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApiHubInstance, + com.google.cloud.apihub.v1.ApiHubInstance.Builder, + com.google.cloud.apihub.v1.ApiHubInstanceOrBuilder> + apiHubInstanceBuilder_; + + /** + * + * + *
                      +     * Required. The ApiHub instance to update.
                      +     *
                      +     * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +     * to update.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the apiHubInstance field is set. + */ + public boolean hasApiHubInstance() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * Required. The ApiHub instance to update.
                      +     *
                      +     * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +     * to update.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The apiHubInstance. + */ + public com.google.cloud.apihub.v1.ApiHubInstance getApiHubInstance() { + if (apiHubInstanceBuilder_ == null) { + return apiHubInstance_ == null + ? com.google.cloud.apihub.v1.ApiHubInstance.getDefaultInstance() + : apiHubInstance_; + } else { + return apiHubInstanceBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Required. The ApiHub instance to update.
                      +     *
                      +     * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +     * to update.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setApiHubInstance(com.google.cloud.apihub.v1.ApiHubInstance value) { + if (apiHubInstanceBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + apiHubInstance_ = value; + } else { + apiHubInstanceBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The ApiHub instance to update.
                      +     *
                      +     * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +     * to update.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setApiHubInstance( + com.google.cloud.apihub.v1.ApiHubInstance.Builder builderForValue) { + if (apiHubInstanceBuilder_ == null) { + apiHubInstance_ = builderForValue.build(); + } else { + apiHubInstanceBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The ApiHub instance to update.
                      +     *
                      +     * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +     * to update.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeApiHubInstance(com.google.cloud.apihub.v1.ApiHubInstance value) { + if (apiHubInstanceBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && apiHubInstance_ != null + && apiHubInstance_ != com.google.cloud.apihub.v1.ApiHubInstance.getDefaultInstance()) { + getApiHubInstanceBuilder().mergeFrom(value); + } else { + apiHubInstance_ = value; + } + } else { + apiHubInstanceBuilder_.mergeFrom(value); + } + if (apiHubInstance_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Required. The ApiHub instance to update.
                      +     *
                      +     * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +     * to update.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearApiHubInstance() { + bitField0_ = (bitField0_ & ~0x00000001); + apiHubInstance_ = null; + if (apiHubInstanceBuilder_ != null) { + apiHubInstanceBuilder_.dispose(); + apiHubInstanceBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The ApiHub instance to update.
                      +     *
                      +     * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +     * to update.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.ApiHubInstance.Builder getApiHubInstanceBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetApiHubInstanceFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Required. The ApiHub instance to update.
                      +     *
                      +     * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +     * to update.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.apihub.v1.ApiHubInstanceOrBuilder getApiHubInstanceOrBuilder() { + if (apiHubInstanceBuilder_ != null) { + return apiHubInstanceBuilder_.getMessageOrBuilder(); + } else { + return apiHubInstance_ == null + ? com.google.cloud.apihub.v1.ApiHubInstance.getDefaultInstance() + : apiHubInstance_; + } + } + + /** + * + * + *
                      +     * Required. The ApiHub instance to update.
                      +     *
                      +     * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +     * to update.
                      +     * Format:
                      +     * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +     * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApiHubInstance, + com.google.cloud.apihub.v1.ApiHubInstance.Builder, + com.google.cloud.apihub.v1.ApiHubInstanceOrBuilder> + internalGetApiHubInstanceFieldBuilder() { + if (apiHubInstanceBuilder_ == null) { + apiHubInstanceBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.apihub.v1.ApiHubInstance, + com.google.cloud.apihub.v1.ApiHubInstance.Builder, + com.google.cloud.apihub.v1.ApiHubInstanceOrBuilder>( + getApiHubInstance(), getParentForChildren(), isClean()); + apiHubInstance_ = null; + } + return apiHubInstanceBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + + /** + * + * + *
                      +     * Required. The list of fields to update.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +     * Required. The list of fields to update.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Required. The list of fields to update.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + } else { + updateMaskBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The list of fields to update.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The list of fields to update.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && updateMask_ != null + && updateMask_ != com.google.protobuf.FieldMask.getDefaultInstance()) { + getUpdateMaskBuilder().mergeFrom(value); + } else { + updateMask_ = value; + } + } else { + updateMaskBuilder_.mergeFrom(value); + } + if (updateMask_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Required. The list of fields to update.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearUpdateMask() { + bitField0_ = (bitField0_ & ~0x00000002); + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The list of fields to update.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetUpdateMaskFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Required. The list of fields to update.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + + /** + * + * + *
                      +     * Required. The list of fields to update.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + internalGetUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.apihub.v1.UpdateApiHubInstanceRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.apihub.v1.UpdateApiHubInstanceRequest) + private static final com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest(); + } + + public static com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateApiHubInstanceRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/UpdateApiHubInstanceRequestOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/UpdateApiHubInstanceRequestOrBuilder.java new file mode 100644 index 000000000000..869243329fad --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/UpdateApiHubInstanceRequestOrBuilder.java @@ -0,0 +1,126 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/apihub/v1/provisioning_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.apihub.v1; + +@com.google.protobuf.Generated +public interface UpdateApiHubInstanceRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.apihub.v1.UpdateApiHubInstanceRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The ApiHub instance to update.
                      +   *
                      +   * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +   * to update.
                      +   * Format:
                      +   * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the apiHubInstance field is set. + */ + boolean hasApiHubInstance(); + + /** + * + * + *
                      +   * Required. The ApiHub instance to update.
                      +   *
                      +   * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +   * to update.
                      +   * Format:
                      +   * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The apiHubInstance. + */ + com.google.cloud.apihub.v1.ApiHubInstance getApiHubInstance(); + + /** + * + * + *
                      +   * Required. The ApiHub instance to update.
                      +   *
                      +   * The ApiHub instance's `name` field is used to identify the ApiHub instance
                      +   * to update.
                      +   * Format:
                      +   * `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`.
                      +   * 
                      + * + * + * .google.cloud.apihub.v1.ApiHubInstance api_hub_instance = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.apihub.v1.ApiHubInstanceOrBuilder getApiHubInstanceOrBuilder(); + + /** + * + * + *
                      +   * Required. The list of fields to update.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + + /** + * + * + *
                      +   * Required. The list of fields to update.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + + /** + * + * + *
                      +   * Required. The list of fields to update.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Version.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Version.java index 7f61789262f9..1ff8269f8443 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Version.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/Version.java @@ -590,10 +590,11 @@ public com.google.protobuf.ByteString getDefinitionsBytes(int index) { * * *
                      -   * Optional. The deployments linked to this API version.
                      -   * Note: A particular API version could be deployed to multiple deployments
                      -   * (for dev deployment, UAT deployment, etc)
                      -   * Format is
                      +   * Optional. The deployments linked directly to this API version. Only
                      +   * directly-linked deployments are returned; deployments linked to this
                      +   * version's specs or operations are not included. Note: A particular API
                      +   * version could be deployed to multiple deployments (for dev deployment, UAT
                      +   * deployment, etc) Format is
                          * `projects/{project}/locations/{location}/deployments/{deployment}`
                          * 
                      * @@ -611,10 +612,11 @@ public com.google.protobuf.ProtocolStringList getDeploymentsList() { * * *
                      -   * Optional. The deployments linked to this API version.
                      -   * Note: A particular API version could be deployed to multiple deployments
                      -   * (for dev deployment, UAT deployment, etc)
                      -   * Format is
                      +   * Optional. The deployments linked directly to this API version. Only
                      +   * directly-linked deployments are returned; deployments linked to this
                      +   * version's specs or operations are not included. Note: A particular API
                      +   * version could be deployed to multiple deployments (for dev deployment, UAT
                      +   * deployment, etc) Format is
                          * `projects/{project}/locations/{location}/deployments/{deployment}`
                          * 
                      * @@ -632,10 +634,11 @@ public int getDeploymentsCount() { * * *
                      -   * Optional. The deployments linked to this API version.
                      -   * Note: A particular API version could be deployed to multiple deployments
                      -   * (for dev deployment, UAT deployment, etc)
                      -   * Format is
                      +   * Optional. The deployments linked directly to this API version. Only
                      +   * directly-linked deployments are returned; deployments linked to this
                      +   * version's specs or operations are not included. Note: A particular API
                      +   * version could be deployed to multiple deployments (for dev deployment, UAT
                      +   * deployment, etc) Format is
                          * `projects/{project}/locations/{location}/deployments/{deployment}`
                          * 
                      * @@ -654,10 +657,11 @@ public java.lang.String getDeployments(int index) { * * *
                      -   * Optional. The deployments linked to this API version.
                      -   * Note: A particular API version could be deployed to multiple deployments
                      -   * (for dev deployment, UAT deployment, etc)
                      -   * Format is
                      +   * Optional. The deployments linked directly to this API version. Only
                      +   * directly-linked deployments are returned; deployments linked to this
                      +   * version's specs or operations are not included. Note: A particular API
                      +   * version could be deployed to multiple deployments (for dev deployment, UAT
                      +   * deployment, etc) Format is
                          * `projects/{project}/locations/{location}/deployments/{deployment}`
                          * 
                      * @@ -3447,10 +3451,11 @@ private void ensureDeploymentsIsMutable() { * * *
                      -     * Optional. The deployments linked to this API version.
                      -     * Note: A particular API version could be deployed to multiple deployments
                      -     * (for dev deployment, UAT deployment, etc)
                      -     * Format is
                      +     * Optional. The deployments linked directly to this API version. Only
                      +     * directly-linked deployments are returned; deployments linked to this
                      +     * version's specs or operations are not included. Note: A particular API
                      +     * version could be deployed to multiple deployments (for dev deployment, UAT
                      +     * deployment, etc) Format is
                            * `projects/{project}/locations/{location}/deployments/{deployment}`
                            * 
                      * @@ -3469,10 +3474,11 @@ public com.google.protobuf.ProtocolStringList getDeploymentsList() { * * *
                      -     * Optional. The deployments linked to this API version.
                      -     * Note: A particular API version could be deployed to multiple deployments
                      -     * (for dev deployment, UAT deployment, etc)
                      -     * Format is
                      +     * Optional. The deployments linked directly to this API version. Only
                      +     * directly-linked deployments are returned; deployments linked to this
                      +     * version's specs or operations are not included. Note: A particular API
                      +     * version could be deployed to multiple deployments (for dev deployment, UAT
                      +     * deployment, etc) Format is
                            * `projects/{project}/locations/{location}/deployments/{deployment}`
                            * 
                      * @@ -3490,10 +3496,11 @@ public int getDeploymentsCount() { * * *
                      -     * Optional. The deployments linked to this API version.
                      -     * Note: A particular API version could be deployed to multiple deployments
                      -     * (for dev deployment, UAT deployment, etc)
                      -     * Format is
                      +     * Optional. The deployments linked directly to this API version. Only
                      +     * directly-linked deployments are returned; deployments linked to this
                      +     * version's specs or operations are not included. Note: A particular API
                      +     * version could be deployed to multiple deployments (for dev deployment, UAT
                      +     * deployment, etc) Format is
                            * `projects/{project}/locations/{location}/deployments/{deployment}`
                            * 
                      * @@ -3512,10 +3519,11 @@ public java.lang.String getDeployments(int index) { * * *
                      -     * Optional. The deployments linked to this API version.
                      -     * Note: A particular API version could be deployed to multiple deployments
                      -     * (for dev deployment, UAT deployment, etc)
                      -     * Format is
                      +     * Optional. The deployments linked directly to this API version. Only
                      +     * directly-linked deployments are returned; deployments linked to this
                      +     * version's specs or operations are not included. Note: A particular API
                      +     * version could be deployed to multiple deployments (for dev deployment, UAT
                      +     * deployment, etc) Format is
                            * `projects/{project}/locations/{location}/deployments/{deployment}`
                            * 
                      * @@ -3534,10 +3542,11 @@ public com.google.protobuf.ByteString getDeploymentsBytes(int index) { * * *
                      -     * Optional. The deployments linked to this API version.
                      -     * Note: A particular API version could be deployed to multiple deployments
                      -     * (for dev deployment, UAT deployment, etc)
                      -     * Format is
                      +     * Optional. The deployments linked directly to this API version. Only
                      +     * directly-linked deployments are returned; deployments linked to this
                      +     * version's specs or operations are not included. Note: A particular API
                      +     * version could be deployed to multiple deployments (for dev deployment, UAT
                      +     * deployment, etc) Format is
                            * `projects/{project}/locations/{location}/deployments/{deployment}`
                            * 
                      * @@ -3564,10 +3573,11 @@ public Builder setDeployments(int index, java.lang.String value) { * * *
                      -     * Optional. The deployments linked to this API version.
                      -     * Note: A particular API version could be deployed to multiple deployments
                      -     * (for dev deployment, UAT deployment, etc)
                      -     * Format is
                      +     * Optional. The deployments linked directly to this API version. Only
                      +     * directly-linked deployments are returned; deployments linked to this
                      +     * version's specs or operations are not included. Note: A particular API
                      +     * version could be deployed to multiple deployments (for dev deployment, UAT
                      +     * deployment, etc) Format is
                            * `projects/{project}/locations/{location}/deployments/{deployment}`
                            * 
                      * @@ -3593,10 +3603,11 @@ public Builder addDeployments(java.lang.String value) { * * *
                      -     * Optional. The deployments linked to this API version.
                      -     * Note: A particular API version could be deployed to multiple deployments
                      -     * (for dev deployment, UAT deployment, etc)
                      -     * Format is
                      +     * Optional. The deployments linked directly to this API version. Only
                      +     * directly-linked deployments are returned; deployments linked to this
                      +     * version's specs or operations are not included. Note: A particular API
                      +     * version could be deployed to multiple deployments (for dev deployment, UAT
                      +     * deployment, etc) Format is
                            * `projects/{project}/locations/{location}/deployments/{deployment}`
                            * 
                      * @@ -3619,10 +3630,11 @@ public Builder addAllDeployments(java.lang.Iterable values) { * * *
                      -     * Optional. The deployments linked to this API version.
                      -     * Note: A particular API version could be deployed to multiple deployments
                      -     * (for dev deployment, UAT deployment, etc)
                      -     * Format is
                      +     * Optional. The deployments linked directly to this API version. Only
                      +     * directly-linked deployments are returned; deployments linked to this
                      +     * version's specs or operations are not included. Note: A particular API
                      +     * version could be deployed to multiple deployments (for dev deployment, UAT
                      +     * deployment, etc) Format is
                            * `projects/{project}/locations/{location}/deployments/{deployment}`
                            * 
                      * @@ -3644,10 +3656,11 @@ public Builder clearDeployments() { * * *
                      -     * Optional. The deployments linked to this API version.
                      -     * Note: A particular API version could be deployed to multiple deployments
                      -     * (for dev deployment, UAT deployment, etc)
                      -     * Format is
                      +     * Optional. The deployments linked directly to this API version. Only
                      +     * directly-linked deployments are returned; deployments linked to this
                      +     * version's specs or operations are not included. Note: A particular API
                      +     * version could be deployed to multiple deployments (for dev deployment, UAT
                      +     * deployment, etc) Format is
                            * `projects/{project}/locations/{location}/deployments/{deployment}`
                            * 
                      * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/VersionOrBuilder.java b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/VersionOrBuilder.java index a7b431d868e1..9e013b9cec27 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/VersionOrBuilder.java +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/java/com/google/cloud/apihub/v1/VersionOrBuilder.java @@ -379,10 +379,11 @@ public interface VersionOrBuilder * * *
                      -   * Optional. The deployments linked to this API version.
                      -   * Note: A particular API version could be deployed to multiple deployments
                      -   * (for dev deployment, UAT deployment, etc)
                      -   * Format is
                      +   * Optional. The deployments linked directly to this API version. Only
                      +   * directly-linked deployments are returned; deployments linked to this
                      +   * version's specs or operations are not included. Note: A particular API
                      +   * version could be deployed to multiple deployments (for dev deployment, UAT
                      +   * deployment, etc) Format is
                          * `projects/{project}/locations/{location}/deployments/{deployment}`
                          * 
                      * @@ -398,10 +399,11 @@ public interface VersionOrBuilder * * *
                      -   * Optional. The deployments linked to this API version.
                      -   * Note: A particular API version could be deployed to multiple deployments
                      -   * (for dev deployment, UAT deployment, etc)
                      -   * Format is
                      +   * Optional. The deployments linked directly to this API version. Only
                      +   * directly-linked deployments are returned; deployments linked to this
                      +   * version's specs or operations are not included. Note: A particular API
                      +   * version could be deployed to multiple deployments (for dev deployment, UAT
                      +   * deployment, etc) Format is
                          * `projects/{project}/locations/{location}/deployments/{deployment}`
                          * 
                      * @@ -417,10 +419,11 @@ public interface VersionOrBuilder * * *
                      -   * Optional. The deployments linked to this API version.
                      -   * Note: A particular API version could be deployed to multiple deployments
                      -   * (for dev deployment, UAT deployment, etc)
                      -   * Format is
                      +   * Optional. The deployments linked directly to this API version. Only
                      +   * directly-linked deployments are returned; deployments linked to this
                      +   * version's specs or operations are not included. Note: A particular API
                      +   * version could be deployed to multiple deployments (for dev deployment, UAT
                      +   * deployment, etc) Format is
                          * `projects/{project}/locations/{location}/deployments/{deployment}`
                          * 
                      * @@ -437,10 +440,11 @@ public interface VersionOrBuilder * * *
                      -   * Optional. The deployments linked to this API version.
                      -   * Note: A particular API version could be deployed to multiple deployments
                      -   * (for dev deployment, UAT deployment, etc)
                      -   * Format is
                      +   * Optional. The deployments linked directly to this API version. Only
                      +   * directly-linked deployments are returned; deployments linked to this
                      +   * version's specs or operations are not included. Note: A particular API
                      +   * version could be deployed to multiple deployments (for dev deployment, UAT
                      +   * deployment, etc) Format is
                          * `projects/{project}/locations/{location}/deployments/{deployment}`
                          * 
                      * diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/addon_service.proto b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/addon_service.proto new file mode 100644 index 000000000000..72c5a74b7747 --- /dev/null +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/addon_service.proto @@ -0,0 +1,304 @@ +// Copyright 2026 Google LLC +// +// 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. + +syntax = "proto3"; + +package google.cloud.apihub.v1; + +import "google/api/annotations.proto"; +import "google/api/client.proto"; +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/cloud/apihub/v1/common_fields.proto"; +import "google/longrunning/operations.proto"; +import "google/protobuf/timestamp.proto"; + +option csharp_namespace = "Google.Cloud.ApiHub.V1"; +option go_package = "cloud.google.com/go/apihub/apiv1/apihubpb;apihubpb"; +option java_multiple_files = true; +option java_outer_classname = "AddonServiceProto"; +option java_package = "com.google.cloud.apihub.v1"; +option php_namespace = "Google\\Cloud\\ApiHub\\V1"; +option ruby_package = "Google::Cloud::ApiHub::V1"; + +// This service is used for managing addons inside the API Hub. +service ApiHubAddon { + option (google.api.default_host) = "apihub.googleapis.com"; + option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/apihub.readonly," + "https://www.googleapis.com/auth/apihub.readwrite," + "https://www.googleapis.com/auth/cloud-platform"; + + // Get an addon. + rpc GetAddon(GetAddonRequest) returns (Addon) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/addons/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Manage addon config. + // This RPC is used for managing the config of the addon. Calling this RPC + // moves the addon into an updating state until the long-running operation + // succeeds. + rpc ManageAddonConfig(ManageAddonConfigRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{name=projects/*/locations/*/addons/*}:manageConfig" + body: "*" + }; + option (google.api.method_signature) = "name,config"; + option (google.longrunning.operation_info) = { + response_type: "Addon" + metadata_type: "OperationMetadata" + }; + } + + // List addons. + rpc ListAddons(ListAddonsRequest) returns (ListAddonsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/addons" + }; + option (google.api.method_signature) = "parent"; + } +} + +// Addon resource. +message Addon { + option (google.api.resource) = { + type: "apihub.googleapis.com/Addon" + pattern: "projects/{project}/locations/{location}/addons/{addon}" + plural: "addons" + singular: "addon" + }; + + // Identifier. The name of the addon to enable. + // Format: `projects/{project}/locations/{location}/addons/{addon}`. + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Required. The display name of the addon. + string display_name = 2 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The description of the addon. + string description = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Required. The data source on which the addon operates. This determines + // which field in the `config` oneof is used. + DataSource data_source = 4 [(google.api.field_behavior) = REQUIRED]; + + // Output only. The time at which the addon was created. + google.protobuf.Timestamp create_time = 5 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The time at which the addon was last updated. + google.protobuf.Timestamp update_time = 6 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Required. The configuration of the addon. + AddonConfig config = 7 [(google.api.field_behavior) = REQUIRED]; + + // Output only. The state of the addon. + AddonState state = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The Vertex AI region where the BoostSpec Gemini model calls + // run for this API Hub instance. Populated only for the SpecGen addon + // (`system-spec-generation`); other addons leave this field empty. + // + // `gemini-2.5-flash` is not available in every API Hub region, so the + // effective region may differ from the API Hub instance's own region. + // The value follows these semantics: + // + // - `""`: BoostSpec is disabled in this region (the addon is not + // SpecGen, or the API Hub instance region has no configured + // Gemini endpoint or fallback). + // - Equal to the API Hub instance region: BoostSpec calls run + // in-region. + // - Differs from the API Hub instance region: BoostSpec calls run + // in the specified fallback region. + // + // Callers rendering this field can derive the three display states + // from this single field combined with the API Hub instance region. + string boost_spec_gemini_region_id = 9 + [(google.api.field_behavior) = OUTPUT_ONLY]; +} + +// Filter for environments. +message EnvironmentFilter { + // Optional. Indicates if this filter should match all environments or only + // a subset of environments. + // If set to true, all environments are matched. + bool all_environments = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. If provided, only environments in this list are matched. This + // field is ignored if `all_environments` is true. + repeated string environments = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// Configuration for a gateway plugin. +// This is used to specify configs for different gateways. +message GatewayPluginConfig { + // The config of the gateway plugin. + oneof config { + // Configuration for Apigee X and Apigee Hybrid gateways. + ApigeeXHybridConfig apigee_x_hybrid_config = 2; + + // Configuration for Apigee Edge gateways. + ApigeeEdgeConfig apigee_edge_config = 3; + + // Configuration for Apigee OPDK gateways. + ApigeeOPDKConfig apigee_opdk_config = 4; + } + + // Required. The name of the gateway plugin instance for which the config is + // to be specified. Format: + // projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance} + string plugin_instance = 1 [(google.api.field_behavior) = REQUIRED]; +} + +// Configuration for Apigee X and Apigee Hybrid gateways. Applicability of a +// filter is determined by the filter being provided. If none of the filters are +// provided the addon will be enabled for all data brought in by the gateway +// plugin instance. +message ApigeeXHybridConfig { + // Optional. The filter to apply on the resources managed by the gateway + // plugin instance. If provided this filter applies environment specific + // filtering. + EnvironmentFilter environment_filter = 1 + [(google.api.field_behavior) = OPTIONAL]; +} + +// Configuration for Apigee Edge gateways. Applicability of a +// filter is determined by the filter being provided. If none of the filters are +// provided the addon will be enabled for all data brought in by the gateway +// plugin instance. +message ApigeeEdgeConfig { + // Optional. The filter to apply on the resources managed by the gateway + // plugin instance. If provided this filter applies environment specific + // filtering. + EnvironmentFilter environment_filter = 1 + [(google.api.field_behavior) = OPTIONAL]; +} + +// Configuration for Apigee OPDK gateways. Applicability of a +// filter is determined by the filter being provided. If none of the filters are +// provided the addon will be enabled for all data brought in by the gateway +// plugin instance. +message ApigeeOPDKConfig { + // Optional. The filter to apply on the resources managed by the gateway + // plugin instance. If provided this filter applies environment specific + // filtering. + EnvironmentFilter environment_filter = 1 + [(google.api.field_behavior) = OPTIONAL]; +} + +// Configuration for gateway plugin addons. +// This is used to specify the list of gateway plugin configs for which the +// addon is enabled. +message GatewayPluginAddonConfig { + // Required. The list of gateway plugin configs for which the addon is + // enabled. Each gateway plugin config should have a unique plugin instance. + repeated GatewayPluginConfig gateway_plugin_configs = 1 + [(google.api.field_behavior) = REQUIRED]; +} + +// Configuration for addons which act on all data in the API hub. +// This is used to specify if the addon is enabled for all data in the API hub. +message AllDataAddonConfig { + // Required. If true, the addon is enabled for all data in the API hub. + bool enabled = 1 [(google.api.field_behavior) = REQUIRED]; +} + +// Configuration for the addon. +message AddonConfig { + // Addon configuration, which varies based on the data_source. Keeping this as + // a oneof in case we want to add configuration for other data sources in the + // future. + oneof config { + // Configuration for gateway plugin addons. + GatewayPluginAddonConfig gateway_plugin_addon_config = 1; + + // Configuration for addons which act on all data in the API hub. + AllDataAddonConfig all_data_addon_config = 2; + } +} + +// The [GetAddon][google.cloud.apihub.v1.ApiHubAddon.GetAddon] method's request. +message GetAddonRequest { + // Required. The name of the addon to get. + // Format: `projects/{project}/locations/{location}/addons/{addon}`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { type: "apihub.googleapis.com/Addon" } + ]; +} + +// The [ManageAddonConfig][google.cloud.apihub.v1.ApiHubAddon.ManageAddonConfig] +// method's request. +message ManageAddonConfigRequest { + // Required. The name of the addon for which the config is to be managed. + // Format: `projects/{project}/locations/{location}/addons/{addon}`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { type: "apihub.googleapis.com/Addon" } + ]; + + // Required. The config of the addon to be managed. This config will replace + // the config present in the addon. The type of the config should match the + // config type already present in the addon. + AddonConfig config = 2 [(google.api.field_behavior) = REQUIRED]; +} + +// The [ListAddons][google.cloud.apihub.v1.ApiHubAddon.ListAddons] method's +// request. +message ListAddonsRequest { + // Required. The parent resource where this addon will be created. + // Format: `projects/{project}/locations/{location}`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "apihub.googleapis.com/Addon" + } + ]; + + // Optional. An expression that filters the list of addons. + // The only supported filter is `plugin_instance_name`. It can be used to + // filter addons that are enabled for a given plugin instance. + // The format of the filter is `plugin_instance_name = + // "projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}"`. + string filter = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The maximum number of hub addons to return. The service may + // return fewer than this value. If unspecified, at most 50 hub addons will be + // returned. The maximum value is 1000; values above 1000 will be coerced to + // 1000. + int32 page_size = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A page token, received from a previous `ListAddons` call. + // Provide this to retrieve the subsequent page. + // + // When paginating, all other parameters (except page_size) provided to + // `ListAddons` must match the call that provided the page token. + string page_token = 4 [(google.api.field_behavior) = OPTIONAL]; +} + +// The [ListAddons][google.cloud.apihub.v1.ApiHubAddon.ListAddons] method's +// response. +message ListAddonsResponse { + // The list of addons. + repeated Addon addons = 1; + + // A token to retrieve the next page of results, or empty if there are no + // more results in the list. + string next_page_token = 2; +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/apihub_service.proto b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/apihub_service.proto index 4d90c680f6a6..8afb2679a40d 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/apihub_service.proto +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/apihub_service.proto @@ -1,4 +1,4 @@ -// Copyright 2025 Google LLC +// Copyright 2026 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -21,6 +21,7 @@ import "google/api/client.proto"; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; import "google/cloud/apihub/v1/common_fields.proto"; +import "google/longrunning/operations.proto"; import "google/protobuf/empty.proto"; import "google/protobuf/field_mask.proto"; @@ -36,6 +37,8 @@ option ruby_package = "Google::Cloud::ApiHub::V1"; service ApiHub { option (google.api.default_host) = "apihub.googleapis.com"; option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/apihub.readonly," + "https://www.googleapis.com/auth/apihub.readwrite," "https://www.googleapis.com/auth/cloud-platform"; // Create an API resource in the API hub. @@ -77,6 +80,7 @@ service ApiHub { // * [maturity_level][google.cloud.apihub.v1.Api.maturity_level] // * [api_style][google.cloud.apihub.v1.Api.api_style] // * [attributes][google.cloud.apihub.v1.Api.attributes] + // * [fingerprint][google.cloud.apihub.v1.Api.fingerprint] // // The // [update_mask][google.cloud.apihub.v1.UpdateApiRequest.update_mask] @@ -208,6 +212,15 @@ service ApiHub { option (google.api.method_signature) = "name"; } + // Fetch additional spec content. + rpc FetchAdditionalSpecContent(FetchAdditionalSpecContentRequest) + returns (FetchAdditionalSpecContentResponse) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}:fetchAdditionalSpecContent" + }; + option (google.api.method_signature) = "name,spec_content_type"; + } + // List specs corresponding to a particular API resource. rpc ListSpecs(ListSpecsRequest) returns (ListSpecsResponse) { option (google.api.http) = { @@ -248,7 +261,7 @@ service ApiHub { // Delete a spec. // Deleting a spec will also delete the associated operations from the - // version. + // version and remove any links between the spec and deployments. rpc DeleteSpec(DeleteSpecRequest) returns (google.protobuf.Empty) { option (google.api.http) = { delete: "/v1/{name=projects/*/locations/*/apis/*/versions/*/specs/*}" @@ -295,6 +308,18 @@ service ApiHub { // * [details.http_operation.method][ApiOperation.details.http_operation.method] // * [details.deprecated][ApiOperation.details.deprecated] // * [attributes][google.cloud.apihub.v1.ApiOperation.attributes] + // * [details.mcp_tool.title][ApiOperation.details.mcp_tool.title] + // * [details.mcp_tool.description][ApiOperation.details.mcp_tool.description] + // * [details.mcp_tool.input_schema][ApiOperation.details.mcp_tool.input_schema] + // * [details.mcp_tool.output_schema][ApiOperation.details.mcp_tool.output_schema] + // * [details.input_schema][ApiOperation.details.input_schema] + // * [details.output_schema][ApiOperation.details.output_schema] + // * [details.mcp_tool.annotations.title][ApiOperation.details.mcp_tool.annotations.title] + // * [details.mcp_tool.annotations.read_only_hint][ApiOperation.details.mcp_tool.annotations.read_only_hint] + // * [details.mcp_tool.annotations.destructive_hint][ApiOperation.details.mcp_tool.annotations.destructive_hint] + // * [details.mcp_tool.annotations.idempotent_hint][ApiOperation.details.mcp_tool.annotations.idempotent_hint] + // * [details.mcp_tool.annotations.open_world_hint][ApiOperation.details.mcp_tool.annotations.open_world_hint] + // * [details.mcp_tool.annotations.additional_hints][ApiOperation.details.mcp_tool.annotations.additional_hints] // // The // [update_mask][google.cloud.apihub.v1.UpdateApiOperationRequest.update_mask] @@ -315,6 +340,8 @@ service ApiHub { // Delete an operation in an API version and we can delete only the // operations created via create API. If the operation was created by parsing // the spec, then it can be deleted by editing or deleting the spec. + // Deleting an operation will also remove any links between the operation and + // deployments. rpc DeleteApiOperation(DeleteApiOperationRequest) returns (google.protobuf.Empty) { option (google.api.http) = { @@ -388,7 +415,9 @@ service ApiHub { option (google.api.method_signature) = "deployment,update_mask"; } - // Delete a deployment resource in the API hub. + // Deletes a deployment resource in the API hub. A deployment can only be + // deleted after its links to any versions, specs, and API operations have + // been removed. rpc DeleteDeployment(DeleteDeploymentRequest) returns (google.protobuf.Empty) { option (google.api.http) = { @@ -536,6 +565,33 @@ service ApiHub { }; option (google.api.method_signature) = "parent"; } + + // Retrieve API views. + rpc RetrieveApiViews(RetrieveApiViewsRequest) + returns (RetrieveApiViewsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}:retrieveApiViews" + }; + option (google.api.method_signature) = "parent,view"; + } + + // Configures and deploys a given server config for given target. Currently + // this API supports only deploying MCP server in Apigee X. For mcp server + // deployment in apigee X, if there is already a mcp proxy deployed, then this + // method will try to overwrite it by creating new revision i.e. all existing + // tools will be removed and new set of tools will be deployed. + rpc ConfigureAndDeployServer(ConfigureAndDeployServerRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*}/servers:configureAndDeployServer" + body: "*" + }; + option (google.api.method_signature) = "parent,mcp_server_config"; + option (google.longrunning.operation_info) = { + response_type: "ConfigureAndDeployServerResponse" + metadata_type: "OperationMetadata" + }; + } } // This service provides methods for various operations related to a @@ -543,6 +599,8 @@ service ApiHub { service ApiHubDependencies { option (google.api.default_host) = "apihub.googleapis.com"; option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/apihub.readonly," + "https://www.googleapis.com/auth/apihub.readwrite," "https://www.googleapis.com/auth/cloud-platform"; // Create a dependency between two entities in the API hub. @@ -596,6 +654,18 @@ service ApiHubDependencies { } } +// The view type of API. +enum ApiViewType { + // The default view type. + API_VIEW_TYPE_UNSPECIFIED = 0; + + // The MCP server view in API hub. + MCP_SERVER = 1; + + // The MCP tool view in API hub. + MCP_TOOL = 2; +} + // The [CreateApi][google.cloud.apihub.v1.ApiHub.CreateApi] method's request. message CreateApiRequest { // Required. The parent resource for the API resource. @@ -749,6 +819,12 @@ message ListApisRequest { // provided the parent is // `projects/test-project-id/locations/test-location-id`. // + // Another supported filter function is `plugins(source_metadata)`. This + // function filters for resources that are associated with a specific plugin. + // For example, `plugins(source_metadata) : + // "projects/test-project-id/locations/test-location-id/plugins/test-plugin-id"` + // will return resources sourced from the given plugin. + // // Expressions are combined with either `AND` logic operator or `OR` logical // operator but not both of them together i.e. only one of the `AND` or `OR` // operator can be used throughout the filter string and both the operators @@ -1204,6 +1280,31 @@ message GetSpecContentsRequest { ]; } +// The +// [FetchAdditionalSpecContent][google.cloud.apihub.v1.ApiHub.FetchAdditionalSpecContent] +// method's request. +message FetchAdditionalSpecContentRequest { + // Required. The name of the spec whose contents need to be retrieved. + // Format: + // `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { type: "apihub.googleapis.com/Spec" } + ]; + + // Optional. The type of the spec contents to be retrieved. + SpecContentType spec_content_type = 2 + [(google.api.field_behavior) = OPTIONAL]; +} + +// The +// [FetchAdditionalSpecContent][google.cloud.apihub.v1.ApiHub.FetchAdditionalSpecContent] +// method's response. +message FetchAdditionalSpecContentResponse { + // The additional spec content. + AdditionalSpecContent additional_spec_content = 1; +} + // The [CreateApiOperation][google.cloud.apihub.v1.ApiHub.CreateApiOperation] // method's request. message CreateApiOperationRequest { @@ -1228,7 +1329,7 @@ message CreateApiOperationRequest { // This value should be 4-500 characters, overall resource name which // will be of format // `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}`, - // its length is limited to 700 characters, and valid characters are + // its length is limited to 1000 characters, and valid characters are // /[a-z][A-Z][0-9]-_/. string api_operation_id = 2 [(google.api.field_behavior) = OPTIONAL]; @@ -2127,3 +2228,225 @@ message ListExternalApisResponse { // If this field is omitted, there are no subsequent pages. string next_page_token = 2; } + +// The +// [RetrieveApiViews][google.cloud.apihub.v1.ApiHub.RetrieveApiViews] +// method's request. +message RetrieveApiViewsRequest { + // Required. The parent resource name. + // Format: `projects/{project}/locations/{location}`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "locations.googleapis.com/Location" + } + ]; + + // Optional. The filter expression. + string filter = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The maximum number of results to return. Default to 100. + int32 page_size = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A page token, received from a previous `RetrieveApiViews` + // call. Provide this to retrieve the subsequent page. + string page_token = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Required. The view type to return. + ApiViewType view = 5 [(google.api.field_behavior) = REQUIRED]; +} + +// The view of an API. +message ApiView { + // API view. + oneof view { + // MCP server view. + FlattenedApiVersionDeploymentView mcp_server_view = 1; + + // MCP tools view. + FlattenedApiVersionOperationDeploymentView mcp_tool_view = 2; + } +} + +// A flattened view of an API, its version and one of the linked deployments. +message FlattenedApiVersionDeploymentView { + // Optional. The API. + Api api = 1 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The version. + Version version = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The deployment. + Deployment deployment = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// A flattened view of an API, its version, one of its operations and one of the +// linked deployments. If there are no deployments linked to the operation then +// the result will be empty. +message FlattenedApiVersionOperationDeploymentView { + // Optional. The API. + Api api = 1 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The version. + Version version = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The API operation. + ApiOperation api_operation = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The deployment. + Deployment deployment = 4 [(google.api.field_behavior) = OPTIONAL]; +} + +// The +// [RetrieveApiViews][google.cloud.apihub.v1.ApiHub.RetrieveApiViews] +// method's response. +message RetrieveApiViewsResponse { + // Output only. The list of API views. + repeated ApiView api_views = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Next page token. + string next_page_token = 2; +} + +// Request message for +// [ApiHub.ConfigureAndDeployServer][google.cloud.apihub.v1.ApiHub.ConfigureAndDeployServer]. +message ConfigureAndDeployServerRequest { + // Protocol-specific server configuration. + oneof server_config { + // MCP (Model Context Protocol) server configuration. + McpServerConfig mcp_server_config = 2; + } + + // Required. Format: `projects/{project}/locations/{location}` + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "locations.googleapis.com/Location" + } + ]; +} + +// MCP-specific server configuration. +message McpServerConfig { + // A tool exposed by the MCP server. Each tool wraps exactly one API + // Hub operation under a caller-supplied identifier. + message McpToolConfig { + // Required. Caller-supplied identifier for the tool; each tool must have a + // unique identifier. This will be by used by agents to invoke the tool. + // Tool ID must be unique across all tools in the given MCP server + // configuration. + string tool_id = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. Description of what the tool does and how it is used. + // Description serves as key reference for the agent to know about the tool + // capabilities. + string description = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. The API Hub operation this tool exposes. Each tool + // wraps exactly one operation; callers that want to expose multiple + // operations should declare multiple tools. + OperationConfig operation = 3 [(google.api.field_behavior) = REQUIRED]; + } + + // The target runtime where the MCP server will be deployed. + // Currently only Apigee X is supported. + oneof target { + // Optional. The target Apigee X configuration. + ApigeeXTargetDetails apigee_x_target_details = 2 + [(google.api.field_behavior) = OPTIONAL]; + } + + // Required. The tools to expose on the MCP server. + repeated McpToolConfig tools = 1 [(google.api.field_behavior) = REQUIRED]; +} + +// The target configuration for Apigee X. +// Note: If this API is called while an earlier deployment is still in +// progress, the earlier deployment will be aborted and a new deployment will +// be triggered. +message ApigeeXTargetDetails { + // Metadata for the server configuration in Apigee X. + message MetaData { + // Optional. Display name for the server. For apigee target, this will be + // used as revision display name. + string display_name = 1 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Description for the server. For apigee target, this will be + // used as revision description. + string description = 2 [(google.api.field_behavior) = OPTIONAL]; + } + + // Required. The specific Apigee environment where the server will be + // deployed. + string environment = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. This name identifies the proxy resource in Apigee. It typically + // follows a standard alphanumeric format (e.g., "mcp-discovery-server"). + string proxy = 3 [(google.api.field_behavior) = REQUIRED]; + + // Required. The runtime project that hosts the Apigee X organization. This + // must be one of the runtime projects attached to the API Hub host project. + string target_project = 4 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Metadata for the proxy configuration in Apigee X. + MetaData metadata = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The revision number of the Apigee proxy that was deployed. + string deployed_revision = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; +} + +// API hub Operation config. +message OperationConfig { + // Identifies a single API Hub operation by spec resource name + HTTP + // path + HTTP method. + message HttpOperationConfig { + // Required. Spec resource name: + // `projects/{project}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}` + string spec = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { type: "apihub.googleapis.com/Spec" } + ]; + + // Required. HTTP path of the operation within the referenced spec. + // Match is exact (no template substitution): the path here must + // appear verbatim on an APIOperationRevision belonging to the spec. + string path = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. HTTP method of the operation within the referenced spec. + // (GET / PUT / POST / DELETE / OPTIONS / HEAD / PATCH / TRACE). + HttpOperation.Method method = 3 [(google.api.field_behavior) = REQUIRED]; + } + + // The operation identifier. + oneof identifier { + // Full API Hub operation resource name: + // `projects/{project}/locations/{location}/apis/{api}/versions/{version}/operations/{operation}` + string operation = 1 [(google.api.resource_reference) = { + type: "apihub.googleapis.com/ApiOperation" + }]; + + // The HTTP operation config. + HttpOperationConfig http_operation = 2; + } +} + +// Response message for +// [ApiHub.ConfigureAndDeployServer][google.cloud.apihub.v1.ApiHub.ConfigureAndDeployServer]. +message ConfigureAndDeployServerResponse { + // The result of the server configuration and deployment. + oneof server_details { + // MCP server result. + McpServerDetails mcp_server_details = 1; + } +} + +// Result of the +// [ApiHub.ConfigureAndDeployServer][google.cloud.apihub.v1.ApiHub.ConfigureAndDeployServer] +// method for MCP servers. +message McpServerDetails { + // Runtime-deployment details. + oneof details { + // Details of the Apigee X deployment. + ApigeeXTargetDetails apigee_x_details = 1; + } +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/collect_service.proto b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/collect_service.proto index cd59bf317342..3fbcfe60cfd7 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/collect_service.proto +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/collect_service.proto @@ -1,4 +1,4 @@ -// Copyright 2025 Google LLC +// Copyright 2026 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -38,6 +38,7 @@ option ruby_package = "Google::Cloud::ApiHub::V1"; service ApiHubCollect { option (google.api.default_host) = "apihub.googleapis.com"; option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/apihub.readwrite," "https://www.googleapis.com/auth/cloud-platform"; // Collect API data from a source and push it to Hub's collect layer. @@ -192,6 +193,15 @@ message SpecMetadata { // source. google.protobuf.Timestamp original_update_time = 4 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The gateway-side URIs of deployments that serve this spec. If + // provided, the API Hub service creates links between this spec and the + // deployments identified by these URIs. URIs that don't match any known + // deployment are ignored; a subsequent ingestion cycle that includes the + // missing deployment will re-establish the link. The maximum number of URIs + // allowed is 100. + repeated string deployment_resource_uris = 5 + [(google.api.field_behavior) = OPTIONAL]; } // The metadata associated with a deployment. diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/common_fields.proto b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/common_fields.proto index 34497ca67256..fefb2e3440ba 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/common_fields.proto +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/common_fields.proto @@ -1,4 +1,4 @@ -// Copyright 2025 Google LLC +// Copyright 2026 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -18,6 +18,7 @@ package google.cloud.apihub.v1; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; +import "google/protobuf/struct.proto"; import "google/protobuf/timestamp.proto"; option csharp_namespace = "Google.Cloud.ApiHub.V1"; @@ -99,6 +100,36 @@ enum AuthType { OAUTH2_CLIENT_CREDENTIALS = 5; } +// The data source on which the addon operates. +enum DataSource { + // The data source of the addon is not specified. + DATA_SOURCE_UNSPECIFIED = 0; + + // Addon operates on data collected from specific plugin instances. + PLUGIN_INSTANCE = 1; + + // Addon operates on all data in the API hub. + ALL_DATA = 2; +} + +// The state of the addon. +enum AddonState { + // The addon state is not specified. + ADDON_STATE_UNSPECIFIED = 0; + + // The addon is active. + ACTIVE = 1; + + // The addon is being updated. + UPDATING = 2; + + // The addon is in error state. + ERROR = 3; + + // The addon is inactive. + INACTIVE = 4; +} + // Enum for the plugin category. enum PluginCategory { // Default unspecified plugin type. @@ -112,6 +143,21 @@ enum PluginCategory { API_PRODUCER = 2; } +// Enumerations of the spec content types. +// More values may be added in the future. +enum SpecContentType { + // Unspecified spec content type. + // Defaults to spec content uploaded by the user. + SPEC_CONTENT_TYPE_UNSPECIFIED = 0; + + // The spec content type for boosted spec. + BOOSTED_SPEC_CONTENT = 1; + + // The spec content type for OpenAPI spec. This enum is used for OpenAPI specs + // ingested via APIGEE X Gateway. + GATEWAY_OPEN_API_SPEC = 2; +} + // An API resource in the API Hub. message Api { option (google.api.resource) = { @@ -223,7 +269,7 @@ message Api { ]; // Optional. The api requirement doc associated with the API resource. - // Carinality is 1 for this attribute. This maps to the following system + // Cardinality is 1 for this attribute. This maps to the following system // defined attribute: // `projects/{project}/locations/{location}/attributes/system-api-requirements` // attribute. The value of the attribute should be a proper URI, and in case @@ -232,7 +278,9 @@ message Api { AttributeValues api_requirements = 16 [(google.api.field_behavior) = OPTIONAL]; - // Optional. Fingerprint of the API resource. + // Optional. Fingerprint of the API resource. This must be unique for each API + // resource. It can neither be unset nor be updated to an existing fingerprint + // of another API resource. string fingerprint = 17 [(google.api.field_behavior) = OPTIONAL]; // Output only. The list of sources and metadata from the sources of the API @@ -241,7 +289,7 @@ message Api { [(google.api.field_behavior) = OUTPUT_ONLY]; // Optional. The api functional requirements associated with the API resource. - // Carinality is 1 for this attribute. + // Cardinality is 1 for this attribute. // This maps to the following system defined attribute: // `projects/{project}/locations/{location}/attributes/system-api-functional-requirements` // attribute. The value of the attribute should be a proper URI, and in case @@ -251,7 +299,7 @@ message Api { [(google.api.field_behavior) = OPTIONAL]; // Optional. The api technical requirements associated with the API resource. - // Carinality is 1 for this attribute. This maps to the following system + // Cardinality is 1 for this attribute. This maps to the following system // defined attribute: // `projects/{project}/locations/{location}/attributes/system-api-technical-requirements` // attribute. The value of the attribute should be a proper URI, and in case @@ -259,6 +307,14 @@ message Api { // not a directory. AttributeValues api_technical_requirements = 20 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The type of the service. + // This maps to the following system defined attribute: + // `projects/{project}/locations/{location}/attributes/system-service-type` + // attribute. + // The cardinality of this attribute is 1. All values should be from the list + // of allowed values defined for the attribute. + AttributeValues service_type = 21 [(google.api.field_behavior) = OPTIONAL]; } // Represents a version of the API resource in API hub. This is also referred @@ -317,10 +373,11 @@ message Version { } ]; - // Optional. The deployments linked to this API version. - // Note: A particular API version could be deployed to multiple deployments - // (for dev deployment, UAT deployment, etc) - // Format is + // Optional. The deployments linked directly to this API version. Only + // directly-linked deployments are returned; deployments linked to this + // version's specs or operations are not included. Note: A particular API + // version could be deployed to multiple deployments (for dev deployment, UAT + // deployment, etc) Format is // `projects/{project}/locations/{location}/deployments/{deployment}` repeated string deployments = 8 [ (google.api.field_behavior) = OPTIONAL, @@ -490,6 +547,43 @@ message Spec { // Output only. The list of sources and metadata from the sources of the spec. repeated SourceMetadata source_metadata = 13 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The additional spec contents for the spec. + repeated AdditionalSpecContent additional_spec_contents = 14 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. The deployments linked directly to this spec. + // Format is + // `projects/{project}/locations/{location}/deployments/{deployment}` + repeated string deployments = 15 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.resource_reference) = { + type: "apihub.googleapis.com/Deployment" + } + ]; +} + +// The additional spec content for the spec. +// This contains the metadata and the last update time for the additional spec +// content. +message AdditionalSpecContent { + // Required. The type of the spec content. + SpecContentType spec_content_type = 1 + [(google.api.field_behavior) = REQUIRED]; + + // Optional. The additional spec contents. + SpecContents spec_contents = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The time at which the spec content was created. + google.protobuf.Timestamp create_time = 3 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The time at which the spec content was last updated. + google.protobuf.Timestamp update_time = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. The labels of the spec content e.g. specboost addon version. + map labels = 5 [(google.api.field_behavior) = OPTIONAL]; } // Details of the deployment where APIs are hosted. @@ -607,13 +701,35 @@ message Deployment { AttributeValues source_uri = 16 [(google.api.field_behavior) = OPTIONAL]; // Optional. The project to which the deployment belongs. - // For GCP gateways, this will refer to the project identifier. + // For Google Cloud gateways, this will refer to the project identifier. // For others like Edge/OPDK, this will refer to the org identifier. string source_project = 17 [(google.api.field_behavior) = OPTIONAL]; // Optional. The environment at source for the deployment. // For example: prod, dev, staging, etc. string source_environment = 18 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The specs linked directly to this deployment. + // Note: a deployment could serve multiple specs (e.g., across different + // revisions of the same underlying gateway configuration). + repeated string specs = 19 [ + (google.api.field_behavior) = OUTPUT_ONLY, + (google.api.resource_reference) = { type: "apihub.googleapis.com/Spec" } + ]; + + // Output only. The API operations linked directly to this deployment. + repeated string api_operations = 20 [ + (google.api.field_behavior) = OUTPUT_ONLY, + (google.api.resource_reference) = { + type: "apihub.googleapis.com/ApiOperation" + } + ]; + + // Optional. A revision identifier for the underlying gateway configuration + // that this deployment serves. For Apigee gateway variants, this is typically + // the proxy revision number populated automatically when the deployment is + // discovered. + string source_revision = 21 [(google.api.field_behavior) = OPTIONAL]; } // Represents an operation contained in an API version in the API Hub. @@ -673,6 +789,18 @@ message ApiOperation { // operation. repeated SourceMetadata source_metadata = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. The deployments linked directly to this API operation. For + // operations parsed from a spec, `UpdateApiOperation` returns + // `FAILED_PRECONDITION`; link the parent spec to the deployment via + // `Spec.deployments` instead. Format is + // `projects/{project}/locations/{location}/deployments/{deployment}` + repeated string deployments = 8 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.resource_reference) = { + type: "apihub.googleapis.com/Deployment" + } + ]; } // Represents a definition for example schema, request, response definitions @@ -760,8 +888,8 @@ message Attribute { // will be used. In this case, the service will handle conflict resolution // by adding a system generated suffix in case of duplicates. // - // This value should be 4-63 characters, and valid characters - // are /[a-z][0-9]-/. + // This value should be 3-500 characters, and valid characters + // are /[a-z][A-Z][0-9]-_/. string id = 1 [(google.api.field_behavior) = REQUIRED]; // Required. The display name of the allowed value. @@ -892,7 +1020,8 @@ message Attribute { // The spec contents. message SpecContents { - // Required. The contents of the spec. + // Required. The contents of the spec. The contents should be base64 encoded + // when calling methods such as CreateSpec, UpdateSpec and CollectApiData. bytes contents = 1 [(google.api.field_behavior) = REQUIRED]; // Required. The mime type of the content for example application/json, @@ -953,6 +1082,9 @@ message OperationDetails { oneof operation { // The HTTP Operation. HttpOperation http_operation = 4; + + // The MCP Tool Operation. + McpTool mcp_tool = 5; } // Optional. Description of the operation behavior. @@ -969,6 +1101,64 @@ message OperationDetails { bool deprecated = 3 [(google.api.field_behavior) = OPTIONAL]; } +// The operation schema needed for an operation. +message OperationSchema { + // The value of the schema. + oneof value { + // The JSON schema. Only valid JSON is accepted but semantic validation of + // schema is not supported right now. + google.protobuf.Struct json_schema = 1; + } +} + +// Details describing an MCP Tool. +message McpTool { + // Required. The name of the tool, unique within its parent scope (version). + string name = 1 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Optional title for the tool. + string title = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Description of what the tool does. + string description = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Optional annotations for the tool. + ToolAnnotations annotations = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Input schema for the operation. This can be parsed only from MCP + // schema type. + OperationSchema input_schema = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Output schema for the operation. This can be parsed only from MCP + // schema type. + OperationSchema output_schema = 6 [(google.api.field_behavior) = OPTIONAL]; +} + +// Annotations for a Tool. +message ToolAnnotations { + // Optional. A human-readable title for the tool (if different from + // Tool.title). + string title = 1 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Hint indicating if the tool is read-only. + optional bool read_only_hint = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Hint indicating if the tool may have destructive side effects. + optional bool destructive_hint = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Hint indicating if the tool is idempotent. + optional bool idempotent_hint = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Hint indicating if the tool interacts with the open world (e.g., + // internet). + optional bool open_world_hint = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Additional hints which may help tools and not covered in + // defaults. + map additional_hints = 6 + [(google.api.field_behavior) = OPTIONAL]; +} + // The HTTP Operation. message HttpOperation { // Enumeration of Method types. @@ -1337,6 +1527,13 @@ message ApiHubInstance { // Available configurations to provision an ApiHub Instance. message Config { + // The configuration for Agent Registry sync. + message AgentRegistrySyncConfig { + // Optional. If true, the MCP data sync to the Agent Registry will be + // disabled. The default value is false. + bool disabled = 1 [(google.api.field_behavior) = OPTIONAL]; + } + // Types of data encryption. enum EncryptionType { // Encryption type unspecified. @@ -1368,6 +1565,11 @@ message ApiHubInstance { // the cmek_key_name must be provided. If no encryption type is provided, // GMEK will be used. EncryptionType encryption_type = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The configuration for syncing MCP data in the API Hub instance + // to the Agent Registry. + AgentRegistrySyncConfig agent_registry_sync_config = 5 + [(google.api.field_behavior) = OPTIONAL]; } // State of the ApiHub Instance. @@ -1439,11 +1641,11 @@ message ExternalApi { // `projects/{project}/locations/{location}/externalApi/{externalApi}`. string name = 1 [(google.api.field_behavior) = IDENTIFIER]; - // Required. Display name of the external API. Max length is 63 characters + // Required. Display name of the external API. Max length is 500 characters // (Unicode Code Points). string display_name = 2 [(google.api.field_behavior) = REQUIRED]; - // Optional. Description of the external API. Max length is 2000 characters + // Optional. Description of the external API. Max length is 500000 characters // (Unicode Code Points). string description = 3 [(google.api.field_behavior) = OPTIONAL]; @@ -1796,10 +1998,10 @@ message DiscoveredApiObservation { // Source type not specified. SOURCE_TYPE_UNSPECIFIED = 0; - // GCP external load balancer. + // Google Cloud external load balancer. GCP_XLB = 1; - // GCP internal load balancer. + // Google Cloud internal load balancer. GCP_ILB = 2; } @@ -1835,8 +2037,8 @@ message DiscoveredApiObservation { // Optional. The number of observed API Operations. int64 api_operation_count = 7 [(google.api.field_behavior) = OPTIONAL]; - // Optional. For an observation pushed from a gcp resource, this would be the - // gcp project id. + // Optional. For an observation pushed from a Google Cloud resource, this + // would be the Google Cloud project id. string origin = 8 [(google.api.field_behavior) = OPTIONAL]; // Optional. The type of the source from which the observation was collected. diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/curate_service.proto b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/curate_service.proto index 8fbe6b0c75ea..b86df27786a2 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/curate_service.proto +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/curate_service.proto @@ -1,4 +1,4 @@ -// Copyright 2025 Google LLC +// Copyright 2026 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -37,6 +37,8 @@ option ruby_package = "Google::Cloud::ApiHub::V1"; service ApiHubCurate { option (google.api.default_host) = "apihub.googleapis.com"; option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/apihub.readonly," + "https://www.googleapis.com/auth/apihub.readwrite," "https://www.googleapis.com/auth/cloud-platform"; // Create a curation resource in the API hub. diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/discovery_service.proto b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/discovery_service.proto index 544d6122e34f..4ecc9dfaeea6 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/discovery_service.proto +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/discovery_service.proto @@ -1,4 +1,4 @@ -// Copyright 2025 Google LLC +// Copyright 2026 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -35,6 +35,8 @@ option ruby_package = "Google::Cloud::ApiHub::V1"; service ApiHubDiscovery { option (google.api.default_host) = "apihub.googleapis.com"; option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/apihub.readonly," + "https://www.googleapis.com/auth/apihub.readwrite," "https://www.googleapis.com/auth/cloud-platform"; // Lists all the DiscoveredAPIObservations in a given project and location. diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/host_project_registration_service.proto b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/host_project_registration_service.proto index f0d14bb3c145..8ac1ddc8259f 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/host_project_registration_service.proto +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/host_project_registration_service.proto @@ -1,4 +1,4 @@ -// Copyright 2025 Google LLC +// Copyright 2026 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -34,13 +34,16 @@ option ruby_package = "Google::Cloud::ApiHub::V1"; service HostProjectRegistrationService { option (google.api.default_host) = "apihub.googleapis.com"; option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/apihub.readonly," + "https://www.googleapis.com/auth/apihub.readwrite," "https://www.googleapis.com/auth/cloud-platform"; // Create a host project registration. // A Google cloud project can be registered as a host project if it is not // attached as a runtime project to another host project. - // A project can be registered as a host project only once. Subsequent - // register calls for the same project will fail. + // A project can have only one host project registration at a time. + // Subsequent register calls for the same project will fail until the + // existing registration is deleted. rpc CreateHostProjectRegistration(CreateHostProjectRegistrationRequest) returns (HostProjectRegistration) { option (google.api.http) = { diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/linting_service.proto b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/linting_service.proto index 19325427f204..e45340ac4926 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/linting_service.proto +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/linting_service.proto @@ -1,4 +1,4 @@ -// Copyright 2025 Google LLC +// Copyright 2026 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -36,6 +36,8 @@ option ruby_package = "Google::Cloud::ApiHub::V1"; service LintingService { option (google.api.default_host) = "apihub.googleapis.com"; option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/apihub.readonly," + "https://www.googleapis.com/auth/apihub.readwrite," "https://www.googleapis.com/auth/cloud-platform"; // Get the style guide being used for linting. diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/plugin_service.proto b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/plugin_service.proto index ed393bfec887..dfc3cd97958f 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/plugin_service.proto +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/plugin_service.proto @@ -1,4 +1,4 @@ -// Copyright 2025 Google LLC +// Copyright 2026 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -38,6 +38,8 @@ option ruby_package = "Google::Cloud::ApiHub::V1"; service ApiHubPlugin { option (google.api.default_host) = "apihub.googleapis.com"; option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/apihub.readonly," + "https://www.googleapis.com/auth/apihub.readwrite," "https://www.googleapis.com/auth/cloud-platform"; // Get an API Hub plugin. @@ -213,6 +215,17 @@ service ApiHubPlugin { metadata_type: "OperationMetadata" }; } + + // Manages data for a given plugin instance. + rpc ManagePluginInstanceSourceData(ManagePluginInstanceSourceDataRequest) + returns (ManagePluginInstanceSourceDataResponse) { + option (google.api.http) = { + post: "/v1/{name=projects/*/locations/*/plugins/*/instances/*}:manageSourceData" + body: "*" + }; + option (google.api.method_signature) = + "name,data_type,action,relative_path,data"; + } } // Enum for the action type. @@ -252,6 +265,12 @@ enum GatewayType { // The gateway type for any other types of gateways. OTHERS = 7; + + // The gateway type is AWS API Gateway. + AWS_API_GATEWAY = 8; + + // The gateway type is Azure API Management. + AZURE_API_MANAGEMENT = 9; } // Enum for the curation type. @@ -351,7 +370,7 @@ message Plugin { // Format: `projects/{project}/locations/{location}/plugins/{plugin}` string name = 1 [(google.api.field_behavior) = IDENTIFIER]; - // Required. The display name of the plugin. Max length is 50 characters + // Required. The display name of the plugin. Max length is 500 characters // (Unicode code points). string display_name = 2 [(google.api.field_behavior) = REQUIRED]; @@ -366,7 +385,7 @@ message Plugin { // Note this field is not required for plugins developed via plugin framework. AttributeValues type = 3 [(google.api.field_behavior) = OPTIONAL]; - // Optional. The plugin description. Max length is 2000 characters (Unicode + // Optional. The plugin description. Max length is 500000 characters (Unicode // code points). string description = 4 [(google.api.field_behavior) = OPTIONAL]; @@ -575,12 +594,12 @@ message PluginInstanceAction { string schedule_time_zone = 7 [(google.api.field_behavior) = OPTIONAL]; // Optional. The service account used to publish data. Note, the service - // account will only be accepted for non GCP plugins like OPDK. + // account will only be accepted for non-Google Cloud plugins like OPDK. string service_account = 8 [(google.api.field_behavior) = OPTIONAL]; // Output only. The configuration of resources created for a given plugin - // instance action. Note these will be returned only in case of Non-GCP - // plugins like OPDK. + // instance action. Note these will be returned only in case of non-Google + // Cloud plugins like OPDK. ResourceConfig resource_config = 9 [(google.api.field_behavior) = OUTPUT_ONLY]; } @@ -640,7 +659,7 @@ message PluginInstance { // `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}` string name = 1 [(google.api.field_behavior) = IDENTIFIER]; - // Required. The display name for this plugin instance. Max length is 255 + // Required. The display name for this plugin instance. Max length is 500 // characters. string display_name = 2 [(google.api.field_behavior) = REQUIRED]; @@ -679,10 +698,36 @@ message PluginInstance { [(google.api.field_behavior) = OUTPUT_ONLY]; // Optional. The source project id of the plugin instance. This will be the id - // of runtime project in case of gcp based plugins and org id in case of non - // gcp based plugins. This field will be a required field for Google provided - // on-ramp plugins. + // of runtime project in case of Google Cloud based plugins and org id in case + // of non-Google Cloud based plugins. This field will be a required field for + // Google provided on-ramp plugins. string source_project_id = 11 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The source environment's config present in the gateway instance + // linked to the plugin instance. The key is the `source_environment` name + // from the SourceEnvironment message. + map source_environments_config = 12 + [(google.api.field_behavior) = OPTIONAL]; +} + +// Message representing the source environment details. +message SourceEnvironment { + // Required. The name of the environment at the source. This should map to + // [Deployment][google.cloud.apihub.v1.SourceEnvironment.source_environment]. + string source_environment = 1 [(google.api.field_behavior) = REQUIRED]; + + // The location where additional information about source environments can be + // found. The location should be relative path of the environment manifest + // with respect to a plugin instance. + string source_environment_uri = 3; + + // Optional. The time at which the environment was created at the source. + google.protobuf.Timestamp create_time = 4 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The time at which the environment was last updated at the source. + google.protobuf.Timestamp update_time = 5 + [(google.api.field_behavior) = OPTIONAL]; } // The curation information for this plugin instance. @@ -735,6 +780,11 @@ message ExecutionStatus { // Output only. The last execution end time of the plugin instance. google.protobuf.Timestamp end_time = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The result metadata of the last execution of the plugin + // instance. This will be a string representation of a JSON object and will + // be available on successful execution. + string result_metadata = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; } // Enum for the current state of the execution. @@ -959,6 +1009,8 @@ message ListPluginInstancesRequest { // // * `state` - The state of the Plugin Instance. Allowed // comparison operators: `=`. + // * `source_project_id` - The source project id of the Plugin Instance. + // Allowed comparison operators: `=`. // // A filter function is also supported in the filter string. The filter // function is `id(name)`. The `id(name)` function returns the id of the @@ -1078,3 +1130,65 @@ message DeletePluginInstanceRequest { } ]; } + +// The +// [ManagePluginInstanceSourceData][google.cloud.apihub.v1.ApiHubPlugin.ManagePluginInstanceSourceData] +// method's request. +message ManagePluginInstanceSourceDataRequest { + // Type of data to be managed. + enum DataType { + // Default unspecified type. + DATA_TYPE_UNSPECIFIED = 0; + + // Proxy deployment manifest. + PROXY_DEPLOYMENT_MANIFEST = 1; + + // Environment manifest. + ENVIRONMENT_MANIFEST = 2; + + // Proxy bundle. + PROXY_BUNDLE = 3; + + // Shared flow bundle. + SHARED_FLOW_BUNDLE = 4; + } + + // Action to be performed. + enum Action { + // Default unspecified action. + ACTION_UNSPECIFIED = 0; + + // Upload or upsert data. + UPLOAD = 1; + + // Delete data. + DELETE = 2; + } + + // Required. The name of the plugin instance for which data needs to be + // managed. Format: + // `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "apihub.googleapis.com/PluginInstance" + } + ]; + + // Required. Type of data to be managed. + DataType data_type = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. Action to be performed. + Action action = 3 [(google.api.field_behavior) = REQUIRED]; + + // Required. Relative path of data being managed for a given plugin instance. + string relative_path = 4 [(google.api.field_behavior) = REQUIRED]; + + // Required. Data to be managed. + bytes data = 5 [(google.api.field_behavior) = REQUIRED]; +} + +// The +// [ManagePluginInstanceSourceData][google.cloud.apihub.v1.ApiHubPlugin.ManagePluginInstanceSourceData] +// method's response. +message ManagePluginInstanceSourceDataResponse {} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/provisioning_service.proto b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/provisioning_service.proto index 1f9b925a8c75..32044d1eec90 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/provisioning_service.proto +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/provisioning_service.proto @@ -1,4 +1,4 @@ -// Copyright 2025 Google LLC +// Copyright 2026 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -23,6 +23,7 @@ import "google/api/resource.proto"; import "google/cloud/apihub/v1/common_fields.proto"; import "google/longrunning/operations.proto"; import "google/protobuf/empty.proto"; +import "google/protobuf/field_mask.proto"; option csharp_namespace = "Google.Cloud.ApiHub.V1"; option go_package = "cloud.google.com/go/apihub/apiv1/apihubpb;apihubpb"; @@ -36,6 +37,8 @@ option ruby_package = "Google::Cloud::ApiHub::V1"; service Provisioning { option (google.api.default_host) = "apihub.googleapis.com"; option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/apihub.readonly," + "https://www.googleapis.com/auth/apihub.readwrite," "https://www.googleapis.com/auth/cloud-platform"; // Provisions instance resources for the API Hub. @@ -54,6 +57,8 @@ service Provisioning { } // Deletes the API hub instance. + // Deleting the API hub instance will also result in the removal of all + // associated runtime project attachments and the host project registration. rpc DeleteApiHubInstance(DeleteApiHubInstanceRequest) returns (google.longrunning.Operation) { option (google.api.http) = { @@ -74,8 +79,32 @@ service Provisioning { option (google.api.method_signature) = "name"; } - // Looks up an Api Hub instance in a given GCP project. There will always be - // only one Api Hub instance for a GCP project across all locations. + // Update an Api Hub instance. The following fields in the + // [ApiHubInstance][google.cloud.apihub.v1.ApiHubInstance] can be updated: + // + // * [disable_search][ApiHubInstance.config.disable_search] + // * [vertex_location][ApiHubInstance.config.vertex_location] + // * [agent_registry_sync_config][ApiHubInstance.config.agent_registry_sync_config] + // + // The + // [update_mask][google.cloud.apihub.v1.UpdateApiHubInstanceRequest.update_mask] + // should be used to specify the fields being updated. + rpc UpdateApiHubInstance(UpdateApiHubInstanceRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + patch: "/v1/{api_hub_instance.name=projects/*/locations/*/apiHubInstances/*}" + body: "api_hub_instance" + }; + option (google.api.method_signature) = "api_hub_instance,update_mask"; + option (google.longrunning.operation_info) = { + response_type: "ApiHubInstance" + metadata_type: "OperationMetadata" + }; + } + + // Looks up an Api Hub instance in a given Google Cloud project. There will + // always be only one Api Hub instance for a Google Cloud project across all + // locations. rpc LookupApiHubInstance(LookupApiHubInstanceRequest) returns (LookupApiHubInstanceResponse) { option (google.api.http) = { @@ -144,10 +173,9 @@ message GetApiHubInstanceRequest { // [LookupApiHubInstance][google.cloud.apihub.v1.Provisioning.LookupApiHubInstance] // method's request. message LookupApiHubInstanceRequest { - // Required. There will always be only one Api Hub instance for a GCP project - // across all locations. - // The parent resource for the Api Hub instance resource. - // Format: `projects/{project}/locations/{location}` + // Required. There will always be only one Api Hub instance for a Google Cloud + // project across all locations. The parent resource for the Api Hub instance + // resource. Format: `projects/{project}/locations/{location}` string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -163,3 +191,20 @@ message LookupApiHubInstanceResponse { // API Hub instance for a project if it exists, empty otherwise. ApiHubInstance api_hub_instance = 1; } + +// The +// [UpdateApiHubInstance][google.cloud.apihub.v1.Provisioning.UpdateApiHubInstance] +// method's request. +message UpdateApiHubInstanceRequest { + // Required. The ApiHub instance to update. + // + // The ApiHub instance's `name` field is used to identify the ApiHub instance + // to update. + // Format: + // `projects/{project}/locations/{location}/apiHubInstances/{apiHubInstance}`. + ApiHubInstance api_hub_instance = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The list of fields to update. + google.protobuf.FieldMask update_mask = 2 + [(google.api.field_behavior) = REQUIRED]; +} diff --git a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/runtime_project_attachment_service.proto b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/runtime_project_attachment_service.proto index 17f705bc3925..594894cd7037 100644 --- a/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/runtime_project_attachment_service.proto +++ b/java-apihub/proto-google-cloud-apihub-v1/src/main/proto/google/cloud/apihub/v1/runtime_project_attachment_service.proto @@ -1,4 +1,4 @@ -// Copyright 2025 Google LLC +// Copyright 2026 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -35,6 +35,8 @@ option ruby_package = "Google::Cloud::ApiHub::V1"; service RuntimeProjectAttachmentService { option (google.api.default_host) = "apihub.googleapis.com"; option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/apihub.readonly," + "https://www.googleapis.com/auth/apihub.readwrite," "https://www.googleapis.com/auth/cloud-platform"; // Attaches a runtime project to the host project. diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/AsyncConfigureAndDeployServer.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/AsyncConfigureAndDeployServer.java new file mode 100644 index 000000000000..471494ed09a9 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/AsyncConfigureAndDeployServer.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_ConfigureAndDeployServer_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest; +import com.google.cloud.apihub.v1.LocationName; +import com.google.longrunning.Operation; + +public class AsyncConfigureAndDeployServer { + + public static void main(String[] args) throws Exception { + asyncConfigureAndDeployServer(); + } + + public static void asyncConfigureAndDeployServer() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + ConfigureAndDeployServerRequest request = + ConfigureAndDeployServerRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .build(); + ApiFuture future = + apiHubClient.configureAndDeployServerCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END apihub_v1_generated_ApiHub_ConfigureAndDeployServer_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/AsyncConfigureAndDeployServerLRO.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/AsyncConfigureAndDeployServerLRO.java new file mode 100644 index 000000000000..7f1df9ec64dc --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/AsyncConfigureAndDeployServerLRO.java @@ -0,0 +1,51 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_ConfigureAndDeployServer_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse; +import com.google.cloud.apihub.v1.LocationName; +import com.google.cloud.apihub.v1.OperationMetadata; + +public class AsyncConfigureAndDeployServerLRO { + + public static void main(String[] args) throws Exception { + asyncConfigureAndDeployServerLRO(); + } + + public static void asyncConfigureAndDeployServerLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + ConfigureAndDeployServerRequest request = + ConfigureAndDeployServerRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .build(); + OperationFuture future = + apiHubClient.configureAndDeployServerOperationCallable().futureCall(request); + // Do something. + ConfigureAndDeployServerResponse response = future.get(); + } + } +} +// [END apihub_v1_generated_ApiHub_ConfigureAndDeployServer_LRO_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/SyncConfigureAndDeployServer.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/SyncConfigureAndDeployServer.java new file mode 100644 index 000000000000..ed1a64960676 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/SyncConfigureAndDeployServer.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_ConfigureAndDeployServer_sync] +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerRequest; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse; +import com.google.cloud.apihub.v1.LocationName; + +public class SyncConfigureAndDeployServer { + + public static void main(String[] args) throws Exception { + syncConfigureAndDeployServer(); + } + + public static void syncConfigureAndDeployServer() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + ConfigureAndDeployServerRequest request = + ConfigureAndDeployServerRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .build(); + ConfigureAndDeployServerResponse response = + apiHubClient.configureAndDeployServerAsync(request).get(); + } + } +} +// [END apihub_v1_generated_ApiHub_ConfigureAndDeployServer_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/SyncConfigureAndDeployServerLocationnameMcpserverconfig.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/SyncConfigureAndDeployServerLocationnameMcpserverconfig.java new file mode 100644 index 000000000000..a5ec6d7d5dcb --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/SyncConfigureAndDeployServerLocationnameMcpserverconfig.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_ConfigureAndDeployServer_LocationnameMcpserverconfig_sync] +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse; +import com.google.cloud.apihub.v1.LocationName; +import com.google.cloud.apihub.v1.McpServerConfig; + +public class SyncConfigureAndDeployServerLocationnameMcpserverconfig { + + public static void main(String[] args) throws Exception { + syncConfigureAndDeployServerLocationnameMcpserverconfig(); + } + + public static void syncConfigureAndDeployServerLocationnameMcpserverconfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + McpServerConfig mcpServerConfig = McpServerConfig.newBuilder().build(); + ConfigureAndDeployServerResponse response = + apiHubClient.configureAndDeployServerAsync(parent, mcpServerConfig).get(); + } + } +} +// [END apihub_v1_generated_ApiHub_ConfigureAndDeployServer_LocationnameMcpserverconfig_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/SyncConfigureAndDeployServerStringMcpserverconfig.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/SyncConfigureAndDeployServerStringMcpserverconfig.java new file mode 100644 index 000000000000..4ce333cff18f --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/configureanddeployserver/SyncConfigureAndDeployServerStringMcpserverconfig.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_ConfigureAndDeployServer_StringMcpserverconfig_sync] +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.ConfigureAndDeployServerResponse; +import com.google.cloud.apihub.v1.LocationName; +import com.google.cloud.apihub.v1.McpServerConfig; + +public class SyncConfigureAndDeployServerStringMcpserverconfig { + + public static void main(String[] args) throws Exception { + syncConfigureAndDeployServerStringMcpserverconfig(); + } + + public static void syncConfigureAndDeployServerStringMcpserverconfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + McpServerConfig mcpServerConfig = McpServerConfig.newBuilder().build(); + ConfigureAndDeployServerResponse response = + apiHubClient.configureAndDeployServerAsync(parent, mcpServerConfig).get(); + } + } +} +// [END apihub_v1_generated_ApiHub_ConfigureAndDeployServer_StringMcpserverconfig_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/AsyncFetchAdditionalSpecContent.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/AsyncFetchAdditionalSpecContent.java new file mode 100644 index 000000000000..c8bb2562df24 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/AsyncFetchAdditionalSpecContent.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_FetchAdditionalSpecContent_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse; +import com.google.cloud.apihub.v1.SpecContentType; +import com.google.cloud.apihub.v1.SpecName; + +public class AsyncFetchAdditionalSpecContent { + + public static void main(String[] args) throws Exception { + asyncFetchAdditionalSpecContent(); + } + + public static void asyncFetchAdditionalSpecContent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + FetchAdditionalSpecContentRequest request = + FetchAdditionalSpecContentRequest.newBuilder() + .setName( + SpecName.of("[PROJECT]", "[LOCATION]", "[API]", "[VERSION]", "[SPEC]").toString()) + .setSpecContentType(SpecContentType.forNumber(0)) + .build(); + ApiFuture future = + apiHubClient.fetchAdditionalSpecContentCallable().futureCall(request); + // Do something. + FetchAdditionalSpecContentResponse response = future.get(); + } + } +} +// [END apihub_v1_generated_ApiHub_FetchAdditionalSpecContent_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/SyncFetchAdditionalSpecContent.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/SyncFetchAdditionalSpecContent.java new file mode 100644 index 000000000000..741a0203e39f --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/SyncFetchAdditionalSpecContent.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_FetchAdditionalSpecContent_sync] +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentRequest; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse; +import com.google.cloud.apihub.v1.SpecContentType; +import com.google.cloud.apihub.v1.SpecName; + +public class SyncFetchAdditionalSpecContent { + + public static void main(String[] args) throws Exception { + syncFetchAdditionalSpecContent(); + } + + public static void syncFetchAdditionalSpecContent() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + FetchAdditionalSpecContentRequest request = + FetchAdditionalSpecContentRequest.newBuilder() + .setName( + SpecName.of("[PROJECT]", "[LOCATION]", "[API]", "[VERSION]", "[SPEC]").toString()) + .setSpecContentType(SpecContentType.forNumber(0)) + .build(); + FetchAdditionalSpecContentResponse response = + apiHubClient.fetchAdditionalSpecContent(request); + } + } +} +// [END apihub_v1_generated_ApiHub_FetchAdditionalSpecContent_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/SyncFetchAdditionalSpecContentSpecnameSpeccontenttype.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/SyncFetchAdditionalSpecContentSpecnameSpeccontenttype.java new file mode 100644 index 000000000000..faea2f919d41 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/SyncFetchAdditionalSpecContentSpecnameSpeccontenttype.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_FetchAdditionalSpecContent_SpecnameSpeccontenttype_sync] +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse; +import com.google.cloud.apihub.v1.SpecContentType; +import com.google.cloud.apihub.v1.SpecName; + +public class SyncFetchAdditionalSpecContentSpecnameSpeccontenttype { + + public static void main(String[] args) throws Exception { + syncFetchAdditionalSpecContentSpecnameSpeccontenttype(); + } + + public static void syncFetchAdditionalSpecContentSpecnameSpeccontenttype() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + SpecName name = SpecName.of("[PROJECT]", "[LOCATION]", "[API]", "[VERSION]", "[SPEC]"); + SpecContentType specContentType = SpecContentType.forNumber(0); + FetchAdditionalSpecContentResponse response = + apiHubClient.fetchAdditionalSpecContent(name, specContentType); + } + } +} +// [END apihub_v1_generated_ApiHub_FetchAdditionalSpecContent_SpecnameSpeccontenttype_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/SyncFetchAdditionalSpecContentStringSpeccontenttype.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/SyncFetchAdditionalSpecContentStringSpeccontenttype.java new file mode 100644 index 000000000000..00ebb046c741 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/fetchadditionalspeccontent/SyncFetchAdditionalSpecContentStringSpeccontenttype.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_FetchAdditionalSpecContent_StringSpeccontenttype_sync] +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.FetchAdditionalSpecContentResponse; +import com.google.cloud.apihub.v1.SpecContentType; +import com.google.cloud.apihub.v1.SpecName; + +public class SyncFetchAdditionalSpecContentStringSpeccontenttype { + + public static void main(String[] args) throws Exception { + syncFetchAdditionalSpecContentStringSpeccontenttype(); + } + + public static void syncFetchAdditionalSpecContentStringSpeccontenttype() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + String name = + SpecName.of("[PROJECT]", "[LOCATION]", "[API]", "[VERSION]", "[SPEC]").toString(); + SpecContentType specContentType = SpecContentType.forNumber(0); + FetchAdditionalSpecContentResponse response = + apiHubClient.fetchAdditionalSpecContent(name, specContentType); + } + } +} +// [END apihub_v1_generated_ApiHub_FetchAdditionalSpecContent_StringSpeccontenttype_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/AsyncRetrieveApiViews.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/AsyncRetrieveApiViews.java new file mode 100644 index 000000000000..e2af327d5f07 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/AsyncRetrieveApiViews.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_RetrieveApiViews_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.ApiView; +import com.google.cloud.apihub.v1.ApiViewType; +import com.google.cloud.apihub.v1.LocationName; +import com.google.cloud.apihub.v1.RetrieveApiViewsRequest; + +public class AsyncRetrieveApiViews { + + public static void main(String[] args) throws Exception { + asyncRetrieveApiViews(); + } + + public static void asyncRetrieveApiViews() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + RetrieveApiViewsRequest request = + RetrieveApiViewsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setView(ApiViewType.forNumber(0)) + .build(); + ApiFuture future = apiHubClient.retrieveApiViewsPagedCallable().futureCall(request); + // Do something. + for (ApiView element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END apihub_v1_generated_ApiHub_RetrieveApiViews_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/AsyncRetrieveApiViewsPaged.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/AsyncRetrieveApiViewsPaged.java new file mode 100644 index 000000000000..b94d790befb1 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/AsyncRetrieveApiViewsPaged.java @@ -0,0 +1,64 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_RetrieveApiViews_Paged_async] +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.ApiView; +import com.google.cloud.apihub.v1.ApiViewType; +import com.google.cloud.apihub.v1.LocationName; +import com.google.cloud.apihub.v1.RetrieveApiViewsRequest; +import com.google.cloud.apihub.v1.RetrieveApiViewsResponse; +import com.google.common.base.Strings; + +public class AsyncRetrieveApiViewsPaged { + + public static void main(String[] args) throws Exception { + asyncRetrieveApiViewsPaged(); + } + + public static void asyncRetrieveApiViewsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + RetrieveApiViewsRequest request = + RetrieveApiViewsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setView(ApiViewType.forNumber(0)) + .build(); + while (true) { + RetrieveApiViewsResponse response = apiHubClient.retrieveApiViewsCallable().call(request); + for (ApiView element : response.getApiViewsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END apihub_v1_generated_ApiHub_RetrieveApiViews_Paged_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/SyncRetrieveApiViews.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/SyncRetrieveApiViews.java new file mode 100644 index 000000000000..3629ab5d27e4 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/SyncRetrieveApiViews.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_RetrieveApiViews_sync] +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.ApiView; +import com.google.cloud.apihub.v1.ApiViewType; +import com.google.cloud.apihub.v1.LocationName; +import com.google.cloud.apihub.v1.RetrieveApiViewsRequest; + +public class SyncRetrieveApiViews { + + public static void main(String[] args) throws Exception { + syncRetrieveApiViews(); + } + + public static void syncRetrieveApiViews() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + RetrieveApiViewsRequest request = + RetrieveApiViewsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setView(ApiViewType.forNumber(0)) + .build(); + for (ApiView element : apiHubClient.retrieveApiViews(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END apihub_v1_generated_ApiHub_RetrieveApiViews_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/SyncRetrieveApiViewsLocationnameApiviewtype.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/SyncRetrieveApiViewsLocationnameApiviewtype.java new file mode 100644 index 000000000000..32bedf0bcbb9 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/SyncRetrieveApiViewsLocationnameApiviewtype.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_RetrieveApiViews_LocationnameApiviewtype_sync] +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.ApiView; +import com.google.cloud.apihub.v1.ApiViewType; +import com.google.cloud.apihub.v1.LocationName; + +public class SyncRetrieveApiViewsLocationnameApiviewtype { + + public static void main(String[] args) throws Exception { + syncRetrieveApiViewsLocationnameApiviewtype(); + } + + public static void syncRetrieveApiViewsLocationnameApiviewtype() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + ApiViewType view = ApiViewType.forNumber(0); + for (ApiView element : apiHubClient.retrieveApiViews(parent, view).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END apihub_v1_generated_ApiHub_RetrieveApiViews_LocationnameApiviewtype_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/SyncRetrieveApiViewsStringApiviewtype.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/SyncRetrieveApiViewsStringApiviewtype.java new file mode 100644 index 000000000000..d6c80d96d058 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihub/retrieveapiviews/SyncRetrieveApiViewsStringApiviewtype.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHub_RetrieveApiViews_StringApiviewtype_sync] +import com.google.cloud.apihub.v1.ApiHubClient; +import com.google.cloud.apihub.v1.ApiView; +import com.google.cloud.apihub.v1.ApiViewType; +import com.google.cloud.apihub.v1.LocationName; + +public class SyncRetrieveApiViewsStringApiviewtype { + + public static void main(String[] args) throws Exception { + syncRetrieveApiViewsStringApiviewtype(); + } + + public static void syncRetrieveApiViewsStringApiviewtype() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubClient apiHubClient = ApiHubClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + ApiViewType view = ApiViewType.forNumber(0); + for (ApiView element : apiHubClient.retrieveApiViews(parent, view).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END apihub_v1_generated_ApiHub_RetrieveApiViews_StringApiviewtype_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/create/SyncCreateSetCredentialsProvider.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/create/SyncCreateSetCredentialsProvider.java new file mode 100644 index 000000000000..ad8925043fea --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/create/SyncCreateSetCredentialsProvider.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_Create_SetCredentialsProvider_sync] +import com.google.api.gax.core.FixedCredentialsProvider; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.ApiHubAddonSettings; +import com.google.cloud.apihub.v1.myCredentials; + +public class SyncCreateSetCredentialsProvider { + + public static void main(String[] args) throws Exception { + syncCreateSetCredentialsProvider(); + } + + public static void syncCreateSetCredentialsProvider() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + ApiHubAddonSettings apiHubAddonSettings = + ApiHubAddonSettings.newBuilder() + .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials)) + .build(); + ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create(apiHubAddonSettings); + } +} +// [END apihub_v1_generated_ApiHubAddon_Create_SetCredentialsProvider_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/create/SyncCreateSetEndpoint.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/create/SyncCreateSetEndpoint.java new file mode 100644 index 000000000000..fbadf430fada --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/create/SyncCreateSetEndpoint.java @@ -0,0 +1,41 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_Create_SetEndpoint_sync] +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.ApiHubAddonSettings; +import com.google.cloud.apihub.v1.myEndpoint; + +public class SyncCreateSetEndpoint { + + public static void main(String[] args) throws Exception { + syncCreateSetEndpoint(); + } + + public static void syncCreateSetEndpoint() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + ApiHubAddonSettings apiHubAddonSettings = + ApiHubAddonSettings.newBuilder().setEndpoint(myEndpoint).build(); + ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create(apiHubAddonSettings); + } +} +// [END apihub_v1_generated_ApiHubAddon_Create_SetEndpoint_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/AsyncGetAddon.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/AsyncGetAddon.java new file mode 100644 index 000000000000..09281a49058c --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/AsyncGetAddon.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_GetAddon_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.AddonName; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.GetAddonRequest; + +public class AsyncGetAddon { + + public static void main(String[] args) throws Exception { + asyncGetAddon(); + } + + public static void asyncGetAddon() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + GetAddonRequest request = + GetAddonRequest.newBuilder() + .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString()) + .build(); + ApiFuture future = apiHubAddonClient.getAddonCallable().futureCall(request); + // Do something. + Addon response = future.get(); + } + } +} +// [END apihub_v1_generated_ApiHubAddon_GetAddon_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/SyncGetAddon.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/SyncGetAddon.java new file mode 100644 index 000000000000..b1c709859364 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/SyncGetAddon.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_GetAddon_sync] +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.AddonName; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.GetAddonRequest; + +public class SyncGetAddon { + + public static void main(String[] args) throws Exception { + syncGetAddon(); + } + + public static void syncGetAddon() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + GetAddonRequest request = + GetAddonRequest.newBuilder() + .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString()) + .build(); + Addon response = apiHubAddonClient.getAddon(request); + } + } +} +// [END apihub_v1_generated_ApiHubAddon_GetAddon_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/SyncGetAddonAddonname.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/SyncGetAddonAddonname.java new file mode 100644 index 000000000000..de4a47c54d24 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/SyncGetAddonAddonname.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_GetAddon_Addonname_sync] +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.AddonName; +import com.google.cloud.apihub.v1.ApiHubAddonClient; + +public class SyncGetAddonAddonname { + + public static void main(String[] args) throws Exception { + syncGetAddonAddonname(); + } + + public static void syncGetAddonAddonname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + AddonName name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]"); + Addon response = apiHubAddonClient.getAddon(name); + } + } +} +// [END apihub_v1_generated_ApiHubAddon_GetAddon_Addonname_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/SyncGetAddonString.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/SyncGetAddonString.java new file mode 100644 index 000000000000..fb3292bf5a81 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getaddon/SyncGetAddonString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_GetAddon_String_sync] +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.AddonName; +import com.google.cloud.apihub.v1.ApiHubAddonClient; + +public class SyncGetAddonString { + + public static void main(String[] args) throws Exception { + syncGetAddonString(); + } + + public static void syncGetAddonString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + String name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString(); + Addon response = apiHubAddonClient.getAddon(name); + } + } +} +// [END apihub_v1_generated_ApiHubAddon_GetAddon_String_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getlocation/AsyncGetLocation.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getlocation/AsyncGetLocation.java new file mode 100644 index 000000000000..1b0b13afa9f0 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getlocation/AsyncGetLocation.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_GetLocation_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.Location; + +public class AsyncGetLocation { + + public static void main(String[] args) throws Exception { + asyncGetLocation(); + } + + public static void asyncGetLocation() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + ApiFuture future = apiHubAddonClient.getLocationCallable().futureCall(request); + // Do something. + Location response = future.get(); + } + } +} +// [END apihub_v1_generated_ApiHubAddon_GetLocation_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getlocation/SyncGetLocation.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getlocation/SyncGetLocation.java new file mode 100644 index 000000000000..3b7171125947 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/getlocation/SyncGetLocation.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_GetLocation_sync] +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.Location; + +public class SyncGetLocation { + + public static void main(String[] args) throws Exception { + syncGetLocation(); + } + + public static void syncGetLocation() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + Location response = apiHubAddonClient.getLocation(request); + } + } +} +// [END apihub_v1_generated_ApiHubAddon_GetLocation_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/AsyncListAddons.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/AsyncListAddons.java new file mode 100644 index 000000000000..f279da8acd78 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/AsyncListAddons.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ListAddons_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.ListAddonsRequest; +import com.google.cloud.apihub.v1.LocationName; + +public class AsyncListAddons { + + public static void main(String[] args) throws Exception { + asyncListAddons(); + } + + public static void asyncListAddons() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + ListAddonsRequest request = + ListAddonsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = apiHubAddonClient.listAddonsPagedCallable().futureCall(request); + // Do something. + for (Addon element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ListAddons_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/AsyncListAddonsPaged.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/AsyncListAddonsPaged.java new file mode 100644 index 000000000000..4a3e998de86b --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/AsyncListAddonsPaged.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ListAddons_Paged_async] +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.ListAddonsRequest; +import com.google.cloud.apihub.v1.ListAddonsResponse; +import com.google.cloud.apihub.v1.LocationName; +import com.google.common.base.Strings; + +public class AsyncListAddonsPaged { + + public static void main(String[] args) throws Exception { + asyncListAddonsPaged(); + } + + public static void asyncListAddonsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + ListAddonsRequest request = + ListAddonsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListAddonsResponse response = apiHubAddonClient.listAddonsCallable().call(request); + for (Addon element : response.getAddonsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ListAddons_Paged_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/SyncListAddons.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/SyncListAddons.java new file mode 100644 index 000000000000..d9c4775f73dc --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/SyncListAddons.java @@ -0,0 +1,51 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ListAddons_sync] +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.ListAddonsRequest; +import com.google.cloud.apihub.v1.LocationName; + +public class SyncListAddons { + + public static void main(String[] args) throws Exception { + syncListAddons(); + } + + public static void syncListAddons() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + ListAddonsRequest request = + ListAddonsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (Addon element : apiHubAddonClient.listAddons(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ListAddons_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/SyncListAddonsLocationname.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/SyncListAddonsLocationname.java new file mode 100644 index 000000000000..87fa2b456f6a --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/SyncListAddonsLocationname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ListAddons_Locationname_sync] +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.LocationName; + +public class SyncListAddonsLocationname { + + public static void main(String[] args) throws Exception { + syncListAddonsLocationname(); + } + + public static void syncListAddonsLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (Addon element : apiHubAddonClient.listAddons(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ListAddons_Locationname_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/SyncListAddonsString.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/SyncListAddonsString.java new file mode 100644 index 000000000000..21133ea551ce --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listaddons/SyncListAddonsString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ListAddons_String_sync] +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.LocationName; + +public class SyncListAddonsString { + + public static void main(String[] args) throws Exception { + syncListAddonsString(); + } + + public static void syncListAddonsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (Addon element : apiHubAddonClient.listAddons(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ListAddons_String_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listlocations/AsyncListLocations.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listlocations/AsyncListLocations.java new file mode 100644 index 000000000000..a42f106cb4d5 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listlocations/AsyncListLocations.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ListLocations_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.Location; + +public class AsyncListLocations { + + public static void main(String[] args) throws Exception { + asyncListLocations(); + } + + public static void asyncListLocations() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + apiHubAddonClient.listLocationsPagedCallable().futureCall(request); + // Do something. + for (Location element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ListLocations_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listlocations/AsyncListLocationsPaged.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listlocations/AsyncListLocationsPaged.java new file mode 100644 index 000000000000..88e51727e28a --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listlocations/AsyncListLocationsPaged.java @@ -0,0 +1,61 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ListLocations_Paged_async] +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.base.Strings; + +public class AsyncListLocationsPaged { + + public static void main(String[] args) throws Exception { + asyncListLocationsPaged(); + } + + public static void asyncListLocationsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListLocationsResponse response = apiHubAddonClient.listLocationsCallable().call(request); + for (Location element : response.getLocationsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ListLocations_Paged_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listlocations/SyncListLocations.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listlocations/SyncListLocations.java new file mode 100644 index 000000000000..a047d219d86c --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/listlocations/SyncListLocations.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ListLocations_sync] +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.Location; + +public class SyncListLocations { + + public static void main(String[] args) throws Exception { + syncListLocations(); + } + + public static void syncListLocations() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (Location element : apiHubAddonClient.listLocations(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ListLocations_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/AsyncManageAddonConfig.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/AsyncManageAddonConfig.java new file mode 100644 index 000000000000..61c5b0ccbc18 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/AsyncManageAddonConfig.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ManageAddonConfig_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.apihub.v1.AddonConfig; +import com.google.cloud.apihub.v1.AddonName; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.ManageAddonConfigRequest; +import com.google.longrunning.Operation; + +public class AsyncManageAddonConfig { + + public static void main(String[] args) throws Exception { + asyncManageAddonConfig(); + } + + public static void asyncManageAddonConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + ManageAddonConfigRequest request = + ManageAddonConfigRequest.newBuilder() + .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString()) + .setConfig(AddonConfig.newBuilder().build()) + .build(); + ApiFuture future = + apiHubAddonClient.manageAddonConfigCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ManageAddonConfig_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/AsyncManageAddonConfigLRO.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/AsyncManageAddonConfigLRO.java new file mode 100644 index 000000000000..2f15de2ce07e --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/AsyncManageAddonConfigLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ManageAddonConfig_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.AddonConfig; +import com.google.cloud.apihub.v1.AddonName; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.ManageAddonConfigRequest; +import com.google.cloud.apihub.v1.OperationMetadata; + +public class AsyncManageAddonConfigLRO { + + public static void main(String[] args) throws Exception { + asyncManageAddonConfigLRO(); + } + + public static void asyncManageAddonConfigLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + ManageAddonConfigRequest request = + ManageAddonConfigRequest.newBuilder() + .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString()) + .setConfig(AddonConfig.newBuilder().build()) + .build(); + OperationFuture future = + apiHubAddonClient.manageAddonConfigOperationCallable().futureCall(request); + // Do something. + Addon response = future.get(); + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ManageAddonConfig_LRO_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/SyncManageAddonConfig.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/SyncManageAddonConfig.java new file mode 100644 index 000000000000..22926ea4d1d3 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/SyncManageAddonConfig.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ManageAddonConfig_sync] +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.AddonConfig; +import com.google.cloud.apihub.v1.AddonName; +import com.google.cloud.apihub.v1.ApiHubAddonClient; +import com.google.cloud.apihub.v1.ManageAddonConfigRequest; + +public class SyncManageAddonConfig { + + public static void main(String[] args) throws Exception { + syncManageAddonConfig(); + } + + public static void syncManageAddonConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + ManageAddonConfigRequest request = + ManageAddonConfigRequest.newBuilder() + .setName(AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString()) + .setConfig(AddonConfig.newBuilder().build()) + .build(); + Addon response = apiHubAddonClient.manageAddonConfigAsync(request).get(); + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ManageAddonConfig_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/SyncManageAddonConfigAddonnameAddonconfig.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/SyncManageAddonConfigAddonnameAddonconfig.java new file mode 100644 index 000000000000..479015142809 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/SyncManageAddonConfigAddonnameAddonconfig.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ManageAddonConfig_AddonnameAddonconfig_sync] +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.AddonConfig; +import com.google.cloud.apihub.v1.AddonName; +import com.google.cloud.apihub.v1.ApiHubAddonClient; + +public class SyncManageAddonConfigAddonnameAddonconfig { + + public static void main(String[] args) throws Exception { + syncManageAddonConfigAddonnameAddonconfig(); + } + + public static void syncManageAddonConfigAddonnameAddonconfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + AddonName name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]"); + AddonConfig config = AddonConfig.newBuilder().build(); + Addon response = apiHubAddonClient.manageAddonConfigAsync(name, config).get(); + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ManageAddonConfig_AddonnameAddonconfig_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/SyncManageAddonConfigStringAddonconfig.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/SyncManageAddonConfigStringAddonconfig.java new file mode 100644 index 000000000000..f5151190a677 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddon/manageaddonconfig/SyncManageAddonConfigStringAddonconfig.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddon_ManageAddonConfig_StringAddonconfig_sync] +import com.google.cloud.apihub.v1.Addon; +import com.google.cloud.apihub.v1.AddonConfig; +import com.google.cloud.apihub.v1.AddonName; +import com.google.cloud.apihub.v1.ApiHubAddonClient; + +public class SyncManageAddonConfigStringAddonconfig { + + public static void main(String[] args) throws Exception { + syncManageAddonConfigStringAddonconfig(); + } + + public static void syncManageAddonConfigStringAddonconfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubAddonClient apiHubAddonClient = ApiHubAddonClient.create()) { + String name = AddonName.of("[PROJECT]", "[LOCATION]", "[ADDON]").toString(); + AddonConfig config = AddonConfig.newBuilder().build(); + Addon response = apiHubAddonClient.manageAddonConfigAsync(name, config).get(); + } + } +} +// [END apihub_v1_generated_ApiHubAddon_ManageAddonConfig_StringAddonconfig_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddonsettings/getaddon/SyncGetAddon.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddonsettings/getaddon/SyncGetAddon.java new file mode 100644 index 000000000000..a047c8543732 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddonsettings/getaddon/SyncGetAddon.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddonSettings_GetAddon_sync] +import com.google.cloud.apihub.v1.ApiHubAddonSettings; +import java.time.Duration; + +public class SyncGetAddon { + + public static void main(String[] args) throws Exception { + syncGetAddon(); + } + + public static void syncGetAddon() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + ApiHubAddonSettings.Builder apiHubAddonSettingsBuilder = ApiHubAddonSettings.newBuilder(); + apiHubAddonSettingsBuilder + .getAddonSettings() + .setRetrySettings( + apiHubAddonSettingsBuilder + .getAddonSettings() + .getRetrySettings() + .toBuilder() + .setInitialRetryDelayDuration(Duration.ofSeconds(1)) + .setInitialRpcTimeoutDuration(Duration.ofSeconds(5)) + .setMaxAttempts(5) + .setMaxRetryDelayDuration(Duration.ofSeconds(30)) + .setMaxRpcTimeoutDuration(Duration.ofSeconds(60)) + .setRetryDelayMultiplier(1.3) + .setRpcTimeoutMultiplier(1.5) + .setTotalTimeoutDuration(Duration.ofSeconds(300)) + .build()); + ApiHubAddonSettings apiHubAddonSettings = apiHubAddonSettingsBuilder.build(); + } +} +// [END apihub_v1_generated_ApiHubAddonSettings_GetAddon_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddonsettings/manageaddonconfig/SyncManageAddonConfig.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddonsettings/manageaddonconfig/SyncManageAddonConfig.java new file mode 100644 index 000000000000..2f159a441c6e --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubaddonsettings/manageaddonconfig/SyncManageAddonConfig.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubAddonSettings_ManageAddonConfig_sync] +import com.google.api.gax.longrunning.OperationalTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.retrying.TimedRetryAlgorithm; +import com.google.cloud.apihub.v1.ApiHubAddonSettings; +import java.time.Duration; + +public class SyncManageAddonConfig { + + public static void main(String[] args) throws Exception { + syncManageAddonConfig(); + } + + public static void syncManageAddonConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + ApiHubAddonSettings.Builder apiHubAddonSettingsBuilder = ApiHubAddonSettings.newBuilder(); + TimedRetryAlgorithm timedRetryAlgorithm = + OperationalTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(500)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(5000)) + .setTotalTimeoutDuration(Duration.ofHours(24)) + .build()); + apiHubAddonSettingsBuilder + .createClusterOperationSettings() + .setPollingAlgorithm(timedRetryAlgorithm) + .build(); + } +} +// [END apihub_v1_generated_ApiHubAddonSettings_ManageAddonConfig_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/AsyncManagePluginInstanceSourceData.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/AsyncManagePluginInstanceSourceData.java new file mode 100644 index 000000000000..b875435ff883 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/AsyncManagePluginInstanceSourceData.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubPlugin_ManagePluginInstanceSourceData_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.apihub.v1.ApiHubPluginClient; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse; +import com.google.cloud.apihub.v1.PluginInstanceName; +import com.google.protobuf.ByteString; + +public class AsyncManagePluginInstanceSourceData { + + public static void main(String[] args) throws Exception { + asyncManagePluginInstanceSourceData(); + } + + public static void asyncManagePluginInstanceSourceData() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubPluginClient apiHubPluginClient = ApiHubPluginClient.create()) { + ManagePluginInstanceSourceDataRequest request = + ManagePluginInstanceSourceDataRequest.newBuilder() + .setName( + PluginInstanceName.of("[PROJECT]", "[LOCATION]", "[PLUGIN]", "[INSTANCE]") + .toString()) + .setRelativePath("relativePath-70808303") + .setData(ByteString.EMPTY) + .build(); + ApiFuture future = + apiHubPluginClient.managePluginInstanceSourceDataCallable().futureCall(request); + // Do something. + ManagePluginInstanceSourceDataResponse response = future.get(); + } + } +} +// [END apihub_v1_generated_ApiHubPlugin_ManagePluginInstanceSourceData_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/SyncManagePluginInstanceSourceData.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/SyncManagePluginInstanceSourceData.java new file mode 100644 index 000000000000..ae5acab163b2 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/SyncManagePluginInstanceSourceData.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubPlugin_ManagePluginInstanceSourceData_sync] +import com.google.cloud.apihub.v1.ApiHubPluginClient; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse; +import com.google.cloud.apihub.v1.PluginInstanceName; +import com.google.protobuf.ByteString; + +public class SyncManagePluginInstanceSourceData { + + public static void main(String[] args) throws Exception { + syncManagePluginInstanceSourceData(); + } + + public static void syncManagePluginInstanceSourceData() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubPluginClient apiHubPluginClient = ApiHubPluginClient.create()) { + ManagePluginInstanceSourceDataRequest request = + ManagePluginInstanceSourceDataRequest.newBuilder() + .setName( + PluginInstanceName.of("[PROJECT]", "[LOCATION]", "[PLUGIN]", "[INSTANCE]") + .toString()) + .setRelativePath("relativePath-70808303") + .setData(ByteString.EMPTY) + .build(); + ManagePluginInstanceSourceDataResponse response = + apiHubPluginClient.managePluginInstanceSourceData(request); + } + } +} +// [END apihub_v1_generated_ApiHubPlugin_ManagePluginInstanceSourceData_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/SyncManagePluginInstanceSourceDataPlugininstancenameManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/SyncManagePluginInstanceSourceDataPlugininstancenameManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring.java new file mode 100644 index 000000000000..779f7df8c2fa --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/SyncManagePluginInstanceSourceDataPlugininstancenameManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubPlugin_ManagePluginInstanceSourceData_PlugininstancenameManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring_sync] +import com.google.cloud.apihub.v1.ApiHubPluginClient; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse; +import com.google.cloud.apihub.v1.PluginInstanceName; +import com.google.protobuf.ByteString; + +public +class SyncManagePluginInstanceSourceDataPlugininstancenameManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring { + + public static void main(String[] args) throws Exception { + syncManagePluginInstanceSourceDataPlugininstancenameManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring(); + } + + public static void + syncManagePluginInstanceSourceDataPlugininstancenameManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubPluginClient apiHubPluginClient = ApiHubPluginClient.create()) { + PluginInstanceName name = + PluginInstanceName.of("[PROJECT]", "[LOCATION]", "[PLUGIN]", "[INSTANCE]"); + ManagePluginInstanceSourceDataRequest.DataType dataType = + ManagePluginInstanceSourceDataRequest.DataType.forNumber(0); + ManagePluginInstanceSourceDataRequest.Action action = + ManagePluginInstanceSourceDataRequest.Action.forNumber(0); + String relativePath = "relativePath-70808303"; + ByteString data = ByteString.EMPTY; + ManagePluginInstanceSourceDataResponse response = + apiHubPluginClient.managePluginInstanceSourceData( + name, dataType, action, relativePath, data); + } + } +} +// [END apihub_v1_generated_ApiHubPlugin_ManagePluginInstanceSourceData_PlugininstancenameManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/SyncManagePluginInstanceSourceDataStringManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/SyncManagePluginInstanceSourceDataStringManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring.java new file mode 100644 index 000000000000..08509d5a42db --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubplugin/manageplugininstancesourcedata/SyncManagePluginInstanceSourceDataStringManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubPlugin_ManagePluginInstanceSourceData_StringManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring_sync] +import com.google.cloud.apihub.v1.ApiHubPluginClient; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataRequest; +import com.google.cloud.apihub.v1.ManagePluginInstanceSourceDataResponse; +import com.google.cloud.apihub.v1.PluginInstanceName; +import com.google.protobuf.ByteString; + +public +class SyncManagePluginInstanceSourceDataStringManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring { + + public static void main(String[] args) throws Exception { + syncManagePluginInstanceSourceDataStringManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring(); + } + + public static void + syncManagePluginInstanceSourceDataStringManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ApiHubPluginClient apiHubPluginClient = ApiHubPluginClient.create()) { + String name = + PluginInstanceName.of("[PROJECT]", "[LOCATION]", "[PLUGIN]", "[INSTANCE]").toString(); + ManagePluginInstanceSourceDataRequest.DataType dataType = + ManagePluginInstanceSourceDataRequest.DataType.forNumber(0); + ManagePluginInstanceSourceDataRequest.Action action = + ManagePluginInstanceSourceDataRequest.Action.forNumber(0); + String relativePath = "relativePath-70808303"; + ByteString data = ByteString.EMPTY; + ManagePluginInstanceSourceDataResponse response = + apiHubPluginClient.managePluginInstanceSourceData( + name, dataType, action, relativePath, data); + } + } +} +// [END apihub_v1_generated_ApiHubPlugin_ManagePluginInstanceSourceData_StringManageplugininstancesourcedatarequestdatatypeManageplugininstancesourcedatarequestactionStringBytestring_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubsettings/configureanddeployserver/SyncConfigureAndDeployServer.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubsettings/configureanddeployserver/SyncConfigureAndDeployServer.java new file mode 100644 index 000000000000..bcf658419e1c --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/apihubsettings/configureanddeployserver/SyncConfigureAndDeployServer.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_ApiHubSettings_ConfigureAndDeployServer_sync] +import com.google.api.gax.longrunning.OperationalTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.retrying.TimedRetryAlgorithm; +import com.google.cloud.apihub.v1.ApiHubSettings; +import java.time.Duration; + +public class SyncConfigureAndDeployServer { + + public static void main(String[] args) throws Exception { + syncConfigureAndDeployServer(); + } + + public static void syncConfigureAndDeployServer() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + ApiHubSettings.Builder apiHubSettingsBuilder = ApiHubSettings.newBuilder(); + TimedRetryAlgorithm timedRetryAlgorithm = + OperationalTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(500)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(5000)) + .setTotalTimeoutDuration(Duration.ofHours(24)) + .build()); + apiHubSettingsBuilder + .createClusterOperationSettings() + .setPollingAlgorithm(timedRetryAlgorithm) + .build(); + } +} +// [END apihub_v1_generated_ApiHubSettings_ConfigureAndDeployServer_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/AsyncUpdateApiHubInstance.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/AsyncUpdateApiHubInstance.java new file mode 100644 index 000000000000..7ab913b11e56 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/AsyncUpdateApiHubInstance.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_Provisioning_UpdateApiHubInstance_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.apihub.v1.ApiHubInstance; +import com.google.cloud.apihub.v1.ProvisioningClient; +import com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest; +import com.google.longrunning.Operation; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateApiHubInstance { + + public static void main(String[] args) throws Exception { + asyncUpdateApiHubInstance(); + } + + public static void asyncUpdateApiHubInstance() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ProvisioningClient provisioningClient = ProvisioningClient.create()) { + UpdateApiHubInstanceRequest request = + UpdateApiHubInstanceRequest.newBuilder() + .setApiHubInstance(ApiHubInstance.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ApiFuture future = + provisioningClient.updateApiHubInstanceCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END apihub_v1_generated_Provisioning_UpdateApiHubInstance_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/AsyncUpdateApiHubInstanceLRO.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/AsyncUpdateApiHubInstanceLRO.java new file mode 100644 index 000000000000..0364d65bff94 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/AsyncUpdateApiHubInstanceLRO.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_Provisioning_UpdateApiHubInstance_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.apihub.v1.ApiHubInstance; +import com.google.cloud.apihub.v1.OperationMetadata; +import com.google.cloud.apihub.v1.ProvisioningClient; +import com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateApiHubInstanceLRO { + + public static void main(String[] args) throws Exception { + asyncUpdateApiHubInstanceLRO(); + } + + public static void asyncUpdateApiHubInstanceLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ProvisioningClient provisioningClient = ProvisioningClient.create()) { + UpdateApiHubInstanceRequest request = + UpdateApiHubInstanceRequest.newBuilder() + .setApiHubInstance(ApiHubInstance.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + OperationFuture future = + provisioningClient.updateApiHubInstanceOperationCallable().futureCall(request); + // Do something. + ApiHubInstance response = future.get(); + } + } +} +// [END apihub_v1_generated_Provisioning_UpdateApiHubInstance_LRO_async] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/SyncUpdateApiHubInstance.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/SyncUpdateApiHubInstance.java new file mode 100644 index 000000000000..c14cd5c34371 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/SyncUpdateApiHubInstance.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_Provisioning_UpdateApiHubInstance_sync] +import com.google.cloud.apihub.v1.ApiHubInstance; +import com.google.cloud.apihub.v1.ProvisioningClient; +import com.google.cloud.apihub.v1.UpdateApiHubInstanceRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateApiHubInstance { + + public static void main(String[] args) throws Exception { + syncUpdateApiHubInstance(); + } + + public static void syncUpdateApiHubInstance() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ProvisioningClient provisioningClient = ProvisioningClient.create()) { + UpdateApiHubInstanceRequest request = + UpdateApiHubInstanceRequest.newBuilder() + .setApiHubInstance(ApiHubInstance.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ApiHubInstance response = provisioningClient.updateApiHubInstanceAsync(request).get(); + } + } +} +// [END apihub_v1_generated_Provisioning_UpdateApiHubInstance_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/SyncUpdateApiHubInstanceApihubinstanceFieldmask.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/SyncUpdateApiHubInstanceApihubinstanceFieldmask.java new file mode 100644 index 000000000000..03c8d13c0985 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/provisioning/updateapihubinstance/SyncUpdateApiHubInstanceApihubinstanceFieldmask.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.samples; + +// [START apihub_v1_generated_Provisioning_UpdateApiHubInstance_ApihubinstanceFieldmask_sync] +import com.google.cloud.apihub.v1.ApiHubInstance; +import com.google.cloud.apihub.v1.ProvisioningClient; +import com.google.protobuf.FieldMask; + +public class SyncUpdateApiHubInstanceApihubinstanceFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateApiHubInstanceApihubinstanceFieldmask(); + } + + public static void syncUpdateApiHubInstanceApihubinstanceFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ProvisioningClient provisioningClient = ProvisioningClient.create()) { + ApiHubInstance apiHubInstance = ApiHubInstance.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + ApiHubInstance response = + provisioningClient.updateApiHubInstanceAsync(apiHubInstance, updateMask).get(); + } + } +} +// [END apihub_v1_generated_Provisioning_UpdateApiHubInstance_ApihubinstanceFieldmask_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/stub/apihubaddonstubsettings/getaddon/SyncGetAddon.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/stub/apihubaddonstubsettings/getaddon/SyncGetAddon.java new file mode 100644 index 000000000000..346800caad1f --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/stub/apihubaddonstubsettings/getaddon/SyncGetAddon.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.stub.samples; + +// [START apihub_v1_generated_ApiHubAddonStubSettings_GetAddon_sync] +import com.google.cloud.apihub.v1.stub.ApiHubAddonStubSettings; +import java.time.Duration; + +public class SyncGetAddon { + + public static void main(String[] args) throws Exception { + syncGetAddon(); + } + + public static void syncGetAddon() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + ApiHubAddonStubSettings.Builder apiHubAddonSettingsBuilder = + ApiHubAddonStubSettings.newBuilder(); + apiHubAddonSettingsBuilder + .getAddonSettings() + .setRetrySettings( + apiHubAddonSettingsBuilder + .getAddonSettings() + .getRetrySettings() + .toBuilder() + .setInitialRetryDelayDuration(Duration.ofSeconds(1)) + .setInitialRpcTimeoutDuration(Duration.ofSeconds(5)) + .setMaxAttempts(5) + .setMaxRetryDelayDuration(Duration.ofSeconds(30)) + .setMaxRpcTimeoutDuration(Duration.ofSeconds(60)) + .setRetryDelayMultiplier(1.3) + .setRpcTimeoutMultiplier(1.5) + .setTotalTimeoutDuration(Duration.ofSeconds(300)) + .build()); + ApiHubAddonStubSettings apiHubAddonSettings = apiHubAddonSettingsBuilder.build(); + } +} +// [END apihub_v1_generated_ApiHubAddonStubSettings_GetAddon_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/stub/apihubaddonstubsettings/manageaddonconfig/SyncManageAddonConfig.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/stub/apihubaddonstubsettings/manageaddonconfig/SyncManageAddonConfig.java new file mode 100644 index 000000000000..7e03ada1e307 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/stub/apihubaddonstubsettings/manageaddonconfig/SyncManageAddonConfig.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.stub.samples; + +// [START apihub_v1_generated_ApiHubAddonStubSettings_ManageAddonConfig_sync] +import com.google.api.gax.longrunning.OperationalTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.retrying.TimedRetryAlgorithm; +import com.google.cloud.apihub.v1.stub.ApiHubAddonStubSettings; +import java.time.Duration; + +public class SyncManageAddonConfig { + + public static void main(String[] args) throws Exception { + syncManageAddonConfig(); + } + + public static void syncManageAddonConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + ApiHubAddonStubSettings.Builder apiHubAddonSettingsBuilder = + ApiHubAddonStubSettings.newBuilder(); + TimedRetryAlgorithm timedRetryAlgorithm = + OperationalTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(500)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(5000)) + .setTotalTimeoutDuration(Duration.ofHours(24)) + .build()); + apiHubAddonSettingsBuilder + .createClusterOperationSettings() + .setPollingAlgorithm(timedRetryAlgorithm) + .build(); + } +} +// [END apihub_v1_generated_ApiHubAddonStubSettings_ManageAddonConfig_sync] diff --git a/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/stub/apihubstubsettings/configureanddeployserver/SyncConfigureAndDeployServer.java b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/stub/apihubstubsettings/configureanddeployserver/SyncConfigureAndDeployServer.java new file mode 100644 index 000000000000..bdb15eea3830 --- /dev/null +++ b/java-apihub/samples/snippets/generated/com/google/cloud/apihub/v1/stub/apihubstubsettings/configureanddeployserver/SyncConfigureAndDeployServer.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.apihub.v1.stub.samples; + +// [START apihub_v1_generated_ApiHubStubSettings_ConfigureAndDeployServer_sync] +import com.google.api.gax.longrunning.OperationalTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.retrying.TimedRetryAlgorithm; +import com.google.cloud.apihub.v1.stub.ApiHubStubSettings; +import java.time.Duration; + +public class SyncConfigureAndDeployServer { + + public static void main(String[] args) throws Exception { + syncConfigureAndDeployServer(); + } + + public static void syncConfigureAndDeployServer() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + ApiHubStubSettings.Builder apiHubSettingsBuilder = ApiHubStubSettings.newBuilder(); + TimedRetryAlgorithm timedRetryAlgorithm = + OperationalTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(500)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(5000)) + .setTotalTimeoutDuration(Duration.ofHours(24)) + .build()); + apiHubSettingsBuilder + .createClusterOperationSettings() + .setPollingAlgorithm(timedRetryAlgorithm) + .build(); + } +} +// [END apihub_v1_generated_ApiHubStubSettings_ConfigureAndDeployServer_sync] diff --git a/java-apikeys/README.md b/java-apikeys/README.md index 8fd7c8ed44d5..0d43689791f0 100644 --- a/java-apikeys/README.md +++ b/java-apikeys/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-apikeys - 0.100.0 + 0.101.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-apikeys' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-apikeys:0.100.0' +implementation 'com.google.cloud:google-cloud-apikeys:0.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-apikeys" % "0.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-apikeys" % "0.101.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-apikeys/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-apikeys.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-apikeys/0.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-apikeys/0.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-appengine-admin/README.md b/java-appengine-admin/README.md index 50d1be2aaa4c..d932bba9d1a5 100644 --- a/java-appengine-admin/README.md +++ b/java-appengine-admin/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-appengine-admin - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-appengine-admin' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-appengine-admin:2.102.0' +implementation 'com.google.cloud:google-cloud-appengine-admin:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-appengine-admin" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-appengine-admin" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-appengine-admin/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-appengine-admin.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-appengine-admin/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-appengine-admin/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-apphub/README.md b/java-apphub/README.md index 1e1f1dc59a9d..6b8572b2fea6 100644 --- a/java-apphub/README.md +++ b/java-apphub/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-apphub - 0.66.0 + 0.67.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-apphub' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-apphub:0.66.0' +implementation 'com.google.cloud:google-cloud-apphub:0.67.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-apphub" % "0.66.0" +libraryDependencies += "com.google.cloud" % "google-cloud-apphub" % "0.67.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-apphub/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-apphub.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-apphub/0.66.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-apphub/0.67.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-apphub/proto-google-cloud-apphub-v1/src/main/java/com/google/cloud/apphub/v1/ApplicationProto.java b/java-apphub/proto-google-cloud-apphub-v1/src/main/java/com/google/cloud/apphub/v1/ApplicationProto.java index eabfd3e78d98..5a23a438f561 100644 --- a/java-apphub/proto-google-cloud-apphub-v1/src/main/java/com/google/cloud/apphub/v1/ApplicationProto.java +++ b/java-apphub/proto-google-cloud-apphub-v1/src/main/java/com/google/cloud/apphub/v1/ApplicationProto.java @@ -108,24 +108,25 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004type\030\001 \001(\0162,.google.cloud.apphub.v1.ApplicationType.Type\"0\n" + "\004Type\022\024\n" + "\020TYPE_UNSPECIFIED\020\000\022\022\n" - + "\016AI_APPLICATION\020\001\"w\n" + + "\016AI_APPLICATION\020\001\"\213\001\n" + "\005Scope\0226\n" - + "\004type\030\001 \001(\0162\".google.cloud.apphub.v1.Scope.TypeB\004\342A\001\002\"6\n" + + "\004type\030\001 \001(\0162\".google.cloud.apphub.v1.Scope.TypeB\004\342A\001\002\"J\n" + "\004Type\022\024\n" + "\020TYPE_UNSPECIFIED\020\000\022\014\n" + "\010REGIONAL\020\001\022\n\n" - + "\006GLOBAL\020\002\"\340\001\n" + + "\006GLOBAL\020\002\022\022\n" + + "\016MULTI_REGIONAL\020\003\"\340\001\n" + "\025ApplicationProperties\022d\n" - + "\021extended_metadata\030\001 \003(\0132C.google.clo" - + "ud.apphub.v1.ApplicationProperties.ExtendedMetadataEntryB\004\342A\001\003\032a\n" + + "\021extended_metadata\030\001 \003(\0132C.google.cloud.apphub.v1.Applic" + + "ationProperties.ExtendedMetadataEntryB\004\342A\001\003\032a\n" + "\025ExtendedMetadataEntry\022\013\n" + "\003key\030\001 \001(\t\0227\n" - + "\005value\030\002 \001(\0132(.go" - + "ogle.cloud.apphub.v1.ExtendedMetadata:\0028\001B\262\001\n" - + "\032com.google.cloud.apphub.v1B\020ApplicationProtoP\001Z2cloud.google.com/go/apphub" - + "/apiv1/apphubpb;apphubpb\252\002\026Google.Cloud." - + "AppHub.V1\312\002\026Google\\Cloud\\AppHub\\V1\352\002\031Goo" - + "gle::Cloud::AppHub::V1b\006proto3" + + "\005value\030\002" + + " \001(\0132(.google.cloud.apphub.v1.ExtendedMetadata:\0028\001B\262\001\n" + + "\032com.google.cloud.apphub.v1B\020ApplicationProtoP\001Z2cloud" + + ".google.com/go/apphub/apiv1/apphubpb;app" + + "hubpb\252\002\026Google.Cloud.AppHub.V1\312\002\026Google\\" + + "Cloud\\AppHub\\V1\352\002\031Google::Cloud::AppHub::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/java-apphub/proto-google-cloud-apphub-v1/src/main/java/com/google/cloud/apphub/v1/Scope.java b/java-apphub/proto-google-cloud-apphub-v1/src/main/java/com/google/cloud/apphub/v1/Scope.java index f5be0234abf4..c44682b3a5b8 100644 --- a/java-apphub/proto-google-cloud-apphub-v1/src/main/java/com/google/cloud/apphub/v1/Scope.java +++ b/java-apphub/proto-google-cloud-apphub-v1/src/main/java/com/google/cloud/apphub/v1/Scope.java @@ -109,6 +109,16 @@ public enum Type implements com.google.protobuf.ProtocolMessageEnum { * GLOBAL = 2; */ GLOBAL(2), + /** + * + * + *
                      +     * Multi-regional type.
                      +     * 
                      + * + * MULTI_REGIONAL = 3; + */ + MULTI_REGIONAL(3), UNRECOGNIZED(-1), ; @@ -155,6 +165,17 @@ public enum Type implements com.google.protobuf.ProtocolMessageEnum { */ public static final int GLOBAL_VALUE = 2; + /** + * + * + *
                      +     * Multi-regional type.
                      +     * 
                      + * + * MULTI_REGIONAL = 3; + */ + public static final int MULTI_REGIONAL_VALUE = 3; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -185,6 +206,8 @@ public static Type forNumber(int value) { return REGIONAL; case 2: return GLOBAL; + case 3: + return MULTI_REGIONAL; default: return null; } diff --git a/java-apphub/proto-google-cloud-apphub-v1/src/main/proto/google/cloud/apphub/v1/application.proto b/java-apphub/proto-google-cloud-apphub-v1/src/main/proto/google/cloud/apphub/v1/application.proto index d10162478bf3..cd8d02cd260c 100644 --- a/java-apphub/proto-google-cloud-apphub-v1/src/main/proto/google/cloud/apphub/v1/application.proto +++ b/java-apphub/proto-google-cloud-apphub-v1/src/main/proto/google/cloud/apphub/v1/application.proto @@ -135,6 +135,9 @@ message Scope { // Global type. GLOBAL = 2; + + // Multi-regional type. + MULTI_REGIONAL = 3; } // Required. Scope Type. diff --git a/java-appoptimize/README.md b/java-appoptimize/README.md index 43e5fcaeff53..bf3b81695ddf 100644 --- a/java-appoptimize/README.md +++ b/java-appoptimize/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-appoptimize - 0.12.0 + 0.13.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-appoptimize' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-appoptimize:0.12.0' +implementation 'com.google.cloud:google-cloud-appoptimize:0.13.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-appoptimize" % "0.12.0" +libraryDependencies += "com.google.cloud" % "google-cloud-appoptimize" % "0.13.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-appoptimize/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-appoptimize.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-appoptimize/0.12.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-appoptimize/0.13.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-apptopology/README.md b/java-apptopology/README.md index f5ec8c0e57bf..74be95041a4f 100644 --- a/java-apptopology/README.md +++ b/java-apptopology/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-apptopology - 0.6.0 + 0.7.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-apptopology' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-apptopology:0.6.0' +implementation 'com.google.cloud:google-cloud-apptopology:0.7.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-apptopology" % "0.6.0" +libraryDependencies += "com.google.cloud" % "google-cloud-apptopology" % "0.7.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-apptopology/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-apptopology.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-apptopology/0.6.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-apptopology/0.7.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-artifact-registry/README.md b/java-artifact-registry/README.md index a953e921a68d..590d8b463f97 100644 --- a/java-artifact-registry/README.md +++ b/java-artifact-registry/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-artifact-registry - 1.101.0 + 1.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-artifact-registry' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-artifact-registry:1.101.0' +implementation 'com.google.cloud:google-cloud-artifact-registry:1.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-artifact-registry" % "1.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-artifact-registry" % "1.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-artifact-registry/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-artifact-registry.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-artifact-registry/1.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-artifact-registry/1.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-asset/README.md b/java-asset/README.md index da8fdce880f0..b4f5cfbb754f 100644 --- a/java-asset/README.md +++ b/java-asset/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-asset - 3.106.0 + 3.107.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-asset' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-asset:3.106.0' +implementation 'com.google.cloud:google-cloud-asset:3.107.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-asset" % "3.106.0" +libraryDependencies += "com.google.cloud" % "google-cloud-asset" % "3.107.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-asset/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-asset.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-asset/3.106.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-asset/3.107.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-assured-workloads/README.md b/java-assured-workloads/README.md index d9c1452692b5..23218d0dee69 100644 --- a/java-assured-workloads/README.md +++ b/java-assured-workloads/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-assured-workloads - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-assured-workloads' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-assured-workloads:2.102.0' +implementation 'com.google.cloud:google-cloud-assured-workloads:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-assured-workloads" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-assured-workloads" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-assured-workloads/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-assured-workloads.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-assured-workloads/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-assured-workloads/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-auditmanager/README.md b/java-auditmanager/README.md index bb5f219a7499..777dac78d239 100644 --- a/java-auditmanager/README.md +++ b/java-auditmanager/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-auditmanager - 0.20.0 + 0.21.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-auditmanager' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-auditmanager:0.20.0' +implementation 'com.google.cloud:google-cloud-auditmanager:0.21.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-auditmanager" % "0.20.0" +libraryDependencies += "com.google.cloud" % "google-cloud-auditmanager" % "0.21.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-auditmanager/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-auditmanager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-auditmanager/0.20.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-auditmanager/0.21.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-auditmanager/google-cloud-auditmanager/src/main/java/com/google/cloud/auditmanager/v1/AuditManagerClient.java b/java-auditmanager/google-cloud-auditmanager/src/main/java/com/google/cloud/auditmanager/v1/AuditManagerClient.java index dc59181c07e5..5c9836542f2b 100644 --- a/java-auditmanager/google-cloud-auditmanager/src/main/java/com/google/cloud/auditmanager/v1/AuditManagerClient.java +++ b/java-auditmanager/google-cloud-auditmanager/src/main/java/com/google/cloud/auditmanager/v1/AuditManagerClient.java @@ -79,7 +79,7 @@ * * *

                      CreateAuditSchedule - *

                      Creates a new audit schedule in a given project and location. + *

                      Creates a new audit schedule in a given location for an organization, folder, or project. * *

                      Request object method variants only take one parameter, a request object, which must be constructed before the call.

                      *
                        @@ -136,7 +136,7 @@ * * *

                        ListAuditSchedules - *

                        Lists audit schedules in a given project and location. + *

                        Lists audit schedules in a given location for an organization, folder, or project. * *

                        Request object method variants only take one parameter, a request object, which must be constructed before the call.

                        *
                          @@ -476,7 +476,7 @@ public final OperationsClient getHttpJsonOperationsClient() { // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new audit schedule in a given project and location. + * Creates a new audit schedule in a given location for an organization, folder, or project. * *

                          Sample code: * @@ -496,11 +496,12 @@ public final OperationsClient getHttpJsonOperationsClient() { * } * }

                      * - * @param parent Required. Project or folder that this audit schedule is for, in one of the - * following formats: + * @param parent Required. Project, folder, or organization that this audit schedule is for, in + * one of the following formats: *
                        *
                      • `projects/{project}/locations/{location}` *
                      • `folders/{folder}/locations/{location}` + *
                      • `organizations/{organization}/locations/{location}` *
                      * * @param auditSchedule Required. Audit schedule to create. @@ -523,7 +524,7 @@ public final AuditSchedule createAuditSchedule( // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new audit schedule in a given project and location. + * Creates a new audit schedule in a given location for an organization, folder, or project. * *

                      Sample code: * @@ -542,11 +543,12 @@ public final AuditSchedule createAuditSchedule( * } * }

                      * - * @param parent Required. Project or folder that this audit schedule is for, in one of the - * following formats: + * @param parent Required. Project, folder, or organization that this audit schedule is for, in + * one of the following formats: *
                        *
                      • `projects/{project}/locations/{location}` *
                      • `folders/{folder}/locations/{location}` + *
                      • `organizations/{organization}/locations/{location}` *
                      * * @param auditSchedule Required. Audit schedule to create. @@ -567,7 +569,7 @@ public final AuditSchedule createAuditSchedule( // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new audit schedule in a given project and location. + * Creates a new audit schedule in a given location for an organization, folder, or project. * *

                      Sample code: * @@ -586,11 +588,12 @@ public final AuditSchedule createAuditSchedule( * } * }

                      * - * @param parent Required. Project or folder that this audit schedule is for, in one of the - * following formats: + * @param parent Required. Project, folder, or organization that this audit schedule is for, in + * one of the following formats: *
                        *
                      • `projects/{project}/locations/{location}` *
                      • `folders/{folder}/locations/{location}` + *
                      • `organizations/{organization}/locations/{location}` *
                      * * @param auditSchedule Required. Audit schedule to create. @@ -611,7 +614,7 @@ public final AuditSchedule createAuditSchedule( // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new audit schedule in a given project and location. + * Creates a new audit schedule in a given location for an organization, folder, or project. * *

                      Sample code: * @@ -642,7 +645,7 @@ public final AuditSchedule createAuditSchedule(CreateAuditScheduleRequest reques // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a new audit schedule in a given project and location. + * Creates a new audit schedule in a given location for an organization, folder, or project. * *

                      Sample code: * @@ -900,7 +903,7 @@ public final UnaryCallable getAuditSched // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists audit schedules in a given project and location. + * Lists audit schedules in a given location for an organization, folder, or project. * *

                      Sample code: * @@ -939,7 +942,7 @@ public final ListAuditSchedulesPagedResponse listAuditSchedules( // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists audit schedules in a given project and location. + * Lists audit schedules in a given location for an organization, folder, or project. * *

                      Sample code: * @@ -976,7 +979,7 @@ public final ListAuditSchedulesPagedResponse listAuditSchedules(@Nullable Locati // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists audit schedules in a given project and location. + * Lists audit schedules in a given location for an organization, folder, or project. * *

                      Sample code: * @@ -1011,7 +1014,7 @@ public final ListAuditSchedulesPagedResponse listAuditSchedules(String parent) { // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists audit schedules in a given project and location. + * Lists audit schedules in a given location for an organization, folder, or project. * *

                      Sample code: * @@ -1044,7 +1047,7 @@ public final ListAuditSchedulesPagedResponse listAuditSchedules( // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists audit schedules in a given project and location. + * Lists audit schedules in a given location for an organization, folder, or project. * *

                      Sample code: * @@ -1077,7 +1080,7 @@ public final ListAuditSchedulesPagedResponse listAuditSchedules( // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists audit schedules in a given project and location. + * Lists audit schedules in a given location for an organization, folder, or project. * *

                      Sample code: * @@ -1441,6 +1444,7 @@ public final OperationFuture generateAuditReport * .setComplianceFramework("complianceFramework-1808314333") * .putAllParameterOverrides(new HashMap()) * .setValidateOnly(true) + * .addAllReportExportFormats(new ArrayList()) * .build(); * AuditReport response = auditManagerClient.generateAuditReportAsync(request).get(); * } @@ -1475,6 +1479,7 @@ public final OperationFuture generateAuditReport * .setComplianceFramework("complianceFramework-1808314333") * .putAllParameterOverrides(new HashMap()) * .setValidateOnly(true) + * .addAllReportExportFormats(new ArrayList()) * .build(); * OperationFuture future = * auditManagerClient.generateAuditReportOperationCallable().futureCall(request); @@ -1509,6 +1514,7 @@ public final OperationFuture generateAuditReport * .setComplianceFramework("complianceFramework-1808314333") * .putAllParameterOverrides(new HashMap()) * .setValidateOnly(true) + * .addAllReportExportFormats(new ArrayList()) * .build(); * ApiFuture future = * auditManagerClient.generateAuditReportCallable().futureCall(request); diff --git a/java-auditmanager/google-cloud-auditmanager/src/main/resources/META-INF/native-image/com.google.cloud.auditmanager.v1/reflect-config.json b/java-auditmanager/google-cloud-auditmanager/src/main/resources/META-INF/native-image/com.google.cloud.auditmanager.v1/reflect-config.json index a3608a4b9155..946140b9ad2d 100644 --- a/java-auditmanager/google-cloud-auditmanager/src/main/resources/META-INF/native-image/com.google.cloud.auditmanager.v1/reflect-config.json +++ b/java-auditmanager/google-cloud-auditmanager/src/main/resources/META-INF/native-image/com.google.cloud.auditmanager.v1/reflect-config.json @@ -1079,6 +1079,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.auditmanager.v1.ReportExportFormat", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.auditmanager.v1.ReportGenerationProgress", "queryAllDeclaredConstructors": true, diff --git a/java-auditmanager/google-cloud-auditmanager/src/test/java/com/google/cloud/auditmanager/v1/AuditManagerClientHttpJsonTest.java b/java-auditmanager/google-cloud-auditmanager/src/test/java/com/google/cloud/auditmanager/v1/AuditManagerClientHttpJsonTest.java index a686d8deef49..b0879761a06f 100644 --- a/java-auditmanager/google-cloud-auditmanager/src/test/java/com/google/cloud/auditmanager/v1/AuditManagerClientHttpJsonTest.java +++ b/java-auditmanager/google-cloud-auditmanager/src/test/java/com/google/cloud/auditmanager/v1/AuditManagerClientHttpJsonTest.java @@ -109,6 +109,7 @@ public void createAuditScheduleTest() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -174,6 +175,7 @@ public void createAuditScheduleTest2() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -237,6 +239,7 @@ public void createAuditScheduleTest3() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -300,6 +303,7 @@ public void updateAuditScheduleTest() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -320,6 +324,7 @@ public void updateAuditScheduleTest() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); @@ -366,6 +371,7 @@ public void updateAuditScheduleExceptionTest() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); client.updateAuditSchedule(auditSchedule, updateMask); @@ -394,6 +400,7 @@ public void getAuditScheduleTest() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -456,6 +463,7 @@ public void getAuditScheduleTest2() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -762,6 +770,7 @@ public void generateAuditReportTest() throws Exception { .setComplianceFramework("complianceFramework-1808314333") .setScopeId("scopeId1923941007") .putAllCloudControlParameterStates(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); Operation resultOperation = Operation.newBuilder() @@ -985,6 +994,7 @@ public void getAuditReportTest() throws Exception { .setComplianceFramework("complianceFramework-1808314333") .setScopeId("scopeId1923941007") .putAllCloudControlParameterStates(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockService.addResponse(expectedResponse); @@ -1045,6 +1055,7 @@ public void getAuditReportTest2() throws Exception { .setComplianceFramework("complianceFramework-1808314333") .setScopeId("scopeId1923941007") .putAllCloudControlParameterStates(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockService.addResponse(expectedResponse); diff --git a/java-auditmanager/google-cloud-auditmanager/src/test/java/com/google/cloud/auditmanager/v1/AuditManagerClientTest.java b/java-auditmanager/google-cloud-auditmanager/src/test/java/com/google/cloud/auditmanager/v1/AuditManagerClientTest.java index dc1b8b1eb63e..6d37ea38b601 100644 --- a/java-auditmanager/google-cloud-auditmanager/src/test/java/com/google/cloud/auditmanager/v1/AuditManagerClientTest.java +++ b/java-auditmanager/google-cloud-auditmanager/src/test/java/com/google/cloud/auditmanager/v1/AuditManagerClientTest.java @@ -116,6 +116,7 @@ public void createAuditScheduleTest() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockAuditManager.addResponse(expectedResponse); @@ -177,6 +178,7 @@ public void createAuditScheduleTest2() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockAuditManager.addResponse(expectedResponse); @@ -236,6 +238,7 @@ public void createAuditScheduleTest3() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockAuditManager.addResponse(expectedResponse); @@ -295,6 +298,7 @@ public void updateAuditScheduleTest() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockAuditManager.addResponse(expectedResponse); @@ -350,6 +354,7 @@ public void getAuditScheduleTest() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockAuditManager.addResponse(expectedResponse); @@ -406,6 +411,7 @@ public void getAuditScheduleTest2() throws Exception { .setLastTriggerTime(Timestamp.newBuilder().build()) .setErrorMessage("errorMessage1203236063") .putAllParameterOverrides(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockAuditManager.addResponse(expectedResponse); @@ -679,6 +685,7 @@ public void generateAuditReportTest() throws Exception { .setComplianceFramework("complianceFramework-1808314333") .setScopeId("scopeId1923941007") .putAllCloudControlParameterStates(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); Operation resultOperation = Operation.newBuilder() @@ -884,6 +891,7 @@ public void getAuditReportTest() throws Exception { .setComplianceFramework("complianceFramework-1808314333") .setScopeId("scopeId1923941007") .putAllCloudControlParameterStates(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockAuditManager.addResponse(expectedResponse); @@ -938,6 +946,7 @@ public void getAuditReportTest2() throws Exception { .setComplianceFramework("complianceFramework-1808314333") .setScopeId("scopeId1923941007") .putAllCloudControlParameterStates(new HashMap()) + .addAllReportExportFormats(new ArrayList()) .build(); mockAuditManager.addResponse(expectedResponse); diff --git a/java-auditmanager/grpc-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditManagerGrpc.java b/java-auditmanager/grpc-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditManagerGrpc.java index 4cbc5f81fb38..a6285d874d9d 100644 --- a/java-auditmanager/grpc-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditManagerGrpc.java +++ b/java-auditmanager/grpc-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditManagerGrpc.java @@ -676,7 +676,8 @@ public interface AsyncService { * * *

                      -     * Creates a new audit schedule in a given project and location.
                      +     * Creates a new audit schedule in a given location for an organization,
                      +     * folder, or project.
                            * 
                      */ default void createAuditSchedule( @@ -721,7 +722,8 @@ default void getAuditSchedule( * * *
                      -     * Lists audit schedules in a given project and location.
                      +     * Lists audit schedules in a given location for an organization, folder, or
                      +     * project.
                            * 
                      */ default void listAuditSchedules( @@ -904,7 +906,8 @@ protected AuditManagerStub build(io.grpc.Channel channel, io.grpc.CallOptions ca * * *
                      -     * Creates a new audit schedule in a given project and location.
                      +     * Creates a new audit schedule in a given location for an organization,
                      +     * folder, or project.
                            * 
                      */ public void createAuditSchedule( @@ -955,7 +958,8 @@ public void getAuditSchedule( * * *
                      -     * Lists audit schedules in a given project and location.
                      +     * Lists audit schedules in a given location for an organization, folder, or
                      +     * project.
                            * 
                      */ public void listAuditSchedules( @@ -1141,7 +1145,8 @@ protected AuditManagerBlockingV2Stub build( * * *
                      -     * Creates a new audit schedule in a given project and location.
                      +     * Creates a new audit schedule in a given location for an organization,
                      +     * folder, or project.
                            * 
                      */ public com.google.cloud.auditmanager.v1.AuditSchedule createAuditSchedule( @@ -1183,7 +1188,8 @@ public com.google.cloud.auditmanager.v1.AuditSchedule getAuditSchedule( * * *
                      -     * Lists audit schedules in a given project and location.
                      +     * Lists audit schedules in a given location for an organization, folder, or
                      +     * project.
                            * 
                      */ public com.google.cloud.auditmanager.v1.ListAuditSchedulesResponse listAuditSchedules( @@ -1344,7 +1350,8 @@ protected AuditManagerBlockingStub build( * * *
                      -     * Creates a new audit schedule in a given project and location.
                      +     * Creates a new audit schedule in a given location for an organization,
                      +     * folder, or project.
                            * 
                      */ public com.google.cloud.auditmanager.v1.AuditSchedule createAuditSchedule( @@ -1383,7 +1390,8 @@ public com.google.cloud.auditmanager.v1.AuditSchedule getAuditSchedule( * * *
                      -     * Lists audit schedules in a given project and location.
                      +     * Lists audit schedules in a given location for an organization, folder, or
                      +     * project.
                            * 
                      */ public com.google.cloud.auditmanager.v1.ListAuditSchedulesResponse listAuditSchedules( @@ -1535,7 +1543,8 @@ protected AuditManagerFutureStub build( * * *
                      -     * Creates a new audit schedule in a given project and location.
                      +     * Creates a new audit schedule in a given location for an organization,
                      +     * folder, or project.
                            * 
                      */ public com.google.common.util.concurrent.ListenableFuture< @@ -1577,7 +1586,8 @@ protected AuditManagerFutureStub build( * * *
                      -     * Lists audit schedules in a given project and location.
                      +     * Lists audit schedules in a given location for an organization, folder, or
                      +     * project.
                            * 
                      */ public com.google.common.util.concurrent.ListenableFuture< diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditReport.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditReport.java index 62a25dc38080..511d9f249284 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditReport.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditReport.java @@ -60,6 +60,7 @@ private AuditReport() { reportGenerationState_ = 0; complianceFramework_ = ""; scopeId_ = ""; + reportExportFormats_ = emptyIntList(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -153,6 +154,18 @@ public enum ReportGenerationState implements com.google.protobuf.ProtocolMessage * SUMMARY_UNKNOWN = 4; */ SUMMARY_UNKNOWN(4), + /** + * + * + *
                      +     * The process completed and the mandatory report was generated, but an
                      +     * optional additional report export (for example, PDF) failed. The
                      +     * operation state is `OPERATION_STATE_DONE`.
                      +     * 
                      + * + * DONE_WITH_ERRORS = 5; + */ + DONE_WITH_ERRORS(5), UNRECOGNIZED(-1), ; @@ -225,6 +238,19 @@ public enum ReportGenerationState implements com.google.protobuf.ProtocolMessage */ public static final int SUMMARY_UNKNOWN_VALUE = 4; + /** + * + * + *
                      +     * The process completed and the mandatory report was generated, but an
                      +     * optional additional report export (for example, PDF) failed. The
                      +     * operation state is `OPERATION_STATE_DONE`.
                      +     * 
                      + * + * DONE_WITH_ERRORS = 5; + */ + public static final int DONE_WITH_ERRORS_VALUE = 5; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -259,6 +285,8 @@ public static ReportGenerationState forNumber(int value) { return FAILED; case 4: return SUMMARY_UNKNOWN; + case 5: + return DONE_WITH_ERRORS; default: return null; } @@ -571,7 +599,7 @@ public com.google.cloud.auditmanager.v1.DestinationDetails getDestinationDetails * * * @deprecated google.cloud.auditmanager.v1.AuditReport.compliance_standard is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=892 + * google/cloud/auditmanager/v1/auditmanager.proto;l=913 * @return The complianceStandard. */ @java.lang.Override @@ -602,7 +630,7 @@ public java.lang.String getComplianceStandard() { * * * @deprecated google.cloud.auditmanager.v1.AuditReport.compliance_standard is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=892 + * google/cloud/auditmanager/v1/auditmanager.proto;l=913 * @return The bytes for complianceStandard. */ @java.lang.Override @@ -1113,6 +1141,127 @@ public boolean containsCloudControlParameterStates(java.lang.String key) { return map.get(key); } + public static final int REPORT_EXPORT_FORMATS_FIELD_NUMBER = 17; + + @SuppressWarnings("serial") + private com.google.protobuf.Internal.IntList reportExportFormats_ = emptyIntList(); + + private static final com.google.protobuf.Internal.IntListAdapter.IntConverter< + com.google.cloud.auditmanager.v1.ReportExportFormat> + reportExportFormats_converter_ = + new com.google.protobuf.Internal.IntListAdapter.IntConverter< + com.google.cloud.auditmanager.v1.ReportExportFormat>() { + public com.google.cloud.auditmanager.v1.ReportExportFormat convert(int from) { + com.google.cloud.auditmanager.v1.ReportExportFormat result = + com.google.cloud.auditmanager.v1.ReportExportFormat.forNumber(from); + return result == null + ? com.google.cloud.auditmanager.v1.ReportExportFormat.UNRECOGNIZED + : result; + } + }; + + /** + * + * + *
                      +   * Output only. Additional formats in which the audit report was requested to
                      +   * be exported.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the reportExportFormats. + */ + @java.lang.Override + public java.util.List + getReportExportFormatsList() { + return new com.google.protobuf.Internal.IntListAdapter< + com.google.cloud.auditmanager.v1.ReportExportFormat>( + reportExportFormats_, reportExportFormats_converter_); + } + + /** + * + * + *
                      +   * Output only. Additional formats in which the audit report was requested to
                      +   * be exported.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of reportExportFormats. + */ + @java.lang.Override + public int getReportExportFormatsCount() { + return reportExportFormats_.size(); + } + + /** + * + * + *
                      +   * Output only. Additional formats in which the audit report was requested to
                      +   * be exported.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The reportExportFormats at the given index. + */ + @java.lang.Override + public com.google.cloud.auditmanager.v1.ReportExportFormat getReportExportFormats(int index) { + return reportExportFormats_converter_.convert(reportExportFormats_.getInt(index)); + } + + /** + * + * + *
                      +   * Output only. Additional formats in which the audit report was requested to
                      +   * be exported.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the enum numeric values on the wire for reportExportFormats. + */ + @java.lang.Override + public java.util.List getReportExportFormatsValueList() { + return reportExportFormats_; + } + + /** + * + * + *
                      +   * Output only. Additional formats in which the audit report was requested to
                      +   * be exported.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of reportExportFormats at the given index. + */ + @java.lang.Override + public int getReportExportFormatsValue(int index) { + return reportExportFormats_.getInt(index); + } + + private int reportExportFormatsMemoizedSerializedSize; + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -1127,6 +1276,7 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + getSerializedSize(); if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); } @@ -1168,6 +1318,13 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io internalGetCloudControlParameterStates(), CloudControlParameterStatesDefaultEntryHolder.defaultEntry, 16); + if (getReportExportFormatsList().size() > 0) { + output.writeUInt32NoTag(138); + output.writeUInt32NoTag(reportExportFormatsMemoizedSerializedSize); + } + for (int i = 0; i < reportExportFormats_.size(); i++) { + output.writeEnumNoTag(reportExportFormats_.getInt(i)); + } getUnknownFields().writeTo(output); } @@ -1228,6 +1385,20 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 16, cloudControlParameterStates__); } + { + int dataSize = 0; + for (int i = 0; i < reportExportFormats_.size(); i++) { + dataSize += + com.google.protobuf.CodedOutputStream.computeEnumSizeNoTag( + reportExportFormats_.getInt(i)); + } + size += dataSize; + if (!getReportExportFormatsList().isEmpty()) { + size += 2; + size += com.google.protobuf.CodedOutputStream.computeUInt32SizeNoTag(dataSize); + } + reportExportFormatsMemoizedSerializedSize = dataSize; + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1266,6 +1437,7 @@ public boolean equals(final java.lang.Object obj) { if (!getScopeId().equals(other.getScopeId())) return false; if (!internalGetCloudControlParameterStates() .equals(other.internalGetCloudControlParameterStates())) return false; + if (!reportExportFormats_.equals(other.reportExportFormats_)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1311,6 +1483,10 @@ public int hashCode() { hash = (37 * hash) + CLOUD_CONTROL_PARAMETER_STATES_FIELD_NUMBER; hash = (53 * hash) + internalGetCloudControlParameterStates().hashCode(); } + if (getReportExportFormatsCount() > 0) { + hash = (37 * hash) + REPORT_EXPORT_FORMATS_FIELD_NUMBER; + hash = (53 * hash) + reportExportFormats_.hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1515,6 +1691,7 @@ public Builder clear() { complianceFramework_ = ""; scopeId_ = ""; internalGetMutableCloudControlParameterStates().clear(); + reportExportFormats_ = emptyIntList(); return this; } @@ -1607,6 +1784,10 @@ private void buildPartial0(com.google.cloud.auditmanager.v1.AuditReport result) internalGetCloudControlParameterStates() .build(CloudControlParameterStatesDefaultEntryHolder.defaultEntry); } + if (((from_bitField0_ & 0x00001000) != 0)) { + reportExportFormats_.makeImmutable(); + result.reportExportFormats_ = reportExportFormats_; + } result.bitField0_ |= to_bitField0_; } @@ -1694,6 +1875,17 @@ public Builder mergeFrom(com.google.cloud.auditmanager.v1.AuditReport other) { internalGetMutableCloudControlParameterStates() .mergeFrom(other.internalGetCloudControlParameterStates()); bitField0_ |= 0x00000800; + if (!other.reportExportFormats_.isEmpty()) { + if (reportExportFormats_.isEmpty()) { + reportExportFormats_ = other.reportExportFormats_; + reportExportFormats_.makeImmutable(); + bitField0_ |= 0x00001000; + } else { + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addAll(other.reportExportFormats_); + } + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1815,6 +2007,24 @@ public Builder mergeFrom( bitField0_ |= 0x00000800; break; } // case 130 + case 136: + { + int tmpRaw = input.readEnum(); + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addInt(tmpRaw); + break; + } // case 136 + case 138: + { + int length = input.readRawVarint32(); + int limit = input.pushLimit(length); + ensureReportExportFormatsIsMutable(); + while (input.getBytesUntilLimit() > 0) { + reportExportFormats_.addInt(input.readEnum()); + } + input.popLimit(limit); + break; + } // case 138 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -2533,7 +2743,7 @@ public Builder clearDestinationDetails() { * * * @deprecated google.cloud.auditmanager.v1.AuditReport.compliance_standard is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=892 + * google/cloud/auditmanager/v1/auditmanager.proto;l=913 * @return The complianceStandard. */ @java.lang.Deprecated @@ -2563,7 +2773,7 @@ public java.lang.String getComplianceStandard() { * * * @deprecated google.cloud.auditmanager.v1.AuditReport.compliance_standard is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=892 + * google/cloud/auditmanager/v1/auditmanager.proto;l=913 * @return The bytes for complianceStandard. */ @java.lang.Deprecated @@ -2593,7 +2803,7 @@ public com.google.protobuf.ByteString getComplianceStandardBytes() { * * * @deprecated google.cloud.auditmanager.v1.AuditReport.compliance_standard is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=892 + * google/cloud/auditmanager/v1/auditmanager.proto;l=913 * @param value The complianceStandard to set. * @return This builder for chaining. */ @@ -2622,7 +2832,7 @@ public Builder setComplianceStandard(java.lang.String value) { * * * @deprecated google.cloud.auditmanager.v1.AuditReport.compliance_standard is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=892 + * google/cloud/auditmanager/v1/auditmanager.proto;l=913 * @return This builder for chaining. */ @java.lang.Deprecated @@ -2647,7 +2857,7 @@ public Builder clearComplianceStandard() { * * * @deprecated google.cloud.auditmanager.v1.AuditReport.compliance_standard is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=892 + * google/cloud/auditmanager/v1/auditmanager.proto;l=913 * @param value The bytes for complianceStandard to set. * @return This builder for chaining. */ @@ -4055,6 +4265,279 @@ public Builder putAllCloudControlParameterStates( return (com.google.cloud.auditmanager.v1.CloudControlParameterStates.Builder) entry; } + private com.google.protobuf.Internal.IntList reportExportFormats_ = emptyIntList(); + + private void ensureReportExportFormatsIsMutable() { + if (!reportExportFormats_.isModifiable()) { + reportExportFormats_ = makeMutableCopy(reportExportFormats_); + } + bitField0_ |= 0x00001000; + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the reportExportFormats. + */ + public java.util.List + getReportExportFormatsList() { + return new com.google.protobuf.Internal.IntListAdapter< + com.google.cloud.auditmanager.v1.ReportExportFormat>( + reportExportFormats_, reportExportFormats_converter_); + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of reportExportFormats. + */ + public int getReportExportFormatsCount() { + return reportExportFormats_.size(); + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The reportExportFormats at the given index. + */ + public com.google.cloud.auditmanager.v1.ReportExportFormat getReportExportFormats(int index) { + return reportExportFormats_converter_.convert(reportExportFormats_.getInt(index)); + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index to set the value at. + * @param value The reportExportFormats to set. + * @return This builder for chaining. + */ + public Builder setReportExportFormats( + int index, com.google.cloud.auditmanager.v1.ReportExportFormat value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReportExportFormatsIsMutable(); + reportExportFormats_.setInt(index, value.getNumber()); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addReportExportFormats( + com.google.cloud.auditmanager.v1.ReportExportFormat value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addInt(value.getNumber()); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param values The reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addAllReportExportFormats( + java.lang.Iterable values) { + ensureReportExportFormatsIsMutable(); + for (com.google.cloud.auditmanager.v1.ReportExportFormat value : values) { + reportExportFormats_.addInt(value.getNumber()); + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearReportExportFormats() { + reportExportFormats_ = emptyIntList(); + bitField0_ = (bitField0_ & ~0x00001000); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the enum numeric values on the wire for reportExportFormats. + */ + public java.util.List getReportExportFormatsValueList() { + reportExportFormats_.makeImmutable(); + return reportExportFormats_; + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of reportExportFormats at the given index. + */ + public int getReportExportFormatsValue(int index) { + return reportExportFormats_.getInt(index); + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index to set the value at. + * @param value The enum numeric value on the wire for reportExportFormats to set. + * @return This builder for chaining. + */ + public Builder setReportExportFormatsValue(int index, int value) { + ensureReportExportFormatsIsMutable(); + reportExportFormats_.setInt(index, value); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addReportExportFormatsValue(int value) { + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addInt(value); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. Additional formats in which the audit report was requested to
                      +     * be exported.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param values The enum numeric values on the wire for reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addAllReportExportFormatsValue(java.lang.Iterable values) { + ensureReportExportFormatsIsMutable(); + for (int value : values) { + reportExportFormats_.addInt(value); + } + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.auditmanager.v1.AuditReport) } diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditReportOrBuilder.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditReportOrBuilder.java index 9f943a4d0399..979c5fa14bd4 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditReportOrBuilder.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditReportOrBuilder.java @@ -189,7 +189,7 @@ public interface AuditReportOrBuilder * * * @deprecated google.cloud.auditmanager.v1.AuditReport.compliance_standard is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=892 + * google/cloud/auditmanager/v1/auditmanager.proto;l=913 * @return The complianceStandard. */ @java.lang.Deprecated @@ -209,7 +209,7 @@ public interface AuditReportOrBuilder * * * @deprecated google.cloud.auditmanager.v1.AuditReport.compliance_standard is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=892 + * google/cloud/auditmanager/v1/auditmanager.proto;l=913 * @return The bytes for complianceStandard. */ @java.lang.Deprecated @@ -524,4 +524,86 @@ public interface AuditReportOrBuilder */ com.google.cloud.auditmanager.v1.CloudControlParameterStates getCloudControlParameterStatesOrThrow(java.lang.String key); + + /** + * + * + *
                      +   * Output only. Additional formats in which the audit report was requested to
                      +   * be exported.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the reportExportFormats. + */ + java.util.List getReportExportFormatsList(); + + /** + * + * + *
                      +   * Output only. Additional formats in which the audit report was requested to
                      +   * be exported.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of reportExportFormats. + */ + int getReportExportFormatsCount(); + + /** + * + * + *
                      +   * Output only. Additional formats in which the audit report was requested to
                      +   * be exported.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The reportExportFormats at the given index. + */ + com.google.cloud.auditmanager.v1.ReportExportFormat getReportExportFormats(int index); + + /** + * + * + *
                      +   * Output only. Additional formats in which the audit report was requested to
                      +   * be exported.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the enum numeric values on the wire for reportExportFormats. + */ + java.util.List getReportExportFormatsValueList(); + + /** + * + * + *
                      +   * Output only. Additional formats in which the audit report was requested to
                      +   * be exported.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of reportExportFormats at the given index. + */ + int getReportExportFormatsValue(int index); } diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditSchedule.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditSchedule.java index 0748238e6bba..a668f6681ed3 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditSchedule.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditSchedule.java @@ -28,6 +28,7 @@ * * * `projects/{project}/locations/{location}/auditSchedules/{audit_schedule}` * * `folders/{folder}/locations/{location}/auditSchedules/{audit_schedule}` + * * `organizations/{organization}/locations/{location}/auditSchedules/{audit_schedule}` *
                      * * Protobuf type {@code google.cloud.auditmanager.v1.AuditSchedule} @@ -62,6 +63,7 @@ private AuditSchedule() { reportFormat_ = 0; state_ = 0; errorMessage_ = ""; + reportExportFormats_ = emptyIntList(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -1030,6 +1032,127 @@ public com.google.cloud.auditmanager.v1.ParameterOverrides getParameterOverrides return map.get(key); } + public static final int REPORT_EXPORT_FORMATS_FIELD_NUMBER = 15; + + @SuppressWarnings("serial") + private com.google.protobuf.Internal.IntList reportExportFormats_ = emptyIntList(); + + private static final com.google.protobuf.Internal.IntListAdapter.IntConverter< + com.google.cloud.auditmanager.v1.ReportExportFormat> + reportExportFormats_converter_ = + new com.google.protobuf.Internal.IntListAdapter.IntConverter< + com.google.cloud.auditmanager.v1.ReportExportFormat>() { + public com.google.cloud.auditmanager.v1.ReportExportFormat convert(int from) { + com.google.cloud.auditmanager.v1.ReportExportFormat result = + com.google.cloud.auditmanager.v1.ReportExportFormat.forNumber(from); + return result == null + ? com.google.cloud.auditmanager.v1.ReportExportFormat.UNRECOGNIZED + : result; + } + }; + + /** + * + * + *
                      +   * Optional. Formats in which to export each scheduled audit report, in
                      +   * addition to the ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the reportExportFormats. + */ + @java.lang.Override + public java.util.List + getReportExportFormatsList() { + return new com.google.protobuf.Internal.IntListAdapter< + com.google.cloud.auditmanager.v1.ReportExportFormat>( + reportExportFormats_, reportExportFormats_converter_); + } + + /** + * + * + *
                      +   * Optional. Formats in which to export each scheduled audit report, in
                      +   * addition to the ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of reportExportFormats. + */ + @java.lang.Override + public int getReportExportFormatsCount() { + return reportExportFormats_.size(); + } + + /** + * + * + *
                      +   * Optional. Formats in which to export each scheduled audit report, in
                      +   * addition to the ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The reportExportFormats at the given index. + */ + @java.lang.Override + public com.google.cloud.auditmanager.v1.ReportExportFormat getReportExportFormats(int index) { + return reportExportFormats_converter_.convert(reportExportFormats_.getInt(index)); + } + + /** + * + * + *
                      +   * Optional. Formats in which to export each scheduled audit report, in
                      +   * addition to the ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the enum numeric values on the wire for reportExportFormats. + */ + @java.lang.Override + public java.util.List getReportExportFormatsValueList() { + return reportExportFormats_; + } + + /** + * + * + *
                      +   * Optional. Formats in which to export each scheduled audit report, in
                      +   * addition to the ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of reportExportFormats at the given index. + */ + @java.lang.Override + public int getReportExportFormatsValue(int index) { + return reportExportFormats_.getInt(index); + } + + private int reportExportFormatsMemoizedSerializedSize; + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -1044,6 +1167,7 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + getSerializedSize(); if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); } @@ -1089,6 +1213,13 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io internalGetParameterOverrides(), ParameterOverridesDefaultEntryHolder.defaultEntry, 14); + if (getReportExportFormatsList().size() > 0) { + output.writeUInt32NoTag(122); + output.writeUInt32NoTag(reportExportFormatsMemoizedSerializedSize); + } + for (int i = 0; i < reportExportFormats_.size(); i++) { + output.writeEnumNoTag(reportExportFormats_.getInt(i)); + } getUnknownFields().writeTo(output); } @@ -1150,6 +1281,20 @@ public int getSerializedSize() { .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(14, parameterOverrides__); } + { + int dataSize = 0; + for (int i = 0; i < reportExportFormats_.size(); i++) { + dataSize += + com.google.protobuf.CodedOutputStream.computeEnumSizeNoTag( + reportExportFormats_.getInt(i)); + } + size += dataSize; + if (!getReportExportFormatsList().isEmpty()) { + size += 1; + size += com.google.protobuf.CodedOutputStream.computeUInt32SizeNoTag(dataSize); + } + reportExportFormatsMemoizedSerializedSize = dataSize; + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1195,6 +1340,7 @@ public boolean equals(final java.lang.Object obj) { if (!getErrorMessage().equals(other.getErrorMessage())) return false; if (!internalGetParameterOverrides().equals(other.internalGetParameterOverrides())) return false; + if (!reportExportFormats_.equals(other.reportExportFormats_)) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1244,6 +1390,10 @@ public int hashCode() { hash = (37 * hash) + PARAMETER_OVERRIDES_FIELD_NUMBER; hash = (53 * hash) + internalGetParameterOverrides().hashCode(); } + if (getReportExportFormatsCount() > 0) { + hash = (37 * hash) + REPORT_EXPORT_FORMATS_FIELD_NUMBER; + hash = (53 * hash) + reportExportFormats_.hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1353,6 +1503,7 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.Builder * * * `projects/{project}/locations/{location}/auditSchedules/{audit_schedule}` * * `folders/{folder}/locations/{location}/auditSchedules/{audit_schedule}` + * * `organizations/{organization}/locations/{location}/auditSchedules/{audit_schedule}` *
                      * * Protobuf type {@code google.cloud.auditmanager.v1.AuditSchedule} @@ -1455,6 +1606,7 @@ public Builder clear() { } errorMessage_ = ""; internalGetMutableParameterOverrides().clear(); + reportExportFormats_ = emptyIntList(); return this; } @@ -1541,6 +1693,10 @@ private void buildPartial0(com.google.cloud.auditmanager.v1.AuditSchedule result internalGetParameterOverrides() .build(ParameterOverridesDefaultEntryHolder.defaultEntry); } + if (((from_bitField0_ & 0x00002000) != 0)) { + reportExportFormats_.makeImmutable(); + result.reportExportFormats_ = reportExportFormats_; + } result.bitField0_ |= to_bitField0_; } @@ -1604,6 +1760,17 @@ public Builder mergeFrom(com.google.cloud.auditmanager.v1.AuditSchedule other) { } internalGetMutableParameterOverrides().mergeFrom(other.internalGetParameterOverrides()); bitField0_ |= 0x00001000; + if (!other.reportExportFormats_.isEmpty()) { + if (reportExportFormats_.isEmpty()) { + reportExportFormats_ = other.reportExportFormats_; + reportExportFormats_.makeImmutable(); + bitField0_ |= 0x00002000; + } else { + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addAll(other.reportExportFormats_); + } + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1721,6 +1888,24 @@ public Builder mergeFrom( bitField0_ |= 0x00001000; break; } // case 114 + case 120: + { + int tmpRaw = input.readEnum(); + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addInt(tmpRaw); + break; + } // case 120 + case 122: + { + int length = input.readRawVarint32(); + int limit = input.pushLimit(length); + ensureReportExportFormatsIsMutable(); + while (input.getBytesUntilLimit() > 0) { + reportExportFormats_.addInt(input.readEnum()); + } + input.popLimit(limit); + break; + } // case 122 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -3916,6 +4101,279 @@ public Builder putAllParameterOverrides( return (com.google.cloud.auditmanager.v1.ParameterOverrides.Builder) entry; } + private com.google.protobuf.Internal.IntList reportExportFormats_ = emptyIntList(); + + private void ensureReportExportFormatsIsMutable() { + if (!reportExportFormats_.isModifiable()) { + reportExportFormats_ = makeMutableCopy(reportExportFormats_); + } + bitField0_ |= 0x00002000; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the reportExportFormats. + */ + public java.util.List + getReportExportFormatsList() { + return new com.google.protobuf.Internal.IntListAdapter< + com.google.cloud.auditmanager.v1.ReportExportFormat>( + reportExportFormats_, reportExportFormats_converter_); + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of reportExportFormats. + */ + public int getReportExportFormatsCount() { + return reportExportFormats_.size(); + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The reportExportFormats at the given index. + */ + public com.google.cloud.auditmanager.v1.ReportExportFormat getReportExportFormats(int index) { + return reportExportFormats_converter_.convert(reportExportFormats_.getInt(index)); + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The reportExportFormats to set. + * @return This builder for chaining. + */ + public Builder setReportExportFormats( + int index, com.google.cloud.auditmanager.v1.ReportExportFormat value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReportExportFormatsIsMutable(); + reportExportFormats_.setInt(index, value.getNumber()); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addReportExportFormats( + com.google.cloud.auditmanager.v1.ReportExportFormat value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addInt(value.getNumber()); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addAllReportExportFormats( + java.lang.Iterable values) { + ensureReportExportFormatsIsMutable(); + for (com.google.cloud.auditmanager.v1.ReportExportFormat value : values) { + reportExportFormats_.addInt(value.getNumber()); + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearReportExportFormats() { + reportExportFormats_ = emptyIntList(); + bitField0_ = (bitField0_ & ~0x00002000); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the enum numeric values on the wire for reportExportFormats. + */ + public java.util.List getReportExportFormatsValueList() { + reportExportFormats_.makeImmutable(); + return reportExportFormats_; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of reportExportFormats at the given index. + */ + public int getReportExportFormatsValue(int index) { + return reportExportFormats_.getInt(index); + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The enum numeric value on the wire for reportExportFormats to set. + * @return This builder for chaining. + */ + public Builder setReportExportFormatsValue(int index, int value) { + ensureReportExportFormatsIsMutable(); + reportExportFormats_.setInt(index, value); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addReportExportFormatsValue(int value) { + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addInt(value); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export each scheduled audit report, in
                      +     * addition to the ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The enum numeric values on the wire for reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addAllReportExportFormatsValue(java.lang.Iterable values) { + ensureReportExportFormatsIsMutable(); + for (int value : values) { + reportExportFormats_.addInt(value); + } + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.auditmanager.v1.AuditSchedule) } diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditScheduleOrBuilder.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditScheduleOrBuilder.java index bf1f10ed936d..54811cb91572 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditScheduleOrBuilder.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/AuditScheduleOrBuilder.java @@ -536,4 +536,86 @@ com.google.cloud.auditmanager.v1.ParameterOverrides getParameterOverridesOrDefau */ com.google.cloud.auditmanager.v1.ParameterOverrides getParameterOverridesOrThrow( java.lang.String key); + + /** + * + * + *
                      +   * Optional. Formats in which to export each scheduled audit report, in
                      +   * addition to the ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the reportExportFormats. + */ + java.util.List getReportExportFormatsList(); + + /** + * + * + *
                      +   * Optional. Formats in which to export each scheduled audit report, in
                      +   * addition to the ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of reportExportFormats. + */ + int getReportExportFormatsCount(); + + /** + * + * + *
                      +   * Optional. Formats in which to export each scheduled audit report, in
                      +   * addition to the ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The reportExportFormats at the given index. + */ + com.google.cloud.auditmanager.v1.ReportExportFormat getReportExportFormats(int index); + + /** + * + * + *
                      +   * Optional. Formats in which to export each scheduled audit report, in
                      +   * addition to the ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the enum numeric values on the wire for reportExportFormats. + */ + java.util.List getReportExportFormatsValueList(); + + /** + * + * + *
                      +   * Optional. Formats in which to export each scheduled audit report, in
                      +   * addition to the ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 15 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of reportExportFormats at the given index. + */ + int getReportExportFormatsValue(int index); } diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/CreateAuditScheduleRequest.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/CreateAuditScheduleRequest.java index aa31bb758dc1..0609a2e4f936 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/CreateAuditScheduleRequest.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/CreateAuditScheduleRequest.java @@ -82,11 +82,12 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
                      -   * Required. Project or folder that this audit schedule is for, in one of the
                      -   * following formats:
                      +   * Required. Project, folder, or organization that this audit schedule is for,
                      +   * in one of the following formats:
                          *
                          * * `projects/{project}/locations/{location}`
                          * * `folders/{folder}/locations/{location}`
                      +   * * `organizations/{organization}/locations/{location}`
                          * 
                      * * @@ -112,11 +113,12 @@ public java.lang.String getParent() { * * *
                      -   * Required. Project or folder that this audit schedule is for, in one of the
                      -   * following formats:
                      +   * Required. Project, folder, or organization that this audit schedule is for,
                      +   * in one of the following formats:
                          *
                          * * `projects/{project}/locations/{location}`
                          * * `folders/{folder}/locations/{location}`
                      +   * * `organizations/{organization}/locations/{location}`
                          * 
                      * * @@ -691,11 +693,12 @@ public Builder mergeFrom( * * *
                      -     * Required. Project or folder that this audit schedule is for, in one of the
                      -     * following formats:
                      +     * Required. Project, folder, or organization that this audit schedule is for,
                      +     * in one of the following formats:
                            *
                            * * `projects/{project}/locations/{location}`
                            * * `folders/{folder}/locations/{location}`
                      +     * * `organizations/{organization}/locations/{location}`
                            * 
                      * * @@ -720,11 +723,12 @@ public java.lang.String getParent() { * * *
                      -     * Required. Project or folder that this audit schedule is for, in one of the
                      -     * following formats:
                      +     * Required. Project, folder, or organization that this audit schedule is for,
                      +     * in one of the following formats:
                            *
                            * * `projects/{project}/locations/{location}`
                            * * `folders/{folder}/locations/{location}`
                      +     * * `organizations/{organization}/locations/{location}`
                            * 
                      * * @@ -749,11 +753,12 @@ public com.google.protobuf.ByteString getParentBytes() { * * *
                      -     * Required. Project or folder that this audit schedule is for, in one of the
                      -     * following formats:
                      +     * Required. Project, folder, or organization that this audit schedule is for,
                      +     * in one of the following formats:
                            *
                            * * `projects/{project}/locations/{location}`
                            * * `folders/{folder}/locations/{location}`
                      +     * * `organizations/{organization}/locations/{location}`
                            * 
                      * * @@ -777,11 +782,12 @@ public Builder setParent(java.lang.String value) { * * *
                      -     * Required. Project or folder that this audit schedule is for, in one of the
                      -     * following formats:
                      +     * Required. Project, folder, or organization that this audit schedule is for,
                      +     * in one of the following formats:
                            *
                            * * `projects/{project}/locations/{location}`
                            * * `folders/{folder}/locations/{location}`
                      +     * * `organizations/{organization}/locations/{location}`
                            * 
                      * * @@ -801,11 +807,12 @@ public Builder clearParent() { * * *
                      -     * Required. Project or folder that this audit schedule is for, in one of the
                      -     * following formats:
                      +     * Required. Project, folder, or organization that this audit schedule is for,
                      +     * in one of the following formats:
                            *
                            * * `projects/{project}/locations/{location}`
                            * * `folders/{folder}/locations/{location}`
                      +     * * `organizations/{organization}/locations/{location}`
                            * 
                      * * diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/CreateAuditScheduleRequestOrBuilder.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/CreateAuditScheduleRequestOrBuilder.java index 396fcfa4e510..ed197781a7c7 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/CreateAuditScheduleRequestOrBuilder.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/CreateAuditScheduleRequestOrBuilder.java @@ -30,11 +30,12 @@ public interface CreateAuditScheduleRequestOrBuilder * * *
                      -   * Required. Project or folder that this audit schedule is for, in one of the
                      -   * following formats:
                      +   * Required. Project, folder, or organization that this audit schedule is for,
                      +   * in one of the following formats:
                          *
                          * * `projects/{project}/locations/{location}`
                          * * `folders/{folder}/locations/{location}`
                      +   * * `organizations/{organization}/locations/{location}`
                          * 
                      * * @@ -49,11 +50,12 @@ public interface CreateAuditScheduleRequestOrBuilder * * *
                      -   * Required. Project or folder that this audit schedule is for, in one of the
                      -   * following formats:
                      +   * Required. Project, folder, or organization that this audit schedule is for,
                      +   * in one of the following formats:
                          *
                          * * `projects/{project}/locations/{location}`
                          * * `folders/{folder}/locations/{location}`
                      +   * * `organizations/{organization}/locations/{location}`
                          * 
                      * * diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditReportRequest.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditReportRequest.java index 8e67021d8b5b..23f1f43aa9bf 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditReportRequest.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditReportRequest.java @@ -57,6 +57,7 @@ private GenerateAuditReportRequest() { complianceStandard_ = ""; reportFormat_ = 0; complianceFramework_ = ""; + reportExportFormats_ = emptyIntList(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -445,7 +446,7 @@ public com.google.protobuf.ByteString getScopeBytes() { * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=486 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=497 * @return The complianceStandard. */ @java.lang.Override @@ -476,7 +477,7 @@ public java.lang.String getComplianceStandard() { *
                      * * @deprecated google.cloud.auditmanager.v1.GenerateAuditReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=486 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=497 * @return The bytes for complianceStandard. */ @java.lang.Override @@ -766,6 +767,127 @@ public boolean getValidateOnly() { return validateOnly_; } + public static final int REPORT_EXPORT_FORMATS_FIELD_NUMBER = 9; + + @SuppressWarnings("serial") + private com.google.protobuf.Internal.IntList reportExportFormats_ = emptyIntList(); + + private static final com.google.protobuf.Internal.IntListAdapter.IntConverter< + com.google.cloud.auditmanager.v1.ReportExportFormat> + reportExportFormats_converter_ = + new com.google.protobuf.Internal.IntListAdapter.IntConverter< + com.google.cloud.auditmanager.v1.ReportExportFormat>() { + public com.google.cloud.auditmanager.v1.ReportExportFormat convert(int from) { + com.google.cloud.auditmanager.v1.ReportExportFormat result = + com.google.cloud.auditmanager.v1.ReportExportFormat.forNumber(from); + return result == null + ? com.google.cloud.auditmanager.v1.ReportExportFormat.UNRECOGNIZED + : result; + } + }; + + /** + * + * + *
                      +   * Optional. Formats in which to export the audit report, in addition to the
                      +   * ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the reportExportFormats. + */ + @java.lang.Override + public java.util.List + getReportExportFormatsList() { + return new com.google.protobuf.Internal.IntListAdapter< + com.google.cloud.auditmanager.v1.ReportExportFormat>( + reportExportFormats_, reportExportFormats_converter_); + } + + /** + * + * + *
                      +   * Optional. Formats in which to export the audit report, in addition to the
                      +   * ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of reportExportFormats. + */ + @java.lang.Override + public int getReportExportFormatsCount() { + return reportExportFormats_.size(); + } + + /** + * + * + *
                      +   * Optional. Formats in which to export the audit report, in addition to the
                      +   * ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The reportExportFormats at the given index. + */ + @java.lang.Override + public com.google.cloud.auditmanager.v1.ReportExportFormat getReportExportFormats(int index) { + return reportExportFormats_converter_.convert(reportExportFormats_.getInt(index)); + } + + /** + * + * + *
                      +   * Optional. Formats in which to export the audit report, in addition to the
                      +   * ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the enum numeric values on the wire for reportExportFormats. + */ + @java.lang.Override + public java.util.List getReportExportFormatsValueList() { + return reportExportFormats_; + } + + /** + * + * + *
                      +   * Optional. Formats in which to export the audit report, in addition to the
                      +   * ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of reportExportFormats at the given index. + */ + @java.lang.Override + public int getReportExportFormatsValue(int index) { + return reportExportFormats_.getInt(index); + } + + private int reportExportFormatsMemoizedSerializedSize; + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -780,6 +902,7 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + getSerializedSize(); if (!com.google.protobuf.GeneratedMessage.isStringEmpty(scope_)) { com.google.protobuf.GeneratedMessage.writeString(output, 1, scope_); } @@ -806,6 +929,13 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (validateOnly_ != false) { output.writeBool(8, validateOnly_); } + if (getReportExportFormatsList().size() > 0) { + output.writeUInt32NoTag(74); + output.writeUInt32NoTag(reportExportFormatsMemoizedSerializedSize); + } + for (int i = 0; i < reportExportFormats_.size(); i++) { + output.writeEnumNoTag(reportExportFormats_.getInt(i)); + } getUnknownFields().writeTo(output); } @@ -848,6 +978,20 @@ public int getSerializedSize() { if (validateOnly_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, validateOnly_); } + { + int dataSize = 0; + for (int i = 0; i < reportExportFormats_.size(); i++) { + dataSize += + com.google.protobuf.CodedOutputStream.computeEnumSizeNoTag( + reportExportFormats_.getInt(i)); + } + size += dataSize; + if (!getReportExportFormatsList().isEmpty()) { + size += 1; + size += com.google.protobuf.CodedOutputStream.computeUInt32SizeNoTag(dataSize); + } + reportExportFormatsMemoizedSerializedSize = dataSize; + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -871,6 +1015,7 @@ public boolean equals(final java.lang.Object obj) { if (!internalGetParameterOverrides().equals(other.internalGetParameterOverrides())) return false; if (getValidateOnly() != other.getValidateOnly()) return false; + if (!reportExportFormats_.equals(other.reportExportFormats_)) return false; if (!getDestinationCase().equals(other.getDestinationCase())) return false; switch (destinationCase_) { case 2: @@ -904,6 +1049,10 @@ public int hashCode() { } hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); + if (getReportExportFormatsCount() > 0) { + hash = (37 * hash) + REPORT_EXPORT_FORMATS_FIELD_NUMBER; + hash = (53 * hash) + reportExportFormats_.hashCode(); + } switch (destinationCase_) { case 2: hash = (37 * hash) + GCS_URI_FIELD_NUMBER; @@ -1082,6 +1231,7 @@ public Builder clear() { complianceFramework_ = ""; internalGetMutableParameterOverrides().clear(); validateOnly_ = false; + reportExportFormats_ = emptyIntList(); destinationCase_ = 0; destination_ = null; return this; @@ -1141,6 +1291,10 @@ private void buildPartial0(com.google.cloud.auditmanager.v1.GenerateAuditReportR if (((from_bitField0_ & 0x00000040) != 0)) { result.validateOnly_ = validateOnly_; } + if (((from_bitField0_ & 0x00000080) != 0)) { + reportExportFormats_.makeImmutable(); + result.reportExportFormats_ = reportExportFormats_; + } } private void buildPartialOneofs( @@ -1185,6 +1339,17 @@ public Builder mergeFrom(com.google.cloud.auditmanager.v1.GenerateAuditReportReq if (other.getValidateOnly() != false) { setValidateOnly(other.getValidateOnly()); } + if (!other.reportExportFormats_.isEmpty()) { + if (reportExportFormats_.isEmpty()) { + reportExportFormats_ = other.reportExportFormats_; + reportExportFormats_.makeImmutable(); + bitField0_ |= 0x00000080; + } else { + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addAll(other.reportExportFormats_); + } + onChanged(); + } switch (other.getDestinationCase()) { case GCS_URI: { @@ -1275,6 +1440,24 @@ public Builder mergeFrom( bitField0_ |= 0x00000040; break; } // case 64 + case 72: + { + int tmpRaw = input.readEnum(); + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addInt(tmpRaw); + break; + } // case 72 + case 74: + { + int length = input.readRawVarint32(); + int limit = input.pushLimit(length); + ensureReportExportFormatsIsMutable(); + while (input.getBytesUntilLimit() > 0) { + reportExportFormats_.addInt(input.readEnum()); + } + input.popLimit(limit); + break; + } // case 74 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -1611,7 +1794,7 @@ public Builder setScopeBytes(com.google.protobuf.ByteString value) { *
                      * * @deprecated google.cloud.auditmanager.v1.GenerateAuditReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=486 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=497 * @return The complianceStandard. */ @java.lang.Deprecated @@ -1641,7 +1824,7 @@ public java.lang.String getComplianceStandard() { *
                      * * @deprecated google.cloud.auditmanager.v1.GenerateAuditReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=486 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=497 * @return The bytes for complianceStandard. */ @java.lang.Deprecated @@ -1671,7 +1854,7 @@ public com.google.protobuf.ByteString getComplianceStandardBytes() { *
                      * * @deprecated google.cloud.auditmanager.v1.GenerateAuditReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=486 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=497 * @param value The complianceStandard to set. * @return This builder for chaining. */ @@ -1700,7 +1883,7 @@ public Builder setComplianceStandard(java.lang.String value) { *
                      * * @deprecated google.cloud.auditmanager.v1.GenerateAuditReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=486 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=497 * @return This builder for chaining. */ @java.lang.Deprecated @@ -1725,7 +1908,7 @@ public Builder clearComplianceStandard() { *
                      * * @deprecated google.cloud.auditmanager.v1.GenerateAuditReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=486 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=497 * @param value The bytes for complianceStandard to set. * @return This builder for chaining. */ @@ -2352,6 +2535,279 @@ public Builder clearValidateOnly() { return this; } + private com.google.protobuf.Internal.IntList reportExportFormats_ = emptyIntList(); + + private void ensureReportExportFormatsIsMutable() { + if (!reportExportFormats_.isModifiable()) { + reportExportFormats_ = makeMutableCopy(reportExportFormats_); + } + bitField0_ |= 0x00000080; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the reportExportFormats. + */ + public java.util.List + getReportExportFormatsList() { + return new com.google.protobuf.Internal.IntListAdapter< + com.google.cloud.auditmanager.v1.ReportExportFormat>( + reportExportFormats_, reportExportFormats_converter_); + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of reportExportFormats. + */ + public int getReportExportFormatsCount() { + return reportExportFormats_.size(); + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The reportExportFormats at the given index. + */ + public com.google.cloud.auditmanager.v1.ReportExportFormat getReportExportFormats(int index) { + return reportExportFormats_converter_.convert(reportExportFormats_.getInt(index)); + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The reportExportFormats to set. + * @return This builder for chaining. + */ + public Builder setReportExportFormats( + int index, com.google.cloud.auditmanager.v1.ReportExportFormat value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReportExportFormatsIsMutable(); + reportExportFormats_.setInt(index, value.getNumber()); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addReportExportFormats( + com.google.cloud.auditmanager.v1.ReportExportFormat value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addInt(value.getNumber()); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addAllReportExportFormats( + java.lang.Iterable values) { + ensureReportExportFormatsIsMutable(); + for (com.google.cloud.auditmanager.v1.ReportExportFormat value : values) { + reportExportFormats_.addInt(value.getNumber()); + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearReportExportFormats() { + reportExportFormats_ = emptyIntList(); + bitField0_ = (bitField0_ & ~0x00000080); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the enum numeric values on the wire for reportExportFormats. + */ + public java.util.List getReportExportFormatsValueList() { + reportExportFormats_.makeImmutable(); + return reportExportFormats_; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of reportExportFormats at the given index. + */ + public int getReportExportFormatsValue(int index) { + return reportExportFormats_.getInt(index); + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The enum numeric value on the wire for reportExportFormats to set. + * @return This builder for chaining. + */ + public Builder setReportExportFormatsValue(int index, int value) { + ensureReportExportFormatsIsMutable(); + reportExportFormats_.setInt(index, value); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addReportExportFormatsValue(int value) { + ensureReportExportFormatsIsMutable(); + reportExportFormats_.addInt(value); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Formats in which to export the audit report, in addition to the
                      +     * ODF report. Each format can be listed only once.
                      +     * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The enum numeric values on the wire for reportExportFormats to add. + * @return This builder for chaining. + */ + public Builder addAllReportExportFormatsValue(java.lang.Iterable values) { + ensureReportExportFormatsIsMutable(); + for (int value : values) { + reportExportFormats_.addInt(value); + } + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.auditmanager.v1.GenerateAuditReportRequest) } diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditReportRequestOrBuilder.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditReportRequestOrBuilder.java index 5f0f1150294d..41ec06c509ef 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditReportRequestOrBuilder.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditReportRequestOrBuilder.java @@ -121,7 +121,7 @@ public interface GenerateAuditReportRequestOrBuilder * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=486 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=497 * @return The complianceStandard. */ @java.lang.Deprecated @@ -141,7 +141,7 @@ public interface GenerateAuditReportRequestOrBuilder * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=486 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=497 * @return The bytes for complianceStandard. */ @java.lang.Deprecated @@ -321,5 +321,87 @@ com.google.cloud.auditmanager.v1.ParameterOverrides getParameterOverridesOrThrow */ boolean getValidateOnly(); + /** + * + * + *
                      +   * Optional. Formats in which to export the audit report, in addition to the
                      +   * ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the reportExportFormats. + */ + java.util.List getReportExportFormatsList(); + + /** + * + * + *
                      +   * Optional. Formats in which to export the audit report, in addition to the
                      +   * ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of reportExportFormats. + */ + int getReportExportFormatsCount(); + + /** + * + * + *
                      +   * Optional. Formats in which to export the audit report, in addition to the
                      +   * ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The reportExportFormats at the given index. + */ + com.google.cloud.auditmanager.v1.ReportExportFormat getReportExportFormats(int index); + + /** + * + * + *
                      +   * Optional. Formats in which to export the audit report, in addition to the
                      +   * ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the enum numeric values on the wire for reportExportFormats. + */ + java.util.List getReportExportFormatsValueList(); + + /** + * + * + *
                      +   * Optional. Formats in which to export the audit report, in addition to the
                      +   * ODF report. Each format can be listed only once.
                      +   * 
                      + * + * + * repeated .google.cloud.auditmanager.v1.ReportExportFormat report_export_formats = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of reportExportFormats at the given index. + */ + int getReportExportFormatsValue(int index); + com.google.cloud.auditmanager.v1.GenerateAuditReportRequest.DestinationCase getDestinationCase(); } diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditScopeReportRequest.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditScopeReportRequest.java index 4ef212e04a93..52b65f4961d3 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditScopeReportRequest.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditScopeReportRequest.java @@ -321,7 +321,7 @@ public com.google.protobuf.ByteString getScopeBytes() { * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditScopeReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=421 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=432 * @return The complianceStandard. */ @java.lang.Override @@ -353,7 +353,7 @@ public java.lang.String getComplianceStandard() { * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditScopeReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=421 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=432 * @return The bytes for complianceStandard. */ @java.lang.Override @@ -1278,7 +1278,7 @@ public Builder setScopeBytes(com.google.protobuf.ByteString value) { * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditScopeReportRequest.compliance_standard - * is deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=421 + * is deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=432 * @return The complianceStandard. */ @java.lang.Deprecated @@ -1309,7 +1309,7 @@ public java.lang.String getComplianceStandard() { * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditScopeReportRequest.compliance_standard - * is deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=421 + * is deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=432 * @return The bytes for complianceStandard. */ @java.lang.Deprecated @@ -1340,7 +1340,7 @@ public com.google.protobuf.ByteString getComplianceStandardBytes() { * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditScopeReportRequest.compliance_standard - * is deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=421 + * is deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=432 * @param value The complianceStandard to set. * @return This builder for chaining. */ @@ -1370,7 +1370,7 @@ public Builder setComplianceStandard(java.lang.String value) { * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditScopeReportRequest.compliance_standard - * is deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=421 + * is deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=432 * @return This builder for chaining. */ @java.lang.Deprecated @@ -1396,7 +1396,7 @@ public Builder clearComplianceStandard() { * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditScopeReportRequest.compliance_standard - * is deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=421 + * is deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=432 * @param value The bytes for complianceStandard to set. * @return This builder for chaining. */ diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditScopeReportRequestOrBuilder.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditScopeReportRequestOrBuilder.java index 2c40acee8bb8..03f0e31a3fa1 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditScopeReportRequestOrBuilder.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/GenerateAuditScopeReportRequestOrBuilder.java @@ -77,7 +77,7 @@ public interface GenerateAuditScopeReportRequestOrBuilder * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditScopeReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=421 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=432 * @return The complianceStandard. */ @java.lang.Deprecated @@ -98,7 +98,7 @@ public interface GenerateAuditScopeReportRequestOrBuilder * * * @deprecated google.cloud.auditmanager.v1.GenerateAuditScopeReportRequest.compliance_standard is - * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=421 + * deprecated. See google/cloud/auditmanager/v1/auditmanager.proto;l=432 * @return The bytes for complianceStandard. */ @java.lang.Deprecated diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/ReportExportFormat.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/ReportExportFormat.java new file mode 100644 index 000000000000..d39fb6a15006 --- /dev/null +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/ReportExportFormat.java @@ -0,0 +1,170 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/auditmanager/v1/auditmanager.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.auditmanager.v1; + +/** + * + * + *
                      + * Additional formats in which the audit report can be exported.
                      + * 
                      + * + * Protobuf enum {@code google.cloud.auditmanager.v1.ReportExportFormat} + */ +@com.google.protobuf.Generated +public enum ReportExportFormat implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                      +   * Default value. This value is unused.
                      +   * 
                      + * + * REPORT_EXPORT_FORMAT_UNSPECIFIED = 0; + */ + REPORT_EXPORT_FORMAT_UNSPECIFIED(0), + /** + * + * + *
                      +   * Portable Document Format (PDF).
                      +   * 
                      + * + * REPORT_EXPORT_FORMAT_PDF = 1; + */ + REPORT_EXPORT_FORMAT_PDF(1), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ReportExportFormat"); + } + + /** + * + * + *
                      +   * Default value. This value is unused.
                      +   * 
                      + * + * REPORT_EXPORT_FORMAT_UNSPECIFIED = 0; + */ + public static final int REPORT_EXPORT_FORMAT_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                      +   * Portable Document Format (PDF).
                      +   * 
                      + * + * REPORT_EXPORT_FORMAT_PDF = 1; + */ + public static final int REPORT_EXPORT_FORMAT_PDF_VALUE = 1; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ReportExportFormat valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static ReportExportFormat forNumber(int value) { + switch (value) { + case 0: + return REPORT_EXPORT_FORMAT_UNSPECIFIED; + case 1: + return REPORT_EXPORT_FORMAT_PDF; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public ReportExportFormat findValueByNumber(int number) { + return ReportExportFormat.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.auditmanager.v1.V1mainProto.getDescriptor().getEnumTypes().get(3); + } + + private static final ReportExportFormat[] VALUES = values(); + + public static ReportExportFormat valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private ReportExportFormat(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.auditmanager.v1.ReportExportFormat) +} diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/ResourceEnrollmentStatus.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/ResourceEnrollmentStatus.java index 6c439bcb4da3..190d058a1727 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/ResourceEnrollmentStatus.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/ResourceEnrollmentStatus.java @@ -410,7 +410,7 @@ public com.google.cloud.auditmanager.v1.EnrollmentOrBuilder getEnrollmentOrBuild * bool enrolled = 3 [deprecated = true, (.google.api.field_behavior) = OUTPUT_ONLY]; * * @deprecated google.cloud.auditmanager.v1.ResourceEnrollmentStatus.enrolled is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=827 + * google/cloud/auditmanager/v1/auditmanager.proto;l=843 * @return The enrolled. */ @java.lang.Override @@ -1319,7 +1319,7 @@ public com.google.cloud.auditmanager.v1.EnrollmentOrBuilder getEnrollmentOrBuild * * * @deprecated google.cloud.auditmanager.v1.ResourceEnrollmentStatus.enrolled is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=827 + * google/cloud/auditmanager/v1/auditmanager.proto;l=843 * @return The enrolled. */ @java.lang.Override @@ -1340,7 +1340,7 @@ public boolean getEnrolled() { * * * @deprecated google.cloud.auditmanager.v1.ResourceEnrollmentStatus.enrolled is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=827 + * google/cloud/auditmanager/v1/auditmanager.proto;l=843 * @param value The enrolled to set. * @return This builder for chaining. */ @@ -1365,7 +1365,7 @@ public Builder setEnrolled(boolean value) { * * * @deprecated google.cloud.auditmanager.v1.ResourceEnrollmentStatus.enrolled is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=827 + * google/cloud/auditmanager/v1/auditmanager.proto;l=843 * @return This builder for chaining. */ @java.lang.Deprecated diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/ResourceEnrollmentStatusOrBuilder.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/ResourceEnrollmentStatusOrBuilder.java index 6bcb05d6fdc2..1cd7f43ca56e 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/ResourceEnrollmentStatusOrBuilder.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/ResourceEnrollmentStatusOrBuilder.java @@ -119,7 +119,7 @@ public interface ResourceEnrollmentStatusOrBuilder * bool enrolled = 3 [deprecated = true, (.google.api.field_behavior) = OUTPUT_ONLY]; * * @deprecated google.cloud.auditmanager.v1.ResourceEnrollmentStatus.enrolled is deprecated. See - * google/cloud/auditmanager/v1/auditmanager.proto;l=827 + * google/cloud/auditmanager/v1/auditmanager.proto;l=843 * @return The enrolled. */ @java.lang.Deprecated diff --git a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/V1mainProto.java b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/V1mainProto.java index ddcf8ca1d354..e27783a167f0 100644 --- a/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/V1mainProto.java +++ b/java-auditmanager/proto-google-cloud-auditmanager-v1/src/main/java/com/google/cloud/auditmanager/v1/V1mainProto.java @@ -216,7 +216,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\01320.google.cloud.auditmanager.v1.ParameterOverrides:\0028\001\"f\n" + "\026AuditScopeReportFormat\022)\n" + "%AUDIT_SCOPE_REPORT_FORMAT_UNSPECIFIED\020\000\022!\n" - + "\035AUDIT_SCOPE_REPORT_FORMAT_ODF\020\001\"\333\004\n" + + "\035AUDIT_SCOPE_REPORT_FORMAT_ODF\020\001\"\262\005\n" + "\032GenerateAuditReportRequest\022\021\n" + "\007gcs_uri\030\002 \001(\tH\000\022\023\n" + "\005scope\030\001 \001(\tB\004\342A\001\002\022#\n" @@ -226,11 +226,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\024compliance_framework\030\005 \001(\tB\004\342A\001\002\022s\n" + "\023parameter_overrides\030\007 \003(\0132P.google.cloud.auditmanager.v1." + "GenerateAuditReportRequest.ParameterOverridesEntryB\004\342A\001\001\022\033\n\r" - + "validate_only\030\010 \001(\010B\004\342A\001\001\032k\n" + + "validate_only\030\010 \001(\010B\004\342A\001\001\022U\n" + + "\025report_export_formats\030\t \003(\01620.g" + + "oogle.cloud.auditmanager.v1.ReportExportFormatB\004\342A\001\001\032k\n" + "\027ParameterOverridesEntry\022\013\n" + "\003key\030\001 \001(\t\022?\n" - + "\005value\030\002" - + " \001(\01320.google.cloud.auditmanager.v1.ParameterOverrides:\0028\001\"U\n" + + "\005value\030\002 \001(\01320.google.clo" + + "ud.auditmanager.v1.ParameterOverrides:\0028\001\"U\n" + "\021AuditReportFormat\022#\n" + "\037AUDIT_REPORT_FORMAT_UNSPECIFIED\020\000\022\033\n" + "\027AUDIT_REPORT_FORMAT_ODF\020\001B\r\n" @@ -244,17 +246,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"\245\001\n" + "&ListResourceEnrollmentStatusesResponse\022\\\n" - + "\034resource_enrollment_statuses\030\001" - + " \003(\01326.google.cloud.auditmanager.v1.ResourceEnrollmentStatus\022\035\n" + + "\034resource_enrollment_statuses\030\001 \003(\01326.google.cl" + + "oud.auditmanager.v1.ResourceEnrollmentStatus\022\035\n" + "\017next_page_token\030\002 \001(\tB\004\342A\001\003\"\216\001\n" + "\027ListAuditReportsRequest\022@\n" - + "\006parent\030\001 \001(\tB0\342A\001\002\372A" - + ")\022\'auditmanager.googleapis.com/AuditReport\022\027\n" + + "\006parent\030\001 \001(\tB" + + "0\342A\001\002\372A)\022\'auditmanager.googleapis.com/AuditReport\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"\201\001\n" + "\030ListAuditReportsResponse\022F\n\r" - + "audit_reports\030\001" - + " \003(\0132).google.cloud.auditmanager.v1.AuditReportB\004\342A\001\003\022\035\n" + + "audit_reports\030\001 \003(\0132).googl" + + "e.cloud.auditmanager.v1.AuditReportB\004\342A\001\003\022\035\n" + "\017next_page_token\030\002 \001(\tB\004\342A\001\003\"W\n" + "\025GetAuditReportRequest\022>\n" + "\004name\030\001 \001(\tB0\342A\001\002\372A)\n" @@ -280,21 +282,21 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\'auditmanager.googleapis.com/AuditReport\"\213\003\n\n" + "Enrollment\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022S\n" - + "\023destination_details\030\003 \003(\01320.goo" - + "gle.cloud.auditmanager.v1.DestinationDetailsB\004\342A\001\003:\223\002\352A\217\002\n" - + "&auditmanager.googleapis.com/Enrollment\022@projects/{project}/lo" - + "cations/{location}/enrollments/{enrollment}\022>folders/{folder}/locations/{locatio" - + "n}/enrollments/{enrollment}\022Jorganizatio" - + "ns/{organization}/locations/{location}/enrollments/{enrollment}*\013enrollments2\n" + + "\023destination_details\030\003 \003(" + + "\01320.google.cloud.auditmanager.v1.DestinationDetailsB\004\342A\001\003:\223\002\352A\217\002\n" + + "&auditmanager.googleapis.com/Enrollment\022@projects/{proj" + + "ect}/locations/{location}/enrollments/{enrollment}\022>folders/{folder}/locations/{" + + "location}/enrollments/{enrollment}\022Jorganizations/{organization}/locations/{loca" + + "tion}/enrollments/{enrollment}*\013enrollments2\n" + "enrollment\"\251\003\n" + "\020AuditScopeReport\022\037\n" + "\025scope_report_contents\030\001 \001(\014H\000\022\022\n" + "\004name\030\002 \001(\tB\004\342A\001\010:\317\002\352A\313\002\n" - + ",auditmanager.googleapis.com/AuditScopeReport\022Nprojects/{project}/loca" - + "tions/{location}/auditScopeReports/{audit_scope_report}\022Lfolders/{folder}/locati" - + "ons/{location}/auditScopeReports/{audit_scope_report}\022Xorganizations/{organizati" - + "on}/locations/{location}/auditScopeRepor" - + "ts/{audit_scope_report}*\021auditScopeReports2\020auditScopeReportB\016\n" + + ",auditmanager.googleapis.com/AuditScopeReport\022Nprojects/{projec" + + "t}/locations/{location}/auditScopeReports/{audit_scope_report}\022Lfolders/{folder}" + + "/locations/{location}/auditScopeReports/{audit_scope_report}\022Xorganizations/{org" + + "anization}/locations/{location}/auditSco" + + "peReports/{audit_scope_report}*\021auditScopeReports2\020auditScopeReportB\016\n" + "\014audit_report\"\207\002\n" + "\021OperationMetadata\0225\n" + "\013create_time\030\001" @@ -312,20 +314,19 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132(.google.cloud.auditmanager.v1.EnrollmentB\004\342A\001\003\022\030\n" + "\010enrolled\030\003 \001(\010B\006\030\001\342A\001\003\022\032\n" + "\014display_name\030\004 \001(\tB\004\342A\001\003\022n\n" - + "\020enrollment_state\030\005 \001(\0162N.google.cloud.audit" - + "manager.v1.ResourceEnrollmentStatus.ResourceEnrollmentStateB\004\342A\001\003\"s\n" + + "\020enrollment_state\030\005 \001(\0162N.google.clou" + + "d.auditmanager.v1.ResourceEnrollmentStatus.ResourceEnrollmentStateB\004\342A\001\003\"s\n" + "\027ResourceEnrollmentState\022)\n" + "%RESOURCE_ENROLLMENT_STATE_UNSPECIFIED\020\000\022\020\n" + "\014NOT_ENROLLED\020\001\022\r\n" + "\tINHERITED\020\002\022\014\n" + "\010ENROLLED\020\003:\233\003\352A\227\003\n" - + "4auditmanager.googleapis.com/ResourceEnrollmentSta" - + "tus\022]folders/{folder}/locations/{location}/resourceEnrollmentStatuses/{resource_" - + "enrollment_status}\022_projects/{project}/locations/{location}/resourceEnrollmentSt" - + "atuses/{resource_enrollment_status}\022iorganizations/{organization}/locations/{loc" - + "ation}/resourceEnrollmentStatuses/{resou" - + "rce_enrollment_status}*\032resourceEnrollmentStatuses2\030resourceEnrollmentStatus\"\336" - + "\t\n" + + "4auditmanager.googleapis.com/ResourceEnrollmentStatus\022]folders/{folder}/locations/{" + + "location}/resourceEnrollmentStatuses/{resource_enrollment_status}\022_projects/{pro" + + "ject}/locations/{location}/resourceEnrollmentStatuses/{resource_enrollment_statu" + + "s}\022iorganizations/{organization}/locations/{location}/resourceEnrollmentStatuses" + + "/{resource_enrollment_status}*\032resourceE" + + "nrollmentStatuses2\030resourceEnrollmentStatus\"\313\n\n" + "\013AuditReport\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022I\n" + "\016report_summary\030\002" @@ -337,29 +338,32 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005scope\030\006 \001(\tB\004\342A\001\003\0225\n" + "\013create_time\030\007" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022K\n" - + "\017control_details\030\010 \003(\0132," - + ".google.cloud.auditmanager.v1.ControlDetailsB\004\342A\001\003\022f\n" - + "\027report_generation_state\030\t " - + "\001(\0162?.google.cloud.auditmanager.v1.AuditReport.ReportGenerationStateB\004\342A\001\003\022\"\n" + + "\017control_details\030\010" + + " \003(\0132,.google.cloud.auditmanager.v1.ControlDetailsB\004\342A\001\003\022f\n" + + "\027report_generation_state\030\t \001(\0162?.google.cloud.auditmanager.v" + + "1.AuditReport.ReportGenerationStateB\004\342A\001\003\022\"\n" + "\024compliance_framework\030\n" + " \001(\tB\004\342A\001\003\022\026\n" + "\010scope_id\030\013 \001(\tB\004\342A\001\003\022x\n" - + "\036cloud_control_parameter_states\030\020 \003(\0132J.google.cloud.auditmanag" - + "er.v1.AuditReport.CloudControlParameterStatesEntryB\004\342A\001\003\032}\n" + + "\036cloud_control_parameter_states\030\020 \003(\0132J.google.cloud.aud" + + "itmanager.v1.AuditReport.CloudControlParameterStatesEntryB\004\342A\001\003\022U\n" + + "\025report_export_formats\030\021" + + " \003(\01620.google.cloud.auditmanager.v1.ReportExportFormatB\004\342A\001\003\032}\n" + " CloudControlParameterStatesEntry\022\013\n" + "\003key\030\001 \001(\t\022H\n" - + "\005value\030\002 \001(\013" - + "29.google.cloud.auditmanager.v1.CloudControlParameterStates:\0028\001\"\201\001\n" + + "\005value\030\002 \001(\01329.google.cloud.auditmanag" + + "er.v1.CloudControlParameterStates:\0028\001\"\227\001\n" + "\025ReportGenerationState\022\'\n" + "#REPORT_GENERATION_STATE_UNSPECIFIED\020\000\022\017\n" + "\013IN_PROGRESS\020\001\022\r\n" + "\tCOMPLETED\020\002\022\n\n" + "\006FAILED\020\003\022\023\n" - + "\017SUMMARY_UNKNOWN\020\004:\237\002\352A\233\002\n" - + "\'auditmanager.googleapis.com/AuditReport\022Cprojects/{project}/locations/{locat" - + "ion}/auditReports/{audit_report}\022Afolders/{folder}/locations/{location}/auditRep" - + "orts/{audit_report}\022Morganizations/{organization}/locations/{location}/auditRepo" - + "rts/{audit_report}*\014auditReports2\013auditReport\"8\n\r" + + "\017SUMMARY_UNKNOWN\020\004\022\024\n" + + "\020DONE_WITH_ERRORS\020\005:\237\002\352A\233\002\n" + + "\'auditmanager.googleapis.com/AuditReport\022Cprojects/{project}/locations/{location}" + + "/auditReports/{audit_report}\022Afolders/{folder}/locations/{location}/auditReports" + + "/{audit_report}\022Morganizations/{organization}/locations/{location}/auditReports/" + + "{audit_report}*\014auditReports2\013auditReport\"8\n\r" + "ControlFamily\022\021\n" + "\tfamily_id\030\001 \001(\t\022\024\n" + "\014display_name\030\002 \001(\t\"\205\005\n" @@ -414,15 +418,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\026control_report_summary\030\003" + " \001(\0132+.google.cloud.auditmanager.v1.ReportSummary\"\351\001\n" + "\032CreateAuditScheduleRequest\022B\n" - + "\006parent\030\001 \001(\tB2" - + "\342A\001\002\372A+\022)auditmanager.googleapis.com/AuditSchedule\022I\n" - + "\016audit_schedule\030\002 \001(\0132+.goo" - + "gle.cloud.auditmanager.v1.AuditScheduleB\004\342A\001\002\022\037\n" + + "\006parent\030\001 \001(\tB2\342A\001\002" + + "\372A+\022)auditmanager.googleapis.com/AuditSchedule\022I\n" + + "\016audit_schedule\030\002 \001(\0132+.google." + + "cloud.auditmanager.v1.AuditScheduleB\004\342A\001\002\022\037\n" + "\021audit_schedule_id\030\003 \001(\tB\004\342A\001\002\022\033\n\r" + "validate_only\030\004 \001(\010B\004\342A\001\001\"\273\001\n" + "\032UpdateAuditScheduleRequest\022I\n" - + "\016audit_schedule\030\001 \001" - + "(\0132+.google.cloud.auditmanager.v1.AuditScheduleB\004\342A\001\002\0225\n" + + "\016audit_schedule\030\001 \001(\0132+" + + ".google.cloud.auditmanager.v1.AuditScheduleB\004\342A\001\002\0225\n" + "\013update_mask\030\002" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022\033\n\r" + "validate_only\030\003 \001(\010B\004\342A\001\001\"[\n" @@ -430,26 +434,26 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004name\030\001 \001(\tB2\342A\001\002\372A+\n" + ")auditmanager.googleapis.com/AuditSchedule\"\222\001\n" + "\031ListAuditSchedulesRequest\022B\n" - + "\006parent\030\001 \001(\tB2\342A" - + "\001\002\372A+\022)auditmanager.googleapis.com/AuditSchedule\022\027\n" + + "\006parent\030\001 \001(\tB2\342A\001\002\372A" + + "+\022)auditmanager.googleapis.com/AuditSchedule\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"\220\001\n" + "\032ListAuditSchedulesResponse\022D\n" - + "\017audit_schedules\030\001 \003(\0132+.go" - + "ogle.cloud.auditmanager.v1.AuditSchedule\022\027\n" + + "\017audit_schedules\030\001" + + " \003(\0132+.google.cloud.auditmanager.v1.AuditSchedule\022\027\n" + "\017next_page_token\030\002 \001(\t\022\023\n" - + "\013unreachable\030\003 \003(\t\"\306\t\n\r" + + "\013unreachable\030\003 \003(\t\"\235\n\n\r" + "AuditSchedule\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\032\n" + "\014display_name\030\002 \001(\tB\004\342A\001\001\022\025\n" + "\007gcs_uri\030\003 \001(\tB\004\342A\001\002\022\"\n" + "\024compliance_framework\030\004 \001(\tB\004\342A\001\002\022Z\n\r" - + "report_format\030\005 \001(\0162=.goo" - + "gle.cloud.auditmanager.v1.AuditSchedule.AuditReportFormatB\004\342A\001\002\022K\n" + + "report_format\030\005 \001(\0162=.google." + + "cloud.auditmanager.v1.AuditSchedule.AuditReportFormatB\004\342A\001\002\022K\n" + "\017schedule_config\030\006" + " \001(\0132,.google.cloud.auditmanager.v1.ScheduleConfigB\004\342A\001\002\022@\n" - + "\005state\030\007 \001(\0162+.go" - + "ogle.cloud.auditmanager.v1.ScheduleStateB\004\342A\001\001\0225\n" + + "\005state\030\007 \001(\0162+.google" + + ".cloud.auditmanager.v1.ScheduleStateB\004\342A\001\001\0225\n" + "\013create_time\030\010" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\t" @@ -460,25 +464,27 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022\033\n\r" + "error_message\030\r" + " \001(\tB\004\342A\001\003\022f\n" - + "\023parameter_overrides\030\016 \003(\0132C.google.cloud.auditmanager" - + ".v1.AuditSchedule.ParameterOverridesEntryB\004\342A\001\001\032k\n" + + "\023parameter_overrides\030\016 \003(\0132C.google.cloud.auditmanager.v1." + + "AuditSchedule.ParameterOverridesEntryB\004\342A\001\001\022U\n" + + "\025report_export_formats\030\017 \003(\01620.goo" + + "gle.cloud.auditmanager.v1.ReportExportFormatB\004\342A\001\001\032k\n" + "\027ParameterOverridesEntry\022\013\n" + "\003key\030\001 \001(\t\022?\n" - + "\005value\030\002" - + " \001(\01320.google.cloud.auditmanager.v1.ParameterOverrides:\0028\001\"U\n" + + "\005value\030\002 \001(\01320.google.cloud" + + ".auditmanager.v1.ParameterOverrides:\0028\001\"U\n" + "\021AuditReportFormat\022#\n" + "\037AUDIT_REPORT_FORMAT_UNSPECIFIED\020\000\022\033\n" + "\027AUDIT_REPORT_FORMAT_ODF\020\001:\261\002\352A\255\002\n" - + ")auditmanager.googleapis.com/AuditSchedule\022Gprojects/{project}/locati" - + "ons/{location}/auditSchedules/{audit_schedule}\022Efolders/{folder}/locations/{loca" - + "tion}/auditSchedules/{audit_schedule}\022Qorganizations/{organization}/locations/{l" - + "ocation}/auditSchedules/{audit_schedule}*\016auditSchedules2\r" + + ")auditmanager.googleapis.com/AuditSchedule\022Gprojects/{project}/loc" + + "ations/{location}/auditSchedules/{audit_schedule}\022Efolders/{folder}/locations/{l" + + "ocation}/auditSchedules/{audit_schedule}\022Qorganizations/{organization}/locations" + + "/{location}/auditSchedules/{audit_schedule}*\016auditSchedules2\r" + "auditSchedule\"\315\002\n" + "\016ScheduleConfig\0224\n\n" + "start_time\030\001 \001(\0132\032.google.protobuf.TimestampB\004\342A\001\002\0222\n" + "\010end_time\030\002 \001(\0132\032.google.protobuf.TimestampB\004\342A\001\001\022O\n" - + "\tfrequency\030\003" - + " \001(\01626.google.cloud.auditmanager.v1.ScheduleConfig.FrequencyB\004\342A\001\002\022\027\n" + + "\tfrequency\030\003 \001(\01626.google.cloud.auditm" + + "anager.v1.ScheduleConfig.FrequencyB\004\342A\001\002\022\027\n" + "\ttime_zone\030\004 \001(\tB\004\342A\001\001\"g\n" + "\tFrequency\022\031\n" + "\025FREQUENCY_UNSPECIFIED\020\000\022\t\n" @@ -512,102 +518,107 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\030SCHEDULE_STATE_COMPLETED\020\003\022\037\n" + "\033SCHEDULE_STATE_FAILED_SETUP\020\004\022\030\n" + "\024SCHEDULE_STATE_ERROR\020\005\022\032\n" - + "\026SCHEDULE_STATE_DELETED\020\0062\332!\n" + + "\026SCHEDULE_STATE_DELETED\020\006*X\n" + + "\022ReportExportFormat\022$\n" + + " REPORT_EXPORT_FORMAT_UNSPECIFIED\020\000\022\034\n" + + "\030REPORT_EXPORT_FORMAT_PDF\020\0012\332!\n" + "\014AuditManager\022\204\003\n" - + "\023CreateAuditSchedule\0228.google.cloud.auditmanager.v1.CreateAudit" - + "ScheduleRequest\032+.google.cloud.auditmana" - + "ger.v1.AuditSchedule\"\205\002\332A\'parent,audit_s" - + "chedule,audit_schedule_id\202\323\344\223\002\324\001\"2/v1/{p" - + "arent=projects/*/locations/*}/auditSchedules:\016audit_scheduleZC\"1/v1/{parent=fold" - + "ers/*/locations/*}/auditSchedules:\016audit_scheduleZI\"7/v1/{parent=organizations/*" - + "/locations/*}/auditSchedules:\016audit_schedule\022\244\003\n" - + "\023UpdateAuditSchedule\0228.google.cloud.auditmanager.v1.UpdateAuditScheduleR" - + "equest\032+.google.cloud.auditmanager.v1.Au" - + "ditSchedule\"\245\002\332A\032audit_schedule,update_m" - + "ask\202\323\344\223\002\201\0022A/v1/{audit_schedule.name=pro" - + "jects/*/locations/*/auditSchedules/*}:\016audit_scheduleZR2@/v1/{audit_schedule.nam" - + "e=folders/*/locations/*/auditSchedules/*}:\016audit_scheduleZX2F/v1/{audit_schedule" - + ".name=organizations/*/locations/*/auditSchedules/*}:\016audit_schedule\022\253\002\n" - + "\020GetAuditSchedule\0225.google.cloud.auditmanager.v1." - + "GetAuditScheduleRequest\032+.google.cloud.a" - + "uditmanager.v1.AuditSchedule\"\262\001\332A\004name\202\323" - + "\344\223\002\244\001\0222/v1/{name=projects/*/locations/*/" - + "auditSchedules/*}Z3\0221/v1/{name=folders/*/locations/*/auditSchedules/*}Z9\0227/v1/{n" - + "ame=organizations/*/locations/*/auditSchedules/*}\022\276\002\n" - + "\022ListAuditSchedules\0227.google.cloud.auditmanager.v1.ListAuditSchedul" - + "esRequest\0328.google.cloud.auditmanager.v1" - + ".ListAuditSchedulesResponse\"\264\001\332A\006parent\202" - + "\323\344\223\002\244\001\0222/v1/{parent=projects/*/locations" - + "/*}/auditSchedulesZ3\0221/v1/{parent=folders/*/locations/*}/auditSchedulesZ9\0227/v1/{" - + "parent=organizations/*/locations/*}/auditSchedules\022\270\002\n" - + "\016EnrollResource\0223.google.cloud.auditmanager.v1.EnrollResourceReque" - + "st\032(.google.cloud.auditmanager.v1.Enroll" - + "ment\"\306\001\332A\022scope,destinations\202\323\344\223\002\252\001\"0/v1" - + "/{scope=folders/*/locations/*}:enrollResource:\001*Z6\"1/v1/{scope=projects/*/locati" - + "ons/*}:enrollResource:\001*Z;\"6/v1/{scope=o" - + "rganizations/*/locations/*}:enrollResource:\001*\022\213\003\n" - + "\030GenerateAuditScopeReport\022=.google.cloud.auditmanager.v1.GenerateAuditS" - + "copeReportRequest\032..google.cloud.auditma" - + "nager.v1.AuditScopeReport\"\377\001\332A\'scope,com" - + "pliance_standard,report_format\202\323\344\223\002\316\001\"/v1/{name=projects/*/locat" - + "ions/*/resourceEnrollmentStatuses/*}Z?\022=/v1/{name=folders/*/locations/*/resource" - + "EnrollmentStatuses/*}ZE\022C/v1/{name=organ" - + "izations/*/locations/*/resourceEnrollmentStatuses/*}\022\304\002\n" - + "\036ListResourceEnrollmentStatuses\022C.google.cloud.auditmanager.v1.L" - + "istResourceEnrollmentStatusesRequest\032D.google.cloud.auditmanager.v1.ListResource" - + "EnrollmentStatusesResponse\"\226\001\332A\006parent\202\323" - + "\344\223\002\206\001\022C/v1/{parent=organizations/*/locat" - + "ions/*}/resourceEnrollmentStatusesZ?\022=/v" - + "1/{parent=folders/*/locations/*}/resourceEnrollmentStatuses\022\276\002\n" - + "\014ListControls\0221.google.cloud.auditmanager.v1.ListControls" - + "Request\0322.google.cloud.auditmanager.v1.L" - + "istControlsResponse\"\306\001\332A\006parent\202\323\344\223\002\266\001\022=" - + "/v1/{parent=organizations/*/locations/*/standards/*}/controlsZ9\0227/v1/{parent=fol" - + "ders/*/locations/*/standards/*}/controlsZ:\0228/v1/{parent=projects/*/locations/*/s" - + "tandards/*}/controls\032\202\001\312A\033auditmanager.g" - + "oogleapis.com\322Aahttps://www.googleapis.c" - + "om/auth/cloud-auditmanager,https://www.googleapis.com/auth/cloud-platformB\222\006\n" - + " com.google.cloud.auditmanager.v1B\013V1mainPr" - + "otoP\001ZDcloud.google.com/go/auditmanager/" - + "apiv1/auditmanagerpb;auditmanagerpb\252\002\034Go" - + "ogle.Cloud.AuditManager.V1\312\002\034Google\\Clou" - + "d\\AuditManager\\V1\352\002\037Google::Cloud::AuditManager::V1\352AS\n" - + "*auditmanager.googleapis." - + "com/FolderLocation\022%folders/{folder}/locations/{location}\352Ae\n" - + "0auditmanager.googleapis.com/OrganizationLocation\0221organiza" - + "tions/{organization}/locations/{location}\352A\350\001\n" - + "$auditmanager.googleapis.com/Standard\022/v1/{name=pro" + + "jects/*/locations/*/resourceEnrollmentStatuses/*}Z?\022=/v1/{name=folders/*/locatio" + + "ns/*/resourceEnrollmentStatuses/*}ZE\022C/v" + + "1/{name=organizations/*/locations/*/resourceEnrollmentStatuses/*}\022\304\002\n" + + "\036ListResourceEnrollmentStatuses\022C.google.cloud.audi" + + "tmanager.v1.ListResourceEnrollmentStatusesRequest\032D.google.cloud.auditmanager.v1" + + ".ListResourceEnrollmentStatusesResponse\"" + + "\226\001\332A\006parent\202\323\344\223\002\206\001\022C/v1/{parent=organiza" + + "tions/*/locations/*}/resourceEnrollmentS" + + "tatusesZ?\022=/v1/{parent=folders/*/locations/*}/resourceEnrollmentStatuses\022\276\002\n" + + "\014ListControls\0221.google.cloud.auditmanager.v1" + + ".ListControlsRequest\0322.google.cloud.audi" + + "tmanager.v1.ListControlsResponse\"\306\001\332A\006pa" + + "rent\202\323\344\223\002\266\001\022=/v1/{parent=organizations/*" + + "/locations/*/standards/*}/controlsZ9\0227/v1/{parent=folders/*/locations/*/standard" + + "s/*}/controlsZ:\0228/v1/{parent=projects/*/" + + "locations/*/standards/*}/controls\032\202\001\312A\033a" + + "uditmanager.googleapis.com\322Aahttps://www.googleapis.com/auth/cloud-auditmanager," + + "https://www.googleapis.com/auth/cloud-platformB\222\006\n" + + " com.google.cloud.auditmanager.v1B\013V1mainProtoP\001ZDcloud.google.com/go/" + + "auditmanager/apiv1/auditmanagerpb;auditm" + + "anagerpb\252\002\034Google.Cloud.AuditManager.V1\312" + + "\002\034Google\\Cloud\\AuditManager\\V1\352\002\037Google::Cloud::AuditManager::V1\352AS\n" + + "*auditmanage" + + "r.googleapis.com/FolderLocation\022%folders/{folder}/locations/{location}\352Ae\n" + + "0auditmanager.googleapis.com/OrganizationLocat" + + "ion\0221organizations/{organization}/locations/{location}\352A\350\001\n" + + "$auditmanager.googleapis.com/Standard\022 cloud_control_parameter_states = 16 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Additional formats in which the audit report was requested to + // be exported. + repeated ReportExportFormat report_export_formats = 17 + [(google.api.field_behavior) = OUTPUT_ONLY]; } // Regulatory family of the control. @@ -1086,11 +1112,12 @@ message ControlDetails { // Request message for // [CreateAuditSchedule][google.cloud.auditmanager.v1.AuditManager.CreateAuditSchedule]. message CreateAuditScheduleRequest { - // Required. Project or folder that this audit schedule is for, in one of the - // following formats: + // Required. Project, folder, or organization that this audit schedule is for, + // in one of the following formats: // // * `projects/{project}/locations/{location}` // * `folders/{folder}/locations/{location}` + // * `organizations/{organization}/locations/{location}` string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -1208,6 +1235,7 @@ message ListAuditSchedulesResponse { // // * `projects/{project}/locations/{location}/auditSchedules/{audit_schedule}` // * `folders/{folder}/locations/{location}/auditSchedules/{audit_schedule}` +// * `organizations/{organization}/locations/{location}/auditSchedules/{audit_schedule}` message AuditSchedule { option (google.api.resource) = { type: "auditmanager.googleapis.com/AuditSchedule" @@ -1283,6 +1311,11 @@ message AuditSchedule { // {parameters: [...]}}` map parameter_overrides = 14 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Formats in which to export each scheduled audit report, in + // addition to the ODF report. Each format can be listed only once. + repeated ReportExportFormat report_export_formats = 15 + [(google.api.field_behavior) = OPTIONAL]; } // Timing and frequency parameters for recurring audit runs. diff --git a/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/AsyncGenerateAuditReport.java b/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/AsyncGenerateAuditReport.java index 2488d412e5c7..fa7536990f54 100644 --- a/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/AsyncGenerateAuditReport.java +++ b/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/AsyncGenerateAuditReport.java @@ -21,7 +21,9 @@ import com.google.cloud.auditmanager.v1.AuditManagerClient; import com.google.cloud.auditmanager.v1.GenerateAuditReportRequest; import com.google.cloud.auditmanager.v1.ParameterOverrides; +import com.google.cloud.auditmanager.v1.ReportExportFormat; import com.google.longrunning.Operation; +import java.util.ArrayList; import java.util.HashMap; public class AsyncGenerateAuditReport { @@ -44,6 +46,7 @@ public static void asyncGenerateAuditReport() throws Exception { .setComplianceFramework("complianceFramework-1808314333") .putAllParameterOverrides(new HashMap()) .setValidateOnly(true) + .addAllReportExportFormats(new ArrayList()) .build(); ApiFuture future = auditManagerClient.generateAuditReportCallable().futureCall(request); diff --git a/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/AsyncGenerateAuditReportLRO.java b/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/AsyncGenerateAuditReportLRO.java index 35a76b54cbd5..79e3cb2f6822 100644 --- a/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/AsyncGenerateAuditReportLRO.java +++ b/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/AsyncGenerateAuditReportLRO.java @@ -23,6 +23,8 @@ import com.google.cloud.auditmanager.v1.GenerateAuditReportRequest; import com.google.cloud.auditmanager.v1.OperationMetadata; import com.google.cloud.auditmanager.v1.ParameterOverrides; +import com.google.cloud.auditmanager.v1.ReportExportFormat; +import java.util.ArrayList; import java.util.HashMap; public class AsyncGenerateAuditReportLRO { @@ -45,6 +47,7 @@ public static void asyncGenerateAuditReportLRO() throws Exception { .setComplianceFramework("complianceFramework-1808314333") .putAllParameterOverrides(new HashMap()) .setValidateOnly(true) + .addAllReportExportFormats(new ArrayList()) .build(); OperationFuture future = auditManagerClient.generateAuditReportOperationCallable().futureCall(request); diff --git a/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/SyncGenerateAuditReport.java b/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/SyncGenerateAuditReport.java index b5d1a8653e62..72cfbd2a3bdf 100644 --- a/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/SyncGenerateAuditReport.java +++ b/java-auditmanager/samples/snippets/generated/com/google/cloud/auditmanager/v1/auditmanager/generateauditreport/SyncGenerateAuditReport.java @@ -21,6 +21,8 @@ import com.google.cloud.auditmanager.v1.AuditReport; import com.google.cloud.auditmanager.v1.GenerateAuditReportRequest; import com.google.cloud.auditmanager.v1.ParameterOverrides; +import com.google.cloud.auditmanager.v1.ReportExportFormat; +import java.util.ArrayList; import java.util.HashMap; public class SyncGenerateAuditReport { @@ -43,6 +45,7 @@ public static void syncGenerateAuditReport() throws Exception { .setComplianceFramework("complianceFramework-1808314333") .putAllParameterOverrides(new HashMap()) .setValidateOnly(true) + .addAllReportExportFormats(new ArrayList()) .build(); AuditReport response = auditManagerClient.generateAuditReportAsync(request).get(); } diff --git a/java-backstory/README.md b/java-backstory/README.md index abe966124f77..f5641c5ccc53 100644 --- a/java-backstory/README.md +++ b/java-backstory/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-backstory - 0.10.0 + 0.11.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-backstory' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-backstory:0.10.0' +implementation 'com.google.cloud:google-cloud-backstory:0.11.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-backstory" % "0.10.0" +libraryDependencies += "com.google.cloud" % "google-cloud-backstory" % "0.11.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-backstory/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-backstory.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-backstory/0.10.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-backstory/0.11.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-backupdr/README.md b/java-backupdr/README.md index 127e479249c5..0cb08f372b1d 100644 --- a/java-backupdr/README.md +++ b/java-backupdr/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-backupdr - 0.61.0 + 0.62.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-backupdr' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-backupdr:0.61.0' +implementation 'com.google.cloud:google-cloud-backupdr:0.62.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-backupdr" % "0.61.0" +libraryDependencies += "com.google.cloud" % "google-cloud-backupdr" % "0.62.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-backupdr/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-backupdr.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-backupdr/0.61.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-backupdr/0.62.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-bare-metal-solution/README.md b/java-bare-metal-solution/README.md index c81b183603bf..e8f79d28a97d 100644 --- a/java-bare-metal-solution/README.md +++ b/java-bare-metal-solution/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-bare-metal-solution - 0.102.0 + 0.103.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-bare-metal-solution' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-bare-metal-solution:0.102.0' +implementation 'com.google.cloud:google-cloud-bare-metal-solution:0.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-bare-metal-solution" % "0.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-bare-metal-solution" % "0.103.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-bare-metal-solution/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-bare-metal-solution.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bare-metal-solution/0.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bare-metal-solution/0.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-batch/README.md b/java-batch/README.md index 9da38d014b7c..d438105084e6 100644 --- a/java-batch/README.md +++ b/java-batch/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-batch - 0.102.0 + 0.103.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-batch' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-batch:0.102.0' +implementation 'com.google.cloud:google-cloud-batch:0.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-batch" % "0.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-batch" % "0.103.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-batch/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-batch.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-batch/0.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-batch/0.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-batch/google-cloud-batch/src/main/resources/META-INF/native-image/com.google.cloud.batch.v1/reflect-config.json b/java-batch/google-cloud-batch/src/main/resources/META-INF/native-image/com.google.cloud.batch.v1/reflect-config.json index 17097b573c12..e45e45c5c296 100644 --- a/java-batch/google-cloud-batch/src/main/resources/META-INF/native-image/com.google.cloud.batch.v1/reflect-config.json +++ b/java-batch/google-cloud-batch/src/main/resources/META-INF/native-image/com.google.cloud.batch.v1/reflect-config.json @@ -593,6 +593,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.batch.v1.AllocationPolicy$InstanceFlexibilityPolicy", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.batch.v1.AllocationPolicy$InstanceFlexibilityPolicy$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.batch.v1.AllocationPolicy$InstancePolicy", "queryAllDeclaredConstructors": true, @@ -629,6 +647,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.batch.v1.AllocationPolicy$InstanceSelection", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.batch.v1.AllocationPolicy$InstanceSelection$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.batch.v1.AllocationPolicy$LocationPolicy", "queryAllDeclaredConstructors": true, diff --git a/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/AllocationPolicy.java b/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/AllocationPolicy.java index 09e8c730c42d..c7f1bbffee4c 100644 --- a/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/AllocationPolicy.java +++ b/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/AllocationPolicy.java @@ -13739,6 +13739,2146 @@ public com.google.cloud.batch.v1.AllocationPolicy.PlacementPolicy getDefaultInst } } + public interface InstanceFlexibilityPolicyOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +     * Required. Named instance selections configuring properties that the group
                      +     * will use when creating new VMs. The map key is a user-specified name for
                      +     * the instance selection. The key must be 1-63 characters long, and comply
                      +     * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +     * key must consist of lowercase letters, numbers, and hyphens. The first
                      +     * character must be a lowercase letter, and the last character must be a
                      +     * lowercase letter or number.
                      +     * The maximum number of instance selections is 50. Exceeding this limit
                      +     * results in a validation error with code `INVALID_ARGUMENT`.
                      +     * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + int getInstanceSelectionsCount(); + + /** + * + * + *
                      +     * Required. Named instance selections configuring properties that the group
                      +     * will use when creating new VMs. The map key is a user-specified name for
                      +     * the instance selection. The key must be 1-63 characters long, and comply
                      +     * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +     * key must consist of lowercase letters, numbers, and hyphens. The first
                      +     * character must be a lowercase letter, and the last character must be a
                      +     * lowercase letter or number.
                      +     * The maximum number of instance selections is 50. Exceeding this limit
                      +     * results in a validation error with code `INVALID_ARGUMENT`.
                      +     * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + boolean containsInstanceSelections(java.lang.String key); + + /** Use {@link #getInstanceSelectionsMap()} instead. */ + @java.lang.Deprecated + java.util.Map + getInstanceSelections(); + + /** + * + * + *
                      +     * Required. Named instance selections configuring properties that the group
                      +     * will use when creating new VMs. The map key is a user-specified name for
                      +     * the instance selection. The key must be 1-63 characters long, and comply
                      +     * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +     * key must consist of lowercase letters, numbers, and hyphens. The first
                      +     * character must be a lowercase letter, and the last character must be a
                      +     * lowercase letter or number.
                      +     * The maximum number of instance selections is 50. Exceeding this limit
                      +     * results in a validation error with code `INVALID_ARGUMENT`.
                      +     * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + java.util.Map + getInstanceSelectionsMap(); + + /** + * + * + *
                      +     * Required. Named instance selections configuring properties that the group
                      +     * will use when creating new VMs. The map key is a user-specified name for
                      +     * the instance selection. The key must be 1-63 characters long, and comply
                      +     * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +     * key must consist of lowercase letters, numbers, and hyphens. The first
                      +     * character must be a lowercase letter, and the last character must be a
                      +     * lowercase letter or number.
                      +     * The maximum number of instance selections is 50. Exceeding this limit
                      +     * results in a validation error with code `INVALID_ARGUMENT`.
                      +     * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + /* nullable */ + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection getInstanceSelectionsOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection defaultValue); + + /** + * + * + *
                      +     * Required. Named instance selections configuring properties that the group
                      +     * will use when creating new VMs. The map key is a user-specified name for
                      +     * the instance selection. The key must be 1-63 characters long, and comply
                      +     * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +     * key must consist of lowercase letters, numbers, and hyphens. The first
                      +     * character must be a lowercase letter, and the last character must be a
                      +     * lowercase letter or number.
                      +     * The maximum number of instance selections is 50. Exceeding this limit
                      +     * results in a validation error with code `INVALID_ARGUMENT`.
                      +     * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection getInstanceSelectionsOrThrow( + java.lang.String key); + } + + /** + * + * + *
                      +   * Allows creating VMs from multiple types of machines. Instance flexibility
                      +   * configuration overrides instances configuration.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy} + */ + public static final class InstanceFlexibilityPolicy extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy) + InstanceFlexibilityPolicyOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "InstanceFlexibilityPolicy"); + } + + // Use InstanceFlexibilityPolicy.newBuilder() to construct. + private InstanceFlexibilityPolicy(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private InstanceFlexibilityPolicy() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.batch.v1.JobProto + .internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 1: + return internalGetInstanceSelections(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.batch.v1.JobProto + .internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.class, + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.Builder.class); + } + + public static final int INSTANCE_SELECTIONS_FIELD_NUMBER = 1; + + private static final class InstanceSelectionsDefaultEntryHolder { + static final com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + defaultEntry = + com.google.protobuf.MapEntry + . + newDefaultInstance( + com.google.cloud.batch.v1.JobProto + .internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_InstanceSelectionsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.MESSAGE, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection + .getDefaultInstance()); + } + + @SuppressWarnings("serial") + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + instanceSelections_; + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + internalGetInstanceSelections() { + if (instanceSelections_ == null) { + return com.google.protobuf.MapField.emptyMapField( + InstanceSelectionsDefaultEntryHolder.defaultEntry); + } + return instanceSelections_; + } + + public int getInstanceSelectionsCount() { + return internalGetInstanceSelections().getMap().size(); + } + + /** + * + * + *
                      +     * Required. Named instance selections configuring properties that the group
                      +     * will use when creating new VMs. The map key is a user-specified name for
                      +     * the instance selection. The key must be 1-63 characters long, and comply
                      +     * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +     * key must consist of lowercase letters, numbers, and hyphens. The first
                      +     * character must be a lowercase letter, and the last character must be a
                      +     * lowercase letter or number.
                      +     * The maximum number of instance selections is 50. Exceeding this limit
                      +     * results in a validation error with code `INVALID_ARGUMENT`.
                      +     * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public boolean containsInstanceSelections(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetInstanceSelections().getMap().containsKey(key); + } + + /** Use {@link #getInstanceSelectionsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + getInstanceSelections() { + return getInstanceSelectionsMap(); + } + + /** + * + * + *
                      +     * Required. Named instance selections configuring properties that the group
                      +     * will use when creating new VMs. The map key is a user-specified name for
                      +     * the instance selection. The key must be 1-63 characters long, and comply
                      +     * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +     * key must consist of lowercase letters, numbers, and hyphens. The first
                      +     * character must be a lowercase letter, and the last character must be a
                      +     * lowercase letter or number.
                      +     * The maximum number of instance selections is 50. Exceeding this limit
                      +     * results in a validation error with code `INVALID_ARGUMENT`.
                      +     * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public java.util.Map< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + getInstanceSelectionsMap() { + return internalGetInstanceSelections().getMap(); + } + + /** + * + * + *
                      +     * Required. Named instance selections configuring properties that the group
                      +     * will use when creating new VMs. The map key is a user-specified name for
                      +     * the instance selection. The key must be 1-63 characters long, and comply
                      +     * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +     * key must consist of lowercase letters, numbers, and hyphens. The first
                      +     * character must be a lowercase letter, and the last character must be a
                      +     * lowercase letter or number.
                      +     * The maximum number of instance selections is 50. Exceeding this limit
                      +     * results in a validation error with code `INVALID_ARGUMENT`.
                      +     * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public /* nullable */ com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection + getInstanceSelectionsOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map + map = internalGetInstanceSelections().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
                      +     * Required. Named instance selections configuring properties that the group
                      +     * will use when creating new VMs. The map key is a user-specified name for
                      +     * the instance selection. The key must be 1-63 characters long, and comply
                      +     * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +     * key must consist of lowercase letters, numbers, and hyphens. The first
                      +     * character must be a lowercase letter, and the last character must be a
                      +     * lowercase letter or number.
                      +     * The maximum number of instance selections is 50. Exceeding this limit
                      +     * results in a validation error with code `INVALID_ARGUMENT`.
                      +     * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection + getInstanceSelectionsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map + map = internalGetInstanceSelections().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + com.google.protobuf.GeneratedMessage.serializeStringMapTo( + output, + internalGetInstanceSelections(), + InstanceSelectionsDefaultEntryHolder.defaultEntry, + 1); + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (java.util.Map.Entry< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + entry : internalGetInstanceSelections().getMap().entrySet()) { + com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + instanceSelections__ = + InstanceSelectionsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, instanceSelections__); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy)) { + return super.equals(obj); + } + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy other = + (com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy) obj; + + if (!internalGetInstanceSelections().equals(other.internalGetInstanceSelections())) + return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (!internalGetInstanceSelections().getMap().isEmpty()) { + hash = (37 * hash) + INSTANCE_SELECTIONS_FIELD_NUMBER; + hash = (53 * hash) + internalGetInstanceSelections().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +     * Allows creating VMs from multiple types of machines. Instance flexibility
                      +     * configuration overrides instances configuration.
                      +     * 
                      + * + * Protobuf type {@code google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy) + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicyOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.batch.v1.JobProto + .internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 1: + return internalGetInstanceSelections(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( + int number) { + switch (number) { + case 1: + return internalGetMutableInstanceSelections(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.batch.v1.JobProto + .internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.class, + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.Builder.class); + } + + // Construct using + // com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + internalGetMutableInstanceSelections().clear(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.batch.v1.JobProto + .internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_descriptor; + } + + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + getDefaultInstanceForType() { + return com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy build() { + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy buildPartial() { + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy result = + new com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.instanceSelections_ = + internalGetInstanceSelections() + .build(InstanceSelectionsDefaultEntryHolder.defaultEntry); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy) { + return mergeFrom( + (com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy other) { + if (other + == com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + .getDefaultInstance()) return this; + internalGetMutableInstanceSelections().mergeFrom(other.internalGetInstanceSelections()); + bitField0_ |= 0x00000001; + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.protobuf.MapEntry< + java.lang.String, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + instanceSelections__ = + input.readMessage( + InstanceSelectionsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableInstanceSelections() + .ensureBuilderMap() + .put(instanceSelections__.getKey(), instanceSelections__.getValue()); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private static final class InstanceSelectionsConverter + implements com.google.protobuf.MapFieldBuilder.Converter< + java.lang.String, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelectionOrBuilder, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> { + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection build( + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelectionOrBuilder val) { + if (val instanceof com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection) { + return (com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection) val; + } + return ((com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.Builder) val) + .build(); + } + + @java.lang.Override + public com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + defaultEntry() { + return InstanceSelectionsDefaultEntryHolder.defaultEntry; + } + } + ; + + private static final InstanceSelectionsConverter instanceSelectionsConverter = + new InstanceSelectionsConverter(); + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelectionOrBuilder, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.Builder> + instanceSelections_; + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelectionOrBuilder, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.Builder> + internalGetInstanceSelections() { + if (instanceSelections_ == null) { + return new com.google.protobuf.MapFieldBuilder<>(instanceSelectionsConverter); + } + return instanceSelections_; + } + + private com.google.protobuf.MapFieldBuilder< + java.lang.String, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelectionOrBuilder, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.Builder> + internalGetMutableInstanceSelections() { + if (instanceSelections_ == null) { + instanceSelections_ = + new com.google.protobuf.MapFieldBuilder<>(instanceSelectionsConverter); + } + bitField0_ |= 0x00000001; + onChanged(); + return instanceSelections_; + } + + public int getInstanceSelectionsCount() { + return internalGetInstanceSelections().ensureBuilderMap().size(); + } + + /** + * + * + *
                      +       * Required. Named instance selections configuring properties that the group
                      +       * will use when creating new VMs. The map key is a user-specified name for
                      +       * the instance selection. The key must be 1-63 characters long, and comply
                      +       * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +       * key must consist of lowercase letters, numbers, and hyphens. The first
                      +       * character must be a lowercase letter, and the last character must be a
                      +       * lowercase letter or number.
                      +       * The maximum number of instance selections is 50. Exceeding this limit
                      +       * results in a validation error with code `INVALID_ARGUMENT`.
                      +       * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public boolean containsInstanceSelections(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetInstanceSelections().ensureBuilderMap().containsKey(key); + } + + /** Use {@link #getInstanceSelectionsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + getInstanceSelections() { + return getInstanceSelectionsMap(); + } + + /** + * + * + *
                      +       * Required. Named instance selections configuring properties that the group
                      +       * will use when creating new VMs. The map key is a user-specified name for
                      +       * the instance selection. The key must be 1-63 characters long, and comply
                      +       * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +       * key must consist of lowercase letters, numbers, and hyphens. The first
                      +       * character must be a lowercase letter, and the last character must be a
                      +       * lowercase letter or number.
                      +       * The maximum number of instance selections is 50. Exceeding this limit
                      +       * results in a validation error with code `INVALID_ARGUMENT`.
                      +       * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public java.util.Map< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + getInstanceSelectionsMap() { + return internalGetInstanceSelections().getImmutableMap(); + } + + /** + * + * + *
                      +       * Required. Named instance selections configuring properties that the group
                      +       * will use when creating new VMs. The map key is a user-specified name for
                      +       * the instance selection. The key must be 1-63 characters long, and comply
                      +       * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +       * key must consist of lowercase letters, numbers, and hyphens. The first
                      +       * character must be a lowercase letter, and the last character must be a
                      +       * lowercase letter or number.
                      +       * The maximum number of instance selections is 50. Exceeding this limit
                      +       * results in a validation error with code `INVALID_ARGUMENT`.
                      +       * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public /* nullable */ com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection + getInstanceSelectionsOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelectionOrBuilder> + map = internalGetMutableInstanceSelections().ensureBuilderMap(); + return map.containsKey(key) + ? instanceSelectionsConverter.build(map.get(key)) + : defaultValue; + } + + /** + * + * + *
                      +       * Required. Named instance selections configuring properties that the group
                      +       * will use when creating new VMs. The map key is a user-specified name for
                      +       * the instance selection. The key must be 1-63 characters long, and comply
                      +       * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +       * key must consist of lowercase letters, numbers, and hyphens. The first
                      +       * character must be a lowercase letter, and the last character must be a
                      +       * lowercase letter or number.
                      +       * The maximum number of instance selections is 50. Exceeding this limit
                      +       * results in a validation error with code `INVALID_ARGUMENT`.
                      +       * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection + getInstanceSelectionsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map< + java.lang.String, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelectionOrBuilder> + map = internalGetMutableInstanceSelections().ensureBuilderMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return instanceSelectionsConverter.build(map.get(key)); + } + + public Builder clearInstanceSelections() { + bitField0_ = (bitField0_ & ~0x00000001); + internalGetMutableInstanceSelections().clear(); + return this; + } + + /** + * + * + *
                      +       * Required. Named instance selections configuring properties that the group
                      +       * will use when creating new VMs. The map key is a user-specified name for
                      +       * the instance selection. The key must be 1-63 characters long, and comply
                      +       * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +       * key must consist of lowercase letters, numbers, and hyphens. The first
                      +       * character must be a lowercase letter, and the last character must be a
                      +       * lowercase letter or number.
                      +       * The maximum number of instance selections is 50. Exceeding this limit
                      +       * results in a validation error with code `INVALID_ARGUMENT`.
                      +       * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder removeInstanceSelections(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableInstanceSelections().ensureBuilderMap().remove(key); + return this; + } + + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + getMutableInstanceSelections() { + bitField0_ |= 0x00000001; + return internalGetMutableInstanceSelections().ensureMessageMap(); + } + + /** + * + * + *
                      +       * Required. Named instance selections configuring properties that the group
                      +       * will use when creating new VMs. The map key is a user-specified name for
                      +       * the instance selection. The key must be 1-63 characters long, and comply
                      +       * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +       * key must consist of lowercase letters, numbers, and hyphens. The first
                      +       * character must be a lowercase letter, and the last character must be a
                      +       * lowercase letter or number.
                      +       * The maximum number of instance selections is 50. Exceeding this limit
                      +       * results in a validation error with code `INVALID_ARGUMENT`.
                      +       * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder putInstanceSelections( + java.lang.String key, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + internalGetMutableInstanceSelections().ensureBuilderMap().put(key, value); + bitField0_ |= 0x00000001; + return this; + } + + /** + * + * + *
                      +       * Required. Named instance selections configuring properties that the group
                      +       * will use when creating new VMs. The map key is a user-specified name for
                      +       * the instance selection. The key must be 1-63 characters long, and comply
                      +       * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +       * key must consist of lowercase letters, numbers, and hyphens. The first
                      +       * character must be a lowercase letter, and the last character must be a
                      +       * lowercase letter or number.
                      +       * The maximum number of instance selections is 50. Exceeding this limit
                      +       * results in a validation error with code `INVALID_ARGUMENT`.
                      +       * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder putAllInstanceSelections( + java.util.Map< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + values) { + for (java.util.Map.Entry< + java.lang.String, com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection> + e : values.entrySet()) { + if (e.getKey() == null || e.getValue() == null) { + throw new NullPointerException(); + } + } + internalGetMutableInstanceSelections().ensureBuilderMap().putAll(values); + bitField0_ |= 0x00000001; + return this; + } + + /** + * + * + *
                      +       * Required. Named instance selections configuring properties that the group
                      +       * will use when creating new VMs. The map key is a user-specified name for
                      +       * the instance selection. The key must be 1-63 characters long, and comply
                      +       * with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the
                      +       * key must consist of lowercase letters, numbers, and hyphens. The first
                      +       * character must be a lowercase letter, and the last character must be a
                      +       * lowercase letter or number.
                      +       * The maximum number of instance selections is 50. Exceeding this limit
                      +       * results in a validation error with code `INVALID_ARGUMENT`.
                      +       * 
                      + * + * + * map<string, .google.cloud.batch.v1.AllocationPolicy.InstanceSelection> instance_selections = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.Builder + putInstanceSelectionsBuilderIfAbsent(java.lang.String key) { + java.util.Map< + java.lang.String, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelectionOrBuilder> + builderMap = internalGetMutableInstanceSelections().ensureBuilderMap(); + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelectionOrBuilder entry = + builderMap.get(key); + if (entry == null) { + entry = com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.newBuilder(); + builderMap.put(key, entry); + } + if (entry instanceof com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection) { + entry = + ((com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection) entry).toBuilder(); + builderMap.put(key, entry); + } + return (com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.Builder) entry; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy) + } + + // @@protoc_insertion_point(class_scope:google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy) + private static final com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy(); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public InstanceFlexibilityPolicy parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface InstanceSelectionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.batch.v1.AllocationPolicy.InstanceSelection) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +     * Required. The Compute Engine machine type IDs.
                      +     * Only the machine type ID is supported, such as `n1-standard-16`.
                      +     * Full or partial URLs are not accepted.
                      +     * The total maximum number of machine types across all instance selections
                      +     * is 200. Exceeding this limit results in a validation error with code
                      +     * `INVALID_ARGUMENT`.
                      +     * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return A list containing the machineTypes. + */ + java.util.List getMachineTypesList(); + + /** + * + * + *
                      +     * Required. The Compute Engine machine type IDs.
                      +     * Only the machine type ID is supported, such as `n1-standard-16`.
                      +     * Full or partial URLs are not accepted.
                      +     * The total maximum number of machine types across all instance selections
                      +     * is 200. Exceeding this limit results in a validation error with code
                      +     * `INVALID_ARGUMENT`.
                      +     * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The count of machineTypes. + */ + int getMachineTypesCount(); + + /** + * + * + *
                      +     * Required. The Compute Engine machine type IDs.
                      +     * Only the machine type ID is supported, such as `n1-standard-16`.
                      +     * Full or partial URLs are not accepted.
                      +     * The total maximum number of machine types across all instance selections
                      +     * is 200. Exceeding this limit results in a validation error with code
                      +     * `INVALID_ARGUMENT`.
                      +     * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the element to return. + * @return The machineTypes at the given index. + */ + java.lang.String getMachineTypes(int index); + + /** + * + * + *
                      +     * Required. The Compute Engine machine type IDs.
                      +     * Only the machine type ID is supported, such as `n1-standard-16`.
                      +     * Full or partial URLs are not accepted.
                      +     * The total maximum number of machine types across all instance selections
                      +     * is 200. Exceeding this limit results in a validation error with code
                      +     * `INVALID_ARGUMENT`.
                      +     * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the value to return. + * @return The bytes of the machineTypes at the given index. + */ + com.google.protobuf.ByteString getMachineTypesBytes(int index); + + /** + * + * + *
                      +     * Optional. Indicates the preference of this instance selection. Lower
                      +     * number means higher preference. First try is to create a VM based on the
                      +     * machine-type with lowest rank and fallback to next rank based on
                      +     * availability. Machine types and instance selections with the same rank
                      +     * have the same preference.
                      +     * 
                      + * + * optional int32 rank = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the rank field is set. + */ + boolean hasRank(); + + /** + * + * + *
                      +     * Optional. Indicates the preference of this instance selection. Lower
                      +     * number means higher preference. First try is to create a VM based on the
                      +     * machine-type with lowest rank and fallback to next rank based on
                      +     * availability. Machine types and instance selections with the same rank
                      +     * have the same preference.
                      +     * 
                      + * + * optional int32 rank = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The rank. + */ + int getRank(); + } + + /** + * + * + *
                      +   * Defines an instance selection for a given instance flexibility policy.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.batch.v1.AllocationPolicy.InstanceSelection} + */ + public static final class InstanceSelection extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.batch.v1.AllocationPolicy.InstanceSelection) + InstanceSelectionOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "InstanceSelection"); + } + + // Use InstanceSelection.newBuilder() to construct. + private InstanceSelection(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private InstanceSelection() { + machineTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.batch.v1.JobProto + .internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceSelection_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.batch.v1.JobProto + .internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceSelection_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.class, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.Builder.class); + } + + private int bitField0_; + public static final int MACHINE_TYPES_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList machineTypes_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
                      +     * Required. The Compute Engine machine type IDs.
                      +     * Only the machine type ID is supported, such as `n1-standard-16`.
                      +     * Full or partial URLs are not accepted.
                      +     * The total maximum number of machine types across all instance selections
                      +     * is 200. Exceeding this limit results in a validation error with code
                      +     * `INVALID_ARGUMENT`.
                      +     * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return A list containing the machineTypes. + */ + public com.google.protobuf.ProtocolStringList getMachineTypesList() { + return machineTypes_; + } + + /** + * + * + *
                      +     * Required. The Compute Engine machine type IDs.
                      +     * Only the machine type ID is supported, such as `n1-standard-16`.
                      +     * Full or partial URLs are not accepted.
                      +     * The total maximum number of machine types across all instance selections
                      +     * is 200. Exceeding this limit results in a validation error with code
                      +     * `INVALID_ARGUMENT`.
                      +     * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The count of machineTypes. + */ + public int getMachineTypesCount() { + return machineTypes_.size(); + } + + /** + * + * + *
                      +     * Required. The Compute Engine machine type IDs.
                      +     * Only the machine type ID is supported, such as `n1-standard-16`.
                      +     * Full or partial URLs are not accepted.
                      +     * The total maximum number of machine types across all instance selections
                      +     * is 200. Exceeding this limit results in a validation error with code
                      +     * `INVALID_ARGUMENT`.
                      +     * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the element to return. + * @return The machineTypes at the given index. + */ + public java.lang.String getMachineTypes(int index) { + return machineTypes_.get(index); + } + + /** + * + * + *
                      +     * Required. The Compute Engine machine type IDs.
                      +     * Only the machine type ID is supported, such as `n1-standard-16`.
                      +     * Full or partial URLs are not accepted.
                      +     * The total maximum number of machine types across all instance selections
                      +     * is 200. Exceeding this limit results in a validation error with code
                      +     * `INVALID_ARGUMENT`.
                      +     * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the value to return. + * @return The bytes of the machineTypes at the given index. + */ + public com.google.protobuf.ByteString getMachineTypesBytes(int index) { + return machineTypes_.getByteString(index); + } + + public static final int RANK_FIELD_NUMBER = 2; + private int rank_ = 0; + + /** + * + * + *
                      +     * Optional. Indicates the preference of this instance selection. Lower
                      +     * number means higher preference. First try is to create a VM based on the
                      +     * machine-type with lowest rank and fallback to next rank based on
                      +     * availability. Machine types and instance selections with the same rank
                      +     * have the same preference.
                      +     * 
                      + * + * optional int32 rank = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the rank field is set. + */ + @java.lang.Override + public boolean hasRank() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * Optional. Indicates the preference of this instance selection. Lower
                      +     * number means higher preference. First try is to create a VM based on the
                      +     * machine-type with lowest rank and fallback to next rank based on
                      +     * availability. Machine types and instance selections with the same rank
                      +     * have the same preference.
                      +     * 
                      + * + * optional int32 rank = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The rank. + */ + @java.lang.Override + public int getRank() { + return rank_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < machineTypes_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, machineTypes_.getRaw(i)); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeInt32(2, rank_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + for (int i = 0; i < machineTypes_.size(); i++) { + dataSize += computeStringSizeNoTag(machineTypes_.getRaw(i)); + } + size += dataSize; + size += 1 * getMachineTypesList().size(); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, rank_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection)) { + return super.equals(obj); + } + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection other = + (com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection) obj; + + if (!getMachineTypesList().equals(other.getMachineTypesList())) return false; + if (hasRank() != other.hasRank()) return false; + if (hasRank()) { + if (getRank() != other.getRank()) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getMachineTypesCount() > 0) { + hash = (37 * hash) + MACHINE_TYPES_FIELD_NUMBER; + hash = (53 * hash) + getMachineTypesList().hashCode(); + } + if (hasRank()) { + hash = (37 * hash) + RANK_FIELD_NUMBER; + hash = (53 * hash) + getRank(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +     * Defines an instance selection for a given instance flexibility policy.
                      +     * 
                      + * + * Protobuf type {@code google.cloud.batch.v1.AllocationPolicy.InstanceSelection} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.batch.v1.AllocationPolicy.InstanceSelection) + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelectionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.batch.v1.JobProto + .internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceSelection_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.batch.v1.JobProto + .internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceSelection_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.class, + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.Builder.class); + } + + // Construct using com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + machineTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + rank_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.batch.v1.JobProto + .internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceSelection_descriptor; + } + + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection + getDefaultInstanceForType() { + return com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection build() { + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection buildPartial() { + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection result = + new com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + machineTypes_.makeImmutable(); + result.machineTypes_ = machineTypes_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.rank_ = rank_; + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection) { + return mergeFrom((com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection other) { + if (other + == com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection.getDefaultInstance()) + return this; + if (!other.machineTypes_.isEmpty()) { + if (machineTypes_.isEmpty()) { + machineTypes_ = other.machineTypes_; + bitField0_ |= 0x00000001; + } else { + ensureMachineTypesIsMutable(); + machineTypes_.addAll(other.machineTypes_); + } + onChanged(); + } + if (other.hasRank()) { + setRank(other.getRank()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureMachineTypesIsMutable(); + machineTypes_.add(s); + break; + } // case 10 + case 16: + { + rank_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringArrayList machineTypes_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureMachineTypesIsMutable() { + if (!machineTypes_.isModifiable()) { + machineTypes_ = new com.google.protobuf.LazyStringArrayList(machineTypes_); + } + bitField0_ |= 0x00000001; + } + + /** + * + * + *
                      +       * Required. The Compute Engine machine type IDs.
                      +       * Only the machine type ID is supported, such as `n1-standard-16`.
                      +       * Full or partial URLs are not accepted.
                      +       * The total maximum number of machine types across all instance selections
                      +       * is 200. Exceeding this limit results in a validation error with code
                      +       * `INVALID_ARGUMENT`.
                      +       * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return A list containing the machineTypes. + */ + public com.google.protobuf.ProtocolStringList getMachineTypesList() { + machineTypes_.makeImmutable(); + return machineTypes_; + } + + /** + * + * + *
                      +       * Required. The Compute Engine machine type IDs.
                      +       * Only the machine type ID is supported, such as `n1-standard-16`.
                      +       * Full or partial URLs are not accepted.
                      +       * The total maximum number of machine types across all instance selections
                      +       * is 200. Exceeding this limit results in a validation error with code
                      +       * `INVALID_ARGUMENT`.
                      +       * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The count of machineTypes. + */ + public int getMachineTypesCount() { + return machineTypes_.size(); + } + + /** + * + * + *
                      +       * Required. The Compute Engine machine type IDs.
                      +       * Only the machine type ID is supported, such as `n1-standard-16`.
                      +       * Full or partial URLs are not accepted.
                      +       * The total maximum number of machine types across all instance selections
                      +       * is 200. Exceeding this limit results in a validation error with code
                      +       * `INVALID_ARGUMENT`.
                      +       * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the element to return. + * @return The machineTypes at the given index. + */ + public java.lang.String getMachineTypes(int index) { + return machineTypes_.get(index); + } + + /** + * + * + *
                      +       * Required. The Compute Engine machine type IDs.
                      +       * Only the machine type ID is supported, such as `n1-standard-16`.
                      +       * Full or partial URLs are not accepted.
                      +       * The total maximum number of machine types across all instance selections
                      +       * is 200. Exceeding this limit results in a validation error with code
                      +       * `INVALID_ARGUMENT`.
                      +       * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the value to return. + * @return The bytes of the machineTypes at the given index. + */ + public com.google.protobuf.ByteString getMachineTypesBytes(int index) { + return machineTypes_.getByteString(index); + } + + /** + * + * + *
                      +       * Required. The Compute Engine machine type IDs.
                      +       * Only the machine type ID is supported, such as `n1-standard-16`.
                      +       * Full or partial URLs are not accepted.
                      +       * The total maximum number of machine types across all instance selections
                      +       * is 200. Exceeding this limit results in a validation error with code
                      +       * `INVALID_ARGUMENT`.
                      +       * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index to set the value at. + * @param value The machineTypes to set. + * @return This builder for chaining. + */ + public Builder setMachineTypes(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureMachineTypesIsMutable(); + machineTypes_.set(index, value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. The Compute Engine machine type IDs.
                      +       * Only the machine type ID is supported, such as `n1-standard-16`.
                      +       * Full or partial URLs are not accepted.
                      +       * The total maximum number of machine types across all instance selections
                      +       * is 200. Exceeding this limit results in a validation error with code
                      +       * `INVALID_ARGUMENT`.
                      +       * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The machineTypes to add. + * @return This builder for chaining. + */ + public Builder addMachineTypes(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureMachineTypesIsMutable(); + machineTypes_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. The Compute Engine machine type IDs.
                      +       * Only the machine type ID is supported, such as `n1-standard-16`.
                      +       * Full or partial URLs are not accepted.
                      +       * The total maximum number of machine types across all instance selections
                      +       * is 200. Exceeding this limit results in a validation error with code
                      +       * `INVALID_ARGUMENT`.
                      +       * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param values The machineTypes to add. + * @return This builder for chaining. + */ + public Builder addAllMachineTypes(java.lang.Iterable values) { + ensureMachineTypesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, machineTypes_); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. The Compute Engine machine type IDs.
                      +       * Only the machine type ID is supported, such as `n1-standard-16`.
                      +       * Full or partial URLs are not accepted.
                      +       * The total maximum number of machine types across all instance selections
                      +       * is 200. Exceeding this limit results in a validation error with code
                      +       * `INVALID_ARGUMENT`.
                      +       * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearMachineTypes() { + machineTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + ; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Required. The Compute Engine machine type IDs.
                      +       * Only the machine type ID is supported, such as `n1-standard-16`.
                      +       * Full or partial URLs are not accepted.
                      +       * The total maximum number of machine types across all instance selections
                      +       * is 200. Exceeding this limit results in a validation error with code
                      +       * `INVALID_ARGUMENT`.
                      +       * 
                      + * + * repeated string machine_types = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes of the machineTypes to add. + * @return This builder for chaining. + */ + public Builder addMachineTypesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureMachineTypesIsMutable(); + machineTypes_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int rank_; + + /** + * + * + *
                      +       * Optional. Indicates the preference of this instance selection. Lower
                      +       * number means higher preference. First try is to create a VM based on the
                      +       * machine-type with lowest rank and fallback to next rank based on
                      +       * availability. Machine types and instance selections with the same rank
                      +       * have the same preference.
                      +       * 
                      + * + * optional int32 rank = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the rank field is set. + */ + @java.lang.Override + public boolean hasRank() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +       * Optional. Indicates the preference of this instance selection. Lower
                      +       * number means higher preference. First try is to create a VM based on the
                      +       * machine-type with lowest rank and fallback to next rank based on
                      +       * availability. Machine types and instance selections with the same rank
                      +       * have the same preference.
                      +       * 
                      + * + * optional int32 rank = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The rank. + */ + @java.lang.Override + public int getRank() { + return rank_; + } + + /** + * + * + *
                      +       * Optional. Indicates the preference of this instance selection. Lower
                      +       * number means higher preference. First try is to create a VM based on the
                      +       * machine-type with lowest rank and fallback to next rank based on
                      +       * availability. Machine types and instance selections with the same rank
                      +       * have the same preference.
                      +       * 
                      + * + * optional int32 rank = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The rank to set. + * @return This builder for chaining. + */ + public Builder setRank(int value) { + + rank_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +       * Optional. Indicates the preference of this instance selection. Lower
                      +       * number means higher preference. First try is to create a VM based on the
                      +       * machine-type with lowest rank and fallback to next rank based on
                      +       * availability. Machine types and instance selections with the same rank
                      +       * have the same preference.
                      +       * 
                      + * + * optional int32 rank = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearRank() { + bitField0_ = (bitField0_ & ~0x00000002); + rank_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.batch.v1.AllocationPolicy.InstanceSelection) + } + + // @@protoc_insertion_point(class_scope:google.cloud.batch.v1.AllocationPolicy.InstanceSelection) + private static final com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection(); + } + + public static com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public InstanceSelection parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceSelection + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + private int bitField0_; public static final int LOCATION_FIELD_NUMBER = 1; private com.google.cloud.batch.v1.AllocationPolicy.LocationPolicy location_; @@ -14317,6 +16457,74 @@ public com.google.protobuf.ByteString getTagsBytes(int index) { return tags_.getByteString(index); } + public static final int INSTANCE_FLEXIBILITY_POLICY_FIELD_NUMBER = 12; + private com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + instanceFlexibilityPolicy_; + + /** + * + * + *
                      +   * Optional. The instance flexibility policy for the job. This configuration
                      +   * overrides the `instances` configuration. Only allowed in job level. Not
                      +   * allowed in task group level.
                      +   * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the instanceFlexibilityPolicy field is set. + */ + @java.lang.Override + public boolean hasInstanceFlexibilityPolicy() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
                      +   * Optional. The instance flexibility policy for the job. This configuration
                      +   * overrides the `instances` configuration. Only allowed in job level. Not
                      +   * allowed in task group level.
                      +   * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The instanceFlexibilityPolicy. + */ + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + getInstanceFlexibilityPolicy() { + return instanceFlexibilityPolicy_ == null + ? com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.getDefaultInstance() + : instanceFlexibilityPolicy_; + } + + /** + * + * + *
                      +   * Optional. The instance flexibility policy for the job. This configuration
                      +   * overrides the `instances` configuration. Only allowed in job level. Not
                      +   * allowed in task group level.
                      +   * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicyOrBuilder + getInstanceFlexibilityPolicyOrBuilder() { + return instanceFlexibilityPolicy_ == null + ? com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.getDefaultInstance() + : instanceFlexibilityPolicy_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -14351,6 +16559,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < tags_.size(); i++) { com.google.protobuf.GeneratedMessage.writeString(output, 11, tags_.getRaw(i)); } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeMessage(12, getInstanceFlexibilityPolicy()); + } getUnknownFields().writeTo(output); } @@ -14393,6 +16604,11 @@ public int getSerializedSize() { size += dataSize; size += 1 * getTagsList().size(); } + if (((bitField0_ & 0x00000010) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 12, getInstanceFlexibilityPolicy()); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -14428,6 +16644,11 @@ public boolean equals(final java.lang.Object obj) { if (!getPlacement().equals(other.getPlacement())) return false; } if (!getTagsList().equals(other.getTagsList())) return false; + if (hasInstanceFlexibilityPolicy() != other.hasInstanceFlexibilityPolicy()) return false; + if (hasInstanceFlexibilityPolicy()) { + if (!getInstanceFlexibilityPolicy().equals(other.getInstanceFlexibilityPolicy())) + return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -14467,6 +16688,10 @@ public int hashCode() { hash = (37 * hash) + TAGS_FIELD_NUMBER; hash = (53 * hash) + getTagsList().hashCode(); } + if (hasInstanceFlexibilityPolicy()) { + hash = (37 * hash) + INSTANCE_FLEXIBILITY_POLICY_FIELD_NUMBER; + hash = (53 * hash) + getInstanceFlexibilityPolicy().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -14636,6 +16861,7 @@ private void maybeForceBuilderInitialization() { internalGetServiceAccountFieldBuilder(); internalGetNetworkFieldBuilder(); internalGetPlacementFieldBuilder(); + internalGetInstanceFlexibilityPolicyFieldBuilder(); } } @@ -14672,6 +16898,11 @@ public Builder clear() { placementBuilder_ = null; } tags_ = com.google.protobuf.LazyStringArrayList.emptyList(); + instanceFlexibilityPolicy_ = null; + if (instanceFlexibilityPolicyBuilder_ != null) { + instanceFlexibilityPolicyBuilder_.dispose(); + instanceFlexibilityPolicyBuilder_ = null; + } return this; } @@ -14747,6 +16978,13 @@ private void buildPartial0(com.google.cloud.batch.v1.AllocationPolicy result) { tags_.makeImmutable(); result.tags_ = tags_; } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.instanceFlexibilityPolicy_ = + instanceFlexibilityPolicyBuilder_ == null + ? instanceFlexibilityPolicy_ + : instanceFlexibilityPolicyBuilder_.build(); + to_bitField0_ |= 0x00000010; + } result.bitField0_ |= to_bitField0_; } @@ -14813,6 +17051,9 @@ public Builder mergeFrom(com.google.cloud.batch.v1.AllocationPolicy other) { } onChanged(); } + if (other.hasInstanceFlexibilityPolicy()) { + mergeInstanceFlexibilityPolicy(other.getInstanceFlexibilityPolicy()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -14900,6 +17141,14 @@ public Builder mergeFrom( tags_.add(s); break; } // case 90 + case 98: + { + input.readMessage( + internalGetInstanceFlexibilityPolicyFieldBuilder().getBuilder(), + extensionRegistry); + bitField0_ |= 0x00000080; + break; + } // case 98 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -16740,6 +18989,248 @@ public Builder addTagsBytes(com.google.protobuf.ByteString value) { return this; } + private com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + instanceFlexibilityPolicy_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy, + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.Builder, + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicyOrBuilder> + instanceFlexibilityPolicyBuilder_; + + /** + * + * + *
                      +     * Optional. The instance flexibility policy for the job. This configuration
                      +     * overrides the `instances` configuration. Only allowed in job level. Not
                      +     * allowed in task group level.
                      +     * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the instanceFlexibilityPolicy field is set. + */ + public boolean hasInstanceFlexibilityPolicy() { + return ((bitField0_ & 0x00000080) != 0); + } + + /** + * + * + *
                      +     * Optional. The instance flexibility policy for the job. This configuration
                      +     * overrides the `instances` configuration. Only allowed in job level. Not
                      +     * allowed in task group level.
                      +     * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The instanceFlexibilityPolicy. + */ + public com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + getInstanceFlexibilityPolicy() { + if (instanceFlexibilityPolicyBuilder_ == null) { + return instanceFlexibilityPolicy_ == null + ? com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + .getDefaultInstance() + : instanceFlexibilityPolicy_; + } else { + return instanceFlexibilityPolicyBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The instance flexibility policy for the job. This configuration
                      +     * overrides the `instances` configuration. Only allowed in job level. Not
                      +     * allowed in task group level.
                      +     * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setInstanceFlexibilityPolicy( + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy value) { + if (instanceFlexibilityPolicyBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + instanceFlexibilityPolicy_ = value; + } else { + instanceFlexibilityPolicyBuilder_.setMessage(value); + } + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The instance flexibility policy for the job. This configuration
                      +     * overrides the `instances` configuration. Only allowed in job level. Not
                      +     * allowed in task group level.
                      +     * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setInstanceFlexibilityPolicy( + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.Builder + builderForValue) { + if (instanceFlexibilityPolicyBuilder_ == null) { + instanceFlexibilityPolicy_ = builderForValue.build(); + } else { + instanceFlexibilityPolicyBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The instance flexibility policy for the job. This configuration
                      +     * overrides the `instances` configuration. Only allowed in job level. Not
                      +     * allowed in task group level.
                      +     * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeInstanceFlexibilityPolicy( + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy value) { + if (instanceFlexibilityPolicyBuilder_ == null) { + if (((bitField0_ & 0x00000080) != 0) + && instanceFlexibilityPolicy_ != null + && instanceFlexibilityPolicy_ + != com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + .getDefaultInstance()) { + getInstanceFlexibilityPolicyBuilder().mergeFrom(value); + } else { + instanceFlexibilityPolicy_ = value; + } + } else { + instanceFlexibilityPolicyBuilder_.mergeFrom(value); + } + if (instanceFlexibilityPolicy_ != null) { + bitField0_ |= 0x00000080; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The instance flexibility policy for the job. This configuration
                      +     * overrides the `instances` configuration. Only allowed in job level. Not
                      +     * allowed in task group level.
                      +     * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearInstanceFlexibilityPolicy() { + bitField0_ = (bitField0_ & ~0x00000080); + instanceFlexibilityPolicy_ = null; + if (instanceFlexibilityPolicyBuilder_ != null) { + instanceFlexibilityPolicyBuilder_.dispose(); + instanceFlexibilityPolicyBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The instance flexibility policy for the job. This configuration
                      +     * overrides the `instances` configuration. Only allowed in job level. Not
                      +     * allowed in task group level.
                      +     * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.Builder + getInstanceFlexibilityPolicyBuilder() { + bitField0_ |= 0x00000080; + onChanged(); + return internalGetInstanceFlexibilityPolicyFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The instance flexibility policy for the job. This configuration
                      +     * overrides the `instances` configuration. Only allowed in job level. Not
                      +     * allowed in task group level.
                      +     * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicyOrBuilder + getInstanceFlexibilityPolicyOrBuilder() { + if (instanceFlexibilityPolicyBuilder_ != null) { + return instanceFlexibilityPolicyBuilder_.getMessageOrBuilder(); + } else { + return instanceFlexibilityPolicy_ == null + ? com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + .getDefaultInstance() + : instanceFlexibilityPolicy_; + } + } + + /** + * + * + *
                      +     * Optional. The instance flexibility policy for the job. This configuration
                      +     * overrides the `instances` configuration. Only allowed in job level. Not
                      +     * allowed in task group level.
                      +     * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy, + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.Builder, + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicyOrBuilder> + internalGetInstanceFlexibilityPolicyFieldBuilder() { + if (instanceFlexibilityPolicyBuilder_ == null) { + instanceFlexibilityPolicyBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy, + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy.Builder, + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicyOrBuilder>( + getInstanceFlexibilityPolicy(), getParentForChildren(), isClean()); + instanceFlexibilityPolicy_ = null; + } + return instanceFlexibilityPolicyBuilder_; + } + // @@protoc_insertion_point(builder_scope:google.cloud.batch.v1.AllocationPolicy) } diff --git a/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/AllocationPolicyOrBuilder.java b/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/AllocationPolicyOrBuilder.java index f02663b271db..e81a94919597 100644 --- a/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/AllocationPolicyOrBuilder.java +++ b/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/AllocationPolicyOrBuilder.java @@ -467,4 +467,55 @@ java.lang.String getLabelsOrDefault( * @return The bytes of the tags at the given index. */ com.google.protobuf.ByteString getTagsBytes(int index); + + /** + * + * + *
                      +   * Optional. The instance flexibility policy for the job. This configuration
                      +   * overrides the `instances` configuration. Only allowed in job level. Not
                      +   * allowed in task group level.
                      +   * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the instanceFlexibilityPolicy field is set. + */ + boolean hasInstanceFlexibilityPolicy(); + + /** + * + * + *
                      +   * Optional. The instance flexibility policy for the job. This configuration
                      +   * overrides the `instances` configuration. Only allowed in job level. Not
                      +   * allowed in task group level.
                      +   * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The instanceFlexibilityPolicy. + */ + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy + getInstanceFlexibilityPolicy(); + + /** + * + * + *
                      +   * Optional. The instance flexibility policy for the job. This configuration
                      +   * overrides the `instances` configuration. Only allowed in job level. Not
                      +   * allowed in task group level.
                      +   * 
                      + * + * + * .google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicy instance_flexibility_policy = 12 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.batch.v1.AllocationPolicy.InstanceFlexibilityPolicyOrBuilder + getInstanceFlexibilityPolicyOrBuilder(); } diff --git a/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/JobProto.java b/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/JobProto.java index e9f23e38c83a..a0a27d336a2c 100644 --- a/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/JobProto.java +++ b/java-batch/proto-google-cloud-batch-v1/src/main/java/com/google/cloud/batch/v1/JobProto.java @@ -124,6 +124,18 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_batch_v1_AllocationPolicy_PlacementPolicy_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_batch_v1_AllocationPolicy_PlacementPolicy_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_InstanceSelectionsEntry_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_InstanceSelectionsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceSelection_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceSelection_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_batch_v1_AllocationPolicy_LabelsEntry_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -229,7 +241,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004Type\022\024\n" + "\020TYPE_UNSPECIFIED\020\000\022\025\n" + "\021JOB_STATE_CHANGED\020\001\022\026\n" - + "\022TASK_STATE_CHANGED\020\002\"\345\020\n" + + "\022TASK_STATE_CHANGED\020\002\"\271\024\n" + "\020AllocationPolicy\022H\n" + "\010location\030\001 \001(\01326.google.cloud" + ".batch.v1.AllocationPolicy.LocationPolicy\022S\n" @@ -242,7 +254,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "oogle.cloud.batch.v1.AllocationPolicy.NetworkPolicy\022J\n" + "\tplacement\030\n" + " \001(\01327.google.cloud.batch.v1.AllocationPolicy.PlacementPolicy\022\022\n" - + "\004tags\030\013 \003(\tB\004\342A\001\001\032+\n" + + "\004tags\030\013 \003(\tB\004\342A\001\001\022l\n" + + "\033instance_flexibility_policy\030\014 \001(\0132A.google.cloud." + + "batch.v1.AllocationPolicy.InstanceFlexibilityPolicyB\004\342A\001\001\032+\n" + "\016LocationPolicy\022\031\n" + "\021allowed_locations\030\001 \003(\t\032q\n" + "\004Disk\022\017\n" @@ -266,17 +280,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016InstancePolicy\022\024\n" + "\014machine_type\030\002 \001(\t\022\030\n" + "\020min_cpu_platform\030\003 \001(\t\022U\n" - + "\022provisioning_model\030\004" - + " \001(\01629.google.cloud.batch.v1.AllocationPolicy.ProvisioningModel\022I\n" - + "\014accelerators\030\005" - + " \003(\01323.google.cloud.batch.v1.AllocationPolicy.Accelerator\022?\n" + + "\022provisioning_model\030\004 \001(\016" + + "29.google.cloud.batch.v1.AllocationPolicy.ProvisioningModel\022I\n" + + "\014accelerators\030\005 \003(" + + "\01323.google.cloud.batch.v1.AllocationPolicy.Accelerator\022?\n" + "\tboot_disk\030\010 \001(\0132,.google.cloud.batch.v1.AllocationPolicy.Disk\022C\n" - + "\005disks\030\006 \003(\01324.google.cloud." - + "batch.v1.AllocationPolicy.AttachedDisk\022\031\n" + + "\005disks\030\006" + + " \003(\01324.google.cloud.batch.v1.AllocationPolicy.AttachedDisk\022\031\n" + "\013reservation\030\007 \001(\tB\004\342A\001\001\032\370\001\n" + "\030InstancePolicyOrTemplate\022H\n" - + "\006policy\030\001 \001(\01326.google." - + "cloud.batch.v1.AllocationPolicy.InstancePolicyH\000\022\033\n" + + "\006policy\030\001 \001(\01326.google.cloud.batc" + + "h.v1.AllocationPolicy.InstancePolicyH\000\022\033\n" + "\021instance_template\030\002 \001(\tH\000\022\033\n" + "\023install_gpu_drivers\030\003 \001(\010\022\037\n" + "\021install_ops_agent\030\004 \001(\010B\004\342A\001\001\022$\n" @@ -286,8 +300,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\007network\030\001 \001(\t\022\022\n\n" + "subnetwork\030\002 \001(\t\022\036\n" + "\026no_external_ip_address\030\003 \001(\010\022]\n" - + "\010nic_type\030\007 \001(\0162@.google.cloud." - + "batch.v1.AllocationPolicy.NetworkInterface.NicTypeB\004\342A\001\001H\000\210\001\001\"D\n" + + "\010nic_type\030\007 \001(\0162@.google.cloud.batch.v1.A" + + "llocationPolicy.NetworkInterface.NicTypeB\004\342A\001\001H\000\210\001\001\"D\n" + "\007NicType\022\030\n" + "\024NIC_TYPE_UNSPECIFIED\020\000\022\t\n" + "\005GVNIC\020\001\022\t\n" @@ -295,11 +309,22 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005MRDMA\020\003B\013\n" + "\t_nic_type\032e\n\r" + "NetworkPolicy\022T\n" - + "\022network_interfaces\030\001 \003(\01328.google.c" - + "loud.batch.v1.AllocationPolicy.NetworkInterface\032<\n" + + "\022network_interfaces\030\001" + + " \003(\01328.google.cloud.batch.v1.AllocationPolicy.NetworkInterface\032<\n" + "\017PlacementPolicy\022\023\n" + "\013collocation\030\001 \001(\t\022\024\n" - + "\014max_distance\030\002 \001(\003\032-\n" + + "\014max_distance\030\002 \001(\003\032\217\002\n" + + "\031InstanceFlexibilityPolicy\022|\n" + + "\023instance_selections\030\001 \003(\0132Y.google.cloud.batch.v1.AllocationPolicy." + + "InstanceFlexibilityPolicy.InstanceSelectionsEntryB\004\342A\001\002\032t\n" + + "\027InstanceSelectionsEntry\022\013\n" + + "\003key\030\001 \001(\t\022H\n" + + "\005value\030\002 \001(\01329.google." + + "cloud.batch.v1.AllocationPolicy.InstanceSelection:\0028\001\032R\n" + + "\021InstanceSelection\022\033\n\r" + + "machine_types\030\001 \003(\tB\004\342A\001\002\022\027\n" + + "\004rank\030\002 \001(\005B\004\342A\001\001H\000\210\001\001B\007\n" + + "\005_rank\032-\n" + "\013LabelsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001\"\213\001\n" @@ -328,15 +353,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\035SCHEDULING_POLICY_UNSPECIFIED\020\000\022\027\n" + "\023AS_SOON_AS_POSSIBLE\020\001\022\014\n" + "\010IN_ORDER\020\002:o\352Al\n" - + "\036batch.googleapis.com/TaskGroup\022Jprojects/{project}/loca" - + "tions/{location}/jobs/{job}/taskGroups/{task_group}\"/\n" + + "\036batch.googleapis.com/TaskGroup\022Jprojects/{project}/locations/{locat" + + "ion}/jobs/{job}/taskGroups/{task_group}\"/\n" + "\016ServiceAccount\022\r\n" + "\005email\030\001 \001(\t\022\016\n" + "\006scopes\030\002 \003(\tB\251\001\n" - + "\031com.google.cloud.batch.v1B\010JobProtoP\001Z/cloud.google.com" - + "/go/batch/apiv1/batchpb;batchpb\242\002\003GCB\252\002\025" - + "Google.Cloud.Batch.V1\312\002\025Google\\Cloud\\Bat" - + "ch\\V1\352\002\030Google::Cloud::Batch::V1b\006proto3" + + "\031com.google.cloud.batch.v1B\010JobProtoP\001Z/cloud.google.com/go/batch/ap" + + "iv1/batchpb;batchpb\242\002\003GCB\252\002\025Google.Cloud" + + ".Batch.V1\312\002\025Google\\Cloud\\Batch\\V1\352\002\030Goog" + + "le::Cloud::Batch::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -449,7 +474,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_batch_v1_AllocationPolicy_descriptor, new java.lang.String[] { - "Location", "Instances", "ServiceAccount", "Labels", "Network", "Placement", "Tags", + "Location", + "Instances", + "ServiceAccount", + "Labels", + "Network", + "Placement", + "Tags", + "InstanceFlexibilityPolicy", }); internal_static_google_cloud_batch_v1_AllocationPolicy_LocationPolicy_descriptor = internal_static_google_cloud_batch_v1_AllocationPolicy_descriptor.getNestedType(0); @@ -534,8 +566,33 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Collocation", "MaxDistance", }); - internal_static_google_cloud_batch_v1_AllocationPolicy_LabelsEntry_descriptor = + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_descriptor = internal_static_google_cloud_batch_v1_AllocationPolicy_descriptor.getNestedType(9); + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_descriptor, + new java.lang.String[] { + "InstanceSelections", + }); + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_InstanceSelectionsEntry_descriptor = + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_descriptor + .getNestedType(0); + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_InstanceSelectionsEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceFlexibilityPolicy_InstanceSelectionsEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceSelection_descriptor = + internal_static_google_cloud_batch_v1_AllocationPolicy_descriptor.getNestedType(10); + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceSelection_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_batch_v1_AllocationPolicy_InstanceSelection_descriptor, + new java.lang.String[] { + "MachineTypes", "Rank", + }); + internal_static_google_cloud_batch_v1_AllocationPolicy_LabelsEntry_descriptor = + internal_static_google_cloud_batch_v1_AllocationPolicy_descriptor.getNestedType(11); internal_static_google_cloud_batch_v1_AllocationPolicy_LabelsEntry_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_batch_v1_AllocationPolicy_LabelsEntry_descriptor, diff --git a/java-batch/proto-google-cloud-batch-v1/src/main/proto/google/cloud/batch/v1/job.proto b/java-batch/proto-google-cloud-batch-v1/src/main/proto/google/cloud/batch/v1/job.proto index d4bae45fbf3a..89abec2a7929 100644 --- a/java-batch/proto-google-cloud-batch-v1/src/main/proto/google/cloud/batch/v1/job.proto +++ b/java-batch/proto-google-cloud-batch-v1/src/main/proto/google/cloud/batch/v1/job.proto @@ -572,6 +572,40 @@ message AllocationPolicy { int64 max_distance = 2; } + // Allows creating VMs from multiple types of machines. Instance flexibility + // configuration overrides instances configuration. + message InstanceFlexibilityPolicy { + // Required. Named instance selections configuring properties that the group + // will use when creating new VMs. The map key is a user-specified name for + // the instance selection. The key must be 1-63 characters long, and comply + // with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). Specifically, the + // key must consist of lowercase letters, numbers, and hyphens. The first + // character must be a lowercase letter, and the last character must be a + // lowercase letter or number. + // The maximum number of instance selections is 50. Exceeding this limit + // results in a validation error with code `INVALID_ARGUMENT`. + map instance_selections = 1 + [(google.api.field_behavior) = REQUIRED]; + } + + // Defines an instance selection for a given instance flexibility policy. + message InstanceSelection { + // Required. The Compute Engine machine type IDs. + // Only the machine type ID is supported, such as `n1-standard-16`. + // Full or partial URLs are not accepted. + // The total maximum number of machine types across all instance selections + // is 200. Exceeding this limit results in a validation error with code + // `INVALID_ARGUMENT`. + repeated string machine_types = 1 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Indicates the preference of this instance selection. Lower + // number means higher preference. First try is to create a VM based on the + // machine-type with lowest rank and fallback to next rank based on + // availability. Machine types and instance selections with the same rank + // have the same preference. + optional int32 rank = 2 [(google.api.field_behavior) = OPTIONAL]; + } + // Compute Engine VM instance provisioning model. enum ProvisioningModel { // Unspecified. @@ -648,6 +682,12 @@ message AllocationPolicy { // Each tag must be 1-63 characters long, and comply with // [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). repeated string tags = 11 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The instance flexibility policy for the job. This configuration + // overrides the `instances` configuration. Only allowed in job level. Not + // allowed in task group level. + InstanceFlexibilityPolicy instance_flexibility_policy = 12 + [(google.api.field_behavior) = OPTIONAL]; } // A TaskGroup defines one or more Tasks that all share the same TaskSpec. diff --git a/java-beyondcorp-appconnections/README.md b/java-beyondcorp-appconnections/README.md index 3a2d8460d353..cd7fefc7f027 100644 --- a/java-beyondcorp-appconnections/README.md +++ b/java-beyondcorp-appconnections/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-beyondcorp-appconnections - 0.100.0 + 0.101.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-beyondcorp-appconnections' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-beyondcorp-appconnections:0.100.0' +implementation 'com.google.cloud:google-cloud-beyondcorp-appconnections:0.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-beyondcorp-appconnections" % "0.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-beyondcorp-appconnections" % "0.101.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-beyondcorp-appconnections/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-beyondcorp-appconnections.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-beyondcorp-appconnections/0.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-beyondcorp-appconnections/0.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-beyondcorp-appconnectors/README.md b/java-beyondcorp-appconnectors/README.md index c2d5d6e0adbe..9ff86e08501d 100644 --- a/java-beyondcorp-appconnectors/README.md +++ b/java-beyondcorp-appconnectors/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-beyondcorp-appconnectors - 0.100.0 + 0.101.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-beyondcorp-appconnectors' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-beyondcorp-appconnectors:0.100.0' +implementation 'com.google.cloud:google-cloud-beyondcorp-appconnectors:0.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-beyondcorp-appconnectors" % "0.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-beyondcorp-appconnectors" % "0.101.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-beyondcorp-appconnectors/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-beyondcorp-appconnectors.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-beyondcorp-appconnectors/0.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-beyondcorp-appconnectors/0.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-beyondcorp-appgateways/README.md b/java-beyondcorp-appgateways/README.md index cb74ab1ddbe2..4270f93544f5 100644 --- a/java-beyondcorp-appgateways/README.md +++ b/java-beyondcorp-appgateways/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-beyondcorp-appgateways - 0.100.0 + 0.101.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-beyondcorp-appgateways' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-beyondcorp-appgateways:0.100.0' +implementation 'com.google.cloud:google-cloud-beyondcorp-appgateways:0.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-beyondcorp-appgateways" % "0.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-beyondcorp-appgateways" % "0.101.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-beyondcorp-appgateways/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-beyondcorp-appgateways.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-beyondcorp-appgateways/0.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-beyondcorp-appgateways/0.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-beyondcorp-clientconnectorservices/README.md b/java-beyondcorp-clientconnectorservices/README.md index fdb2ce8610a6..29e067a491b0 100644 --- a/java-beyondcorp-clientconnectorservices/README.md +++ b/java-beyondcorp-clientconnectorservices/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-beyondcorp-clientconnectorservices - 0.100.0 + 0.101.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-beyondcorp-clientconnectorservices If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-beyondcorp-clientconnectorservices:0.100.0' +implementation 'com.google.cloud:google-cloud-beyondcorp-clientconnectorservices:0.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-beyondcorp-clientconnectorservices" % "0.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-beyondcorp-clientconnectorservices" % "0.101.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-beyondcorp-clientconnectorservices/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-beyondcorp-clientconnectorservices.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-beyondcorp-clientconnectorservices/0.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-beyondcorp-clientconnectorservices/0.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-beyondcorp-clientgateways/README.md b/java-beyondcorp-clientgateways/README.md index 71565e64a971..d7e6f4aef718 100644 --- a/java-beyondcorp-clientgateways/README.md +++ b/java-beyondcorp-clientgateways/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-beyondcorp-clientgateways - 0.100.0 + 0.101.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-beyondcorp-clientgateways' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-beyondcorp-clientgateways:0.100.0' +implementation 'com.google.cloud:google-cloud-beyondcorp-clientgateways:0.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-beyondcorp-clientgateways" % "0.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-beyondcorp-clientgateways" % "0.101.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-beyondcorp-clientgateways/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-beyondcorp-clientgateways.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-beyondcorp-clientgateways/0.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-beyondcorp-clientgateways/0.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-biglake-hive/README.md b/java-biglake-hive/README.md index a48a1e4b8808..749a819d385b 100644 --- a/java-biglake-hive/README.md +++ b/java-biglake-hive/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-biglake-hive - 0.7.0 + 0.8.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-biglake-hive' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-biglake-hive:0.7.0' +implementation 'com.google.cloud:google-cloud-biglake-hive:0.8.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-biglake-hive" % "0.7.0" +libraryDependencies += "com.google.cloud" % "google-cloud-biglake-hive" % "0.8.0" ``` ## Authentication @@ -195,7 +195,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-biglake-hive/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-biglake-hive.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-biglake-hive/0.7.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-biglake-hive/0.8.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-biglake/README.md b/java-biglake/README.md index 0e2968535ef1..46c9f45c5125 100644 --- a/java-biglake/README.md +++ b/java-biglake/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-biglake - 0.90.0 + 0.91.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-biglake' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-biglake:0.90.0' +implementation 'com.google.cloud:google-cloud-biglake:0.91.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-biglake" % "0.90.0" +libraryDependencies += "com.google.cloud" % "google-cloud-biglake" % "0.91.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-biglake/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-biglake.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-biglake/0.90.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-biglake/0.91.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-bigquery-data-exchange/README.md b/java-bigquery-data-exchange/README.md index 19d974ec72da..946ed0849bbb 100644 --- a/java-bigquery-data-exchange/README.md +++ b/java-bigquery-data-exchange/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-bigquery-data-exchange - 2.97.0 + 2.98.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-bigquery-data-exchange' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-bigquery-data-exchange:2.97.0' +implementation 'com.google.cloud:google-cloud-bigquery-data-exchange:2.98.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-bigquery-data-exchange" % "2.97.0" +libraryDependencies += "com.google.cloud" % "google-cloud-bigquery-data-exchange" % "2.98.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-bigquery-data-exchange/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-bigquery-data-exchange.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquery-data-exchange/2.97.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquery-data-exchange/2.98.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-bigqueryconnection/README.md b/java-bigqueryconnection/README.md index 9eed3cf71c93..2b80f76fe4fe 100644 --- a/java-bigqueryconnection/README.md +++ b/java-bigqueryconnection/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-bigqueryconnection - 2.104.0 + 2.105.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-bigqueryconnection' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-bigqueryconnection:2.104.0' +implementation 'com.google.cloud:google-cloud-bigqueryconnection:2.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-bigqueryconnection" % "2.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-bigqueryconnection" % "2.105.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/bigquery/docs/reference/reservations/rpc/google.cloud.bigquery.reservation.v1beta1 [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-bigqueryconnection.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigqueryconnection/2.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigqueryconnection/2.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-bigquerydatapolicy/README.md b/java-bigquerydatapolicy/README.md index 4d7bf5296bcd..dfa890144b40 100644 --- a/java-bigquerydatapolicy/README.md +++ b/java-bigquerydatapolicy/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-bigquerydatapolicy - 0.99.0 + 0.100.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-bigquerydatapolicy' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-bigquerydatapolicy:0.99.0' +implementation 'com.google.cloud:google-cloud-bigquerydatapolicy:0.100.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-bigquerydatapolicy" % "0.99.0" +libraryDependencies += "com.google.cloud" % "google-cloud-bigquerydatapolicy" % "0.100.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-bigquerydatapolicy/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-bigquerydatapolicy.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquerydatapolicy/0.99.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquerydatapolicy/0.100.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-bigquerydatatransfer/README.md b/java-bigquerydatatransfer/README.md index dacc1ca901f1..46a01a9df6c8 100644 --- a/java-bigquerydatatransfer/README.md +++ b/java-bigquerydatatransfer/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-bigquerydatatransfer - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-bigquerydatatransfer' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-bigquerydatatransfer:2.102.0' +implementation 'com.google.cloud:google-cloud-bigquerydatatransfer:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-bigquerydatatransfer" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-bigquerydatatransfer" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-bigquerydatatransfer/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-bigquerydatatransfer.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquerydatatransfer/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquerydatatransfer/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-bigquerymigration/README.md b/java-bigquerymigration/README.md index ef35c54723ba..b30934f67629 100644 --- a/java-bigquerymigration/README.md +++ b/java-bigquerymigration/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-bigquerymigration - 0.105.0 + 0.106.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-bigquerymigration' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-bigquerymigration:0.105.0' +implementation 'com.google.cloud:google-cloud-bigquerymigration:0.106.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-bigquerymigration" % "0.105.0" +libraryDependencies += "com.google.cloud" % "google-cloud-bigquerymigration" % "0.106.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-bigquerymigration/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-bigquerymigration.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquerymigration/0.105.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquerymigration/0.106.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-bigqueryreservation/README.md b/java-bigqueryreservation/README.md index 31a8ddd41e6a..b4641b9ec0ab 100644 --- a/java-bigqueryreservation/README.md +++ b/java-bigqueryreservation/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-bigqueryreservation - 2.103.0 + 2.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-bigqueryreservation' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-bigqueryreservation:2.103.0' +implementation 'com.google.cloud:google-cloud-bigqueryreservation:2.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-bigqueryreservation" % "2.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-bigqueryreservation" % "2.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-bigqueryreservation/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-bigqueryreservation.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigqueryreservation/2.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigqueryreservation/2.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-bigquerystorage/README.md b/java-bigquerystorage/README.md index 339527309e6a..b14498081754 100644 --- a/java-bigquerystorage/README.md +++ b/java-bigquerystorage/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-bigquerystorage - 3.38.0 + 3.39.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-bigquerystorage' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-bigquerystorage:3.38.0' +implementation 'com.google.cloud:google-cloud-bigquerystorage:3.39.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-bigquerystorage" % "3.38.0" +libraryDependencies += "com.google.cloud" % "google-cloud-bigquerystorage" % "3.39.0" ``` ## Authentication @@ -233,7 +233,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-bigquerystorage/latest/history [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-bigquerystorage.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquerystorage/3.38.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquerystorage/3.39.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-bigtable/README.md b/java-bigtable/README.md index 2f131b1cee87..a7292e34fb44 100644 --- a/java-bigtable/README.md +++ b/java-bigtable/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-bigtable - 2.88.0 + 2.89.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-bigtable' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-bigtable:2.88.0' +implementation 'com.google.cloud:google-cloud-bigtable:2.89.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-bigtable" % "2.88.0" +libraryDependencies += "com.google.cloud" % "google-cloud-bigtable" % "2.89.0" ``` ## Authentication @@ -369,10 +369,13 @@ Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-java/ | --------------------------- | --------------------------------- | ------ | | Authorized View Example | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/AuthorizedViewExample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/AuthorizedViewExample.java) | | Configure Connection Pool | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/ConfigureConnectionPool.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/ConfigureConnectionPool.java) | +| Delete Instance Async | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/DeleteInstanceAsync.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/DeleteInstanceAsync.java) | | Filters | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/Filters.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/Filters.java) | | Hello World | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/HelloWorld.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/HelloWorld.java) | | Instance Admin Example | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/InstanceAdminExample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/InstanceAdminExample.java) | | Key Salting | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/KeySalting.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/KeySalting.java) | +| List Clusters | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/ListClusters.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/ListClusters.java) | +| List Instances | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/ListInstances.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/ListInstances.java) | | Quickstart | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/Quickstart.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/Quickstart.java) | | Reads | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/Reads.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/Reads.java) | | Schema Bundle Example | [source code](https://github.com/googleapis/google-cloud-java/blob/main/samples/snippets/src/main/java/com/example/bigtable/SchemaBundleExample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-java&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/SchemaBundleExample.java) | @@ -472,7 +475,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-bigtable/latest/history [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-bigtable.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigtable/2.88.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigtable/2.89.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfile.java b/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfile.java index 69869bc3052b..c0d64bc6cc1e 100644 --- a/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfile.java +++ b/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfile.java @@ -5316,7 +5316,7 @@ public com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting getSingleClu * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @return Whether the priority field is set. */ @java.lang.Deprecated @@ -5337,7 +5337,7 @@ public boolean hasPriority() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @return The enum numeric value on the wire for priority. */ @java.lang.Deprecated @@ -5361,7 +5361,7 @@ public int getPriorityValue() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @return The priority. */ @java.lang.Deprecated @@ -6964,7 +6964,7 @@ public Builder clearSingleClusterRouting() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @return Whether the priority field is set. */ @java.lang.Override @@ -6986,7 +6986,7 @@ public boolean hasPriority() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @return The enum numeric value on the wire for priority. */ @java.lang.Override @@ -7011,7 +7011,7 @@ public int getPriorityValue() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @param value The enum numeric value on the wire for priority to set. * @return This builder for chaining. */ @@ -7036,7 +7036,7 @@ public Builder setPriorityValue(int value) { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @return The priority. */ @java.lang.Override @@ -7066,7 +7066,7 @@ public com.google.bigtable.admin.v2.AppProfile.Priority getPriority() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @param value The priority to set. * @return This builder for chaining. */ @@ -7094,7 +7094,7 @@ public Builder setPriority(com.google.bigtable.admin.v2.AppProfile.Priority valu * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @return This builder for chaining. */ @java.lang.Deprecated diff --git a/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfileOrBuilder.java b/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfileOrBuilder.java index 5b97739eb12f..3dc9029e3581 100644 --- a/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfileOrBuilder.java +++ b/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfileOrBuilder.java @@ -218,7 +218,7 @@ public interface AppProfileOrBuilder * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @return Whether the priority field is set. */ @java.lang.Deprecated @@ -237,7 +237,7 @@ public interface AppProfileOrBuilder * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @return The enum numeric value on the wire for priority. */ @java.lang.Deprecated @@ -256,7 +256,7 @@ public interface AppProfileOrBuilder * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=519 + * google/bigtable/admin/v2/instance.proto;l=516 * @return The priority. */ @java.lang.Deprecated diff --git a/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceProto.java b/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceProto.java index d90df6639706..454c073e2e91 100644 --- a/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceProto.java +++ b/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceProto.java @@ -220,43 +220,41 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\026NODE_SCALING_FACTOR_2X\020\002:x\352Au\n" + "$bigtableadmin.googleapis.com/Cluster\022:projects/{project}/in" + "stances/{instance}/clusters/{cluster}*\010clusters2\007clusterB\010\n" - + "\006config\"\331\003\n" + + "\006config\"\271\003\n" + "\013MemoryLayer\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022I\n\r" + "memory_config\030\002" + " \001(\01322.google.bigtable.admin.v2.MemoryLayer.MemoryConfig\022\022\n" + "\004etag\030\003 \001(\tB\004\342A\001\001\022@\n" + "\005state\030\004" - + " \001(\0162+.google.bigtable.admin.v2.MemoryLayer.StateB\004\342A\001\003\032.\n" - + "\014MemoryConfig\022\036\n" - + "\020storage_size_gib\030\002 \001(\005B\004\342A\001\003\"Q\n" + + " \001(\0162+.google.bigtable.admin.v2.MemoryLayer.StateB\004\342A\001\003\032\016\n" + + "\014MemoryConfig\"Q\n" + "\005State\022\023\n" + "\017STATE_NOT_KNOWN\020\000\022\t\n" + "\005READY\020\001\022\014\n" + "\010ENABLING\020\002\022\014\n" + "\010RESIZING\020\003\022\014\n" + "\010DISABLED\020\004:\221\001\352A\215\001\n" - + "(bigtableadmin.googleapis.com/MemoryLayer\022Fprojects/{project}/instances/{insta" - + "nce}/clusters/{cluster}/memoryLayer*\014memoryLayers2\013memoryLayer\"\340\013\n\n" + + "(bigtableadmin.googleapis.com/MemoryLayer\022Fprojects/{project}/instance" + + "s/{instance}/clusters/{cluster}/memoryLayer*\014memoryLayers2\013memoryLayer\"\340\013\n\n" + "AppProfile\022\014\n" + "\004name\030\001 \001(\t\022\014\n" + "\004etag\030\002 \001(\t\022\023\n" + "\013description\030\003 \001(\t\022g\n" - + "\035multi_cluster_routing_use_any\030\005" - + " \001(\0132>.google.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAnyH\000\022[\n" - + "\026single_cluster_routing\030\006 \001(\01329.google.bigtabl" - + "e.admin.v2.AppProfile.SingleClusterRoutingH\000\022E\n" - + "\010priority\030\007" - + " \001(\0162-.google.bigtable.admin.v2.AppProfile.PriorityB\002\030\001H\001\022T\n" - + "\022standard_isolation\030\013 \001(\01326.google.bigtabl" - + "e.admin.v2.AppProfile.StandardIsolationH\001\022i\n" + + "\035multi_cluster_routing_use_any\030\005 \001(\0132>.google.bigtable.admin.v2" + + ".AppProfile.MultiClusterRoutingUseAnyH\000\022[\n" + + "\026single_cluster_routing\030\006 \001(\01329.google" + + ".bigtable.admin.v2.AppProfile.SingleClusterRoutingH\000\022E\n" + + "\010priority\030\007 \001(\0162-.google." + + "bigtable.admin.v2.AppProfile.PriorityB\002\030\001H\001\022T\n" + + "\022standard_isolation\030\013 \001(\01326.google" + + ".bigtable.admin.v2.AppProfile.StandardIsolationH\001\022i\n" + "\036data_boost_isolation_read_only\030\n" - + " \001(" - + "\0132?.google.bigtable.admin.v2.AppProfile.DataBoostIsolationReadOnlyH\001\032\257\001\n" + + " \001(\0132?.google.bigtable.admin.v2.AppProfile.DataBoostIsolationReadOnlyH\001\032\257\001\n" + "\031MultiClusterRoutingUseAny\022\023\n" + "\013cluster_ids\030\001 \003(\t\022b\n" - + "\014row_affinity\030\003 \001(\0132J.google.bigtable." - + "admin.v2.AppProfile.MultiClusterRoutingUseAny.RowAffinityH\000\032\r\n" + + "\014row_affinity\030\003 \001(\0132J.google.b" + + "igtable.admin.v2.AppProfile.MultiClusterRoutingUseAny.RowAffinityH\000\032\r\n" + "\013RowAffinityB\n\n" + "\010affinity\032N\n" + "\024SingleClusterRouting\022\022\n\n" @@ -264,13 +262,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\032allow_transactional_writes\030\002 \001(\010\032\306\001\n" + "\021StandardIsolation\022?\n" + "\010priority\030\001 \001(\0162-.google.bigtable.admin.v2.AppProfile.Priority\022`\n\r" - + "memory_config\030\002 \001(\0132C.g" - + "oogle.bigtable.admin.v2.AppProfile.StandardIsolation.MemoryConfigB\004\342A\001\001\032\016\n" + + "memory_config\030\002 \001(\0132C.google.bigtable.admin.v2.AppProfi" + + "le.StandardIsolation.MemoryConfigB\004\342A\001\001\032\016\n" + "\014MemoryConfig\032\374\001\n" + "\032DataBoostIsolationReadOnly\022w\n" - + "\025compute_billing_owner\030\001 \001(\0162S.google.b" - + "igtable.admin.v2.AppProfile.DataBoostIso" - + "lationReadOnly.ComputeBillingOwnerH\000\210\001\001\"K\n" + + "\025compute_billing_owner\030\001 \001(\0162S.google.bigtable.admin.v2.AppProfile.Data" + + "BoostIsolationReadOnly.ComputeBillingOwnerH\000\210\001\001\"K\n" + "\023ComputeBillingOwner\022%\n" + "!COMPUTE_BILLING_OWNER_UNSPECIFIED\020\000\022\r\n" + "\tHOST_PAYS\020\001B\030\n" @@ -280,14 +277,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\014PRIORITY_LOW\020\001\022\023\n" + "\017PRIORITY_MEDIUM\020\002\022\021\n\r" + "PRIORITY_HIGH\020\003:\211\001\352A\205\001\n" - + "\'bigtableadmin.googleapis.com/AppProfile\022Aprojects/{project}/instances/{in" - + "stance}/appProfiles/{app_profile}*\013appProfiles2\n" + + "\'bigtableadmin.googleapis.com/AppProfile\022Aprojects/{project}/insta" + + "nces/{instance}/appProfiles/{app_profile}*\013appProfiles2\n" + "appProfileB\020\n" + "\016routing_policyB\013\n" + "\tisolation\"\244\003\n" + "\tHotTablet\022\014\n" - + "\004name\030\001 \001(\t\022;\n" - + "\n" + + "\004name\030\001 \001(\t\022;\n\n" + "table_name\030\002 \001(\tB\'\372A$\n" + "\"bigtableadmin.googleapis.com/Table\0224\n\n" + "start_time\030\003 \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0222\n" @@ -296,31 +292,30 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tstart_key\030\005 \001(\t\022\017\n" + "\007end_key\030\006 \001(\t\022$\n" + "\026node_cpu_usage_percent\030\007 \001(\002B\004\342A\001\003:\227\001\352A\223\001\n" - + "&bigtableadmin.googleapis.com/HotTablet\022Rprojects/{project}/instances/{ins" - + "tance}/clusters/{cluster}/hotTablets/{hot_tablet}*\n" + + "&bigtableadmin.googleapis.com/HotTablet\022Rprojects/{project}/instan" + + "ces/{instance}/clusters/{cluster}/hotTablets/{hot_tablet}*\n" + "hotTablets2\thotTablet\"\376\001\n" + "\013LogicalView\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\023\n" + "\005query\030\002 \001(\tB\004\342A\001\002\022\022\n" + "\004etag\030\003 \001(\tB\004\342A\001\001\022!\n" + "\023deletion_protection\030\006 \001(\010B\004\342A\001\001:\216\001\352A\212\001\n" - + "(bigtableadmin.googleapis.com/LogicalView\022Cproje" - + "cts/{project}/instances/{instance}/logic" - + "alViews/{logical_view}*\014logicalViews2\013logicalView\"\227\002\n" + + "(bigtableadmin.googleapis.com/LogicalView\022Cprojects/{project}/instances/{instanc" + + "e}/logicalViews/{logical_view}*\014logicalViews2\013logicalView\"\227\002\n" + "\020MaterializedView\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\024\n" + "\005query\030\002 \001(\tB\005\342A\002\002\005\022\022\n" + "\004etag\030\003 \001(\tB\004\342A\001\001\022\033\n" + "\023deletion_protection\030\006 \001(\010:\247\001\352A\243\001\n" - + "-bigtableadmin.googleapis.com/MaterializedView\022Mprojects/{project}/inst" - + "ances/{instance}/materializedViews/{mate" - + "rialized_view}*\021materializedViews2\020materializedViewB\313\002\n" + + "-bigtableadmin.googleapis.com/MaterializedView\022Mprojects/{proje" + + "ct}/instances/{instance}/materializedVie" + + "ws/{materialized_view}*\021materializedViews2\020materializedViewB\313\002\n" + "\034com.google.bigtable.admin.v2B\r" - + "InstanceProtoP\001Z8cloud.google.com/go/bigtable/admin/apiv2/adminpb;adminpb\252" - + "\002\036Google.Cloud.Bigtable.Admin.V2\312\002\036Googl" - + "e\\Cloud\\Bigtable\\Admin\\V2\352\002\"Google::Cloud::Bigtable::Admin::V2\352Ax\n" - + "!cloudkms.googleapis.com/CryptoKey\022Sprojects/{project}" - + "/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}b\006proto3" + + "InstanceProtoP\001Z8cloud.google.com/go/bigtable/admin/apiv2/adminpb;" + + "adminpb\252\002\036Google.Cloud.Bigtable.Admin.V2" + + "\312\002\036Google\\Cloud\\Bigtable\\Admin\\V2\352\002\"Google::Cloud::Bigtable::Admin::V2\352Ax\n" + + "!cloudkms.googleapis.com/CryptoKey\022Sprojects/{" + + "project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -432,9 +427,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { internal_static_google_bigtable_admin_v2_MemoryLayer_MemoryConfig_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_bigtable_admin_v2_MemoryLayer_MemoryConfig_descriptor, - new java.lang.String[] { - "StorageSizeGib", - }); + new java.lang.String[] {}); internal_static_google_bigtable_admin_v2_AppProfile_descriptor = getDescriptor().getMessageType(5); internal_static_google_bigtable_admin_v2_AppProfile_fieldAccessorTable = diff --git a/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/MemoryLayer.java b/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/MemoryLayer.java index d5f5da895989..120451f61e7c 100644 --- a/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/MemoryLayer.java +++ b/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/MemoryLayer.java @@ -307,21 +307,7 @@ private State(int value) { public interface MemoryConfigOrBuilder extends // @@protoc_insertion_point(interface_extends:google.bigtable.admin.v2.MemoryLayer.MemoryConfig) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
                      -     * Output only. Reporting the current size of the memory layer in GiB.
                      -     * 
                      - * - * int32 storage_size_gib = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The storageSizeGib. - */ - int getStorageSizeGib(); - } + com.google.protobuf.MessageOrBuilder {} /** * @@ -370,25 +356,6 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { com.google.bigtable.admin.v2.MemoryLayer.MemoryConfig.Builder.class); } - public static final int STORAGE_SIZE_GIB_FIELD_NUMBER = 2; - private int storageSizeGib_ = 0; - - /** - * - * - *
                      -     * Output only. Reporting the current size of the memory layer in GiB.
                      -     * 
                      - * - * int32 storage_size_gib = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The storageSizeGib. - */ - @java.lang.Override - public int getStorageSizeGib() { - return storageSizeGib_; - } - private byte memoizedIsInitialized = -1; @java.lang.Override @@ -403,9 +370,6 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (storageSizeGib_ != 0) { - output.writeInt32(2, storageSizeGib_); - } getUnknownFields().writeTo(output); } @@ -415,9 +379,6 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - if (storageSizeGib_ != 0) { - size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, storageSizeGib_); - } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -434,7 +395,6 @@ public boolean equals(final java.lang.Object obj) { com.google.bigtable.admin.v2.MemoryLayer.MemoryConfig other = (com.google.bigtable.admin.v2.MemoryLayer.MemoryConfig) obj; - if (getStorageSizeGib() != other.getStorageSizeGib()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -446,8 +406,6 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + STORAGE_SIZE_GIB_FIELD_NUMBER; - hash = (53 * hash) + getStorageSizeGib(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -588,8 +546,6 @@ private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { @java.lang.Override public Builder clear() { super.clear(); - bitField0_ = 0; - storageSizeGib_ = 0; return this; } @@ -617,20 +573,10 @@ public com.google.bigtable.admin.v2.MemoryLayer.MemoryConfig build() { public com.google.bigtable.admin.v2.MemoryLayer.MemoryConfig buildPartial() { com.google.bigtable.admin.v2.MemoryLayer.MemoryConfig result = new com.google.bigtable.admin.v2.MemoryLayer.MemoryConfig(this); - if (bitField0_ != 0) { - buildPartial0(result); - } onBuilt(); return result; } - private void buildPartial0(com.google.bigtable.admin.v2.MemoryLayer.MemoryConfig result) { - int from_bitField0_ = bitField0_; - if (((from_bitField0_ & 0x00000001) != 0)) { - result.storageSizeGib_ = storageSizeGib_; - } - } - @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.bigtable.admin.v2.MemoryLayer.MemoryConfig) { @@ -644,9 +590,6 @@ public Builder mergeFrom(com.google.protobuf.Message other) { public Builder mergeFrom(com.google.bigtable.admin.v2.MemoryLayer.MemoryConfig other) { if (other == com.google.bigtable.admin.v2.MemoryLayer.MemoryConfig.getDefaultInstance()) return this; - if (other.getStorageSizeGib() != 0) { - setStorageSizeGib(other.getStorageSizeGib()); - } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -673,12 +616,6 @@ public Builder mergeFrom( case 0: done = true; break; - case 16: - { - storageSizeGib_ = input.readInt32(); - bitField0_ |= 0x00000001; - break; - } // case 16 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -696,64 +633,6 @@ public Builder mergeFrom( return this; } - private int bitField0_; - - private int storageSizeGib_; - - /** - * - * - *
                      -       * Output only. Reporting the current size of the memory layer in GiB.
                      -       * 
                      - * - * int32 storage_size_gib = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The storageSizeGib. - */ - @java.lang.Override - public int getStorageSizeGib() { - return storageSizeGib_; - } - - /** - * - * - *
                      -       * Output only. Reporting the current size of the memory layer in GiB.
                      -       * 
                      - * - * int32 storage_size_gib = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The storageSizeGib to set. - * @return This builder for chaining. - */ - public Builder setStorageSizeGib(int value) { - - storageSizeGib_ = value; - bitField0_ |= 0x00000001; - onChanged(); - return this; - } - - /** - * - * - *
                      -       * Output only. Reporting the current size of the memory layer in GiB.
                      -       * 
                      - * - * int32 storage_size_gib = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearStorageSizeGib() { - bitField0_ = (bitField0_ & ~0x00000001); - storageSizeGib_ = 0; - onChanged(); - return this; - } - // @@protoc_insertion_point(builder_scope:google.bigtable.admin.v2.MemoryLayer.MemoryConfig) } diff --git a/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/instance.proto b/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/instance.proto index 1994c56e9eed..d5309e662fe4 100644 --- a/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/instance.proto +++ b/java-bigtable/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/instance.proto @@ -322,10 +322,7 @@ message MemoryLayer { }; // Configuration of a memory layer. - message MemoryConfig { - // Output only. Reporting the current size of the memory layer in GiB. - int32 storage_size_gib = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; - } + message MemoryConfig {} // Possible states of a memory layer. enum State { diff --git a/java-billing/README.md b/java-billing/README.md index 634bc8218816..e2cca9ea22dd 100644 --- a/java-billing/README.md +++ b/java-billing/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-billing - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-billing' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-billing:2.102.0' +implementation 'com.google.cloud:google-cloud-billing:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-billing" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-billing" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-billing/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-billing.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-billing/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-billing/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-billingbudgets/README.md b/java-billingbudgets/README.md index b9d7700ec05e..0b5c66d08bdf 100644 --- a/java-billingbudgets/README.md +++ b/java-billingbudgets/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-billingbudgets - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-billingbudgets' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-billingbudgets:2.102.0' +implementation 'com.google.cloud:google-cloud-billingbudgets:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-billingbudgets" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-billingbudgets" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-billingbudgets/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-billingbudgets.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-billingbudgets/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-billingbudgets/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-binary-authorization/README.md b/java-binary-authorization/README.md index f7a1612ba081..88c60b07f1b0 100644 --- a/java-binary-authorization/README.md +++ b/java-binary-authorization/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-binary-authorization - 1.101.0 + 1.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-binary-authorization' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-binary-authorization:1.101.0' +implementation 'com.google.cloud:google-cloud-binary-authorization:1.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-binary-authorization" % "1.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-binary-authorization" % "1.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-binary-authorization/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-binary-authorization.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-binary-authorization/1.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-binary-authorization/1.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-capacityplanner/README.md b/java-capacityplanner/README.md index 864dc607fc71..1bb64652aed8 100644 --- a/java-capacityplanner/README.md +++ b/java-capacityplanner/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-capacityplanner - 0.25.0 + 0.26.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-capacityplanner' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-capacityplanner:0.25.0' +implementation 'com.google.cloud:google-cloud-capacityplanner:0.26.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-capacityplanner" % "0.25.0" +libraryDependencies += "com.google.cloud" % "google-cloud-capacityplanner" % "0.26.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-capacityplanner/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-capacityplanner.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-capacityplanner/0.25.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-capacityplanner/0.26.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-certificate-manager/README.md b/java-certificate-manager/README.md index cb425e8ae755..51ca99ff326a 100644 --- a/java-certificate-manager/README.md +++ b/java-certificate-manager/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-certificate-manager - 0.105.0 + 0.106.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-certificate-manager' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-certificate-manager:0.105.0' +implementation 'com.google.cloud:google-cloud-certificate-manager:0.106.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-certificate-manager" % "0.105.0" +libraryDependencies += "com.google.cloud" % "google-cloud-certificate-manager" % "0.106.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-certificate-manager/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-certificate-manager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-certificate-manager/0.105.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-certificate-manager/0.106.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-ces/README.md b/java-ces/README.md index 4b3d94f6d86b..6f8910581d50 100644 --- a/java-ces/README.md +++ b/java-ces/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-ces - 0.18.0 + 0.19.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-ces' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-ces:0.18.0' +implementation 'com.google.cloud:google-cloud-ces:0.19.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-ces" % "0.18.0" +libraryDependencies += "com.google.cloud" % "google-cloud-ces" % "0.19.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-ces/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-ces.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-ces/0.18.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-ces/0.19.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-channel/README.md b/java-channel/README.md index 6e01416f6526..f4a025c1595e 100644 --- a/java-channel/README.md +++ b/java-channel/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-channel - 3.106.0 + 3.107.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-channel' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-channel:3.106.0' +implementation 'com.google.cloud:google-cloud-channel:3.107.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-channel" % "3.106.0" +libraryDependencies += "com.google.cloud" % "google-cloud-channel" % "3.107.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-channel/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-channel.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-channel/3.106.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-channel/3.107.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-chat/README.md b/java-chat/README.md index 74a7e5c52bd3..06be053471b5 100644 --- a/java-chat/README.md +++ b/java-chat/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-chat - 0.66.0 + 0.67.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-chat' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-chat:0.66.0' +implementation 'com.google.cloud:google-cloud-chat:0.67.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-chat" % "0.66.0" +libraryDependencies += "com.google.cloud" % "google-cloud-chat" % "0.67.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-chat/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-chat.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-chat/0.66.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-chat/0.67.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/ChatServiceClient.java b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/ChatServiceClient.java index d084e6b14677..04b2ff93139b 100644 --- a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/ChatServiceClient.java +++ b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/ChatServiceClient.java @@ -847,6 +847,26 @@ * * * + *

                      UpdateThreadReadState + *

                      Updates a user's read state within a thread, used to identify read and unread messages. For an example, see [Update a user's thread read state](https://developers.google.com/workspace/chat/update-thread-read-state). + *

                      Requires [user authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) with the [authorization scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes): + *

                      - `https://www.googleapis.com/auth/chat.users.readstate` + * + *

                      Request object method variants only take one parameter, a request object, which must be constructed before the call.

                      + *
                        + *
                      • updateThreadReadState(UpdateThreadReadStateRequest request) + *

                      + *

                      "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

                      + *
                        + *
                      • updateThreadReadState(ThreadReadState threadReadState, FieldMask updateMask) + *

                      + *

                      Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

                      + *
                        + *
                      • updateThreadReadStateCallable() + *

                      + * + * + * *

                      GetThreadReadState *

                      Returns details about a user's read state within a thread, used to identify read and unread messages. For an example, see [Get details about a user's thread read state](https://developers.google.com/workspace/chat/get-thread-read-state). *

                      Requires [user authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) with one of the following [authorization scopes](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes): @@ -8130,6 +8150,142 @@ public final SpaceReadState updateSpaceReadState(UpdateSpaceReadStateRequest req return stub.updateSpaceReadStateCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a user's read state within a thread, used to identify read and unread messages. For an + * example, see [Update a user's thread read + * state](https://developers.google.com/workspace/chat/update-thread-read-state). + * + *

                      Requires [user + * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) + * with the [authorization + * scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes): + * + *

                      - `https://www.googleapis.com/auth/chat.users.readstate` + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (ChatServiceClient chatServiceClient = ChatServiceClient.create()) {
                      +   *   ThreadReadState threadReadState = ThreadReadState.newBuilder().build();
                      +   *   FieldMask updateMask = FieldMask.newBuilder().build();
                      +   *   ThreadReadState response =
                      +   *       chatServiceClient.updateThreadReadState(threadReadState, updateMask);
                      +   * }
                      +   * }
                      + * + * @param threadReadState Required. The thread read state and fields to update. + *

                      Only supports updating read state for the calling user. + *

                      To refer to the calling user, set one of the following: + *

                      - The `me` alias. For example, + * `users/me/spaces/{space}/threads/{thread}/threadReadState`. + *

                      - Their Workspace email address. For example, + * `users/user{@literal @}example.com/spaces/{space}/threads/{thread}/threadReadState`. + *

                      - Their user id. For example, + * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`. + *

                      Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState` + * @param updateMask Required. The field paths to update. Currently supported field paths: + *

                      - `last_read_time` + *

                      When `last_read_time` is before the latest message create time, the thread appears as + * unread in the UI. + *

                      To mark the thread as read, set `last_read_time` to a timestamp equal to or later than + * the latest message create time. Future timestamps are coerced to the current request time. + * Setting a negative timestamp (before `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` + * error. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ThreadReadState updateThreadReadState( + ThreadReadState threadReadState, FieldMask updateMask) { + UpdateThreadReadStateRequest request = + UpdateThreadReadStateRequest.newBuilder() + .setThreadReadState(threadReadState) + .setUpdateMask(updateMask) + .build(); + return updateThreadReadState(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a user's read state within a thread, used to identify read and unread messages. For an + * example, see [Update a user's thread read + * state](https://developers.google.com/workspace/chat/update-thread-read-state). + * + *

                      Requires [user + * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) + * with the [authorization + * scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes): + * + *

                      - `https://www.googleapis.com/auth/chat.users.readstate` + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (ChatServiceClient chatServiceClient = ChatServiceClient.create()) {
                      +   *   UpdateThreadReadStateRequest request =
                      +   *       UpdateThreadReadStateRequest.newBuilder()
                      +   *           .setThreadReadState(ThreadReadState.newBuilder().build())
                      +   *           .setUpdateMask(FieldMask.newBuilder().build())
                      +   *           .build();
                      +   *   ThreadReadState response = chatServiceClient.updateThreadReadState(request);
                      +   * }
                      +   * }
                      + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ThreadReadState updateThreadReadState(UpdateThreadReadStateRequest request) { + return updateThreadReadStateCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a user's read state within a thread, used to identify read and unread messages. For an + * example, see [Update a user's thread read + * state](https://developers.google.com/workspace/chat/update-thread-read-state). + * + *

                      Requires [user + * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) + * with the [authorization + * scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes): + * + *

                      - `https://www.googleapis.com/auth/chat.users.readstate` + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (ChatServiceClient chatServiceClient = ChatServiceClient.create()) {
                      +   *   UpdateThreadReadStateRequest request =
                      +   *       UpdateThreadReadStateRequest.newBuilder()
                      +   *           .setThreadReadState(ThreadReadState.newBuilder().build())
                      +   *           .setUpdateMask(FieldMask.newBuilder().build())
                      +   *           .build();
                      +   *   ApiFuture future =
                      +   *       chatServiceClient.updateThreadReadStateCallable().futureCall(request);
                      +   *   // Do something.
                      +   *   ThreadReadState response = future.get();
                      +   * }
                      +   * }
                      + */ + public final UnaryCallable + updateThreadReadStateCallable() { + return stub.updateThreadReadStateCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Returns details about a user's read state within a thread, used to identify read and unread diff --git a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/ChatServiceSettings.java b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/ChatServiceSettings.java index 28538887cb99..06e9c9d53882 100644 --- a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/ChatServiceSettings.java +++ b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/ChatServiceSettings.java @@ -294,6 +294,12 @@ public UnaryCallSettings getSpaceReadS return ((ChatServiceStubSettings) getStubSettings()).updateSpaceReadStateSettings(); } + /** Returns the object with the settings used for calls to updateThreadReadState. */ + public UnaryCallSettings + updateThreadReadStateSettings() { + return ((ChatServiceStubSettings) getStubSettings()).updateThreadReadStateSettings(); + } + /** Returns the object with the settings used for calls to getThreadReadState. */ public UnaryCallSettings getThreadReadStateSettings() { @@ -707,6 +713,12 @@ public UnaryCallSettings.Builder deleteCustomEm return getStubSettingsBuilder().updateSpaceReadStateSettings(); } + /** Returns the builder for the settings used for calls to updateThreadReadState. */ + public UnaryCallSettings.Builder + updateThreadReadStateSettings() { + return getStubSettingsBuilder().updateThreadReadStateSettings(); + } + /** Returns the builder for the settings used for calls to getThreadReadState. */ public UnaryCallSettings.Builder getThreadReadStateSettings() { diff --git a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/gapic_metadata.json b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/gapic_metadata.json index fb29e81bc974..45ceacfda93a 100644 --- a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/gapic_metadata.json +++ b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/gapic_metadata.json @@ -166,6 +166,9 @@ "UpdateSpaceReadState": { "methods": ["updateSpaceReadState", "updateSpaceReadState", "updateSpaceReadStateCallable"] }, + "UpdateThreadReadState": { + "methods": ["updateThreadReadState", "updateThreadReadState", "updateThreadReadStateCallable"] + }, "UploadAttachment": { "methods": ["uploadAttachment", "uploadAttachmentCallable"] } diff --git a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/ChatServiceStub.java b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/ChatServiceStub.java index 9c00bb5e5ae9..d78fb9950fe2 100644 --- a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/ChatServiceStub.java +++ b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/ChatServiceStub.java @@ -112,6 +112,7 @@ import com.google.chat.v1.UpdateSpaceNotificationSettingRequest; import com.google.chat.v1.UpdateSpaceReadStateRequest; import com.google.chat.v1.UpdateSpaceRequest; +import com.google.chat.v1.UpdateThreadReadStateRequest; import com.google.chat.v1.UploadAttachmentRequest; import com.google.chat.v1.UploadAttachmentResponse; import com.google.protobuf.Empty; @@ -313,6 +314,11 @@ public UnaryCallable updateSpaceRea throw new UnsupportedOperationException("Not implemented: updateSpaceReadStateCallable()"); } + public UnaryCallable + updateThreadReadStateCallable() { + throw new UnsupportedOperationException("Not implemented: updateThreadReadStateCallable()"); + } + public UnaryCallable getThreadReadStateCallable() { throw new UnsupportedOperationException("Not implemented: getThreadReadStateCallable()"); } diff --git a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/ChatServiceStubSettings.java b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/ChatServiceStubSettings.java index 835f991635a5..0d9883da329f 100644 --- a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/ChatServiceStubSettings.java +++ b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/ChatServiceStubSettings.java @@ -139,6 +139,7 @@ import com.google.chat.v1.UpdateSpaceNotificationSettingRequest; import com.google.chat.v1.UpdateSpaceReadStateRequest; import com.google.chat.v1.UpdateSpaceRequest; +import com.google.chat.v1.UpdateThreadReadStateRequest; import com.google.chat.v1.UploadAttachmentRequest; import com.google.chat.v1.UploadAttachmentResponse; import com.google.common.collect.ImmutableList; @@ -309,6 +310,8 @@ public class ChatServiceStubSettings extends StubSettings updateSpaceReadStateSettings; + private final UnaryCallSettings + updateThreadReadStateSettings; private final UnaryCallSettings getThreadReadStateSettings; private final UnaryCallSettings getAvailabilitySettings; @@ -1172,6 +1175,12 @@ public UnaryCallSettings getSpaceReadS return updateSpaceReadStateSettings; } + /** Returns the object with the settings used for calls to updateThreadReadState. */ + public UnaryCallSettings + updateThreadReadStateSettings() { + return updateThreadReadStateSettings; + } + /** Returns the object with the settings used for calls to getThreadReadState. */ public UnaryCallSettings getThreadReadStateSettings() { @@ -1419,6 +1428,7 @@ protected ChatServiceStubSettings(Builder settingsBuilder) throws IOException { deleteCustomEmojiSettings = settingsBuilder.deleteCustomEmojiSettings().build(); getSpaceReadStateSettings = settingsBuilder.getSpaceReadStateSettings().build(); updateSpaceReadStateSettings = settingsBuilder.updateSpaceReadStateSettings().build(); + updateThreadReadStateSettings = settingsBuilder.updateThreadReadStateSettings().build(); getThreadReadStateSettings = settingsBuilder.getThreadReadStateSettings().build(); getAvailabilitySettings = settingsBuilder.getAvailabilitySettings().build(); markAsActiveSettings = settingsBuilder.markAsActiveSettings().build(); @@ -1519,6 +1529,8 @@ public static class Builder extends StubSettings.Builder updateSpaceReadStateSettings; + private final UnaryCallSettings.Builder + updateThreadReadStateSettings; private final UnaryCallSettings.Builder getThreadReadStateSettings; private final UnaryCallSettings.Builder @@ -1630,6 +1642,7 @@ protected Builder(@Nullable ClientContext clientContext) { deleteCustomEmojiSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); getSpaceReadStateSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); updateSpaceReadStateSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateThreadReadStateSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); getThreadReadStateSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); getAvailabilitySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); markAsActiveSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -1686,6 +1699,7 @@ protected Builder(@Nullable ClientContext clientContext) { deleteCustomEmojiSettings, getSpaceReadStateSettings, updateSpaceReadStateSettings, + updateThreadReadStateSettings, getThreadReadStateSettings, getAvailabilitySettings, markAsActiveSettings, @@ -1745,6 +1759,7 @@ protected Builder(ChatServiceStubSettings settings) { deleteCustomEmojiSettings = settings.deleteCustomEmojiSettings.toBuilder(); getSpaceReadStateSettings = settings.getSpaceReadStateSettings.toBuilder(); updateSpaceReadStateSettings = settings.updateSpaceReadStateSettings.toBuilder(); + updateThreadReadStateSettings = settings.updateThreadReadStateSettings.toBuilder(); getThreadReadStateSettings = settings.getThreadReadStateSettings.toBuilder(); getAvailabilitySettings = settings.getAvailabilitySettings.toBuilder(); markAsActiveSettings = settings.markAsActiveSettings.toBuilder(); @@ -1803,6 +1818,7 @@ protected Builder(ChatServiceStubSettings settings) { deleteCustomEmojiSettings, getSpaceReadStateSettings, updateSpaceReadStateSettings, + updateThreadReadStateSettings, getThreadReadStateSettings, getAvailabilitySettings, markAsActiveSettings, @@ -2023,6 +2039,11 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + builder + .updateThreadReadStateSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + builder .getThreadReadStateSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) @@ -2332,6 +2353,12 @@ public UnaryCallSettings.Builder deleteCustomEm return updateSpaceReadStateSettings; } + /** Returns the builder for the settings used for calls to updateThreadReadState. */ + public UnaryCallSettings.Builder + updateThreadReadStateSettings() { + return updateThreadReadStateSettings; + } + /** Returns the builder for the settings used for calls to getThreadReadState. */ public UnaryCallSettings.Builder getThreadReadStateSettings() { diff --git a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/GrpcChatServiceStub.java b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/GrpcChatServiceStub.java index 90ea925826bc..ff76d30b17be 100644 --- a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/GrpcChatServiceStub.java +++ b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/GrpcChatServiceStub.java @@ -117,6 +117,7 @@ import com.google.chat.v1.UpdateSpaceNotificationSettingRequest; import com.google.chat.v1.UpdateSpaceReadStateRequest; import com.google.chat.v1.UpdateSpaceRequest; +import com.google.chat.v1.UpdateThreadReadStateRequest; import com.google.chat.v1.UploadAttachmentRequest; import com.google.chat.v1.UploadAttachmentResponse; import com.google.longrunning.stub.GrpcOperationsStub; @@ -515,6 +516,17 @@ public class GrpcChatServiceStub extends ChatServiceStub { .setSampledToLocalTracing(true) .build(); + private static final MethodDescriptor + updateThreadReadStateMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.chat.v1.ChatService/UpdateThreadReadState") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateThreadReadStateRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(ThreadReadState.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + private static final MethodDescriptor getThreadReadStateMethodDescriptor = MethodDescriptor.newBuilder() @@ -778,6 +790,8 @@ public class GrpcChatServiceStub extends ChatServiceStub { private final UnaryCallable getSpaceReadStateCallable; private final UnaryCallable updateSpaceReadStateCallable; + private final UnaryCallable + updateThreadReadStateCallable; private final UnaryCallable getThreadReadStateCallable; private final UnaryCallable getAvailabilityCallable; @@ -1188,6 +1202,19 @@ protected GrpcChatServiceStub( return builder.build(); }) .build(); + GrpcCallSettings + updateThreadReadStateTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateThreadReadStateMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add( + "thread_read_state.name", + String.valueOf(request.getThreadReadState().getName())); + return builder.build(); + }) + .build(); GrpcCallSettings getThreadReadStateTransportSettings = GrpcCallSettings.newBuilder() @@ -1541,6 +1568,11 @@ protected GrpcChatServiceStub( updateSpaceReadStateTransportSettings, settings.updateSpaceReadStateSettings(), clientContext); + this.updateThreadReadStateCallable = + callableFactory.createUnaryCallable( + updateThreadReadStateTransportSettings, + settings.updateThreadReadStateSettings(), + clientContext); this.getThreadReadStateCallable = callableFactory.createUnaryCallable( getThreadReadStateTransportSettings, @@ -1854,6 +1886,12 @@ public UnaryCallable updateSpaceRea return updateSpaceReadStateCallable; } + @Override + public UnaryCallable + updateThreadReadStateCallable() { + return updateThreadReadStateCallable; + } + @Override public UnaryCallable getThreadReadStateCallable() { return getThreadReadStateCallable; diff --git a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/HttpJsonChatServiceStub.java b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/HttpJsonChatServiceStub.java index c529851b7130..1200b4ca0338 100644 --- a/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/HttpJsonChatServiceStub.java +++ b/java-chat/google-cloud-chat/src/main/java/com/google/chat/v1/stub/HttpJsonChatServiceStub.java @@ -122,6 +122,7 @@ import com.google.chat.v1.UpdateSpaceNotificationSettingRequest; import com.google.chat.v1.UpdateSpaceReadStateRequest; import com.google.chat.v1.UpdateSpaceRequest; +import com.google.chat.v1.UpdateThreadReadStateRequest; import com.google.chat.v1.UploadAttachmentRequest; import com.google.chat.v1.UploadAttachmentResponse; import com.google.protobuf.Empty; @@ -1440,6 +1441,47 @@ public class HttpJsonChatServiceStub extends ChatServiceStub { .build()) .build(); + private static final ApiMethodDescriptor + updateThreadReadStateMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.chat.v1.ChatService/UpdateThreadReadState") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{threadReadState.name=users/*/spaces/*/threads/*/threadReadState}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, + "threadReadState.name", + request.getThreadReadState().getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("threadReadState", request.getThreadReadState(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ThreadReadState.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + private static final ApiMethodDescriptor getThreadReadStateMethodDescriptor = ApiMethodDescriptor.newBuilder() @@ -2163,6 +2205,8 @@ public class HttpJsonChatServiceStub extends ChatServiceStub { private final UnaryCallable getSpaceReadStateCallable; private final UnaryCallable updateSpaceReadStateCallable; + private final UnaryCallable + updateThreadReadStateCallable; private final UnaryCallable getThreadReadStateCallable; private final UnaryCallable getAvailabilityCallable; @@ -2611,6 +2655,20 @@ protected HttpJsonChatServiceStub( return builder.build(); }) .build(); + HttpJsonCallSettings + updateThreadReadStateTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateThreadReadStateMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add( + "thread_read_state.name", + String.valueOf(request.getThreadReadState().getName())); + return builder.build(); + }) + .build(); HttpJsonCallSettings getThreadReadStateTransportSettings = HttpJsonCallSettings.newBuilder() @@ -2985,6 +3043,11 @@ protected HttpJsonChatServiceStub( updateSpaceReadStateTransportSettings, settings.updateSpaceReadStateSettings(), clientContext); + this.updateThreadReadStateCallable = + callableFactory.createUnaryCallable( + updateThreadReadStateTransportSettings, + settings.updateThreadReadStateSettings(), + clientContext); this.getThreadReadStateCallable = callableFactory.createUnaryCallable( getThreadReadStateTransportSettings, @@ -3103,6 +3166,7 @@ public static List getMethodDescriptors() { methodDescriptors.add(deleteCustomEmojiMethodDescriptor); methodDescriptors.add(getSpaceReadStateMethodDescriptor); methodDescriptors.add(updateSpaceReadStateMethodDescriptor); + methodDescriptors.add(updateThreadReadStateMethodDescriptor); methodDescriptors.add(getThreadReadStateMethodDescriptor); methodDescriptors.add(getAvailabilityMethodDescriptor); methodDescriptors.add(markAsActiveMethodDescriptor); @@ -3353,6 +3417,12 @@ public UnaryCallable updateSpaceRea return updateSpaceReadStateCallable; } + @Override + public UnaryCallable + updateThreadReadStateCallable() { + return updateThreadReadStateCallable; + } + @Override public UnaryCallable getThreadReadStateCallable() { return getThreadReadStateCallable; diff --git a/java-chat/google-cloud-chat/src/main/resources/META-INF/native-image/com.google.chat.v1/reflect-config.json b/java-chat/google-cloud-chat/src/main/resources/META-INF/native-image/com.google.chat.v1/reflect-config.json index 67ec7fa1b797..087c2ebff131 100644 --- a/java-chat/google-cloud-chat/src/main/resources/META-INF/native-image/com.google.chat.v1/reflect-config.json +++ b/java-chat/google-cloud-chat/src/main/resources/META-INF/native-image/com.google.chat.v1/reflect-config.json @@ -4580,6 +4580,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.chat.v1.UpdateThreadReadStateRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.chat.v1.UpdateThreadReadStateRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.chat.v1.UploadAttachmentRequest", "queryAllDeclaredConstructors": true, diff --git a/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/ChatServiceClientHttpJsonTest.java b/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/ChatServiceClientHttpJsonTest.java index ce6d11915a9e..1db137c575ee 100644 --- a/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/ChatServiceClientHttpJsonTest.java +++ b/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/ChatServiceClientHttpJsonTest.java @@ -3064,6 +3064,61 @@ public void updateSpaceReadStateExceptionTest() throws Exception { } } + @Test + public void updateThreadReadStateTest() throws Exception { + ThreadReadState expectedResponse = + ThreadReadState.newBuilder() + .setName(ThreadReadStateName.of("[USER]", "[SPACE]", "[THREAD]").toString()) + .setLastReadTime(Timestamp.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + ThreadReadState threadReadState = + ThreadReadState.newBuilder() + .setName(ThreadReadStateName.of("[USER]", "[SPACE]", "[THREAD]").toString()) + .setLastReadTime(Timestamp.newBuilder().build()) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + ThreadReadState actualResponse = client.updateThreadReadState(threadReadState, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void updateThreadReadStateExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + ThreadReadState threadReadState = + ThreadReadState.newBuilder() + .setName(ThreadReadStateName.of("[USER]", "[SPACE]", "[THREAD]").toString()) + .setLastReadTime(Timestamp.newBuilder().build()) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateThreadReadState(threadReadState, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + @Test public void getThreadReadStateTest() throws Exception { ThreadReadState expectedResponse = diff --git a/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/ChatServiceClientTest.java b/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/ChatServiceClientTest.java index 9f8ed58440a2..ac256c19dc0c 100644 --- a/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/ChatServiceClientTest.java +++ b/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/ChatServiceClientTest.java @@ -2635,6 +2635,49 @@ public void updateSpaceReadStateExceptionTest() throws Exception { } } + @Test + public void updateThreadReadStateTest() throws Exception { + ThreadReadState expectedResponse = + ThreadReadState.newBuilder() + .setName(ThreadReadStateName.of("[USER]", "[SPACE]", "[THREAD]").toString()) + .setLastReadTime(Timestamp.newBuilder().build()) + .build(); + mockChatService.addResponse(expectedResponse); + + ThreadReadState threadReadState = ThreadReadState.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + ThreadReadState actualResponse = client.updateThreadReadState(threadReadState, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockChatService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateThreadReadStateRequest actualRequest = + ((UpdateThreadReadStateRequest) actualRequests.get(0)); + + Assert.assertEquals(threadReadState, actualRequest.getThreadReadState()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateThreadReadStateExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockChatService.addException(exception); + + try { + ThreadReadState threadReadState = ThreadReadState.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateThreadReadState(threadReadState, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + @Test public void getThreadReadStateTest() throws Exception { ThreadReadState expectedResponse = diff --git a/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/MockChatServiceImpl.java b/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/MockChatServiceImpl.java index 8db15afc6ab6..b7c3d9ef94c9 100644 --- a/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/MockChatServiceImpl.java +++ b/java-chat/google-cloud-chat/src/test/java/com/google/chat/v1/MockChatServiceImpl.java @@ -789,6 +789,28 @@ public void updateSpaceReadState( } } + @Override + public void updateThreadReadState( + UpdateThreadReadStateRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ThreadReadState) { + requests.add(request); + responseObserver.onNext(((ThreadReadState) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method UpdateThreadReadState, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + ThreadReadState.class.getName(), + Exception.class.getName()))); + } + } + @Override public void getThreadReadState( GetThreadReadStateRequest request, StreamObserver responseObserver) { diff --git a/java-chat/grpc-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ChatServiceGrpc.java b/java-chat/grpc-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ChatServiceGrpc.java index da7dd3b664d6..db6ac5e6160a 100644 --- a/java-chat/grpc-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ChatServiceGrpc.java +++ b/java-chat/grpc-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ChatServiceGrpc.java @@ -1451,6 +1451,50 @@ private ChatServiceGrpc() {} return getUpdateSpaceReadStateMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.chat.v1.UpdateThreadReadStateRequest, com.google.chat.v1.ThreadReadState> + getUpdateThreadReadStateMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateThreadReadState", + requestType = com.google.chat.v1.UpdateThreadReadStateRequest.class, + responseType = com.google.chat.v1.ThreadReadState.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.chat.v1.UpdateThreadReadStateRequest, com.google.chat.v1.ThreadReadState> + getUpdateThreadReadStateMethod() { + io.grpc.MethodDescriptor< + com.google.chat.v1.UpdateThreadReadStateRequest, com.google.chat.v1.ThreadReadState> + getUpdateThreadReadStateMethod; + if ((getUpdateThreadReadStateMethod = ChatServiceGrpc.getUpdateThreadReadStateMethod) == null) { + synchronized (ChatServiceGrpc.class) { + if ((getUpdateThreadReadStateMethod = ChatServiceGrpc.getUpdateThreadReadStateMethod) + == null) { + ChatServiceGrpc.getUpdateThreadReadStateMethod = + getUpdateThreadReadStateMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "UpdateThreadReadState")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.chat.v1.UpdateThreadReadStateRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.chat.v1.ThreadReadState.getDefaultInstance())) + .setSchemaDescriptor( + new ChatServiceMethodDescriptorSupplier("UpdateThreadReadState")) + .build(); + } + } + } + return getUpdateThreadReadStateMethod; + } + private static volatile io.grpc.MethodDescriptor< com.google.chat.v1.GetThreadReadStateRequest, com.google.chat.v1.ThreadReadState> getGetThreadReadStateMethod; @@ -3409,6 +3453,27 @@ default void updateSpaceReadState( getUpdateSpaceReadStateMethod(), responseObserver); } + /** + * + * + *
                      +     * Updates a user's read state within a thread, used to identify read and
                      +     * unread messages. For an example, see [Update a user's thread read
                      +     * state](https://developers.google.com/workspace/chat/update-thread-read-state).
                      +     * Requires [user
                      +     * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user)
                      +     * with the [authorization
                      +     * scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes):
                      +     *   - `https://www.googleapis.com/auth/chat.users.readstate`
                      +     * 
                      + */ + default void updateThreadReadState( + com.google.chat.v1.UpdateThreadReadStateRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateThreadReadStateMethod(), responseObserver); + } + /** * * @@ -5105,6 +5170,29 @@ public void updateSpaceReadState( responseObserver); } + /** + * + * + *
                      +     * Updates a user's read state within a thread, used to identify read and
                      +     * unread messages. For an example, see [Update a user's thread read
                      +     * state](https://developers.google.com/workspace/chat/update-thread-read-state).
                      +     * Requires [user
                      +     * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user)
                      +     * with the [authorization
                      +     * scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes):
                      +     *   - `https://www.googleapis.com/auth/chat.users.readstate`
                      +     * 
                      + */ + public void updateThreadReadState( + com.google.chat.v1.UpdateThreadReadStateRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateThreadReadStateMethod(), getCallOptions()), + request, + responseObserver); + } + /** * * @@ -6722,6 +6810,26 @@ public com.google.chat.v1.SpaceReadState updateSpaceReadState( getChannel(), getUpdateSpaceReadStateMethod(), getCallOptions(), request); } + /** + * + * + *
                      +     * Updates a user's read state within a thread, used to identify read and
                      +     * unread messages. For an example, see [Update a user's thread read
                      +     * state](https://developers.google.com/workspace/chat/update-thread-read-state).
                      +     * Requires [user
                      +     * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user)
                      +     * with the [authorization
                      +     * scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes):
                      +     *   - `https://www.googleapis.com/auth/chat.users.readstate`
                      +     * 
                      + */ + public com.google.chat.v1.ThreadReadState updateThreadReadState( + com.google.chat.v1.UpdateThreadReadStateRequest request) throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getUpdateThreadReadStateMethod(), getCallOptions(), request); + } + /** * * @@ -8282,6 +8390,26 @@ public com.google.chat.v1.SpaceReadState updateSpaceReadState( getChannel(), getUpdateSpaceReadStateMethod(), getCallOptions(), request); } + /** + * + * + *
                      +     * Updates a user's read state within a thread, used to identify read and
                      +     * unread messages. For an example, see [Update a user's thread read
                      +     * state](https://developers.google.com/workspace/chat/update-thread-read-state).
                      +     * Requires [user
                      +     * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user)
                      +     * with the [authorization
                      +     * scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes):
                      +     *   - `https://www.googleapis.com/auth/chat.users.readstate`
                      +     * 
                      + */ + public com.google.chat.v1.ThreadReadState updateThreadReadState( + com.google.chat.v1.UpdateThreadReadStateRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateThreadReadStateMethod(), getCallOptions(), request); + } + /** * * @@ -9856,6 +9984,26 @@ public com.google.common.util.concurrent.ListenableFuture + * Updates a user's read state within a thread, used to identify read and + * unread messages. For an example, see [Update a user's thread read + * state](https://developers.google.com/workspace/chat/update-thread-read-state). + * Requires [user + * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) + * with the [authorization + * scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes): + * - `https://www.googleapis.com/auth/chat.users.readstate` + *
                      + */ + public com.google.common.util.concurrent.ListenableFuture + updateThreadReadState(com.google.chat.v1.UpdateThreadReadStateRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateThreadReadStateMethod(), getCallOptions()), request); + } + /** * * @@ -10341,24 +10489,25 @@ public com.google.common.util.concurrent.ListenableFuture implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -10563,6 +10712,11 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (com.google.chat.v1.UpdateSpaceReadStateRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_UPDATE_THREAD_READ_STATE: + serviceImpl.updateThreadReadState( + (com.google.chat.v1.UpdateThreadReadStateRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; case METHODID_GET_THREAD_READ_STATE: serviceImpl.getThreadReadState( (com.google.chat.v1.GetThreadReadStateRequest) request, @@ -10890,6 +11044,13 @@ public static final io.grpc.ServerServiceDefinition bindService(AsyncService ser new MethodHandlers< com.google.chat.v1.UpdateSpaceReadStateRequest, com.google.chat.v1.SpaceReadState>(service, METHODID_UPDATE_SPACE_READ_STATE))) + .addMethod( + getUpdateThreadReadStateMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.chat.v1.UpdateThreadReadStateRequest, + com.google.chat.v1.ThreadReadState>( + service, METHODID_UPDATE_THREAD_READ_STATE))) .addMethod( getGetThreadReadStateMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( @@ -11091,6 +11252,7 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getDeleteCustomEmojiMethod()) .addMethod(getGetSpaceReadStateMethod()) .addMethod(getUpdateSpaceReadStateMethod()) + .addMethod(getUpdateThreadReadStateMethod()) .addMethod(getGetThreadReadStateMethod()) .addMethod(getGetAvailabilityMethod()) .addMethod(getMarkAsActiveMethod()) diff --git a/java-chat/proto-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ChatServiceProto.java b/java-chat/proto-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ChatServiceProto.java index abc160526a5e..f466f7111085 100644 --- a/java-chat/proto-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ChatServiceProto.java +++ b/java-chat/proto-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ChatServiceProto.java @@ -62,7 +62,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "oto\032%google/chat/v1/space_read_state.pro" + "to\032 google/chat/v1/space_setup.proto\032&go" + "ogle/chat/v1/thread_read_state.proto\032\033go" - + "ogle/protobuf/empty.proto2\204P\n\013ChatServic" + + "ogle/protobuf/empty.proto2\362Q\n\013ChatServic" + "e\022\233\001\n\rCreateMessage\022$.google.chat.v1.Cre" + "ateMessageRequest\032\027.google.chat.v1.Messa" + "ge\"K\332A\031parent,message,message_id\202\323\344\223\002)\"\036" @@ -188,142 +188,148 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "v1.SpaceReadState\"t\332A\034space_read_state,u" + "pdate_mask\202\323\344\223\002O2;/v1/{space_read_state." + "name=users/*/spaces/*/spaceReadState}:\020s" - + "pace_read_state\022\246\001\n\022GetThreadReadState\022)" - + ".google.chat.v1.GetThreadReadStateReques" - + "t\032\037.google.chat.v1.ThreadReadState\"D\332A\004n" - + "ame\202\323\344\223\0027\0225/v1/{name=users/*/spaces/*/th" - + "reads/*/threadReadState}\022\207\001\n\017GetAvailabi" - + "lity\022&.google.chat.v1.GetAvailabilityReq" - + "uest\032\034.google.chat.v1.Availability\".\332A\004n" - + "ame\202\323\344\223\002!\022\037/v1/{name=users/*/availabilit" - + "y}\022\212\001\n\014MarkAsActive\022#.google.chat.v1.Mar" - + "kAsActiveRequest\032\034.google.chat.v1.Availa" - + "bility\"7\202\323\344\223\0021\",/v1/{name=users/*/availa" - + "bility}:markAsActive:\001*\022\204\001\n\nMarkAsAway\022!" - + ".google.chat.v1.MarkAsAwayRequest\032\034.goog" - + "le.chat.v1.Availability\"5\202\323\344\223\002/\"*/v1/{na" - + "me=users/*/availability}:markAsAway:\001*\022\234" - + "\001\n\022MarkAsDoNotDisturb\022).google.chat.v1.M" - + "arkAsDoNotDisturbRequest\032\034.google.chat.v" - + "1.Availability\"=\202\323\344\223\0027\"2/v1/{name=users/" - + "*/availability}:markAsDoNotDisturb:\001*\022\274\001" - + "\n\022UpdateAvailability\022).google.chat.v1.Up" - + "dateAvailabilityRequest\032\034.google.chat.v1" - + ".Availability\"]\332A\030availability,update_ma" - + "sk\202\323\344\223\002<2,/v1/{availability.name=users/*" - + "/availability}:\014availability\022\203\001\n\rGetSpac" - + "eEvent\022$.google.chat.v1.GetSpaceEventReq" - + "uest\032\032.google.chat.v1.SpaceEvent\"0\332A\004nam" - + "e\202\323\344\223\002#\022!/v1/{name=spaces/*/spaceEvents/" - + "*}\022\235\001\n\017ListSpaceEvents\022&.google.chat.v1." - + "ListSpaceEventsRequest\032\'.google.chat.v1." - + "ListSpaceEventsResponse\"9\332A\rparent,filte" - + "r\202\323\344\223\002#\022!/v1/{parent=spaces/*}/spaceEven" - + "ts\022\300\001\n\033GetSpaceNotificationSetting\0222.goo" - + "gle.chat.v1.GetSpaceNotificationSettingR" - + "equest\032(.google.chat.v1.SpaceNotificatio" - + "nSetting\"C\332A\004name\202\323\344\223\0026\0224/v1/{name=users" - + "/*/spaces/*/spaceNotificationSetting}\022\240\002" - + "\n\036UpdateSpaceNotificationSetting\0225.googl" - + "e.chat.v1.UpdateSpaceNotificationSetting" - + "Request\032(.google.chat.v1.SpaceNotificati" - + "onSetting\"\234\001\332A&space_notification_settin" - + "g,update_mask\202\323\344\223\002m2O/v1/{space_notifica" - + "tion_setting.name=users/*/spaces/*/space" - + "NotificationSetting}:\032space_notification" - + "_setting\022\217\001\n\rCreateSection\022$.google.chat" - + ".v1.CreateSectionRequest\032\027.google.chat.v" - + "1.Section\"?\332A\016parent,section\202\323\344\223\002(\"\035/v1/" - + "{parent=users/*}/sections:\007section\022{\n\rDe" - + "leteSection\022$.google.chat.v1.DeleteSecti" - + "onRequest\032\026.google.protobuf.Empty\",\332A\004na" - + "me\202\323\344\223\002\037*\035/v1/{name=users/*/sections/*}\022" - + "\234\001\n\rUpdateSection\022$.google.chat.v1.Updat" - + "eSectionRequest\032\027.google.chat.v1.Section" - + "\"L\332A\023section,update_mask\202\323\344\223\00202%/v1/{sec" - + "tion.name=users/*/sections/*}:\007section\022\211" - + "\001\n\014ListSections\022#.google.chat.v1.ListSec" - + "tionsRequest\032$.google.chat.v1.ListSectio" - + "nsResponse\".\332A\006parent\202\323\344\223\002\037\022\035/v1/{parent" - + "=users/*}/sections\022\225\001\n\017PositionSection\022&" - + ".google.chat.v1.PositionSectionRequest\032\'" - + ".google.chat.v1.PositionSectionResponse\"" - + "1\202\323\344\223\002+\"&/v1/{name=users/*/sections/*}:p" - + "osition:\001*\022\235\001\n\020ListSectionItems\022\'.google" - + ".chat.v1.ListSectionItemsRequest\032(.googl" - + "e.chat.v1.ListSectionItemsResponse\"6\332A\006p" - + "arent\202\323\344\223\002\'\022%/v1/{parent=users/*/section" - + "s/*}/items\022\257\001\n\017MoveSectionItem\022&.google." - + "chat.v1.MoveSectionItemRequest\032\'.google." - + "chat.v1.MoveSectionItemResponse\"K\332A\023name" - + ",target_section\202\323\344\223\002/\"*/v1/{name=users/*" - + "/sections/*/items/*}:move:\001*\022\246\001\n\023Replace" - + "MessageCards\022*.google.chat.v1.ReplaceMes" - + "sageCardsRequest\032+.google.chat.v1.Replac" - + "eMessageCardsResponse\"6\202\323\344\223\0020\"+/v1/{name" - + "=spaces/*/messages/*}:replaceCards:\001*\032\340\021" - + "\312A\023chat.googleapis.com\322A\306\021https://www.go" - + "ogleapis.com/auth/chat.admin.delete,http" - + "s://www.googleapis.com/auth/chat.admin.m" - + "emberships,https://www.googleapis.com/au" - + "th/chat.admin.memberships.readonly,https" - + "://www.googleapis.com/auth/chat.admin.sp" - + "aces,https://www.googleapis.com/auth/cha" - + "t.admin.spaces.readonly,https://www.goog" - + "leapis.com/auth/chat.app.all.memberships" - + ".readonly,https://www.googleapis.com/aut" - + "h/chat.app.all.messages.readonly,https:/" - + "/www.googleapis.com/auth/chat.app.all.sp" - + "aces.readonly,https://www.googleapis.com" - + "/auth/chat.app.delete,https://www.google" - + "apis.com/auth/chat.app.memberships,https" - + "://www.googleapis.com/auth/chat.app.memb" - + "erships.readonly,https://www.googleapis." - + "com/auth/chat.app.messages.readonly,http" - + "s://www.googleapis.com/auth/chat.app.spa" - + "ces,https://www.googleapis.com/auth/chat" - + ".app.spaces.create,https://www.googleapi" - + "s.com/auth/chat.app.spaces.readonly,http" - + "s://www.googleapis.com/auth/chat.bot,htt" - + "ps://www.googleapis.com/auth/chat.custom" - + "emojis,https://www.googleapis.com/auth/c" - + "hat.customemojis.readonly,https://www.go" - + "ogleapis.com/auth/chat.delete,https://ww" - + "w.googleapis.com/auth/chat.import,https:" - + "//www.googleapis.com/auth/chat.membershi" - + "ps,https://www.googleapis.com/auth/chat." - + "memberships.app,https://www.googleapis.c" - + "om/auth/chat.memberships.readonly,https:" - + "//www.googleapis.com/auth/chat.messages," - + "https://www.googleapis.com/auth/chat.mes" - + "sages.create,https://www.googleapis.com/" - + "auth/chat.messages.reactions,https://www" - + ".googleapis.com/auth/chat.messages.react" - + "ions.create,https://www.googleapis.com/a" - + "uth/chat.messages.reactions.readonly,htt" - + "ps://www.googleapis.com/auth/chat.messag" + + "pace_read_state\022\353\001\n\025UpdateThreadReadStat" + + "e\022,.google.chat.v1.UpdateThreadReadState" + + "Request\032\037.google.chat.v1.ThreadReadState" + + "\"\202\001\332A\035thread_read_state,update_mask\202\323\344\223\002" + + "\\2G/v1/{thread_read_state.name=users/*/s" + + "paces/*/threads/*/threadReadState}:\021thre" + + "ad_read_state\022\246\001\n\022GetThreadReadState\022).g" + + "oogle.chat.v1.GetThreadReadStateRequest\032" + + "\037.google.chat.v1.ThreadReadState\"D\332A\004nam" + + "e\202\323\344\223\0027\0225/v1/{name=users/*/spaces/*/thre" + + "ads/*/threadReadState}\022\207\001\n\017GetAvailabili" + + "ty\022&.google.chat.v1.GetAvailabilityReque" + + "st\032\034.google.chat.v1.Availability\".\332A\004nam" + + "e\202\323\344\223\002!\022\037/v1/{name=users/*/availability}" + + "\022\212\001\n\014MarkAsActive\022#.google.chat.v1.MarkA" + + "sActiveRequest\032\034.google.chat.v1.Availabi" + + "lity\"7\202\323\344\223\0021\",/v1/{name=users/*/availabi" + + "lity}:markAsActive:\001*\022\204\001\n\nMarkAsAway\022!.g" + + "oogle.chat.v1.MarkAsAwayRequest\032\034.google" + + ".chat.v1.Availability\"5\202\323\344\223\002/\"*/v1/{name" + + "=users/*/availability}:markAsAway:\001*\022\234\001\n" + + "\022MarkAsDoNotDisturb\022).google.chat.v1.Mar" + + "kAsDoNotDisturbRequest\032\034.google.chat.v1." + + "Availability\"=\202\323\344\223\0027\"2/v1/{name=users/*/" + + "availability}:markAsDoNotDisturb:\001*\022\274\001\n\022" + + "UpdateAvailability\022).google.chat.v1.Upda" + + "teAvailabilityRequest\032\034.google.chat.v1.A" + + "vailability\"]\332A\030availability,update_mask" + + "\202\323\344\223\002<2,/v1/{availability.name=users/*/a" + + "vailability}:\014availability\022\203\001\n\rGetSpaceE" + + "vent\022$.google.chat.v1.GetSpaceEventReque" + + "st\032\032.google.chat.v1.SpaceEvent\"0\332A\004name\202" + + "\323\344\223\002#\022!/v1/{name=spaces/*/spaceEvents/*}" + + "\022\235\001\n\017ListSpaceEvents\022&.google.chat.v1.Li" + + "stSpaceEventsRequest\032\'.google.chat.v1.Li" + + "stSpaceEventsResponse\"9\332A\rparent,filter\202" + + "\323\344\223\002#\022!/v1/{parent=spaces/*}/spaceEvents" + + "\022\300\001\n\033GetSpaceNotificationSetting\0222.googl" + + "e.chat.v1.GetSpaceNotificationSettingReq" + + "uest\032(.google.chat.v1.SpaceNotificationS" + + "etting\"C\332A\004name\202\323\344\223\0026\0224/v1/{name=users/*" + + "/spaces/*/spaceNotificationSetting}\022\240\002\n\036" + + "UpdateSpaceNotificationSetting\0225.google." + + "chat.v1.UpdateSpaceNotificationSettingRe" + + "quest\032(.google.chat.v1.SpaceNotification" + + "Setting\"\234\001\332A&space_notification_setting," + + "update_mask\202\323\344\223\002m2O/v1/{space_notificati" + + "on_setting.name=users/*/spaces/*/spaceNo" + + "tificationSetting}:\032space_notification_s" + + "etting\022\217\001\n\rCreateSection\022$.google.chat.v" + + "1.CreateSectionRequest\032\027.google.chat.v1." + + "Section\"?\332A\016parent,section\202\323\344\223\002(\"\035/v1/{p" + + "arent=users/*}/sections:\007section\022{\n\rDele" + + "teSection\022$.google.chat.v1.DeleteSection" + + "Request\032\026.google.protobuf.Empty\",\332A\004name" + + "\202\323\344\223\002\037*\035/v1/{name=users/*/sections/*}\022\234\001" + + "\n\rUpdateSection\022$.google.chat.v1.UpdateS" + + "ectionRequest\032\027.google.chat.v1.Section\"L" + + "\332A\023section,update_mask\202\323\344\223\00202%/v1/{secti" + + "on.name=users/*/sections/*}:\007section\022\211\001\n" + + "\014ListSections\022#.google.chat.v1.ListSecti" + + "onsRequest\032$.google.chat.v1.ListSections" + + "Response\".\332A\006parent\202\323\344\223\002\037\022\035/v1/{parent=u" + + "sers/*}/sections\022\225\001\n\017PositionSection\022&.g" + + "oogle.chat.v1.PositionSectionRequest\032\'.g" + + "oogle.chat.v1.PositionSectionResponse\"1\202" + + "\323\344\223\002+\"&/v1/{name=users/*/sections/*}:pos" + + "ition:\001*\022\235\001\n\020ListSectionItems\022\'.google.c" + + "hat.v1.ListSectionItemsRequest\032(.google." + + "chat.v1.ListSectionItemsResponse\"6\332A\006par" + + "ent\202\323\344\223\002\'\022%/v1/{parent=users/*/sections/" + + "*}/items\022\257\001\n\017MoveSectionItem\022&.google.ch" + + "at.v1.MoveSectionItemRequest\032\'.google.ch" + + "at.v1.MoveSectionItemResponse\"K\332A\023name,t" + + "arget_section\202\323\344\223\002/\"*/v1/{name=users/*/s" + + "ections/*/items/*}:move:\001*\022\246\001\n\023ReplaceMe" + + "ssageCards\022*.google.chat.v1.ReplaceMessa" + + "geCardsRequest\032+.google.chat.v1.ReplaceM" + + "essageCardsResponse\"6\202\323\344\223\0020\"+/v1/{name=s" + + "paces/*/messages/*}:replaceCards:\001*\032\340\021\312A" + + "\023chat.googleapis.com\322A\306\021https://www.goog" + + "leapis.com/auth/chat.admin.delete,https:" + + "//www.googleapis.com/auth/chat.admin.mem" + + "berships,https://www.googleapis.com/auth" + + "/chat.admin.memberships.readonly,https:/" + + "/www.googleapis.com/auth/chat.admin.spac" + + "es,https://www.googleapis.com/auth/chat." + + "admin.spaces.readonly,https://www.google" + + "apis.com/auth/chat.app.all.memberships.r" + + "eadonly,https://www.googleapis.com/auth/" + + "chat.app.all.messages.readonly,https://w" + + "ww.googleapis.com/auth/chat.app.all.spac" + "es.readonly,https://www.googleapis.com/a" - + "uth/chat.spaces,https://www.googleapis.c" - + "om/auth/chat.spaces.create,https://www.g" - + "oogleapis.com/auth/chat.spaces.pins,http" - + "s://www.googleapis.com/auth/chat.spaces." - + "pins.readonly,https://www.googleapis.com" - + "/auth/chat.spaces.readonly,https://www.g" - + "oogleapis.com/auth/chat.users.availabili" - + "ty,https://www.googleapis.com/auth/chat." - + "users.availability.readonly,https://www." - + "googleapis.com/auth/chat.users.readstate" + + "uth/chat.app.delete,https://www.googleap" + + "is.com/auth/chat.app.memberships,https:/" + + "/www.googleapis.com/auth/chat.app.member" + + "ships.readonly,https://www.googleapis.co" + + "m/auth/chat.app.messages.readonly,https:" + + "//www.googleapis.com/auth/chat.app.space" + + "s,https://www.googleapis.com/auth/chat.a" + + "pp.spaces.create,https://www.googleapis." + + "com/auth/chat.app.spaces.readonly,https:" + + "//www.googleapis.com/auth/chat.bot,https" + + "://www.googleapis.com/auth/chat.customem" + + "ojis,https://www.googleapis.com/auth/cha" + + "t.customemojis.readonly,https://www.goog" + + "leapis.com/auth/chat.delete,https://www." + + "googleapis.com/auth/chat.import,https://" + + "www.googleapis.com/auth/chat.memberships" + + ",https://www.googleapis.com/auth/chat.me" + + "mberships.app,https://www.googleapis.com" + + "/auth/chat.memberships.readonly,https://" + + "www.googleapis.com/auth/chat.messages,ht" + + "tps://www.googleapis.com/auth/chat.messa" + + "ges.create,https://www.googleapis.com/au" + + "th/chat.messages.reactions,https://www.g" + + "oogleapis.com/auth/chat.messages.reactio" + + "ns.create,https://www.googleapis.com/aut" + + "h/chat.messages.reactions.readonly,https" + + "://www.googleapis.com/auth/chat.messages" + + ".readonly,https://www.googleapis.com/aut" + + "h/chat.spaces,https://www.googleapis.com" + + "/auth/chat.spaces.create,https://www.goo" + + "gleapis.com/auth/chat.spaces.pins,https:" + + "//www.googleapis.com/auth/chat.spaces.pi" + + "ns.readonly,https://www.googleapis.com/a" + + "uth/chat.spaces.readonly,https://www.goo" + + "gleapis.com/auth/chat.users.availability" + ",https://www.googleapis.com/auth/chat.us" - + "ers.readstate.readonly,https://www.googl" - + "eapis.com/auth/chat.users.sections,https" - + "://www.googleapis.com/auth/chat.users.se" - + "ctions.readonly,https://www.googleapis.c" - + "om/auth/chat.users.spacesettingsB\251\001\n\022com" - + ".google.chat.v1B\020ChatServiceProtoP\001Z,clo" - + "ud.google.com/go/chat/apiv1/chatpb;chatp" - + "b\242\002\013DYNAPIProto\252\002\023Google.Apps.Chat.V1\312\002\023" - + "Google\\Apps\\Chat\\V1\352\002\026Google::Apps::Chat" - + "::V1b\006proto3" + + "ers.availability.readonly,https://www.go" + + "ogleapis.com/auth/chat.users.readstate,h" + + "ttps://www.googleapis.com/auth/chat.user" + + "s.readstate.readonly,https://www.googlea" + + "pis.com/auth/chat.users.sections,https:/" + + "/www.googleapis.com/auth/chat.users.sect" + + "ions.readonly,https://www.googleapis.com" + + "/auth/chat.users.spacesettingsB\251\001\n\022com.g" + + "oogle.chat.v1B\020ChatServiceProtoP\001Z,cloud" + + ".google.com/go/chat/apiv1/chatpb;chatpb\242" + + "\002\013DYNAPIProto\252\002\023Google.Apps.Chat.V1\312\002\023Go" + + "ogle\\Apps\\Chat\\V1\352\002\026Google::Apps::Chat::" + + "V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/java-chat/proto-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ThreadReadStateProto.java b/java-chat/proto-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ThreadReadStateProto.java index 9803d66f6e76..8e64446e907b 100644 --- a/java-chat/proto-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ThreadReadStateProto.java +++ b/java-chat/proto-google-cloud-chat-v1/src/main/java/com/google/chat/v1/ThreadReadStateProto.java @@ -48,6 +48,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_chat_v1_GetThreadReadStateRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_chat_v1_GetThreadReadStateRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_chat_v1_UpdateThreadReadStateRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_chat_v1_UpdateThreadReadStateRequest_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -59,20 +63,25 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { java.lang.String[] descriptorData = { "\n&google/chat/v1/thread_read_state.proto" + "\022\016google.chat.v1\032\037google/api/field_behav" - + "ior.proto\032\031google/api/resource.proto\032\037go" - + "ogle/protobuf/timestamp.proto\"\314\001\n\017Thread" - + "ReadState\022\014\n\004name\030\001 \001(\t\0222\n\016last_read_tim" - + "e\030\002 \001(\0132\032.google.protobuf.Timestamp:w\352At" - + "\n#chat.googleapis.com/ThreadReadState\022 + * Request message for UpdateThreadReadState API. + *
                      + * + * Protobuf type {@code google.chat.v1.UpdateThreadReadStateRequest} + */ +@com.google.protobuf.Generated +public final class UpdateThreadReadStateRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.chat.v1.UpdateThreadReadStateRequest) + UpdateThreadReadStateRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "UpdateThreadReadStateRequest"); + } + + // Use UpdateThreadReadStateRequest.newBuilder() to construct. + private UpdateThreadReadStateRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private UpdateThreadReadStateRequest() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.chat.v1.ThreadReadStateProto + .internal_static_google_chat_v1_UpdateThreadReadStateRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.chat.v1.ThreadReadStateProto + .internal_static_google_chat_v1_UpdateThreadReadStateRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.chat.v1.UpdateThreadReadStateRequest.class, + com.google.chat.v1.UpdateThreadReadStateRequest.Builder.class); + } + + private int bitField0_; + public static final int THREAD_READ_STATE_FIELD_NUMBER = 1; + private com.google.chat.v1.ThreadReadState threadReadState_; + + /** + * + * + *
                      +   * Required. The thread read state and fields to update.
                      +   *
                      +   * Only supports updating read state for the calling user.
                      +   *
                      +   * To refer to the calling user, set one of the following:
                      +   *
                      +   * - The `me` alias. For example,
                      +   * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their Workspace email address. For example,
                      +   * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their user id. For example,
                      +   * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +   * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the threadReadState field is set. + */ + @java.lang.Override + public boolean hasThreadReadState() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Required. The thread read state and fields to update.
                      +   *
                      +   * Only supports updating read state for the calling user.
                      +   *
                      +   * To refer to the calling user, set one of the following:
                      +   *
                      +   * - The `me` alias. For example,
                      +   * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their Workspace email address. For example,
                      +   * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their user id. For example,
                      +   * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +   * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The threadReadState. + */ + @java.lang.Override + public com.google.chat.v1.ThreadReadState getThreadReadState() { + return threadReadState_ == null + ? com.google.chat.v1.ThreadReadState.getDefaultInstance() + : threadReadState_; + } + + /** + * + * + *
                      +   * Required. The thread read state and fields to update.
                      +   *
                      +   * Only supports updating read state for the calling user.
                      +   *
                      +   * To refer to the calling user, set one of the following:
                      +   *
                      +   * - The `me` alias. For example,
                      +   * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their Workspace email address. For example,
                      +   * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their user id. For example,
                      +   * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +   * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.chat.v1.ThreadReadStateOrBuilder getThreadReadStateOrBuilder() { + return threadReadState_ == null + ? com.google.chat.v1.ThreadReadState.getDefaultInstance() + : threadReadState_; + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + + /** + * + * + *
                      +   * Required. The field paths to update. Currently supported field paths:
                      +   *
                      +   * - `last_read_time`
                      +   *
                      +   * When `last_read_time` is before the latest message create time, the thread
                      +   * appears as unread in the UI.
                      +   *
                      +   * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +   * later than the latest message create time. Future timestamps are coerced to
                      +   * the current request time. Setting a negative timestamp (before
                      +   * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Required. The field paths to update. Currently supported field paths:
                      +   *
                      +   * - `last_read_time`
                      +   *
                      +   * When `last_read_time` is before the latest message create time, the thread
                      +   * appears as unread in the UI.
                      +   *
                      +   * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +   * later than the latest message create time. Future timestamps are coerced to
                      +   * the current request time. Setting a negative timestamp (before
                      +   * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + /** + * + * + *
                      +   * Required. The field paths to update. Currently supported field paths:
                      +   *
                      +   * - `last_read_time`
                      +   *
                      +   * When `last_read_time` is before the latest message create time, the thread
                      +   * appears as unread in the UI.
                      +   *
                      +   * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +   * later than the latest message create time. Future timestamps are coerced to
                      +   * the current request time. Setting a negative timestamp (before
                      +   * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getThreadReadState()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getUpdateMask()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getThreadReadState()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.chat.v1.UpdateThreadReadStateRequest)) { + return super.equals(obj); + } + com.google.chat.v1.UpdateThreadReadStateRequest other = + (com.google.chat.v1.UpdateThreadReadStateRequest) obj; + + if (hasThreadReadState() != other.hasThreadReadState()) return false; + if (hasThreadReadState()) { + if (!getThreadReadState().equals(other.getThreadReadState())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasThreadReadState()) { + hash = (37 * hash) + THREAD_READ_STATE_FIELD_NUMBER; + hash = (53 * hash) + getThreadReadState().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.chat.v1.UpdateThreadReadStateRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Request message for UpdateThreadReadState API.
                      +   * 
                      + * + * Protobuf type {@code google.chat.v1.UpdateThreadReadStateRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.chat.v1.UpdateThreadReadStateRequest) + com.google.chat.v1.UpdateThreadReadStateRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.chat.v1.ThreadReadStateProto + .internal_static_google_chat_v1_UpdateThreadReadStateRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.chat.v1.ThreadReadStateProto + .internal_static_google_chat_v1_UpdateThreadReadStateRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.chat.v1.UpdateThreadReadStateRequest.class, + com.google.chat.v1.UpdateThreadReadStateRequest.Builder.class); + } + + // Construct using com.google.chat.v1.UpdateThreadReadStateRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetThreadReadStateFieldBuilder(); + internalGetUpdateMaskFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + threadReadState_ = null; + if (threadReadStateBuilder_ != null) { + threadReadStateBuilder_.dispose(); + threadReadStateBuilder_ = null; + } + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.chat.v1.ThreadReadStateProto + .internal_static_google_chat_v1_UpdateThreadReadStateRequest_descriptor; + } + + @java.lang.Override + public com.google.chat.v1.UpdateThreadReadStateRequest getDefaultInstanceForType() { + return com.google.chat.v1.UpdateThreadReadStateRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.chat.v1.UpdateThreadReadStateRequest build() { + com.google.chat.v1.UpdateThreadReadStateRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.chat.v1.UpdateThreadReadStateRequest buildPartial() { + com.google.chat.v1.UpdateThreadReadStateRequest result = + new com.google.chat.v1.UpdateThreadReadStateRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.chat.v1.UpdateThreadReadStateRequest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.threadReadState_ = + threadReadStateBuilder_ == null ? threadReadState_ : threadReadStateBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.updateMask_ = updateMaskBuilder_ == null ? updateMask_ : updateMaskBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.chat.v1.UpdateThreadReadStateRequest) { + return mergeFrom((com.google.chat.v1.UpdateThreadReadStateRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.chat.v1.UpdateThreadReadStateRequest other) { + if (other == com.google.chat.v1.UpdateThreadReadStateRequest.getDefaultInstance()) + return this; + if (other.hasThreadReadState()) { + mergeThreadReadState(other.getThreadReadState()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetThreadReadStateFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.chat.v1.ThreadReadState threadReadState_; + private com.google.protobuf.SingleFieldBuilder< + com.google.chat.v1.ThreadReadState, + com.google.chat.v1.ThreadReadState.Builder, + com.google.chat.v1.ThreadReadStateOrBuilder> + threadReadStateBuilder_; + + /** + * + * + *
                      +     * Required. The thread read state and fields to update.
                      +     *
                      +     * Only supports updating read state for the calling user.
                      +     *
                      +     * To refer to the calling user, set one of the following:
                      +     *
                      +     * - The `me` alias. For example,
                      +     * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their Workspace email address. For example,
                      +     * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their user id. For example,
                      +     * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +     * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the threadReadState field is set. + */ + public boolean hasThreadReadState() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * Required. The thread read state and fields to update.
                      +     *
                      +     * Only supports updating read state for the calling user.
                      +     *
                      +     * To refer to the calling user, set one of the following:
                      +     *
                      +     * - The `me` alias. For example,
                      +     * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their Workspace email address. For example,
                      +     * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their user id. For example,
                      +     * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +     * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The threadReadState. + */ + public com.google.chat.v1.ThreadReadState getThreadReadState() { + if (threadReadStateBuilder_ == null) { + return threadReadState_ == null + ? com.google.chat.v1.ThreadReadState.getDefaultInstance() + : threadReadState_; + } else { + return threadReadStateBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Required. The thread read state and fields to update.
                      +     *
                      +     * Only supports updating read state for the calling user.
                      +     *
                      +     * To refer to the calling user, set one of the following:
                      +     *
                      +     * - The `me` alias. For example,
                      +     * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their Workspace email address. For example,
                      +     * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their user id. For example,
                      +     * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +     * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setThreadReadState(com.google.chat.v1.ThreadReadState value) { + if (threadReadStateBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + threadReadState_ = value; + } else { + threadReadStateBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The thread read state and fields to update.
                      +     *
                      +     * Only supports updating read state for the calling user.
                      +     *
                      +     * To refer to the calling user, set one of the following:
                      +     *
                      +     * - The `me` alias. For example,
                      +     * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their Workspace email address. For example,
                      +     * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their user id. For example,
                      +     * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +     * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setThreadReadState(com.google.chat.v1.ThreadReadState.Builder builderForValue) { + if (threadReadStateBuilder_ == null) { + threadReadState_ = builderForValue.build(); + } else { + threadReadStateBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The thread read state and fields to update.
                      +     *
                      +     * Only supports updating read state for the calling user.
                      +     *
                      +     * To refer to the calling user, set one of the following:
                      +     *
                      +     * - The `me` alias. For example,
                      +     * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their Workspace email address. For example,
                      +     * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their user id. For example,
                      +     * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +     * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeThreadReadState(com.google.chat.v1.ThreadReadState value) { + if (threadReadStateBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && threadReadState_ != null + && threadReadState_ != com.google.chat.v1.ThreadReadState.getDefaultInstance()) { + getThreadReadStateBuilder().mergeFrom(value); + } else { + threadReadState_ = value; + } + } else { + threadReadStateBuilder_.mergeFrom(value); + } + if (threadReadState_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Required. The thread read state and fields to update.
                      +     *
                      +     * Only supports updating read state for the calling user.
                      +     *
                      +     * To refer to the calling user, set one of the following:
                      +     *
                      +     * - The `me` alias. For example,
                      +     * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their Workspace email address. For example,
                      +     * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their user id. For example,
                      +     * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +     * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearThreadReadState() { + bitField0_ = (bitField0_ & ~0x00000001); + threadReadState_ = null; + if (threadReadStateBuilder_ != null) { + threadReadStateBuilder_.dispose(); + threadReadStateBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The thread read state and fields to update.
                      +     *
                      +     * Only supports updating read state for the calling user.
                      +     *
                      +     * To refer to the calling user, set one of the following:
                      +     *
                      +     * - The `me` alias. For example,
                      +     * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their Workspace email address. For example,
                      +     * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their user id. For example,
                      +     * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +     * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.chat.v1.ThreadReadState.Builder getThreadReadStateBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetThreadReadStateFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Required. The thread read state and fields to update.
                      +     *
                      +     * Only supports updating read state for the calling user.
                      +     *
                      +     * To refer to the calling user, set one of the following:
                      +     *
                      +     * - The `me` alias. For example,
                      +     * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their Workspace email address. For example,
                      +     * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their user id. For example,
                      +     * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +     * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.chat.v1.ThreadReadStateOrBuilder getThreadReadStateOrBuilder() { + if (threadReadStateBuilder_ != null) { + return threadReadStateBuilder_.getMessageOrBuilder(); + } else { + return threadReadState_ == null + ? com.google.chat.v1.ThreadReadState.getDefaultInstance() + : threadReadState_; + } + } + + /** + * + * + *
                      +     * Required. The thread read state and fields to update.
                      +     *
                      +     * Only supports updating read state for the calling user.
                      +     *
                      +     * To refer to the calling user, set one of the following:
                      +     *
                      +     * - The `me` alias. For example,
                      +     * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their Workspace email address. For example,
                      +     * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * - Their user id. For example,
                      +     * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +     *
                      +     * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +     * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.chat.v1.ThreadReadState, + com.google.chat.v1.ThreadReadState.Builder, + com.google.chat.v1.ThreadReadStateOrBuilder> + internalGetThreadReadStateFieldBuilder() { + if (threadReadStateBuilder_ == null) { + threadReadStateBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.chat.v1.ThreadReadState, + com.google.chat.v1.ThreadReadState.Builder, + com.google.chat.v1.ThreadReadStateOrBuilder>( + getThreadReadState(), getParentForChildren(), isClean()); + threadReadState_ = null; + } + return threadReadStateBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + + /** + * + * + *
                      +     * Required. The field paths to update. Currently supported field paths:
                      +     *
                      +     * - `last_read_time`
                      +     *
                      +     * When `last_read_time` is before the latest message create time, the thread
                      +     * appears as unread in the UI.
                      +     *
                      +     * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +     * later than the latest message create time. Future timestamps are coerced to
                      +     * the current request time. Setting a negative timestamp (before
                      +     * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +     * Required. The field paths to update. Currently supported field paths:
                      +     *
                      +     * - `last_read_time`
                      +     *
                      +     * When `last_read_time` is before the latest message create time, the thread
                      +     * appears as unread in the UI.
                      +     *
                      +     * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +     * later than the latest message create time. Future timestamps are coerced to
                      +     * the current request time. Setting a negative timestamp (before
                      +     * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Required. The field paths to update. Currently supported field paths:
                      +     *
                      +     * - `last_read_time`
                      +     *
                      +     * When `last_read_time` is before the latest message create time, the thread
                      +     * appears as unread in the UI.
                      +     *
                      +     * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +     * later than the latest message create time. Future timestamps are coerced to
                      +     * the current request time. Setting a negative timestamp (before
                      +     * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + } else { + updateMaskBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The field paths to update. Currently supported field paths:
                      +     *
                      +     * - `last_read_time`
                      +     *
                      +     * When `last_read_time` is before the latest message create time, the thread
                      +     * appears as unread in the UI.
                      +     *
                      +     * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +     * later than the latest message create time. Future timestamps are coerced to
                      +     * the current request time. Setting a negative timestamp (before
                      +     * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The field paths to update. Currently supported field paths:
                      +     *
                      +     * - `last_read_time`
                      +     *
                      +     * When `last_read_time` is before the latest message create time, the thread
                      +     * appears as unread in the UI.
                      +     *
                      +     * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +     * later than the latest message create time. Future timestamps are coerced to
                      +     * the current request time. Setting a negative timestamp (before
                      +     * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && updateMask_ != null + && updateMask_ != com.google.protobuf.FieldMask.getDefaultInstance()) { + getUpdateMaskBuilder().mergeFrom(value); + } else { + updateMask_ = value; + } + } else { + updateMaskBuilder_.mergeFrom(value); + } + if (updateMask_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Required. The field paths to update. Currently supported field paths:
                      +     *
                      +     * - `last_read_time`
                      +     *
                      +     * When `last_read_time` is before the latest message create time, the thread
                      +     * appears as unread in the UI.
                      +     *
                      +     * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +     * later than the latest message create time. Future timestamps are coerced to
                      +     * the current request time. Setting a negative timestamp (before
                      +     * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearUpdateMask() { + bitField0_ = (bitField0_ & ~0x00000002); + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Required. The field paths to update. Currently supported field paths:
                      +     *
                      +     * - `last_read_time`
                      +     *
                      +     * When `last_read_time` is before the latest message create time, the thread
                      +     * appears as unread in the UI.
                      +     *
                      +     * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +     * later than the latest message create time. Future timestamps are coerced to
                      +     * the current request time. Setting a negative timestamp (before
                      +     * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetUpdateMaskFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Required. The field paths to update. Currently supported field paths:
                      +     *
                      +     * - `last_read_time`
                      +     *
                      +     * When `last_read_time` is before the latest message create time, the thread
                      +     * appears as unread in the UI.
                      +     *
                      +     * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +     * later than the latest message create time. Future timestamps are coerced to
                      +     * the current request time. Setting a negative timestamp (before
                      +     * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + + /** + * + * + *
                      +     * Required. The field paths to update. Currently supported field paths:
                      +     *
                      +     * - `last_read_time`
                      +     *
                      +     * When `last_read_time` is before the latest message create time, the thread
                      +     * appears as unread in the UI.
                      +     *
                      +     * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +     * later than the latest message create time. Future timestamps are coerced to
                      +     * the current request time. Setting a negative timestamp (before
                      +     * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +     * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + internalGetUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.chat.v1.UpdateThreadReadStateRequest) + } + + // @@protoc_insertion_point(class_scope:google.chat.v1.UpdateThreadReadStateRequest) + private static final com.google.chat.v1.UpdateThreadReadStateRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.chat.v1.UpdateThreadReadStateRequest(); + } + + public static com.google.chat.v1.UpdateThreadReadStateRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateThreadReadStateRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.chat.v1.UpdateThreadReadStateRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-chat/proto-google-cloud-chat-v1/src/main/java/com/google/chat/v1/UpdateThreadReadStateRequestOrBuilder.java b/java-chat/proto-google-cloud-chat-v1/src/main/java/com/google/chat/v1/UpdateThreadReadStateRequestOrBuilder.java new file mode 100644 index 000000000000..293657824b06 --- /dev/null +++ b/java-chat/proto-google-cloud-chat-v1/src/main/java/com/google/chat/v1/UpdateThreadReadStateRequestOrBuilder.java @@ -0,0 +1,186 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/chat/v1/thread_read_state.proto +// Protobuf Java Version: 4.33.6 + +package com.google.chat.v1; + +@com.google.protobuf.Generated +public interface UpdateThreadReadStateRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.chat.v1.UpdateThreadReadStateRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Required. The thread read state and fields to update.
                      +   *
                      +   * Only supports updating read state for the calling user.
                      +   *
                      +   * To refer to the calling user, set one of the following:
                      +   *
                      +   * - The `me` alias. For example,
                      +   * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their Workspace email address. For example,
                      +   * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their user id. For example,
                      +   * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +   * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the threadReadState field is set. + */ + boolean hasThreadReadState(); + + /** + * + * + *
                      +   * Required. The thread read state and fields to update.
                      +   *
                      +   * Only supports updating read state for the calling user.
                      +   *
                      +   * To refer to the calling user, set one of the following:
                      +   *
                      +   * - The `me` alias. For example,
                      +   * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their Workspace email address. For example,
                      +   * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their user id. For example,
                      +   * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +   * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The threadReadState. + */ + com.google.chat.v1.ThreadReadState getThreadReadState(); + + /** + * + * + *
                      +   * Required. The thread read state and fields to update.
                      +   *
                      +   * Only supports updating read state for the calling user.
                      +   *
                      +   * To refer to the calling user, set one of the following:
                      +   *
                      +   * - The `me` alias. For example,
                      +   * `users/me/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their Workspace email address. For example,
                      +   * `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * - Their user id. For example,
                      +   * `users/123456789/spaces/{space}/threads/{thread}/threadReadState`.
                      +   *
                      +   * Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState`
                      +   * 
                      + * + * + * .google.chat.v1.ThreadReadState thread_read_state = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.chat.v1.ThreadReadStateOrBuilder getThreadReadStateOrBuilder(); + + /** + * + * + *
                      +   * Required. The field paths to update. Currently supported field paths:
                      +   *
                      +   * - `last_read_time`
                      +   *
                      +   * When `last_read_time` is before the latest message create time, the thread
                      +   * appears as unread in the UI.
                      +   *
                      +   * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +   * later than the latest message create time. Future timestamps are coerced to
                      +   * the current request time. Setting a negative timestamp (before
                      +   * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + + /** + * + * + *
                      +   * Required. The field paths to update. Currently supported field paths:
                      +   *
                      +   * - `last_read_time`
                      +   *
                      +   * When `last_read_time` is before the latest message create time, the thread
                      +   * appears as unread in the UI.
                      +   *
                      +   * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +   * later than the latest message create time. Future timestamps are coerced to
                      +   * the current request time. Setting a negative timestamp (before
                      +   * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + + /** + * + * + *
                      +   * Required. The field paths to update. Currently supported field paths:
                      +   *
                      +   * - `last_read_time`
                      +   *
                      +   * When `last_read_time` is before the latest message create time, the thread
                      +   * appears as unread in the UI.
                      +   *
                      +   * To mark the thread as read, set `last_read_time` to a timestamp equal to or
                      +   * later than the latest message create time. Future timestamps are coerced to
                      +   * the current request time. Setting a negative timestamp (before
                      +   * `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error.
                      +   * 
                      + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); +} diff --git a/java-chat/proto-google-cloud-chat-v1/src/main/proto/google/chat/v1/chat_service.proto b/java-chat/proto-google-cloud-chat-v1/src/main/proto/google/chat/v1/chat_service.proto index b4bdf14da99c..bfeba9a69924 100644 --- a/java-chat/proto-google-cloud-chat-v1/src/main/proto/google/chat/v1/chat_service.proto +++ b/java-chat/proto-google-cloud-chat-v1/src/main/proto/google/chat/v1/chat_service.proto @@ -1174,6 +1174,25 @@ service ChatService { option (google.api.method_signature) = "space_read_state,update_mask"; } + // Updates a user's read state within a thread, used to identify read and + // unread messages. For an example, see [Update a user's thread read + // state](https://developers.google.com/workspace/chat/update-thread-read-state). + // + // Requires [user + // authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user) + // with the [authorization + // scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes): + // + // - `https://www.googleapis.com/auth/chat.users.readstate` + rpc UpdateThreadReadState(UpdateThreadReadStateRequest) + returns (ThreadReadState) { + option (google.api.http) = { + patch: "/v1/{thread_read_state.name=users/*/spaces/*/threads/*/threadReadState}" + body: "thread_read_state" + }; + option (google.api.method_signature) = "thread_read_state,update_mask"; + } + // Returns details about a user's read state within a thread, used to identify // read and unread messages. For an example, see [Get details about a user's // thread read diff --git a/java-chat/proto-google-cloud-chat-v1/src/main/proto/google/chat/v1/thread_read_state.proto b/java-chat/proto-google-cloud-chat-v1/src/main/proto/google/chat/v1/thread_read_state.proto index 23934346840d..4d9c833f2bd2 100644 --- a/java-chat/proto-google-cloud-chat-v1/src/main/proto/google/chat/v1/thread_read_state.proto +++ b/java-chat/proto-google-cloud-chat-v1/src/main/proto/google/chat/v1/thread_read_state.proto @@ -18,6 +18,7 @@ package google.chat.v1; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; +import "google/protobuf/field_mask.proto"; import "google/protobuf/timestamp.proto"; option csharp_namespace = "Google.Apps.Chat.V1"; @@ -73,3 +74,39 @@ message GetThreadReadStateRequest { } ]; } + +// Request message for UpdateThreadReadState API. +message UpdateThreadReadStateRequest { + // Required. The thread read state and fields to update. + // + // Only supports updating read state for the calling user. + // + // To refer to the calling user, set one of the following: + // + // - The `me` alias. For example, + // `users/me/spaces/{space}/threads/{thread}/threadReadState`. + // + // - Their Workspace email address. For example, + // `users/user@example.com/spaces/{space}/threads/{thread}/threadReadState`. + // + // - Their user id. For example, + // `users/123456789/spaces/{space}/threads/{thread}/threadReadState`. + // + // Format: `users/{user}/spaces/{space}/threads/{thread}/threadReadState` + ThreadReadState thread_read_state = 1 + [(google.api.field_behavior) = REQUIRED]; + + // Required. The field paths to update. Currently supported field paths: + // + // - `last_read_time` + // + // When `last_read_time` is before the latest message create time, the thread + // appears as unread in the UI. + // + // To mark the thread as read, set `last_read_time` to a timestamp equal to or + // later than the latest message create time. Future timestamps are coerced to + // the current request time. Setting a negative timestamp (before + // `1970-01-01T00:00:00Z`) returns an `INVALID_ARGUMENT` error. + google.protobuf.FieldMask update_mask = 2 + [(google.api.field_behavior) = REQUIRED]; +} diff --git a/java-chat/samples/snippets/generated/com/google/chat/v1/chatservice/updatethreadreadstate/AsyncUpdateThreadReadState.java b/java-chat/samples/snippets/generated/com/google/chat/v1/chatservice/updatethreadreadstate/AsyncUpdateThreadReadState.java new file mode 100644 index 000000000000..e40529ccf348 --- /dev/null +++ b/java-chat/samples/snippets/generated/com/google/chat/v1/chatservice/updatethreadreadstate/AsyncUpdateThreadReadState.java @@ -0,0 +1,51 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.chat.v1.samples; + +// [START chat_v1_generated_ChatService_UpdateThreadReadState_async] +import com.google.api.core.ApiFuture; +import com.google.chat.v1.ChatServiceClient; +import com.google.chat.v1.ThreadReadState; +import com.google.chat.v1.UpdateThreadReadStateRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateThreadReadState { + + public static void main(String[] args) throws Exception { + asyncUpdateThreadReadState(); + } + + public static void asyncUpdateThreadReadState() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ChatServiceClient chatServiceClient = ChatServiceClient.create()) { + UpdateThreadReadStateRequest request = + UpdateThreadReadStateRequest.newBuilder() + .setThreadReadState(ThreadReadState.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ApiFuture future = + chatServiceClient.updateThreadReadStateCallable().futureCall(request); + // Do something. + ThreadReadState response = future.get(); + } + } +} +// [END chat_v1_generated_ChatService_UpdateThreadReadState_async] diff --git a/java-chat/samples/snippets/generated/com/google/chat/v1/chatservice/updatethreadreadstate/SyncUpdateThreadReadState.java b/java-chat/samples/snippets/generated/com/google/chat/v1/chatservice/updatethreadreadstate/SyncUpdateThreadReadState.java new file mode 100644 index 000000000000..618653a40156 --- /dev/null +++ b/java-chat/samples/snippets/generated/com/google/chat/v1/chatservice/updatethreadreadstate/SyncUpdateThreadReadState.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.chat.v1.samples; + +// [START chat_v1_generated_ChatService_UpdateThreadReadState_sync] +import com.google.chat.v1.ChatServiceClient; +import com.google.chat.v1.ThreadReadState; +import com.google.chat.v1.UpdateThreadReadStateRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateThreadReadState { + + public static void main(String[] args) throws Exception { + syncUpdateThreadReadState(); + } + + public static void syncUpdateThreadReadState() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ChatServiceClient chatServiceClient = ChatServiceClient.create()) { + UpdateThreadReadStateRequest request = + UpdateThreadReadStateRequest.newBuilder() + .setThreadReadState(ThreadReadState.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ThreadReadState response = chatServiceClient.updateThreadReadState(request); + } + } +} +// [END chat_v1_generated_ChatService_UpdateThreadReadState_sync] diff --git a/java-chat/samples/snippets/generated/com/google/chat/v1/chatservice/updatethreadreadstate/SyncUpdateThreadReadStateThreadreadstateFieldmask.java b/java-chat/samples/snippets/generated/com/google/chat/v1/chatservice/updatethreadreadstate/SyncUpdateThreadReadStateThreadreadstateFieldmask.java new file mode 100644 index 000000000000..e7a516babe06 --- /dev/null +++ b/java-chat/samples/snippets/generated/com/google/chat/v1/chatservice/updatethreadreadstate/SyncUpdateThreadReadStateThreadreadstateFieldmask.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.chat.v1.samples; + +// [START chat_v1_generated_ChatService_UpdateThreadReadState_ThreadreadstateFieldmask_sync] +import com.google.chat.v1.ChatServiceClient; +import com.google.chat.v1.ThreadReadState; +import com.google.protobuf.FieldMask; + +public class SyncUpdateThreadReadStateThreadreadstateFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateThreadReadStateThreadreadstateFieldmask(); + } + + public static void syncUpdateThreadReadStateThreadreadstateFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (ChatServiceClient chatServiceClient = ChatServiceClient.create()) { + ThreadReadState threadReadState = ThreadReadState.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + ThreadReadState response = + chatServiceClient.updateThreadReadState(threadReadState, updateMask); + } + } +} +// [END chat_v1_generated_ChatService_UpdateThreadReadState_ThreadreadstateFieldmask_sync] diff --git a/java-chronicle/README.md b/java-chronicle/README.md index 3426da96bbd3..6f707a49d391 100644 --- a/java-chronicle/README.md +++ b/java-chronicle/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-chronicle - 0.40.0 + 0.41.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-chronicle' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-chronicle:0.40.0' +implementation 'com.google.cloud:google-cloud-chronicle:0.41.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-chronicle" % "0.40.0" +libraryDependencies += "com.google.cloud" % "google-cloud-chronicle" % "0.41.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-chronicle/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-chronicle.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-chronicle/0.40.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-chronicle/0.41.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-cloudapiregistry/README.md b/java-cloudapiregistry/README.md index 448256745d1d..4d4a061db853 100644 --- a/java-cloudapiregistry/README.md +++ b/java-cloudapiregistry/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-cloudapiregistry - 0.21.0 + 0.22.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-cloudapiregistry' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-cloudapiregistry:0.21.0' +implementation 'com.google.cloud:google-cloud-cloudapiregistry:0.22.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-cloudapiregistry" % "0.21.0" +libraryDependencies += "com.google.cloud" % "google-cloud-cloudapiregistry" % "0.22.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-cloudapiregistry/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-cloudapiregistry.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudapiregistry/0.21.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudapiregistry/0.22.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-cloudbuild/README.md b/java-cloudbuild/README.md index 32010bd157a7..a770e6cf7d75 100644 --- a/java-cloudbuild/README.md +++ b/java-cloudbuild/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-build - 3.104.0 + 3.105.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-build' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-build:3.104.0' +implementation 'com.google.cloud:google-cloud-build:3.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.105.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-build/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-build.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-build/3.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-build/3.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-cloudcommerceconsumerprocurement/README.md b/java-cloudcommerceconsumerprocurement/README.md index 63a55a61bc51..ba4f619369f1 100644 --- a/java-cloudcommerceconsumerprocurement/README.md +++ b/java-cloudcommerceconsumerprocurement/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-cloudcommerceconsumerprocurement - 0.100.0 + 0.101.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-cloudcommerceconsumerprocurement' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-cloudcommerceconsumerprocurement:0.100.0' +implementation 'com.google.cloud:google-cloud-cloudcommerceconsumerprocurement:0.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-cloudcommerceconsumerprocurement" % "0.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-cloudcommerceconsumerprocurement" % "0.101.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-cloudcommerceconsumerprocurement/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-cloudcommerceconsumerprocurement.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudcommerceconsumerprocurement/0.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudcommerceconsumerprocurement/0.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-cloudcontrolspartner/README.md b/java-cloudcontrolspartner/README.md index 36e9bd643158..f22ac0a4d569 100644 --- a/java-cloudcontrolspartner/README.md +++ b/java-cloudcontrolspartner/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-cloudcontrolspartner - 0.66.0 + 0.67.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-cloudcontrolspartner' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-cloudcontrolspartner:0.66.0' +implementation 'com.google.cloud:google-cloud-cloudcontrolspartner:0.67.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-cloudcontrolspartner" % "0.66.0" +libraryDependencies += "com.google.cloud" % "google-cloud-cloudcontrolspartner" % "0.67.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-cloudcontrolspartner/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-cloudcontrolspartner.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudcontrolspartner/0.66.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudcontrolspartner/0.67.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-cloudquotas/README.md b/java-cloudquotas/README.md index c7052dc2a3c2..d8bf76ca93eb 100644 --- a/java-cloudquotas/README.md +++ b/java-cloudquotas/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-cloudquotas - 0.70.0 + 0.71.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-cloudquotas' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-cloudquotas:0.70.0' +implementation 'com.google.cloud:google-cloud-cloudquotas:0.71.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-cloudquotas" % "0.70.0" +libraryDependencies += "com.google.cloud" % "google-cloud-cloudquotas" % "0.71.0" ``` ## Authentication @@ -182,7 +182,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-cloudquotas/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-cloudquotas.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudquotas/0.70.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudquotas/0.71.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-cloudsecuritycompliance/README.md b/java-cloudsecuritycompliance/README.md index 46b5a1e53d5f..61db46fcca89 100644 --- a/java-cloudsecuritycompliance/README.md +++ b/java-cloudsecuritycompliance/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-cloudsecuritycompliance - 0.29.0 + 0.30.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-cloudsecuritycompliance' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-cloudsecuritycompliance:0.29.0' +implementation 'com.google.cloud:google-cloud-cloudsecuritycompliance:0.30.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-cloudsecuritycompliance" % "0.29.0" +libraryDependencies += "com.google.cloud" % "google-cloud-cloudsecuritycompliance" % "0.30.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-cloudsecuritycompliance/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-cloudsecuritycompliance.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudsecuritycompliance/0.29.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudsecuritycompliance/0.30.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-cloudsupport/README.md b/java-cloudsupport/README.md index dd0ced8c3cfe..6db54e1953a7 100644 --- a/java-cloudsupport/README.md +++ b/java-cloudsupport/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-cloudsupport - 0.86.0 + 0.87.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-cloudsupport' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-cloudsupport:0.86.0' +implementation 'com.google.cloud:google-cloud-cloudsupport:0.87.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-cloudsupport" % "0.86.0" +libraryDependencies += "com.google.cloud" % "google-cloud-cloudsupport" % "0.87.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-cloudsupport/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-cloudsupport.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudsupport/0.86.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-cloudsupport/0.87.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-commerceproducer/README.md b/java-commerceproducer/README.md index de38f816d758..ef7798a87807 100644 --- a/java-commerceproducer/README.md +++ b/java-commerceproducer/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-commerceproducer - 0.8.0 + 0.9.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-commerceproducer' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-commerceproducer:0.8.0' +implementation 'com.google.cloud:google-cloud-commerceproducer:0.9.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-commerceproducer" % "0.8.0" +libraryDependencies += "com.google.cloud" % "google-cloud-commerceproducer" % "0.9.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-commerceproducer/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-commerceproducer.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-commerceproducer/0.8.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-commerceproducer/0.9.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-compute/README.md b/java-compute/README.md index 2973a9eb11d8..a3fd8d8e30e1 100644 --- a/java-compute/README.md +++ b/java-compute/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-compute - 1.112.0 + 1.113.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-compute' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-compute:1.112.0' +implementation 'com.google.cloud:google-cloud-compute:1.113.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-compute" % "1.112.0" +libraryDependencies += "com.google.cloud" % "google-cloud-compute" % "1.113.0" ``` ## Authentication @@ -245,7 +245,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-compute/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-compute.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-compute/1.112.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-compute/1.113.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-compute/proto-google-cloud-compute-v1/src/main/java/com/google/cloud/compute/v1/BackendServiceHAPolicy.java b/java-compute/proto-google-cloud-compute-v1/src/main/java/com/google/cloud/compute/v1/BackendServiceHAPolicy.java index 3d0888254c7c..7f4c3c6e4e63 100644 --- a/java-compute/proto-google-cloud-compute-v1/src/main/java/com/google/cloud/compute/v1/BackendServiceHAPolicy.java +++ b/java-compute/proto-google-cloud-compute-v1/src/main/java/com/google/cloud/compute/v1/BackendServiceHAPolicy.java @@ -88,9 +88,6 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * @@ -310,9 +307,6 @@ private FastIPMove(int value) { * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * @@ -404,9 +398,6 @@ public boolean hasFastIPMove() { * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * @@ -506,9 +497,6 @@ public java.lang.String getFastIPMove() { * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * @@ -1051,9 +1039,6 @@ public Builder mergeFrom( * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * @@ -1144,9 +1129,6 @@ public boolean hasFastIPMove() { * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * @@ -1245,9 +1227,6 @@ public java.lang.String getFastIPMove() { * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * @@ -1346,9 +1325,6 @@ public com.google.protobuf.ByteString getFastIPMoveBytes() { * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * @@ -1446,9 +1422,6 @@ public Builder setFastIPMove(java.lang.String value) { * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * @@ -1542,9 +1515,6 @@ public Builder clearFastIPMove() { * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * diff --git a/java-compute/proto-google-cloud-compute-v1/src/main/java/com/google/cloud/compute/v1/BackendServiceHAPolicyOrBuilder.java b/java-compute/proto-google-cloud-compute-v1/src/main/java/com/google/cloud/compute/v1/BackendServiceHAPolicyOrBuilder.java index 6d1da74080a9..6e68e8bb8f07 100644 --- a/java-compute/proto-google-cloud-compute-v1/src/main/java/com/google/cloud/compute/v1/BackendServiceHAPolicyOrBuilder.java +++ b/java-compute/proto-google-cloud-compute-v1/src/main/java/com/google/cloud/compute/v1/BackendServiceHAPolicyOrBuilder.java @@ -45,9 +45,6 @@ public interface BackendServiceHAPolicyOrBuilder * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * @@ -136,9 +133,6 @@ public interface BackendServiceHAPolicyOrBuilder * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * @@ -227,9 +221,6 @@ public interface BackendServiceHAPolicyOrBuilder * Advertisement(RA) packet (IPv6). Google Cloud immediately but * temporarily associates the forwarding rule IP address with that VM, and * both new and in-flight packets are quickly delivered to that VM. - * - HA_CONTROLLER: The Backend Service is managed by a High Availability - * Controller. Failover and leader election are exclusively managed by the - * HA Controller service. * * * diff --git a/java-compute/proto-google-cloud-compute-v1/src/main/proto/google/cloud/compute/v1/compute.proto b/java-compute/proto-google-cloud-compute-v1/src/main/proto/google/cloud/compute/v1/compute.proto index 6ad144abe151..fd5672b56c87 100644 --- a/java-compute/proto-google-cloud-compute-v1/src/main/proto/google/cloud/compute/v1/compute.proto +++ b/java-compute/proto-google-cloud-compute-v1/src/main/proto/google/cloud/compute/v1/compute.proto @@ -14,7 +14,7 @@ // Generated by the disco-to-proto3-converter. DO NOT EDIT! // Source Discovery file: compute.v1.json -// Source file revision: 20261026 +// Source file revision: 20261106 // API name: compute // API version: v1 @@ -11298,9 +11298,6 @@ message BackendServiceHAPolicy { // Advertisement(RA) packet (IPv6). Google Cloud immediately but // temporarily associates the forwarding rule IP address with that VM, and // both new and in-flight packets are quickly delivered to that VM. - // - HA_CONTROLLER: The Backend Service is managed by a High Availability - // Controller. Failover and leader election are exclusively managed by the - // HA Controller service. // // // @@ -11386,9 +11383,6 @@ message BackendServiceHAPolicy { // Advertisement(RA) packet (IPv6). Google Cloud immediately but // temporarily associates the forwarding rule IP address with that VM, and // both new and in-flight packets are quickly delivered to that VM. - // - HA_CONTROLLER: The Backend Service is managed by a High Availability - // Controller. Failover and leader election are exclusively managed by the - // HA Controller service. // // // diff --git a/java-confidentialcomputing/README.md b/java-confidentialcomputing/README.md index 231f35fdf86f..f8cf59ecec18 100644 --- a/java-confidentialcomputing/README.md +++ b/java-confidentialcomputing/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-confidentialcomputing - 0.88.0 + 0.89.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-confidentialcomputing' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-confidentialcomputing:0.88.0' +implementation 'com.google.cloud:google-cloud-confidentialcomputing:0.89.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-confidentialcomputing" % "0.88.0" +libraryDependencies += "com.google.cloud" % "google-cloud-confidentialcomputing" % "0.89.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-confidentialcomputing/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-confidentialcomputing.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-confidentialcomputing/0.88.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-confidentialcomputing/0.89.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-configdelivery/README.md b/java-configdelivery/README.md index 2323b1c8df68..3b76250ed33c 100644 --- a/java-configdelivery/README.md +++ b/java-configdelivery/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-configdelivery - 0.36.0 + 0.37.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-configdelivery' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-configdelivery:0.36.0' +implementation 'com.google.cloud:google-cloud-configdelivery:0.37.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-configdelivery" % "0.36.0" +libraryDependencies += "com.google.cloud" % "google-cloud-configdelivery" % "0.37.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-configdelivery/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-configdelivery.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-configdelivery/0.36.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-configdelivery/0.37.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-connectgateway/README.md b/java-connectgateway/README.md index 8b15b6345a1f..470275182be6 100644 --- a/java-connectgateway/README.md +++ b/java-connectgateway/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-connectgateway - 0.54.0 + 0.55.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-connectgateway' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-connectgateway:0.54.0' +implementation 'com.google.cloud:google-cloud-connectgateway:0.55.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-connectgateway" % "0.54.0" +libraryDependencies += "com.google.cloud" % "google-cloud-connectgateway" % "0.55.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-connectgateway/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-connectgateway.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-connectgateway/0.54.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-connectgateway/0.55.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-contact-center-insights/README.md b/java-contact-center-insights/README.md index 66728154e4eb..b2979d574cc6 100644 --- a/java-contact-center-insights/README.md +++ b/java-contact-center-insights/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-contact-center-insights - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-contact-center-insights' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-contact-center-insights:2.102.0' +implementation 'com.google.cloud:google-cloud-contact-center-insights:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-contact-center-insights" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-contact-center-insights" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-contact-center-insights/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-contact-center-insights.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-contact-center-insights/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-contact-center-insights/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-container/README.md b/java-container/README.md index 115bef601ecb..628db512d6e8 100644 --- a/java-container/README.md +++ b/java-container/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-container - 2.105.0 + 2.106.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-container' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-container:2.105.0' +implementation 'com.google.cloud:google-cloud-container:2.106.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-container" % "2.105.0" +libraryDependencies += "com.google.cloud" % "google-cloud-container" % "2.106.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-container/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-container.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-container/2.105.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-container/2.106.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-containeranalysis/README.md b/java-containeranalysis/README.md index 4c5c47a6d299..3888e1178fe9 100644 --- a/java-containeranalysis/README.md +++ b/java-containeranalysis/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-containeranalysis - 2.103.0 + 2.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-containeranalysis' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-containeranalysis:2.103.0' +implementation 'com.google.cloud:google-cloud-containeranalysis:2.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-containeranalysis" % "2.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-containeranalysis" % "2.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-containeranalysis/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-containeranalysis.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-containeranalysis/2.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-containeranalysis/2.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-contentwarehouse/README.md b/java-contentwarehouse/README.md index e32413426bbc..80fbce7c9970 100644 --- a/java-contentwarehouse/README.md +++ b/java-contentwarehouse/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-contentwarehouse - 0.98.0 + 0.99.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-contentwarehouse' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-contentwarehouse:0.98.0' +implementation 'com.google.cloud:google-cloud-contentwarehouse:0.99.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-contentwarehouse" % "0.98.0" +libraryDependencies += "com.google.cloud" % "google-cloud-contentwarehouse" % "0.99.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-contentwarehouse/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-contentwarehouse.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-contentwarehouse/0.98.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-contentwarehouse/0.99.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-data-fusion/README.md b/java-data-fusion/README.md index 6362c4a7325a..ce6363f32af5 100644 --- a/java-data-fusion/README.md +++ b/java-data-fusion/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-data-fusion - 1.102.0 + 1.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-data-fusion' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-data-fusion:1.102.0' +implementation 'com.google.cloud:google-cloud-data-fusion:1.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-data-fusion" % "1.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-data-fusion" % "1.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-data-fusion/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-data-fusion.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-data-fusion/1.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-data-fusion/1.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-databasecenter/README.md b/java-databasecenter/README.md index bf84f3371a75..d1baf58ae6ed 100644 --- a/java-databasecenter/README.md +++ b/java-databasecenter/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-databasecenter - 0.23.0 + 0.24.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-databasecenter' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-databasecenter:0.23.0' +implementation 'com.google.cloud:google-cloud-databasecenter:0.24.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-databasecenter" % "0.23.0" +libraryDependencies += "com.google.cloud" % "google-cloud-databasecenter" % "0.24.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-databasecenter/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-databasecenter.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-databasecenter/0.23.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-databasecenter/0.24.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-dataflow/README.md b/java-dataflow/README.md index e0c9cea08605..67147849351b 100644 --- a/java-dataflow/README.md +++ b/java-dataflow/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-dataflow - 0.106.0 + 0.107.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-dataflow' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-dataflow:0.106.0' +implementation 'com.google.cloud:google-cloud-dataflow:0.107.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-dataflow" % "0.106.0" +libraryDependencies += "com.google.cloud" % "google-cloud-dataflow" % "0.107.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-dataflow/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-dataflow.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataflow/0.106.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataflow/0.107.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-dataform/README.md b/java-dataform/README.md index cc7c9c8c35ca..7e0ddd57412e 100644 --- a/java-dataform/README.md +++ b/java-dataform/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-dataform - 0.101.0 + 0.102.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-dataform' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-dataform:0.101.0' +implementation 'com.google.cloud:google-cloud-dataform:0.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-dataform" % "0.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-dataform" % "0.102.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-dataform/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-dataform.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataform/0.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataform/0.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/DataformClient.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/DataformClient.java index c78015af400a..aa16f8fe3779 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/DataformClient.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/DataformClient.java @@ -628,6 +628,26 @@ * * * + *

                      CreateWorkspaceLongRunning + *

                      Creates a new Workspace in a given Repository asynchronously. + * + *

                      Request object method variants only take one parameter, a request object, which must be constructed before the call.

                      + *
                        + *
                      • createWorkspaceLongRunningAsync(CreateWorkspaceRequest request) + *

                      + *

                      Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

                      + *
                        + *
                      • createWorkspaceLongRunningAsync(RepositoryName parent, Workspace workspace, String workspaceId) + *

                      • createWorkspaceLongRunningAsync(String parent, Workspace workspace, String workspaceId) + *

                      + *

                      Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

                      + *
                        + *
                      • createWorkspaceLongRunningOperationCallable() + *

                      • createWorkspaceLongRunningCallable() + *

                      + * + * + * *

                      DeleteWorkspace *

                      Deletes a single Workspace. * @@ -5224,6 +5244,177 @@ public final UnaryCallable createWorkspaceCal return stub.createWorkspaceCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Workspace in a given Repository asynchronously. + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (DataformClient dataformClient = DataformClient.create()) {
                      +   *   RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
                      +   *   Workspace workspace = Workspace.newBuilder().build();
                      +   *   String workspaceId = "workspaceId466560144";
                      +   *   Workspace response =
                      +   *       dataformClient.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get();
                      +   * }
                      +   * }
                      + * + * @param parent Required. The repository in which to create the workspace. Must be in the format + * `projects/*/locations/*/repositories/*`. + * @param workspace Required. The workspace to create. + * @param workspaceId Required. The ID to use for the workspace, which will become the final + * component of the workspace's resource name. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createWorkspaceLongRunningAsync( + @Nullable RepositoryName parent, Workspace workspace, String workspaceId) { + CreateWorkspaceRequest request = + CreateWorkspaceRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setWorkspace(workspace) + .setWorkspaceId(workspaceId) + .build(); + return createWorkspaceLongRunningAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Workspace in a given Repository asynchronously. + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (DataformClient dataformClient = DataformClient.create()) {
                      +   *   String parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString();
                      +   *   Workspace workspace = Workspace.newBuilder().build();
                      +   *   String workspaceId = "workspaceId466560144";
                      +   *   Workspace response =
                      +   *       dataformClient.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get();
                      +   * }
                      +   * }
                      + * + * @param parent Required. The repository in which to create the workspace. Must be in the format + * `projects/*/locations/*/repositories/*`. + * @param workspace Required. The workspace to create. + * @param workspaceId Required. The ID to use for the workspace, which will become the final + * component of the workspace's resource name. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createWorkspaceLongRunningAsync( + String parent, Workspace workspace, String workspaceId) { + CreateWorkspaceRequest request = + CreateWorkspaceRequest.newBuilder() + .setParent(parent) + .setWorkspace(workspace) + .setWorkspaceId(workspaceId) + .build(); + return createWorkspaceLongRunningAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Workspace in a given Repository asynchronously. + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (DataformClient dataformClient = DataformClient.create()) {
                      +   *   CreateWorkspaceRequest request =
                      +   *       CreateWorkspaceRequest.newBuilder()
                      +   *           .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString())
                      +   *           .setWorkspace(Workspace.newBuilder().build())
                      +   *           .setWorkspaceId("workspaceId466560144")
                      +   *           .build();
                      +   *   Workspace response = dataformClient.createWorkspaceLongRunningAsync(request).get();
                      +   * }
                      +   * }
                      + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createWorkspaceLongRunningAsync( + CreateWorkspaceRequest request) { + return createWorkspaceLongRunningOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Workspace in a given Repository asynchronously. + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (DataformClient dataformClient = DataformClient.create()) {
                      +   *   CreateWorkspaceRequest request =
                      +   *       CreateWorkspaceRequest.newBuilder()
                      +   *           .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString())
                      +   *           .setWorkspace(Workspace.newBuilder().build())
                      +   *           .setWorkspaceId("workspaceId466560144")
                      +   *           .build();
                      +   *   OperationFuture future =
                      +   *       dataformClient.createWorkspaceLongRunningOperationCallable().futureCall(request);
                      +   *   // Do something.
                      +   *   Workspace response = future.get();
                      +   * }
                      +   * }
                      + */ + public final OperationCallable + createWorkspaceLongRunningOperationCallable() { + return stub.createWorkspaceLongRunningOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Workspace in a given Repository asynchronously. + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (DataformClient dataformClient = DataformClient.create()) {
                      +   *   CreateWorkspaceRequest request =
                      +   *       CreateWorkspaceRequest.newBuilder()
                      +   *           .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString())
                      +   *           .setWorkspace(Workspace.newBuilder().build())
                      +   *           .setWorkspaceId("workspaceId466560144")
                      +   *           .build();
                      +   *   ApiFuture future =
                      +   *       dataformClient.createWorkspaceLongRunningCallable().futureCall(request);
                      +   *   // Do something.
                      +   *   Operation response = future.get();
                      +   * }
                      +   * }
                      + */ + public final UnaryCallable + createWorkspaceLongRunningCallable() { + return stub.createWorkspaceLongRunningCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Deletes a single Workspace. diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/DataformSettings.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/DataformSettings.java index 30455f383a64..9788b96168c8 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/DataformSettings.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/DataformSettings.java @@ -346,6 +346,17 @@ public UnaryCallSettings createWorkspaceSetti return ((DataformStubSettings) getStubSettings()).createWorkspaceSettings(); } + /** Returns the object with the settings used for calls to createWorkspaceLongRunning. */ + public UnaryCallSettings createWorkspaceLongRunningSettings() { + return ((DataformStubSettings) getStubSettings()).createWorkspaceLongRunningSettings(); + } + + /** Returns the object with the settings used for calls to createWorkspaceLongRunning. */ + public OperationCallSettings + createWorkspaceLongRunningOperationSettings() { + return ((DataformStubSettings) getStubSettings()).createWorkspaceLongRunningOperationSettings(); + } + /** Returns the object with the settings used for calls to deleteWorkspace. */ public UnaryCallSettings deleteWorkspaceSettings() { return ((DataformStubSettings) getStubSettings()).deleteWorkspaceSettings(); @@ -954,6 +965,18 @@ public UnaryCallSettings.Builder createWorksp return getStubSettingsBuilder().createWorkspaceSettings(); } + /** Returns the builder for the settings used for calls to createWorkspaceLongRunning. */ + public UnaryCallSettings.Builder + createWorkspaceLongRunningSettings() { + return getStubSettingsBuilder().createWorkspaceLongRunningSettings(); + } + + /** Returns the builder for the settings used for calls to createWorkspaceLongRunning. */ + public OperationCallSettings.Builder + createWorkspaceLongRunningOperationSettings() { + return getStubSettingsBuilder().createWorkspaceLongRunningOperationSettings(); + } + /** Returns the builder for the settings used for calls to deleteWorkspace. */ public UnaryCallSettings.Builder deleteWorkspaceSettings() { return getStubSettingsBuilder().deleteWorkspaceSettings(); diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/gapic_metadata.json b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/gapic_metadata.json index 87ad780ee4eb..3c7dd735f024 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/gapic_metadata.json +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/gapic_metadata.json @@ -49,6 +49,9 @@ "CreateWorkspace": { "methods": ["createWorkspace", "createWorkspace", "createWorkspace", "createWorkspaceCallable"] }, + "CreateWorkspaceLongRunning": { + "methods": ["createWorkspaceLongRunningAsync", "createWorkspaceLongRunningAsync", "createWorkspaceLongRunningAsync", "createWorkspaceLongRunningOperationCallable", "createWorkspaceLongRunningCallable"] + }, "DeleteFolder": { "methods": ["deleteFolder", "deleteFolder", "deleteFolder", "deleteFolderCallable"] }, diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/DataformStub.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/DataformStub.java index 593f0c0f5d0d..9a77fc9ae7b7 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/DataformStub.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/DataformStub.java @@ -55,6 +55,7 @@ import com.google.cloud.dataform.v1.CreateTeamFolderRequest; import com.google.cloud.dataform.v1.CreateWorkflowConfigRequest; import com.google.cloud.dataform.v1.CreateWorkflowInvocationRequest; +import com.google.cloud.dataform.v1.CreateWorkspaceMetadata; import com.google.cloud.dataform.v1.CreateWorkspaceRequest; import com.google.cloud.dataform.v1.DeleteFolderRequest; import com.google.cloud.dataform.v1.DeleteFolderTreeMetadata; @@ -392,6 +393,17 @@ public UnaryCallable createWorkspaceCallable( throw new UnsupportedOperationException("Not implemented: createWorkspaceCallable()"); } + public OperationCallable + createWorkspaceLongRunningOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: createWorkspaceLongRunningOperationCallable()"); + } + + public UnaryCallable createWorkspaceLongRunningCallable() { + throw new UnsupportedOperationException( + "Not implemented: createWorkspaceLongRunningCallable()"); + } + public UnaryCallable deleteWorkspaceCallable() { throw new UnsupportedOperationException("Not implemented: deleteWorkspaceCallable()"); } diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/DataformStubSettings.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/DataformStubSettings.java index c7f89b99ac35..df22f76fe476 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/DataformStubSettings.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/DataformStubSettings.java @@ -85,6 +85,7 @@ import com.google.cloud.dataform.v1.CreateTeamFolderRequest; import com.google.cloud.dataform.v1.CreateWorkflowConfigRequest; import com.google.cloud.dataform.v1.CreateWorkflowInvocationRequest; +import com.google.cloud.dataform.v1.CreateWorkspaceMetadata; import com.google.cloud.dataform.v1.CreateWorkspaceRequest; import com.google.cloud.dataform.v1.DeleteFolderRequest; import com.google.cloud.dataform.v1.DeleteFolderTreeMetadata; @@ -364,6 +365,10 @@ public class DataformStubSettings extends StubSettings { listWorkspacesSettings; private final UnaryCallSettings getWorkspaceSettings; private final UnaryCallSettings createWorkspaceSettings; + private final UnaryCallSettings + createWorkspaceLongRunningSettings; + private final OperationCallSettings + createWorkspaceLongRunningOperationSettings; private final UnaryCallSettings deleteWorkspaceSettings; private final UnaryCallSettings installNpmPackagesSettings; @@ -1780,6 +1785,17 @@ public UnaryCallSettings createWorkspaceSetti return createWorkspaceSettings; } + /** Returns the object with the settings used for calls to createWorkspaceLongRunning. */ + public UnaryCallSettings createWorkspaceLongRunningSettings() { + return createWorkspaceLongRunningSettings; + } + + /** Returns the object with the settings used for calls to createWorkspaceLongRunning. */ + public OperationCallSettings + createWorkspaceLongRunningOperationSettings() { + return createWorkspaceLongRunningOperationSettings; + } + /** Returns the object with the settings used for calls to deleteWorkspace. */ public UnaryCallSettings deleteWorkspaceSettings() { return deleteWorkspaceSettings; @@ -2207,6 +2223,10 @@ protected DataformStubSettings(Builder settingsBuilder) throws IOException { listWorkspacesSettings = settingsBuilder.listWorkspacesSettings().build(); getWorkspaceSettings = settingsBuilder.getWorkspaceSettings().build(); createWorkspaceSettings = settingsBuilder.createWorkspaceSettings().build(); + createWorkspaceLongRunningSettings = + settingsBuilder.createWorkspaceLongRunningSettings().build(); + createWorkspaceLongRunningOperationSettings = + settingsBuilder.createWorkspaceLongRunningOperationSettings().build(); deleteWorkspaceSettings = settingsBuilder.deleteWorkspaceSettings().build(); installNpmPackagesSettings = settingsBuilder.installNpmPackagesSettings().build(); pullGitCommitsSettings = settingsBuilder.pullGitCommitsSettings().build(); @@ -2355,6 +2375,11 @@ public static class Builder extends StubSettings.Builder getWorkspaceSettings; private final UnaryCallSettings.Builder createWorkspaceSettings; + private final UnaryCallSettings.Builder + createWorkspaceLongRunningSettings; + private final OperationCallSettings.Builder< + CreateWorkspaceRequest, Workspace, CreateWorkspaceMetadata> + createWorkspaceLongRunningOperationSettings; private final UnaryCallSettings.Builder deleteWorkspaceSettings; private final UnaryCallSettings.Builder installNpmPackagesSettings; @@ -2532,6 +2557,8 @@ protected Builder(@Nullable ClientContext clientContext) { listWorkspacesSettings = PagedCallSettings.newBuilder(LIST_WORKSPACES_PAGE_STR_FACT); getWorkspaceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); createWorkspaceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createWorkspaceLongRunningSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createWorkspaceLongRunningOperationSettings = OperationCallSettings.newBuilder(); deleteWorkspaceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); installNpmPackagesSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); pullGitCommitsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -2618,6 +2645,7 @@ protected Builder(@Nullable ClientContext clientContext) { listWorkspacesSettings, getWorkspaceSettings, createWorkspaceSettings, + createWorkspaceLongRunningSettings, deleteWorkspaceSettings, installNpmPackagesSettings, pullGitCommitsSettings, @@ -2707,6 +2735,9 @@ protected Builder(DataformStubSettings settings) { listWorkspacesSettings = settings.listWorkspacesSettings.toBuilder(); getWorkspaceSettings = settings.getWorkspaceSettings.toBuilder(); createWorkspaceSettings = settings.createWorkspaceSettings.toBuilder(); + createWorkspaceLongRunningSettings = settings.createWorkspaceLongRunningSettings.toBuilder(); + createWorkspaceLongRunningOperationSettings = + settings.createWorkspaceLongRunningOperationSettings.toBuilder(); deleteWorkspaceSettings = settings.deleteWorkspaceSettings.toBuilder(); installNpmPackagesSettings = settings.installNpmPackagesSettings.toBuilder(); pullGitCommitsSettings = settings.pullGitCommitsSettings.toBuilder(); @@ -2791,6 +2822,7 @@ protected Builder(DataformStubSettings settings) { listWorkspacesSettings, getWorkspaceSettings, createWorkspaceSettings, + createWorkspaceLongRunningSettings, deleteWorkspaceSettings, installNpmPackagesSettings, pullGitCommitsSettings, @@ -3014,6 +3046,11 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + builder + .createWorkspaceLongRunningSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + builder .deleteWorkspaceSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) @@ -3339,6 +3376,30 @@ private static Builder initDefaults(Builder builder) { .setTotalTimeoutDuration(Duration.ofMillis(300000L)) .build())); + builder + .createWorkspaceLongRunningOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Workspace.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(CreateWorkspaceMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + builder .createCompilationResultLongRunningOperationSettings() .setInitialCallSettings( @@ -3597,6 +3658,18 @@ public UnaryCallSettings.Builder createWorksp return createWorkspaceSettings; } + /** Returns the builder for the settings used for calls to createWorkspaceLongRunning. */ + public UnaryCallSettings.Builder + createWorkspaceLongRunningSettings() { + return createWorkspaceLongRunningSettings; + } + + /** Returns the builder for the settings used for calls to createWorkspaceLongRunning. */ + public OperationCallSettings.Builder + createWorkspaceLongRunningOperationSettings() { + return createWorkspaceLongRunningOperationSettings; + } + /** Returns the builder for the settings used for calls to deleteWorkspace. */ public UnaryCallSettings.Builder deleteWorkspaceSettings() { return deleteWorkspaceSettings; diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/GrpcDataformStub.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/GrpcDataformStub.java index 2e3454641c4d..07d5ddc61162 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/GrpcDataformStub.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/GrpcDataformStub.java @@ -60,6 +60,7 @@ import com.google.cloud.dataform.v1.CreateTeamFolderRequest; import com.google.cloud.dataform.v1.CreateWorkflowConfigRequest; import com.google.cloud.dataform.v1.CreateWorkflowInvocationRequest; +import com.google.cloud.dataform.v1.CreateWorkspaceMetadata; import com.google.cloud.dataform.v1.CreateWorkspaceRequest; import com.google.cloud.dataform.v1.DeleteFolderRequest; import com.google.cloud.dataform.v1.DeleteFolderTreeMetadata; @@ -539,6 +540,17 @@ public class GrpcDataformStub extends DataformStub { .setSampledToLocalTracing(true) .build(); + private static final MethodDescriptor + createWorkspaceLongRunningMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dataform.v1.Dataform/CreateWorkspaceLongRunning") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateWorkspaceRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + private static final MethodDescriptor deleteWorkspaceMethodDescriptor = MethodDescriptor.newBuilder() @@ -1138,6 +1150,9 @@ public class GrpcDataformStub extends DataformStub { listWorkspacesPagedCallable; private final UnaryCallable getWorkspaceCallable; private final UnaryCallable createWorkspaceCallable; + private final UnaryCallable createWorkspaceLongRunningCallable; + private final OperationCallable + createWorkspaceLongRunningOperationCallable; private final UnaryCallable deleteWorkspaceCallable; private final UnaryCallable installNpmPackagesCallable; @@ -1625,6 +1640,18 @@ protected GrpcDataformStub( }) .setResourceNameExtractor(request -> request.getParent()) .build(); + GrpcCallSettings + createWorkspaceLongRunningTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createWorkspaceLongRunningMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); GrpcCallSettings deleteWorkspaceTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(deleteWorkspaceMethodDescriptor) @@ -2340,6 +2367,17 @@ protected GrpcDataformStub( this.createWorkspaceCallable = callableFactory.createUnaryCallable( createWorkspaceTransportSettings, settings.createWorkspaceSettings(), clientContext); + this.createWorkspaceLongRunningCallable = + callableFactory.createUnaryCallable( + createWorkspaceLongRunningTransportSettings, + settings.createWorkspaceLongRunningSettings(), + clientContext); + this.createWorkspaceLongRunningOperationCallable = + callableFactory.createOperationCallable( + createWorkspaceLongRunningTransportSettings, + settings.createWorkspaceLongRunningOperationSettings(), + clientContext, + operationsStub); this.deleteWorkspaceCallable = callableFactory.createUnaryCallable( deleteWorkspaceTransportSettings, settings.deleteWorkspaceSettings(), clientContext); @@ -2824,6 +2862,17 @@ public UnaryCallable createWorkspaceCallable( return createWorkspaceCallable; } + @Override + public UnaryCallable createWorkspaceLongRunningCallable() { + return createWorkspaceLongRunningCallable; + } + + @Override + public OperationCallable + createWorkspaceLongRunningOperationCallable() { + return createWorkspaceLongRunningOperationCallable; + } + @Override public UnaryCallable deleteWorkspaceCallable() { return deleteWorkspaceCallable; diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/HttpJsonDataformStub.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/HttpJsonDataformStub.java index cb745674056b..0574abeb4735 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/HttpJsonDataformStub.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1/stub/HttpJsonDataformStub.java @@ -68,6 +68,7 @@ import com.google.cloud.dataform.v1.CreateTeamFolderRequest; import com.google.cloud.dataform.v1.CreateWorkflowConfigRequest; import com.google.cloud.dataform.v1.CreateWorkflowInvocationRequest; +import com.google.cloud.dataform.v1.CreateWorkspaceMetadata; import com.google.cloud.dataform.v1.CreateWorkspaceRequest; import com.google.cloud.dataform.v1.DeleteFolderRequest; import com.google.cloud.dataform.v1.DeleteFolderTreeMetadata; @@ -207,7 +208,9 @@ public class HttpJsonDataformStub extends DataformStub { .add(CreateCompilationResultMetadata.getDescriptor()) .add(MoveFolderMetadata.getDescriptor()) .add(MoveRepositoryMetadata.getDescriptor()) + .add(CreateWorkspaceMetadata.getDescriptor()) .add(DeleteFolderTreeMetadata.getDescriptor()) + .add(Workspace.getDescriptor()) .build(); private static final ApiMethodDescriptor @@ -1341,6 +1344,48 @@ public class HttpJsonDataformStub extends DataformStub { .build()) .build(); + private static final ApiMethodDescriptor + createWorkspaceLongRunningMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.dataform.v1.Dataform/CreateWorkspaceLongRunning") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*/repositories/*}/workspaces:createLongRunning", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam( + fields, "workspaceId", request.getWorkspaceId()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("workspace", request.getWorkspace(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (CreateWorkspaceRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + private static final ApiMethodDescriptor deleteWorkspaceMethodDescriptor = ApiMethodDescriptor.newBuilder() @@ -3121,6 +3166,9 @@ public class HttpJsonDataformStub extends DataformStub { listWorkspacesPagedCallable; private final UnaryCallable getWorkspaceCallable; private final UnaryCallable createWorkspaceCallable; + private final UnaryCallable createWorkspaceLongRunningCallable; + private final OperationCallable + createWorkspaceLongRunningOperationCallable; private final UnaryCallable deleteWorkspaceCallable; private final UnaryCallable installNpmPackagesCallable; @@ -3671,6 +3719,19 @@ protected HttpJsonDataformStub( }) .setResourceNameExtractor(request -> request.getParent()) .build(); + HttpJsonCallSettings + createWorkspaceLongRunningTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createWorkspaceLongRunningMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); HttpJsonCallSettings deleteWorkspaceTransportSettings = HttpJsonCallSettings.newBuilder() .setMethodDescriptor(deleteWorkspaceMethodDescriptor) @@ -4442,6 +4503,17 @@ protected HttpJsonDataformStub( this.createWorkspaceCallable = callableFactory.createUnaryCallable( createWorkspaceTransportSettings, settings.createWorkspaceSettings(), clientContext); + this.createWorkspaceLongRunningCallable = + callableFactory.createUnaryCallable( + createWorkspaceLongRunningTransportSettings, + settings.createWorkspaceLongRunningSettings(), + clientContext); + this.createWorkspaceLongRunningOperationCallable = + callableFactory.createOperationCallable( + createWorkspaceLongRunningTransportSettings, + settings.createWorkspaceLongRunningOperationSettings(), + clientContext, + httpJsonOperationsStub); this.deleteWorkspaceCallable = callableFactory.createUnaryCallable( deleteWorkspaceTransportSettings, settings.deleteWorkspaceSettings(), clientContext); @@ -4719,6 +4791,7 @@ public static List getMethodDescriptors() { methodDescriptors.add(listWorkspacesMethodDescriptor); methodDescriptors.add(getWorkspaceMethodDescriptor); methodDescriptors.add(createWorkspaceMethodDescriptor); + methodDescriptors.add(createWorkspaceLongRunningMethodDescriptor); methodDescriptors.add(deleteWorkspaceMethodDescriptor); methodDescriptors.add(installNpmPackagesMethodDescriptor); methodDescriptors.add(pullGitCommitsMethodDescriptor); @@ -5008,6 +5081,17 @@ public UnaryCallable createWorkspaceCallable( return createWorkspaceCallable; } + @Override + public UnaryCallable createWorkspaceLongRunningCallable() { + return createWorkspaceLongRunningCallable; + } + + @Override + public OperationCallable + createWorkspaceLongRunningOperationCallable() { + return createWorkspaceLongRunningOperationCallable; + } + @Override public UnaryCallable deleteWorkspaceCallable() { return deleteWorkspaceCallable; diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/DataformClient.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/DataformClient.java index 1a059b8881b2..813b9ebb1850 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/DataformClient.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/DataformClient.java @@ -648,6 +648,26 @@ * * * + *

                      CreateWorkspaceLongRunning + *

                      Creates a new Workspace in a given Repository asynchronously. + * + *

                      Request object method variants only take one parameter, a request object, which must be constructed before the call.

                      + *
                        + *
                      • createWorkspaceLongRunningAsync(CreateWorkspaceRequest request) + *

                      + *

                      Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

                      + *
                        + *
                      • createWorkspaceLongRunningAsync(RepositoryName parent, Workspace workspace, String workspaceId) + *

                      • createWorkspaceLongRunningAsync(String parent, Workspace workspace, String workspaceId) + *

                      + *

                      Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

                      + *
                        + *
                      • createWorkspaceLongRunningOperationCallable() + *

                      • createWorkspaceLongRunningCallable() + *

                      + * + * + * *

                      DeleteWorkspace *

                      Deletes a single Workspace. * @@ -5508,6 +5528,177 @@ public final UnaryCallable createWorkspaceCal return stub.createWorkspaceCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Workspace in a given Repository asynchronously. + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (DataformClient dataformClient = DataformClient.create()) {
                      +   *   RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]");
                      +   *   Workspace workspace = Workspace.newBuilder().build();
                      +   *   String workspaceId = "workspaceId466560144";
                      +   *   Workspace response =
                      +   *       dataformClient.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get();
                      +   * }
                      +   * }
                      + * + * @param parent Required. The repository in which to create the workspace. Must be in the format + * `projects/*/locations/*/repositories/*`. + * @param workspace Required. The workspace to create. + * @param workspaceId Required. The ID to use for the workspace, which will become the final + * component of the workspace's resource name. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createWorkspaceLongRunningAsync( + @Nullable RepositoryName parent, Workspace workspace, String workspaceId) { + CreateWorkspaceRequest request = + CreateWorkspaceRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setWorkspace(workspace) + .setWorkspaceId(workspaceId) + .build(); + return createWorkspaceLongRunningAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Workspace in a given Repository asynchronously. + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (DataformClient dataformClient = DataformClient.create()) {
                      +   *   String parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString();
                      +   *   Workspace workspace = Workspace.newBuilder().build();
                      +   *   String workspaceId = "workspaceId466560144";
                      +   *   Workspace response =
                      +   *       dataformClient.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get();
                      +   * }
                      +   * }
                      + * + * @param parent Required. The repository in which to create the workspace. Must be in the format + * `projects/*/locations/*/repositories/*`. + * @param workspace Required. The workspace to create. + * @param workspaceId Required. The ID to use for the workspace, which will become the final + * component of the workspace's resource name. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createWorkspaceLongRunningAsync( + String parent, Workspace workspace, String workspaceId) { + CreateWorkspaceRequest request = + CreateWorkspaceRequest.newBuilder() + .setParent(parent) + .setWorkspace(workspace) + .setWorkspaceId(workspaceId) + .build(); + return createWorkspaceLongRunningAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Workspace in a given Repository asynchronously. + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (DataformClient dataformClient = DataformClient.create()) {
                      +   *   CreateWorkspaceRequest request =
                      +   *       CreateWorkspaceRequest.newBuilder()
                      +   *           .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString())
                      +   *           .setWorkspace(Workspace.newBuilder().build())
                      +   *           .setWorkspaceId("workspaceId466560144")
                      +   *           .build();
                      +   *   Workspace response = dataformClient.createWorkspaceLongRunningAsync(request).get();
                      +   * }
                      +   * }
                      + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createWorkspaceLongRunningAsync( + CreateWorkspaceRequest request) { + return createWorkspaceLongRunningOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Workspace in a given Repository asynchronously. + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (DataformClient dataformClient = DataformClient.create()) {
                      +   *   CreateWorkspaceRequest request =
                      +   *       CreateWorkspaceRequest.newBuilder()
                      +   *           .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString())
                      +   *           .setWorkspace(Workspace.newBuilder().build())
                      +   *           .setWorkspaceId("workspaceId466560144")
                      +   *           .build();
                      +   *   OperationFuture future =
                      +   *       dataformClient.createWorkspaceLongRunningOperationCallable().futureCall(request);
                      +   *   // Do something.
                      +   *   Workspace response = future.get();
                      +   * }
                      +   * }
                      + */ + public final OperationCallable + createWorkspaceLongRunningOperationCallable() { + return stub.createWorkspaceLongRunningOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Workspace in a given Repository asynchronously. + * + *

                      Sample code: + * + *

                      {@code
                      +   * // This snippet has been automatically generated and should be regarded as a code template only.
                      +   * // It will require modifications to work:
                      +   * // - It may require correct/in-range values for request initialization.
                      +   * // - It may require specifying regional endpoints when creating the service client as shown in
                      +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                      +   * try (DataformClient dataformClient = DataformClient.create()) {
                      +   *   CreateWorkspaceRequest request =
                      +   *       CreateWorkspaceRequest.newBuilder()
                      +   *           .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString())
                      +   *           .setWorkspace(Workspace.newBuilder().build())
                      +   *           .setWorkspaceId("workspaceId466560144")
                      +   *           .build();
                      +   *   ApiFuture future =
                      +   *       dataformClient.createWorkspaceLongRunningCallable().futureCall(request);
                      +   *   // Do something.
                      +   *   Operation response = future.get();
                      +   * }
                      +   * }
                      + */ + public final UnaryCallable + createWorkspaceLongRunningCallable() { + return stub.createWorkspaceLongRunningCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Deletes a single Workspace. diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/DataformSettings.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/DataformSettings.java index ee27c8c71ef6..956a1cab0425 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/DataformSettings.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/DataformSettings.java @@ -365,6 +365,17 @@ public UnaryCallSettings createWorkspaceSetti return ((DataformStubSettings) getStubSettings()).createWorkspaceSettings(); } + /** Returns the object with the settings used for calls to createWorkspaceLongRunning. */ + public UnaryCallSettings createWorkspaceLongRunningSettings() { + return ((DataformStubSettings) getStubSettings()).createWorkspaceLongRunningSettings(); + } + + /** Returns the object with the settings used for calls to createWorkspaceLongRunning. */ + public OperationCallSettings + createWorkspaceLongRunningOperationSettings() { + return ((DataformStubSettings) getStubSettings()).createWorkspaceLongRunningOperationSettings(); + } + /** Returns the object with the settings used for calls to deleteWorkspace. */ public UnaryCallSettings deleteWorkspaceSettings() { return ((DataformStubSettings) getStubSettings()).deleteWorkspaceSettings(); @@ -1029,6 +1040,18 @@ public UnaryCallSettings.Builder createWorksp return getStubSettingsBuilder().createWorkspaceSettings(); } + /** Returns the builder for the settings used for calls to createWorkspaceLongRunning. */ + public UnaryCallSettings.Builder + createWorkspaceLongRunningSettings() { + return getStubSettingsBuilder().createWorkspaceLongRunningSettings(); + } + + /** Returns the builder for the settings used for calls to createWorkspaceLongRunning. */ + public OperationCallSettings.Builder + createWorkspaceLongRunningOperationSettings() { + return getStubSettingsBuilder().createWorkspaceLongRunningOperationSettings(); + } + /** Returns the builder for the settings used for calls to deleteWorkspace. */ public UnaryCallSettings.Builder deleteWorkspaceSettings() { return getStubSettingsBuilder().deleteWorkspaceSettings(); diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/gapic_metadata.json b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/gapic_metadata.json index f70c854a368c..628d28e3b5ee 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/gapic_metadata.json +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/gapic_metadata.json @@ -52,6 +52,9 @@ "CreateWorkspace": { "methods": ["createWorkspace", "createWorkspace", "createWorkspace", "createWorkspaceCallable"] }, + "CreateWorkspaceLongRunning": { + "methods": ["createWorkspaceLongRunningAsync", "createWorkspaceLongRunningAsync", "createWorkspaceLongRunningAsync", "createWorkspaceLongRunningOperationCallable", "createWorkspaceLongRunningCallable"] + }, "DeleteBranch": { "methods": ["deleteBranch", "deleteBranchCallable"] }, diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/DataformStub.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/DataformStub.java index 3d17ac3e6e0e..54db9995000e 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/DataformStub.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/DataformStub.java @@ -59,6 +59,7 @@ import com.google.cloud.dataform.v1beta1.CreateTeamFolderRequest; import com.google.cloud.dataform.v1beta1.CreateWorkflowConfigRequest; import com.google.cloud.dataform.v1beta1.CreateWorkflowInvocationRequest; +import com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata; import com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest; import com.google.cloud.dataform.v1beta1.DeleteBranchRequest; import com.google.cloud.dataform.v1beta1.DeleteBranchResponse; @@ -425,6 +426,17 @@ public UnaryCallable createWorkspaceCallable( throw new UnsupportedOperationException("Not implemented: createWorkspaceCallable()"); } + public OperationCallable + createWorkspaceLongRunningOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: createWorkspaceLongRunningOperationCallable()"); + } + + public UnaryCallable createWorkspaceLongRunningCallable() { + throw new UnsupportedOperationException( + "Not implemented: createWorkspaceLongRunningCallable()"); + } + public UnaryCallable deleteWorkspaceCallable() { throw new UnsupportedOperationException("Not implemented: deleteWorkspaceCallable()"); } diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/DataformStubSettings.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/DataformStubSettings.java index e17cbaa8cfad..7d5e0ab7cb9d 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/DataformStubSettings.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/DataformStubSettings.java @@ -89,6 +89,7 @@ import com.google.cloud.dataform.v1beta1.CreateTeamFolderRequest; import com.google.cloud.dataform.v1beta1.CreateWorkflowConfigRequest; import com.google.cloud.dataform.v1beta1.CreateWorkflowInvocationRequest; +import com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata; import com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest; import com.google.cloud.dataform.v1beta1.DeleteBranchRequest; import com.google.cloud.dataform.v1beta1.DeleteBranchResponse; @@ -389,6 +390,10 @@ public class DataformStubSettings extends StubSettings { listWorkspacesSettings; private final UnaryCallSettings getWorkspaceSettings; private final UnaryCallSettings createWorkspaceSettings; + private final UnaryCallSettings + createWorkspaceLongRunningSettings; + private final OperationCallSettings + createWorkspaceLongRunningOperationSettings; private final UnaryCallSettings deleteWorkspaceSettings; private final UnaryCallSettings installNpmPackagesSettings; @@ -1967,6 +1972,17 @@ public UnaryCallSettings createWorkspaceSetti return createWorkspaceSettings; } + /** Returns the object with the settings used for calls to createWorkspaceLongRunning. */ + public UnaryCallSettings createWorkspaceLongRunningSettings() { + return createWorkspaceLongRunningSettings; + } + + /** Returns the object with the settings used for calls to createWorkspaceLongRunning. */ + public OperationCallSettings + createWorkspaceLongRunningOperationSettings() { + return createWorkspaceLongRunningOperationSettings; + } + /** Returns the object with the settings used for calls to deleteWorkspace. */ public UnaryCallSettings deleteWorkspaceSettings() { return deleteWorkspaceSettings; @@ -2439,6 +2455,10 @@ protected DataformStubSettings(Builder settingsBuilder) throws IOException { listWorkspacesSettings = settingsBuilder.listWorkspacesSettings().build(); getWorkspaceSettings = settingsBuilder.getWorkspaceSettings().build(); createWorkspaceSettings = settingsBuilder.createWorkspaceSettings().build(); + createWorkspaceLongRunningSettings = + settingsBuilder.createWorkspaceLongRunningSettings().build(); + createWorkspaceLongRunningOperationSettings = + settingsBuilder.createWorkspaceLongRunningOperationSettings().build(); deleteWorkspaceSettings = settingsBuilder.deleteWorkspaceSettings().build(); installNpmPackagesSettings = settingsBuilder.installNpmPackagesSettings().build(); pullGitCommitsSettings = settingsBuilder.pullGitCommitsSettings().build(); @@ -2601,6 +2621,11 @@ public static class Builder extends StubSettings.Builder getWorkspaceSettings; private final UnaryCallSettings.Builder createWorkspaceSettings; + private final UnaryCallSettings.Builder + createWorkspaceLongRunningSettings; + private final OperationCallSettings.Builder< + CreateWorkspaceRequest, Workspace, CreateWorkspaceMetadata> + createWorkspaceLongRunningOperationSettings; private final UnaryCallSettings.Builder deleteWorkspaceSettings; private final UnaryCallSettings.Builder installNpmPackagesSettings; @@ -2799,6 +2824,8 @@ protected Builder(@Nullable ClientContext clientContext) { listWorkspacesSettings = PagedCallSettings.newBuilder(LIST_WORKSPACES_PAGE_STR_FACT); getWorkspaceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); createWorkspaceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createWorkspaceLongRunningSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createWorkspaceLongRunningOperationSettings = OperationCallSettings.newBuilder(); deleteWorkspaceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); installNpmPackagesSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); pullGitCommitsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -2894,6 +2921,7 @@ protected Builder(@Nullable ClientContext clientContext) { listWorkspacesSettings, getWorkspaceSettings, createWorkspaceSettings, + createWorkspaceLongRunningSettings, deleteWorkspaceSettings, installNpmPackagesSettings, pullGitCommitsSettings, @@ -2993,6 +3021,9 @@ protected Builder(DataformStubSettings settings) { listWorkspacesSettings = settings.listWorkspacesSettings.toBuilder(); getWorkspaceSettings = settings.getWorkspaceSettings.toBuilder(); createWorkspaceSettings = settings.createWorkspaceSettings.toBuilder(); + createWorkspaceLongRunningSettings = settings.createWorkspaceLongRunningSettings.toBuilder(); + createWorkspaceLongRunningOperationSettings = + settings.createWorkspaceLongRunningOperationSettings.toBuilder(); deleteWorkspaceSettings = settings.deleteWorkspaceSettings.toBuilder(); installNpmPackagesSettings = settings.installNpmPackagesSettings.toBuilder(); pullGitCommitsSettings = settings.pullGitCommitsSettings.toBuilder(); @@ -3085,6 +3116,7 @@ protected Builder(DataformStubSettings settings) { listWorkspacesSettings, getWorkspaceSettings, createWorkspaceSettings, + createWorkspaceLongRunningSettings, deleteWorkspaceSettings, installNpmPackagesSettings, pullGitCommitsSettings, @@ -3319,6 +3351,11 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + builder + .createWorkspaceLongRunningSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + builder .deleteWorkspaceSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) @@ -3701,6 +3738,30 @@ private static Builder initDefaults(Builder builder) { .setTotalTimeoutDuration(Duration.ofMillis(300000L)) .build())); + builder + .createWorkspaceLongRunningOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Workspace.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(CreateWorkspaceMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + builder .createCompilationResultLongRunningOperationSettings() .setInitialCallSettings( @@ -3974,6 +4035,18 @@ public UnaryCallSettings.Builder createWorksp return createWorkspaceSettings; } + /** Returns the builder for the settings used for calls to createWorkspaceLongRunning. */ + public UnaryCallSettings.Builder + createWorkspaceLongRunningSettings() { + return createWorkspaceLongRunningSettings; + } + + /** Returns the builder for the settings used for calls to createWorkspaceLongRunning. */ + public OperationCallSettings.Builder + createWorkspaceLongRunningOperationSettings() { + return createWorkspaceLongRunningOperationSettings; + } + /** Returns the builder for the settings used for calls to deleteWorkspace. */ public UnaryCallSettings.Builder deleteWorkspaceSettings() { return deleteWorkspaceSettings; diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/GrpcDataformStub.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/GrpcDataformStub.java index 9b2d7c8f00dd..147494450e4b 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/GrpcDataformStub.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/GrpcDataformStub.java @@ -64,6 +64,7 @@ import com.google.cloud.dataform.v1beta1.CreateTeamFolderRequest; import com.google.cloud.dataform.v1beta1.CreateWorkflowConfigRequest; import com.google.cloud.dataform.v1beta1.CreateWorkflowInvocationRequest; +import com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata; import com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest; import com.google.cloud.dataform.v1beta1.DeleteBranchRequest; import com.google.cloud.dataform.v1beta1.DeleteBranchResponse; @@ -569,6 +570,18 @@ public class GrpcDataformStub extends DataformStub { .setSampledToLocalTracing(true) .build(); + private static final MethodDescriptor + createWorkspaceLongRunningMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dataform.v1beta1.Dataform/CreateWorkspaceLongRunning") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateWorkspaceRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + private static final MethodDescriptor deleteWorkspaceMethodDescriptor = MethodDescriptor.newBuilder() @@ -1252,6 +1265,9 @@ public class GrpcDataformStub extends DataformStub { listWorkspacesPagedCallable; private final UnaryCallable getWorkspaceCallable; private final UnaryCallable createWorkspaceCallable; + private final UnaryCallable createWorkspaceLongRunningCallable; + private final OperationCallable + createWorkspaceLongRunningOperationCallable; private final UnaryCallable deleteWorkspaceCallable; private final UnaryCallable installNpmPackagesCallable; @@ -1767,6 +1783,18 @@ protected GrpcDataformStub( }) .setResourceNameExtractor(request -> request.getParent()) .build(); + GrpcCallSettings + createWorkspaceLongRunningTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createWorkspaceLongRunningMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); GrpcCallSettings deleteWorkspaceTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(deleteWorkspaceMethodDescriptor) @@ -2568,6 +2596,17 @@ protected GrpcDataformStub( this.createWorkspaceCallable = callableFactory.createUnaryCallable( createWorkspaceTransportSettings, settings.createWorkspaceSettings(), clientContext); + this.createWorkspaceLongRunningCallable = + callableFactory.createUnaryCallable( + createWorkspaceLongRunningTransportSettings, + settings.createWorkspaceLongRunningSettings(), + clientContext); + this.createWorkspaceLongRunningOperationCallable = + callableFactory.createOperationCallable( + createWorkspaceLongRunningTransportSettings, + settings.createWorkspaceLongRunningOperationSettings(), + clientContext, + operationsStub); this.deleteWorkspaceCallable = callableFactory.createUnaryCallable( deleteWorkspaceTransportSettings, settings.deleteWorkspaceSettings(), clientContext); @@ -3105,6 +3144,17 @@ public UnaryCallable createWorkspaceCallable( return createWorkspaceCallable; } + @Override + public UnaryCallable createWorkspaceLongRunningCallable() { + return createWorkspaceLongRunningCallable; + } + + @Override + public OperationCallable + createWorkspaceLongRunningOperationCallable() { + return createWorkspaceLongRunningOperationCallable; + } + @Override public UnaryCallable deleteWorkspaceCallable() { return deleteWorkspaceCallable; diff --git a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/HttpJsonDataformStub.java b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/HttpJsonDataformStub.java index 5a311a99a858..ccca84704321 100644 --- a/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/HttpJsonDataformStub.java +++ b/java-dataform/google-cloud-dataform/src/main/java/com/google/cloud/dataform/v1beta1/stub/HttpJsonDataformStub.java @@ -72,6 +72,7 @@ import com.google.cloud.dataform.v1beta1.CreateTeamFolderRequest; import com.google.cloud.dataform.v1beta1.CreateWorkflowConfigRequest; import com.google.cloud.dataform.v1beta1.CreateWorkflowInvocationRequest; +import com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata; import com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest; import com.google.cloud.dataform.v1beta1.DeleteBranchRequest; import com.google.cloud.dataform.v1beta1.DeleteBranchResponse; @@ -225,8 +226,10 @@ public class HttpJsonDataformStub extends DataformStub { .add(DeleteRepositoryLongRunningMetadata.getDescriptor()) .add(MoveRepositoryMetadata.getDescriptor()) .add(CreateCompilationResultMetadata.getDescriptor()) + .add(Workspace.getDescriptor()) .add(CompilationResult.getDescriptor()) .add(DeleteFolderTreeMetadata.getDescriptor()) + .add(CreateWorkspaceMetadata.getDescriptor()) .add(MoveFolderMetadata.getDescriptor()) .build(); @@ -1405,6 +1408,49 @@ public class HttpJsonDataformStub extends DataformStub { .build()) .build(); + private static final ApiMethodDescriptor + createWorkspaceLongRunningMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.dataform.v1beta1.Dataform/CreateWorkspaceLongRunning") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1beta1/{parent=projects/*/locations/*/repositories/*}/workspaces:createLongRunning", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam( + fields, "workspaceId", request.getWorkspaceId()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("workspace", request.getWorkspace(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (CreateWorkspaceRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + private static final ApiMethodDescriptor deleteWorkspaceMethodDescriptor = ApiMethodDescriptor.newBuilder() @@ -3419,6 +3465,9 @@ public class HttpJsonDataformStub extends DataformStub { listWorkspacesPagedCallable; private final UnaryCallable getWorkspaceCallable; private final UnaryCallable createWorkspaceCallable; + private final UnaryCallable createWorkspaceLongRunningCallable; + private final OperationCallable + createWorkspaceLongRunningOperationCallable; private final UnaryCallable deleteWorkspaceCallable; private final UnaryCallable installNpmPackagesCallable; @@ -3998,6 +4047,19 @@ protected HttpJsonDataformStub( }) .setResourceNameExtractor(request -> request.getParent()) .build(); + HttpJsonCallSettings + createWorkspaceLongRunningTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createWorkspaceLongRunningMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); HttpJsonCallSettings deleteWorkspaceTransportSettings = HttpJsonCallSettings.newBuilder() .setMethodDescriptor(deleteWorkspaceMethodDescriptor) @@ -4861,6 +4923,17 @@ protected HttpJsonDataformStub( this.createWorkspaceCallable = callableFactory.createUnaryCallable( createWorkspaceTransportSettings, settings.createWorkspaceSettings(), clientContext); + this.createWorkspaceLongRunningCallable = + callableFactory.createUnaryCallable( + createWorkspaceLongRunningTransportSettings, + settings.createWorkspaceLongRunningSettings(), + clientContext); + this.createWorkspaceLongRunningOperationCallable = + callableFactory.createOperationCallable( + createWorkspaceLongRunningTransportSettings, + settings.createWorkspaceLongRunningOperationSettings(), + clientContext, + httpJsonOperationsStub); this.deleteWorkspaceCallable = callableFactory.createUnaryCallable( deleteWorkspaceTransportSettings, settings.deleteWorkspaceSettings(), clientContext); @@ -5177,6 +5250,7 @@ public static List getMethodDescriptors() { methodDescriptors.add(listWorkspacesMethodDescriptor); methodDescriptors.add(getWorkspaceMethodDescriptor); methodDescriptors.add(createWorkspaceMethodDescriptor); + methodDescriptors.add(createWorkspaceLongRunningMethodDescriptor); methodDescriptors.add(deleteWorkspaceMethodDescriptor); methodDescriptors.add(installNpmPackagesMethodDescriptor); methodDescriptors.add(pullGitCommitsMethodDescriptor); @@ -5487,6 +5561,17 @@ public UnaryCallable createWorkspaceCallable( return createWorkspaceCallable; } + @Override + public UnaryCallable createWorkspaceLongRunningCallable() { + return createWorkspaceLongRunningCallable; + } + + @Override + public OperationCallable + createWorkspaceLongRunningOperationCallable() { + return createWorkspaceLongRunningOperationCallable; + } + @Override public UnaryCallable deleteWorkspaceCallable() { return deleteWorkspaceCallable; diff --git a/java-dataform/google-cloud-dataform/src/main/resources/META-INF/native-image/com.google.cloud.dataform.v1/reflect-config.json b/java-dataform/google-cloud-dataform/src/main/resources/META-INF/native-image/com.google.cloud.dataform.v1/reflect-config.json index 1d5e5a15f384..6067ceae95ac 100644 --- a/java-dataform/google-cloud-dataform/src/main/resources/META-INF/native-image/com.google.cloud.dataform.v1/reflect-config.json +++ b/java-dataform/google-cloud-dataform/src/main/resources/META-INF/native-image/com.google.cloud.dataform.v1/reflect-config.json @@ -1286,6 +1286,33 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataform.v1.CreateWorkspaceMetadata", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataform.v1.CreateWorkspaceMetadata$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataform.v1.CreateWorkspaceMetadata$State", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataform.v1.CreateWorkspaceRequest", "queryAllDeclaredConstructors": true, diff --git a/java-dataform/google-cloud-dataform/src/main/resources/META-INF/native-image/com.google.cloud.dataform.v1beta1/reflect-config.json b/java-dataform/google-cloud-dataform/src/main/resources/META-INF/native-image/com.google.cloud.dataform.v1beta1/reflect-config.json index 5c1604893ad6..523d1be41db4 100644 --- a/java-dataform/google-cloud-dataform/src/main/resources/META-INF/native-image/com.google.cloud.dataform.v1beta1/reflect-config.json +++ b/java-dataform/google-cloud-dataform/src/main/resources/META-INF/native-image/com.google.cloud.dataform.v1beta1/reflect-config.json @@ -1322,6 +1322,33 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata$State", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest", "queryAllDeclaredConstructors": true, diff --git a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/DataformClientHttpJsonTest.java b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/DataformClientHttpJsonTest.java index 6a565d41fb80..5d9305db46f0 100644 --- a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/DataformClientHttpJsonTest.java +++ b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/DataformClientHttpJsonTest.java @@ -2749,6 +2749,128 @@ public void createWorkspaceExceptionTest2() throws Exception { } } + @Test + public void createWorkspaceLongRunningTest() throws Exception { + Workspace expectedResponse = + Workspace.newBuilder() + .setName( + WorkspaceName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[WORKSPACE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setDataEncryptionState(DataEncryptionState.newBuilder().build()) + .setInternalMetadata("internalMetadata6789388") + .setDisableMoves(true) + .setPrivateResourceMetadata(PrivateResourceMetadata.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createWorkspaceLongRunningTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]"); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + + Workspace actualResponse = + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createWorkspaceLongRunningExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]"); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void createWorkspaceLongRunningTest2() throws Exception { + Workspace expectedResponse = + Workspace.newBuilder() + .setName( + WorkspaceName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[WORKSPACE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setDataEncryptionState(DataEncryptionState.newBuilder().build()) + .setInternalMetadata("internalMetadata6789388") + .setDisableMoves(true) + .setPrivateResourceMetadata(PrivateResourceMetadata.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createWorkspaceLongRunningTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String parent = "projects/project-9015/locations/location-9015/repositories/repositorie-9015"; + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + + Workspace actualResponse = + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createWorkspaceLongRunningExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-9015/locations/location-9015/repositories/repositorie-9015"; + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + @Test public void deleteWorkspaceTest() throws Exception { Empty expectedResponse = Empty.newBuilder().build(); diff --git a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/DataformClientTest.java b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/DataformClientTest.java index a592375e1ba0..c3680f57fbeb 100644 --- a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/DataformClientTest.java +++ b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/DataformClientTest.java @@ -2460,6 +2460,126 @@ public void createWorkspaceExceptionTest2() throws Exception { } } + @Test + public void createWorkspaceLongRunningTest() throws Exception { + Workspace expectedResponse = + Workspace.newBuilder() + .setName( + WorkspaceName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[WORKSPACE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setDataEncryptionState(DataEncryptionState.newBuilder().build()) + .setInternalMetadata("internalMetadata6789388") + .setDisableMoves(true) + .setPrivateResourceMetadata(PrivateResourceMetadata.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createWorkspaceLongRunningTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockDataform.addResponse(resultOperation); + + RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]"); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + + Workspace actualResponse = + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDataform.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateWorkspaceRequest actualRequest = ((CreateWorkspaceRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(workspace, actualRequest.getWorkspace()); + Assert.assertEquals(workspaceId, actualRequest.getWorkspaceId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createWorkspaceLongRunningExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockDataform.addException(exception); + + try { + RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]"); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void createWorkspaceLongRunningTest2() throws Exception { + Workspace expectedResponse = + Workspace.newBuilder() + .setName( + WorkspaceName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[WORKSPACE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setDataEncryptionState(DataEncryptionState.newBuilder().build()) + .setInternalMetadata("internalMetadata6789388") + .setDisableMoves(true) + .setPrivateResourceMetadata(PrivateResourceMetadata.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createWorkspaceLongRunningTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockDataform.addResponse(resultOperation); + + String parent = "parent-995424086"; + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + + Workspace actualResponse = + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDataform.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateWorkspaceRequest actualRequest = ((CreateWorkspaceRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(workspace, actualRequest.getWorkspace()); + Assert.assertEquals(workspaceId, actualRequest.getWorkspaceId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createWorkspaceLongRunningExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockDataform.addException(exception); + + try { + String parent = "parent-995424086"; + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + @Test public void deleteWorkspaceTest() throws Exception { Empty expectedResponse = Empty.newBuilder().build(); diff --git a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/MockDataformImpl.java b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/MockDataformImpl.java index 2ff66696bbc3..5ad4fff5d095 100644 --- a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/MockDataformImpl.java +++ b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1/MockDataformImpl.java @@ -707,6 +707,28 @@ public void createWorkspace( } } + @Override + public void createWorkspaceLongRunning( + CreateWorkspaceRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method CreateWorkspaceLongRunning, expected %s" + + " or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + @Override public void deleteWorkspace( DeleteWorkspaceRequest request, StreamObserver responseObserver) { diff --git a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/DataformClientHttpJsonTest.java b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/DataformClientHttpJsonTest.java index 3b40aaf7c3d7..986894d820f4 100644 --- a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/DataformClientHttpJsonTest.java +++ b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/DataformClientHttpJsonTest.java @@ -2867,6 +2867,136 @@ public void createWorkspaceExceptionTest2() throws Exception { } } + @Test + public void createWorkspaceLongRunningTest() throws Exception { + Workspace expectedResponse = + Workspace.newBuilder() + .setName( + WorkspaceName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[WORKSPACE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setDataEncryptionState(DataEncryptionState.newBuilder().build()) + .setInternalMetadata("internalMetadata6789388") + .setDisableMoves(true) + .setOriginalBranch("originalBranch1098005203") + .setPrivateResourceMetadata(PrivateResourceMetadata.newBuilder().build()) + .setEnableBranchManagement(true) + .setDepth(95472323) + .setShallow(true) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createWorkspaceLongRunningTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]"); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + + Workspace actualResponse = + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createWorkspaceLongRunningExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]"); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void createWorkspaceLongRunningTest2() throws Exception { + Workspace expectedResponse = + Workspace.newBuilder() + .setName( + WorkspaceName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[WORKSPACE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setDataEncryptionState(DataEncryptionState.newBuilder().build()) + .setInternalMetadata("internalMetadata6789388") + .setDisableMoves(true) + .setOriginalBranch("originalBranch1098005203") + .setPrivateResourceMetadata(PrivateResourceMetadata.newBuilder().build()) + .setEnableBranchManagement(true) + .setDepth(95472323) + .setShallow(true) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createWorkspaceLongRunningTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String parent = "projects/project-9015/locations/location-9015/repositories/repositorie-9015"; + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + + Workspace actualResponse = + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createWorkspaceLongRunningExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-9015/locations/location-9015/repositories/repositorie-9015"; + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + @Test public void deleteWorkspaceTest() throws Exception { Empty expectedResponse = Empty.newBuilder().build(); diff --git a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/DataformClientTest.java b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/DataformClientTest.java index cddf2d8e9f7d..b2f3399bc749 100644 --- a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/DataformClientTest.java +++ b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/DataformClientTest.java @@ -2576,6 +2576,134 @@ public void createWorkspaceExceptionTest2() throws Exception { } } + @Test + public void createWorkspaceLongRunningTest() throws Exception { + Workspace expectedResponse = + Workspace.newBuilder() + .setName( + WorkspaceName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[WORKSPACE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setDataEncryptionState(DataEncryptionState.newBuilder().build()) + .setInternalMetadata("internalMetadata6789388") + .setDisableMoves(true) + .setOriginalBranch("originalBranch1098005203") + .setPrivateResourceMetadata(PrivateResourceMetadata.newBuilder().build()) + .setEnableBranchManagement(true) + .setDepth(95472323) + .setShallow(true) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createWorkspaceLongRunningTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockDataform.addResponse(resultOperation); + + RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]"); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + + Workspace actualResponse = + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDataform.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateWorkspaceRequest actualRequest = ((CreateWorkspaceRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(workspace, actualRequest.getWorkspace()); + Assert.assertEquals(workspaceId, actualRequest.getWorkspaceId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createWorkspaceLongRunningExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockDataform.addException(exception); + + try { + RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]"); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void createWorkspaceLongRunningTest2() throws Exception { + Workspace expectedResponse = + Workspace.newBuilder() + .setName( + WorkspaceName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]", "[WORKSPACE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setDataEncryptionState(DataEncryptionState.newBuilder().build()) + .setInternalMetadata("internalMetadata6789388") + .setDisableMoves(true) + .setOriginalBranch("originalBranch1098005203") + .setPrivateResourceMetadata(PrivateResourceMetadata.newBuilder().build()) + .setEnableBranchManagement(true) + .setDepth(95472323) + .setShallow(true) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createWorkspaceLongRunningTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockDataform.addResponse(resultOperation); + + String parent = "parent-995424086"; + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + + Workspace actualResponse = + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDataform.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateWorkspaceRequest actualRequest = ((CreateWorkspaceRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(workspace, actualRequest.getWorkspace()); + Assert.assertEquals(workspaceId, actualRequest.getWorkspaceId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createWorkspaceLongRunningExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockDataform.addException(exception); + + try { + String parent = "parent-995424086"; + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + client.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + @Test public void deleteWorkspaceTest() throws Exception { Empty expectedResponse = Empty.newBuilder().build(); diff --git a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/MockDataformImpl.java b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/MockDataformImpl.java index ebf8464c2498..a9a751290619 100644 --- a/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/MockDataformImpl.java +++ b/java-dataform/google-cloud-dataform/src/test/java/com/google/cloud/dataform/v1beta1/MockDataformImpl.java @@ -729,6 +729,28 @@ public void createWorkspace( } } + @Override + public void createWorkspaceLongRunning( + CreateWorkspaceRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method CreateWorkspaceLongRunning, expected %s" + + " or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + @Override public void deleteWorkspace( DeleteWorkspaceRequest request, StreamObserver responseObserver) { diff --git a/java-dataform/grpc-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/DataformGrpc.java b/java-dataform/grpc-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/DataformGrpc.java index 2003c9028f11..bb78b29e1ab2 100644 --- a/java-dataform/grpc-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/DataformGrpc.java +++ b/java-dataform/grpc-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/DataformGrpc.java @@ -1399,6 +1399,52 @@ private DataformGrpc() {} return getCreateWorkspaceMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataform.v1.CreateWorkspaceRequest, com.google.longrunning.Operation> + getCreateWorkspaceLongRunningMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateWorkspaceLongRunning", + requestType = com.google.cloud.dataform.v1.CreateWorkspaceRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataform.v1.CreateWorkspaceRequest, com.google.longrunning.Operation> + getCreateWorkspaceLongRunningMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataform.v1.CreateWorkspaceRequest, com.google.longrunning.Operation> + getCreateWorkspaceLongRunningMethod; + if ((getCreateWorkspaceLongRunningMethod = DataformGrpc.getCreateWorkspaceLongRunningMethod) + == null) { + synchronized (DataformGrpc.class) { + if ((getCreateWorkspaceLongRunningMethod = DataformGrpc.getCreateWorkspaceLongRunningMethod) + == null) { + DataformGrpc.getCreateWorkspaceLongRunningMethod = + getCreateWorkspaceLongRunningMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "CreateWorkspaceLongRunning")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataform.v1.CreateWorkspaceRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new DataformMethodDescriptorSupplier("CreateWorkspaceLongRunning")) + .build(); + } + } + } + return getCreateWorkspaceLongRunningMethod; + } + private static volatile io.grpc.MethodDescriptor< com.google.cloud.dataform.v1.DeleteWorkspaceRequest, com.google.protobuf.Empty> getDeleteWorkspaceMethod; @@ -3947,6 +3993,20 @@ default void createWorkspace( getCreateWorkspaceMethod(), responseObserver); } + /** + * + * + *
                      +     * Creates a new Workspace in a given Repository asynchronously.
                      +     * 
                      + */ + default void createWorkspaceLongRunning( + com.google.cloud.dataform.v1.CreateWorkspaceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateWorkspaceLongRunningMethod(), responseObserver); + } + /** * * @@ -5152,6 +5212,22 @@ public void createWorkspace( responseObserver); } + /** + * + * + *
                      +     * Creates a new Workspace in a given Repository asynchronously.
                      +     * 
                      + */ + public void createWorkspaceLongRunning( + com.google.cloud.dataform.v1.CreateWorkspaceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateWorkspaceLongRunningMethod(), getCallOptions()), + request, + responseObserver); + } + /** * * @@ -6348,6 +6424,20 @@ public com.google.cloud.dataform.v1.Workspace createWorkspace( getChannel(), getCreateWorkspaceMethod(), getCallOptions(), request); } + /** + * + * + *
                      +     * Creates a new Workspace in a given Repository asynchronously.
                      +     * 
                      + */ + public com.google.longrunning.Operation createWorkspaceLongRunning( + com.google.cloud.dataform.v1.CreateWorkspaceRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getCreateWorkspaceLongRunningMethod(), getCallOptions(), request); + } + /** * * @@ -7401,6 +7491,19 @@ public com.google.cloud.dataform.v1.Workspace createWorkspace( getChannel(), getCreateWorkspaceMethod(), getCallOptions(), request); } + /** + * + * + *
                      +     * Creates a new Workspace in a given Repository asynchronously.
                      +     * 
                      + */ + public com.google.longrunning.Operation createWorkspaceLongRunning( + com.google.cloud.dataform.v1.CreateWorkspaceRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateWorkspaceLongRunningMethod(), getCallOptions(), request); + } + /** * * @@ -8447,6 +8550,19 @@ protected DataformFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions getChannel().newCall(getCreateWorkspaceMethod(), getCallOptions()), request); } + /** + * + * + *
                      +     * Creates a new Workspace in a given Repository asynchronously.
                      +     * 
                      + */ + public com.google.common.util.concurrent.ListenableFuture + createWorkspaceLongRunning(com.google.cloud.dataform.v1.CreateWorkspaceRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateWorkspaceLongRunningMethod(), getCallOptions()), request); + } + /** * * @@ -9119,50 +9235,51 @@ protected DataformFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions private static final int METHODID_LIST_WORKSPACES = 27; private static final int METHODID_GET_WORKSPACE = 28; private static final int METHODID_CREATE_WORKSPACE = 29; - private static final int METHODID_DELETE_WORKSPACE = 30; - private static final int METHODID_INSTALL_NPM_PACKAGES = 31; - private static final int METHODID_PULL_GIT_COMMITS = 32; - private static final int METHODID_PUSH_GIT_COMMITS = 33; - private static final int METHODID_FETCH_FILE_GIT_STATUSES = 34; - private static final int METHODID_FETCH_GIT_AHEAD_BEHIND = 35; - private static final int METHODID_COMMIT_WORKSPACE_CHANGES = 36; - private static final int METHODID_RESET_WORKSPACE_CHANGES = 37; - private static final int METHODID_FETCH_FILE_DIFF = 38; - private static final int METHODID_QUERY_DIRECTORY_CONTENTS = 39; - private static final int METHODID_SEARCH_FILES = 40; - private static final int METHODID_MAKE_DIRECTORY = 41; - private static final int METHODID_REMOVE_DIRECTORY = 42; - private static final int METHODID_MOVE_DIRECTORY = 43; - private static final int METHODID_READ_FILE = 44; - private static final int METHODID_REMOVE_FILE = 45; - private static final int METHODID_MOVE_FILE = 46; - private static final int METHODID_WRITE_FILE = 47; - private static final int METHODID_LIST_RELEASE_CONFIGS = 48; - private static final int METHODID_GET_RELEASE_CONFIG = 49; - private static final int METHODID_CREATE_RELEASE_CONFIG = 50; - private static final int METHODID_UPDATE_RELEASE_CONFIG = 51; - private static final int METHODID_DELETE_RELEASE_CONFIG = 52; - private static final int METHODID_LIST_COMPILATION_RESULTS = 53; - private static final int METHODID_GET_COMPILATION_RESULT = 54; - private static final int METHODID_CREATE_COMPILATION_RESULT = 55; - private static final int METHODID_CREATE_COMPILATION_RESULT_LONG_RUNNING = 56; - private static final int METHODID_QUERY_COMPILATION_RESULT_ACTIONS = 57; - private static final int METHODID_LIST_WORKFLOW_CONFIGS = 58; - private static final int METHODID_GET_WORKFLOW_CONFIG = 59; - private static final int METHODID_CREATE_WORKFLOW_CONFIG = 60; - private static final int METHODID_UPDATE_WORKFLOW_CONFIG = 61; - private static final int METHODID_DELETE_WORKFLOW_CONFIG = 62; - private static final int METHODID_LIST_WORKFLOW_INVOCATIONS = 63; - private static final int METHODID_GET_WORKFLOW_INVOCATION = 64; - private static final int METHODID_CREATE_WORKFLOW_INVOCATION = 65; - private static final int METHODID_DELETE_WORKFLOW_INVOCATION = 66; - private static final int METHODID_CANCEL_WORKFLOW_INVOCATION = 67; - private static final int METHODID_QUERY_WORKFLOW_INVOCATION_ACTIONS = 68; - private static final int METHODID_GET_CONFIG = 69; - private static final int METHODID_UPDATE_CONFIG = 70; - private static final int METHODID_GET_IAM_POLICY = 71; - private static final int METHODID_SET_IAM_POLICY = 72; - private static final int METHODID_TEST_IAM_PERMISSIONS = 73; + private static final int METHODID_CREATE_WORKSPACE_LONG_RUNNING = 30; + private static final int METHODID_DELETE_WORKSPACE = 31; + private static final int METHODID_INSTALL_NPM_PACKAGES = 32; + private static final int METHODID_PULL_GIT_COMMITS = 33; + private static final int METHODID_PUSH_GIT_COMMITS = 34; + private static final int METHODID_FETCH_FILE_GIT_STATUSES = 35; + private static final int METHODID_FETCH_GIT_AHEAD_BEHIND = 36; + private static final int METHODID_COMMIT_WORKSPACE_CHANGES = 37; + private static final int METHODID_RESET_WORKSPACE_CHANGES = 38; + private static final int METHODID_FETCH_FILE_DIFF = 39; + private static final int METHODID_QUERY_DIRECTORY_CONTENTS = 40; + private static final int METHODID_SEARCH_FILES = 41; + private static final int METHODID_MAKE_DIRECTORY = 42; + private static final int METHODID_REMOVE_DIRECTORY = 43; + private static final int METHODID_MOVE_DIRECTORY = 44; + private static final int METHODID_READ_FILE = 45; + private static final int METHODID_REMOVE_FILE = 46; + private static final int METHODID_MOVE_FILE = 47; + private static final int METHODID_WRITE_FILE = 48; + private static final int METHODID_LIST_RELEASE_CONFIGS = 49; + private static final int METHODID_GET_RELEASE_CONFIG = 50; + private static final int METHODID_CREATE_RELEASE_CONFIG = 51; + private static final int METHODID_UPDATE_RELEASE_CONFIG = 52; + private static final int METHODID_DELETE_RELEASE_CONFIG = 53; + private static final int METHODID_LIST_COMPILATION_RESULTS = 54; + private static final int METHODID_GET_COMPILATION_RESULT = 55; + private static final int METHODID_CREATE_COMPILATION_RESULT = 56; + private static final int METHODID_CREATE_COMPILATION_RESULT_LONG_RUNNING = 57; + private static final int METHODID_QUERY_COMPILATION_RESULT_ACTIONS = 58; + private static final int METHODID_LIST_WORKFLOW_CONFIGS = 59; + private static final int METHODID_GET_WORKFLOW_CONFIG = 60; + private static final int METHODID_CREATE_WORKFLOW_CONFIG = 61; + private static final int METHODID_UPDATE_WORKFLOW_CONFIG = 62; + private static final int METHODID_DELETE_WORKFLOW_CONFIG = 63; + private static final int METHODID_LIST_WORKFLOW_INVOCATIONS = 64; + private static final int METHODID_GET_WORKFLOW_INVOCATION = 65; + private static final int METHODID_CREATE_WORKFLOW_INVOCATION = 66; + private static final int METHODID_DELETE_WORKFLOW_INVOCATION = 67; + private static final int METHODID_CANCEL_WORKFLOW_INVOCATION = 68; + private static final int METHODID_QUERY_WORKFLOW_INVOCATION_ACTIONS = 69; + private static final int METHODID_GET_CONFIG = 70; + private static final int METHODID_UPDATE_CONFIG = 71; + private static final int METHODID_GET_IAM_POLICY = 72; + private static final int METHODID_SET_IAM_POLICY = 73; + private static final int METHODID_TEST_IAM_PERMISSIONS = 74; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -9359,6 +9476,11 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_CREATE_WORKSPACE_LONG_RUNNING: + serviceImpl.createWorkspaceLongRunning( + (com.google.cloud.dataform.v1.CreateWorkspaceRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; case METHODID_DELETE_WORKSPACE: serviceImpl.deleteWorkspace( (com.google.cloud.dataform.v1.DeleteWorkspaceRequest) request, @@ -9835,6 +9957,13 @@ public static final io.grpc.ServerServiceDefinition bindService(AsyncService ser new MethodHandlers< com.google.cloud.dataform.v1.CreateWorkspaceRequest, com.google.cloud.dataform.v1.Workspace>(service, METHODID_CREATE_WORKSPACE))) + .addMethod( + getCreateWorkspaceLongRunningMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataform.v1.CreateWorkspaceRequest, + com.google.longrunning.Operation>( + service, METHODID_CREATE_WORKSPACE_LONG_RUNNING))) .addMethod( getDeleteWorkspaceMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( @@ -10209,6 +10338,7 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getListWorkspacesMethod()) .addMethod(getGetWorkspaceMethod()) .addMethod(getCreateWorkspaceMethod()) + .addMethod(getCreateWorkspaceLongRunningMethod()) .addMethod(getDeleteWorkspaceMethod()) .addMethod(getInstallNpmPackagesMethod()) .addMethod(getPullGitCommitsMethod()) diff --git a/java-dataform/grpc-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/DataformGrpc.java b/java-dataform/grpc-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/DataformGrpc.java index 25611c3c7571..34ac7e1e1589 100644 --- a/java-dataform/grpc-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/DataformGrpc.java +++ b/java-dataform/grpc-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/DataformGrpc.java @@ -1472,6 +1472,55 @@ private DataformGrpc() {} return getCreateWorkspaceMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest, + com.google.longrunning.Operation> + getCreateWorkspaceLongRunningMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateWorkspaceLongRunning", + requestType = com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest, + com.google.longrunning.Operation> + getCreateWorkspaceLongRunningMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest, + com.google.longrunning.Operation> + getCreateWorkspaceLongRunningMethod; + if ((getCreateWorkspaceLongRunningMethod = DataformGrpc.getCreateWorkspaceLongRunningMethod) + == null) { + synchronized (DataformGrpc.class) { + if ((getCreateWorkspaceLongRunningMethod = DataformGrpc.getCreateWorkspaceLongRunningMethod) + == null) { + DataformGrpc.getCreateWorkspaceLongRunningMethod = + getCreateWorkspaceLongRunningMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "CreateWorkspaceLongRunning")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new DataformMethodDescriptorSupplier("CreateWorkspaceLongRunning")) + .build(); + } + } + } + return getCreateWorkspaceLongRunningMethod; + } + private static volatile io.grpc.MethodDescriptor< com.google.cloud.dataform.v1beta1.DeleteWorkspaceRequest, com.google.protobuf.Empty> getDeleteWorkspaceMethod; @@ -4361,6 +4410,20 @@ default void createWorkspace( getCreateWorkspaceMethod(), responseObserver); } + /** + * + * + *
                      +     * Creates a new Workspace in a given Repository asynchronously.
                      +     * 
                      + */ + default void createWorkspaceLongRunning( + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateWorkspaceLongRunningMethod(), responseObserver); + } + /** * * @@ -5693,6 +5756,22 @@ public void createWorkspace( responseObserver); } + /** + * + * + *
                      +     * Creates a new Workspace in a given Repository asynchronously.
                      +     * 
                      + */ + public void createWorkspaceLongRunning( + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateWorkspaceLongRunningMethod(), getCallOptions()), + request, + responseObserver); + } + /** * * @@ -7028,6 +7107,20 @@ public com.google.cloud.dataform.v1beta1.Workspace createWorkspace( getChannel(), getCreateWorkspaceMethod(), getCallOptions(), request); } + /** + * + * + *
                      +     * Creates a new Workspace in a given Repository asynchronously.
                      +     * 
                      + */ + public com.google.longrunning.Operation createWorkspaceLongRunning( + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getCreateWorkspaceLongRunningMethod(), getCallOptions(), request); + } + /** * * @@ -8191,6 +8284,19 @@ public com.google.cloud.dataform.v1beta1.Workspace createWorkspace( getChannel(), getCreateWorkspaceMethod(), getCallOptions(), request); } + /** + * + * + *
                      +     * Creates a new Workspace in a given Repository asynchronously.
                      +     * 
                      + */ + public com.google.longrunning.Operation createWorkspaceLongRunning( + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateWorkspaceLongRunningMethod(), getCallOptions(), request); + } + /** * * @@ -9338,6 +9444,20 @@ protected DataformFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions getChannel().newCall(getCreateWorkspaceMethod(), getCallOptions()), request); } + /** + * + * + *
                      +     * Creates a new Workspace in a given Repository asynchronously.
                      +     * 
                      + */ + public com.google.common.util.concurrent.ListenableFuture + createWorkspaceLongRunning( + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateWorkspaceLongRunningMethod(), getCallOptions()), request); + } + /** * * @@ -10110,56 +10230,57 @@ protected DataformFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions private static final int METHODID_LIST_WORKSPACES = 28; private static final int METHODID_GET_WORKSPACE = 29; private static final int METHODID_CREATE_WORKSPACE = 30; - private static final int METHODID_DELETE_WORKSPACE = 31; - private static final int METHODID_INSTALL_NPM_PACKAGES = 32; - private static final int METHODID_PULL_GIT_COMMITS = 33; - private static final int METHODID_SYNC_WORKSPACE_REFS = 34; - private static final int METHODID_FETCH_WORKSPACE_BRANCHES = 35; - private static final int METHODID_DELETE_BRANCH = 36; - private static final int METHODID_CHECKOUT_WORKSPACE_BRANCH = 37; - private static final int METHODID_FETCH_CURRENT_WORKSPACE_BRANCH = 38; - private static final int METHODID_PUSH_GIT_COMMITS = 39; - private static final int METHODID_FETCH_FILE_GIT_STATUSES = 40; - private static final int METHODID_FETCH_GIT_AHEAD_BEHIND = 41; - private static final int METHODID_FETCH_WORKSPACE_HISTORY = 42; - private static final int METHODID_COMMIT_WORKSPACE_CHANGES = 43; - private static final int METHODID_RESET_WORKSPACE_CHANGES = 44; - private static final int METHODID_FETCH_FILE_DIFF = 45; - private static final int METHODID_QUERY_DIRECTORY_CONTENTS = 46; - private static final int METHODID_SEARCH_FILES = 47; - private static final int METHODID_MAKE_DIRECTORY = 48; - private static final int METHODID_REMOVE_DIRECTORY = 49; - private static final int METHODID_MOVE_DIRECTORY = 50; - private static final int METHODID_READ_FILE = 51; - private static final int METHODID_REMOVE_FILE = 52; - private static final int METHODID_MOVE_FILE = 53; - private static final int METHODID_WRITE_FILE = 54; - private static final int METHODID_LIST_RELEASE_CONFIGS = 55; - private static final int METHODID_GET_RELEASE_CONFIG = 56; - private static final int METHODID_CREATE_RELEASE_CONFIG = 57; - private static final int METHODID_UPDATE_RELEASE_CONFIG = 58; - private static final int METHODID_DELETE_RELEASE_CONFIG = 59; - private static final int METHODID_LIST_COMPILATION_RESULTS = 60; - private static final int METHODID_GET_COMPILATION_RESULT = 61; - private static final int METHODID_CREATE_COMPILATION_RESULT = 62; - private static final int METHODID_CREATE_COMPILATION_RESULT_LONG_RUNNING = 63; - private static final int METHODID_QUERY_COMPILATION_RESULT_ACTIONS = 64; - private static final int METHODID_LIST_WORKFLOW_CONFIGS = 65; - private static final int METHODID_GET_WORKFLOW_CONFIG = 66; - private static final int METHODID_CREATE_WORKFLOW_CONFIG = 67; - private static final int METHODID_UPDATE_WORKFLOW_CONFIG = 68; - private static final int METHODID_DELETE_WORKFLOW_CONFIG = 69; - private static final int METHODID_LIST_WORKFLOW_INVOCATIONS = 70; - private static final int METHODID_GET_WORKFLOW_INVOCATION = 71; - private static final int METHODID_CREATE_WORKFLOW_INVOCATION = 72; - private static final int METHODID_DELETE_WORKFLOW_INVOCATION = 73; - private static final int METHODID_CANCEL_WORKFLOW_INVOCATION = 74; - private static final int METHODID_QUERY_WORKFLOW_INVOCATION_ACTIONS = 75; - private static final int METHODID_GET_CONFIG = 76; - private static final int METHODID_UPDATE_CONFIG = 77; - private static final int METHODID_GET_IAM_POLICY = 78; - private static final int METHODID_SET_IAM_POLICY = 79; - private static final int METHODID_TEST_IAM_PERMISSIONS = 80; + private static final int METHODID_CREATE_WORKSPACE_LONG_RUNNING = 31; + private static final int METHODID_DELETE_WORKSPACE = 32; + private static final int METHODID_INSTALL_NPM_PACKAGES = 33; + private static final int METHODID_PULL_GIT_COMMITS = 34; + private static final int METHODID_SYNC_WORKSPACE_REFS = 35; + private static final int METHODID_FETCH_WORKSPACE_BRANCHES = 36; + private static final int METHODID_DELETE_BRANCH = 37; + private static final int METHODID_CHECKOUT_WORKSPACE_BRANCH = 38; + private static final int METHODID_FETCH_CURRENT_WORKSPACE_BRANCH = 39; + private static final int METHODID_PUSH_GIT_COMMITS = 40; + private static final int METHODID_FETCH_FILE_GIT_STATUSES = 41; + private static final int METHODID_FETCH_GIT_AHEAD_BEHIND = 42; + private static final int METHODID_FETCH_WORKSPACE_HISTORY = 43; + private static final int METHODID_COMMIT_WORKSPACE_CHANGES = 44; + private static final int METHODID_RESET_WORKSPACE_CHANGES = 45; + private static final int METHODID_FETCH_FILE_DIFF = 46; + private static final int METHODID_QUERY_DIRECTORY_CONTENTS = 47; + private static final int METHODID_SEARCH_FILES = 48; + private static final int METHODID_MAKE_DIRECTORY = 49; + private static final int METHODID_REMOVE_DIRECTORY = 50; + private static final int METHODID_MOVE_DIRECTORY = 51; + private static final int METHODID_READ_FILE = 52; + private static final int METHODID_REMOVE_FILE = 53; + private static final int METHODID_MOVE_FILE = 54; + private static final int METHODID_WRITE_FILE = 55; + private static final int METHODID_LIST_RELEASE_CONFIGS = 56; + private static final int METHODID_GET_RELEASE_CONFIG = 57; + private static final int METHODID_CREATE_RELEASE_CONFIG = 58; + private static final int METHODID_UPDATE_RELEASE_CONFIG = 59; + private static final int METHODID_DELETE_RELEASE_CONFIG = 60; + private static final int METHODID_LIST_COMPILATION_RESULTS = 61; + private static final int METHODID_GET_COMPILATION_RESULT = 62; + private static final int METHODID_CREATE_COMPILATION_RESULT = 63; + private static final int METHODID_CREATE_COMPILATION_RESULT_LONG_RUNNING = 64; + private static final int METHODID_QUERY_COMPILATION_RESULT_ACTIONS = 65; + private static final int METHODID_LIST_WORKFLOW_CONFIGS = 66; + private static final int METHODID_GET_WORKFLOW_CONFIG = 67; + private static final int METHODID_CREATE_WORKFLOW_CONFIG = 68; + private static final int METHODID_UPDATE_WORKFLOW_CONFIG = 69; + private static final int METHODID_DELETE_WORKFLOW_CONFIG = 70; + private static final int METHODID_LIST_WORKFLOW_INVOCATIONS = 71; + private static final int METHODID_GET_WORKFLOW_INVOCATION = 72; + private static final int METHODID_CREATE_WORKFLOW_INVOCATION = 73; + private static final int METHODID_DELETE_WORKFLOW_INVOCATION = 74; + private static final int METHODID_CANCEL_WORKFLOW_INVOCATION = 75; + private static final int METHODID_QUERY_WORKFLOW_INVOCATION_ACTIONS = 76; + private static final int METHODID_GET_CONFIG = 77; + private static final int METHODID_UPDATE_CONFIG = 78; + private static final int METHODID_GET_IAM_POLICY = 79; + private static final int METHODID_SET_IAM_POLICY = 80; + private static final int METHODID_TEST_IAM_PERMISSIONS = 81; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -10368,6 +10489,11 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_CREATE_WORKSPACE_LONG_RUNNING: + serviceImpl.createWorkspaceLongRunning( + (com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; case METHODID_DELETE_WORKSPACE: serviceImpl.deleteWorkspace( (com.google.cloud.dataform.v1beta1.DeleteWorkspaceRequest) request, @@ -10904,6 +11030,13 @@ public static final io.grpc.ServerServiceDefinition bindService(AsyncService ser com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest, com.google.cloud.dataform.v1beta1.Workspace>( service, METHODID_CREATE_WORKSPACE))) + .addMethod( + getCreateWorkspaceLongRunningMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest, + com.google.longrunning.Operation>( + service, METHODID_CREATE_WORKSPACE_LONG_RUNNING))) .addMethod( getDeleteWorkspaceMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( @@ -11323,6 +11456,7 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getListWorkspacesMethod()) .addMethod(getGetWorkspaceMethod()) .addMethod(getCreateWorkspaceMethod()) + .addMethod(getCreateWorkspaceLongRunningMethod()) .addMethod(getDeleteWorkspaceMethod()) .addMethod(getInstallNpmPackagesMethod()) .addMethod(getPullGitCommitsMethod()) diff --git a/java-dataform/proto-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/CreateWorkspaceMetadata.java b/java-dataform/proto-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/CreateWorkspaceMetadata.java new file mode 100644 index 000000000000..967ecab5f32f --- /dev/null +++ b/java-dataform/proto-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/CreateWorkspaceMetadata.java @@ -0,0 +1,1622 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/dataform/v1/dataform.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.dataform.v1; + +/** + * + * + *
                      + * Represents the metadata of the `CreateWorkspaceLongRunning` operation.
                      + * 
                      + * + * Protobuf type {@code google.cloud.dataform.v1.CreateWorkspaceMetadata} + */ +@com.google.protobuf.Generated +public final class CreateWorkspaceMetadata extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataform.v1.CreateWorkspaceMetadata) + CreateWorkspaceMetadataOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "CreateWorkspaceMetadata"); + } + + // Use CreateWorkspaceMetadata.newBuilder() to construct. + private CreateWorkspaceMetadata(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private CreateWorkspaceMetadata() { + id_ = ""; + target_ = ""; + state_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataform.v1.DataformProto + .internal_static_google_cloud_dataform_v1_CreateWorkspaceMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataform.v1.DataformProto + .internal_static_google_cloud_dataform_v1_CreateWorkspaceMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataform.v1.CreateWorkspaceMetadata.class, + com.google.cloud.dataform.v1.CreateWorkspaceMetadata.Builder.class); + } + + /** + * + * + *
                      +   * State of the LRO.
                      +   * 
                      + * + * Protobuf enum {@code google.cloud.dataform.v1.CreateWorkspaceMetadata.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                      +     * The state is unspecified.
                      +     * 
                      + * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
                      +     * The LRO has been created.
                      +     * 
                      + * + * CREATED = 1; + */ + CREATED(1), + /** + * + * + *
                      +     * The LRO is in progress.
                      +     * 
                      + * + * RUNNING = 2; + */ + RUNNING(2), + /** + * + * + *
                      +     * The RPC call has finished.
                      +     * 
                      + * + * FINISHED = 3; + */ + FINISHED(3), + /** + * + * + *
                      +     * The LRO has succeeded.
                      +     * 
                      + * + * SUCCEEDED = 4; + */ + SUCCEEDED(4), + /** + * + * + *
                      +     * The LRO has failed.
                      +     * 
                      + * + * FAILED = 5; + */ + FAILED(5), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "State"); + } + + /** + * + * + *
                      +     * The state is unspecified.
                      +     * 
                      + * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                      +     * The LRO has been created.
                      +     * 
                      + * + * CREATED = 1; + */ + public static final int CREATED_VALUE = 1; + + /** + * + * + *
                      +     * The LRO is in progress.
                      +     * 
                      + * + * RUNNING = 2; + */ + public static final int RUNNING_VALUE = 2; + + /** + * + * + *
                      +     * The RPC call has finished.
                      +     * 
                      + * + * FINISHED = 3; + */ + public static final int FINISHED_VALUE = 3; + + /** + * + * + *
                      +     * The LRO has succeeded.
                      +     * 
                      + * + * SUCCEEDED = 4; + */ + public static final int SUCCEEDED_VALUE = 4; + + /** + * + * + *
                      +     * The LRO has failed.
                      +     * 
                      + * + * FAILED = 5; + */ + public static final int FAILED_VALUE = 5; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return CREATED; + case 2: + return RUNNING; + case 3: + return FINISHED; + case 4: + return SUCCEEDED; + case 5: + return FAILED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public State findValueByNumber(int number) { + return State.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.dataform.v1.CreateWorkspaceMetadata.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final State[] VALUES = values(); + + public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private State(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.dataform.v1.CreateWorkspaceMetadata.State) + } + + private int requestCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object request_; + + public enum RequestCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + CREATE_WORKSPACE_REQUEST(4), + REQUEST_NOT_SET(0); + private final int value; + + private RequestCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static RequestCase valueOf(int value) { + return forNumber(value); + } + + public static RequestCase forNumber(int value) { + switch (value) { + case 4: + return CREATE_WORKSPACE_REQUEST; + case 0: + return REQUEST_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public RequestCase getRequestCase() { + return RequestCase.forNumber(requestCase_); + } + + public static final int CREATE_WORKSPACE_REQUEST_FIELD_NUMBER = 4; + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createWorkspaceRequest field is set. + */ + @java.lang.Override + public boolean hasCreateWorkspaceRequest() { + return requestCase_ == 4; + } + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createWorkspaceRequest. + */ + @java.lang.Override + public com.google.cloud.dataform.v1.CreateWorkspaceRequest getCreateWorkspaceRequest() { + if (requestCase_ == 4) { + return (com.google.cloud.dataform.v1.CreateWorkspaceRequest) request_; + } + return com.google.cloud.dataform.v1.CreateWorkspaceRequest.getDefaultInstance(); + } + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.dataform.v1.CreateWorkspaceRequestOrBuilder + getCreateWorkspaceRequestOrBuilder() { + if (requestCase_ == 4) { + return (com.google.cloud.dataform.v1.CreateWorkspaceRequest) request_; + } + return com.google.cloud.dataform.v1.CreateWorkspaceRequest.getDefaultInstance(); + } + + public static final int ID_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object id_ = ""; + + /** + * + * + *
                      +   * Output only. The ID of the LRO.
                      +   * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The id. + */ + @java.lang.Override + public java.lang.String getId() { + java.lang.Object ref = id_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + id_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Output only. The ID of the LRO.
                      +   * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for id. + */ + @java.lang.Override + public com.google.protobuf.ByteString getIdBytes() { + java.lang.Object ref = id_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + id_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TARGET_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object target_ = ""; + + /** + * + * + *
                      +   * Output only. Server-defined resource path for the target of the operation.
                      +   * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + @java.lang.Override + public java.lang.String getTarget() { + java.lang.Object ref = target_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + target_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Output only. Server-defined resource path for the target of the operation.
                      +   * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTargetBytes() { + java.lang.Object ref = target_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + target_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STATE_FIELD_NUMBER = 3; + private int state_ = 0; + + /** + * + * + *
                      +   * Output only. The state of the LRO.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
                      +   * Output only. The state of the LRO.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State getState() { + com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State result = + com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State.forNumber(state_); + return result == null + ? com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(id_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, id_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(target_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, target_); + } + if (state_ + != com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State.STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, state_); + } + if (requestCase_ == 4) { + output.writeMessage(4, (com.google.cloud.dataform.v1.CreateWorkspaceRequest) request_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(id_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, id_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(target_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, target_); + } + if (state_ + != com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State.STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, state_); + } + if (requestCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.cloud.dataform.v1.CreateWorkspaceRequest) request_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.dataform.v1.CreateWorkspaceMetadata)) { + return super.equals(obj); + } + com.google.cloud.dataform.v1.CreateWorkspaceMetadata other = + (com.google.cloud.dataform.v1.CreateWorkspaceMetadata) obj; + + if (!getId().equals(other.getId())) return false; + if (!getTarget().equals(other.getTarget())) return false; + if (state_ != other.state_) return false; + if (!getRequestCase().equals(other.getRequestCase())) return false; + switch (requestCase_) { + case 4: + if (!getCreateWorkspaceRequest().equals(other.getCreateWorkspaceRequest())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ID_FIELD_NUMBER; + hash = (53 * hash) + getId().hashCode(); + hash = (37 * hash) + TARGET_FIELD_NUMBER; + hash = (53 * hash) + getTarget().hashCode(); + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + switch (requestCase_) { + case 4: + hash = (37 * hash) + CREATE_WORKSPACE_REQUEST_FIELD_NUMBER; + hash = (53 * hash) + getCreateWorkspaceRequest().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.dataform.v1.CreateWorkspaceMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Represents the metadata of the `CreateWorkspaceLongRunning` operation.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.dataform.v1.CreateWorkspaceMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataform.v1.CreateWorkspaceMetadata) + com.google.cloud.dataform.v1.CreateWorkspaceMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataform.v1.DataformProto + .internal_static_google_cloud_dataform_v1_CreateWorkspaceMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataform.v1.DataformProto + .internal_static_google_cloud_dataform_v1_CreateWorkspaceMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataform.v1.CreateWorkspaceMetadata.class, + com.google.cloud.dataform.v1.CreateWorkspaceMetadata.Builder.class); + } + + // Construct using com.google.cloud.dataform.v1.CreateWorkspaceMetadata.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (createWorkspaceRequestBuilder_ != null) { + createWorkspaceRequestBuilder_.clear(); + } + id_ = ""; + target_ = ""; + state_ = 0; + requestCase_ = 0; + request_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataform.v1.DataformProto + .internal_static_google_cloud_dataform_v1_CreateWorkspaceMetadata_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataform.v1.CreateWorkspaceMetadata getDefaultInstanceForType() { + return com.google.cloud.dataform.v1.CreateWorkspaceMetadata.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataform.v1.CreateWorkspaceMetadata build() { + com.google.cloud.dataform.v1.CreateWorkspaceMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataform.v1.CreateWorkspaceMetadata buildPartial() { + com.google.cloud.dataform.v1.CreateWorkspaceMetadata result = + new com.google.cloud.dataform.v1.CreateWorkspaceMetadata(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataform.v1.CreateWorkspaceMetadata result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.id_ = id_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.target_ = target_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.state_ = state_; + } + } + + private void buildPartialOneofs(com.google.cloud.dataform.v1.CreateWorkspaceMetadata result) { + result.requestCase_ = requestCase_; + result.request_ = this.request_; + if (requestCase_ == 4 && createWorkspaceRequestBuilder_ != null) { + result.request_ = createWorkspaceRequestBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataform.v1.CreateWorkspaceMetadata) { + return mergeFrom((com.google.cloud.dataform.v1.CreateWorkspaceMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataform.v1.CreateWorkspaceMetadata other) { + if (other == com.google.cloud.dataform.v1.CreateWorkspaceMetadata.getDefaultInstance()) + return this; + if (!other.getId().isEmpty()) { + id_ = other.id_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getTarget().isEmpty()) { + target_ = other.target_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + switch (other.getRequestCase()) { + case CREATE_WORKSPACE_REQUEST: + { + mergeCreateWorkspaceRequest(other.getCreateWorkspaceRequest()); + break; + } + case REQUEST_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + id_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 10 + case 18: + { + target_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 18 + case 24: + { + state_ = input.readEnum(); + bitField0_ |= 0x00000008; + break; + } // case 24 + case 34: + { + input.readMessage( + internalGetCreateWorkspaceRequestFieldBuilder().getBuilder(), + extensionRegistry); + requestCase_ = 4; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int requestCase_ = 0; + private java.lang.Object request_; + + public RequestCase getRequestCase() { + return RequestCase.forNumber(requestCase_); + } + + public Builder clearRequest() { + requestCase_ = 0; + request_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.dataform.v1.CreateWorkspaceRequest, + com.google.cloud.dataform.v1.CreateWorkspaceRequest.Builder, + com.google.cloud.dataform.v1.CreateWorkspaceRequestOrBuilder> + createWorkspaceRequestBuilder_; + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createWorkspaceRequest field is set. + */ + @java.lang.Override + public boolean hasCreateWorkspaceRequest() { + return requestCase_ == 4; + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createWorkspaceRequest. + */ + @java.lang.Override + public com.google.cloud.dataform.v1.CreateWorkspaceRequest getCreateWorkspaceRequest() { + if (createWorkspaceRequestBuilder_ == null) { + if (requestCase_ == 4) { + return (com.google.cloud.dataform.v1.CreateWorkspaceRequest) request_; + } + return com.google.cloud.dataform.v1.CreateWorkspaceRequest.getDefaultInstance(); + } else { + if (requestCase_ == 4) { + return createWorkspaceRequestBuilder_.getMessage(); + } + return com.google.cloud.dataform.v1.CreateWorkspaceRequest.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateWorkspaceRequest( + com.google.cloud.dataform.v1.CreateWorkspaceRequest value) { + if (createWorkspaceRequestBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + request_ = value; + onChanged(); + } else { + createWorkspaceRequestBuilder_.setMessage(value); + } + requestCase_ = 4; + return this; + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateWorkspaceRequest( + com.google.cloud.dataform.v1.CreateWorkspaceRequest.Builder builderForValue) { + if (createWorkspaceRequestBuilder_ == null) { + request_ = builderForValue.build(); + onChanged(); + } else { + createWorkspaceRequestBuilder_.setMessage(builderForValue.build()); + } + requestCase_ = 4; + return this; + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateWorkspaceRequest( + com.google.cloud.dataform.v1.CreateWorkspaceRequest value) { + if (createWorkspaceRequestBuilder_ == null) { + if (requestCase_ == 4 + && request_ + != com.google.cloud.dataform.v1.CreateWorkspaceRequest.getDefaultInstance()) { + request_ = + com.google.cloud.dataform.v1.CreateWorkspaceRequest.newBuilder( + (com.google.cloud.dataform.v1.CreateWorkspaceRequest) request_) + .mergeFrom(value) + .buildPartial(); + } else { + request_ = value; + } + onChanged(); + } else { + if (requestCase_ == 4) { + createWorkspaceRequestBuilder_.mergeFrom(value); + } else { + createWorkspaceRequestBuilder_.setMessage(value); + } + } + requestCase_ = 4; + return this; + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateWorkspaceRequest() { + if (createWorkspaceRequestBuilder_ == null) { + if (requestCase_ == 4) { + requestCase_ = 0; + request_ = null; + onChanged(); + } + } else { + if (requestCase_ == 4) { + requestCase_ = 0; + request_ = null; + } + createWorkspaceRequestBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.dataform.v1.CreateWorkspaceRequest.Builder + getCreateWorkspaceRequestBuilder() { + return internalGetCreateWorkspaceRequestFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.dataform.v1.CreateWorkspaceRequestOrBuilder + getCreateWorkspaceRequestOrBuilder() { + if ((requestCase_ == 4) && (createWorkspaceRequestBuilder_ != null)) { + return createWorkspaceRequestBuilder_.getMessageOrBuilder(); + } else { + if (requestCase_ == 4) { + return (com.google.cloud.dataform.v1.CreateWorkspaceRequest) request_; + } + return com.google.cloud.dataform.v1.CreateWorkspaceRequest.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.dataform.v1.CreateWorkspaceRequest, + com.google.cloud.dataform.v1.CreateWorkspaceRequest.Builder, + com.google.cloud.dataform.v1.CreateWorkspaceRequestOrBuilder> + internalGetCreateWorkspaceRequestFieldBuilder() { + if (createWorkspaceRequestBuilder_ == null) { + if (!(requestCase_ == 4)) { + request_ = com.google.cloud.dataform.v1.CreateWorkspaceRequest.getDefaultInstance(); + } + createWorkspaceRequestBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.dataform.v1.CreateWorkspaceRequest, + com.google.cloud.dataform.v1.CreateWorkspaceRequest.Builder, + com.google.cloud.dataform.v1.CreateWorkspaceRequestOrBuilder>( + (com.google.cloud.dataform.v1.CreateWorkspaceRequest) request_, + getParentForChildren(), + isClean()); + request_ = null; + } + requestCase_ = 4; + onChanged(); + return createWorkspaceRequestBuilder_; + } + + private java.lang.Object id_ = ""; + + /** + * + * + *
                      +     * Output only. The ID of the LRO.
                      +     * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The id. + */ + public java.lang.String getId() { + java.lang.Object ref = id_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + id_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Output only. The ID of the LRO.
                      +     * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for id. + */ + public com.google.protobuf.ByteString getIdBytes() { + java.lang.Object ref = id_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + id_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Output only. The ID of the LRO.
                      +     * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The id to set. + * @return This builder for chaining. + */ + public Builder setId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + id_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The ID of the LRO.
                      +     * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearId() { + id_ = getDefaultInstance().getId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The ID of the LRO.
                      +     * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for id to set. + * @return This builder for chaining. + */ + public Builder setIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + id_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object target_ = ""; + + /** + * + * + *
                      +     * Output only. Server-defined resource path for the target of the operation.
                      +     * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + public java.lang.String getTarget() { + java.lang.Object ref = target_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + target_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Output only. Server-defined resource path for the target of the operation.
                      +     * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + public com.google.protobuf.ByteString getTargetBytes() { + java.lang.Object ref = target_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + target_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Output only. Server-defined resource path for the target of the operation.
                      +     * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The target to set. + * @return This builder for chaining. + */ + public Builder setTarget(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + target_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. Server-defined resource path for the target of the operation.
                      +     * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearTarget() { + target_ = getDefaultInstance().getTarget(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. Server-defined resource path for the target of the operation.
                      +     * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for target to set. + * @return This builder for chaining. + */ + public Builder setTargetBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + target_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private int state_ = 0; + + /** + * + * + *
                      +     * Output only. The state of the LRO.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
                      +     * Output only. The state of the LRO.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The state of the LRO.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State getState() { + com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State result = + com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State.forNumber(state_); + return result == null + ? com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State.UNRECOGNIZED + : result; + } + + /** + * + * + *
                      +     * Output only. The state of the LRO.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000008; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The state of the LRO.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000008); + state_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataform.v1.CreateWorkspaceMetadata) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataform.v1.CreateWorkspaceMetadata) + private static final com.google.cloud.dataform.v1.CreateWorkspaceMetadata DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataform.v1.CreateWorkspaceMetadata(); + } + + public static com.google.cloud.dataform.v1.CreateWorkspaceMetadata getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateWorkspaceMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.dataform.v1.CreateWorkspaceMetadata getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataform/proto-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/CreateWorkspaceMetadataOrBuilder.java b/java-dataform/proto-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/CreateWorkspaceMetadataOrBuilder.java new file mode 100644 index 000000000000..129b414372d3 --- /dev/null +++ b/java-dataform/proto-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/CreateWorkspaceMetadataOrBuilder.java @@ -0,0 +1,155 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/dataform/v1/dataform.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.dataform.v1; + +@com.google.protobuf.Generated +public interface CreateWorkspaceMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataform.v1.CreateWorkspaceMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createWorkspaceRequest field is set. + */ + boolean hasCreateWorkspaceRequest(); + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createWorkspaceRequest. + */ + com.google.cloud.dataform.v1.CreateWorkspaceRequest getCreateWorkspaceRequest(); + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.dataform.v1.CreateWorkspaceRequestOrBuilder getCreateWorkspaceRequestOrBuilder(); + + /** + * + * + *
                      +   * Output only. The ID of the LRO.
                      +   * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The id. + */ + java.lang.String getId(); + + /** + * + * + *
                      +   * Output only. The ID of the LRO.
                      +   * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for id. + */ + com.google.protobuf.ByteString getIdBytes(); + + /** + * + * + *
                      +   * Output only. Server-defined resource path for the target of the operation.
                      +   * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + java.lang.String getTarget(); + + /** + * + * + *
                      +   * Output only. Server-defined resource path for the target of the operation.
                      +   * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + com.google.protobuf.ByteString getTargetBytes(); + + /** + * + * + *
                      +   * Output only. The state of the LRO.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
                      +   * Output only. The state of the LRO.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.dataform.v1.CreateWorkspaceMetadata.State getState(); + + com.google.cloud.dataform.v1.CreateWorkspaceMetadata.RequestCase getRequestCase(); +} diff --git a/java-dataform/proto-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/DataformProto.java b/java-dataform/proto-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/DataformProto.java index 90b6e2d155ae..664431b15bb4 100644 --- a/java-dataform/proto-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/DataformProto.java +++ b/java-dataform/proto-google-cloud-dataform-v1/src/main/java/com/google/cloud/dataform/v1/DataformProto.java @@ -196,6 +196,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_dataform_v1_CreateWorkspaceRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_dataform_v1_CreateWorkspaceRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataform_v1_CreateWorkspaceMetadata_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_dataform_v1_CreateWorkspaceMetadata_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_dataform_v1_DeleteWorkspaceRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -1010,7 +1014,22 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\"dataform.googleapis.com/Repository\022<\n" + "\tworkspace\030\002" + " \001(\0132#.google.cloud.dataform.v1.WorkspaceB\004\342A\001\002\022\032\n" - + "\014workspace_id\030\003 \001(\tB\004\342A\001\002\"R\n" + + "\014workspace_id\030\003 \001(\tB\004\342A\001\002\"\331\002\n" + + "\027CreateWorkspaceMetadata\022Z\n" + + "\030create_workspace_request\030\004 \001(" + + "\01320.google.cloud.dataform.v1.CreateWorkspaceRequestB\004\342A\001\003H\000\022\020\n" + + "\002id\030\001 \001(\tB\004\342A\001\003\022\024\n" + + "\006target\030\002 \001(\tB\004\342A\001\003\022L\n" + + "\005state\030\003 \001(\01627.goo" + + "gle.cloud.dataform.v1.CreateWorkspaceMetadata.StateB\004\342A\001\003\"a\n" + + "\005State\022\025\n" + + "\021STATE_UNSPECIFIED\020\000\022\013\n" + + "\007CREATED\020\001\022\013\n" + + "\007RUNNING\020\002\022\014\n" + + "\010FINISHED\020\003\022\r\n" + + "\tSUCCEEDED\020\004\022\n\n" + + "\006FAILED\020\005B\t\n" + + "\007request\"R\n" + "\026DeleteWorkspaceRequest\0228\n" + "\004name\030\001 \001(\tB*\342A\001\002\372A#\n" + "!dataform.googleapis.com/Workspace\"?\n" @@ -1033,12 +1052,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004name\030\001 \001(\tB*\342A\001\002\372A#\n" + "!dataform.googleapis.com/Workspace\"\370\002\n" + "\034FetchFileGitStatusesResponse\022n\n" - + "\030uncommitted_file_changes\030\001 \003(\0132L.google.cloud.d" - + "ataform.v1.FetchFileGitStatusesResponse.UncommittedFileChange\032\347\001\n" + + "\030uncommitted_file_changes\030\001 \003(\0132L.google.cloud.dataform.v1.F" + + "etchFileGitStatusesResponse.UncommittedFileChange\032\347\001\n" + "\025UncommittedFileChange\022\014\n" + "\004path\030\001 \001(\t\022g\n" - + "\005state\030\002 \001(\0162R.google.cloud.dataform.v1.FetchFileGitStat" - + "usesResponse.UncommittedFileChange.StateB\004\342A\001\003\"W\n" + + "\005state\030\002 \001(\0162R.google.cloud." + + "dataform.v1.FetchFileGitStatusesResponse.UncommittedFileChange.StateB\004\342A\001\003\"W\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\t\n" + "\005ADDED\020\001\022\013\n" @@ -1055,8 +1074,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\035CommitWorkspaceChangesRequest\0228\n" + "\004name\030\001 \001(\tB*\342A\001\002\372A#\n" + "!dataform.googleapis.com/Workspace\022<\n" - + "\006author\030\004 \001(\0132&" - + ".google.cloud.dataform.v1.CommitAuthorB\004\342A\001\002\022\034\n" + + "\006author\030\004" + + " \001(\0132&.google.cloud.dataform.v1.CommitAuthorB\004\342A\001\002\022\034\n" + "\016commit_message\030\002 \001(\tB\004\342A\001\001\022\023\n" + "\005paths\030\003 \003(\tB\004\342A\001\001\" \n" + "\036CommitWorkspaceChangesResponse\"\202\001\n" @@ -1078,8 +1097,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004path\030\002 \001(\tB\004\342A\001\001\022\027\n" + "\tpage_size\030\003 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\004 \001(\tB\004\342A\001\001\022C\n" - + "\004view\030\005 \001(\0162/.goog" - + "le.cloud.dataform.v1.DirectoryContentsViewB\004\342A\001\001\"~\n" + + "\004view\030\005" + + " \001(\0162/.google.cloud.dataform.v1.DirectoryContentsViewB\004\342A\001\001\"~\n" + "\036QueryDirectoryContentsResponse\022C\n" + "\021directory_entries\030\001" + " \003(\0132(.google.cloud.dataform.v1.DirectoryEntry\022\027\n" @@ -1087,8 +1106,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016DirectoryEntry\022\016\n" + "\004file\030\001 \001(\tH\000\022\023\n" + "\tdirectory\030\002 \001(\tH\000\022C\n" - + "\010metadata\030\003" - + " \001(\01321.google.cloud.dataform.v1.FilesystemEntryMetadataB\007\n" + + "\010metadata\030\003 \001(\01321" + + ".google.cloud.dataform.v1.FilesystemEntryMetadataB\007\n" + "\005entry\"j\n" + "\027FilesystemEntryMetadata\022\030\n\n" + "size_bytes\030\001 \001(\003B\004\342A\001\003\0225\n" @@ -1097,7 +1116,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\022SearchFilesRequest\022=\n" + "\tworkspace\030\001 \001(\tB*\342A\001\002\372A#\n" + "!dataform.googleapis.com/Workspace\022\027\n" - + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n" + + "\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\"t\n" + "\023SearchFilesResponse\022>\n" @@ -1105,8 +1125,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017next_page_token\030\002 \001(\tB\004\342A\001\001\"\231\001\n" + "\014SearchResult\022:\n" + "\004file\030\001 \001(\0132*.google.cloud.dataform.v1.FileSearchResultH\000\022D\n" - + "\tdirectory\030\002 \001(\0132/.google" - + ".cloud.dataform.v1.DirectorySearchResultH\000B\007\n" + + "\tdirectory\030\002" + + " \001(\0132/.google.cloud.dataform.v1.DirectorySearchResultH\000B\007\n" + "\005entry\" \n" + "\020FileSearchResult\022\014\n" + "\004path\030\001 \001(\t\"%\n" @@ -1161,12 +1181,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ReleaseConfig\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\033\n\r" + "git_commitish\030\002 \001(\tB\004\342A\001\002\022V\n" - + "\027code_compilation_config\030\003 \001(\0132/.goo" - + "gle.cloud.dataform.v1.CodeCompilationConfigB\004\342A\001\001\022\033\n\r" + + "\027code_compilation_config\030\003" + + " \001(\0132/.google.cloud.dataform.v1.CodeCompilationConfigB\004\342A\001\001\022\033\n" + + "\r" + "cron_schedule\030\004 \001(\tB\004\342A\001\001\022\027\n" + "\ttime_zone\030\007 \001(\tB\004\342A\001\001\022n\n" - + " recent_scheduled_release_records\030\005 \003(\0132>.google.cloud" - + ".dataform.v1.ReleaseConfig.ScheduledReleaseRecordB\004\342A\001\003\022V\n" + + " recent_scheduled_release_records\030\005 \003(\0132>.google.cloud.dataform.v1" + + ".ReleaseConfig.ScheduledReleaseRecordB\004\342A\001\003\022V\n" + "\032release_compilation_result\030\006 \001(\tB2\342A\001\001\372A+\n" + ")dataform.googleapis.com/CompilationResult\022\026\n" + "\010disabled\030\010 \001(\010B\004\342A\001\001\022$\n" @@ -1178,9 +1199,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\014release_time\030\001" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003B\010\n" + "\006result:\255\001\352A\251\001\n" - + "%dataform.googleapis.com/ReleaseConfig\022aprojects/{pr" - + "oject}/locations/{location}/repositories" - + "/{repository}/releaseConfigs/{release_config}*\016releaseConfigs2\r" + + "%dataform.googleapis.com/ReleaseConfig\022aprojects/{project}/locat" + + "ions/{location}/repositories/{repository" + + "}/releaseConfigs/{release_config}*\016releaseConfigs2\r" + "releaseConfigB\024\n" + "\022_internal_metadata\"\213\001\n" + "\031ListReleaseConfigsRequest\022;\n" @@ -1217,31 +1238,30 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016release_config\030\007 \001(\tB.\342A\001\005\372A\'\n" + "%dataform.googleapis.com/ReleaseConfigH\000\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\003\022V\n" - + "\027code_compilation_config\030\004 \001" - + "(\0132/.google.cloud.dataform.v1.CodeCompilationConfigB\004\342A\001\005\022%\n" + + "\027code_compilation_config\030\004 \001(\0132/.google." + + "cloud.dataform.v1.CodeCompilationConfigB\004\342A\001\005\022%\n" + "\027resolved_git_commit_sha\030\010 \001(\tB\004\342A\001\003\022#\n" + "\025dataform_core_version\030\005 \001(\tB\004\342A\001\003\022^\n" - + "\022compilation_errors\030\006 \003(" - + "\0132<.google.cloud.dataform.v1.CompilationResult.CompilationErrorB\004\342A\001\003\022R\n" + + "\022compilation_errors\030\006 \003(\0132<.google.c" + + "loud.dataform.v1.CompilationResult.CompilationErrorB\004\342A\001\003\022R\n" + "\025data_encryption_state\030\t" + " \001(\0132-.google.cloud.dataform.v1.DataEncryptionStateB\004\342A\001\003\0225\n" + "\013create_time\030\n" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022$\n" + "\021internal_metadata\030\013 \001(\tB\004\342A\001\003H\001\210\001\001\022Z\n" - + "\031private_resource_metadata\030\014 \001(" - + "\01321.google.cloud.dataform.v1.PrivateResourceMetadataB\004\342A\001\003\022g\n" + + "\031private_resource_metadata\030\014 \001(\01321.google.c" + + "loud.dataform.v1.PrivateResourceMetadataB\004\342A\001\003\022g\n" + " gcs_repository_snapshot_metadata\030\r" - + " \001(\01327.google.cloud.data" - + "form.v1.GcsRepositorySnapshotMetadataB\004\342A\001\003\032\221\001\n" + + " \001(\01327.google.cloud.dataform.v1.GcsRepositorySnapshotMetadataB\004\342A\001\003\032\221\001\n" + "\020CompilationError\022\025\n" + "\007message\030\001 \001(\tB\004\342A\001\003\022\023\n" + "\005stack\030\002 \001(\tB\004\342A\001\003\022\022\n" + "\004path\030\003 \001(\tB\004\342A\001\003\022=\n\r" + "action_target\030\004 \001(\0132" + " .google.cloud.dataform.v1.TargetB\004\342A\001\003:\301\001\352A\275\001\n" - + ")dataform.googleapis.com/CompilationResult\022iprojects/{project}/locations/{locatio" - + "n}/repositories/{repository}/compilation" - + "Results/{compilation_result}*\022compilationResults2\021compilationResultB\010\n" + + ")dataform.googleapis.com/CompilationResult\022iprojects/" + + "{project}/locations/{location}/repositories/{repository}/compilationResults/{com" + + "pilation_result}*\022compilationResults2\021compilationResultB\010\n" + "\006sourceB\024\n" + "\022_internal_metadata\"\371\004\n" + "\025CodeCompilationConfig\022\036\n" @@ -1249,15 +1269,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016default_schema\030\002 \001(\tB\004\342A\001\001\022\036\n" + "\020default_location\030\010 \001(\tB\004\342A\001\001\022\036\n" + "\020assertion_schema\030\003 \001(\tB\004\342A\001\001\022M\n" - + "\004vars\030\004 \003(\01329.google.cloud" - + ".dataform.v1.CodeCompilationConfig.VarsEntryB\004\342A\001\001\022\035\n" + + "\004vars\030\004 \003(\01329.google.cloud.dataform.v1" + + ".CodeCompilationConfig.VarsEntryB\004\342A\001\001\022\035\n" + "\017database_suffix\030\005 \001(\tB\004\342A\001\001\022\033\n\r" + "schema_suffix\030\006 \001(\tB\004\342A\001\001\022\032\n" + "\014table_prefix\030\007 \001(\tB\004\342A\001\001\022+\n" + "\035builtin_assertion_name_prefix\030\n" + " \001(\tB\004\342A\001\001\022`\n" - + " default_notebook_runtime_options\030\t \001(\01320.google.cloud" - + ".dataform.v1.NotebookRuntimeOptionsB\004\342A\001\001\022G\n" + + " default_notebook_runtime_options\030\t" + + " \001(\01320.google.cloud.dataform.v1.NotebookRuntimeOptionsB\004\342A\001\001\022G\n" + "\017pipeline_config\030\014" + " \001(\0132(.google.cloud.dataform.v1.PipelineConfigB\004\342A\001\001\022\"\n" + "\017lineage_enabled\030\016 \001(\010B\004\342A\001\003H\000\210\001\001\032+\n" @@ -1273,50 +1293,50 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\027repository_snapshot_uri\030\001 \001(\tB\004\342A\001\001\"\310\002\n" + "\026NotebookRuntimeOptions\022!\n" + "\021gcs_output_bucket\030\001 \001(\tB\004\342A\001\001H\000\022o\n" - + "#gcs_repository_snapshot_destination\030\003" - + " \001(\0132:.google.cloud.dataform.v1.GcsRepositorySnapshotDestinationB\004\342A\001\001H\001\022i\n" + + "#gcs_repository_snapshot_destination\030\003 \001(\0132:.goo" + + "gle.cloud.dataform.v1.GcsRepositorySnapshotDestinationB\004\342A\001\001H\001\022i\n" + "%ai_platform_notebook_runtime_template\030\002 \001(\tB:\342A\001\001\372A3\n" + "1aiplatform.googleapis.com/NotebookRuntimeTemplateB\020\n" + "\016execution_sinkB\035\n" + "\033repository_snapshot_storage\"\314\001\n" - + "\016PipelineConfig\022R\n\r" - + "pipeline_type\030\001 \001(\01625.googl" - + "e.cloud.dataform.v1.PipelineConfig.PipelineTypeB\004\342A\001\002\022\022\n" + + "\016PipelineConfig\022R\n" + + "\r" + + "pipeline_type\030\001 \001(\01625.google.cloud.data" + + "form.v1.PipelineConfig.PipelineTypeB\004\342A\001\002\022\022\n" + "\004path\030\002 \001(\tB\004\342A\001\002\"R\n" + "\014PipelineType\022\035\n" + "\031PIPELINE_TYPE_UNSPECIFIED\020\000\022\014\n" + "\010DATAFORM\020\001\022\007\n" + "\003SQL\020\003\022\014\n" + "\010NOTEBOOK\020\004\"\275\001\n" - + "\035ListCompilationResultsRequest\022;\n" + + "\035ListCompil", + "ationResultsRequest\022;\n" + "\006parent\030\001 \001(\tB+\342A\001\002\372A$\n" + "\"dataform.googleapis.com/Repository\022\027\n" - + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n" - + "\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\026\n" + "\010order_by\030\004 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\"\230\001\n" + "\036ListCompilationResultsResponse\022H\n" - + "\023compilation_results\030\001" - + " \003(\0132+.google.cloud.dataform.v1.CompilationResult\022\027\n" + + "\023compilation_results\030\001 \003(" + + "\0132+.google.cloud.dataform.v1.CompilationResult\022\027\n" + "\017next_page_token\030\002 \001(\t\022\023\n" + "\013unreachable\030\003 \003(\t\"_\n" - + "\033GetCompilati", - "onResultRequest\022@\n" + + "\033GetCompilationResultRequest\022@\n" + "\004name\030\001 \001(\tB2\342A\001\002\372A+\n" + ")dataform.googleapis.com/CompilationResult\"\254\001\n" + "\036CreateCompilationResultRequest\022;\n" + "\006parent\030\001 \001(\tB+\342A\001\002\372A$\n" + "\"dataform.googleapis.com/Repository\022M\n" - + "\022compilation_result\030\002" - + " \001(\0132+.google.cloud.dataform.v1.CompilationResultB\004\342A\001\002\"\355\002\n" + + "\022compilation_result\030\002 \001(\0132+.goog" + + "le.cloud.dataform.v1.CompilationResultB\004\342A\001\002\"\355\002\n" + "\037CreateCompilationResultMetadata\022\020\n" + "\002id\030\001 \001(\tB\004\342A\001\003\022\024\n" + "\006target\030\002 \001(\tB\004\342A\001\003\022T\n" - + "\005state\030\003 \001(\0162?.google.clo" - + "ud.dataform.v1.CreateCompilationResultMetadata.StateB\004\342A\001\003\022i\n" - + "!create_compilation_result_request\030\004 \001(\01328.google.cloud.dat" - + "aform.v1.CreateCompilationResultRequestB\004\342A\001\003\"a\n" + + "\005state\030\003 \001(\0162?.google.cloud.dataform." + + "v1.CreateCompilationResultMetadata.StateB\004\342A\001\003\022i\n" + + "!create_compilation_result_request\030\004" + + " \001(\01328.google.cloud.dataform.v1.CreateCompilationResultRequestB\004\342A\001\003\"a\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\013\n" + "\007CREATED\020\001\022\013\n" @@ -1330,10 +1350,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004name\030\003 \001(\tB\004\342A\001\001\"\340\002\n" + "\022RelationDescriptor\022\023\n" + "\013description\030\001 \001(\t\022N\n" - + "\007columns\030\002 \003(" - + "\0132=.google.cloud.dataform.v1.RelationDescriptor.ColumnDescriptor\022Y\n" - + "\017bigquery_labels\030\003" - + " \003(\0132@.google.cloud.dataform.v1.RelationDescriptor.BigqueryLabelsEntry\032S\n" + + "\007columns\030\002 \003(\0132=.google.c" + + "loud.dataform.v1.RelationDescriptor.ColumnDescriptor\022Y\n" + + "\017bigquery_labels\030\003 \003(\0132@." + + "google.cloud.dataform.v1.RelationDescriptor.BigqueryLabelsEntry\032S\n" + "\020ColumnDescriptor\022\014\n" + "\004path\030\001 \003(\t\022\023\n" + "\013description\030\002 \001(\t\022\034\n" @@ -1342,20 +1362,20 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001\"\306 \n" + "\027CompilationResultAction\022N\n" - + "\010relation\030\004 \001(\0132:.google.cloud.dat" - + "aform.v1.CompilationResultAction.RelationH\000\022R\n\n" - + "operations\030\005 \001(\0132<.google.cloud.d" - + "ataform.v1.CompilationResultAction.OperationsH\000\022P\n" - + "\tassertion\030\006 \001(\0132;.google.clou" - + "d.dataform.v1.CompilationResultAction.AssertionH\000\022T\n" - + "\013declaration\030\007 \001(\0132=.google." - + "cloud.dataform.v1.CompilationResultAction.DeclarationH\000\022N\n" - + "\010notebook\030\010 \001(\0132:.goog" - + "le.cloud.dataform.v1.CompilationResultAction.NotebookH\000\022]\n" - + "\020data_preparation\030\t \001(" - + "\0132A.google.cloud.dataform.v1.CompilationResultAction.DataPreparationH\000\022`\n" - + "\022bigquery_unit_test\030\013 \001(\0132B.google.cloud.datafo" - + "rm.v1.CompilationResultAction.BigQueryUnitTestH\000\0220\n" + + "\010relation\030\004" + + " \001(\0132:.google.cloud.dataform.v1.CompilationResultAction.RelationH\000\022R\n\n" + + "operations\030\005" + + " \001(\0132<.google.cloud.dataform.v1.CompilationResultAction.OperationsH\000\022P\n" + + "\tassertion\030\006" + + " \001(\0132;.google.cloud.dataform.v1.CompilationResultAction.AssertionH\000\022T\n" + + "\013declaration\030\007 \001(\0132=.google.cloud.datafo" + + "rm.v1.CompilationResultAction.DeclarationH\000\022N\n" + + "\010notebook\030\010 \001(\0132:.google.cloud.dat" + + "aform.v1.CompilationResultAction.NotebookH\000\022]\n" + + "\020data_preparation\030\t \001(\0132A.google.c" + + "loud.dataform.v1.CompilationResultAction.DataPreparationH\000\022`\n" + + "\022bigquery_unit_test\030\013" + + " \001(\0132B.google.cloud.dataform.v1.CompilationResultAction.BigQueryUnitTestH\000\0220\n" + "\006target\030\001 \001(\0132 .google.cloud.dataform.v1.Target\022:\n" + "\020canonical_target\030\002 \001(\0132 .google.cloud.dataform.v1.Target\022\021\n" + "\tfile_path\030\003 \001(\t\022$\n" @@ -1366,28 +1386,27 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010disabled\030\002 \001(\010\022\014\n" + "\004tags\030\003 \003(\t\022I\n" + "\023relation_descriptor\030\004" - + " \001(\0132,.google.cloud.dataform.v1.RelationDescriptor\022^\n" - + "\r" - + "relation_type\030\005 \001(\0162G.google.cloud.data" - + "form.v1.CompilationResultAction.Relation.RelationType\022\024\n" + + " \001(\0132,.google.cloud.dataform.v1.RelationDescriptor\022^\n\r" + + "relation_type\030\005 \001(\0162G.google.cloud.dataform.v1.Comp" + + "ilationResultAction.Relation.RelationType\022\024\n" + "\014select_query\030\006 \001(\t\022\026\n" + "\016pre_operations\030\007 \003(\t\022\027\n" + "\017post_operations\030\010 \003(\t\022s\n" - + "\030incremental_table_config\030\t \001(\0132Q.google.cloud.dataform.v1.CompilationRes" - + "ultAction.Relation.IncrementalTableConfig\022\034\n" + + "\030incremental_table_config\030\t \001(\0132Q.google.clou" + + "d.dataform.v1.CompilationResultAction.Relation.IncrementalTableConfig\022\034\n" + "\024partition_expression\030\n" + " \001(\t\022\033\n" + "\023cluster_expressions\030\013 \003(\t\022!\n" + "\031partition_expiration_days\030\014 \001(\005\022 \n" + "\030require_partition_filter\030\r" + " \001(\010\022m\n" - + "\022additional_options\030\016 \003(\0132Q.google.cloud.dataform.v1.CompilationResu" - + "ltAction.Relation.AdditionalOptionsEntry\022\030\n\n" + + "\022additional_options\030\016 \003(\0132Q.google.cloud" + + ".dataform.v1.CompilationResultAction.Relation.AdditionalOptionsEntry\022\030\n\n" + "connection\030\017 \001(\tB\004\342A\001\001\022b\n" - + "\014table_format\030\020 \001(\0162F.google.cloud.dataform.v1.Comp" - + "ilationResultAction.Relation.TableFormatB\004\342A\001\001\022`\n" - + "\013file_format\030\021 \001(\0162E.google.clo" - + "ud.dataform.v1.CompilationResultAction.Relation.FileFormatB\004\342A\001\001\022\031\n" + + "\014table_format\030\020 \001(\0162F.g" + + "oogle.cloud.dataform.v1.CompilationResultAction.Relation.TableFormatB\004\342A\001\001\022`\n" + + "\013file_format\030\021 \001(\0162E.google.cloud.dataform." + + "v1.CompilationResultAction.Relation.FileFormatB\004\342A\001\001\022\031\n" + "\013storage_uri\030\022 \001(\tB\004\342A\001\001\032\330\001\n" + "\026IncrementalTableConfig\022 \n" + "\030incremental_select_query\030\001 \001(\t\022\030\n" @@ -1410,16 +1429,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\007ICEBERG\020\001\"6\n\n" + "FileFormat\022\033\n" + "\027FILE_FORMAT_UNSPECIFIED\020\000\022\013\n" - + "\007PARQUET\020\001\032\332\001\n" - + "\n" + + "\007PARQUET\020\001\032\332\001\n\n" + "Operations\022<\n" + "\022dependency_targets\030\001 \003(\0132 .google.cloud.dataform.v1.Target\022\020\n" + "\010disabled\030\002 \001(\010\022\014\n" + "\004tags\030\003 \003(\t\022I\n" - + "\023relation_descriptor\030\006" - + " \001(\0132,.google.cloud.dataform.v1.RelationDescriptor\022\017\n" - + "\007queries\030\004 \003(\t\022\022\n" - + "\n" + + "\023relation_descriptor\030\006 \001" + + "(\0132,.google.cloud.dataform.v1.RelationDescriptor\022\017\n" + + "\007queries\030\004 \003(\t\022\022\n\n" + "has_output\030\005 \001(\010\032\203\002\n" + "\tAssertion\022<\n" + "\022dependency_targets\030\001 \003(\0132 .google.cloud.dataform.v1.Target\0227\n\r" @@ -1427,11 +1444,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010disabled\030\002 \001(\010\022\014\n" + "\004tags\030\003 \003(\t\022\024\n" + "\014select_query\030\004 \001(\t\022I\n" - + "\023relation_descriptor\030\006 \001(\0132,.goog" - + "le.cloud.dataform.v1.RelationDescriptor\032X\n" + + "\023relation_descriptor\030\006" + + " \001(\0132,.google.cloud.dataform.v1.RelationDescriptor\032X\n" + "\013Declaration\022I\n" - + "\023relation_descriptor\030\001 " - + "\001(\0132,.google.cloud.dataform.v1.RelationDescriptor\032z\n" + + "\023relation_descriptor\030\001" + + " \001(\0132,.google.cloud.dataform.v1.RelationDescriptor\032z\n" + "\010Notebook\022<\n" + "\022dependency_targets\030\001 \003(\0132 .google.cloud.dataform.v1.Target\022\020\n" + "\010disabled\030\002 \001(\010\022\020\n" @@ -1439,17 +1456,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004tags\030\004 \003(\t\032\247\004\n" + "\017DataPreparation\022\027\n\r" + "contents_yaml\030\005 \001(\tH\000\022g\n" - + "\014contents_sql\030\006 \001(\0132O.google.cloud.dataform.v1.CompilationR" - + "esultAction.DataPreparation.SqlDefinitionH\000\022<\n" + + "\014contents_sql\030\006 \001(\0132O.google.cl" + + "oud.dataform.v1.CompilationResultAction.DataPreparation.SqlDefinitionH\000\022<\n" + "\022dependency_targets\030\001 \003(\0132 .google.cloud.dataform.v1.Target\022\020\n" + "\010disabled\030\002 \001(\010\022\014\n" + "\004tags\030\004 \003(\t\032\315\001\n\r" + "SqlDefinition\022\r\n" + "\005query\030\001 \001(\t\022a\n" - + "\013error_table\030\002 \001(\0132L.google" - + ".cloud.dataform.v1.CompilationResultAction.DataPreparation.ErrorTable\022J\n" - + "\004load\030\003 " - + "\001(\0132<.google.cloud.dataform.v1.CompilationResultAction.LoadConfig\032V\n\n" + + "\013error_table\030\002 \001(\0132L.google.cloud.dataf" + + "orm.v1.CompilationResultAction.DataPreparation.ErrorTable\022J\n" + + "\004load\030\003 \001(\0132<.google" + + ".cloud.dataform.v1.CompilationResultAction.LoadConfig\032V\n\n" + "ErrorTable\0220\n" + "\006target\030\001 \001(\0132 .google.cloud.dataform.v1.Target\022\026\n" + "\016retention_days\030\002 \001(\005B\014\n\n" @@ -1462,14 +1479,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "test_query\030\005 \001(\t\022\035\n" + "\025expected_output_query\030\006 \001(\t\032\360\002\n\n" + "LoadConfig\022S\n" - + "\007replace\030\001 \001(\0132@.google.clo" - + "ud.dataform.v1.CompilationResultAction.SimpleLoadModeH\000\022R\n" - + "\006append\030\002 \001(\0132@.google" - + ".cloud.dataform.v1.CompilationResultAction.SimpleLoadModeH\000\022X\n" - + "\007maximum\030\003 \001(\0132E.g" - + "oogle.cloud.dataform.v1.CompilationResultAction.IncrementalLoadModeH\000\022W\n" - + "\006unique\030\004 \001(\0132E.google.cloud.dataform.v1.Compila" - + "tionResultAction.IncrementalLoadModeH\000B\006\n" + + "\007replace\030\001 \001(\0132@.google.cloud.dataform." + + "v1.CompilationResultAction.SimpleLoadModeH\000\022R\n" + + "\006append\030\002 \001(\0132@.google.cloud.dataf" + + "orm.v1.CompilationResultAction.SimpleLoadModeH\000\022X\n" + + "\007maximum\030\003 \001(\0132E.google.cloud." + + "dataform.v1.CompilationResultAction.IncrementalLoadModeH\000\022W\n" + + "\006unique\030\004 \001(\0132E.goog" + + "le.cloud.dataform.v1.CompilationResultAction.IncrementalLoadModeH\000B\006\n" + "\004mode\032\020\n" + "\016SimpleLoadMode\032%\n" + "\023IncrementalLoadMode\022\016\n" @@ -1483,8 +1500,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\"\227\001\n" + "%QueryCompilationResultActionsResponse\022U\n" - + "\032compilation_result_actions\030\001 \003" - + "(\01321.google.cloud.dataform.v1.CompilationResultAction\022\027\n" + + "\032compilation_result_actions\030\001 \003(\01321.google." + + "cloud.dataform.v1.CompilationResultAction\022\027\n" + "\017next_page_token\030\002 \001(\t\"\270\007\n" + "\016WorkflowConfig\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022F\n" @@ -1494,8 +1511,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132*.google.cloud.dataform.v1.InvocationConfigB\004\342A\001\001\022\033\n\r" + "cron_schedule\030\004 \001(\tB\004\342A\001\001\022\027\n" + "\ttime_zone\030\007 \001(\tB\004\342A\001\001\022s\n" - + "\"recent_scheduled_execution_records\030\005" - + " \003(\0132A.google.cloud.dataform.v1.WorkflowConfig.ScheduledExecutionRecordB\004\342A\001\003\022\026\n" + + "\"recent_scheduled_execution_records\030\005 \003(\0132A.googl" + + "e.cloud.dataform.v1.WorkflowConfig.ScheduledExecutionRecordB\004\342A\001\003\022\026\n" + "\010disabled\030\010 \001(\010B\004\342A\001\001\0225\n" + "\013create_time\030\t" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" @@ -1509,9 +1526,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016execution_time\030\001" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003B\010\n" + "\006result:\262\001\352A\256\001\n" - + "&dataform.googleapis.com/WorkflowConfig\022cprojects/{project}/locations/{location}/r" - + "epositories/{repository}/workflowConfigs" - + "/{workflow_config}*\017workflowConfigs2\016workflowConfigB\024\n" + + "&dataform.googleapis.com/WorkflowConfig\022cprojects/{pro" + + "ject}/locations/{location}/repositories/{repository}/workflowConfigs/{workflow_c" + + "onfig}*\017workflowConfigs2\016workflowConfigB\024\n" + "\022_internal_metadata\"\341\007\n" + "\020InvocationConfig\022@\n" + "\020included_targets\030\001 \003(\0132" @@ -1522,14 +1539,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "(fully_refresh_incremental_tables_enabled\030\005" + " \001(\010B\004\342A\001\001\022\035\n" + "\017service_account\030\006 \001(\tB\004\342A\001\001\022j\n" - + "\024end_user_auth_config\030\007 \001(\0132F.google.cloud.dataform.v1.InvocationCo" - + "nfig.EndUserAuthenticationConfigB\004\342A\001\001\022[\n" - + "\016query_priority\030\t \001(\01628.google.cloud.da" - + "taform.v1.InvocationConfig.QueryPriorityB\004\342A\001\001H\000\210\001\001\022+\n" + + "\024end_user_auth_config\030\007 \001(\0132F.google.cl" + + "oud.dataform.v1.InvocationConfig.EndUserAuthenticationConfigB\004\342A\001\001\022[\n" + + "\016query_priority\030\t \001(\01628.google.cloud.dataform.v1.In" + + "vocationConfig.QueryPriorityB\004\342A\001\001H\000\210\001\001\022+\n" + "\030concurrent_actions_limit\030\n" + " \001(\005B\004\342A\001\001H\001\210\001\001\022V\n" - + "\016execution_mode\030\020 \001(\016" - + "28.google.cloud.dataform.v1.InvocationConfig.ExecutionModeB\004\342A\001\001\032z\n" + + "\016execution_mode\030\020 \001(\01628.google.cl" + + "oud.dataform.v1.InvocationConfig.ExecutionModeB\004\342A\001\001\032z\n" + "\033EndUserAuthenticationConfig\022\030\n\n" + "user_email\030\002 \001(\tB\004\342A\001\003\022A\n" + "\014oauth_config\030\004" @@ -1561,14 +1578,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\033CreateWorkflowConfigRequest\022;\n" + "\006parent\030\001 \001(\tB+\342A\001\002\372A$\n" + "\"dataform.googleapis.com/Repository\022G\n" - + "\017workflow_config\030\002" - + " \001(\0132(.google.cloud.dataform.v1.WorkflowConfigB\004\342A\001\002\022 \n" + + "\017workflow_config\030\002 \001(\0132(.go" + + "ogle.cloud.dataform.v1.WorkflowConfigB\004\342A\001\002\022 \n" + "\022workflow_config_id\030\003 \001(\tB\004\342A\001\002\"\235\001\n" + "\033UpdateWorkflowConfigRequest\0225\n" + "\013update_mask\030\001" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022G\n" - + "\017workflow_config\030\002 \001(" - + "\0132(.google.cloud.dataform.v1.WorkflowConfigB\004\342A\001\002\"\\\n" + + "\017workflow_config\030\002" + + " \001(\0132(.google.cloud.dataform.v1.WorkflowConfigB\004\342A\001\002\"\\\n" + "\033DeleteWorkflowConfigRequest\022=\n" + "\004name\030\001 \001(\tB/\342A\001\002\372A(\n" + "&dataform.googleapis.com/WorkflowConfig\"\347\010\n" @@ -1578,21 +1595,21 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017workflow_config\030\006 \001(\tB/\342A\001\005\372A(\n" + "&dataform.googleapis.com/WorkflowConfigH\000\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\003\022K\n" - + "\021invocation_config\030\003" - + " \001(\0132*.google.cloud.dataform.v1.InvocationConfigB\004\342A\001\005\022G\n" - + "\005state\030\004 \001(\01622.g" - + "oogle.cloud.dataform.v1.WorkflowInvocation.StateB\004\342A\001\003\0226\n" + + "\021invocation_config\030\003 \001(\0132" + + "*.google.cloud.dataform.v1.InvocationConfigB\004\342A\001\005\022G\n" + + "\005state\030\004 \001(\01622.google.cloud." + + "dataform.v1.WorkflowInvocation.StateB\004\342A\001\003\0226\n" + "\021invocation_timing\030\005" + " \001(\0132\025.google.type.IntervalB\004\342A\001\003\022W\n" + "\033resolved_compilation_result\030\007 \001(\tB2\342A\001\003\372A+\n" + ")dataform.googleapis.com/CompilationResult\022R\n" - + "\025data_encryption_state\030\010 \001(\0132-.google." - + "cloud.dataform.v1.DataEncryptionStateB\004\342A\001\003\022$\n" + + "\025data_encryption_state\030\010" + + " \001(\0132-.google.cloud.dataform.v1.DataEncryptionStateB\004\342A\001\003\022$\n" + "\021internal_metadata\030\t \001(\tB\004\342A\001\003H\001\210\001\001\022Z\n" + "\031private_resource_metadata\030\n" + " \001(\01321.google.cloud.dataform.v1.PrivateResourceMetadataB\004\342A\001\003\022G\n" - + "\017pipeline_config\030\013 \001(\0132(" - + ".google.cloud.dataform.v1.PipelineConfigB\004\342A\001\003\"d\n" + + "\017pipeline_config\030\013" + + " \001(\0132(.google.cloud.dataform.v1.PipelineConfigB\004\342A\001\003\"d\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\013\n" + "\007RUNNING\020\001\022\r\n" @@ -1600,9 +1617,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tCANCELLED\020\003\022\n\n" + "\006FAILED\020\004\022\r\n" + "\tCANCELING\020\005:\306\001\352A\302\001\n" - + "*dataform.googleapis.com/WorkflowInvocation\022" - + "kprojects/{project}/locations/{location}/repositories/{repository}/workflowInvoc" - + "ations/{workflow_invocation}*\023workflowInvocations2\022workflowInvocationB\024\n" + + "*dataform.googleapis.com/WorkflowInvocation\022kprojects/{p" + + "roject}/locations/{location}/repositories/{repository}/workflowInvocations/{work" + + "flow_invocation}*\023workflowInvocations2\022workflowInvocationB\024\n" + "\022compilation_sourceB\024\n" + "\022_internal_metadata\"\276\001\n" + "\036ListWorkflowInvocationsRequest\022;\n" @@ -1613,8 +1630,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010order_by\030\004 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\"\233\001\n" + "\037ListWorkflowInvocationsResponse\022J\n" - + "\024workflow_invocations\030\001" - + " \003(\0132,.google.cloud.dataform.v1.WorkflowInvocation\022\027\n" + + "\024workflow_invocations\030\001 \003(\013" + + "2,.google.cloud.dataform.v1.WorkflowInvocation\022\027\n" + "\017next_page_token\030\002 \001(\t\022\023\n" + "\013unreachable\030\003 \003(\t\"a\n" + "\034GetWorkflowInvocationRequest\022A\n" @@ -1623,8 +1640,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\037CreateWorkflowInvocationRequest\022;\n" + "\006parent\030\001 \001(\tB+\342A\001\002\372A$\n" + "\"dataform.googleapis.com/Repository\022O\n" - + "\023workflow_invocation\030\002" - + " \001(\0132,.google.cloud.dataform.v1.WorkflowInvocationB\004\342A\001\002\"d\n" + + "\023workflow_invocation\030\002 \001(\0132,." + + "google.cloud.dataform.v1.WorkflowInvocationB\004\342A\001\002\"d\n" + "\037DeleteWorkflowInvocationRequest\022A\n" + "\004name\030\001 \001(\tB3\342A\001\002\372A,\n" + "*dataform.googleapis.com/WorkflowInvocation\"d\n" @@ -1633,21 +1650,20 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "*dataform.googleapis.com/WorkflowInvocation\"\"\n" + " CancelWorkflowInvocationResponse\"\310\023\n" + "\030WorkflowInvocationAction\022b\n" - + "\017bigquery_action\030\006 \001(\0132A.go" - + "ogle.cloud.dataform.v1.WorkflowInvocationAction.BigQueryActionB\004\342A\001\003H\000\022b\n" - + "\017notebook_action\030\010 \001(\0132A.google.cloud.dataform." - + "v1.WorkflowInvocationAction.NotebookActionB\004\342A\001\003H\000\022q\n" - + "\027data_preparation_action\030\t \001(\0132H.google.cloud.dataform.v1.WorkflowI" - + "nvocationAction.DataPreparationActionB\004\342A\001\003H\000\022t\n" - + "\031bigquery_unit_test_action\030\014 \001(\013" - + "2I.google.cloud.dataform.v1.WorkflowInvo" - + "cationAction.BigQueryUnitTestActionB\004\342A\001\003H\000\0226\n" + + "\017bigquery_action\030\006 \001(\0132A.google.cloud.d" + + "ataform.v1.WorkflowInvocationAction.BigQueryActionB\004\342A\001\003H\000\022b\n" + + "\017notebook_action\030\010 \001(\0132A.google.cloud.dataform.v1.WorkflowI" + + "nvocationAction.NotebookActionB\004\342A\001\003H\000\022q\n" + + "\027data_preparation_action\030\t \001(\0132H.google" + + ".cloud.dataform.v1.WorkflowInvocationAction.DataPreparationActionB\004\342A\001\003H\000\022t\n" + + "\031bigquery_unit_test_action\030\014 \001(\0132I.google.cl" + + "oud.dataform.v1.WorkflowInvocationAction.BigQueryUnitTestActionB\004\342A\001\003H\000\0226\n" + "\006target\030\001 \001(\0132" + " .google.cloud.dataform.v1.TargetB\004\342A\001\003\022@\n" + "\020canonical_target\030\002 \001(\0132" + " .google.cloud.dataform.v1.TargetB\004\342A\001\003\022M\n" - + "\005state\030\004 \001(\01628.google.cloud.data" - + "form.v1.WorkflowInvocationAction.StateB\004\342A\001\003\022\034\n" + + "\005state\030\004" + + " \001(\01628.google.cloud.dataform.v1.WorkflowInvocationAction.StateB\004\342A\001\003\022\034\n" + "\016failure_reason\030\007 \001(\tB\004\342A\001\003\0226\n" + "\021invocation_timing\030\005" + " \001(\0132\025.google.type.IntervalB\004\342A\001\003\022$\n" @@ -1662,28 +1678,28 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tfile_path\030\003 \001(\tB\004\342A\001\003\032\204\t\n" + "\025DataPreparationAction\022\035\n\r" + "contents_yaml\030\002 \001(\tB\004\342A\001\003H\000\022t\n" - + "\014contents_sql\030\006 \001(\0132\\.google.cloud.dataform.v1.WorkflowIn" - + "vocationAction.DataPreparationAction.ActionSqlDefinitionH\000\022\033\n\r" + + "\014contents_sql\030\006 \001(\0132\\.google.cloud.dataform.v1.WorkflowInvocationActi" + + "on.DataPreparationAction.ActionSqlDefinitionH\000\022\033\n\r" + "generated_sql\030\003 \001(\tB\004\342A\001\003\022\024\n" + "\006job_id\030\004 \001(\tB\004\342A\001\003\032\204\002\n" + "\023ActionSqlDefinition\022\r\n" + "\005query\030\001 \001(\t\022n\n" - + "\013error_table\030\002 \001(\0132Y.google.cloud.dataform.v1.Wor" - + "kflowInvocationAction.DataPreparationAction.ActionErrorTable\022n\n" - + "\013load_config\030\003 \001(\0132Y.google.cloud.dataform.v1.WorkflowInv" - + "ocationAction.DataPreparationAction.ActionLoadConfig\032\\\n" + + "\013error_table\030\002 \001(\0132Y.google.cloud.dataform.v1.WorkflowInvocat" + + "ionAction.DataPreparationAction.ActionErrorTable\022n\n" + + "\013load_config\030\003 \001(\0132Y.google.cloud.dataform.v1.WorkflowInvocationActio" + + "n.DataPreparationAction.ActionLoadConfig\032\\\n" + "\020ActionErrorTable\0220\n" + "\006target\030\001 \001(\0132 .google.cloud.dataform.v1.Target\022\026\n" + "\016retention_days\030\002 \001(\005\032\352\003\n" + "\020ActionLoadConfig\022p\n" - + "\007replace\030\001 \001(\0132].google.cloud.dataform.v1.WorkflowInvocationAction.Dat" - + "aPreparationAction.ActionSimpleLoadModeH\000\022o\n" - + "\006append\030\002 \001(\0132].google.cloud.datafor" - + "m.v1.WorkflowInvocationAction.DataPreparationAction.ActionSimpleLoadModeH\000\022u\n" - + "\007maximum\030\003 \001(\0132b.google.cloud.dataform.v1.W" - + "orkflowInvocationAction.DataPreparationAction.ActionIncrementalLoadModeH\000\022t\n" - + "\006unique\030\004 \001(\0132b.google.cloud.dataform.v1.Wor" - + "kflowInvocationAction.DataPreparationAction.ActionIncrementalLoadModeH\000B\006\n" + + "\007replace\030\001 \001(\0132].google.cloud.dataform.v1." + + "WorkflowInvocationAction.DataPreparationAction.ActionSimpleLoadModeH\000\022o\n" + + "\006append\030\002 \001(\0132].google.cloud.dataform.v1.Workflo" + + "wInvocationAction.DataPreparationAction.ActionSimpleLoadModeH\000\022u\n" + + "\007maximum\030\003 \001(\0132b.google.cloud.dataform.v1.WorkflowInvoc" + + "ationAction.DataPreparationAction.ActionIncrementalLoadModeH\000\022t\n" + + "\006unique\030\004 \001(\0132b.google.cloud.dataform.v1.WorkflowInvocat" + + "ionAction.DataPreparationAction.ActionIncrementalLoadModeH\000B\006\n" + "\004mode\032\026\n" + "\024ActionSimpleLoadMode\032+\n" + "\031ActionIncrementalLoadMode\022\016\n" @@ -1713,16 +1729,16 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"\232\001\n" + "&QueryWorkflowInvocationActionsResponse\022W\n" - + "\033workflow_invocation_actions\030\001" - + " \003(\01322.google.cloud.dataform.v1.WorkflowInvocationAction\022\027\n" + + "\033workflow_invocation_actions\030\001 \003(\01322.g" + + "oogle.cloud.dataform.v1.WorkflowInvocationAction\022\027\n" + "\017next_page_token\030\002 \001(\t\"\210\002\n" + "\006Config\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022H\n" + "\024default_kms_key_name\030\002 \001(\tB*\342A\001\001\372A#\n" + "!cloudkms.googleapis.com/CryptoKey\022$\n" + "\021internal_metadata\030\007 \001(\tB\004\342A\001\003H\000\210\001\001:d\352Aa\n" - + "\036dataform.googleapis.com/Config\022.projects/{pro" - + "ject}/locations/{location}/config*\007configs2\006configB\024\n" + + "\036dataform.googleapis.com/Config\022.projects/{project}/locati" + + "ons/{location}/config*\007configs2\006configB\024\n" + "\022_internal_metadata\"I\n" + "\020GetConfigRequest\0225\n" + "\004name\030\001 \001(\tB\'\342A\001\002\372A \n" @@ -1743,8 +1759,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022$\n" + "\021internal_metadata\030\007 \001(\tB\004\342A\001\003H\000\210\001\001\022(\n" + "\025creator_iam_principal\030\010 \001(\tB\004\342A\001\003H\001\210\001\001:n\352Ak\n" - + "\036dataform.googleapis.com/Folder\0228proje" - + "cts/{project}/locations/{location}/folders/{folder}*\007folders2\006folderB\024\n" + + "\036dataform.googleapis.com/Folder\0228projects/{project" + + "}/locations/{location}/folders/{folder}*\007folders2\006folderB\024\n" + "\022_internal_metadataB\030\n" + "\026_creator_iam_principal\"\211\001\n" + "\023CreateFolderRequest\022:\n" @@ -1782,8 +1798,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010end_time\030\002" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022\024\n" + "\006target\030\003 \001(\tB\004\342A\001\003\022M\n" - + "\005state\030\004" - + " \001(\01628.google.cloud.dataform.v1.DeleteFolderTreeMetadata.StateB\004\342A\001\003\022\036\n" + + "\005state\030\004 \001(\016" + + "28.google.cloud.dataform.v1.DeleteFolderTreeMetadata.StateB\004\342A\001\003\022\036\n" + "\020percent_complete\030\005 \001(\005B\004\342A\001\003\"[\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\017\n" @@ -1799,11 +1815,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010order_by\030\004 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\"\243\002\n" + "\033QueryFolderContentsResponse\022Z\n" - + "\007entries\030\001 \003(\0132I.go" - + "ogle.cloud.dataform.v1.QueryFolderContentsResponse.FolderContentsEntry\022\027\n" + + "\007entries\030\001 \003(\0132I.google.cloud.d" + + "ataform.v1.QueryFolderContentsResponse.FolderContentsEntry\022\027\n" + "\017next_page_token\030\002 \001(\t\032\216\001\n" + "\023FolderContentsEntry\0222\n" - + "\006folder\030\001 \001(\0132 .google.cloud.dataform.v1.FolderH\000\022:\n\n" + + "\006folder\030\001 ", + "\001(\0132 .google.cloud.dataform.v1.FolderH\000\022:\n\n" + "repository\030\002 \001(\0132$.google.cloud.dataform.v1.RepositoryH\000B\007\n" + "\005entry\"\275\001\n" + "\034QueryUserRootContentsRequest\022<\n" @@ -1814,9 +1831,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010order_by\030\004 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\"\243\002\n" + "\035QueryUserRootContentsResponse\022Z\n" - + "\007entries\030\001 ", - "\003(\0132I.google.cloud.dataform.v1.QueryUser" - + "RootContentsResponse.RootContentsEntry\022\027\n" + + "\007entries\030\001 \003(\0132I.google" + + ".cloud.dataform.v1.QueryUserRootContentsResponse.RootContentsEntry\022\027\n" + "\017next_page_token\030\002 \001(\t\032\214\001\n" + "\021RootContentsEntry\0222\n" + "\006folder\030\001 \001(\0132 .google.cloud.dataform.v1.FolderH\000\022:\n\n" @@ -1832,8 +1848,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\021internal_metadata\030\005 \001(\tB\004\342A\001\003H\000\210\001\001\022(\n" + "\025creator_iam_principal\030\006 \001(" + "\tB\004\342A\001\003H\001\210\001\001:\204\001\352A\200\001\n" - + "\"dataform.googleapis.com/TeamFolder\022Aprojects/{projec" - + "t}/locations/{location}/teamFolders/{team_folder}*\013teamFolders2\n" + + "\"dataform.googleapis.com/TeamFolder\022Aprojects/{project}/locations" + + "/{location}/teamFolders/{team_folder}*\013teamFolders2\n" + "teamFolderB\024\n" + "\022_internal_metadataB\030\n" + "\026_creator_iam_principal\"\226\001\n" @@ -1861,8 +1877,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010order_by\030\004 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\"\263\002\n" + "\037QueryTeamFolderContentsResponse\022b\n" - + "\007entries\030\001 \003(\0132Q.google.cloud.dataform.v1.QueryTeam" - + "FolderContentsResponse.TeamFolderContentsEntry\022\027\n" + + "\007entries\030\001 \003(\0132Q.google" + + ".cloud.dataform.v1.QueryTeamFolderContentsResponse.TeamFolderContentsEntry\022\027\n" + "\017next_page_token\030\002 \001(\t\032\222\001\n" + "\027TeamFolderContentsEntry\0222\n" + "\006folder\030\001 \001(\0132 .google.cloud.dataform.v1.FolderH\000\022:\n\n" @@ -1876,8 +1892,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010order_by\030\004 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\"\361\001\n" + "\031SearchTeamFoldersResponse\022[\n" - + "\007results\030\001 \003(\0132J.google.cloud.dataform." - + "v1.SearchTeamFoldersResponse.TeamFolderSearchResult\022\027\n" + + "\007results\030\001 \003(\0132J.google.cloud.dataform.v1.SearchTea" + + "mFoldersResponse.TeamFolderSearchResult\022\027\n" + "\017next_page_token\030\002 \001(\t\032^\n" + "\026TeamFolderSearchResult\022;\n" + "\013team_folder\030\002 \001(\0132$.google.cloud.dataform.v1.TeamFolderH\000B\007\n" @@ -1903,8 +1919,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010end_time\030\002" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022\024\n" + "\006target\030\003 \001(\tB\004\342A\001\003\022E\n" - + "\005state\030\004 \001(\0162" - + "6.google.cloud.dataform.v1.MoveRepositoryMetadata.State\022\030\n" + + "\005state\030\004 \001(\01626.google.clo" + + "ud.dataform.v1.MoveRepositoryMetadata.State\022\030\n" + "\020percent_complete\030\005 \001(\005\"Y\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\017\n" @@ -1915,375 +1931,388 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\025DirectoryContentsView\022\'\n" + "#DIRECTORY_CONTENTS_VIEW_UNSPECIFIED\020\000\022!\n" + "\035DIRECTORY_CONTENTS_VIEW_BASIC\020\001\022$\n" - + " DIRECTORY_CONTENTS_VIEW_METADATA\020\0022\254\200\001\n" + + " DIRECTORY_CONTENTS_VIEW_METADATA\020\0022\310\202\001\n" + "\010Dataform\022\245\001\n\r" - + "GetTeamFolder\022..google.cloud.dataform.v1.GetTeamFolderRequest\032$.googl" - + "e.cloud.dataform.v1.TeamFolder\">\332A\004name\202" - + "\323\344\223\0021\022//v1/{name=projects/*/locations/*/teamFolders/*}\022\306\001\n" - + "\020CreateTeamFolder\0221.google.cloud.dataform.v1.CreateTeamFolderR" - + "equest\032$.google.cloud.dataform.v1.TeamFo" - + "lder\"Y\332A\022parent,team_folder\202\323\344\223\002>\"//v1/{" - + "parent=projects/*/locations/*}/teamFolders:\013team_folder\022\327\001\n" - + "\020UpdateTeamFolder\0221.google.cloud.dataform.v1.UpdateTeamFolder" - + "Request\032$.google.cloud.dataform.v1.TeamF" - + "older\"j\332A\027team_folder,update_mask\202\323\344\223\002J2" - + ";/v1/{team_folder.name=projects/*/locations/*/teamFolders/*}:\013team_folder\022\235\001\n" - + "\020DeleteTeamFolder\0221.google.cloud.dataform.v" - + "1.DeleteTeamFolderRequest\032\026.google.proto" - + "buf.Empty\">\332A\004name\202\323\344\223\0021*//v1/{name=projects/*/locations/*/teamFolders/*}\022\365\001\n" - + "\024DeleteTeamFolderTree\0225.google.cloud.datafo" - + "rm.v1.DeleteTeamFolderTreeRequest\032\035.google.longrunning.Operation\"\206\001\312A1\n" + + "GetTeamFolder\022..google.cloud.dataform.v1." + + "GetTeamFolderRequest\032$.google.cloud.data" + + "form.v1.TeamFolder\">\332A\004name\202\323\344\223\0021\022//v1/{" + + "name=projects/*/locations/*/teamFolders/*}\022\306\001\n" + + "\020CreateTeamFolder\0221.google.cloud.dataform.v1.CreateTeamFolderRequest\032$.goo" + + "gle.cloud.dataform.v1.TeamFolder\"Y\332A\022par" + + "ent,team_folder\202\323\344\223\002>\"//v1/{parent=proje" + + "cts/*/locations/*}/teamFolders:\013team_folder\022\327\001\n" + + "\020UpdateTeamFolder\0221.google.cloud.dataform.v1.UpdateTeamFolderRequest\032$.go" + + "ogle.cloud.dataform.v1.TeamFolder\"j\332A\027te" + + "am_folder,update_mask\202\323\344\223\002J2;/v1/{team_f" + + "older.name=projects/*/locations/*/teamFolders/*}:\013team_folder\022\235\001\n" + + "\020DeleteTeamFolder\0221.google.cloud.dataform.v1.DeleteTeam" + + "FolderRequest\032\026.google.protobuf.Empty\">\332" + + "A\004name\202\323\344\223\0021*//v1/{name=projects/*/locations/*/teamFolders/*}\022\365\001\n" + + "\024DeleteTeamFolderTree\0225.google.cloud.dataform.v1.Delete" + + "TeamFolderTreeRequest\032\035.google.longrunning.Operation\"\206\001\312A1\n" + "\025google.protobuf.Empty\022\030DeleteFolderTreeMetadata\332A\n" - + "name,force\202\323\344\223\002?\":/v1/{name=projects/*" - + "/locations/*/teamFolders/*}:deleteTree:\001*\022\352\001\n" - + "\027QueryTeamFolderContents\0228.google.cloud.dataform.v1.QueryTeamFolderContents" - + "Request\0329.google.cloud.dataform.v1.Query" - + "TeamFolderContentsResponse\"Z\332A\013team_fold" - + "er\202\323\344\223\002F\022D/v1/{team_folder=projects/*/lo" - + "cations/*/teamFolders/*}:queryContents\022\276\001\n" - + "\021SearchTeamFolders\0222.google.cloud.data" - + "form.v1.SearchTeamFoldersRequest\0323.google.cloud.dataform.v1.SearchTeamFoldersRes" - + "ponse\"@\202\323\344\223\002:\0228/v1/{location=projects/*/locations/*}/teamFolders:search\022\225\001\n" - + "\tGetFolder\022*.google.cloud.dataform.v1.GetFolderRequest\032" - + " .google.cloud.dataform.v1.Fol" - + "der\":\332A\004name\202\323\344\223\002-\022+/v1/{name=projects/*/locations/*/folders/*}\022\254\001\n" + + "name,force" + + "\202\323\344\223\002?\":/v1/{name=projects/*/locations/*/teamFolders/*}:deleteTree:\001*\022\352\001\n" + + "\027QueryTeamFolderContents\0228.google.cloud.datafor" + + "m.v1.QueryTeamFolderContentsRequest\0329.google.cloud.dataform.v1.QueryTeamFolderCo" + + "ntentsResponse\"Z\332A\013team_folder\202\323\344\223\002F\022D/v" + + "1/{team_folder=projects/*/locations/*/teamFolders/*}:queryContents\022\276\001\n" + + "\021SearchTeamFolders\0222.google.cloud.dataform.v1.Sear" + + "chTeamFoldersRequest\0323.google.cloud.data" + + "form.v1.SearchTeamFoldersResponse\"@\202\323\344\223\002" + + ":\0228/v1/{location=projects/*/locations/*}/teamFolders:search\022\225\001\n" + + "\tGetFolder\022*.google.cloud.dataform.v1.GetFolderRequest\032 ." + + "google.cloud.dataform.v1.Folder\":\332A\004name" + + "\202\323\344\223\002-\022+/v1/{name=projects/*/locations/*/folders/*}\022\254\001\n" + "\014CreateFolder\022-.google.cloud.dataform.v1.CreateFolderRequest\032" + " .google.cloud.dataform.v1.Folder\"K\332A\r" - + "parent,folder\202\323\344\223\0025\"+/v1/{parent=p" - + "rojects/*/locations/*}/folders:\006folder\022\270\001\n" + + "parent" + + ",folder\202\323\344\223\0025\"+/v1/{parent=projects/*/locations/*}/folders:\006folder\022\270\001\n" + "\014UpdateFolder\022-.google.cloud.dataform.v1.UpdateFolderRequest\032" - + " .google.cloud.dataform.v1.Folder\"W\332A\022folder,update_mask\202" - + "\323\344\223\002<22/v1/{folder.name=projects/*/locations/*/folders/*}:\006folder\022\221\001\n" - + "\014DeleteFolder\022-.google.cloud.dataform.v1.DeleteFold" - + "erRequest\032\026.google.protobuf.Empty\":\332A\004na" - + "me\202\323\344\223\002-*+/v1/{name=projects/*/locations/*/folders/*}\022\351\001\n" - + "\020DeleteFolderTree\0221.google.cloud.dataform.v1.DeleteFolderTreeRe" - + "quest\032\035.google.longrunning.Operation\"\202\001\312A1\n" + + " .google.cloud.dataform.v1.Fo" + + "lder\"W\332A\022folder,update_mask\202\323\344\223\002<22/v1/{" + + "folder.name=projects/*/locations/*/folders/*}:\006folder\022\221\001\n" + + "\014DeleteFolder\022-.google.cloud.dataform.v1.DeleteFolderRequest\032\026." + + "google.protobuf.Empty\":\332A\004name\202\323\344\223\002-*+/v" + + "1/{name=projects/*/locations/*/folders/*}\022\351\001\n" + + "\020DeleteFolderTree\0221.google.cloud.da" + + "taform.v1.DeleteFolderTreeRequest\032\035.google.longrunning.Operation\"\202\001\312A1\n" + "\025google.protobuf.Empty\022\030DeleteFolderTreeMetadata\332A\n" - + "name,force\202\323\344\223\002;\"6/v1/{nam" - + "e=projects/*/locations/*/folders/*}:deleteTree:\001*\022\326\001\n" - + "\023QueryFolderContents\0224.google.cloud.dataform.v1.QueryFolderContents" - + "Request\0325.google.cloud.dataform.v1.Query" - + "FolderContentsResponse\"R\332A\006folder\202\323\344\223\002C\022" - + "A/v1/{folder=projects/*/locations/*/folders/*}:queryFolderContents\022\330\001\n" - + "\025QueryUserRootContents\0226.google.cloud.dataform.v1." - + "QueryUserRootContentsRequest\0327.google.cloud.dataform.v1.QueryUserRootContentsRes" - + "ponse\"N\332A\010location\202\323\344\223\002=\022;/v1/{location=" - + "projects/*/locations/*}:queryUserRootContents\022\351\001\n\n" - + "MoveFolder\022+.google.cloud.data" - + "form.v1.MoveFolderRequest\032\035.google.longrunning.Operation\"\216\001\312A+\n" - + "\025google.protobuf.Empty\022\022MoveFolderMetadata\332A\"name,destina" - + "tion_containing_folder\202\323\344\223\0025\"0/v1/{name=" - + "projects/*/locations/*/folders/*}:move:\001*\022\274\001\n" - + "\020ListRepositories\0221.google.cloud.dataform.v1.ListRepositoriesRequest\0322.goog" - + "le.cloud.dataform.v1.ListRepositoriesRes" - + "ponse\"A\332A\006parent\202\323\344\223\0022\0220/v1/{parent=projects/*/locations/*}/repositories\022\246\001\n\r" - + "GetRepository\022..google.cloud.dataform.v1.Ge" - + "tRepositoryRequest\032$.google.cloud.datafo" - + "rm.v1.Repository\"?\332A\004name\202\323\344\223\0022\0220/v1/{na" - + "me=projects/*/locations/*/repositories/*}\022\323\001\n" - + "\020CreateRepository\0221.google.cloud.dataform.v1.CreateRepositoryRequest\032$.goog" - + "le.cloud.dataform.v1.Repository\"f\332A\037pare" - + "nt,repository,repository_id\202\323\344\223\002>\"0/v1/{" - + "parent=projects/*/locations/*}/repositories:\n" + + "name,force\202\323\344\223\002;\"6/v1/{name=projects/*" + + "/locations/*/folders/*}:deleteTree:\001*\022\326\001\n" + + "\023QueryFolderContents\0224.google.cloud.dat" + + "aform.v1.QueryFolderContentsRequest\0325.google.cloud.dataform.v1.QueryFolderConten" + + "tsResponse\"R\332A\006folder\202\323\344\223\002C\022A/v1/{folder" + + "=projects/*/locations/*/folders/*}:queryFolderContents\022\330\001\n" + + "\025QueryUserRootContents\0226.google.cloud.dataform.v1.QueryUserRoo" + + "tContentsRequest\0327.google.cloud.dataform" + + ".v1.QueryUserRootContentsResponse\"N\332A\010lo" + + "cation\202\323\344\223\002=\022;/v1/{location=projects/*/locations/*}:queryUserRootContents\022\351\001\n\n" + + "MoveFolder\022+.google.cloud.dataform.v1.Move" + + "FolderRequest\032\035.google.longrunning.Operation\"\216\001\312A+\n" + + "\025google.protobuf.Empty\022\022MoveFolderMetadata\332A\"name,destination_contain" + + "ing_folder\202\323\344\223\0025\"0/v1/{name=projects/*/locations/*/folders/*}:move:\001*\022\274\001\n" + + "\020ListRepositories\0221.google.cloud.dataform.v1.Li" + + "stRepositoriesRequest\0322.google.cloud.dat" + + "aform.v1.ListRepositoriesResponse\"A\332A\006pa" + + "rent\202\323\344\223\0022\0220/v1/{parent=projects/*/locations/*}/repositories\022\246\001\n\r" + + "GetRepository\022..google.cloud.dataform.v1.GetRepositoryR" + + "equest\032$.google.cloud.dataform.v1.Reposi" + + "tory\"?\332A\004name\202\323\344\223\0022\0220/v1/{name=projects/*/locations/*/repositories/*}\022\323\001\n" + + "\020CreateRepository\0221.google.cloud.dataform.v1.Cr" + + "eateRepositoryRequest\032$.google.cloud.dat" + + "aform.v1.Repository\"f\332A\037parent,repositor" + + "y,repository_id\202\323\344\223\002>\"0/v1/{parent=projects/*/locations/*}/repositories:\n" + "repository\022\325\001\n" - + "\020UpdateRepository\0221.google.cloud.dataform.v1.UpdateRepository" - + "Request\032$.google.cloud.dataform.v1.Repos" - + "itory\"h\332A\026repository,update_mask\202\323\344\223\002I2;" - + "/v1/{repository.name=projects/*/locations/*/repositories/*}:\n" + + "\020UpdateRepository\0221.google.cloud.dataform.v1.UpdateRepositoryRequest\032$.go" + + "ogle.cloud.dataform.v1.Repository\"h\332A\026re" + + "pository,update_mask\202\323\344\223\002I2;/v1/{reposit" + + "ory.name=projects/*/locations/*/repositories/*}:\n" + "repository\022\236\001\n" - + "\020DeleteRepository\0221.google.cloud.dataform.v1." - + "DeleteRepositoryRequest\032\026.google.protobu" - + "f.Empty\"?\332A\004name\202\323\344\223\0022*0/v1/{name=projects/*/locations/*/repositories/*}\022\372\001\n" - + "\016MoveRepository\022/.google.cloud.dataform.v1.M" - + "oveRepositoryRequest\032\035.google.longrunning.Operation\"\227\001\312A/\n" - + "\025google.protobuf.Empty\022\026MoveRepositoryMetadata\332A\"name,destinat" - + "ion_containing_folder\202\323\344\223\002:\"5/v1/{name=p" - + "rojects/*/locations/*/repositories/*}:move:\001*\022\322\001\n" - + "\027CommitRepositoryChanges\0228.google.cloud.dataform.v1.CommitRepositoryCha" - + "ngesRequest\0329.google.cloud.dataform.v1.C" - + "ommitRepositoryChangesResponse\"B\202\323\344\223\002<\"7" - + "/v1/{name=projects/*/locations/*/repositories/*}:commit:\001*\022\302\001\n" - + "\022ReadRepositoryFile\0223.google.cloud.dataform.v1.ReadReposit" - + "oryFileRequest\0324.google.cloud.dataform.v" - + "1.ReadRepositoryFileResponse\"A\202\323\344\223\002;\0229/v" - + "1/{name=projects/*/locations/*/repositories/*}:readFile\022\372\001\n" - + " QueryRepositoryDirectoryContents\022A.google.cloud.dataform.v1." - + "QueryRepositoryDirectoryContentsRequest\032B.google.cloud.dataform.v1.QueryReposito" - + "ryDirectoryContentsResponse\"O\202\323\344\223\002I\022G/v1" - + "/{name=projects/*/locations/*/repositories/*}:queryDirectoryContents\022\322\001\n" - + "\026FetchRepositoryHistory\0227.google.cloud.dataform." - + "v1.FetchRepositoryHistoryRequest\0328.google.cloud.dataform.v1.FetchRepositoryHisto" - + "ryResponse\"E\202\323\344\223\002?\022=/v1/{name=projects/*" - + "/locations/*/repositories/*}:fetchHistory\022\202\002\n" - + "\"ComputeRepositoryAccessTokenStatus\022C.google.cloud.dataform.v1.ComputeRepos" - + "itoryAccessTokenStatusRequest\032D.google.cloud.dataform.v1.ComputeRepositoryAccess" - + "TokenStatusResponse\"Q\202\323\344\223\002K\022I/v1/{name=p" - + "rojects/*/locations/*/repositories/*}:computeAccessTokenStatus\022\320\001\n" - + "\023FetchRemoteBranches\0224.google.cloud.dataform.v1.FetchR" - + "emoteBranchesRequest\0325.google.cloud.data" - + "form.v1.FetchRemoteBranchesResponse\"L\202\323\344" - + "\223\002F\022D/v1/{name=projects/*/locations/*/repositories/*}:fetchRemoteBranches\022\303\001\n" - + "\016ListWorkspaces\022/.google.cloud.dataform.v1." - + "ListWorkspacesRequest\0320.google.cloud.dat" - + "aform.v1.ListWorkspacesResponse\"N\332A\006pare" - + "nt\202\323\344\223\002?\022=/v1/{parent=projects/*/locations/*/repositories/*}/workspaces\022\260\001\n" - + "\014GetWorkspace\022-.google.cloud.dataform.v1.GetW" - + "orkspaceRequest\032#.google.cloud.dataform." - + "v1.Workspace\"L\332A\004name\202\323\344\223\002?\022=/v1/{name=p" - + "rojects/*/locations/*/repositories/*/workspaces/*}\022\332\001\n" - + "\017CreateWorkspace\0220.google.cloud.dataform.v1.CreateWorkspaceRequest" - + "\032#.google.cloud.dataform.v1.Workspace\"p\332" - + "A\035parent,workspace,workspace_id\202\323\344\223\002J\"=/" - + "v1/{parent=projects/*/locations/*/repositories/*}/workspaces:\tworkspace\022\251\001\n" - + "\017DeleteWorkspace\0220.google.cloud.dataform.v1.D" - + "eleteWorkspaceRequest\032\026.google.protobuf." - + "Empty\"L\332A\004name\202\323\344\223\002?*=/v1/{name=projects" - + "/*/locations/*/repositories/*/workspaces/*}\022\341\001\n" - + "\022InstallNpmPackages\0223.google.cloud.dataform.v1.InstallNpmPackagesRequest\032" - + "4.google.cloud.dataform.v1.InstallNpmPac" - + "kagesResponse\"`\202\323\344\223\002Z\"U/v1/{workspace=pr" - + "ojects/*/locations/*/repositories/*/workspaces/*}:installNpmPackages:\001*\022\302\001\n" - + "\016PullGitCommits\022/.google.cloud.dataform.v1.Pu" - + "llGitCommitsRequest\0320.google.cloud.dataf" - + "orm.v1.PullGitCommitsResponse\"M\202\323\344\223\002G\"B/" - + "v1/{name=projects/*/locations/*/repositories/*/workspaces/*}:pull:\001*\022\302\001\n" - + "\016PushGitCommits\022/.google.cloud.dataform.v1.PushG" - + "itCommitsRequest\0320.google.cloud.dataform" - + ".v1.PushGitCommitsResponse\"M\202\323\344\223\002G\"B/v1/" - + "{name=projects/*/locations/*/repositories/*/workspaces/*}:push:\001*\022\341\001\n" - + "\024FetchFileGitStatuses\0225.google.cloud.dataform.v1.Fe" - + "tchFileGitStatusesRequest\0326.google.cloud.dataform.v1.FetchFileGitStatusesRespons" - + "e\"Z\202\323\344\223\002T\022R/v1/{name=projects/*/location" - + "s/*/repositories/*/workspaces/*}:fetchFileGitStatuses\022\335\001\n" - + "\023FetchGitAheadBehind\0224.google.cloud.dataform.v1.FetchGitAheadBe" - + "hindRequest\0325.google.cloud.dataform.v1.F" - + "etchGitAheadBehindResponse\"Y\202\323\344\223\002S\022Q/v1/" - + "{name=projects/*/locations/*/repositorie" - + "s/*/workspaces/*}:fetchGitAheadBehind\022\334\001\n" - + "\026CommitWorkspaceChanges\0227.google.cloud.dataform.v1.CommitWorkspaceChangesReques" - + "t\0328.google.cloud.dataform.v1.CommitWorks" - + "paceChangesResponse\"O\202\323\344\223\002I\"D/v1/{name=p" - + "rojects/*/locations/*/repositories/*/workspaces/*}:commit:\001*\022\330\001\n" - + "\025ResetWorkspaceChanges\0226.google.cloud.dataform.v1.ResetW" - + "orkspaceChangesRequest\0327.google.cloud.dataform.v1.ResetWorkspaceChangesResponse\"" - + "N\202\323\344\223\002H\"C/v1/{name=projects/*/locations/" - + "*/repositories/*/workspaces/*}:reset:\001*\022\312\001\n\r" - + "FetchFileDiff\022..google.cloud.dataform.v1.FetchFileDiffRequest\032/.google.cloud" - + ".dataform.v1.FetchFileDiffResponse\"X\202\323\344\223" - + "\002R\022P/v1/{workspace=projects/*/locations/" - + "*/repositories/*/workspaces/*}:fetchFileDiff\022\356\001\n" - + "\026QueryDirectoryContents\0227.google.cloud.dataform.v1.QueryDirectoryContent" - + "sRequest\0328.google.cloud.dataform.v1.Quer" - + "yDirectoryContentsResponse\"a\202\323\344\223\002[\022Y/v1/" - + "{workspace=projects/*/locations/*/reposi" - + "tories/*/workspaces/*}:queryDirectoryContents\022\302\001\n" - + "\013SearchFiles\022,.google.cloud.dataform.v1.SearchFilesRequest\032-.google.clo" - + "ud.dataform.v1.SearchFilesResponse\"V\202\323\344\223" - + "\002P\022N/v1/{workspace=projects/*/locations/" - + "*/repositories/*/workspaces/*}:searchFiles\022\315\001\n\r" - + "MakeDirectory\022..google.cloud.dataform.v1.MakeDirectoryRequest\032/.google.cl" - + "oud.dataform.v1.MakeDirectoryResponse\"[\202" - + "\323\344\223\002U\"P/v1/{workspace=projects/*/locatio" - + "ns/*/repositories/*/workspaces/*}:makeDirectory:\001*\022\325\001\n" - + "\017RemoveDirectory\0220.google.cloud.dataform.v1.RemoveDirectoryRequest" - + "\0321.google.cloud.dataform.v1.RemoveDirect" - + "oryResponse\"]\202\323\344\223\002W\"R/v1/{workspace=proj" - + "ects/*/locations/*/repositories/*/workspaces/*}:removeDirectory:\001*\022\315\001\n\r" - + "MoveDirectory\022..google.cloud.dataform.v1.MoveDire" - + "ctoryRequest\032/.google.cloud.dataform.v1." - + "MoveDirectoryResponse\"[\202\323\344\223\002U\"P/v1/{work" - + "space=projects/*/locations/*/repositories/*/workspaces/*}:moveDirectory:\001*\022\266\001\n" - + "\010ReadFile\022).google.cloud.dataform.v1.ReadF" - + "ileRequest\032*.google.cloud.dataform.v1.Re" - + "adFileResponse\"S\202\323\344\223\002M\022K/v1/{workspace=p" - + "rojects/*/locations/*/repositories/*/workspaces/*}:readFile\022\301\001\n\n" - + "RemoveFile\022+.google.cloud.dataform.v1.RemoveFileRequest\032" - + ",.google.cloud.dataform.v1.RemoveFileRes" - + "ponse\"X\202\323\344\223\002R\"M/v1/{workspace=projects/*" - + "/locations/*/repositories/*/workspaces/*}:removeFile:\001*\022\271\001\n" - + "\010MoveFile\022).google.cloud.dataform.v1.MoveFileRequest\032*.google" - + ".cloud.dataform.v1.MoveFileResponse\"V\202\323\344" - + "\223\002P\"K/v1/{workspace=projects/*/locations" - + "/*/repositories/*/workspaces/*}:moveFile:\001*\022\275\001\n" - + "\tWriteFile\022*.google.cloud.dataform.v1.WriteFileRequest\032+.google.cloud.dat" - + "aform.v1.WriteFileResponse\"W\202\323\344\223\002Q\"L/v1/" - + "{workspace=projects/*/locations/*/repositories/*/workspaces/*}:writeFile:\001*\022\323\001\n" - + "\022ListReleaseConfigs\0223.google.cloud.datafo" - + "rm.v1.ListReleaseConfigsRequest\0324.google.cloud.dataform.v1.ListReleaseConfigsRes" - + "ponse\"R\332A\006parent\202\323\344\223\002C\022A/v1/{parent=proj" - + "ects/*/locations/*/repositories/*}/releaseConfigs\022\300\001\n" - + "\020GetReleaseConfig\0221.google.cloud.dataform.v1.GetReleaseConfigReques" - + "t\032\'.google.cloud.dataform.v1.ReleaseConf" - + "ig\"P\332A\004name\202\323\344\223\002C\022A/v1/{name=projects/*/" - + "locations/*/repositories/*/releaseConfigs/*}\022\372\001\n" - + "\023CreateReleaseConfig\0224.google.cloud.dataform.v1.CreateReleaseConfigReque" - + "st\032\'.google.cloud.dataform.v1.ReleaseCon" - + "fig\"\203\001\332A\'parent,release_config,release_c" - + "onfig_id\202\323\344\223\002S\"A/v1/{parent=projects/*/l" - + "ocations/*/repositories/*}/releaseConfigs:\016release_config\022\374\001\n" - + "\023UpdateReleaseConfig\0224.google.cloud.dataform.v1.UpdateRelea" - + "seConfigRequest\032\'.google.cloud.dataform." - + "v1.ReleaseConfig\"\205\001\332A\032release_config,upd" - + "ate_mask\202\323\344\223\002b2P/v1/{release_config.name" - + "=projects/*/locations/*/repositories/*/releaseConfigs/*}:\016release_config\022\265\001\n" - + "\023DeleteReleaseConfig\0224.google.cloud.dataform" - + ".v1.DeleteReleaseConfigRequest\032\026.google." - + "protobuf.Empty\"P\332A\004name\202\323\344\223\002C*A/v1/{name" - + "=projects/*/locations/*/repositories/*/releaseConfigs/*}\022\343\001\n" - + "\026ListCompilationResults\0227.google.cloud.dataform.v1.ListCompi" - + "lationResultsRequest\0328.google.cloud.dataform.v1.ListCompilationResultsResponse\"V" - + "\332A\006parent\202\323\344\223\002G\022E/v1/{parent=projects/*/" - + "locations/*/repositories/*}/compilationResults\022\320\001\n" - + "\024GetCompilationResult\0225.google.cloud.dataform.v1.GetCompilationResultR" - + "equest\032+.google.cloud.dataform.v1.Compil" - + "ationResult\"T\332A\004name\202\323\344\223\002G\022E/v1/{name=pr" - + "ojects/*/locations/*/repositories/*/compilationResults/*}\022\377\001\n" - + "\027CreateCompilationResult\0228.google.cloud.dataform.v1.CreateC" - + "ompilationResultRequest\032+.google.cloud.d" - + "ataform.v1.CompilationResult\"}\332A\031parent," - + "compilation_result\202\323\344\223\002[\"E/v1/{parent=pr" - + "ojects/*/locations/*/repositories/*}/compilationResults:\022compilation_result\022\306\002\n" - + "\"CreateCompilationResultLongRunning\0228.google.cloud.dataform.v1.CreateCompilationR" - + "esultRequest\032\035.google.longrunning.Operation\"\306\001\312A4\n" - + "\021CompilationResult\022\037CreateCompilationResultMetadata\332A\031parent,compilati" - + "on_result\202\323\344\223\002m\"W/v1/{parent=projects/*/" - + "locations/*/repositories/*}/compilationR" - + "esults:createLongRunning:\022compilation_result\022\365\001\n" - + "\035QueryCompilationResultActions\022>.google.cloud.dataform.v1.QueryCompilati" - + "onResultActionsRequest\032?.google.cloud.dataform.v1.QueryCompilationResultActionsR" - + "esponse\"S\202\323\344\223\002M\022K/v1/{name=projects/*/lo" - + "cations/*/repositories/*/compilationResults/*}:query\022\327\001\n" - + "\023ListWorkflowConfigs\0224.google.cloud.dataform.v1.ListWorkflowConf" - + "igsRequest\0325.google.cloud.dataform.v1.Li" - + "stWorkflowConfigsResponse\"S\332A\006parent\202\323\344\223" - + "\002D\022B/v1/{parent=projects/*/locations/*/repositories/*}/workflowConfigs\022\304\001\n" - + "\021GetWorkflowConfig\0222.google.cloud.dataform.v1." - + "GetWorkflowConfigRequest\032(.google.cloud." - + "dataform.v1.WorkflowConfig\"Q\332A\004name\202\323\344\223\002" - + "D\022B/v1/{name=projects/*/locations/*/repositories/*/workflowConfigs/*}\022\201\002\n" - + "\024CreateWorkflowConfig\0225.google.cloud.dataform.v" - + "1.CreateWorkflowConfigRequest\032(.google.c" - + "loud.dataform.v1.WorkflowConfig\"\207\001\332A)par" - + "ent,workflow_config,workflow_config_id\202\323" - + "\344\223\002U\"B/v1/{parent=projects/*/locations/*" - + "/repositories/*}/workflowConfigs:\017workflow_config\022\203\002\n" - + "\024UpdateWorkflowConfig\0225.google.cloud.dataform.v1.UpdateWorkflowConf" - + "igRequest\032(.google.cloud.dataform.v1.Wor" - + "kflowConfig\"\211\001\332A\033workflow_config,update_", - "mask\202\323\344\223\002e2R/v1/{workflow_config.name=pr" - + "ojects/*/locations/*/repositories/*/work" - + "flowConfigs/*}:\017workflow_config\022\270\001\n\024Dele" - + "teWorkflowConfig\0225.google.cloud.dataform" - + ".v1.DeleteWorkflowConfigRequest\032\026.google" - + ".protobuf.Empty\"Q\332A\004name\202\323\344\223\002D*B/v1/{nam" - + "e=projects/*/locations/*/repositories/*/" - + "workflowConfigs/*}\022\347\001\n\027ListWorkflowInvoc" - + "ations\0228.google.cloud.dataform.v1.ListWo" - + "rkflowInvocationsRequest\0329.google.cloud." - + "dataform.v1.ListWorkflowInvocationsRespo" - + "nse\"W\332A\006parent\202\323\344\223\002H\022F/v1/{parent=projec" - + "ts/*/locations/*/repositories/*}/workflo" - + "wInvocations\022\324\001\n\025GetWorkflowInvocation\0226" - + ".google.cloud.dataform.v1.GetWorkflowInv" - + "ocationRequest\032,.google.cloud.dataform.v" - + "1.WorkflowInvocation\"U\332A\004name\202\323\344\223\002H\022F/v1" - + "/{name=projects/*/locations/*/repositori" - + "es/*/workflowInvocations/*}\022\206\002\n\030CreateWo" - + "rkflowInvocation\0229.google.cloud.dataform" - + ".v1.CreateWorkflowInvocationRequest\032,.go" - + "ogle.cloud.dataform.v1.WorkflowInvocatio" - + "n\"\200\001\332A\032parent,workflow_invocation\202\323\344\223\002]\"" - + "F/v1/{parent=projects/*/locations/*/repo" - + "sitories/*}/workflowInvocations:\023workflo" - + "w_invocation\022\304\001\n\030DeleteWorkflowInvocatio" - + "n\0229.google.cloud.dataform.v1.DeleteWorkf" - + "lowInvocationRequest\032\026.google.protobuf.E" - + "mpty\"U\332A\004name\202\323\344\223\002H*F/v1/{name=projects/" - + "*/locations/*/repositories/*/workflowInv" - + "ocations/*}\022\353\001\n\030CancelWorkflowInvocation" - + "\0229.google.cloud.dataform.v1.CancelWorkfl" - + "owInvocationRequest\032:.google.cloud.dataf" - + "orm.v1.CancelWorkflowInvocationResponse\"" - + "X\202\323\344\223\002R\"M/v1/{name=projects/*/locations/" - + "*/repositories/*/workflowInvocations/*}:" - + "cancel:\001*\022\371\001\n\036QueryWorkflowInvocationAct" - + "ions\022?.google.cloud.dataform.v1.QueryWor" - + "kflowInvocationActionsRequest\032@.google.c" - + "loud.dataform.v1.QueryWorkflowInvocation" - + "ActionsResponse\"T\202\323\344\223\002N\022L/v1/{name=proje" - + "cts/*/locations/*/repositories/*/workflo" - + "wInvocations/*}:query\022\222\001\n\tGetConfig\022*.go" - + "ogle.cloud.dataform.v1.GetConfigRequest\032" - + " .google.cloud.dataform.v1.Config\"7\332A\004na" - + "me\202\323\344\223\002*\022(/v1/{name=projects/*/locations" - + "/*/config}\022\265\001\n\014UpdateConfig\022-.google.clo" - + "ud.dataform.v1.UpdateConfigRequest\032 .goo" - + "gle.cloud.dataform.v1.Config\"T\332A\022config," - + "update_mask\202\323\344\223\00292//v1/{config.name=proj" - + "ects/*/locations/*/config}:\006config\022\367\002\n\014G" - + "etIamPolicy\022\".google.iam.v1.GetIamPolicy" - + "Request\032\025.google.iam.v1.Policy\"\253\002\332A\010reso" - + "urce\202\323\344\223\002\231\002\022A/v1/{resource=projects/*/lo" - + "cations/*/repositories/*}:getIamPolicyZP" - + "\022N/v1/{resource=projects/*/locations/*/r" - + "epositories/*/workspaces/*}:getIamPolicy" - + "Z>\022.google.cloud.dataform.v1.QueryCompilationResult" + + "ActionsRequest\032?.google.cloud.dataform.v1.QueryCompilationResultActionsResponse\"" + + "S\202\323\344\223\002M\022K/v1/{name=projects/*/locations/" + + "*/repositories/*/compilationResults/*}:query\022\327\001\n" + + "\023ListWorkflowConfigs\0224.google.cloud.dataform.v1.ListWorkflowConfigsReque" + + "st\0325.google.cloud.dataform.v1.ListWorkfl" + + "owConfigsResponse\"S\332A\006parent\202\323\344\223\002D\022B/v1/" + + "{parent=projects/*/locations/*/repositor", + "ies/*}/workflowConfigs\022\304\001\n\021GetWorkflowCo" + + "nfig\0222.google.cloud.dataform.v1.GetWorkf" + + "lowConfigRequest\032(.google.cloud.dataform" + + ".v1.WorkflowConfig\"Q\332A\004name\202\323\344\223\002D\022B/v1/{" + + "name=projects/*/locations/*/repositories" + + "/*/workflowConfigs/*}\022\201\002\n\024CreateWorkflow" + + "Config\0225.google.cloud.dataform.v1.Create" + + "WorkflowConfigRequest\032(.google.cloud.dat" + + "aform.v1.WorkflowConfig\"\207\001\332A)parent,work" + + "flow_config,workflow_config_id\202\323\344\223\002U\"B/v" + + "1/{parent=projects/*/locations/*/reposit" + + "ories/*}/workflowConfigs:\017workflow_confi" + + "g\022\203\002\n\024UpdateWorkflowConfig\0225.google.clou" + + "d.dataform.v1.UpdateWorkflowConfigReques" + + "t\032(.google.cloud.dataform.v1.WorkflowCon" + + "fig\"\211\001\332A\033workflow_config,update_mask\202\323\344\223" + + "\002e2R/v1/{workflow_config.name=projects/*" + + "/locations/*/repositories/*/workflowConf" + + "igs/*}:\017workflow_config\022\270\001\n\024DeleteWorkfl" + + "owConfig\0225.google.cloud.dataform.v1.Dele" + + "teWorkflowConfigRequest\032\026.google.protobu" + + "f.Empty\"Q\332A\004name\202\323\344\223\002D*B/v1/{name=projec" + + "ts/*/locations/*/repositories/*/workflow" + + "Configs/*}\022\347\001\n\027ListWorkflowInvocations\0228" + + ".google.cloud.dataform.v1.ListWorkflowIn" + + "vocationsRequest\0329.google.cloud.dataform" + + ".v1.ListWorkflowInvocationsResponse\"W\332A\006" + + "parent\202\323\344\223\002H\022F/v1/{parent=projects/*/loc" + + "ations/*/repositories/*}/workflowInvocat" + + "ions\022\324\001\n\025GetWorkflowInvocation\0226.google." + + "cloud.dataform.v1.GetWorkflowInvocationR" + + "equest\032,.google.cloud.dataform.v1.Workfl" + + "owInvocation\"U\332A\004name\202\323\344\223\002H\022F/v1/{name=p" + + "rojects/*/locations/*/repositories/*/wor" + + "kflowInvocations/*}\022\206\002\n\030CreateWorkflowIn" + + "vocation\0229.google.cloud.dataform.v1.Crea" + + "teWorkflowInvocationRequest\032,.google.clo" + + "ud.dataform.v1.WorkflowInvocation\"\200\001\332A\032p" + + "arent,workflow_invocation\202\323\344\223\002]\"F/v1/{pa" + + "rent=projects/*/locations/*/repositories" + + "/*}/workflowInvocations:\023workflow_invoca" + + "tion\022\304\001\n\030DeleteWorkflowInvocation\0229.goog" + + "le.cloud.dataform.v1.DeleteWorkflowInvoc" + + "ationRequest\032\026.google.protobuf.Empty\"U\332A" + + "\004name\202\323\344\223\002H*F/v1/{name=projects/*/locati" + + "ons/*/repositories/*/workflowInvocations" + + "/*}\022\353\001\n\030CancelWorkflowInvocation\0229.googl" + + "e.cloud.dataform.v1.CancelWorkflowInvoca" + + "tionRequest\032:.google.cloud.dataform.v1.C" + + "ancelWorkflowInvocationResponse\"X\202\323\344\223\002R\"" + + "M/v1/{name=projects/*/locations/*/reposi" + + "tories/*/workflowInvocations/*}:cancel:\001" + + "*\022\371\001\n\036QueryWorkflowInvocationActions\022?.g" + + "oogle.cloud.dataform.v1.QueryWorkflowInv" + + "ocationActionsRequest\032@.google.cloud.dat" + + "aform.v1.QueryWorkflowInvocationActionsR" + + "esponse\"T\202\323\344\223\002N\022L/v1/{name=projects/*/lo" + + "cations/*/repositories/*/workflowInvocat" + + "ions/*}:query\022\222\001\n\tGetConfig\022*.google.clo" + + "ud.dataform.v1.GetConfigRequest\032 .google" + + ".cloud.dataform.v1.Config\"7\332A\004name\202\323\344\223\002*" + + "\022(/v1/{name=projects/*/locations/*/confi" + + "g}\022\265\001\n\014UpdateConfig\022-.google.cloud.dataf" + + "orm.v1.UpdateConfigRequest\032 .google.clou" + + "d.dataform.v1.Config\"T\332A\022config,update_m" + + "ask\202\323\344\223\00292//v1/{config.name=projects/*/l" + + "ocations/*/config}:\006config\022\367\002\n\014GetIamPol" + + "icy\022\".google.iam.v1.GetIamPolicyRequest\032" + + "\025.google.iam.v1.Policy\"\253\002\332A\010resource\202\323\344\223" + + "\002\231\002\022A/v1/{resource=projects/*/locations/" + + "*/repositories/*}:getIamPolicyZP\022N/v1/{r" + + "esource=projects/*/locations/*/repositor" + + "ies/*/workspaces/*}:getIamPolicyZ>\022 * * @deprecated google.cloud.dataform.v1.Repository.GitRemoteSettings.token_status is deprecated. - * See google/cloud/dataform/v1/dataform.proto;l=926 + * See google/cloud/dataform/v1/dataform.proto;l=940 * @return The enum numeric value on the wire for tokenStatus. */ @java.lang.Deprecated @@ -342,7 +342,7 @@ public interface GitRemoteSettingsOrBuilder * * * @deprecated google.cloud.dataform.v1.Repository.GitRemoteSettings.token_status is deprecated. - * See google/cloud/dataform/v1/dataform.proto;l=926 + * See google/cloud/dataform/v1/dataform.proto;l=940 * @return The tokenStatus. */ @java.lang.Deprecated @@ -1915,7 +1915,7 @@ public com.google.protobuf.ByteString getGitRepositoryLinkBytes() { * * * @deprecated google.cloud.dataform.v1.Repository.GitRemoteSettings.token_status is deprecated. - * See google/cloud/dataform/v1/dataform.proto;l=926 + * See google/cloud/dataform/v1/dataform.proto;l=940 * @return The enum numeric value on the wire for tokenStatus. */ @java.lang.Override @@ -1937,7 +1937,7 @@ public int getTokenStatusValue() { * * * @deprecated google.cloud.dataform.v1.Repository.GitRemoteSettings.token_status is deprecated. - * See google/cloud/dataform/v1/dataform.proto;l=926 + * See google/cloud/dataform/v1/dataform.proto;l=940 * @return The tokenStatus. */ @java.lang.Override @@ -3329,7 +3329,7 @@ public Builder setGitRepositoryLinkBytes(com.google.protobuf.ByteString value) { * * * @deprecated google.cloud.dataform.v1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1/dataform.proto;l=926 + * deprecated. See google/cloud/dataform/v1/dataform.proto;l=940 * @return The enum numeric value on the wire for tokenStatus. */ @java.lang.Override @@ -3351,7 +3351,7 @@ public int getTokenStatusValue() { * * * @deprecated google.cloud.dataform.v1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1/dataform.proto;l=926 + * deprecated. See google/cloud/dataform/v1/dataform.proto;l=940 * @param value The enum numeric value on the wire for tokenStatus to set. * @return This builder for chaining. */ @@ -3376,7 +3376,7 @@ public Builder setTokenStatusValue(int value) { * * * @deprecated google.cloud.dataform.v1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1/dataform.proto;l=926 + * deprecated. See google/cloud/dataform/v1/dataform.proto;l=940 * @return The tokenStatus. */ @java.lang.Override @@ -3404,7 +3404,7 @@ public Builder setTokenStatusValue(int value) { * * * @deprecated google.cloud.dataform.v1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1/dataform.proto;l=926 + * deprecated. See google/cloud/dataform/v1/dataform.proto;l=940 * @param value The tokenStatus to set. * @return This builder for chaining. */ @@ -3433,7 +3433,7 @@ public Builder setTokenStatus( * * * @deprecated google.cloud.dataform.v1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1/dataform.proto;l=926 + * deprecated. See google/cloud/dataform/v1/dataform.proto;l=940 * @return This builder for chaining. */ @java.lang.Deprecated diff --git a/java-dataform/proto-google-cloud-dataform-v1/src/main/proto/google/cloud/dataform/v1/dataform.proto b/java-dataform/proto-google-cloud-dataform-v1/src/main/proto/google/cloud/dataform/v1/dataform.proto index f626cad9b4dd..8ce71d1fe196 100644 --- a/java-dataform/proto-google-cloud-dataform-v1/src/main/proto/google/cloud/dataform/v1/dataform.proto +++ b/java-dataform/proto-google-cloud-dataform-v1/src/main/proto/google/cloud/dataform/v1/dataform.proto @@ -369,6 +369,20 @@ service Dataform { option (google.api.method_signature) = "parent,workspace,workspace_id"; } + // Creates a new Workspace in a given Repository asynchronously. + rpc CreateWorkspaceLongRunning(CreateWorkspaceRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*/repositories/*}/workspaces:createLongRunning" + body: "workspace" + }; + option (google.api.method_signature) = "parent,workspace,workspace_id"; + option (google.longrunning.operation_info) = { + response_type: "Workspace" + metadata_type: "CreateWorkspaceMetadata" + }; + } + // Deletes a single Workspace. rpc DeleteWorkspace(DeleteWorkspaceRequest) returns (google.protobuf.Empty) { option (google.api.http) = { @@ -1518,6 +1532,46 @@ message CreateWorkspaceRequest { string workspace_id = 3 [(google.api.field_behavior) = REQUIRED]; } +// Represents the metadata of the `CreateWorkspaceLongRunning` operation. +message CreateWorkspaceMetadata { + // State of the LRO. + enum State { + // The state is unspecified. + STATE_UNSPECIFIED = 0; + + // The LRO has been created. + CREATED = 1; + + // The LRO is in progress. + RUNNING = 2; + + // The RPC call has finished. + FINISHED = 3; + + // The LRO has succeeded. + SUCCEEDED = 4; + + // The LRO has failed. + FAILED = 5; + } + + // The unwrapped request. + oneof request { + // Output only. The CreateWorkspace requested. + CreateWorkspaceRequest create_workspace_request = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; + } + + // Output only. The ID of the LRO. + string id = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Server-defined resource path for the target of the operation. + string target = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The state of the LRO. + State state = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; +} + // `DeleteWorkspace` request message. message DeleteWorkspaceRequest { // Required. The workspace resource's name. diff --git a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateFolderRequest.java b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateFolderRequest.java index b19823b4f34a..d57731580c02 100644 --- a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateFolderRequest.java +++ b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateFolderRequest.java @@ -208,7 +208,7 @@ public com.google.cloud.dataform.v1beta1.FolderOrBuilder getFolderOrBuilder() { * string folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateFolderRequest.folder_id is deprecated. See - * google/cloud/dataform/v1beta1/dataform.proto;l=4105 + * google/cloud/dataform/v1beta1/dataform.proto;l=4159 * @return The folderId. */ @java.lang.Override @@ -238,7 +238,7 @@ public java.lang.String getFolderId() { * string folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateFolderRequest.folder_id is deprecated. See - * google/cloud/dataform/v1beta1/dataform.proto;l=4105 + * google/cloud/dataform/v1beta1/dataform.proto;l=4159 * @return The bytes for folderId. */ @java.lang.Override @@ -986,7 +986,7 @@ public com.google.cloud.dataform.v1beta1.FolderOrBuilder getFolderOrBuilder() { * string folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateFolderRequest.folder_id is deprecated. See - * google/cloud/dataform/v1beta1/dataform.proto;l=4105 + * google/cloud/dataform/v1beta1/dataform.proto;l=4159 * @return The folderId. */ @java.lang.Deprecated @@ -1015,7 +1015,7 @@ public java.lang.String getFolderId() { * string folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateFolderRequest.folder_id is deprecated. See - * google/cloud/dataform/v1beta1/dataform.proto;l=4105 + * google/cloud/dataform/v1beta1/dataform.proto;l=4159 * @return The bytes for folderId. */ @java.lang.Deprecated @@ -1044,7 +1044,7 @@ public com.google.protobuf.ByteString getFolderIdBytes() { * string folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateFolderRequest.folder_id is deprecated. See - * google/cloud/dataform/v1beta1/dataform.proto;l=4105 + * google/cloud/dataform/v1beta1/dataform.proto;l=4159 * @param value The folderId to set. * @return This builder for chaining. */ @@ -1072,7 +1072,7 @@ public Builder setFolderId(java.lang.String value) { * string folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateFolderRequest.folder_id is deprecated. See - * google/cloud/dataform/v1beta1/dataform.proto;l=4105 + * google/cloud/dataform/v1beta1/dataform.proto;l=4159 * @return This builder for chaining. */ @java.lang.Deprecated @@ -1096,7 +1096,7 @@ public Builder clearFolderId() { * string folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateFolderRequest.folder_id is deprecated. See - * google/cloud/dataform/v1beta1/dataform.proto;l=4105 + * google/cloud/dataform/v1beta1/dataform.proto;l=4159 * @param value The bytes for folderId to set. * @return This builder for chaining. */ diff --git a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateFolderRequestOrBuilder.java b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateFolderRequestOrBuilder.java index 0315e8e72b3b..e03f3c0d39a0 100644 --- a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateFolderRequestOrBuilder.java +++ b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateFolderRequestOrBuilder.java @@ -114,7 +114,7 @@ public interface CreateFolderRequestOrBuilder * string folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateFolderRequest.folder_id is deprecated. See - * google/cloud/dataform/v1beta1/dataform.proto;l=4105 + * google/cloud/dataform/v1beta1/dataform.proto;l=4159 * @return The folderId. */ @java.lang.Deprecated @@ -133,7 +133,7 @@ public interface CreateFolderRequestOrBuilder * string folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateFolderRequest.folder_id is deprecated. See - * google/cloud/dataform/v1beta1/dataform.proto;l=4105 + * google/cloud/dataform/v1beta1/dataform.proto;l=4159 * @return The bytes for folderId. */ @java.lang.Deprecated diff --git a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateTeamFolderRequest.java b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateTeamFolderRequest.java index 25903c7edf84..b0ef428c67ce 100644 --- a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateTeamFolderRequest.java +++ b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateTeamFolderRequest.java @@ -208,7 +208,7 @@ public com.google.cloud.dataform.v1beta1.TeamFolderOrBuilder getTeamFolderOrBuil * string team_folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateTeamFolderRequest.team_folder_id is deprecated. - * See google/cloud/dataform/v1beta1/dataform.proto;l=4417 + * See google/cloud/dataform/v1beta1/dataform.proto;l=4471 * @return The teamFolderId. */ @java.lang.Override @@ -238,7 +238,7 @@ public java.lang.String getTeamFolderId() { * string team_folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateTeamFolderRequest.team_folder_id is deprecated. - * See google/cloud/dataform/v1beta1/dataform.proto;l=4417 + * See google/cloud/dataform/v1beta1/dataform.proto;l=4471 * @return The bytes for teamFolderId. */ @java.lang.Override @@ -988,7 +988,7 @@ public com.google.cloud.dataform.v1beta1.TeamFolderOrBuilder getTeamFolderOrBuil * string team_folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateTeamFolderRequest.team_folder_id is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=4417 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=4471 * @return The teamFolderId. */ @java.lang.Deprecated @@ -1017,7 +1017,7 @@ public java.lang.String getTeamFolderId() { * string team_folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateTeamFolderRequest.team_folder_id is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=4417 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=4471 * @return The bytes for teamFolderId. */ @java.lang.Deprecated @@ -1046,7 +1046,7 @@ public com.google.protobuf.ByteString getTeamFolderIdBytes() { * string team_folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateTeamFolderRequest.team_folder_id is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=4417 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=4471 * @param value The teamFolderId to set. * @return This builder for chaining. */ @@ -1074,7 +1074,7 @@ public Builder setTeamFolderId(java.lang.String value) { * string team_folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateTeamFolderRequest.team_folder_id is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=4417 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=4471 * @return This builder for chaining. */ @java.lang.Deprecated @@ -1098,7 +1098,7 @@ public Builder clearTeamFolderId() { * string team_folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateTeamFolderRequest.team_folder_id is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=4417 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=4471 * @param value The bytes for teamFolderId to set. * @return This builder for chaining. */ diff --git a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateTeamFolderRequestOrBuilder.java b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateTeamFolderRequestOrBuilder.java index 98b528ae30af..e0bde33df3cf 100644 --- a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateTeamFolderRequestOrBuilder.java +++ b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateTeamFolderRequestOrBuilder.java @@ -114,7 +114,7 @@ public interface CreateTeamFolderRequestOrBuilder * string team_folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateTeamFolderRequest.team_folder_id is deprecated. - * See google/cloud/dataform/v1beta1/dataform.proto;l=4417 + * See google/cloud/dataform/v1beta1/dataform.proto;l=4471 * @return The teamFolderId. */ @java.lang.Deprecated @@ -133,7 +133,7 @@ public interface CreateTeamFolderRequestOrBuilder * string team_folder_id = 3 [deprecated = true]; * * @deprecated google.cloud.dataform.v1beta1.CreateTeamFolderRequest.team_folder_id is deprecated. - * See google/cloud/dataform/v1beta1/dataform.proto;l=4417 + * See google/cloud/dataform/v1beta1/dataform.proto;l=4471 * @return The bytes for teamFolderId. */ @java.lang.Deprecated diff --git a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateWorkspaceMetadata.java b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateWorkspaceMetadata.java new file mode 100644 index 000000000000..eec06002285b --- /dev/null +++ b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateWorkspaceMetadata.java @@ -0,0 +1,1624 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/dataform/v1beta1/dataform.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.dataform.v1beta1; + +/** + * + * + *
                      + * Represents the metadata of the `CreateWorkspaceLongRunning` operation.
                      + * 
                      + * + * Protobuf type {@code google.cloud.dataform.v1beta1.CreateWorkspaceMetadata} + */ +@com.google.protobuf.Generated +public final class CreateWorkspaceMetadata extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataform.v1beta1.CreateWorkspaceMetadata) + CreateWorkspaceMetadataOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "CreateWorkspaceMetadata"); + } + + // Use CreateWorkspaceMetadata.newBuilder() to construct. + private CreateWorkspaceMetadata(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private CreateWorkspaceMetadata() { + id_ = ""; + target_ = ""; + state_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataform.v1beta1.DataformProto + .internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataform.v1beta1.DataformProto + .internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.class, + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.Builder.class); + } + + /** + * + * + *
                      +   * State of the LRO.
                      +   * 
                      + * + * Protobuf enum {@code google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                      +     * The state is unspecified.
                      +     * 
                      + * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
                      +     * The LRO has been created.
                      +     * 
                      + * + * CREATED = 1; + */ + CREATED(1), + /** + * + * + *
                      +     * The LRO is in progress.
                      +     * 
                      + * + * RUNNING = 2; + */ + RUNNING(2), + /** + * + * + *
                      +     * The RPC call has finished.
                      +     * 
                      + * + * FINISHED = 3; + */ + FINISHED(3), + /** + * + * + *
                      +     * The LRO has succeeded.
                      +     * 
                      + * + * SUCCEEDED = 4; + */ + SUCCEEDED(4), + /** + * + * + *
                      +     * The LRO has failed.
                      +     * 
                      + * + * FAILED = 5; + */ + FAILED(5), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "State"); + } + + /** + * + * + *
                      +     * The state is unspecified.
                      +     * 
                      + * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                      +     * The LRO has been created.
                      +     * 
                      + * + * CREATED = 1; + */ + public static final int CREATED_VALUE = 1; + + /** + * + * + *
                      +     * The LRO is in progress.
                      +     * 
                      + * + * RUNNING = 2; + */ + public static final int RUNNING_VALUE = 2; + + /** + * + * + *
                      +     * The RPC call has finished.
                      +     * 
                      + * + * FINISHED = 3; + */ + public static final int FINISHED_VALUE = 3; + + /** + * + * + *
                      +     * The LRO has succeeded.
                      +     * 
                      + * + * SUCCEEDED = 4; + */ + public static final int SUCCEEDED_VALUE = 4; + + /** + * + * + *
                      +     * The LRO has failed.
                      +     * 
                      + * + * FAILED = 5; + */ + public static final int FAILED_VALUE = 5; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return CREATED; + case 2: + return RUNNING; + case 3: + return FINISHED; + case 4: + return SUCCEEDED; + case 5: + return FAILED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public State findValueByNumber(int number) { + return State.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final State[] VALUES = values(); + + public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private State(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State) + } + + private int requestCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object request_; + + public enum RequestCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + CREATE_WORKSPACE_REQUEST(4), + REQUEST_NOT_SET(0); + private final int value; + + private RequestCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static RequestCase valueOf(int value) { + return forNumber(value); + } + + public static RequestCase forNumber(int value) { + switch (value) { + case 4: + return CREATE_WORKSPACE_REQUEST; + case 0: + return REQUEST_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public RequestCase getRequestCase() { + return RequestCase.forNumber(requestCase_); + } + + public static final int CREATE_WORKSPACE_REQUEST_FIELD_NUMBER = 4; + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createWorkspaceRequest field is set. + */ + @java.lang.Override + public boolean hasCreateWorkspaceRequest() { + return requestCase_ == 4; + } + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createWorkspaceRequest. + */ + @java.lang.Override + public com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest getCreateWorkspaceRequest() { + if (requestCase_ == 4) { + return (com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest) request_; + } + return com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.getDefaultInstance(); + } + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.dataform.v1beta1.CreateWorkspaceRequestOrBuilder + getCreateWorkspaceRequestOrBuilder() { + if (requestCase_ == 4) { + return (com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest) request_; + } + return com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.getDefaultInstance(); + } + + public static final int ID_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object id_ = ""; + + /** + * + * + *
                      +   * Output only. The ID of the LRO.
                      +   * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The id. + */ + @java.lang.Override + public java.lang.String getId() { + java.lang.Object ref = id_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + id_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Output only. The ID of the LRO.
                      +   * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for id. + */ + @java.lang.Override + public com.google.protobuf.ByteString getIdBytes() { + java.lang.Object ref = id_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + id_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TARGET_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object target_ = ""; + + /** + * + * + *
                      +   * Output only. Server-defined resource path for the target of the operation.
                      +   * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + @java.lang.Override + public java.lang.String getTarget() { + java.lang.Object ref = target_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + target_ = s; + return s; + } + } + + /** + * + * + *
                      +   * Output only. Server-defined resource path for the target of the operation.
                      +   * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTargetBytes() { + java.lang.Object ref = target_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + target_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STATE_FIELD_NUMBER = 3; + private int state_ = 0; + + /** + * + * + *
                      +   * Output only. The state of the LRO.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
                      +   * Output only. The state of the LRO.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State getState() { + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State result = + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State.forNumber(state_); + return result == null + ? com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(id_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, id_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(target_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, target_); + } + if (state_ + != com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State.STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, state_); + } + if (requestCase_ == 4) { + output.writeMessage(4, (com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest) request_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(id_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, id_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(target_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, target_); + } + if (state_ + != com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State.STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, state_); + } + if (requestCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest) request_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata)) { + return super.equals(obj); + } + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata other = + (com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata) obj; + + if (!getId().equals(other.getId())) return false; + if (!getTarget().equals(other.getTarget())) return false; + if (state_ != other.state_) return false; + if (!getRequestCase().equals(other.getRequestCase())) return false; + switch (requestCase_) { + case 4: + if (!getCreateWorkspaceRequest().equals(other.getCreateWorkspaceRequest())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ID_FIELD_NUMBER; + hash = (53 * hash) + getId().hashCode(); + hash = (37 * hash) + TARGET_FIELD_NUMBER; + hash = (53 * hash) + getTarget().hashCode(); + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + switch (requestCase_) { + case 4: + hash = (37 * hash) + CREATE_WORKSPACE_REQUEST_FIELD_NUMBER; + hash = (53 * hash) + getCreateWorkspaceRequest().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Represents the metadata of the `CreateWorkspaceLongRunning` operation.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.dataform.v1beta1.CreateWorkspaceMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataform.v1beta1.CreateWorkspaceMetadata) + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataform.v1beta1.DataformProto + .internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataform.v1beta1.DataformProto + .internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.class, + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.Builder.class); + } + + // Construct using com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (createWorkspaceRequestBuilder_ != null) { + createWorkspaceRequestBuilder_.clear(); + } + id_ = ""; + target_ = ""; + state_ = 0; + requestCase_ = 0; + request_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataform.v1beta1.DataformProto + .internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceMetadata_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata getDefaultInstanceForType() { + return com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata build() { + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata buildPartial() { + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata result = + new com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.id_ = id_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.target_ = target_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.state_ = state_; + } + } + + private void buildPartialOneofs( + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata result) { + result.requestCase_ = requestCase_; + result.request_ = this.request_; + if (requestCase_ == 4 && createWorkspaceRequestBuilder_ != null) { + result.request_ = createWorkspaceRequestBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata) { + return mergeFrom((com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata other) { + if (other == com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.getDefaultInstance()) + return this; + if (!other.getId().isEmpty()) { + id_ = other.id_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getTarget().isEmpty()) { + target_ = other.target_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + switch (other.getRequestCase()) { + case CREATE_WORKSPACE_REQUEST: + { + mergeCreateWorkspaceRequest(other.getCreateWorkspaceRequest()); + break; + } + case REQUEST_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + id_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 10 + case 18: + { + target_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 18 + case 24: + { + state_ = input.readEnum(); + bitField0_ |= 0x00000008; + break; + } // case 24 + case 34: + { + input.readMessage( + internalGetCreateWorkspaceRequestFieldBuilder().getBuilder(), + extensionRegistry); + requestCase_ = 4; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int requestCase_ = 0; + private java.lang.Object request_; + + public RequestCase getRequestCase() { + return RequestCase.forNumber(requestCase_); + } + + public Builder clearRequest() { + requestCase_ = 0; + request_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest, + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.Builder, + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequestOrBuilder> + createWorkspaceRequestBuilder_; + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createWorkspaceRequest field is set. + */ + @java.lang.Override + public boolean hasCreateWorkspaceRequest() { + return requestCase_ == 4; + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createWorkspaceRequest. + */ + @java.lang.Override + public com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest getCreateWorkspaceRequest() { + if (createWorkspaceRequestBuilder_ == null) { + if (requestCase_ == 4) { + return (com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest) request_; + } + return com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.getDefaultInstance(); + } else { + if (requestCase_ == 4) { + return createWorkspaceRequestBuilder_.getMessage(); + } + return com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateWorkspaceRequest( + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest value) { + if (createWorkspaceRequestBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + request_ = value; + onChanged(); + } else { + createWorkspaceRequestBuilder_.setMessage(value); + } + requestCase_ = 4; + return this; + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateWorkspaceRequest( + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.Builder builderForValue) { + if (createWorkspaceRequestBuilder_ == null) { + request_ = builderForValue.build(); + onChanged(); + } else { + createWorkspaceRequestBuilder_.setMessage(builderForValue.build()); + } + requestCase_ = 4; + return this; + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateWorkspaceRequest( + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest value) { + if (createWorkspaceRequestBuilder_ == null) { + if (requestCase_ == 4 + && request_ + != com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.getDefaultInstance()) { + request_ = + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.newBuilder( + (com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest) request_) + .mergeFrom(value) + .buildPartial(); + } else { + request_ = value; + } + onChanged(); + } else { + if (requestCase_ == 4) { + createWorkspaceRequestBuilder_.mergeFrom(value); + } else { + createWorkspaceRequestBuilder_.setMessage(value); + } + } + requestCase_ = 4; + return this; + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateWorkspaceRequest() { + if (createWorkspaceRequestBuilder_ == null) { + if (requestCase_ == 4) { + requestCase_ = 0; + request_ = null; + onChanged(); + } + } else { + if (requestCase_ == 4) { + requestCase_ = 0; + request_ = null; + } + createWorkspaceRequestBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.Builder + getCreateWorkspaceRequestBuilder() { + return internalGetCreateWorkspaceRequestFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.dataform.v1beta1.CreateWorkspaceRequestOrBuilder + getCreateWorkspaceRequestOrBuilder() { + if ((requestCase_ == 4) && (createWorkspaceRequestBuilder_ != null)) { + return createWorkspaceRequestBuilder_.getMessageOrBuilder(); + } else { + if (requestCase_ == 4) { + return (com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest) request_; + } + return com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Output only. The CreateWorkspace requested.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest, + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.Builder, + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequestOrBuilder> + internalGetCreateWorkspaceRequestFieldBuilder() { + if (createWorkspaceRequestBuilder_ == null) { + if (!(requestCase_ == 4)) { + request_ = com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.getDefaultInstance(); + } + createWorkspaceRequestBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest, + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest.Builder, + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequestOrBuilder>( + (com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest) request_, + getParentForChildren(), + isClean()); + request_ = null; + } + requestCase_ = 4; + onChanged(); + return createWorkspaceRequestBuilder_; + } + + private java.lang.Object id_ = ""; + + /** + * + * + *
                      +     * Output only. The ID of the LRO.
                      +     * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The id. + */ + public java.lang.String getId() { + java.lang.Object ref = id_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + id_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Output only. The ID of the LRO.
                      +     * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for id. + */ + public com.google.protobuf.ByteString getIdBytes() { + java.lang.Object ref = id_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + id_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Output only. The ID of the LRO.
                      +     * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The id to set. + * @return This builder for chaining. + */ + public Builder setId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + id_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The ID of the LRO.
                      +     * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearId() { + id_ = getDefaultInstance().getId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The ID of the LRO.
                      +     * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for id to set. + * @return This builder for chaining. + */ + public Builder setIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + id_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object target_ = ""; + + /** + * + * + *
                      +     * Output only. Server-defined resource path for the target of the operation.
                      +     * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + public java.lang.String getTarget() { + java.lang.Object ref = target_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + target_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                      +     * Output only. Server-defined resource path for the target of the operation.
                      +     * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + public com.google.protobuf.ByteString getTargetBytes() { + java.lang.Object ref = target_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + target_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                      +     * Output only. Server-defined resource path for the target of the operation.
                      +     * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The target to set. + * @return This builder for chaining. + */ + public Builder setTarget(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + target_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. Server-defined resource path for the target of the operation.
                      +     * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearTarget() { + target_ = getDefaultInstance().getTarget(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. Server-defined resource path for the target of the operation.
                      +     * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for target to set. + * @return This builder for chaining. + */ + public Builder setTargetBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + target_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private int state_ = 0; + + /** + * + * + *
                      +     * Output only. The state of the LRO.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
                      +     * Output only. The state of the LRO.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The state of the LRO.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State getState() { + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State result = + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State.forNumber(state_); + return result == null + ? com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State.UNRECOGNIZED + : result; + } + + /** + * + * + *
                      +     * Output only. The state of the LRO.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000008; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Output only. The state of the LRO.
                      +     * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000008); + state_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataform.v1beta1.CreateWorkspaceMetadata) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataform.v1beta1.CreateWorkspaceMetadata) + private static final com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata(); + } + + public static com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateWorkspaceMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateWorkspaceMetadataOrBuilder.java b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateWorkspaceMetadataOrBuilder.java new file mode 100644 index 000000000000..c3763be5fdf3 --- /dev/null +++ b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/CreateWorkspaceMetadataOrBuilder.java @@ -0,0 +1,156 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/dataform/v1beta1/dataform.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.dataform.v1beta1; + +@com.google.protobuf.Generated +public interface CreateWorkspaceMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataform.v1beta1.CreateWorkspaceMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createWorkspaceRequest field is set. + */ + boolean hasCreateWorkspaceRequest(); + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createWorkspaceRequest. + */ + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest getCreateWorkspaceRequest(); + + /** + * + * + *
                      +   * Output only. The CreateWorkspace requested.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceRequest create_workspace_request = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.dataform.v1beta1.CreateWorkspaceRequestOrBuilder + getCreateWorkspaceRequestOrBuilder(); + + /** + * + * + *
                      +   * Output only. The ID of the LRO.
                      +   * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The id. + */ + java.lang.String getId(); + + /** + * + * + *
                      +   * Output only. The ID of the LRO.
                      +   * 
                      + * + * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for id. + */ + com.google.protobuf.ByteString getIdBytes(); + + /** + * + * + *
                      +   * Output only. Server-defined resource path for the target of the operation.
                      +   * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + java.lang.String getTarget(); + + /** + * + * + *
                      +   * Output only. Server-defined resource path for the target of the operation.
                      +   * 
                      + * + * string target = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + com.google.protobuf.ByteString getTargetBytes(); + + /** + * + * + *
                      +   * Output only. The state of the LRO.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
                      +   * Output only. The state of the LRO.
                      +   * 
                      + * + * + * .google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.State getState(); + + com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata.RequestCase getRequestCase(); +} diff --git a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/DataformProto.java b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/DataformProto.java index 1018db6079ce..7d39b4d82007 100644 --- a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/DataformProto.java +++ b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/DataformProto.java @@ -204,6 +204,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceMetadata_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceMetadata_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_dataform_v1beta1_DeleteWorkspaceRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -1106,7 +1110,22 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\"dataform.googleapis.com/Repository\022A\n" + "\tworkspace\030\002" + " \001(\0132(.google.cloud.dataform.v1beta1.WorkspaceB\004\342A\001\002\022\032\n" - + "\014workspace_id\030\003 \001(\tB\004\342A\001\002\"R\n" + + "\014workspace_id\030\003 \001(\tB\004\342A\001\002\"\343\002\n" + + "\027CreateWorkspaceMetadata\022_\n" + + "\030create_workspace_request\030\004 \001(\01325.go" + + "ogle.cloud.dataform.v1beta1.CreateWorkspaceRequestB\004\342A\001\003H\000\022\020\n" + + "\002id\030\001 \001(\tB\004\342A\001\003\022\024\n" + + "\006target\030\002 \001(\tB\004\342A\001\003\022Q\n" + + "\005state\030\003 \001(\0162<.goog" + + "le.cloud.dataform.v1beta1.CreateWorkspaceMetadata.StateB\004\342A\001\003\"a\n" + + "\005State\022\025\n" + + "\021STATE_UNSPECIFIED\020\000\022\013\n" + + "\007CREATED\020\001\022\013\n" + + "\007RUNNING\020\002\022\014\n" + + "\010FINISHED\020\003\022\r\n" + + "\tSUCCEEDED\020\004\022\n\n" + + "\006FAILED\020\005B\t\n" + + "\007request\"R\n" + "\026DeleteWorkspaceRequest\0228\n" + "\004name\030\001 \001(\tB*\342A\001\002\372A#\n" + "!dataform.googleapis.com/Workspace\"?\n" @@ -1124,7 +1143,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004name\030\001 \001(\tB*\342A\001\002\372A#\n" + "!dataform.googleapis.com/Workspace\022\024\n" + "\006branch\030\002 \001(\tB\004\342A\001\002\022\"\n" - + "\024create_if_not_exists\030\003 \001(\010B\004\342A\001\001\022\033\n\r" + + "\024create_if_not_exists\030\003 \001(\010B\004\342A\001\001\022\033\n" + + "\r" + "source_branch\030\004 \001(\tB\004\342A\001\001\"\214\001\n" + "\030SyncWorkspaceRefsRequest\0228\n" + "\004name\030\001 \001(\tB*\342A\001\002\372A#\n" @@ -1147,12 +1167,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004name\030\001 \001(\tB*\342A\001\002\372A#\n" + "!dataform.googleapis.com/Workspace\"\202\003\n" + "\034FetchFileGitStatusesResponse\022s\n" - + "\030uncommitted_file_changes\030\001 \003(\0132Q.google.cloud.dataform.v1beta1.Fetch" - + "FileGitStatusesResponse.UncommittedFileChange\032\354\001\n" + + "\030uncommitted_file_changes\030\001 \003(\0132Q.google.cloud.dataform.v1beta1.FetchFi" + + "leGitStatusesResponse.UncommittedFileChange\032\354\001\n" + "\025UncommittedFileChange\022\014\n" + "\004path\030\001 \001(\t\022l\n" - + "\005state\030\002 \001(\0162W.google.cloud.data" - + "form.v1beta1.FetchFileGitStatusesResponse.UncommittedFileChange.StateB\004\342A\001\003\"W\n" + + "\005state\030\002 \001(\0162W.google.cloud.datafo" + + "rm.v1beta1.FetchFileGitStatusesResponse.UncommittedFileChange.StateB\004\342A\001\003\"W\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\t\n" + "\005ADDED\020\001\022\013\n" @@ -1210,8 +1230,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016DirectoryEntry\022\016\n" + "\004file\030\001 \001(\tH\000\022\023\n" + "\tdirectory\030\002 \001(\tH\000\022H\n" - + "\010metadata\030\003 \001(\013" - + "26.google.cloud.dataform.v1beta1.FilesystemEntryMetadataB\007\n" + + "\010metadata\030\003 \001(\01326" + + ".google.cloud.dataform.v1beta1.FilesystemEntryMetadataB\007\n" + "\005entry\"j\n" + "\027FilesystemEntryMetadata\022\030\n\n" + "size_bytes\030\001 \001(\003B\004\342A\001\003\0225\n" @@ -1230,8 +1250,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\014SearchResult\022?\n" + "\004file\030\001" + " \001(\0132/.google.cloud.dataform.v1beta1.FileSearchResultH\000\022I\n" - + "\tdirectory\030\002 \001(\01324.g" - + "oogle.cloud.dataform.v1beta1.DirectorySearchResultH\000B\007\n" + + "\tdirectory\030\002 \001(\01324.goo" + + "gle.cloud.dataform.v1beta1.DirectorySearchResultH\000B\007\n" + "\005entry\" \n" + "\020FileSearchResult\022\014\n" + "\004path\030\001 \001(\t\"%\n" @@ -1280,8 +1300,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\031InstallNpmPackagesRequest\022=\n" + "\tworkspace\030\001 \001(\tB*\342A\001\002\372A#\n" + "!dataform.googleapis.com/Workspace\022L\n" - + "\017pipeline_config\030\003 \001(\0132-.google.clou" - + "d.dataform.v1beta1.PipelineConfigB\004\342A\001\001\"\034\n" + + "\017pipeline_config\030\003" + + " \001(\0132-.google.cloud.dataform.v1beta1.PipelineConfigB\004\342A\001\001\"\034\n" + "\032InstallNpmPackagesResponse\"\373\006\n\r" + "ReleaseConfig\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\033\n\r" @@ -1290,8 +1310,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\01324.google.cloud.dataform.v1beta1.CodeCompilationConfigB\004\342A\001\001\022\033\n\r" + "cron_schedule\030\004 \001(\tB\004\342A\001\001\022\027\n" + "\ttime_zone\030\007 \001(\tB\004\342A\001\001\022s\n" - + " recent_scheduled_release_records\030\005 \003(\0132C.google.cloud.dataform.v1beta1.Re" - + "leaseConfig.ScheduledReleaseRecordB\004\342A\001\003\022V\n" + + " recent_scheduled_release_records\030\005 " + + "\003(\0132C.google.cloud.dataform.v1beta1.Rele" + + "aseConfig.ScheduledReleaseRecordB\004\342A\001\003\022V\n" + "\032release_compilation_result\030\006 \001(\tB2\342A\001\001\372A+\n" + ")dataform.googleapis.com/CompilationResult\022\026\n" + "\010disabled\030\010 \001(\010B\004\342A\001\001\022$\n" @@ -1303,19 +1324,20 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\014release_time\030\001" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003B\010\n" + "\006result:\255\001\352A\251\001\n" - + "%dataform.googleapis.com/ReleaseConfig\022aprojects/{project}/location" - + "s/{location}/repositories/{repository}/r" - + "eleaseConfigs/{release_config}*\016releaseConfigs2\r" + + "%dataform.googleapis.com/ReleaseConfig\022aprojects/{project}/locations/" + + "{location}/repositories/{repository}/rel" + + "easeConfigs/{release_config}*\016releaseConfigs2\r" + "releaseConfigB\024\n" + "\022_internal_metadata\"\213\001\n" + "\031ListReleaseConfigsRequest\022;\n" + "\006parent\030\001 \001(\tB+\342A\001\002\372A$\n" + "\"dataform.googleapis.com/Repository\022\027\n" - + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n" + + "\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"\221\001\n" + "\032ListReleaseConfigsResponse\022E\n" - + "\017release_configs\030\001 \003(" - + "\0132,.google.cloud.dataform.v1beta1.ReleaseConfig\022\027\n" + + "\017release_configs\030\001 \003(\0132" + + ",.google.cloud.dataform.v1beta1.ReleaseConfig\022\027\n" + "\017next_page_token\030\002 \001(\t\022\023\n" + "\013unreachable\030\003 \003(\t\"W\n" + "\027GetReleaseConfigRequest\022<\n" @@ -1342,39 +1364,38 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016release_config\030\007 \001(\tB.\342A\001\005\372A\'\n" + "%dataform.googleapis.com/ReleaseConfigH\000\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\003\022[\n" - + "\027code_compilation_config\030\004 \001" - + "(\01324.google.cloud.dataform.v1beta1.CodeCompilationConfigB\004\342A\001\005\022%\n" + + "\027code_compilation_config\030\004 \001(\013" + + "24.google.cloud.dataform.v1beta1.CodeCompilationConfigB\004\342A\001\005\022%\n" + "\027resolved_git_commit_sha\030\010 \001(\tB\004\342A\001\003\022#\n" + "\025dataform_core_version\030\005 \001(\tB\004\342A\001\003\022c\n" - + "\022compilation_errors\030\006 \003(\0132A.google.cloud.dataform.v1beta1.C" - + "ompilationResult.CompilationErrorB\004\342A\001\003\022W\n" - + "\025data_encryption_state\030\t \001(\01322.google." - + "cloud.dataform.v1beta1.DataEncryptionStateB\004\342A\001\003\0225\n" + + "\022compilation_errors\030\006" + + " \003(\0132A.google.cloud.dataform.v1beta1.CompilationResult.CompilationErrorB\004\342A\001\003\022W\n" + + "\025data_encryption_state\030\t \001(\01322.google.cl" + + "oud.dataform.v1beta1.DataEncryptionStateB\004\342A\001\003\0225\n" + "\013create_time\030\n" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022$\n" + "\021internal_metadata\030\013 \001(\tB\004\342A\001\003H\001\210\001\001\022_\n" - + "\031private_resource_metadata\030\014 \001(\01326.google.cloud.dataform" - + ".v1beta1.PrivateResourceMetadataB\004\342A\001\003\022l\n" + + "\031private_resource_metadata\030\014" + + " \001(\01326.google.cloud.dataform.v1beta1.PrivateResourceMetadataB\004\342A\001\003\022l\n" + " gcs_repository_snapshot_metadata\030\r" - + " \001(\013" - + "2<.google.cloud.dataform.v1beta1.GcsRepositorySnapshotMetadataB\004\342A\001\003\032\226\001\n" + + " \001(\0132<" + + ".google.cloud.dataform.v1beta1.GcsRepositorySnapshotMetadataB\004\342A\001\003\032\226\001\n" + "\020CompilationError\022\025\n" + "\007message\030\001 \001(\tB\004\342A\001\003\022\023\n" + "\005stack\030\002 \001(\tB\004\342A\001\003\022\022\n" + "\004path\030\003 \001(\tB\004\342A\001\003\022B\n\r" + "action_target\030\004" + " \001(\0132%.google.cloud.dataform.v1beta1.TargetB\004\342A\001\003:\301\001\352A\275\001\n" - + ")dataform.googleapis.com/CompilationResult\022iproject" - + "s/{project}/locations/{location}/repositories/{repository}/compilationResults/{c" - + "ompilation_result}*\022compilationResults2\021compilationResultB\010\n" + + ")dataform.googleapis.com/CompilationResult\022iprojects/", + "{project}/locations/{location}/repositories/{repository}/compilationResults/{com" + + "pilation_result}*\022compilationResults2\021compilationResultB\010\n" + "\006sourceB\024\n" + "\022_internal_metadata\"\254\004\n" + "\025WorkflowTriggerConfig\022W\n" - + "\tcondition\030\001 \001(\0162>.google.cloud.dataform.v" - + "1beta1.WorkflowTriggerConfig.ConditionB\004\342A\001\001\022O\n" - + "\021workflow_triggers\030\002 \003(\0132..google" - + ".cloud.dataform.v1beta1.WorkflowTriggerB", - "\004\342A\001\002\022?\n" + + "\tcondition\030\001 \001(\0162>.google.cloud.dataform.v1b" + + "eta1.WorkflowTriggerConfig.ConditionB\004\342A\001\001\022O\n" + + "\021workflow_triggers\030\002 \003(\0132..google.c" + + "loud.dataform.v1beta1.WorkflowTriggerB\004\342A\001\002\022?\n" + "\026min_execution_duration\030\003" + " \001(\0132\031.google.protobuf.DurationB\004\342A\001\001\022:\n" + "\021max_wait_duration\030\004" @@ -1404,15 +1425,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016default_schema\030\002 \001(\tB\004\342A\001\001\022\036\n" + "\020default_location\030\010 \001(\tB\004\342A\001\001\022\036\n" + "\020assertion_schema\030\003 \001(\tB\004\342A\001\001\022R\n" - + "\004vars\030\004 \003(\0132>.go" - + "ogle.cloud.dataform.v1beta1.CodeCompilationConfig.VarsEntryB\004\342A\001\001\022\035\n" + + "\004vars\030\004 \003(\0132>.goog" + + "le.cloud.dataform.v1beta1.CodeCompilationConfig.VarsEntryB\004\342A\001\001\022\035\n" + "\017database_suffix\030\005 \001(\tB\004\342A\001\001\022\033\n\r" + "schema_suffix\030\006 \001(\tB\004\342A\001\001\022\032\n" + "\014table_prefix\030\007 \001(\tB\004\342A\001\001\022+\n" + "\035builtin_assertion_name_prefix\030\n" + " \001(\tB\004\342A\001\001\022e\n" - + " default_notebook_runtime_options\030\t \001(\013" - + "25.google.cloud.dataform.v1beta1.NotebookRuntimeOptionsB\004\342A\001\001\022L\n" + + " default_notebook_runtime_options\030\t \001(\01325" + + ".google.cloud.dataform.v1beta1.NotebookRuntimeOptionsB\004\342A\001\001\022L\n" + "\017pipeline_config\030\014" + " \001(\0132-.google.cloud.dataform.v1beta1.PipelineConfigB\004\342A\001\001\022\"\n" + "\017lineage_enabled\030\016 \001(\010B\004\342A\001\003H\000\210\001\001\032+\n" @@ -1428,15 +1449,16 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\027repository_snapshot_uri\030\001 \001(\tB\004\342A\001\001\"\315\002\n" + "\026NotebookRuntimeOptions\022!\n" + "\021gcs_output_bucket\030\001 \001(\tB\004\342A\001\001H\000\022t\n" - + "#gcs_repository_snapshot_destination\030\003 \001(\0132?.google" - + ".cloud.dataform.v1beta1.GcsRepositorySnapshotDestinationB\004\342A\001\001H\001\022i\n" + + "#gcs_repository_snapshot_destination\030\003 \001(\0132?.google.c" + + "loud.dataform.v1beta1.GcsRepositorySnapshotDestinationB\004\342A\001\001H\001\022i\n" + "%ai_platform_notebook_runtime_template\030\002 \001(\tB:\342A\001\001\372A3\n" + "1aiplatform.googleapis.com/NotebookRuntimeTemplateB\020\n" + "\016execution_sinkB\035\n" + "\033repository_snapshot_storage\"\321\001\n" - + "\016PipelineConfig\022W\n\r" - + "pipeline_type\030\001 \001(\0162:.google.cloud.da" - + "taform.v1beta1.PipelineConfig.PipelineTypeB\004\342A\001\002\022\022\n" + + "\016PipelineConfig\022W\n" + + "\r" + + "pipeline_type\030\001 \001(\0162:.google.cloud.data" + + "form.v1beta1.PipelineConfig.PipelineTypeB\004\342A\001\002\022\022\n" + "\004path\030\002 \001(\tB\004\342A\001\002\"R\n" + "\014PipelineType\022\035\n" + "\031PIPELINE_TYPE_UNSPECIFIED\020\000\022\014\n" @@ -1461,15 +1483,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\036CreateCompilationResultRequest\022;\n" + "\006parent\030\001 \001(\tB+\342A\001\002\372A$\n" + "\"dataform.googleapis.com/Repository\022R\n" - + "\022compilation_result\030\002" - + " \001(\01320.google.cloud.dataform.v1beta1.CompilationResultB\004\342A\001\002\"\367\002\n" + + "\022compilation_result\030\002 " + + "\001(\01320.google.cloud.dataform.v1beta1.CompilationResultB\004\342A\001\002\"\367\002\n" + "\037CreateCompilationResultMetadata\022\020\n" + "\002id\030\001 \001(\tB\004\342A\001\003\022\024\n" + "\006target\030\002 \001(\tB\004\342A\001\003\022Y\n" - + "\005state\030\003 \001(\0162D.googl" - + "e.cloud.dataform.v1beta1.CreateCompilationResultMetadata.StateB\004\342A\001\003\022n\n" - + "!create_compilation_result_request\030\004 \001(\0132=.google" - + ".cloud.dataform.v1beta1.CreateCompilationResultRequestB\004\342A\001\003\"a\n" + + "\005state\030\003 \001(\0162D.google." + + "cloud.dataform.v1beta1.CreateCompilationResultMetadata.StateB\004\342A\001\003\022n\n" + + "!create_compilation_result_request\030\004 \001(\0132=.google.c" + + "loud.dataform.v1beta1.CreateCompilationResultRequestB\004\342A\001\003\"a\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\013\n" + "\007CREATED\020\001\022\013\n" @@ -1483,10 +1505,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004name\030\003 \001(\tB\004\342A\001\001\"\352\002\n" + "\022RelationDescriptor\022\023\n" + "\013description\030\001 \001(\t\022S\n" - + "\007columns\030\002 \003(\0132B.google.cloud.dataform" - + ".v1beta1.RelationDescriptor.ColumnDescriptor\022^\n" - + "\017bigquery_labels\030\003 \003(\0132E.google.c" - + "loud.dataform.v1beta1.RelationDescriptor.BigqueryLabelsEntry\032S\n" + + "\007columns\030\002 \003(\0132B.google.cloud.dataform.v" + + "1beta1.RelationDescriptor.ColumnDescriptor\022^\n" + + "\017bigquery_labels\030\003 \003(\0132E.google.clo" + + "ud.dataform.v1beta1.RelationDescriptor.BigqueryLabelsEntry\032S\n" + "\020ColumnDescriptor\022\014\n" + "\004path\030\001 \003(\t\022\023\n" + "\013description\030\002 \001(\t\022\034\n" @@ -1497,18 +1519,18 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\027CompilationResultAction\022S\n" + "\010relation\030\004" + " \001(\0132?.google.cloud.dataform.v1beta1.CompilationResultAction.RelationH\000\022W\n\n" - + "operations\030\005 \001(\0132A.google.cloud.dataform.v1" - + "beta1.CompilationResultAction.OperationsH\000\022U\n" - + "\tassertion\030\006 \001(\0132@.google.cloud.dat" - + "aform.v1beta1.CompilationResultAction.AssertionH\000\022Y\n" - + "\013declaration\030\007 \001(\0132B.google." - + "cloud.dataform.v1beta1.CompilationResultAction.DeclarationH\000\022S\n" - + "\010notebook\030\010 \001(\0132?" - + ".google.cloud.dataform.v1beta1.CompilationResultAction.NotebookH\000\022b\n" - + "\020data_preparation\030\t \001(\0132F.google.cloud.dataform.v1be" - + "ta1.CompilationResultAction.DataPreparationH\000\022e\n" - + "\022bigquery_unit_test\030\013 \001(\0132G.goog" - + "le.cloud.dataform.v1beta1.CompilationResultAction.BigQueryUnitTestH\000\0225\n" + + "operations\030\005 \001(\0132A.google.cloud.dataform.v1be" + + "ta1.CompilationResultAction.OperationsH\000\022U\n" + + "\tassertion\030\006 \001(\0132@.google.cloud.dataf" + + "orm.v1beta1.CompilationResultAction.AssertionH\000\022Y\n" + + "\013declaration\030\007 \001(\0132B.google.cl" + + "oud.dataform.v1beta1.CompilationResultAction.DeclarationH\000\022S\n" + + "\010notebook\030\010 \001(\0132?.g" + + "oogle.cloud.dataform.v1beta1.CompilationResultAction.NotebookH\000\022b\n" + + "\020data_preparation\030\t \001(\0132F.google.cloud.dataform.v1beta" + + "1.CompilationResultAction.DataPreparationH\000\022e\n" + + "\022bigquery_unit_test\030\013 \001(\0132G.google" + + ".cloud.dataform.v1beta1.CompilationResultAction.BigQueryUnitTestH\000\0225\n" + "\006target\030\001 \001(\0132%.google.cloud.dataform.v1beta1.Target\022?\n" + "\020canonical_target\030\002" + " \001(\0132%.google.cloud.dataform.v1beta1.Target\022\021\n" @@ -1521,28 +1543,27 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010disabled\030\002 \001(\010\022\014\n" + "\004tags\030\003 \003(\t\022N\n" + "\023relation_descriptor\030\004" - + " \001(\01321.google.cloud.dataform.v1beta1.RelationDescriptor\022c\n" - + "\r" - + "relation_type\030\005 \001(\0162L.google.cloud.data" - + "form.v1beta1.CompilationResultAction.Relation.RelationType\022\024\n" + + " \001(\01321.google.cloud.dataform.v1beta1.RelationDescriptor\022c\n\r" + + "relation_type\030\005 \001(\0162L.google.cloud.datafo" + + "rm.v1beta1.CompilationResultAction.Relation.RelationType\022\024\n" + "\014select_query\030\006 \001(\t\022\026\n" + "\016pre_operations\030\007 \003(\t\022\027\n" + "\017post_operations\030\010 \003(\t\022x\n" - + "\030incremental_table_config\030\t \001(\0132V.google.cloud.dataform.v1beta1.Comp" - + "ilationResultAction.Relation.IncrementalTableConfig\022\034\n" + + "\030incremental_table_config\030\t \001(\0132V.google.cloud.dataform.v1beta1.Compil" + + "ationResultAction.Relation.IncrementalTableConfig\022\034\n" + "\024partition_expression\030\n" + " \001(\t\022\033\n" + "\023cluster_expressions\030\013 \003(\t\022!\n" + "\031partition_expiration_days\030\014 \001(\005\022 \n" + "\030require_partition_filter\030\r" + " \001(\010\022r\n" - + "\022additional_options\030\016 \003(\0132V.google.cloud.dataform.v1beta1." - + "CompilationResultAction.Relation.AdditionalOptionsEntry\022\030\n\n" + + "\022additional_options\030\016 \003(\0132V.google.cloud.dataform.v1beta1.Co" + + "mpilationResultAction.Relation.AdditionalOptionsEntry\022\030\n\n" + "connection\030\017 \001(\tB\004\342A\001\001\022g\n" - + "\014table_format\030\020 \001(\0162K.google.cloud.d" - + "ataform.v1beta1.CompilationResultAction.Relation.TableFormatB\004\342A\001\001\022e\n" - + "\013file_format\030\021 \001(\0162J.google.cloud.dataform.v1beta1." - + "CompilationResultAction.Relation.FileFormatB\004\342A\001\001\022\031\n" + + "\014table_format\030\020 \001(\0162K.google.cloud.dat" + + "aform.v1beta1.CompilationResultAction.Relation.TableFormatB\004\342A\001\001\022e\n" + + "\013file_format\030\021 \001(\0162J.google.cloud.dataform.v1beta1.Co" + + "mpilationResultAction.Relation.FileFormatB\004\342A\001\001\022\031\n" + "\013storage_uri\030\022 \001(\tB\004\342A\001\001\032\330\001\n" + "\026IncrementalTableConfig\022 \n" + "\030incremental_select_query\030\001 \001(\t\022\030\n" @@ -1571,8 +1592,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \003(\0132%.google.cloud.dataform.v1beta1.Target\022\020\n" + "\010disabled\030\002 \001(\010\022\014\n" + "\004tags\030\003 \003(\t\022N\n" - + "\023relation_descriptor\030\006" - + " \001(\01321.google.cloud.dataform.v1beta1.RelationDescriptor\022\017\n" + + "\023relation_descriptor\030\006 \001" + + "(\01321.google.cloud.dataform.v1beta1.RelationDescriptor\022\017\n" + "\007queries\030\004 \003(\t\022\022\n\n" + "has_output\030\005 \001(\010\032\222\002\n" + "\tAssertion\022A\n" @@ -1582,8 +1603,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010disabled\030\002 \001(\010\022\014\n" + "\004tags\030\003 \003(\t\022\024\n" + "\014select_query\030\004 \001(\t\022N\n" - + "\023relation_descriptor\030\006 \001(\01321" - + ".google.cloud.dataform.v1beta1.RelationDescriptor\032]\n" + + "\023relation_descriptor\030\006 \001(\01321.g" + + "oogle.cloud.dataform.v1beta1.RelationDescriptor\032]\n" + "\013Declaration\022N\n" + "\023relation_descriptor\030\001" + " \001(\01321.google.cloud.dataform.v1beta1.RelationDescriptor\032\177\n" @@ -1595,18 +1616,18 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004tags\030\004 \003(\t\032\300\004\n" + "\017DataPreparation\022\027\n\r" + "contents_yaml\030\005 \001(\tH\000\022l\n" - + "\014contents_sql\030\006 \001(\0132T.google.cloud.data" - + "form.v1beta1.CompilationResultAction.DataPreparation.SqlDefinitionH\000\022A\n" + + "\014contents_sql\030\006 \001(\0132T.google.cloud.datafo" + + "rm.v1beta1.CompilationResultAction.DataPreparation.SqlDefinitionH\000\022A\n" + "\022dependency_targets\030\001" + " \003(\0132%.google.cloud.dataform.v1beta1.Target\022\020\n" + "\010disabled\030\002 \001(\010\022\014\n" + "\004tags\030\004 \003(\t\032\327\001\n\r" + "SqlDefinition\022\r\n" + "\005query\030\001 \001(\t\022f\n" - + "\013error_table\030\002 \001(\0132Q.google.cloud.dat" - + "aform.v1beta1.CompilationResultAction.DataPreparation.ErrorTable\022O\n" - + "\004load\030\003 \001(\0132A" - + ".google.cloud.dataform.v1beta1.CompilationResultAction.LoadConfig\032[\n\n" + + "\013error_table\030\002 \001(\0132Q.google.cloud.dataf" + + "orm.v1beta1.CompilationResultAction.DataPreparation.ErrorTable\022O\n" + + "\004load\030\003 \001(\0132A.g" + + "oogle.cloud.dataform.v1beta1.CompilationResultAction.LoadConfig\032[\n\n" + "ErrorTable\0225\n" + "\006target\030\001 \001(\0132%.google.cloud.dataform.v1beta1.Target\022\026\n" + "\016retention_days\030\002 \001(\005B\014\n\n" @@ -1620,14 +1641,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "test_query\030\005 \001(\t\022\035\n" + "\025expected_output_query\030\006 \001(\t\032\204\003\n\n" + "LoadConfig\022X\n" - + "\007replace\030\001 \001(\0132E." - + "google.cloud.dataform.v1beta1.CompilationResultAction.SimpleLoadModeH\000\022W\n" - + "\006append\030\002 \001(\0132E.google.cloud.dataform.v1beta1.C" - + "ompilationResultAction.SimpleLoadModeH\000\022]\n" - + "\007maximum\030\003 \001(\0132J.google.cloud.dataform" - + ".v1beta1.CompilationResultAction.IncrementalLoadModeH\000\022\\\n" - + "\006unique\030\004 \001(\0132J.google." - + "cloud.dataform.v1beta1.CompilationResultAction.IncrementalLoadModeH\000B\006\n" + + "\007replace\030\001 \001(\0132E.go" + + "ogle.cloud.dataform.v1beta1.CompilationResultAction.SimpleLoadModeH\000\022W\n" + + "\006append\030\002" + + " \001(\0132E.google.cloud.dataform.v1beta1.CompilationResultAction.SimpleLoadModeH\000\022]\n" + + "\007maximum\030\003 \001(\0132J.google.cloud.dataform.v" + + "1beta1.CompilationResultAction.IncrementalLoadModeH\000\022\\\n" + + "\006unique\030\004 \001(\0132J.google.cl" + + "oud.dataform.v1beta1.CompilationResultAction.IncrementalLoadModeH\000B\006\n" + "\004mode\032\020\n" + "\016SimpleLoadMode\032%\n" + "\023IncrementalLoadMode\022\016\n" @@ -1641,8 +1662,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\"\234\001\n" + "%QueryCompilationResultActionsResponse\022Z\n" - + "\032compilation_result_actions\030\001 \003(\01326.googl" - + "e.cloud.dataform.v1beta1.CompilationResultAction\022\027\n" + + "\032compilation_result_actions\030\001 \003(\01326.google." + + "cloud.dataform.v1beta1.CompilationResultAction\022\027\n" + "\017next_page_token\030\002 \001(\t\"\237\010\n" + "\016WorkflowConfig\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022F\n" @@ -1652,9 +1673,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132/.google.cloud.dataform.v1beta1.InvocationConfigB\004\342A\001\001\022\033\n\r" + "cron_schedule\030\004 \001(\tB\004\342A\001\001\022\027\n" + "\ttime_zone\030\007 \001(\tB\004\342A\001\001\022x\n" - + "\"recent_scheduled_execution_records\030\005" - + " \003(\0132F.google.cloud.dataform.v1beta1.Wor" - + "kflowConfig.ScheduledExecutionRecordB\004\342A\001\003\022\026\n" + + "\"recent_scheduled_execution_records\030\005 \003" + + "(\0132F.google.cloud.dataform.v1beta1.Workf" + + "lowConfig.ScheduledExecutionRecordB\004\342A\001\003\022\026\n" + "\010disabled\030\010 \001(\010B\004\342A\001\001\0225\n" + "\013create_time\030\t" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" @@ -1670,9 +1691,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016execution_time\030\001" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003B\010\n" + "\006result:\262\001\352A\256\001\n" - + "&dataform.googleapis.com/WorkflowConfig\022cprojects/{project}/loca" - + "tions/{location}/repositories/{repositor" - + "y}/workflowConfigs/{workflow_config}*\017workflowConfigs2\016workflowConfigB\024\n" + + "&dataform.googleapis.com/WorkflowConfig\022cprojects/{project}/locati" + + "ons/{location}/repositories/{repository}" + + "/workflowConfigs/{workflow_config}*\017workflowConfigs2\016workflowConfigB\024\n" + "\022_internal_metadata\"\372\007\n" + "\020InvocationConfig\022E\n" + "\020included_targets\030\001" @@ -1683,14 +1704,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "(fully_refresh_incremental_tables_enabled\030\005" + " \001(\010B\004\342A\001\001\022\035\n" + "\017service_account\030\006 \001(\tB\004\342A\001\001\022o\n" - + "\024end_user_auth_config\030\007 \001(\0132K.google.cloud.d" - + "ataform.v1beta1.InvocationConfig.EndUserAuthenticationConfigB\004\342A\001\001\022`\n" - + "\016query_priority\030\t \001(\0162=.google.cloud.dataform.v1bet" - + "a1.InvocationConfig.QueryPriorityB\004\342A\001\001H\000\210\001\001\022+\n" + + "\024end_user_auth_config\030\007 \001(\0132K.google.cloud.dat" + + "aform.v1beta1.InvocationConfig.EndUserAuthenticationConfigB\004\342A\001\001\022`\n" + + "\016query_priority\030\t \001(\0162=.google.cloud.dataform.v1beta1" + + ".InvocationConfig.QueryPriorityB\004\342A\001\001H\000\210\001\001\022+\n" + "\030concurrent_actions_limit\030\n" + " \001(\005B\004\342A\001\001H\001\210\001\001\022[\n" - + "\016execution_mode\030\020 \001(\0162=.goog" - + "le.cloud.dataform.v1beta1.InvocationConfig.ExecutionModeB\004\342A\001\001\032\177\n" + + "\016execution_mode\030\020 \001(\0162=.google" + + ".cloud.dataform.v1beta1.InvocationConfig.ExecutionModeB\004\342A\001\001\032\177\n" + "\033EndUserAuthenticationConfig\022\030\n\n" + "user_email\030\002 \001(\tB\004\342A\001\003\022F\n" + "\014oauth_config\030\004" @@ -1712,8 +1733,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"\224\001\n" + "\033ListWorkflowConfigsResponse\022G\n" - + "\020workflow_configs\030\001 \003(\0132-.goog" - + "le.cloud.dataform.v1beta1.WorkflowConfig\022\027\n" + + "\020workflow_configs\030\001 \003(\0132-.google" + + ".cloud.dataform.v1beta1.WorkflowConfig\022\027\n" + "\017next_page_token\030\002 \001(\t\022\023\n" + "\013unreachable\030\003 \003(\t\"Y\n" + "\030GetWorkflowConfigRequest\022=\n" @@ -1739,10 +1760,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017workflow_config\030\006 \001(\tB/\342A\001\005\372A(\n" + "&dataform.googleapis.com/WorkflowConfigH\000\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\003\022P\n" - + "\021invocation_config\030\003 \001(\0132/.google.c" - + "loud.dataform.v1beta1.InvocationConfigB\004\342A\001\005\022L\n" - + "\005state\030\004 \001(\01627.google.cloud.dataf" - + "orm.v1beta1.WorkflowInvocation.StateB\004\342A\001\003\0226\n" + + "\021invocation_config\030\003 \001(\0132/.google.clo" + + "ud.dataform.v1beta1.InvocationConfigB\004\342A\001\005\022L\n" + + "\005state\030\004 \001(\01627.google.cloud.datafor" + + "m.v1beta1.WorkflowInvocation.StateB\004\342A\001\003\0226\n" + "\021invocation_timing\030\005" + " \001(\0132\025.google.type.IntervalB\004\342A\001\003\022W\n" + "\033resolved_compilation_result\030\007 \001(\tB2\342A\001\003\372A+\n" @@ -1751,10 +1772,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\01322.google.cloud.dataform.v1beta1.DataEncryptionStateB\004\342A\001\003\022$\n" + "\021internal_metadata\030\t \001(\tB\004\342A\001\003H\001\210\001\001\022_\n" + "\031private_resource_metadata\030\n" - + " \001(\01326.google.c" - + "loud.dataform.v1beta1.PrivateResourceMetadataB\004\342A\001\003\022L\n" - + "\017pipeline_config\030\013 \001(\0132-.g" - + "oogle.cloud.dataform.v1beta1.PipelineConfigB\004\342A\001\003\"d\n" + + " \001(\01326.google.clo" + + "ud.dataform.v1beta1.PrivateResourceMetadataB\004\342A\001\003\022L\n" + + "\017pipeline_config\030\013 \001(\0132-.goo" + + "gle.cloud.dataform.v1beta1.PipelineConfigB\004\342A\001\003\"d\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\013\n" + "\007RUNNING\020\001\022\r\n" @@ -1762,16 +1783,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tCANCELLED\020\003\022\n\n" + "\006FAILED\020\004\022\r\n" + "\tCANCELING\020\005:\306\001\352A\302\001\n" - + "*dataform.googleapis.com/WorkflowInvocation\022kprojects/{project}/locations/{locati" - + "on}/repositories/{repository}/workflowIn" - + "vocations/{workflow_invocation}*\023workflowInvocations2\022workflowInvocationB\024\n" + + "*dataform.googleapis.com/WorkflowInvocation\022kprojects/{project}/locations/{location" + + "}/repositories/{repository}/workflowInvo" + + "cations/{workflow_invocation}*\023workflowInvocations2\022workflowInvocationB\024\n" + "\022compilation_sourceB\024\n" + "\022_internal_metadata\"\276\001\n" + "\036ListWorkflowInvocationsRequest\022;\n" + "\006parent\030\001 \001(\tB+\342A\001\002\372A$\n" + "\"dataform.googleapis.com/Repository\022\027\n" - + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n" - + "\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\026\n" + "\010order_by\030\004 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\"\240\001\n" @@ -1796,20 +1816,20 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "*dataform.googleapis.com/WorkflowInvocation\"\"\n" + " CancelWorkflowInvocationResponse\"\223\024\n" + "\030WorkflowInvocationAction\022g\n" - + "\017bigquery_action\030\006 \001(\0132F.google.cloud.dataform.v1beta1" - + ".WorkflowInvocationAction.BigQueryActionB\004\342A\001\003H\000\022g\n" - + "\017notebook_action\030\010 \001(\0132F.goog" - + "le.cloud.dataform.v1beta1.WorkflowInvocationAction.NotebookActionB\004\342A\001\003H\000\022v\n" - + "\027data_preparation_action\030\t \001(\0132M.google.clou" - + "d.dataform.v1beta1.WorkflowInvocationAction.DataPreparationActionB\004\342A\001\003H\000\022y\n" - + "\031bigquery_unit_test_action\030\014 \001(\0132N.google.cl" - + "oud.dataform.v1beta1.WorkflowInvocationAction.BigQueryUnitTestActionB\004\342A\001\003H\000\022;\n" + + "\017bigquery_action\030\006 \001(\0132F.google.cloud.dataform.v1beta1.W" + + "orkflowInvocationAction.BigQueryActionB\004\342A\001\003H\000\022g\n" + + "\017notebook_action\030\010 \001(\0132F.google" + + ".cloud.dataform.v1beta1.WorkflowInvocationAction.NotebookActionB\004\342A\001\003H\000\022v\n" + + "\027data_preparation_action\030\t \001(\0132M.google.cloud." + + "dataform.v1beta1.WorkflowInvocationAction.DataPreparationActionB\004\342A\001\003H\000\022y\n" + + "\031bigquery_unit_test_action\030\014 \001(\0132N.google.clou" + + "d.dataform.v1beta1.WorkflowInvocationAction.BigQueryUnitTestActionB\004\342A\001\003H\000\022;\n" + "\006target\030\001" + " \001(\0132%.google.cloud.dataform.v1beta1.TargetB\004\342A\001\003\022E\n" - + "\020canonical_target\030\002 " - + "\001(\0132%.google.cloud.dataform.v1beta1.TargetB\004\342A\001\003\022R\n" - + "\005state\030\004 \001(\0162=.google.cloud.d" - + "ataform.v1beta1.WorkflowInvocationAction.StateB\004\342A\001\003\022\034\n" + + "\020canonical_target\030\002 \001(" + + "\0132%.google.cloud.dataform.v1beta1.TargetB\004\342A\001\003\022R\n" + + "\005state\030\004 \001(\0162=.google.cloud.dat" + + "aform.v1beta1.WorkflowInvocationAction.StateB\004\342A\001\003\022\034\n" + "\016failure_reason\030\007 \001(\tB\004\342A\001\003\0226\n" + "\021invocation_timing\030\005" + " \001(\0132\025.google.type.IntervalB\004\342A\001\003\022$\n" @@ -1822,32 +1842,30 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010contents\030\001 \001(\tB\004\342A\001\003\022\024\n" + "\006job_id\030\002 \001(\tB\004\342A\001\003\022\027\n" + "\tfile_path\030\003 \001(\tB\004\342A\001\003\032\254\t\n" - + "\025DataPreparationAction\022\035\n" - + "\r" + + "\025DataPreparationAction\022\035\n\r" + "contents_yaml\030\002 \001(\tB\004\342A\001\003H\000\022y\n" - + "\014contents_sql\030\006 \001(\0132a.google.cloud.dataform.v1bet" - + "a1.WorkflowInvocationAction.DataPreparationAction.ActionSqlDefinitionH\000\022\033\n\r" + + "\014contents_sql\030\006 \001(\0132a.google.cloud.dataform.v1beta1" + + ".WorkflowInvocationAction.DataPreparationAction.ActionSqlDefinitionH\000\022\033\n\r" + "generated_sql\030\003 \001(\tB\004\342A\001\003\022\024\n" + "\006job_id\030\004 \001(\tB\004\342A\001\003\032\216\002\n" + "\023ActionSqlDefinition\022\r\n" + "\005query\030\001 \001(\t\022s\n" - + "\013error_table\030\002 \001(\0132^.google.cloud.da" - + "taform.v1beta1.WorkflowInvocationAction.DataPreparationAction.ActionErrorTable\022s\n" - + "\013load_config\030\003 \001(\0132^.google.cloud.dataf" - + "orm.v1beta1.WorkflowInvocationAction.DataPreparationAction.ActionLoadConfig\032a\n" + + "\013error_table\030\002 \001(\0132^.google.cloud.data" + + "form.v1beta1.WorkflowInvocationAction.DataPreparationAction.ActionErrorTable\022s\n" + + "\013load_config\030\003 \001(\0132^.google.cloud.datafor" + + "m.v1beta1.WorkflowInvocationAction.DataPreparationAction.ActionLoadConfig\032a\n" + "\020ActionErrorTable\0225\n" + "\006target\030\001 \001(\0132%.google.cloud.dataform.v1beta1.Target\022\026\n" + "\016retention_days\030\002 \001(\005\032\376\003\n" + "\020ActionLoadConfig\022u\n" - + "\007replace\030\001 \001(\0132b.google.cloud.dataform.v1b" - + "eta1.WorkflowInvocationAction.DataPreparationAction.ActionSimpleLoadModeH\000\022t\n" - + "\006append\030\002 \001(\0132b.google.cloud.dataform.v1bet" - + "a1.WorkflowInvocationAction.DataPreparationAction.ActionSimpleLoadModeH\000\022z\n" - + "\007maximum\030\003 \001(\0132g.google.cloud.dataform.v1beta" - + "1.WorkflowInvocationAction.DataPreparationAction.ActionIncrementalLoadModeH\000\022y\n" - + "\006unique\030\004 \001(\0132g.google.cloud.dataform.v1b" - + "eta1.WorkflowInvocationAction.DataPrepar" - + "ationAction.ActionIncrementalLoadModeH\000B\006\n" + + "\007replace\030\001 \001(\0132b.google.cloud.dataform.v1bet" + + "a1.WorkflowInvocationAction.DataPreparationAction.ActionSimpleLoadModeH\000\022t\n" + + "\006append\030\002 \001(\0132b.google.cloud.dataform.v1beta1" + + ".WorkflowInvocationAction.DataPreparationAction.ActionSimpleLoadModeH\000\022z\n" + + "\007maximum\030\003 \001(\0132g.google.cloud.dataform.v1beta1." + + "WorkflowInvocationAction.DataPreparationAction.ActionIncrementalLoadModeH\000\022y\n" + + "\006unique\030\004 \001(\0132g.google.cloud.dataform.v1bet" + + "a1.WorkflowInvocationAction.DataPreparationAction.ActionIncrementalLoadModeH\000B\006\n" + "\004mode\032\026\n" + "\024ActionSimpleLoadMode\032+\n" + "\031ActionIncrementalLoadMode\022\016\n" @@ -1859,14 +1877,16 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\027expected_results_job_id\030\003 \001(\tB\004\342A\001\003\022)\n" + "\033expected_results_sql_script\030\004 \001(\tB\004\342A\001\003\022#\n" + "\025total_processed_bytes\030\005 \001(\003B\004\342A\001\003\022 \n" - + "\022total_billed_bytes\030\006 \001(\003B\004\342A\001\003\"r\n" + + "\022tota", + "l_billed_bytes\030\006 \001(\003B\004\342A\001\003\"r\n" + "\005State\022\013\n" + "\007PENDING\020\000\022\013\n" + "\007RUNNING\020\001\022\013\n" + "\007SKIPPED\020\002\022\014\n" + "\010DISABLED\020\003\022\r\n" + "\tSUCCEEDED\020\004\022\r\n" - + "\tCANCELLED\020\005\022\n\n" + + "\tCANCELLED\020\005\022\n" + + "\n" + "\006FAILED\020\006\022\n\n" + "\006QUEUED\020\007B\010\n" + "\006actionB\024\n" @@ -1876,8 +1896,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "*dataform.googleapis.com/WorkflowInvocation\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"\237\001\n" - + "&QueryWorkflowInvoca", - "tionActionsResponse\022\\\n" + + "&QueryWorkflowInvocationActionsResponse\022\\\n" + "\033workflow_invocation_actions\030\001" + " \003(\01327.google.cloud.dataform.v1beta1.WorkflowInvocationAction\022\027\n" + "\017next_page_token\030\002 \001(\t\"\210\002\n" @@ -1886,15 +1905,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\024default_kms_key_name\030\002 \001(\tB*\342A\001\001\372A#\n" + "!cloudkms.googleapis.com/CryptoKey\022$\n" + "\021internal_metadata\030\007 \001(\tB\004\342A\001\003H\000\210\001\001:d\352Aa\n" - + "\036dataform.googleapis.com/Config\022." - + "projects/{project}/locations/{location}/config*\007configs2\006configB\024\n" + + "\036dataform.googleapis.com/Config\022.pr" + + "ojects/{project}/locations/{location}/config*\007configs2\006configB\024\n" + "\022_internal_metadata\"I\n" + "\020GetConfigRequest\0225\n" + "\004name\030\001 \001(\tB\'\342A\001\002\372A \n" + "\036dataform.googleapis.com/Config\"\211\001\n" + "\023UpdateConfigRequest\022;\n" - + "\006config\030\001 \001(\013" - + "2%.google.cloud.dataform.v1beta1.ConfigB\004\342A\001\002\0225\n" + + "\006config\030\001 \001(\0132%" + + ".google.cloud.dataform.v1beta1.ConfigB\004\342A\001\002\0225\n" + "\013update_mask\030\002" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\"\327\003\n" + "\006Folder\022\022\n" @@ -1908,15 +1927,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022$\n" + "\021internal_metadata\030\007 \001(\tB\004\342A\001\003H\000\210\001\001\022(\n" + "\025creator_iam_principal\030\010 \001(\tB\004\342A\001\003H\001\210\001\001:n\352Ak\n" - + "\036dataform.googleapis.com/Folder\0228projects/{project}/location" - + "s/{location}/folders/{folder}*\007folders2\006folderB\024\n" + + "\036dataform.googleapis.com/Folder\0228projects/{project}/locations/" + + "{location}/folders/{folder}*\007folders2\006folderB\024\n" + "\022_internal_metadataB\030\n" + "\026_creator_iam_principal\"\245\001\n" + "\023CreateFolderRequest\022:\n" + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + "!locations.googleapis.com/Location\022;\n" - + "\006folder\030\002 \001(\0132%.goo" - + "gle.cloud.dataform.v1beta1.FolderB\004\342A\001\002\022\025\n" + + "\006folder\030\002" + + " \001(\0132%.google.cloud.dataform.v1beta1.FolderB\004\342A\001\002\022\025\n" + "\tfolder_id\030\003 \001(\tB\002\030\001\"\236\001\n" + "\021MoveFolderRequest\0225\n" + "\004name\030\001 \001(\tB\'\342A\001\002\372A \n" @@ -1930,8 +1949,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\023UpdateFolderRequest\0225\n" + "\013update_mask\030\001" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022;\n" - + "\006folder\030\002 \001(\0132%.goog" - + "le.cloud.dataform.v1beta1.FolderB\004\342A\001\002\"L\n" + + "\006folder\030\002" + + " \001(\0132%.google.cloud.dataform.v1beta1.FolderB\004\342A\001\002\"L\n" + "\023DeleteFolderRequest\0225\n" + "\004name\030\001 \001(\tB\'\342A\001\002\372A \n" + "\036dataform.googleapis.com/Folder\"e\n" @@ -1949,8 +1968,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010end_time\030\002" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022\024\n" + "\006target\030\003 \001(\tB\004\342A\001\003\022R\n" - + "\005state\030\004 \001(\0162=.google.cloud.d" - + "ataform.v1beta1.DeleteFolderTreeMetadata.StateB\004\342A\001\003\022\036\n" + + "\005state\030\004 \001(\0162=.google.cloud.dat" + + "aform.v1beta1.DeleteFolderTreeMetadata.StateB\004\342A\001\003\022\036\n" + "\020percent_complete\030\005 \001(\005B\004\342A\001\003\"[\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\017\n" @@ -1966,12 +1985,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010order_by\030\004 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\"\262\002\n" + "\033QueryFolderContentsResponse\022_\n" - + "\007entries\030\001 \003(\0132N.google.cloud.dataform.v1be" - + "ta1.QueryFolderContentsResponse.FolderContentsEntry\022\027\n" + + "\007entries\030\001 \003(\0132N.google.cloud.dataform.v1beta" + + "1.QueryFolderContentsResponse.FolderContentsEntry\022\027\n" + "\017next_page_token\030\002 \001(\t\032\230\001\n" + "\023FolderContentsEntry\0227\n" - + "\006folder\030\001 \001(\0132%.google.cloud.dataform.v1beta1.FolderH\000\022?\n" - + "\n" + + "\006folder\030\001 \001(\0132%.google.cloud.dataform.v1beta1.FolderH\000\022?\n\n" + "repository\030\002 \001(\0132).google.cloud.dataform.v1beta1.RepositoryH\000B\007\n" + "\005entry\"\275\001\n" + "\034QueryUserRootContentsRequest\022<\n" @@ -1982,8 +2000,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010order_by\030\004 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\"\262\002\n" + "\035QueryUserRootContentsResponse\022_\n" - + "\007entries\030\001 \003(\0132N.goo" - + "gle.cloud.dataform.v1beta1.QueryUserRootContentsResponse.RootContentsEntry\022\027\n" + + "\007entries\030\001 \003(\0132N.googl" + + "e.cloud.dataform.v1beta1.QueryUserRootContentsResponse.RootContentsEntry\022\027\n" + "\017next_page_token\030\002 \001(\t\032\226\001\n" + "\021RootContentsEntry\0227\n" + "\006folder\030\001 \001(\0132%.google.cloud.dataform.v1beta1.FolderH\000\022?\n\n" @@ -1999,16 +2017,16 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\021internal_metadata\030\005 \001(\tB\004\342A\001\003H\000\210\001\001\022(\n" + "\025creator_iam_principal\030\006 \001(" + "\tB\004\342A\001\003H\001\210\001\001:\204\001\352A\200\001\n" - + "\"dataform.googleapis.com/TeamFolder\022Aprojects/{" - + "project}/locations/{location}/teamFolders/{team_folder}*\013teamFolders2\n" + + "\"dataform.googleapis.com/TeamFolder\022Aprojects/{pr" + + "oject}/locations/{location}/teamFolders/{team_folder}*\013teamFolders2\n" + "teamFolderB\024\n" + "\022_internal_metadataB\030\n" + "\026_creator_iam_principal\"\267\001\n" + "\027CreateTeamFolderRequest\022:\n" + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + "!locations.googleapis.com/Location\022D\n" - + "\013team_folder\030\002 \001(\0132)." - + "google.cloud.dataform.v1beta1.TeamFolderB\004\342A\001\002\022\032\n" + + "\013team_folder\030\002 \001(\0132).go" + + "ogle.cloud.dataform.v1beta1.TeamFolderB\004\342A\001\002\022\032\n" + "\016team_folder_id\030\003 \001(\tB\002\030\001\"Q\n" + "\024GetTeamFolderRequest\0229\n" + "\004name\030\001 \001(\tB+\342A\001\002\372A$\n" @@ -2029,8 +2047,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010order_by\030\004 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\"\302\002\n" + "\037QueryTeamFolderContentsResponse\022g\n" - + "\007entries\030\001 \003(\0132V.google.cloud.dataform.v1beta1." - + "QueryTeamFolderContentsResponse.TeamFolderContentsEntry\022\027\n" + + "\007entries\030\001 \003(\0132V.google.cloud.dataform.v1beta1.Qu" + + "eryTeamFolderContentsResponse.TeamFolderContentsEntry\022\027\n" + "\017next_page_token\030\002 \001(\t\032\234\001\n" + "\027TeamFolderContentsEntry\0227\n" + "\006folder\030\001 \001(\0132%.google.cloud.dataform.v1beta1.FolderH\000\022?\n\n" @@ -2044,8 +2062,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010order_by\030\004 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\"\373\001\n" + "\031SearchTeamFoldersResponse\022`\n" - + "\007results\030\001 \003(\0132O.goo" - + "gle.cloud.dataform.v1beta1.SearchTeamFoldersResponse.TeamFolderSearchResult\022\027\n" + + "\007results\030\001 \003(\0132O.googl" + + "e.cloud.dataform.v1beta1.SearchTeamFoldersResponse.TeamFolderSearchResult\022\027\n" + "\017next_page_token\030\002 \001(\t\032c\n" + "\026TeamFolderSearchResult\022@\n" + "\013team_folder\030\002" @@ -2072,8 +2090,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010end_time\030\002" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022\024\n" + "\006target\030\003 \001(\tB\004\342A\001\003\022J\n" - + "\005state\030\004 \001(\0162;.goog" - + "le.cloud.dataform.v1beta1.MoveRepositoryMetadata.State\022\030\n" + + "\005state\030\004 \001(\0162;.google" + + ".cloud.dataform.v1beta1.MoveRepositoryMetadata.State\022\030\n" + "\020percent_complete\030\005 \001(\005\"Y\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\017\n" @@ -2087,8 +2105,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010end_time\030\002 \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022;\n" + "\006target\030\003 \001(\tB+\342A\001\003\372A$\n" + "\"dataform.googleapis.com/Repository\022]\n" - + "\005state\030\004 \001(\0162H.goo" - + "gle.cloud.dataform.v1beta1.DeleteRepositoryLongRunningMetadata.StateB\004\342A\001\003\022\036\n" + + "\005state\030\004 \001(\0162H.googl" + + "e.cloud.dataform.v1beta1.DeleteRepositoryLongRunningMetadata.StateB\004\342A\001\003\022\036\n" + "\020percent_complete\030\005 \001(\005B\004\342A\001\003\022#\n" + "\025child_resources_count\030\006 \001(\003B\004\342A\001\003\022-\n" + "\037remaining_child_resources_count\030\007 \001(\003B\004\342A\001\003\"F\n" @@ -2100,8 +2118,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\035FetchWorkspaceBranchesRequest\0228\n" + "\004name\030\001 \001(\tB*\342A\001\002\372A#\n" + "!dataform.googleapis.com/Workspace\022_\n" - + "\006filter\030\002 \001(\0162I.google.cloud.dataform.v1bet" - + "a1.FetchWorkspaceBranchesRequest.BranchFilterB\004\342A\001\001\022\027\n" + + "\006filter\030\002 \001(\0162I.google.cloud.dataform.v1beta1" + + ".FetchWorkspaceBranchesRequest.BranchFilterB\004\342A\001\001\022\027\n" + "\tpage_size\030\003 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\004 \001(\tB\004\342A\001\001\"W\n" + "\014BranchFilter\022\035\n" @@ -2124,468 +2142,478 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\025DirectoryContentsView\022\'\n" + "#DIRECTORY_CONTENTS_VIEW_UNSPECIFIED\020\000\022!\n" + "\035DIRECTORY_CONTENTS_VIEW_BASIC\020\001\022$\n" - + " DIRECTORY_CONTENTS_VIEW_METADATA\020\0022\370\225\001\n" + + " DIRECTORY_CONTENTS_VIEW_METADATA\020\0022\236\230\001\n" + "\010Dataform\022\264\001\n\r" - + "GetTeamFolder\0223.google.cloud.dataform.v1beta1.GetTeamFolderRequ" - + "est\032).google.cloud.dataform.v1beta1.Team" - + "Folder\"C\332A\004name\202\323\344\223\0026\0224/v1beta1/{name=projects/*/locations/*/teamFolders/*}\022\325\001\n" - + "\020CreateTeamFolder\0226.google.cloud.dataform" - + ".v1beta1.CreateTeamFolderRequest\032).googl" - + "e.cloud.dataform.v1beta1.TeamFolder\"^\332A\022" - + "parent,team_folder\202\323\344\223\002C\"4/v1beta1/{pare" - + "nt=projects/*/locations/*}/teamFolders:\013team_folder\022\346\001\n" - + "\020UpdateTeamFolder\0226.google.cloud.dataform.v1beta1.UpdateTeamFolde" - + "rRequest\032).google.cloud.dataform.v1beta1" - + ".TeamFolder\"o\332A\027team_folder,update_mask\202" - + "\323\344\223\002O2@/v1beta1/{team_folder.name=projec" - + "ts/*/locations/*/teamFolders/*}:\013team_folder\022\247\001\n" - + "\020DeleteTeamFolder\0226.google.cloud.dataform.v1beta1.DeleteTeamFolderReques" - + "t\032\026.google.protobuf.Empty\"C\332A\004name\202\323\344\223\0026" - + "*4/v1beta1/{name=projects/*/locations/*/teamFolders/*}\022\377\001\n" - + "\024DeleteTeamFolderTree\022:.google.cloud.dataform.v1beta1.DeleteTe" - + "amFolderTreeRequest\032\035.google.longrunning.Operation\"\213\001\312A1\n" + + "GetTeamFolder\0223.google.cloud.dataform.v1beta1.GetTeamFolderReques" + + "t\032).google.cloud.dataform.v1beta1.TeamFo" + + "lder\"C\332A\004name\202\323\344\223\0026\0224/v1beta1/{name=projects/*/locations/*/teamFolders/*}\022\325\001\n" + + "\020CreateTeamFolder\0226.google.cloud.dataform.v" + + "1beta1.CreateTeamFolderRequest\032).google." + + "cloud.dataform.v1beta1.TeamFolder\"^\332A\022pa" + + "rent,team_folder\202\323\344\223\002C\"4/v1beta1/{parent" + + "=projects/*/locations/*}/teamFolders:\013team_folder\022\346\001\n" + + "\020UpdateTeamFolder\0226.google.cloud.dataform.v1beta1.UpdateTeamFolderR" + + "equest\032).google.cloud.dataform.v1beta1.T" + + "eamFolder\"o\332A\027team_folder,update_mask\202\323\344" + + "\223\002O2@/v1beta1/{team_folder.name=projects" + + "/*/locations/*/teamFolders/*}:\013team_folder\022\247\001\n" + + "\020DeleteTeamFolder\0226.google.cloud.dataform.v1beta1.DeleteTeamFolderRequest\032" + + "\026.google.protobuf.Empty\"C\332A\004name\202\323\344\223\0026*4" + + "/v1beta1/{name=projects/*/locations/*/teamFolders/*}\022\377\001\n" + + "\024DeleteTeamFolderTree\022:.google.cloud.dataform.v1beta1.DeleteTeam" + + "FolderTreeRequest\032\035.google.longrunning.Operation\"\213\001\312A1\n" + "\025google.protobuf.Empty\022\030DeleteFolderTreeMetadata\332A\n" - + "name,force\202\323" - + "\344\223\002D\"?/v1beta1/{name=projects/*/locations/*/teamFolders/*}:deleteTree:\001*\022\371\001\n" - + "\027QueryTeamFolderContents\022=.google.cloud.data" - + "form.v1beta1.QueryTeamFolderContentsRequest\032>.google.cloud.dataform.v1beta1.Quer" - + "yTeamFolderContentsResponse\"_\332A\013team_fol" - + "der\202\323\344\223\002K\022I/v1beta1/{team_folder=project" - + "s/*/locations/*/teamFolders/*}:queryContents\022\315\001\n" - + "\021SearchTeamFolders\0227.google.cloud.dataform.v1beta1.SearchTeamFoldersRequ" - + "est\0328.google.cloud.dataform.v1beta1.Sear" - + "chTeamFoldersResponse\"E\202\323\344\223\002?\022=/v1beta1/" - + "{location=projects/*/locations/*}/teamFolders:search\022\244\001\n" - + "\tGetFolder\022/.google.cloud.dataform.v1beta1.GetFolderRequest\032%.go" - + "ogle.cloud.dataform.v1beta1.Folder\"?\332A\004n" - + "ame\202\323\344\223\0022\0220/v1beta1/{name=projects/*/locations/*/folders/*}\022\273\001\n" - + "\014CreateFolder\0222.google.cloud.dataform.v1beta1.CreateFolde" - + "rRequest\032%.google.cloud.dataform.v1beta1.Folder\"P\332A\r" - + "parent,folder\202\323\344\223\002:\"0/v1beta" - + "1/{parent=projects/*/locations/*}/folders:\006folder\022\307\001\n" - + "\014UpdateFolder\0222.google.cloud.dataform.v1beta1.UpdateFolderRequest\032%" - + ".google.cloud.dataform.v1beta1.Folder\"\\\332" - + "A\022folder,update_mask\202\323\344\223\002A27/v1beta1/{fo" - + "lder.name=projects/*/locations/*/folders/*}:\006folder\022\233\001\n" - + "\014DeleteFolder\0222.google.cloud.dataform.v1beta1.DeleteFolderRequest" - + "\032\026.google.protobuf.Empty\"?\332A\004name\202\323\344\223\0022*" - + "0/v1beta1/{name=projects/*/locations/*/folders/*}\022\363\001\n" - + "\020DeleteFolderTree\0226.google.cloud.dataform.v1beta1.DeleteFolderTreeR" - + "equest\032\035.google.longrunning.Operation\"\207\001\312A1\n" + + "name,force\202\323\344\223" + + "\002D\"?/v1beta1/{name=projects/*/locations/*/teamFolders/*}:deleteTree:\001*\022\371\001\n" + + "\027QueryTeamFolderContents\022=.google.cloud.datafo" + + "rm.v1beta1.QueryTeamFolderContentsRequest\032>.google.cloud.dataform.v1beta1.QueryT" + + "eamFolderContentsResponse\"_\332A\013team_folde" + + "r\202\323\344\223\002K\022I/v1beta1/{team_folder=projects/" + + "*/locations/*/teamFolders/*}:queryContents\022\315\001\n" + + "\021SearchTeamFolders\0227.google.cloud.dataform.v1beta1.SearchTeamFoldersReques" + + "t\0328.google.cloud.dataform.v1beta1.Search" + + "TeamFoldersResponse\"E\202\323\344\223\002?\022=/v1beta1/{l" + + "ocation=projects/*/locations/*}/teamFolders:search\022\244\001\n" + + "\tGetFolder\022/.google.cloud.dataform.v1beta1.GetFolderRequest\032%.goog" + + "le.cloud.dataform.v1beta1.Folder\"?\332A\004nam" + + "e\202\323\344\223\0022\0220/v1beta1/{name=projects/*/locations/*/folders/*}\022\273\001\n" + + "\014CreateFolder\0222.google.cloud.dataform.v1beta1.CreateFolderR" + + "equest\032%.google.cloud.dataform.v1beta1.Folder\"P\332A\r" + + "parent,folder\202\323\344\223\002:\"0/v1beta1/" + + "{parent=projects/*/locations/*}/folders:\006folder\022\307\001\n" + + "\014UpdateFolder\0222.google.cloud.dataform.v1beta1.UpdateFolderRequest\032%.g" + + "oogle.cloud.dataform.v1beta1.Folder\"\\\332A\022" + + "folder,update_mask\202\323\344\223\002A27/v1beta1/{fold" + + "er.name=projects/*/locations/*/folders/*}:\006folder\022\233\001\n" + + "\014DeleteFolder\0222.google.cloud.dataform.v1beta1.DeleteFolderRequest\032\026" + + ".google.protobuf.Empty\"?\332A\004name\202\323\344\223\0022*0/" + + "v1beta1/{name=projects/*/locations/*/folders/*}\022\363\001\n" + + "\020DeleteFolderTree\0226.google.cloud.dataform.v1beta1.DeleteFolderTreeReq" + + "uest\032\035.google.longrunning.Operation\"\207\001\312A1\n" + "\025google.protobuf.Empty\022\030DeleteFolderTreeMetadata\332A\n" - + "name,force\202\323\344\223\002@\";/v1beta" - + "1/{name=projects/*/locations/*/folders/*}:deleteTree:\001*\022\345\001\n" - + "\023QueryFolderContents\0229.google.cloud.dataform.v1beta1.QueryFol" - + "derContentsRequest\032:.google.cloud.dataform.v1beta1.QueryFolderContentsResponse\"W" - + "\332A\006folder\202\323\344\223\002H\022F/v1beta1/{folder=projec" - + "ts/*/locations/*/folders/*}:queryFolderContents\022\347\001\n" - + "\025QueryUserRootContents\022;.google.cloud.dataform.v1beta1.QueryUserRootC" - + "ontentsRequest\032<.google.cloud.dataform.v" - + "1beta1.QueryUserRootContentsResponse\"S\332A" - + "\010location\202\323\344\223\002B\022@/v1beta1/{location=proj" - + "ects/*/locations/*}:queryUserRootContents\022\363\001\n\n" - + "MoveFolder\0220.google.cloud.dataform" - + ".v1beta1.MoveFolderRequest\032\035.google.longrunning.Operation\"\223\001\312A+\n" - + "\025google.protobuf.Empty\022\022MoveFolderMetadata\332A\"name,destin" - + "ation_containing_folder\202\323\344\223\002:\"5/v1beta1/" - + "{name=projects/*/locations/*/folders/*}:move:\001*\022\313\001\n" - + "\020ListRepositories\0226.google.cloud.dataform.v1beta1.ListRepositoriesReq" - + "uest\0327.google.cloud.dataform.v1beta1.Lis" - + "tRepositoriesResponse\"F\332A\006parent\202\323\344\223\0027\0225" - + "/v1beta1/{parent=projects/*/locations/*}/repositories\022\265\001\n\r" - + "GetRepository\0223.google.cloud.dataform.v1beta1.GetRepositoryReq" - + "uest\032).google.cloud.dataform.v1beta1.Rep" - + "ository\"D\332A\004name\202\323\344\223\0027\0225/v1beta1/{name=p" - + "rojects/*/locations/*/repositories/*}\022\342\001\n" - + "\020CreateRepository\0226.google.cloud.datafo" - + "rm.v1beta1.CreateRepositoryRequest\032).goo" - + "gle.cloud.dataform.v1beta1.Repository\"k\332" - + "A\037parent,repository,repository_id\202\323\344\223\002C\"" - + "5/v1beta1/{parent=projects/*/locations/*}/repositories:\n" + + "name,force\202\323\344\223\002@\";/v1beta1/" + + "{name=projects/*/locations/*/folders/*}:deleteTree:\001*\022\345\001\n" + + "\023QueryFolderContents\0229.google.cloud.dataform.v1beta1.QueryFolde" + + "rContentsRequest\032:.google.cloud.dataform" + + ".v1beta1.QueryFolderContentsResponse\"W\332A" + + "\006folder\202\323\344\223\002H\022F/v1beta1/{folder=projects" + + "/*/locations/*/folders/*}:queryFolderContents\022\347\001\n" + + "\025QueryUserRootContents\022;.google.cloud.dataform.v1beta1.QueryUserRootCon" + + "tentsRequest\032<.google.cloud.dataform.v1b" + + "eta1.QueryUserRootContentsResponse\"S\332A\010l" + + "ocation\202\323\344\223\002B\022@/v1beta1/{location=projec" + + "ts/*/locations/*}:queryUserRootContents\022\363\001\n\n" + + "MoveFolder\0220.google.cloud.dataform.v" + + "1beta1.MoveFolderRequest\032\035.google.longrunning.Operation\"\223\001\312A+\n" + + "\025google.protobuf.Empty\022\022MoveFolderMetadata\332A\"name,destinat" + + "ion_containing_folder\202\323\344\223\002:\"5/v1beta1/{n" + + "ame=projects/*/locations/*/folders/*}:move:\001*\022\313\001\n" + + "\020ListRepositories\0226.google.cloud.dataform.v1beta1.ListRepositoriesReque" + + "st\0327.google.cloud.dataform.v1beta1.ListR" + + "epositoriesResponse\"F\332A\006parent\202\323\344\223\0027\0225/v" + + "1beta1/{parent=projects/*/locations/*}/repositories\022\265\001\n\r" + + "GetRepository\0223.google.cloud.dataform.v1beta1.GetRepositoryReque" + + "st\032).google.cloud.dataform.v1beta1.Repos" + + "itory\"D\332A\004name\202\323\344\223\0027\0225/v1beta1/{name=projects/*/locations/*/repositories/*}\022\342\001\n" + + "\020CreateRepository\0226.google.cloud.dataform" + + ".v1beta1.CreateRepositoryRequest\032).googl" + + "e.cloud.dataform.v1beta1.Repository\"k\332A\037" + + "parent,repository,repository_id\202\323\344\223\002C\"5/" + + "v1beta1/{parent=projects/*/locations/*}/repositories:\n" + "repository\022\344\001\n" - + "\020UpdateRepository\0226.google.cloud.dataform.v1beta1." - + "UpdateRepositoryRequest\032).google.cloud.d" - + "ataform.v1beta1.Repository\"m\332A\026repositor" - + "y,update_mask\202\323\344\223\002N2@/v1beta1/{repositor" - + "y.name=projects/*/locations/*/repositories/*}:\n" + + "\020UpdateRepository\0226.google.cloud.dataform.v1beta1.Up" + + "dateRepositoryRequest\032).google.cloud.dat" + + "aform.v1beta1.Repository\"m\332A\026repository," + + "update_mask\202\323\344\223\002N2@/v1beta1/{repository." + + "name=projects/*/locations/*/repositories/*}:\n" + "repository\022\250\001\n" - + "\020DeleteRepository\0226.google.cloud.dataform.v1beta1.DeleteRep" - + "ositoryRequest\032\026.google.protobuf.Empty\"D" - + "\332A\004name\202\323\344\223\0027*5/v1beta1/{name=projects/*/locations/*/repositories/*}\022\256\002\n" - + "\033DeleteRepositoryLongRunning\022A.google.cloud.data" - + "form.v1beta1.DeleteRepositoryLongRunning" - + "Request\032\035.google.longrunning.Operation\"\254\001\312AJ\n" + + "\020DeleteRepository\0226.google.cloud.dataform.v1beta1.DeleteRepos" + + "itoryRequest\032\026.google.protobuf.Empty\"D\332A" + + "\004name\202\323\344\223\0027*5/v1beta1/{name=projects/*/locations/*/repositories/*}\022\256\002\n" + + "\033DeleteRepositoryLongRunning\022A.google.cloud.datafo" + + "rm.v1beta1.DeleteRepositoryLongRunningRe" + + "quest\032\035.google.longrunning.Operation\"\254\001\312AJ\n" + "#DeleteRepositoryLongRunningResponse\022#DeleteRepositoryLongRunningMetadata\332A\n" - + "name,force\202\323\344\223\002L\"G/v1beta1/{name=projec" - + "ts/*/locations/*/repositories/*}:deleteLongRunning:\001*\022\204\002\n" - + "\016MoveRepository\0224.google.cloud.dataform.v1beta1.MoveRepositoryR" - + "equest\032\035.google.longrunning.Operation\"\234\001\312A/\n" - + "\025google.protobuf.Empty\022\026MoveReposito" - + "ryMetadata\332A\"name,destination_containing" - + "_folder\202\323\344\223\002?\":/v1beta1/{name=projects/*/locations/*/repositories/*}:move:\001*\022\341\001\n" - + "\027CommitRepositoryChanges\022=.google.cloud.dataform.v1beta1.CommitRepositoryChanges" - + "Request\032>.google.cloud.dataform.v1beta1." - + "CommitRepositoryChangesResponse\"G\202\323\344\223\002A\"" - + "/v1beta1/{name=projects/*/locations/*/repositories/*}:readFile\022\211\002\n" - + " QueryRepositoryDirectoryContents\022F.google.cloud.dataform.v1beta1.QueryRepositor" - + "yDirectoryContentsRequest\032G.google.cloud.dataform.v1beta1.QueryRepositoryDirecto" - + "ryContentsResponse\"T\202\323\344\223\002N\022L/v1beta1/{na" - + "me=projects/*/locations/*/repositories/*}:queryDirectoryContents\022\341\001\n" - + "\026FetchRepositoryHistory\022<.google.cloud.dataform.v1be" - + "ta1.FetchRepositoryHistoryRequest\032=.google.cloud.dataform.v1beta1.FetchRepositor" - + "yHistoryResponse\"J\202\323\344\223\002D\022B/v1beta1/{name" - + "=projects/*/locations/*/repositories/*}:fetchHistory\022\221\002\n" - + "\"ComputeRepositoryAccessTokenStatus\022H.google.cloud.dataform.v1be" - + "ta1.ComputeRepositoryAccessTokenStatusRequest\032I.google.cloud.dataform.v1beta1.Co" - + "mputeRepositoryAccessTokenStatusResponse" - + "\"V\202\323\344\223\002P\022N/v1beta1/{name=projects/*/loca" - + "tions/*/repositories/*}:computeAccessTokenStatus\022\337\001\n" - + "\023FetchRemoteBranches\0229.google.cloud.dataform.v1beta1.FetchRemoteBran" - + "chesRequest\032:.google.cloud.dataform.v1be" - + "ta1.FetchRemoteBranchesResponse\"Q\202\323\344\223\002K\022" - + "I/v1beta1/{name=projects/*/locations/*/repositories/*}:fetchRemoteBranches\022\322\001\n" - + "\016ListWorkspaces\0224.google.cloud.dataform.v1" - + "beta1.ListWorkspacesRequest\0325.google.cloud.dataform.v1beta1.ListWorkspacesRespon" - + "se\"S\332A\006parent\202\323\344\223\002D\022B/v1beta1/{parent=pr" - + "ojects/*/locations/*/repositories/*}/workspaces\022\277\001\n" - + "\014GetWorkspace\0222.google.cloud.dataform.v1beta1.GetWorkspaceRequest\032(.g" - + "oogle.cloud.dataform.v1beta1.Workspace\"Q" - + "\332A\004name\202\323\344\223\002D\022B/v1beta1/{name=projects/*" - + "/locations/*/repositories/*/workspaces/*}\022\351\001\n" - + "\017CreateWorkspace\0225.google.cloud.dataform.v1beta1.CreateWorkspaceRequest\032(.g" - + "oogle.cloud.dataform.v1beta1.Workspace\"u" - + "\332A\035parent,workspace,workspace_id\202\323\344\223\002O\"B" - + "/v1beta1/{parent=projects/*/locations/*/repositories/*}/workspaces:" + + "name,force\202\323\344\223\002L\"G/v1beta1/{name=projects" + + "/*/locations/*/repositories/*}:deleteLongRunning:\001*\022\204\002\n" + + "\016MoveRepository\0224.google.cloud.dataform.v1beta1.MoveRepositoryReq" + + "uest\032\035.google.longrunning.Operation\"\234\001\312A/\n" + + "\025google.protobuf.Empty\022\026MoveRepository" + + "Metadata\332A\"name,destination_containing_f" + + "older\202\323\344\223\002?\":/v1beta1/{name=projects/*/locations/*/repositories/*}:move:\001*\022\341\001\n" + + "\027CommitRepositoryChanges\022=.google.cloud.da" + + "taform.v1beta1.CommitRepositoryChangesRequest\032>.google.cloud.dataform.v1beta1.Co" + + "mmitRepositoryChangesResponse\"G\202\323\344\223\002A\"/v1beta1/{name=projects/*/locations/*/repositories/*}:readFile\022\211\002\n" + + " QueryRepositoryDirectoryContents\022F.google.cloud.dataform.v1beta1.QueryRepositoryD" + + "irectoryContentsRequest\032G.google.cloud.dataform.v1beta1.QueryRepositoryDirectory" + + "ContentsResponse\"T\202\323\344\223\002N\022L/v1beta1/{name" + + "=projects/*/locations/*/repositories/*}:queryDirectoryContents\022\341\001\n" + + "\026FetchRepositoryHistory\022<.google.cloud.dataform.v1beta" + + "1.FetchRepositoryHistoryRequest\032=.google.cloud.dataform.v1beta1.FetchRepositoryH" + + "istoryResponse\"J\202\323\344\223\002D\022B/v1beta1/{name=p" + + "rojects/*/locations/*/repositories/*}:fetchHistory\022\221\002\n" + + "\"ComputeRepositoryAccessTokenStatus\022H.google.cloud.dataform.v1beta" + + "1.ComputeRepositoryAccessTokenStatusRequest\032I.google.cloud.dataform.v1beta1.Comp" + + "uteRepositoryAccessTokenStatusResponse\"V" + + "\202\323\344\223\002P\022N/v1beta1/{name=projects/*/locati" + + "ons/*/repositories/*}:computeAccessTokenStatus\022\337\001\n" + + "\023FetchRemoteBranches\0229.google.cloud.dataform.v1beta1.FetchRemoteBranch" + + "esRequest\032:.google.cloud.dataform.v1beta" + + "1.FetchRemoteBranchesResponse\"Q\202\323\344\223\002K\022I/" + + "v1beta1/{name=projects/*/locations/*/repositories/*}:fetchRemoteBranches\022\322\001\n" + + "\016ListWorkspaces\0224.google.cloud.dataform.v1be" + + "ta1.ListWorkspacesRequest\0325.google.cloud.dataform.v1beta1.ListWorkspacesResponse" + + "\"S\332A\006parent\202\323\344\223\002D\022B/v1beta1/{parent=proj" + + "ects/*/locations/*/repositories/*}/workspaces\022\277\001\n" + + "\014GetWorkspace\0222.google.cloud.dataform.v1beta1.GetWorkspaceRequest\032(.goo" + + "gle.cloud.dataform.v1beta1.Workspace\"Q\332A" + + "\004name\202\323\344\223\002D\022B/v1beta1/{name=projects/*/l" + + "ocations/*/repositories/*/workspaces/*}\022\351\001\n" + + "\017CreateWorkspace\0225.google.cloud.dataform.v1beta1.CreateWorkspaceRequest\032(.goo" + + "gle.cloud.dataform.v1beta1.Workspace\"u\332A" + + "\035parent,workspace,workspace_id\202\323\344\223\002O\"B/v" + + "1beta1/{parent=projects/*/locations/*/repositories/*}/workspaces:" + + "\tworkspace\022\243\002\n" + + "\032CreateWorkspaceLongRunning\0225.google.clou" + + "d.dataform.v1beta1.CreateWorkspaceRequest\032\035.google.longrunning.Operation\"\256\001\312A$\n" + + "\tWorkspace\022\027CreateWorkspaceMetadata\332A\035par" + + "ent,workspace,workspace_id\202\323\344\223\002a\"T/v1bet" + + "a1/{parent=projects/*/locations/*/repositories/*}/workspaces:createLongRunning:" + "\tworkspace\022\263\001\n" - + "\017DeleteWorkspace\0225.google.cloud.datafor" - + "m.v1beta1.DeleteWorkspaceRequest\032\026.googl" - + "e.protobuf.Empty\"Q\332A\004name\202\323\344\223\002D*B/v1beta" - + "1/{name=projects/*/locations/*/repositories/*/workspaces/*}\022\360\001\n" - + "\022InstallNpmPackages\0228.google.cloud.dataform.v1beta1.Insta" - + "llNpmPackagesRequest\0329.google.cloud.dataform.v1beta1.InstallNpmPackagesResponse\"" - + "e\202\323\344\223\002_\"Z/v1beta1/{workspace=projects/*/" - + "locations/*/repositories/*/workspaces/*}:installNpmPackages:\001*\022\321\001\n" - + "\016PullGitCommits\0224.google.cloud.dataform.v1beta1.PullGi" - + "tCommitsRequest\0325.google.cloud.dataform." - + "v1beta1.PullGitCommitsResponse\"R\202\323\344\223\002L\"G" - + "/v1beta1/{name=projects/*/locations/*/repositories/*/workspaces/*}:pull:\001*\022\347\001\n" - + "\021SyncWorkspaceRefs\0227.google.cloud.dataform" - + ".v1beta1.SyncWorkspaceRefsRequest\0328.google.cloud.dataform.v1beta1.SyncWorkspaceR" - + "efsResponse\"_\202\323\344\223\002Y\"T/v1beta1/{name=proj" - + "ects/*/locations/*/repositories/*/workspaces/*}:syncWorkspaceRefs:\001*\022\357\001\n" - + "\026FetchWorkspaceBranches\022<.google.cloud.dataform." - + "v1beta1.FetchWorkspaceBranchesRequest\032=.google.cloud.dataform.v1beta1.FetchWorks" - + "paceBranchesResponse\"X\202\323\344\223\002R\022P/v1beta1/{" - + "name=projects/*/locations/*/repositories/*/workspaces/*}:fetchBranches\022\323\001\n" - + "\014DeleteBranch\0222.google.cloud.dataform.v1beta1." - + "DeleteBranchRequest\0323.google.cloud.dataf" - + "orm.v1beta1.DeleteBranchResponse\"Z\202\323\344\223\002T" - + "\"O/v1beta1/{name=projects/*/locations/*/" - + "repositories/*/workspaces/*}:deleteBranch:\001*\022\310\001\n" - + "\027CheckoutWorkspaceBranch\022=.google.cloud.dataform.v1beta1.CheckoutWorkspa" - + "ceBranchRequest\032\026.google.protobuf.Empty\"" - + "V\202\323\344\223\002P\"K/v1beta1/{name=projects/*/locat" - + "ions/*/repositories/*/workspaces/*}:checkout:\001*\022\203\002\n" - + "\033FetchCurrentWorkspaceBranch\022A.google.cloud.dataform.v1beta1.FetchCur" - + "rentWorkspaceBranchRequest\032B.google.cloud.dataform.v1beta1.FetchCurrentWorkspace" - + "BranchResponse\"]\202\323\344\223\002W\022U/v1beta1/{name=p" - + "rojects/*/locations/*/repositories/*/workspaces/*}:fetchCurrentBranch\022\321\001\n" - + "\016PushGitCommits\0224.google.cloud.dataform.v1beta1" - + ".PushGitCommitsRequest\0325.google.cloud.da", - "taform.v1beta1.PushGitCommitsResponse\"R\202" - + "\323\344\223\002L\"G/v1beta1/{name=projects/*/locatio" - + "ns/*/repositories/*/workspaces/*}:push:\001" - + "*\022\360\001\n\024FetchFileGitStatuses\022:.google.clou" - + "d.dataform.v1beta1.FetchFileGitStatusesR" - + "equest\032;.google.cloud.dataform.v1beta1.F" - + "etchFileGitStatusesResponse\"_\202\323\344\223\002Y\022W/v1" - + "beta1/{name=projects/*/locations/*/repos" - + "itories/*/workspaces/*}:fetchFileGitStat" - + "uses\022\354\001\n\023FetchGitAheadBehind\0229.google.cl" - + "oud.dataform.v1beta1.FetchGitAheadBehind" - + "Request\032:.google.cloud.dataform.v1beta1." - + "FetchGitAheadBehindResponse\"^\202\323\344\223\002X\022V/v1" - + "beta1/{name=projects/*/locations/*/repos" - + "itories/*/workspaces/*}:fetchGitAheadBeh" - + "ind\022\353\001\n\025FetchWorkspaceHistory\022;.google.c" - + "loud.dataform.v1beta1.FetchWorkspaceHist" - + "oryRequest\032<.google.cloud.dataform.v1bet" - + "a1.FetchWorkspaceHistoryResponse\"W\202\323\344\223\002Q" - + "\022O/v1beta1/{name=projects/*/locations/*/" - + "repositories/*/workspaces/*}:fetchHistor" - + "y\022\353\001\n\026CommitWorkspaceChanges\022<.google.cl" - + "oud.dataform.v1beta1.CommitWorkspaceChan" - + "gesRequest\032=.google.cloud.dataform.v1bet" - + "a1.CommitWorkspaceChangesResponse\"T\202\323\344\223\002" - + "N\"I/v1beta1/{name=projects/*/locations/*" - + "/repositories/*/workspaces/*}:commit:\001*\022" - + "\347\001\n\025ResetWorkspaceChanges\022;.google.cloud" - + ".dataform.v1beta1.ResetWorkspaceChangesR" - + "equest\032<.google.cloud.dataform.v1beta1.R" - + "esetWorkspaceChangesResponse\"S\202\323\344\223\002M\"H/v" - + "1beta1/{name=projects/*/locations/*/repo" - + "sitories/*/workspaces/*}:reset:\001*\022\331\001\n\rFe" - + "tchFileDiff\0223.google.cloud.dataform.v1be" - + "ta1.FetchFileDiffRequest\0324.google.cloud." - + "dataform.v1beta1.FetchFileDiffResponse\"]" - + "\202\323\344\223\002W\022U/v1beta1/{workspace=projects/*/l" - + "ocations/*/repositories/*/workspaces/*}:" - + "fetchFileDiff\022\375\001\n\026QueryDirectoryContents" - + "\022<.google.cloud.dataform.v1beta1.QueryDi" - + "rectoryContentsRequest\032=.google.cloud.da" - + "taform.v1beta1.QueryDirectoryContentsRes" - + "ponse\"f\202\323\344\223\002`\022^/v1beta1/{workspace=proje" - + "cts/*/locations/*/repositories/*/workspa" - + "ces/*}:queryDirectoryContents\022\321\001\n\013Search" - + "Files\0221.google.cloud.dataform.v1beta1.Se" - + "archFilesRequest\0322.google.cloud.dataform" - + ".v1beta1.SearchFilesResponse\"[\202\323\344\223\002U\022S/v" - + "1beta1/{workspace=projects/*/locations/*" - + "/repositories/*/workspaces/*}:searchFile" - + "s\022\334\001\n\rMakeDirectory\0223.google.cloud.dataf" - + "orm.v1beta1.MakeDirectoryRequest\0324.googl" - + "e.cloud.dataform.v1beta1.MakeDirectoryRe" - + "sponse\"`\202\323\344\223\002Z\"U/v1beta1/{workspace=proj" + + "\017DeleteWorkspace\0225.google.cloud.dataform.v1beta1.DeleteWorkspaceReq" + + "uest\032\026.google.protobuf.Empty\"Q\332A\004name\202\323\344" + + "\223\002D*B/v1beta1/{name=projects/*/locations/*/repositories/*/workspaces/*}\022\360\001\n" + + "\022InstallNpmPackages\0228.google.cloud.dataform.v" + + "1beta1.InstallNpmPackagesRequest\0329.google.cloud.dataform.v1beta1.InstallNpmPacka" + + "gesResponse\"e\202\323\344\223\002_\"Z/v1beta1/{workspace" + + "=projects/*/locations/*/repositories/*/workspaces/*}:installNpmPackages:\001*\022\321\001\n" + + "\016PullGitCommits\0224.google.cloud.dataform.v1" + + "beta1.PullGitCommitsRequest\0325.google.cloud.dataform.v1beta1.PullGitCommitsRespon" + + "se\"R\202\323\344\223\002L\"G/v1beta1/{name=projects/*/lo" + + "cations/*/repositories/*/workspaces/*}:pull:\001*\022\347\001\n" + + "\021SyncWorkspaceRefs\0227.google.cloud.dataform.v1beta1.SyncWorkspaceRefsRe" + + "quest\0328.google.cloud.dataform.v1beta1.Sy" + + "ncWorkspaceRefsResponse\"_\202\323\344\223\002Y\"T/v1beta" + + "1/{name=projects/*/locations/*/repositor" + + "ies/*/workspaces/*}:syncWorkspaceRefs:\001*\022\357\001\n" + + "\026FetchWorkspaceBranches\022<.google.cloud.dataform.v1beta1.FetchWorkspaceBranch" + + "esRequest\032=.google.cloud.dataform.v1beta" + + "1.FetchWorkspaceBranchesResponse\"X\202\323\344\223\002R" + + "\022P/v1beta1/{name=projects/*/locations/*/" + + "repositories/*/workspaces/*}:fetchBranches\022\323\001\n" + + "\014DeleteBranch\0222.google.cloud.dataform.v1beta1.DeleteBranchRequest\0323.google" + + ".cloud.dataform.v1beta1.DeleteBranchResp", + "onse\"Z\202\323\344\223\002T\"O/v1beta1/{name=projects/*/" + + "locations/*/repositories/*/workspaces/*}" + + ":deleteBranch:\001*\022\310\001\n\027CheckoutWorkspaceBr" + + "anch\022=.google.cloud.dataform.v1beta1.Che" + + "ckoutWorkspaceBranchRequest\032\026.google.pro" + + "tobuf.Empty\"V\202\323\344\223\002P\"K/v1beta1/{name=proj" + "ects/*/locations/*/repositories/*/worksp" - + "aces/*}:makeDirectory:\001*\022\344\001\n\017RemoveDirec" - + "tory\0225.google.cloud.dataform.v1beta1.Rem" - + "oveDirectoryRequest\0326.google.cloud.dataf" - + "orm.v1beta1.RemoveDirectoryResponse\"b\202\323\344" - + "\223\002\\\"W/v1beta1/{workspace=projects/*/loca" - + "tions/*/repositories/*/workspaces/*}:rem" - + "oveDirectory:\001*\022\334\001\n\rMoveDirectory\0223.goog" - + "le.cloud.dataform.v1beta1.MoveDirectoryR" - + "equest\0324.google.cloud.dataform.v1beta1.M" - + "oveDirectoryResponse\"`\202\323\344\223\002Z\"U/v1beta1/{" - + "workspace=projects/*/locations/*/reposit" - + "ories/*/workspaces/*}:moveDirectory:\001*\022\305" - + "\001\n\010ReadFile\022..google.cloud.dataform.v1be" - + "ta1.ReadFileRequest\032/.google.cloud.dataf" - + "orm.v1beta1.ReadFileResponse\"X\202\323\344\223\002R\022P/v" - + "1beta1/{workspace=projects/*/locations/*" - + "/repositories/*/workspaces/*}:readFile\022\320" - + "\001\n\nRemoveFile\0220.google.cloud.dataform.v1" - + "beta1.RemoveFileRequest\0321.google.cloud.d" - + "ataform.v1beta1.RemoveFileResponse\"]\202\323\344\223" - + "\002W\"R/v1beta1/{workspace=projects/*/locat" - + "ions/*/repositories/*/workspaces/*}:remo" - + "veFile:\001*\022\310\001\n\010MoveFile\022..google.cloud.da" - + "taform.v1beta1.MoveFileRequest\032/.google." - + "cloud.dataform.v1beta1.MoveFileResponse\"" - + "[\202\323\344\223\002U\"P/v1beta1/{workspace=projects/*/" + + "aces/*}:checkout:\001*\022\203\002\n\033FetchCurrentWork" + + "spaceBranch\022A.google.cloud.dataform.v1be" + + "ta1.FetchCurrentWorkspaceBranchRequest\032B" + + ".google.cloud.dataform.v1beta1.FetchCurr" + + "entWorkspaceBranchResponse\"]\202\323\344\223\002W\022U/v1b" + + "eta1/{name=projects/*/locations/*/reposi" + + "tories/*/workspaces/*}:fetchCurrentBranc" + + "h\022\321\001\n\016PushGitCommits\0224.google.cloud.data" + + "form.v1beta1.PushGitCommitsRequest\0325.goo" + + "gle.cloud.dataform.v1beta1.PushGitCommit" + + "sResponse\"R\202\323\344\223\002L\"G/v1beta1/{name=projec" + + "ts/*/locations/*/repositories/*/workspac" + + "es/*}:push:\001*\022\360\001\n\024FetchFileGitStatuses\022:" + + ".google.cloud.dataform.v1beta1.FetchFile" + + "GitStatusesRequest\032;.google.cloud.datafo" + + "rm.v1beta1.FetchFileGitStatusesResponse\"" + + "_\202\323\344\223\002Y\022W/v1beta1/{name=projects/*/locat" + + "ions/*/repositories/*/workspaces/*}:fetc" + + "hFileGitStatuses\022\354\001\n\023FetchGitAheadBehind" + + "\0229.google.cloud.dataform.v1beta1.FetchGi" + + "tAheadBehindRequest\032:.google.cloud.dataf" + + "orm.v1beta1.FetchGitAheadBehindResponse\"" + + "^\202\323\344\223\002X\022V/v1beta1/{name=projects/*/locat" + + "ions/*/repositories/*/workspaces/*}:fetc" + + "hGitAheadBehind\022\353\001\n\025FetchWorkspaceHistor" + + "y\022;.google.cloud.dataform.v1beta1.FetchW" + + "orkspaceHistoryRequest\032<.google.cloud.da" + + "taform.v1beta1.FetchWorkspaceHistoryResp" + + "onse\"W\202\323\344\223\002Q\022O/v1beta1/{name=projects/*/" + "locations/*/repositories/*/workspaces/*}" - + ":moveFile:\001*\022\314\001\n\tWriteFile\022/.google.clou" - + "d.dataform.v1beta1.WriteFileRequest\0320.go" - + "ogle.cloud.dataform.v1beta1.WriteFileRes" - + "ponse\"\\\202\323\344\223\002V\"Q/v1beta1/{workspace=proje" - + "cts/*/locations/*/repositories/*/workspa" - + "ces/*}:writeFile:\001*\022\342\001\n\022ListReleaseConfi" - + "gs\0228.google.cloud.dataform.v1beta1.ListR" - + "eleaseConfigsRequest\0329.google.cloud.data" - + "form.v1beta1.ListReleaseConfigsResponse\"" - + "W\332A\006parent\202\323\344\223\002H\022F/v1beta1/{parent=proje" - + "cts/*/locations/*/repositories/*}/releas" - + "eConfigs\022\317\001\n\020GetReleaseConfig\0226.google.c" - + "loud.dataform.v1beta1.GetReleaseConfigRe" - + "quest\032,.google.cloud.dataform.v1beta1.Re" - + "leaseConfig\"U\332A\004name\202\323\344\223\002H\022F/v1beta1/{na" - + "me=projects/*/locations/*/repositories/*" - + "/releaseConfigs/*}\022\211\002\n\023CreateReleaseConf" - + "ig\0229.google.cloud.dataform.v1beta1.Creat" - + "eReleaseConfigRequest\032,.google.cloud.dat" - + "aform.v1beta1.ReleaseConfig\"\210\001\332A\'parent," - + "release_config,release_config_id\202\323\344\223\002X\"F" - + "/v1beta1/{parent=projects/*/locations/*/" - + "repositories/*}/releaseConfigs:\016release_" - + "config\022\213\002\n\023UpdateReleaseConfig\0229.google." - + "cloud.dataform.v1beta1.UpdateReleaseConf" - + "igRequest\032,.google.cloud.dataform.v1beta" - + "1.ReleaseConfig\"\212\001\332A\032release_config,upda" - + "te_mask\202\323\344\223\002g2U/v1beta1/{release_config." - + "name=projects/*/locations/*/repositories" - + "/*/releaseConfigs/*}:\016release_config\022\277\001\n" - + "\023DeleteReleaseConfig\0229.google.cloud.data" - + "form.v1beta1.DeleteReleaseConfigRequest\032" - + "\026.google.protobuf.Empty\"U\332A\004name\202\323\344\223\002H*F" - + "/v1beta1/{name=projects/*/locations/*/re" - + "positories/*/releaseConfigs/*}\022\362\001\n\026ListC" - + "ompilationResults\022<.google.cloud.datafor" - + "m.v1beta1.ListCompilationResultsRequest\032" - + "=.google.cloud.dataform.v1beta1.ListComp" - + "ilationResultsResponse\"[\332A\006parent\202\323\344\223\002L\022" - + "J/v1beta1/{parent=projects/*/locations/*" - + "/repositories/*}/compilationResults\022\337\001\n\024" - + "GetCompilationResult\022:.google.cloud.data" - + "form.v1beta1.GetCompilationResultRequest" - + "\0320.google.cloud.dataform.v1beta1.Compila" - + "tionResult\"Y\332A\004name\202\323\344\223\002L\022J/v1beta1/{nam" - + "e=projects/*/locations/*/repositories/*/" - + "compilationResults/*}\022\217\002\n\027CreateCompilat" - + "ionResult\022=.google.cloud.dataform.v1beta" - + "1.CreateCompilationResultRequest\0320.googl" - + "e.cloud.dataform.v1beta1.CompilationResu" - + "lt\"\202\001\332A\031parent,compilation_result\202\323\344\223\002`\"" - + "J/v1beta1/{parent=projects/*/locations/*" - + "/repositories/*}/compilationResults:\022com" - + "pilation_result\022\320\002\n\"CreateCompilationRes" - + "ultLongRunning\022=.google.cloud.dataform.v" - + "1beta1.CreateCompilationResultRequest\032\035." - + "google.longrunning.Operation\"\313\001\312A4\n\021Comp" - + "ilationResult\022\037CreateCompilationResultMe" - + "tadata\332A\031parent,compilation_result\202\323\344\223\002r" - + "\"\\/v1beta1/{parent=projects/*/locations/" - + "*/repositories/*}/compilationResults:cre" - + "ateLongRunning:\022compilation_result\022\204\002\n\035Q" - + "ueryCompilationResultActions\022C.google.cl" - + "oud.dataform.v1beta1.QueryCompilationRes" - + "ultActionsRequest\032D.google.cloud.datafor" - + "m.v1beta1.QueryCompilationResultActionsR" - + "esponse\"X\202\323\344\223\002R\022P/v1beta1/{name=projects" - + "/*/locations/*/repositories/*/compilatio" - + "nResults/*}:query\022\346\001\n\023ListWorkflowConfig" - + "s\0229.google.cloud.dataform.v1beta1.ListWo" - + "rkflowConfigsRequest\032:.google.cloud.data" - + "form.v1beta1.ListWorkflowConfigsResponse" - + "\"X\332A\006parent\202\323\344\223\002I\022G/v1beta1/{parent=proj" - + "ects/*/locations/*/repositories/*}/workf" - + "lowConfigs\022\323\001\n\021GetWorkflowConfig\0227.googl" - + "e.cloud.dataform.v1beta1.GetWorkflowConf" - + "igRequest\032-.google.cloud.dataform.v1beta" - + "1.WorkflowConfig\"V\332A\004name\202\323\344\223\002I\022G/v1beta" - + "1/{name=projects/*/locations/*/repositor" - + "ies/*/workflowConfigs/*}\022\220\002\n\024CreateWorkf" - + "lowConfig\022:.google.cloud.dataform.v1beta" - + "1.CreateWorkflowConfigRequest\032-.google.c" - + "loud.dataform.v1beta1.WorkflowConfig\"\214\001\332" - + "A)parent,workflow_config,workflow_config" - + "_id\202\323\344\223\002Z\"G/v1beta1/{parent=projects/*/l" - + "ocations/*/repositories/*}/workflowConfi" - + "gs:\017workflow_config\022\222\002\n\024UpdateWorkflowCo" - + "nfig\022:.google.cloud.dataform.v1beta1.Upd" - + "ateWorkflowConfigRequest\032-.google.cloud." - + "dataform.v1beta1.WorkflowConfig\"\216\001\332A\033wor" - + "kflow_config,update_mask\202\323\344\223\002j2W/v1beta1" - + "/{workflow_config.name=projects/*/locati" - + "ons/*/repositories/*/workflowConfigs/*}:" - + "\017workflow_config\022\302\001\n\024DeleteWorkflowConfi" - + "g\022:.google.cloud.dataform.v1beta1.Delete" - + "WorkflowConfigRequest\032\026.google.protobuf." - + "Empty\"V\332A\004name\202\323\344\223\002I*G/v1beta1/{name=pro" - + "jects/*/locations/*/repositories/*/workf" - + "lowConfigs/*}\022\366\001\n\027ListWorkflowInvocation" - + "s\022=.google.cloud.dataform.v1beta1.ListWo" - + "rkflowInvocationsRequest\032>.google.cloud." - + "dataform.v1beta1.ListWorkflowInvocations" - + "Response\"\\\332A\006parent\202\323\344\223\002M\022K/v1beta1/{par" - + "ent=projects/*/locations/*/repositories/" - + "*}/workflowInvocations\022\343\001\n\025GetWorkflowIn" - + "vocation\022;.google.cloud.dataform.v1beta1" - + ".GetWorkflowInvocationRequest\0321.google.c" - + "loud.dataform.v1beta1.WorkflowInvocation" - + "\"Z\332A\004name\202\323\344\223\002M\022K/v1beta1/{name=projects" - + "/*/locations/*/repositories/*/workflowIn" - + "vocations/*}\022\225\002\n\030CreateWorkflowInvocatio" - + "n\022>.google.cloud.dataform.v1beta1.Create" - + "WorkflowInvocationRequest\0321.google.cloud" - + ".dataform.v1beta1.WorkflowInvocation\"\205\001\332" - + "A\032parent,workflow_invocation\202\323\344\223\002b\"K/v1b" - + "eta1/{parent=projects/*/locations/*/repo" - + "sitories/*}/workflowInvocations:\023workflo" - + "w_invocation\022\316\001\n\030DeleteWorkflowInvocatio" - + "n\022>.google.cloud.dataform.v1beta1.Delete" - + "WorkflowInvocationRequest\032\026.google.proto" - + "buf.Empty\"Z\332A\004name\202\323\344\223\002M*K/v1beta1/{name" + + ":fetchHistory\022\353\001\n\026CommitWorkspaceChanges" + + "\022<.google.cloud.dataform.v1beta1.CommitW" + + "orkspaceChangesRequest\032=.google.cloud.da" + + "taform.v1beta1.CommitWorkspaceChangesRes" + + "ponse\"T\202\323\344\223\002N\"I/v1beta1/{name=projects/*" + + "/locations/*/repositories/*/workspaces/*" + + "}:commit:\001*\022\347\001\n\025ResetWorkspaceChanges\022;." + + "google.cloud.dataform.v1beta1.ResetWorks" + + "paceChangesRequest\032<.google.cloud.datafo" + + "rm.v1beta1.ResetWorkspaceChangesResponse" + + "\"S\202\323\344\223\002M\"H/v1beta1/{name=projects/*/loca" + + "tions/*/repositories/*/workspaces/*}:res" + + "et:\001*\022\331\001\n\rFetchFileDiff\0223.google.cloud.d" + + "ataform.v1beta1.FetchFileDiffRequest\0324.g" + + "oogle.cloud.dataform.v1beta1.FetchFileDi" + + "ffResponse\"]\202\323\344\223\002W\022U/v1beta1/{workspace=" + + "projects/*/locations/*/repositories/*/wo" + + "rkspaces/*}:fetchFileDiff\022\375\001\n\026QueryDirec" + + "toryContents\022<.google.cloud.dataform.v1b" + + "eta1.QueryDirectoryContentsRequest\032=.goo" + + "gle.cloud.dataform.v1beta1.QueryDirector" + + "yContentsResponse\"f\202\323\344\223\002`\022^/v1beta1/{wor" + + "kspace=projects/*/locations/*/repositori" + + "es/*/workspaces/*}:queryDirectoryContent" + + "s\022\321\001\n\013SearchFiles\0221.google.cloud.datafor" + + "m.v1beta1.SearchFilesRequest\0322.google.cl" + + "oud.dataform.v1beta1.SearchFilesResponse" + + "\"[\202\323\344\223\002U\022S/v1beta1/{workspace=projects/*" + + "/locations/*/repositories/*/workspaces/*" + + "}:searchFiles\022\334\001\n\rMakeDirectory\0223.google" + + ".cloud.dataform.v1beta1.MakeDirectoryReq" + + "uest\0324.google.cloud.dataform.v1beta1.Mak" + + "eDirectoryResponse\"`\202\323\344\223\002Z\"U/v1beta1/{wo" + + "rkspace=projects/*/locations/*/repositor" + + "ies/*/workspaces/*}:makeDirectory:\001*\022\344\001\n" + + "\017RemoveDirectory\0225.google.cloud.dataform" + + ".v1beta1.RemoveDirectoryRequest\0326.google" + + ".cloud.dataform.v1beta1.RemoveDirectoryR" + + "esponse\"b\202\323\344\223\002\\\"W/v1beta1/{workspace=pro" + + "jects/*/locations/*/repositories/*/works" + + "paces/*}:removeDirectory:\001*\022\334\001\n\rMoveDire" + + "ctory\0223.google.cloud.dataform.v1beta1.Mo" + + "veDirectoryRequest\0324.google.cloud.datafo" + + "rm.v1beta1.MoveDirectoryResponse\"`\202\323\344\223\002Z" + + "\"U/v1beta1/{workspace=projects/*/locatio" + + "ns/*/repositories/*/workspaces/*}:moveDi" + + "rectory:\001*\022\305\001\n\010ReadFile\022..google.cloud.d" + + "ataform.v1beta1.ReadFileRequest\032/.google" + + ".cloud.dataform.v1beta1.ReadFileResponse" + + "\"X\202\323\344\223\002R\022P/v1beta1/{workspace=projects/*" + + "/locations/*/repositories/*/workspaces/*" + + "}:readFile\022\320\001\n\nRemoveFile\0220.google.cloud" + + ".dataform.v1beta1.RemoveFileRequest\0321.go" + + "ogle.cloud.dataform.v1beta1.RemoveFileRe" + + "sponse\"]\202\323\344\223\002W\"R/v1beta1/{workspace=proj" + + "ects/*/locations/*/repositories/*/worksp" + + "aces/*}:removeFile:\001*\022\310\001\n\010MoveFile\022..goo" + + "gle.cloud.dataform.v1beta1.MoveFileReque" + + "st\032/.google.cloud.dataform.v1beta1.MoveF" + + "ileResponse\"[\202\323\344\223\002U\"P/v1beta1/{workspace" + "=projects/*/locations/*/repositories/*/w" - + "orkflowInvocations/*}\022\372\001\n\030CancelWorkflow" - + "Invocation\022>.google.cloud.dataform.v1bet" - + "a1.CancelWorkflowInvocationRequest\032?.goo" - + "gle.cloud.dataform.v1beta1.CancelWorkflo" - + "wInvocationResponse\"]\202\323\344\223\002W\"R/v1beta1/{n" + + "orkspaces/*}:moveFile:\001*\022\314\001\n\tWriteFile\022/" + + ".google.cloud.dataform.v1beta1.WriteFile" + + "Request\0320.google.cloud.dataform.v1beta1." + + "WriteFileResponse\"\\\202\323\344\223\002V\"Q/v1beta1/{wor" + + "kspace=projects/*/locations/*/repositori" + + "es/*/workspaces/*}:writeFile:\001*\022\342\001\n\022List" + + "ReleaseConfigs\0228.google.cloud.dataform.v" + + "1beta1.ListReleaseConfigsRequest\0329.googl" + + "e.cloud.dataform.v1beta1.ListReleaseConf" + + "igsResponse\"W\332A\006parent\202\323\344\223\002H\022F/v1beta1/{" + + "parent=projects/*/locations/*/repositori" + + "es/*}/releaseConfigs\022\317\001\n\020GetReleaseConfi" + + "g\0226.google.cloud.dataform.v1beta1.GetRel" + + "easeConfigRequest\032,.google.cloud.datafor" + + "m.v1beta1.ReleaseConfig\"U\332A\004name\202\323\344\223\002H\022F" + + "/v1beta1/{name=projects/*/locations/*/re" + + "positories/*/releaseConfigs/*}\022\211\002\n\023Creat" + + "eReleaseConfig\0229.google.cloud.dataform.v" + + "1beta1.CreateReleaseConfigRequest\032,.goog" + + "le.cloud.dataform.v1beta1.ReleaseConfig\"" + + "\210\001\332A\'parent,release_config,release_confi" + + "g_id\202\323\344\223\002X\"F/v1beta1/{parent=projects/*/" + + "locations/*/repositories/*}/releaseConfi" + + "gs:\016release_config\022\213\002\n\023UpdateReleaseConf" + + "ig\0229.google.cloud.dataform.v1beta1.Updat" + + "eReleaseConfigRequest\032,.google.cloud.dat" + + "aform.v1beta1.ReleaseConfig\"\212\001\332A\032release" + + "_config,update_mask\202\323\344\223\002g2U/v1beta1/{rel" + + "ease_config.name=projects/*/locations/*/" + + "repositories/*/releaseConfigs/*}:\016releas" + + "e_config\022\277\001\n\023DeleteReleaseConfig\0229.googl" + + "e.cloud.dataform.v1beta1.DeleteReleaseCo" + + "nfigRequest\032\026.google.protobuf.Empty\"U\332A\004" + + "name\202\323\344\223\002H*F/v1beta1/{name=projects/*/lo" + + "cations/*/repositories/*/releaseConfigs/" + + "*}\022\362\001\n\026ListCompilationResults\022<.google.c" + + "loud.dataform.v1beta1.ListCompilationRes" + + "ultsRequest\032=.google.cloud.dataform.v1be" + + "ta1.ListCompilationResultsResponse\"[\332A\006p" + + "arent\202\323\344\223\002L\022J/v1beta1/{parent=projects/*" + + "/locations/*/repositories/*}/compilation" + + "Results\022\337\001\n\024GetCompilationResult\022:.googl" + + "e.cloud.dataform.v1beta1.GetCompilationR" + + "esultRequest\0320.google.cloud.dataform.v1b" + + "eta1.CompilationResult\"Y\332A\004name\202\323\344\223\002L\022J/" + + "v1beta1/{name=projects/*/locations/*/rep" + + "ositories/*/compilationResults/*}\022\217\002\n\027Cr" + + "eateCompilationResult\022=.google.cloud.dat" + + "aform.v1beta1.CreateCompilationResultReq" + + "uest\0320.google.cloud.dataform.v1beta1.Com" + + "pilationResult\"\202\001\332A\031parent,compilation_r" + + "esult\202\323\344\223\002`\"J/v1beta1/{parent=projects/*" + + "/locations/*/repositories/*}/compilation" + + "Results:\022compilation_result\022\320\002\n\"CreateCo" + + "mpilationResultLongRunning\022=.google.clou" + + "d.dataform.v1beta1.CreateCompilationResu" + + "ltRequest\032\035.google.longrunning.Operation" + + "\"\313\001\312A4\n\021CompilationResult\022\037CreateCompila" + + "tionResultMetadata\332A\031parent,compilation_" + + "result\202\323\344\223\002r\"\\/v1beta1/{parent=projects/" + + "*/locations/*/repositories/*}/compilatio" + + "nResults:createLongRunning:\022compilation_" + + "result\022\204\002\n\035QueryCompilationResultActions" + + "\022C.google.cloud.dataform.v1beta1.QueryCo" + + "mpilationResultActionsRequest\032D.google.c" + + "loud.dataform.v1beta1.QueryCompilationRe" + + "sultActionsResponse\"X\202\323\344\223\002R\022P/v1beta1/{n" + "ame=projects/*/locations/*/repositories/" - + "*/workflowInvocations/*}:cancel:\001*\022\210\002\n\036Q" - + "ueryWorkflowInvocationActions\022D.google.c" - + "loud.dataform.v1beta1.QueryWorkflowInvoc" - + "ationActionsRequest\032E.google.cloud.dataf" - + "orm.v1beta1.QueryWorkflowInvocationActio" - + "nsResponse\"Y\202\323\344\223\002S\022Q/v1beta1/{name=proje" + + "*/compilationResults/*}:query\022\346\001\n\023ListWo" + + "rkflowConfigs\0229.google.cloud.dataform.v1" + + "beta1.ListWorkflowConfigsRequest\032:.googl" + + "e.cloud.dataform.v1beta1.ListWorkflowCon" + + "figsResponse\"X\332A\006parent\202\323\344\223\002I\022G/v1beta1/" + + "{parent=projects/*/locations/*/repositor" + + "ies/*}/workflowConfigs\022\323\001\n\021GetWorkflowCo" + + "nfig\0227.google.cloud.dataform.v1beta1.Get" + + "WorkflowConfigRequest\032-.google.cloud.dat" + + "aform.v1beta1.WorkflowConfig\"V\332A\004name\202\323\344" + + "\223\002I\022G/v1beta1/{name=projects/*/locations" + + "/*/repositories/*/workflowConfigs/*}\022\220\002\n" + + "\024CreateWorkflowConfig\022:.google.cloud.dat" + + "aform.v1beta1.CreateWorkflowConfigReques" + + "t\032-.google.cloud.dataform.v1beta1.Workfl" + + "owConfig\"\214\001\332A)parent,workflow_config,wor" + + "kflow_config_id\202\323\344\223\002Z\"G/v1beta1/{parent=" + + "projects/*/locations/*/repositories/*}/w" + + "orkflowConfigs:\017workflow_config\022\222\002\n\024Upda" + + "teWorkflowConfig\022:.google.cloud.dataform" + + ".v1beta1.UpdateWorkflowConfigRequest\032-.g" + + "oogle.cloud.dataform.v1beta1.WorkflowCon" + + "fig\"\216\001\332A\033workflow_config,update_mask\202\323\344\223" + + "\002j2W/v1beta1/{workflow_config.name=proje" + "cts/*/locations/*/repositories/*/workflo" - + "wInvocations/*}:query\022\241\001\n\tGetConfig\022/.go" - + "ogle.cloud.dataform.v1beta1.GetConfigReq" - + "uest\032%.google.cloud.dataform.v1beta1.Con" - + "fig\"<\332A\004name\202\323\344\223\002/\022-/v1beta1/{name=proje" - + "cts/*/locations/*/config}\022\304\001\n\014UpdateConf" - + "ig\0222.google.cloud.dataform.v1beta1.Updat" - + "eConfigRequest\032%.google.cloud.dataform.v" - + "1beta1.Config\"Y\332A\022config,update_mask\202\323\344\223" - + "\002>24/v1beta1/{config.name=projects/*/loc" - + "ations/*/config}:\006config\022\213\003\n\014GetIamPolic" - + "y\022\".google.iam.v1.GetIamPolicyRequest\032\025." - + "google.iam.v1.Policy\"\277\002\332A\010resource\202\323\344\223\002\255" - + "\002\022F/v1beta1/{resource=projects/*/locatio" - + "ns/*/repositories/*}:getIamPolicyZU\022S/v1" - + "beta1/{resource=projects/*/locations/*/r" - + "epositories/*/workspaces/*}:getIamPolicy" - + "ZC\022A/v1beta1/{resource=projects/*/locati" - + "ons/*/folders/*}:getIamPolicyZG\022E/v1beta" - + "1/{resource=projects/*/locations/*/teamF" - + "olders/*}:getIamPolicy\022\214\003\n\014SetIamPolicy\022" - + "\".google.iam.v1.SetIamPolicyRequest\032\025.go" - + "ogle.iam.v1.Policy\"\300\002\202\323\344\223\002\271\002\"F/v1beta1/{" - + "resource=projects/*/locations/*/reposito" - + "ries/*}:setIamPolicy:\001*ZX\"S/v1beta1/{res" - + "ource=projects/*/locations/*/repositorie" - + "s/*/workspaces/*}:setIamPolicy:\001*ZF\"A/v1" - + "beta1/{resource=projects/*/locations/*/f" - + "olders/*}:setIamPolicy:\001*ZJ\"E/v1beta1/{r" - + "esource=projects/*/locations/*/teamFolde" - + "rs/*}:setIamPolicy:\001*\022\304\003\n\022TestIamPermiss" - + "ions\022(.google.iam.v1.TestIamPermissionsR" - + "equest\032).google.iam.v1.TestIamPermission" - + "sResponse\"\330\002\202\323\344\223\002\321\002\"L/v1beta1/{resource=" - + "projects/*/locations/*/repositories/*}:t" - + "estIamPermissions:\001*Z^\"Y/v1beta1/{resour" - + "ce=projects/*/locations/*/repositories/*" - + "/workspaces/*}:testIamPermissions:\001*ZL\"G" - + "/v1beta1/{resource=projects/*/locations/" - + "*/folders/*}:testIamPermissions:\001*ZP\"K/v" - + "1beta1/{resource=projects/*/locations/*/" - + "teamFolders/*}:testIamPermissions:\001*\032t\312A" - + "\027dataform.googleapis.com\322AWhttps://www.g" - + "oogleapis.com/auth/bigquery,https://www." - + "googleapis.com/auth/cloud-platformB\237\t\n!c" - + "om.google.cloud.dataform.v1beta1B\rDatafo" - + "rmProtoP\001Z=cloud.google.com/go/dataform/" - + "apiv1beta1/dataformpb;dataformpb\252\002\035Googl" - + "e.Cloud.Dataform.V1Beta1\312\002\035Google\\Cloud\\" - + "Dataform\\V1beta1\352\002 Google::Cloud::Datafo" - + "rm::V1beta1\352Ad\n*secretmanager.googleapis" - + ".com/SecretVersion\0226projects/{project}/s" - + "ecrets/{secret}/versions/{version}\352Ax\n!c" - + "loudkms.googleapis.com/CryptoKey\022Sprojec" - + "ts/{project}/locations/{location}/keyRin" - + "gs/{key_ring}/cryptoKeys/{crypto_key}\352A\246" - + "\001\n(cloudkms.googleapis.com/CryptoKeyVers" - + "ion\022zprojects/{project}/locations/{locat" - + "ion}/keyRings/{key_ring}/cryptoKeys/{cry" - + "pto_key}/cryptoKeyVersions/{crypto_key_v" - + "ersion}\352A\221\001\n1aiplatform.googleapis.com/N" - + "otebookRuntimeTemplate\022\\projects/{projec" - + "t}/locations/{location}/notebookRuntimeT" - + "emplates/{notebook_runtime_template}\352A~\n" - + "!dataplex.googleapis.com/EntryLink\022Yproj" - + "ects/{project}/locations/{location}/entr" - + "yGroups/{entry_group}/entryLinks/{entry_" - + "link}\352A\236\001\n1developerconnect.googleapis.c" - + "om/GitRepositoryLink\022iprojects/{project}" - + "/locations/{location}/connections/{conne" - + "ction}/gitRepositoryLinks/{git_repositor" - + "y_link}\352A\201\001\n0developerconnect.googleapis" - + ".com/AccountConnector\022Mprojects/{project" - + "}/locations/{location}/accountConnectors" - + "/{account_connector}b\006proto3" + + "wConfigs/*}:\017workflow_config\022\302\001\n\024DeleteW" + + "orkflowConfig\022:.google.cloud.dataform.v1" + + "beta1.DeleteWorkflowConfigRequest\032\026.goog" + + "le.protobuf.Empty\"V\332A\004name\202\323\344\223\002I*G/v1bet" + + "a1/{name=projects/*/locations/*/reposito" + + "ries/*/workflowConfigs/*}\022\366\001\n\027ListWorkfl" + + "owInvocations\022=.google.cloud.dataform.v1" + + "beta1.ListWorkflowInvocationsRequest\032>.g" + + "oogle.cloud.dataform.v1beta1.ListWorkflo" + + "wInvocationsResponse\"\\\332A\006parent\202\323\344\223\002M\022K/" + + "v1beta1/{parent=projects/*/locations/*/r" + + "epositories/*}/workflowInvocations\022\343\001\n\025G" + + "etWorkflowInvocation\022;.google.cloud.data" + + "form.v1beta1.GetWorkflowInvocationReques" + + "t\0321.google.cloud.dataform.v1beta1.Workfl" + + "owInvocation\"Z\332A\004name\202\323\344\223\002M\022K/v1beta1/{n" + + "ame=projects/*/locations/*/repositories/" + + "*/workflowInvocations/*}\022\225\002\n\030CreateWorkf" + + "lowInvocation\022>.google.cloud.dataform.v1" + + "beta1.CreateWorkflowInvocationRequest\0321." + + "google.cloud.dataform.v1beta1.WorkflowIn" + + "vocation\"\205\001\332A\032parent,workflow_invocation" + + "\202\323\344\223\002b\"K/v1beta1/{parent=projects/*/loca" + + "tions/*/repositories/*}/workflowInvocati" + + "ons:\023workflow_invocation\022\316\001\n\030DeleteWorkf" + + "lowInvocation\022>.google.cloud.dataform.v1" + + "beta1.DeleteWorkflowInvocationRequest\032\026." + + "google.protobuf.Empty\"Z\332A\004name\202\323\344\223\002M*K/v" + + "1beta1/{name=projects/*/locations/*/repo" + + "sitories/*/workflowInvocations/*}\022\372\001\n\030Ca" + + "ncelWorkflowInvocation\022>.google.cloud.da" + + "taform.v1beta1.CancelWorkflowInvocationR" + + "equest\032?.google.cloud.dataform.v1beta1.C" + + "ancelWorkflowInvocationResponse\"]\202\323\344\223\002W\"" + + "R/v1beta1/{name=projects/*/locations/*/r" + + "epositories/*/workflowInvocations/*}:can" + + "cel:\001*\022\210\002\n\036QueryWorkflowInvocationAction" + + "s\022D.google.cloud.dataform.v1beta1.QueryW" + + "orkflowInvocationActionsRequest\032E.google" + + ".cloud.dataform.v1beta1.QueryWorkflowInv" + + "ocationActionsResponse\"Y\202\323\344\223\002S\022Q/v1beta1" + + "/{name=projects/*/locations/*/repositori" + + "es/*/workflowInvocations/*}:query\022\241\001\n\tGe" + + "tConfig\022/.google.cloud.dataform.v1beta1." + + "GetConfigRequest\032%.google.cloud.dataform" + + ".v1beta1.Config\"<\332A\004name\202\323\344\223\002/\022-/v1beta1" + + "/{name=projects/*/locations/*/config}\022\304\001" + + "\n\014UpdateConfig\0222.google.cloud.dataform.v" + + "1beta1.UpdateConfigRequest\032%.google.clou" + + "d.dataform.v1beta1.Config\"Y\332A\022config,upd" + + "ate_mask\202\323\344\223\002>24/v1beta1/{config.name=pr" + + "ojects/*/locations/*/config}:\006config\022\213\003\n" + + "\014GetIamPolicy\022\".google.iam.v1.GetIamPoli" + + "cyRequest\032\025.google.iam.v1.Policy\"\277\002\332A\010re" + + "source\202\323\344\223\002\255\002\022F/v1beta1/{resource=projec" + + "ts/*/locations/*/repositories/*}:getIamP" + + "olicyZU\022S/v1beta1/{resource=projects/*/l" + + "ocations/*/repositories/*/workspaces/*}:" + + "getIamPolicyZC\022A/v1beta1/{resource=proje" + + "cts/*/locations/*/folders/*}:getIamPolic" + + "yZG\022E/v1beta1/{resource=projects/*/locat" + + "ions/*/teamFolders/*}:getIamPolicy\022\214\003\n\014S" + + "etIamPolicy\022\".google.iam.v1.SetIamPolicy" + + "Request\032\025.google.iam.v1.Policy\"\300\002\202\323\344\223\002\271\002" + + "\"F/v1beta1/{resource=projects/*/location" + + "s/*/repositories/*}:setIamPolicy:\001*ZX\"S/" + + "v1beta1/{resource=projects/*/locations/*" + + "/repositories/*/workspaces/*}:setIamPoli" + + "cy:\001*ZF\"A/v1beta1/{resource=projects/*/l" + + "ocations/*/folders/*}:setIamPolicy:\001*ZJ\"" + + "E/v1beta1/{resource=projects/*/locations" + + "/*/teamFolders/*}:setIamPolicy:\001*\022\304\003\n\022Te" + + "stIamPermissions\022(.google.iam.v1.TestIam" + + "PermissionsRequest\032).google.iam.v1.TestI" + + "amPermissionsResponse\"\330\002\202\323\344\223\002\321\002\"L/v1beta" + + "1/{resource=projects/*/locations/*/repos" + + "itories/*}:testIamPermissions:\001*Z^\"Y/v1b" + + "eta1/{resource=projects/*/locations/*/re" + + "positories/*/workspaces/*}:testIamPermis" + + "sions:\001*ZL\"G/v1beta1/{resource=projects/" + + "*/locations/*/folders/*}:testIamPermissi" + + "ons:\001*ZP\"K/v1beta1/{resource=projects/*/" + + "locations/*/teamFolders/*}:testIamPermis" + + "sions:\001*\032t\312A\027dataform.googleapis.com\322AWh" + + "ttps://www.googleapis.com/auth/bigquery," + + "https://www.googleapis.com/auth/cloud-pl" + + "atformB\237\t\n!com.google.cloud.dataform.v1b" + + "eta1B\rDataformProtoP\001Z=cloud.google.com/" + + "go/dataform/apiv1beta1/dataformpb;datafo" + + "rmpb\252\002\035Google.Cloud.Dataform.V1Beta1\312\002\035G" + + "oogle\\Cloud\\Dataform\\V1beta1\352\002 Google::C" + + "loud::Dataform::V1beta1\352Ad\n*secretmanage" + + "r.googleapis.com/SecretVersion\0226projects" + + "/{project}/secrets/{secret}/versions/{ve" + + "rsion}\352Ax\n!cloudkms.googleapis.com/Crypt" + + "oKey\022Sprojects/{project}/locations/{loca" + + "tion}/keyRings/{key_ring}/cryptoKeys/{cr" + + "ypto_key}\352A\246\001\n(cloudkms.googleapis.com/C" + + "ryptoKeyVersion\022zprojects/{project}/loca" + + "tions/{location}/keyRings/{key_ring}/cry" + + "ptoKeys/{crypto_key}/cryptoKeyVersions/{" + + "crypto_key_version}\352A\221\001\n1aiplatform.goog" + + "leapis.com/NotebookRuntimeTemplate\022\\proj" + + "ects/{project}/locations/{location}/note" + + "bookRuntimeTemplates/{notebook_runtime_t" + + "emplate}\352A~\n!dataplex.googleapis.com/Ent" + + "ryLink\022Yprojects/{project}/locations/{lo" + + "cation}/entryGroups/{entry_group}/entryL" + + "inks/{entry_link}\352A\236\001\n1developerconnect." + + "googleapis.com/GitRepositoryLink\022iprojec" + + "ts/{project}/locations/{location}/connec" + + "tions/{connection}/gitRepositoryLinks/{g" + + "it_repository_link}\352A\201\001\n0developerconnec" + + "t.googleapis.com/AccountConnector\022Mproje" + + "cts/{project}/locations/{location}/accou" + + "ntConnectors/{account_connector}b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -2965,8 +2993,16 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Parent", "Workspace", "WorkspaceId", }); - internal_static_google_cloud_dataform_v1beta1_DeleteWorkspaceRequest_descriptor = + internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceMetadata_descriptor = getDescriptor().getMessageType(32); + internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_dataform_v1beta1_CreateWorkspaceMetadata_descriptor, + new java.lang.String[] { + "CreateWorkspaceRequest", "Id", "Target", "State", "Request", + }); + internal_static_google_cloud_dataform_v1beta1_DeleteWorkspaceRequest_descriptor = + getDescriptor().getMessageType(33); internal_static_google_cloud_dataform_v1beta1_DeleteWorkspaceRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteWorkspaceRequest_descriptor, @@ -2974,7 +3010,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_CommitAuthor_descriptor = - getDescriptor().getMessageType(33); + getDescriptor().getMessageType(34); internal_static_google_cloud_dataform_v1beta1_CommitAuthor_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CommitAuthor_descriptor, @@ -2982,7 +3018,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "EmailAddress", }); internal_static_google_cloud_dataform_v1beta1_PullGitCommitsRequest_descriptor = - getDescriptor().getMessageType(34); + getDescriptor().getMessageType(35); internal_static_google_cloud_dataform_v1beta1_PullGitCommitsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_PullGitCommitsRequest_descriptor, @@ -2990,13 +3026,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "RemoteBranch", "Author", }); internal_static_google_cloud_dataform_v1beta1_PullGitCommitsResponse_descriptor = - getDescriptor().getMessageType(35); + getDescriptor().getMessageType(36); internal_static_google_cloud_dataform_v1beta1_PullGitCommitsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_PullGitCommitsResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_CheckoutWorkspaceBranchRequest_descriptor = - getDescriptor().getMessageType(36); + getDescriptor().getMessageType(37); internal_static_google_cloud_dataform_v1beta1_CheckoutWorkspaceBranchRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CheckoutWorkspaceBranchRequest_descriptor, @@ -3004,7 +3040,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "Branch", "CreateIfNotExists", "SourceBranch", }); internal_static_google_cloud_dataform_v1beta1_SyncWorkspaceRefsRequest_descriptor = - getDescriptor().getMessageType(37); + getDescriptor().getMessageType(38); internal_static_google_cloud_dataform_v1beta1_SyncWorkspaceRefsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_SyncWorkspaceRefsRequest_descriptor, @@ -3012,13 +3048,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "RemoteBranchName", "Deepen", }); internal_static_google_cloud_dataform_v1beta1_SyncWorkspaceRefsResponse_descriptor = - getDescriptor().getMessageType(38); + getDescriptor().getMessageType(39); internal_static_google_cloud_dataform_v1beta1_SyncWorkspaceRefsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_SyncWorkspaceRefsResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_DeleteBranchRequest_descriptor = - getDescriptor().getMessageType(39); + getDescriptor().getMessageType(40); internal_static_google_cloud_dataform_v1beta1_DeleteBranchRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteBranchRequest_descriptor, @@ -3026,13 +3062,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "Branch", "Force", }); internal_static_google_cloud_dataform_v1beta1_DeleteBranchResponse_descriptor = - getDescriptor().getMessageType(40); + getDescriptor().getMessageType(41); internal_static_google_cloud_dataform_v1beta1_DeleteBranchResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteBranchResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_PushGitCommitsRequest_descriptor = - getDescriptor().getMessageType(41); + getDescriptor().getMessageType(42); internal_static_google_cloud_dataform_v1beta1_PushGitCommitsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_PushGitCommitsRequest_descriptor, @@ -3040,13 +3076,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "RemoteBranch", }); internal_static_google_cloud_dataform_v1beta1_PushGitCommitsResponse_descriptor = - getDescriptor().getMessageType(42); + getDescriptor().getMessageType(43); internal_static_google_cloud_dataform_v1beta1_PushGitCommitsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_PushGitCommitsResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_FetchFileGitStatusesRequest_descriptor = - getDescriptor().getMessageType(43); + getDescriptor().getMessageType(44); internal_static_google_cloud_dataform_v1beta1_FetchFileGitStatusesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchFileGitStatusesRequest_descriptor, @@ -3054,7 +3090,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_FetchFileGitStatusesResponse_descriptor = - getDescriptor().getMessageType(44); + getDescriptor().getMessageType(45); internal_static_google_cloud_dataform_v1beta1_FetchFileGitStatusesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchFileGitStatusesResponse_descriptor, @@ -3071,7 +3107,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Path", "State", }); internal_static_google_cloud_dataform_v1beta1_FetchGitAheadBehindRequest_descriptor = - getDescriptor().getMessageType(45); + getDescriptor().getMessageType(46); internal_static_google_cloud_dataform_v1beta1_FetchGitAheadBehindRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchGitAheadBehindRequest_descriptor, @@ -3079,7 +3115,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "RemoteBranch", }); internal_static_google_cloud_dataform_v1beta1_FetchGitAheadBehindResponse_descriptor = - getDescriptor().getMessageType(46); + getDescriptor().getMessageType(47); internal_static_google_cloud_dataform_v1beta1_FetchGitAheadBehindResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchGitAheadBehindResponse_descriptor, @@ -3087,7 +3123,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CommitsAhead", "CommitsBehind", }); internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceHistoryRequest_descriptor = - getDescriptor().getMessageType(47); + getDescriptor().getMessageType(48); internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceHistoryRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceHistoryRequest_descriptor, @@ -3095,7 +3131,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "PageSize", "PageToken", }); internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceHistoryResponse_descriptor = - getDescriptor().getMessageType(48); + getDescriptor().getMessageType(49); internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceHistoryResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceHistoryResponse_descriptor, @@ -3103,7 +3139,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Commits", "NextPageToken", "ReachesShallowBoundary", }); internal_static_google_cloud_dataform_v1beta1_CommitWorkspaceChangesRequest_descriptor = - getDescriptor().getMessageType(49); + getDescriptor().getMessageType(50); internal_static_google_cloud_dataform_v1beta1_CommitWorkspaceChangesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CommitWorkspaceChangesRequest_descriptor, @@ -3111,13 +3147,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "Author", "CommitMessage", "Paths", }); internal_static_google_cloud_dataform_v1beta1_CommitWorkspaceChangesResponse_descriptor = - getDescriptor().getMessageType(50); + getDescriptor().getMessageType(51); internal_static_google_cloud_dataform_v1beta1_CommitWorkspaceChangesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CommitWorkspaceChangesResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_ResetWorkspaceChangesRequest_descriptor = - getDescriptor().getMessageType(51); + getDescriptor().getMessageType(52); internal_static_google_cloud_dataform_v1beta1_ResetWorkspaceChangesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ResetWorkspaceChangesRequest_descriptor, @@ -3125,13 +3161,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "Paths", "Clean", }); internal_static_google_cloud_dataform_v1beta1_ResetWorkspaceChangesResponse_descriptor = - getDescriptor().getMessageType(52); + getDescriptor().getMessageType(53); internal_static_google_cloud_dataform_v1beta1_ResetWorkspaceChangesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ResetWorkspaceChangesResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_FetchFileDiffRequest_descriptor = - getDescriptor().getMessageType(53); + getDescriptor().getMessageType(54); internal_static_google_cloud_dataform_v1beta1_FetchFileDiffRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchFileDiffRequest_descriptor, @@ -3139,7 +3175,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Workspace", "Path", }); internal_static_google_cloud_dataform_v1beta1_FetchFileDiffResponse_descriptor = - getDescriptor().getMessageType(54); + getDescriptor().getMessageType(55); internal_static_google_cloud_dataform_v1beta1_FetchFileDiffResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchFileDiffResponse_descriptor, @@ -3147,7 +3183,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "FormattedDiff", }); internal_static_google_cloud_dataform_v1beta1_QueryDirectoryContentsRequest_descriptor = - getDescriptor().getMessageType(55); + getDescriptor().getMessageType(56); internal_static_google_cloud_dataform_v1beta1_QueryDirectoryContentsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryDirectoryContentsRequest_descriptor, @@ -3155,7 +3191,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Workspace", "Path", "PageSize", "PageToken", "View", }); internal_static_google_cloud_dataform_v1beta1_QueryDirectoryContentsResponse_descriptor = - getDescriptor().getMessageType(56); + getDescriptor().getMessageType(57); internal_static_google_cloud_dataform_v1beta1_QueryDirectoryContentsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryDirectoryContentsResponse_descriptor, @@ -3163,7 +3199,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "DirectoryEntries", "NextPageToken", }); internal_static_google_cloud_dataform_v1beta1_DirectoryEntry_descriptor = - getDescriptor().getMessageType(57); + getDescriptor().getMessageType(58); internal_static_google_cloud_dataform_v1beta1_DirectoryEntry_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DirectoryEntry_descriptor, @@ -3171,7 +3207,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "File", "Directory", "Metadata", "Entry", }); internal_static_google_cloud_dataform_v1beta1_FilesystemEntryMetadata_descriptor = - getDescriptor().getMessageType(58); + getDescriptor().getMessageType(59); internal_static_google_cloud_dataform_v1beta1_FilesystemEntryMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FilesystemEntryMetadata_descriptor, @@ -3179,7 +3215,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "SizeBytes", "UpdateTime", }); internal_static_google_cloud_dataform_v1beta1_SearchFilesRequest_descriptor = - getDescriptor().getMessageType(59); + getDescriptor().getMessageType(60); internal_static_google_cloud_dataform_v1beta1_SearchFilesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_SearchFilesRequest_descriptor, @@ -3187,7 +3223,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Workspace", "PageSize", "PageToken", "Filter", }); internal_static_google_cloud_dataform_v1beta1_SearchFilesResponse_descriptor = - getDescriptor().getMessageType(60); + getDescriptor().getMessageType(61); internal_static_google_cloud_dataform_v1beta1_SearchFilesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_SearchFilesResponse_descriptor, @@ -3195,7 +3231,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "SearchResults", "NextPageToken", }); internal_static_google_cloud_dataform_v1beta1_SearchResult_descriptor = - getDescriptor().getMessageType(61); + getDescriptor().getMessageType(62); internal_static_google_cloud_dataform_v1beta1_SearchResult_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_SearchResult_descriptor, @@ -3203,7 +3239,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "File", "Directory", "Entry", }); internal_static_google_cloud_dataform_v1beta1_FileSearchResult_descriptor = - getDescriptor().getMessageType(62); + getDescriptor().getMessageType(63); internal_static_google_cloud_dataform_v1beta1_FileSearchResult_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FileSearchResult_descriptor, @@ -3211,7 +3247,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Path", }); internal_static_google_cloud_dataform_v1beta1_DirectorySearchResult_descriptor = - getDescriptor().getMessageType(63); + getDescriptor().getMessageType(64); internal_static_google_cloud_dataform_v1beta1_DirectorySearchResult_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DirectorySearchResult_descriptor, @@ -3219,7 +3255,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Path", }); internal_static_google_cloud_dataform_v1beta1_MakeDirectoryRequest_descriptor = - getDescriptor().getMessageType(64); + getDescriptor().getMessageType(65); internal_static_google_cloud_dataform_v1beta1_MakeDirectoryRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_MakeDirectoryRequest_descriptor, @@ -3227,13 +3263,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Workspace", "Path", }); internal_static_google_cloud_dataform_v1beta1_MakeDirectoryResponse_descriptor = - getDescriptor().getMessageType(65); + getDescriptor().getMessageType(66); internal_static_google_cloud_dataform_v1beta1_MakeDirectoryResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_MakeDirectoryResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_RemoveDirectoryRequest_descriptor = - getDescriptor().getMessageType(66); + getDescriptor().getMessageType(67); internal_static_google_cloud_dataform_v1beta1_RemoveDirectoryRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_RemoveDirectoryRequest_descriptor, @@ -3241,13 +3277,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Workspace", "Path", }); internal_static_google_cloud_dataform_v1beta1_RemoveDirectoryResponse_descriptor = - getDescriptor().getMessageType(67); + getDescriptor().getMessageType(68); internal_static_google_cloud_dataform_v1beta1_RemoveDirectoryResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_RemoveDirectoryResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_MoveDirectoryRequest_descriptor = - getDescriptor().getMessageType(68); + getDescriptor().getMessageType(69); internal_static_google_cloud_dataform_v1beta1_MoveDirectoryRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_MoveDirectoryRequest_descriptor, @@ -3255,13 +3291,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Workspace", "Path", "NewPath", }); internal_static_google_cloud_dataform_v1beta1_MoveDirectoryResponse_descriptor = - getDescriptor().getMessageType(69); + getDescriptor().getMessageType(70); internal_static_google_cloud_dataform_v1beta1_MoveDirectoryResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_MoveDirectoryResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_ReadFileRequest_descriptor = - getDescriptor().getMessageType(70); + getDescriptor().getMessageType(71); internal_static_google_cloud_dataform_v1beta1_ReadFileRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ReadFileRequest_descriptor, @@ -3269,7 +3305,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Workspace", "Path", "Revision", }); internal_static_google_cloud_dataform_v1beta1_ReadFileResponse_descriptor = - getDescriptor().getMessageType(71); + getDescriptor().getMessageType(72); internal_static_google_cloud_dataform_v1beta1_ReadFileResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ReadFileResponse_descriptor, @@ -3277,7 +3313,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "FileContents", }); internal_static_google_cloud_dataform_v1beta1_RemoveFileRequest_descriptor = - getDescriptor().getMessageType(72); + getDescriptor().getMessageType(73); internal_static_google_cloud_dataform_v1beta1_RemoveFileRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_RemoveFileRequest_descriptor, @@ -3285,13 +3321,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Workspace", "Path", }); internal_static_google_cloud_dataform_v1beta1_RemoveFileResponse_descriptor = - getDescriptor().getMessageType(73); + getDescriptor().getMessageType(74); internal_static_google_cloud_dataform_v1beta1_RemoveFileResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_RemoveFileResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_MoveFileRequest_descriptor = - getDescriptor().getMessageType(74); + getDescriptor().getMessageType(75); internal_static_google_cloud_dataform_v1beta1_MoveFileRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_MoveFileRequest_descriptor, @@ -3299,13 +3335,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Workspace", "Path", "NewPath", }); internal_static_google_cloud_dataform_v1beta1_MoveFileResponse_descriptor = - getDescriptor().getMessageType(75); + getDescriptor().getMessageType(76); internal_static_google_cloud_dataform_v1beta1_MoveFileResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_MoveFileResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_WriteFileRequest_descriptor = - getDescriptor().getMessageType(76); + getDescriptor().getMessageType(77); internal_static_google_cloud_dataform_v1beta1_WriteFileRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_WriteFileRequest_descriptor, @@ -3313,13 +3349,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Workspace", "Path", "Contents", }); internal_static_google_cloud_dataform_v1beta1_WriteFileResponse_descriptor = - getDescriptor().getMessageType(77); + getDescriptor().getMessageType(78); internal_static_google_cloud_dataform_v1beta1_WriteFileResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_WriteFileResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_InstallNpmPackagesRequest_descriptor = - getDescriptor().getMessageType(78); + getDescriptor().getMessageType(79); internal_static_google_cloud_dataform_v1beta1_InstallNpmPackagesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_InstallNpmPackagesRequest_descriptor, @@ -3327,13 +3363,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Workspace", "PipelineConfig", }); internal_static_google_cloud_dataform_v1beta1_InstallNpmPackagesResponse_descriptor = - getDescriptor().getMessageType(79); + getDescriptor().getMessageType(80); internal_static_google_cloud_dataform_v1beta1_InstallNpmPackagesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_InstallNpmPackagesResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_ReleaseConfig_descriptor = - getDescriptor().getMessageType(80); + getDescriptor().getMessageType(81); internal_static_google_cloud_dataform_v1beta1_ReleaseConfig_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ReleaseConfig_descriptor, @@ -3357,7 +3393,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CompilationResult", "ErrorStatus", "ReleaseTime", "Result", }); internal_static_google_cloud_dataform_v1beta1_ListReleaseConfigsRequest_descriptor = - getDescriptor().getMessageType(81); + getDescriptor().getMessageType(82); internal_static_google_cloud_dataform_v1beta1_ListReleaseConfigsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ListReleaseConfigsRequest_descriptor, @@ -3365,7 +3401,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PageSize", "PageToken", }); internal_static_google_cloud_dataform_v1beta1_ListReleaseConfigsResponse_descriptor = - getDescriptor().getMessageType(82); + getDescriptor().getMessageType(83); internal_static_google_cloud_dataform_v1beta1_ListReleaseConfigsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ListReleaseConfigsResponse_descriptor, @@ -3373,7 +3409,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ReleaseConfigs", "NextPageToken", "Unreachable", }); internal_static_google_cloud_dataform_v1beta1_GetReleaseConfigRequest_descriptor = - getDescriptor().getMessageType(83); + getDescriptor().getMessageType(84); internal_static_google_cloud_dataform_v1beta1_GetReleaseConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_GetReleaseConfigRequest_descriptor, @@ -3381,7 +3417,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_CreateReleaseConfigRequest_descriptor = - getDescriptor().getMessageType(84); + getDescriptor().getMessageType(85); internal_static_google_cloud_dataform_v1beta1_CreateReleaseConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CreateReleaseConfigRequest_descriptor, @@ -3389,7 +3425,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "ReleaseConfig", "ReleaseConfigId", }); internal_static_google_cloud_dataform_v1beta1_UpdateReleaseConfigRequest_descriptor = - getDescriptor().getMessageType(85); + getDescriptor().getMessageType(86); internal_static_google_cloud_dataform_v1beta1_UpdateReleaseConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_UpdateReleaseConfigRequest_descriptor, @@ -3397,7 +3433,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "UpdateMask", "ReleaseConfig", }); internal_static_google_cloud_dataform_v1beta1_DeleteReleaseConfigRequest_descriptor = - getDescriptor().getMessageType(86); + getDescriptor().getMessageType(87); internal_static_google_cloud_dataform_v1beta1_DeleteReleaseConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteReleaseConfigRequest_descriptor, @@ -3405,7 +3441,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_CompilationResult_descriptor = - getDescriptor().getMessageType(87); + getDescriptor().getMessageType(88); internal_static_google_cloud_dataform_v1beta1_CompilationResult_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CompilationResult_descriptor, @@ -3434,7 +3470,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Message", "Stack", "Path", "ActionTarget", }); internal_static_google_cloud_dataform_v1beta1_WorkflowTriggerConfig_descriptor = - getDescriptor().getMessageType(88); + getDescriptor().getMessageType(89); internal_static_google_cloud_dataform_v1beta1_WorkflowTriggerConfig_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_WorkflowTriggerConfig_descriptor, @@ -3447,7 +3483,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "LastSuccessfulEvaluationTime", }); internal_static_google_cloud_dataform_v1beta1_TriggerEvaluationRecord_descriptor = - getDescriptor().getMessageType(89); + getDescriptor().getMessageType(90); internal_static_google_cloud_dataform_v1beta1_TriggerEvaluationRecord_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_TriggerEvaluationRecord_descriptor, @@ -3455,7 +3491,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "EvaluationTime", "Status", }); internal_static_google_cloud_dataform_v1beta1_WorkflowTrigger_descriptor = - getDescriptor().getMessageType(90); + getDescriptor().getMessageType(91); internal_static_google_cloud_dataform_v1beta1_WorkflowTrigger_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_WorkflowTrigger_descriptor, @@ -3463,7 +3499,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "TableUpdateTrigger", "Trigger", }); internal_static_google_cloud_dataform_v1beta1_TableUpdateTrigger_descriptor = - getDescriptor().getMessageType(91); + getDescriptor().getMessageType(92); internal_static_google_cloud_dataform_v1beta1_TableUpdateTrigger_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_TableUpdateTrigger_descriptor, @@ -3471,7 +3507,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Table", "TriggerUpdateTime", }); internal_static_google_cloud_dataform_v1beta1_CodeCompilationConfig_descriptor = - getDescriptor().getMessageType(92); + getDescriptor().getMessageType(93); internal_static_google_cloud_dataform_v1beta1_CodeCompilationConfig_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CodeCompilationConfig_descriptor, @@ -3499,7 +3535,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Key", "Value", }); internal_static_google_cloud_dataform_v1beta1_GcsRepositorySnapshotMetadata_descriptor = - getDescriptor().getMessageType(93); + getDescriptor().getMessageType(94); internal_static_google_cloud_dataform_v1beta1_GcsRepositorySnapshotMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_GcsRepositorySnapshotMetadata_descriptor, @@ -3507,7 +3543,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "RepositorySnapshotUri", "Crc32CChecksum", "Generation", }); internal_static_google_cloud_dataform_v1beta1_GcsRepositorySnapshotDestination_descriptor = - getDescriptor().getMessageType(94); + getDescriptor().getMessageType(95); internal_static_google_cloud_dataform_v1beta1_GcsRepositorySnapshotDestination_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_GcsRepositorySnapshotDestination_descriptor, @@ -3515,7 +3551,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "RepositorySnapshotUri", }); internal_static_google_cloud_dataform_v1beta1_NotebookRuntimeOptions_descriptor = - getDescriptor().getMessageType(95); + getDescriptor().getMessageType(96); internal_static_google_cloud_dataform_v1beta1_NotebookRuntimeOptions_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_NotebookRuntimeOptions_descriptor, @@ -3527,7 +3563,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "RepositorySnapshotStorage", }); internal_static_google_cloud_dataform_v1beta1_PipelineConfig_descriptor = - getDescriptor().getMessageType(96); + getDescriptor().getMessageType(97); internal_static_google_cloud_dataform_v1beta1_PipelineConfig_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_PipelineConfig_descriptor, @@ -3535,7 +3571,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "PipelineType", "Path", }); internal_static_google_cloud_dataform_v1beta1_ListCompilationResultsRequest_descriptor = - getDescriptor().getMessageType(97); + getDescriptor().getMessageType(98); internal_static_google_cloud_dataform_v1beta1_ListCompilationResultsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ListCompilationResultsRequest_descriptor, @@ -3543,7 +3579,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PageSize", "PageToken", "OrderBy", "Filter", }); internal_static_google_cloud_dataform_v1beta1_ListCompilationResultsResponse_descriptor = - getDescriptor().getMessageType(98); + getDescriptor().getMessageType(99); internal_static_google_cloud_dataform_v1beta1_ListCompilationResultsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ListCompilationResultsResponse_descriptor, @@ -3551,7 +3587,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CompilationResults", "NextPageToken", "Unreachable", }); internal_static_google_cloud_dataform_v1beta1_GetCompilationResultRequest_descriptor = - getDescriptor().getMessageType(99); + getDescriptor().getMessageType(100); internal_static_google_cloud_dataform_v1beta1_GetCompilationResultRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_GetCompilationResultRequest_descriptor, @@ -3559,7 +3595,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_CreateCompilationResultRequest_descriptor = - getDescriptor().getMessageType(100); + getDescriptor().getMessageType(101); internal_static_google_cloud_dataform_v1beta1_CreateCompilationResultRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CreateCompilationResultRequest_descriptor, @@ -3567,7 +3603,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "CompilationResult", }); internal_static_google_cloud_dataform_v1beta1_CreateCompilationResultMetadata_descriptor = - getDescriptor().getMessageType(101); + getDescriptor().getMessageType(102); internal_static_google_cloud_dataform_v1beta1_CreateCompilationResultMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CreateCompilationResultMetadata_descriptor, @@ -3575,7 +3611,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Id", "Target", "State", "CreateCompilationResultRequest", }); internal_static_google_cloud_dataform_v1beta1_Target_descriptor = - getDescriptor().getMessageType(102); + getDescriptor().getMessageType(103); internal_static_google_cloud_dataform_v1beta1_Target_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_Target_descriptor, @@ -3583,7 +3619,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Database", "Schema", "Name", }); internal_static_google_cloud_dataform_v1beta1_RelationDescriptor_descriptor = - getDescriptor().getMessageType(103); + getDescriptor().getMessageType(104); internal_static_google_cloud_dataform_v1beta1_RelationDescriptor_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_RelationDescriptor_descriptor, @@ -3609,7 +3645,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Key", "Value", }); internal_static_google_cloud_dataform_v1beta1_CompilationResultAction_descriptor = - getDescriptor().getMessageType(104); + getDescriptor().getMessageType(105); internal_static_google_cloud_dataform_v1beta1_CompilationResultAction_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CompilationResultAction_descriptor, @@ -3784,7 +3820,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Column", }); internal_static_google_cloud_dataform_v1beta1_QueryCompilationResultActionsRequest_descriptor = - getDescriptor().getMessageType(105); + getDescriptor().getMessageType(106); internal_static_google_cloud_dataform_v1beta1_QueryCompilationResultActionsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryCompilationResultActionsRequest_descriptor, @@ -3792,7 +3828,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "PageSize", "PageToken", "Filter", }); internal_static_google_cloud_dataform_v1beta1_QueryCompilationResultActionsResponse_descriptor = - getDescriptor().getMessageType(106); + getDescriptor().getMessageType(107); internal_static_google_cloud_dataform_v1beta1_QueryCompilationResultActionsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryCompilationResultActionsResponse_descriptor, @@ -3800,7 +3836,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CompilationResultActions", "NextPageToken", }); internal_static_google_cloud_dataform_v1beta1_WorkflowConfig_descriptor = - getDescriptor().getMessageType(107); + getDescriptor().getMessageType(108); internal_static_google_cloud_dataform_v1beta1_WorkflowConfig_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_WorkflowConfig_descriptor, @@ -3826,7 +3862,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "WorkflowInvocation", "ErrorStatus", "ExecutionTime", "Result", }); internal_static_google_cloud_dataform_v1beta1_InvocationConfig_descriptor = - getDescriptor().getMessageType(108); + getDescriptor().getMessageType(109); internal_static_google_cloud_dataform_v1beta1_InvocationConfig_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_InvocationConfig_descriptor, @@ -3851,7 +3887,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "UserEmail", "OauthConfig", }); internal_static_google_cloud_dataform_v1beta1_ListWorkflowConfigsRequest_descriptor = - getDescriptor().getMessageType(109); + getDescriptor().getMessageType(110); internal_static_google_cloud_dataform_v1beta1_ListWorkflowConfigsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ListWorkflowConfigsRequest_descriptor, @@ -3859,7 +3895,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PageSize", "PageToken", }); internal_static_google_cloud_dataform_v1beta1_ListWorkflowConfigsResponse_descriptor = - getDescriptor().getMessageType(110); + getDescriptor().getMessageType(111); internal_static_google_cloud_dataform_v1beta1_ListWorkflowConfigsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ListWorkflowConfigsResponse_descriptor, @@ -3867,7 +3903,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "WorkflowConfigs", "NextPageToken", "Unreachable", }); internal_static_google_cloud_dataform_v1beta1_GetWorkflowConfigRequest_descriptor = - getDescriptor().getMessageType(111); + getDescriptor().getMessageType(112); internal_static_google_cloud_dataform_v1beta1_GetWorkflowConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_GetWorkflowConfigRequest_descriptor, @@ -3875,7 +3911,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_CreateWorkflowConfigRequest_descriptor = - getDescriptor().getMessageType(112); + getDescriptor().getMessageType(113); internal_static_google_cloud_dataform_v1beta1_CreateWorkflowConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CreateWorkflowConfigRequest_descriptor, @@ -3883,7 +3919,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "WorkflowConfig", "WorkflowConfigId", }); internal_static_google_cloud_dataform_v1beta1_UpdateWorkflowConfigRequest_descriptor = - getDescriptor().getMessageType(113); + getDescriptor().getMessageType(114); internal_static_google_cloud_dataform_v1beta1_UpdateWorkflowConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_UpdateWorkflowConfigRequest_descriptor, @@ -3891,7 +3927,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "UpdateMask", "WorkflowConfig", }); internal_static_google_cloud_dataform_v1beta1_DeleteWorkflowConfigRequest_descriptor = - getDescriptor().getMessageType(114); + getDescriptor().getMessageType(115); internal_static_google_cloud_dataform_v1beta1_DeleteWorkflowConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteWorkflowConfigRequest_descriptor, @@ -3899,7 +3935,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_WorkflowInvocation_descriptor = - getDescriptor().getMessageType(115); + getDescriptor().getMessageType(116); internal_static_google_cloud_dataform_v1beta1_WorkflowInvocation_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_WorkflowInvocation_descriptor, @@ -3918,7 +3954,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CompilationSource", }); internal_static_google_cloud_dataform_v1beta1_ListWorkflowInvocationsRequest_descriptor = - getDescriptor().getMessageType(116); + getDescriptor().getMessageType(117); internal_static_google_cloud_dataform_v1beta1_ListWorkflowInvocationsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ListWorkflowInvocationsRequest_descriptor, @@ -3926,7 +3962,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PageSize", "PageToken", "OrderBy", "Filter", }); internal_static_google_cloud_dataform_v1beta1_ListWorkflowInvocationsResponse_descriptor = - getDescriptor().getMessageType(117); + getDescriptor().getMessageType(118); internal_static_google_cloud_dataform_v1beta1_ListWorkflowInvocationsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_ListWorkflowInvocationsResponse_descriptor, @@ -3934,7 +3970,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "WorkflowInvocations", "NextPageToken", "Unreachable", }); internal_static_google_cloud_dataform_v1beta1_GetWorkflowInvocationRequest_descriptor = - getDescriptor().getMessageType(118); + getDescriptor().getMessageType(119); internal_static_google_cloud_dataform_v1beta1_GetWorkflowInvocationRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_GetWorkflowInvocationRequest_descriptor, @@ -3942,7 +3978,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_CreateWorkflowInvocationRequest_descriptor = - getDescriptor().getMessageType(119); + getDescriptor().getMessageType(120); internal_static_google_cloud_dataform_v1beta1_CreateWorkflowInvocationRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CreateWorkflowInvocationRequest_descriptor, @@ -3950,7 +3986,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "WorkflowInvocation", }); internal_static_google_cloud_dataform_v1beta1_DeleteWorkflowInvocationRequest_descriptor = - getDescriptor().getMessageType(120); + getDescriptor().getMessageType(121); internal_static_google_cloud_dataform_v1beta1_DeleteWorkflowInvocationRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteWorkflowInvocationRequest_descriptor, @@ -3958,7 +3994,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_CancelWorkflowInvocationRequest_descriptor = - getDescriptor().getMessageType(121); + getDescriptor().getMessageType(122); internal_static_google_cloud_dataform_v1beta1_CancelWorkflowInvocationRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CancelWorkflowInvocationRequest_descriptor, @@ -3966,13 +4002,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_CancelWorkflowInvocationResponse_descriptor = - getDescriptor().getMessageType(122); + getDescriptor().getMessageType(123); internal_static_google_cloud_dataform_v1beta1_CancelWorkflowInvocationResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CancelWorkflowInvocationResponse_descriptor, new java.lang.String[] {}); internal_static_google_cloud_dataform_v1beta1_WorkflowInvocationAction_descriptor = - getDescriptor().getMessageType(123); + getDescriptor().getMessageType(124); internal_static_google_cloud_dataform_v1beta1_WorkflowInvocationAction_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_WorkflowInvocationAction_descriptor, @@ -4074,7 +4110,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "TotalBilledBytes", }); internal_static_google_cloud_dataform_v1beta1_QueryWorkflowInvocationActionsRequest_descriptor = - getDescriptor().getMessageType(124); + getDescriptor().getMessageType(125); internal_static_google_cloud_dataform_v1beta1_QueryWorkflowInvocationActionsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryWorkflowInvocationActionsRequest_descriptor, @@ -4082,7 +4118,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "PageSize", "PageToken", }); internal_static_google_cloud_dataform_v1beta1_QueryWorkflowInvocationActionsResponse_descriptor = - getDescriptor().getMessageType(125); + getDescriptor().getMessageType(126); internal_static_google_cloud_dataform_v1beta1_QueryWorkflowInvocationActionsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryWorkflowInvocationActionsResponse_descriptor, @@ -4090,7 +4126,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "WorkflowInvocationActions", "NextPageToken", }); internal_static_google_cloud_dataform_v1beta1_Config_descriptor = - getDescriptor().getMessageType(126); + getDescriptor().getMessageType(127); internal_static_google_cloud_dataform_v1beta1_Config_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_Config_descriptor, @@ -4098,7 +4134,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "DefaultKmsKeyName", "InternalMetadata", }); internal_static_google_cloud_dataform_v1beta1_GetConfigRequest_descriptor = - getDescriptor().getMessageType(127); + getDescriptor().getMessageType(128); internal_static_google_cloud_dataform_v1beta1_GetConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_GetConfigRequest_descriptor, @@ -4106,7 +4142,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_UpdateConfigRequest_descriptor = - getDescriptor().getMessageType(128); + getDescriptor().getMessageType(129); internal_static_google_cloud_dataform_v1beta1_UpdateConfigRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_UpdateConfigRequest_descriptor, @@ -4114,7 +4150,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Config", "UpdateMask", }); internal_static_google_cloud_dataform_v1beta1_Folder_descriptor = - getDescriptor().getMessageType(129); + getDescriptor().getMessageType(130); internal_static_google_cloud_dataform_v1beta1_Folder_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_Folder_descriptor, @@ -4129,7 +4165,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CreatorIamPrincipal", }); internal_static_google_cloud_dataform_v1beta1_CreateFolderRequest_descriptor = - getDescriptor().getMessageType(130); + getDescriptor().getMessageType(131); internal_static_google_cloud_dataform_v1beta1_CreateFolderRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CreateFolderRequest_descriptor, @@ -4137,7 +4173,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "Folder", "FolderId", }); internal_static_google_cloud_dataform_v1beta1_MoveFolderRequest_descriptor = - getDescriptor().getMessageType(131); + getDescriptor().getMessageType(132); internal_static_google_cloud_dataform_v1beta1_MoveFolderRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_MoveFolderRequest_descriptor, @@ -4145,7 +4181,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "DestinationContainingFolder", }); internal_static_google_cloud_dataform_v1beta1_GetFolderRequest_descriptor = - getDescriptor().getMessageType(132); + getDescriptor().getMessageType(133); internal_static_google_cloud_dataform_v1beta1_GetFolderRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_GetFolderRequest_descriptor, @@ -4153,7 +4189,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_UpdateFolderRequest_descriptor = - getDescriptor().getMessageType(133); + getDescriptor().getMessageType(134); internal_static_google_cloud_dataform_v1beta1_UpdateFolderRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_UpdateFolderRequest_descriptor, @@ -4161,7 +4197,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "UpdateMask", "Folder", }); internal_static_google_cloud_dataform_v1beta1_DeleteFolderRequest_descriptor = - getDescriptor().getMessageType(134); + getDescriptor().getMessageType(135); internal_static_google_cloud_dataform_v1beta1_DeleteFolderRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteFolderRequest_descriptor, @@ -4169,7 +4205,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_DeleteFolderTreeRequest_descriptor = - getDescriptor().getMessageType(135); + getDescriptor().getMessageType(136); internal_static_google_cloud_dataform_v1beta1_DeleteFolderTreeRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteFolderTreeRequest_descriptor, @@ -4177,7 +4213,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "Force", }); internal_static_google_cloud_dataform_v1beta1_DeleteTeamFolderTreeRequest_descriptor = - getDescriptor().getMessageType(136); + getDescriptor().getMessageType(137); internal_static_google_cloud_dataform_v1beta1_DeleteTeamFolderTreeRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteTeamFolderTreeRequest_descriptor, @@ -4185,7 +4221,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "Force", }); internal_static_google_cloud_dataform_v1beta1_DeleteFolderTreeMetadata_descriptor = - getDescriptor().getMessageType(137); + getDescriptor().getMessageType(138); internal_static_google_cloud_dataform_v1beta1_DeleteFolderTreeMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteFolderTreeMetadata_descriptor, @@ -4193,7 +4229,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CreateTime", "EndTime", "Target", "State", "PercentComplete", }); internal_static_google_cloud_dataform_v1beta1_QueryFolderContentsRequest_descriptor = - getDescriptor().getMessageType(138); + getDescriptor().getMessageType(139); internal_static_google_cloud_dataform_v1beta1_QueryFolderContentsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryFolderContentsRequest_descriptor, @@ -4201,7 +4237,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Folder", "PageSize", "PageToken", "OrderBy", "Filter", }); internal_static_google_cloud_dataform_v1beta1_QueryFolderContentsResponse_descriptor = - getDescriptor().getMessageType(139); + getDescriptor().getMessageType(140); internal_static_google_cloud_dataform_v1beta1_QueryFolderContentsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryFolderContentsResponse_descriptor, @@ -4218,7 +4254,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Folder", "Repository", "Entry", }); internal_static_google_cloud_dataform_v1beta1_QueryUserRootContentsRequest_descriptor = - getDescriptor().getMessageType(140); + getDescriptor().getMessageType(141); internal_static_google_cloud_dataform_v1beta1_QueryUserRootContentsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryUserRootContentsRequest_descriptor, @@ -4226,7 +4262,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Location", "PageSize", "PageToken", "OrderBy", "Filter", }); internal_static_google_cloud_dataform_v1beta1_QueryUserRootContentsResponse_descriptor = - getDescriptor().getMessageType(141); + getDescriptor().getMessageType(142); internal_static_google_cloud_dataform_v1beta1_QueryUserRootContentsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryUserRootContentsResponse_descriptor, @@ -4243,7 +4279,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Folder", "Repository", "Entry", }); internal_static_google_cloud_dataform_v1beta1_TeamFolder_descriptor = - getDescriptor().getMessageType(142); + getDescriptor().getMessageType(143); internal_static_google_cloud_dataform_v1beta1_TeamFolder_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_TeamFolder_descriptor, @@ -4256,7 +4292,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CreatorIamPrincipal", }); internal_static_google_cloud_dataform_v1beta1_CreateTeamFolderRequest_descriptor = - getDescriptor().getMessageType(143); + getDescriptor().getMessageType(144); internal_static_google_cloud_dataform_v1beta1_CreateTeamFolderRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_CreateTeamFolderRequest_descriptor, @@ -4264,7 +4300,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "TeamFolder", "TeamFolderId", }); internal_static_google_cloud_dataform_v1beta1_GetTeamFolderRequest_descriptor = - getDescriptor().getMessageType(144); + getDescriptor().getMessageType(145); internal_static_google_cloud_dataform_v1beta1_GetTeamFolderRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_GetTeamFolderRequest_descriptor, @@ -4272,7 +4308,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_UpdateTeamFolderRequest_descriptor = - getDescriptor().getMessageType(145); + getDescriptor().getMessageType(146); internal_static_google_cloud_dataform_v1beta1_UpdateTeamFolderRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_UpdateTeamFolderRequest_descriptor, @@ -4280,7 +4316,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "UpdateMask", "TeamFolder", }); internal_static_google_cloud_dataform_v1beta1_DeleteTeamFolderRequest_descriptor = - getDescriptor().getMessageType(146); + getDescriptor().getMessageType(147); internal_static_google_cloud_dataform_v1beta1_DeleteTeamFolderRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteTeamFolderRequest_descriptor, @@ -4288,7 +4324,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_QueryTeamFolderContentsRequest_descriptor = - getDescriptor().getMessageType(147); + getDescriptor().getMessageType(148); internal_static_google_cloud_dataform_v1beta1_QueryTeamFolderContentsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryTeamFolderContentsRequest_descriptor, @@ -4296,7 +4332,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "TeamFolder", "PageSize", "PageToken", "OrderBy", "Filter", }); internal_static_google_cloud_dataform_v1beta1_QueryTeamFolderContentsResponse_descriptor = - getDescriptor().getMessageType(148); + getDescriptor().getMessageType(149); internal_static_google_cloud_dataform_v1beta1_QueryTeamFolderContentsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_QueryTeamFolderContentsResponse_descriptor, @@ -4313,7 +4349,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Folder", "Repository", "Entry", }); internal_static_google_cloud_dataform_v1beta1_SearchTeamFoldersRequest_descriptor = - getDescriptor().getMessageType(149); + getDescriptor().getMessageType(150); internal_static_google_cloud_dataform_v1beta1_SearchTeamFoldersRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_SearchTeamFoldersRequest_descriptor, @@ -4321,7 +4357,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Location", "PageSize", "PageToken", "OrderBy", "Filter", }); internal_static_google_cloud_dataform_v1beta1_SearchTeamFoldersResponse_descriptor = - getDescriptor().getMessageType(150); + getDescriptor().getMessageType(151); internal_static_google_cloud_dataform_v1beta1_SearchTeamFoldersResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_SearchTeamFoldersResponse_descriptor, @@ -4338,7 +4374,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "TeamFolder", "Entry", }); internal_static_google_cloud_dataform_v1beta1_MoveFolderMetadata_descriptor = - getDescriptor().getMessageType(151); + getDescriptor().getMessageType(152); internal_static_google_cloud_dataform_v1beta1_MoveFolderMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_MoveFolderMetadata_descriptor, @@ -4346,7 +4382,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CreateTime", "EndTime", "Target", "State", "PercentComplete", }); internal_static_google_cloud_dataform_v1beta1_MoveRepositoryMetadata_descriptor = - getDescriptor().getMessageType(152); + getDescriptor().getMessageType(153); internal_static_google_cloud_dataform_v1beta1_MoveRepositoryMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_MoveRepositoryMetadata_descriptor, @@ -4354,7 +4390,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CreateTime", "EndTime", "Target", "State", "PercentComplete", }); internal_static_google_cloud_dataform_v1beta1_DeleteRepositoryLongRunningMetadata_descriptor = - getDescriptor().getMessageType(153); + getDescriptor().getMessageType(154); internal_static_google_cloud_dataform_v1beta1_DeleteRepositoryLongRunningMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_DeleteRepositoryLongRunningMetadata_descriptor, @@ -4368,7 +4404,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "RemainingChildResourcesCount", }); internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceBranchesRequest_descriptor = - getDescriptor().getMessageType(154); + getDescriptor().getMessageType(155); internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceBranchesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceBranchesRequest_descriptor, @@ -4376,7 +4412,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "Filter", "PageSize", "PageToken", }); internal_static_google_cloud_dataform_v1beta1_BranchMetadata_descriptor = - getDescriptor().getMessageType(155); + getDescriptor().getMessageType(156); internal_static_google_cloud_dataform_v1beta1_BranchMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_BranchMetadata_descriptor, @@ -4384,7 +4420,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "BranchName", "LastCommit", }); internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceBranchesResponse_descriptor = - getDescriptor().getMessageType(156); + getDescriptor().getMessageType(157); internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceBranchesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchWorkspaceBranchesResponse_descriptor, @@ -4392,7 +4428,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Branches", "NextPageToken", }); internal_static_google_cloud_dataform_v1beta1_FetchCurrentWorkspaceBranchRequest_descriptor = - getDescriptor().getMessageType(157); + getDescriptor().getMessageType(158); internal_static_google_cloud_dataform_v1beta1_FetchCurrentWorkspaceBranchRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchCurrentWorkspaceBranchRequest_descriptor, @@ -4400,7 +4436,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_cloud_dataform_v1beta1_FetchCurrentWorkspaceBranchResponse_descriptor = - getDescriptor().getMessageType(158); + getDescriptor().getMessageType(159); internal_static_google_cloud_dataform_v1beta1_FetchCurrentWorkspaceBranchResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataform_v1beta1_FetchCurrentWorkspaceBranchResponse_descriptor, diff --git a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/Repository.java b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/Repository.java index 455ed2ad6d68..30a75239c007 100644 --- a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/Repository.java +++ b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/java/com/google/cloud/dataform/v1beta1/Repository.java @@ -375,7 +375,7 @@ public interface GitRemoteSettingsOrBuilder * * * @deprecated google.cloud.dataform.v1beta1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1002 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1016 * @return The enum numeric value on the wire for tokenStatus. */ @java.lang.Deprecated @@ -395,7 +395,7 @@ public interface GitRemoteSettingsOrBuilder * * * @deprecated google.cloud.dataform.v1beta1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1002 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1016 * @return The tokenStatus. */ @java.lang.Deprecated @@ -2062,7 +2062,7 @@ public com.google.protobuf.ByteString getGitRepositoryLinkBytes() { * * * @deprecated google.cloud.dataform.v1beta1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1002 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1016 * @return The enum numeric value on the wire for tokenStatus. */ @java.lang.Override @@ -2085,7 +2085,7 @@ public int getTokenStatusValue() { * * * @deprecated google.cloud.dataform.v1beta1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1002 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1016 * @return The tokenStatus. */ @java.lang.Override @@ -3669,7 +3669,7 @@ public Builder setGitRepositoryLinkBytes(com.google.protobuf.ByteString value) { * * * @deprecated google.cloud.dataform.v1beta1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1002 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1016 * @return The enum numeric value on the wire for tokenStatus. */ @java.lang.Override @@ -3692,7 +3692,7 @@ public int getTokenStatusValue() { * * * @deprecated google.cloud.dataform.v1beta1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1002 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1016 * @param value The enum numeric value on the wire for tokenStatus to set. * @return This builder for chaining. */ @@ -3718,7 +3718,7 @@ public Builder setTokenStatusValue(int value) { * * * @deprecated google.cloud.dataform.v1beta1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1002 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1016 * @return The tokenStatus. */ @java.lang.Override @@ -3748,7 +3748,7 @@ public Builder setTokenStatusValue(int value) { * * * @deprecated google.cloud.dataform.v1beta1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1002 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1016 * @param value The tokenStatus to set. * @return This builder for chaining. */ @@ -3778,7 +3778,7 @@ public Builder setTokenStatus( * * * @deprecated google.cloud.dataform.v1beta1.Repository.GitRemoteSettings.token_status is - * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1002 + * deprecated. See google/cloud/dataform/v1beta1/dataform.proto;l=1016 * @return This builder for chaining. */ @java.lang.Deprecated diff --git a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/proto/google/cloud/dataform/v1beta1/dataform.proto b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/proto/google/cloud/dataform/v1beta1/dataform.proto index 83732afbd728..386fff57a40c 100644 --- a/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/proto/google/cloud/dataform/v1beta1/dataform.proto +++ b/java-dataform/proto-google-cloud-dataform-v1beta1/src/main/proto/google/cloud/dataform/v1beta1/dataform.proto @@ -384,6 +384,20 @@ service Dataform { option (google.api.method_signature) = "parent,workspace,workspace_id"; } + // Creates a new Workspace in a given Repository asynchronously. + rpc CreateWorkspaceLongRunning(CreateWorkspaceRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1beta1/{parent=projects/*/locations/*/repositories/*}/workspaces:createLongRunning" + body: "workspace" + }; + option (google.api.method_signature) = "parent,workspace,workspace_id"; + option (google.longrunning.operation_info) = { + response_type: "Workspace" + metadata_type: "CreateWorkspaceMetadata" + }; + } + // Deletes a single Workspace. rpc DeleteWorkspace(DeleteWorkspaceRequest) returns (google.protobuf.Empty) { option (google.api.http) = { @@ -1658,6 +1672,46 @@ message CreateWorkspaceRequest { string workspace_id = 3 [(google.api.field_behavior) = REQUIRED]; } +// Represents the metadata of the `CreateWorkspaceLongRunning` operation. +message CreateWorkspaceMetadata { + // State of the LRO. + enum State { + // The state is unspecified. + STATE_UNSPECIFIED = 0; + + // The LRO has been created. + CREATED = 1; + + // The LRO is in progress. + RUNNING = 2; + + // The RPC call has finished. + FINISHED = 3; + + // The LRO has succeeded. + SUCCEEDED = 4; + + // The LRO has failed. + FAILED = 5; + } + + // The unwrapped request. + oneof request { + // Output only. The CreateWorkspace requested. + CreateWorkspaceRequest create_workspace_request = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; + } + + // Output only. The ID of the LRO. + string id = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Server-defined resource path for the target of the operation. + string target = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The state of the LRO. + State state = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; +} + // `DeleteWorkspace` request message. message DeleteWorkspaceRequest { // Required. The workspace resource's name. diff --git a/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunning.java b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunning.java new file mode 100644 index 000000000000..48a2d07df183 --- /dev/null +++ b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunning.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.dataform.v1.samples; + +// [START dataform_v1_generated_Dataform_CreateWorkspaceLongRunning_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataform.v1.CreateWorkspaceRequest; +import com.google.cloud.dataform.v1.DataformClient; +import com.google.cloud.dataform.v1.RepositoryName; +import com.google.cloud.dataform.v1.Workspace; +import com.google.longrunning.Operation; + +public class AsyncCreateWorkspaceLongRunning { + + public static void main(String[] args) throws Exception { + asyncCreateWorkspaceLongRunning(); + } + + public static void asyncCreateWorkspaceLongRunning() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (DataformClient dataformClient = DataformClient.create()) { + CreateWorkspaceRequest request = + CreateWorkspaceRequest.newBuilder() + .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString()) + .setWorkspace(Workspace.newBuilder().build()) + .setWorkspaceId("workspaceId466560144") + .build(); + ApiFuture future = + dataformClient.createWorkspaceLongRunningCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END dataform_v1_generated_Dataform_CreateWorkspaceLongRunning_async] diff --git a/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunningLRO.java b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunningLRO.java new file mode 100644 index 000000000000..342ebe5c6b94 --- /dev/null +++ b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunningLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.dataform.v1.samples; + +// [START dataform_v1_generated_Dataform_CreateWorkspaceLongRunning_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.dataform.v1.CreateWorkspaceMetadata; +import com.google.cloud.dataform.v1.CreateWorkspaceRequest; +import com.google.cloud.dataform.v1.DataformClient; +import com.google.cloud.dataform.v1.RepositoryName; +import com.google.cloud.dataform.v1.Workspace; + +public class AsyncCreateWorkspaceLongRunningLRO { + + public static void main(String[] args) throws Exception { + asyncCreateWorkspaceLongRunningLRO(); + } + + public static void asyncCreateWorkspaceLongRunningLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (DataformClient dataformClient = DataformClient.create()) { + CreateWorkspaceRequest request = + CreateWorkspaceRequest.newBuilder() + .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString()) + .setWorkspace(Workspace.newBuilder().build()) + .setWorkspaceId("workspaceId466560144") + .build(); + OperationFuture future = + dataformClient.createWorkspaceLongRunningOperationCallable().futureCall(request); + // Do something. + Workspace response = future.get(); + } + } +} +// [END dataform_v1_generated_Dataform_CreateWorkspaceLongRunning_LRO_async] diff --git a/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunning.java b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunning.java new file mode 100644 index 000000000000..bc11a42e4b46 --- /dev/null +++ b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunning.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.dataform.v1.samples; + +// [START dataform_v1_generated_Dataform_CreateWorkspaceLongRunning_sync] +import com.google.cloud.dataform.v1.CreateWorkspaceRequest; +import com.google.cloud.dataform.v1.DataformClient; +import com.google.cloud.dataform.v1.RepositoryName; +import com.google.cloud.dataform.v1.Workspace; + +public class SyncCreateWorkspaceLongRunning { + + public static void main(String[] args) throws Exception { + syncCreateWorkspaceLongRunning(); + } + + public static void syncCreateWorkspaceLongRunning() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (DataformClient dataformClient = DataformClient.create()) { + CreateWorkspaceRequest request = + CreateWorkspaceRequest.newBuilder() + .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString()) + .setWorkspace(Workspace.newBuilder().build()) + .setWorkspaceId("workspaceId466560144") + .build(); + Workspace response = dataformClient.createWorkspaceLongRunningAsync(request).get(); + } + } +} +// [END dataform_v1_generated_Dataform_CreateWorkspaceLongRunning_sync] diff --git a/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningRepositorynameWorkspaceString.java b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningRepositorynameWorkspaceString.java new file mode 100644 index 000000000000..07ad9099437b --- /dev/null +++ b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningRepositorynameWorkspaceString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.dataform.v1.samples; + +// [START dataform_v1_generated_Dataform_CreateWorkspaceLongRunning_RepositorynameWorkspaceString_sync] +import com.google.cloud.dataform.v1.DataformClient; +import com.google.cloud.dataform.v1.RepositoryName; +import com.google.cloud.dataform.v1.Workspace; + +public class SyncCreateWorkspaceLongRunningRepositorynameWorkspaceString { + + public static void main(String[] args) throws Exception { + syncCreateWorkspaceLongRunningRepositorynameWorkspaceString(); + } + + public static void syncCreateWorkspaceLongRunningRepositorynameWorkspaceString() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (DataformClient dataformClient = DataformClient.create()) { + RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]"); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + Workspace response = + dataformClient.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + } + } +} +// [END dataform_v1_generated_Dataform_CreateWorkspaceLongRunning_RepositorynameWorkspaceString_sync] diff --git a/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningStringWorkspaceString.java b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningStringWorkspaceString.java new file mode 100644 index 000000000000..c0628b12ddc8 --- /dev/null +++ b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningStringWorkspaceString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.dataform.v1.samples; + +// [START dataform_v1_generated_Dataform_CreateWorkspaceLongRunning_StringWorkspaceString_sync] +import com.google.cloud.dataform.v1.DataformClient; +import com.google.cloud.dataform.v1.RepositoryName; +import com.google.cloud.dataform.v1.Workspace; + +public class SyncCreateWorkspaceLongRunningStringWorkspaceString { + + public static void main(String[] args) throws Exception { + syncCreateWorkspaceLongRunningStringWorkspaceString(); + } + + public static void syncCreateWorkspaceLongRunningStringWorkspaceString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (DataformClient dataformClient = DataformClient.create()) { + String parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString(); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + Workspace response = + dataformClient.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + } + } +} +// [END dataform_v1_generated_Dataform_CreateWorkspaceLongRunning_StringWorkspaceString_sync] diff --git a/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunning.java b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunning.java new file mode 100644 index 000000000000..5e5b016ed366 --- /dev/null +++ b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunning.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.dataform.v1beta1.samples; + +// [START dataform_v1beta1_generated_Dataform_CreateWorkspaceLongRunning_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest; +import com.google.cloud.dataform.v1beta1.DataformClient; +import com.google.cloud.dataform.v1beta1.RepositoryName; +import com.google.cloud.dataform.v1beta1.Workspace; +import com.google.longrunning.Operation; + +public class AsyncCreateWorkspaceLongRunning { + + public static void main(String[] args) throws Exception { + asyncCreateWorkspaceLongRunning(); + } + + public static void asyncCreateWorkspaceLongRunning() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (DataformClient dataformClient = DataformClient.create()) { + CreateWorkspaceRequest request = + CreateWorkspaceRequest.newBuilder() + .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString()) + .setWorkspace(Workspace.newBuilder().build()) + .setWorkspaceId("workspaceId466560144") + .build(); + ApiFuture future = + dataformClient.createWorkspaceLongRunningCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END dataform_v1beta1_generated_Dataform_CreateWorkspaceLongRunning_async] diff --git a/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunningLRO.java b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunningLRO.java new file mode 100644 index 000000000000..ff935164a02c --- /dev/null +++ b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/AsyncCreateWorkspaceLongRunningLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.dataform.v1beta1.samples; + +// [START dataform_v1beta1_generated_Dataform_CreateWorkspaceLongRunning_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.dataform.v1beta1.CreateWorkspaceMetadata; +import com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest; +import com.google.cloud.dataform.v1beta1.DataformClient; +import com.google.cloud.dataform.v1beta1.RepositoryName; +import com.google.cloud.dataform.v1beta1.Workspace; + +public class AsyncCreateWorkspaceLongRunningLRO { + + public static void main(String[] args) throws Exception { + asyncCreateWorkspaceLongRunningLRO(); + } + + public static void asyncCreateWorkspaceLongRunningLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (DataformClient dataformClient = DataformClient.create()) { + CreateWorkspaceRequest request = + CreateWorkspaceRequest.newBuilder() + .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString()) + .setWorkspace(Workspace.newBuilder().build()) + .setWorkspaceId("workspaceId466560144") + .build(); + OperationFuture future = + dataformClient.createWorkspaceLongRunningOperationCallable().futureCall(request); + // Do something. + Workspace response = future.get(); + } + } +} +// [END dataform_v1beta1_generated_Dataform_CreateWorkspaceLongRunning_LRO_async] diff --git a/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunning.java b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunning.java new file mode 100644 index 000000000000..f41c03f6dd4b --- /dev/null +++ b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunning.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.dataform.v1beta1.samples; + +// [START dataform_v1beta1_generated_Dataform_CreateWorkspaceLongRunning_sync] +import com.google.cloud.dataform.v1beta1.CreateWorkspaceRequest; +import com.google.cloud.dataform.v1beta1.DataformClient; +import com.google.cloud.dataform.v1beta1.RepositoryName; +import com.google.cloud.dataform.v1beta1.Workspace; + +public class SyncCreateWorkspaceLongRunning { + + public static void main(String[] args) throws Exception { + syncCreateWorkspaceLongRunning(); + } + + public static void syncCreateWorkspaceLongRunning() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (DataformClient dataformClient = DataformClient.create()) { + CreateWorkspaceRequest request = + CreateWorkspaceRequest.newBuilder() + .setParent(RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString()) + .setWorkspace(Workspace.newBuilder().build()) + .setWorkspaceId("workspaceId466560144") + .build(); + Workspace response = dataformClient.createWorkspaceLongRunningAsync(request).get(); + } + } +} +// [END dataform_v1beta1_generated_Dataform_CreateWorkspaceLongRunning_sync] diff --git a/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningRepositorynameWorkspaceString.java b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningRepositorynameWorkspaceString.java new file mode 100644 index 000000000000..32b81708a710 --- /dev/null +++ b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningRepositorynameWorkspaceString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.dataform.v1beta1.samples; + +// [START dataform_v1beta1_generated_Dataform_CreateWorkspaceLongRunning_RepositorynameWorkspaceString_sync] +import com.google.cloud.dataform.v1beta1.DataformClient; +import com.google.cloud.dataform.v1beta1.RepositoryName; +import com.google.cloud.dataform.v1beta1.Workspace; + +public class SyncCreateWorkspaceLongRunningRepositorynameWorkspaceString { + + public static void main(String[] args) throws Exception { + syncCreateWorkspaceLongRunningRepositorynameWorkspaceString(); + } + + public static void syncCreateWorkspaceLongRunningRepositorynameWorkspaceString() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (DataformClient dataformClient = DataformClient.create()) { + RepositoryName parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]"); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + Workspace response = + dataformClient.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + } + } +} +// [END dataform_v1beta1_generated_Dataform_CreateWorkspaceLongRunning_RepositorynameWorkspaceString_sync] diff --git a/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningStringWorkspaceString.java b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningStringWorkspaceString.java new file mode 100644 index 000000000000..a2ac40229a37 --- /dev/null +++ b/java-dataform/samples/snippets/generated/com/google/cloud/dataform/v1beta1/dataform/createworkspacelongrunning/SyncCreateWorkspaceLongRunningStringWorkspaceString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.dataform.v1beta1.samples; + +// [START dataform_v1beta1_generated_Dataform_CreateWorkspaceLongRunning_StringWorkspaceString_sync] +import com.google.cloud.dataform.v1beta1.DataformClient; +import com.google.cloud.dataform.v1beta1.RepositoryName; +import com.google.cloud.dataform.v1beta1.Workspace; + +public class SyncCreateWorkspaceLongRunningStringWorkspaceString { + + public static void main(String[] args) throws Exception { + syncCreateWorkspaceLongRunningStringWorkspaceString(); + } + + public static void syncCreateWorkspaceLongRunningStringWorkspaceString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (DataformClient dataformClient = DataformClient.create()) { + String parent = RepositoryName.of("[PROJECT]", "[LOCATION]", "[REPOSITORY]").toString(); + Workspace workspace = Workspace.newBuilder().build(); + String workspaceId = "workspaceId466560144"; + Workspace response = + dataformClient.createWorkspaceLongRunningAsync(parent, workspace, workspaceId).get(); + } + } +} +// [END dataform_v1beta1_generated_Dataform_CreateWorkspaceLongRunning_StringWorkspaceString_sync] diff --git a/java-datalineage/README.md b/java-datalineage/README.md index a6a2d9c8eeba..7a92c551543c 100644 --- a/java-datalineage/README.md +++ b/java-datalineage/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-datalineage - 0.94.0 + 0.95.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-datalineage' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-datalineage:0.94.0' +implementation 'com.google.cloud:google-cloud-datalineage:0.95.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-datalineage" % "0.94.0" +libraryDependencies += "com.google.cloud" % "google-cloud-datalineage" % "0.95.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-datalineage/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-datalineage.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-datalineage/0.94.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-datalineage/0.95.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-datamanager/README.md b/java-datamanager/README.md index ec512cff2aef..13f316b48507 100644 --- a/java-datamanager/README.md +++ b/java-datamanager/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.api-ads data-manager - 0.23.0 + 0.24.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.api-ads:data-manager:0.23.0' +implementation 'com.google.api-ads:data-manager:0.24.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.api-ads" % "data-manager" % "0.23.0" +libraryDependencies += "com.google.api-ads" % "data-manager" % "0.24.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/data-manager/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.api-ads/data-manager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.api-ads/data-manager/0.23.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.api-ads/data-manager/0.24.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-dataplex/README.md b/java-dataplex/README.md index eb31cb16a514..ab81ff41ecde 100644 --- a/java-dataplex/README.md +++ b/java-dataplex/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-dataplex - 1.100.0 + 1.101.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-dataplex' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-dataplex:1.100.0' +implementation 'com.google.cloud:google-cloud-dataplex:1.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-dataplex" % "1.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-dataplex" % "1.101.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-dataplex/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-dataplex.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataplex/1.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataplex/1.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-dataproc-metastore/README.md b/java-dataproc-metastore/README.md index 99e5611c9959..4286a828f664 100644 --- a/java-dataproc-metastore/README.md +++ b/java-dataproc-metastore/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-dataproc-metastore - 2.103.0 + 2.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-dataproc-metastore' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-dataproc-metastore:2.103.0' +implementation 'com.google.cloud:google-cloud-dataproc-metastore:2.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-dataproc-metastore" % "2.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-dataproc-metastore" % "2.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-dataproc-metastore/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-dataproc-metastore.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataproc-metastore/2.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataproc-metastore/2.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-dataproc/README.md b/java-dataproc/README.md index 7f9b92376da3..f3921c031646 100644 --- a/java-dataproc/README.md +++ b/java-dataproc/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-dataproc - 4.99.0 + 4.100.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-dataproc' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-dataproc:4.99.0' +implementation 'com.google.cloud:google-cloud-dataproc:4.100.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-dataproc" % "4.99.0" +libraryDependencies += "com.google.cloud" % "google-cloud-dataproc" % "4.100.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-dataproc/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-dataproc.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataproc/4.99.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dataproc/4.100.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-dataproc/google-cloud-dataproc/src/main/resources/META-INF/native-image/com.google.cloud.dataproc.v1/reflect-config.json b/java-dataproc/google-cloud-dataproc/src/main/resources/META-INF/native-image/com.google.cloud.dataproc.v1/reflect-config.json index 3e2d1001f895..ce95d2548e63 100644 --- a/java-dataproc/google-cloud-dataproc/src/main/resources/META-INF/native-image/com.google.cloud.dataproc.v1/reflect-config.json +++ b/java-dataproc/google-cloud-dataproc/src/main/resources/META-INF/native-image/com.google.cloud.dataproc.v1/reflect-config.json @@ -3014,6 +3014,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataproc.v1.SchedulingConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataproc.v1.SchedulingConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataproc.v1.SecurityConfig", "queryAllDeclaredConstructors": true, diff --git a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClusterConfig.java b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClusterConfig.java index aa9ce3e163d7..42a9f9ad7e52 100644 --- a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClusterConfig.java +++ b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClusterConfig.java @@ -609,6 +609,53 @@ private Engine(int value) { } private int bitField0_; + private int provisioningConfigCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object provisioningConfig_; + + public enum ProvisioningConfigCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + SCHEDULING_CONFIG(26), + PROVISIONINGCONFIG_NOT_SET(0); + private final int value; + + private ProvisioningConfigCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ProvisioningConfigCase valueOf(int value) { + return forNumber(value); + } + + public static ProvisioningConfigCase forNumber(int value) { + switch (value) { + case 26: + return SCHEDULING_CONFIG; + case 0: + return PROVISIONINGCONFIG_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ProvisioningConfigCase getProvisioningConfigCase() { + return ProvisioningConfigCase.forNumber(provisioningConfigCase_); + } + public static final int CLUSTER_TYPE_FIELD_NUMBER = 27; private int clusterType_ = 0; @@ -1844,6 +1891,69 @@ public com.google.cloud.dataproc.v1.AuxiliaryNodeGroupOrBuilder getAuxiliaryNode return auxiliaryNodeGroups_.get(index); } + public static final int SCHEDULING_CONFIG_FIELD_NUMBER = 26; + + /** + * + * + *
                      +   * Optional. Config for scheduling the resources to be allocated when
                      +   * available.
                      +   * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the schedulingConfig field is set. + */ + @java.lang.Override + public boolean hasSchedulingConfig() { + return provisioningConfigCase_ == 26; + } + + /** + * + * + *
                      +   * Optional. Config for scheduling the resources to be allocated when
                      +   * available.
                      +   * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The schedulingConfig. + */ + @java.lang.Override + public com.google.cloud.dataproc.v1.SchedulingConfig getSchedulingConfig() { + if (provisioningConfigCase_ == 26) { + return (com.google.cloud.dataproc.v1.SchedulingConfig) provisioningConfig_; + } + return com.google.cloud.dataproc.v1.SchedulingConfig.getDefaultInstance(); + } + + /** + * + * + *
                      +   * Optional. Config for scheduling the resources to be allocated when
                      +   * available.
                      +   * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.dataproc.v1.SchedulingConfigOrBuilder getSchedulingConfigOrBuilder() { + if (provisioningConfigCase_ == 26) { + return (com.google.cloud.dataproc.v1.SchedulingConfig) provisioningConfig_; + } + return com.google.cloud.dataproc.v1.SchedulingConfig.getDefaultInstance(); + } + public static final int MASTER_FLEXIBLE_CONFIG_FIELD_NUMBER = 31; private com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig masterFlexibleConfig_; @@ -2219,6 +2329,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < auxiliaryNodeGroups_.size(); i++) { output.writeMessage(25, auxiliaryNodeGroups_.get(i)); } + if (provisioningConfigCase_ == 26) { + output.writeMessage(26, (com.google.cloud.dataproc.v1.SchedulingConfig) provisioningConfig_); + } if (clusterType_ != com.google.cloud.dataproc.v1.ClusterConfig.ClusterType.CLUSTER_TYPE_UNSPECIFIED .getNumber()) { @@ -2304,6 +2417,11 @@ public int getSerializedSize() { size += com.google.protobuf.CodedOutputStream.computeMessageSize(25, auxiliaryNodeGroups_.get(i)); } + if (provisioningConfigCase_ == 26) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 26, (com.google.cloud.dataproc.v1.SchedulingConfig) provisioningConfig_); + } if (clusterType_ != com.google.cloud.dataproc.v1.ClusterConfig.ClusterType.CLUSTER_TYPE_UNSPECIFIED .getNumber()) { @@ -2416,6 +2534,14 @@ public boolean equals(final java.lang.Object obj) { if (!getSecondaryWorkerFlexibleConfig().equals(other.getSecondaryWorkerFlexibleConfig())) return false; } + if (!getProvisioningConfigCase().equals(other.getProvisioningConfigCase())) return false; + switch (provisioningConfigCase_) { + case 26: + if (!getSchedulingConfig().equals(other.getSchedulingConfig())) return false; + break; + case 0: + default: + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -2505,6 +2631,14 @@ public int hashCode() { hash = (37 * hash) + SECONDARY_WORKER_FLEXIBLE_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getSecondaryWorkerFlexibleConfig().hashCode(); } + switch (provisioningConfigCase_) { + case 26: + hash = (37 * hash) + SCHEDULING_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getSchedulingConfig().hashCode(); + break; + case 0: + default: + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -2749,6 +2883,9 @@ public Builder clear() { auxiliaryNodeGroupsBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00040000); + if (schedulingConfigBuilder_ != null) { + schedulingConfigBuilder_.clear(); + } masterFlexibleConfig_ = null; if (masterFlexibleConfigBuilder_ != null) { masterFlexibleConfigBuilder_.dispose(); @@ -2764,6 +2901,8 @@ public Builder clear() { secondaryWorkerFlexibleConfigBuilder_.dispose(); secondaryWorkerFlexibleConfigBuilder_ = null; } + provisioningConfigCase_ = 0; + provisioningConfig_ = null; return this; } @@ -2795,6 +2934,7 @@ public com.google.cloud.dataproc.v1.ClusterConfig buildPartial() { if (bitField0_ != 0) { buildPartial0(result); } + buildPartialOneofs(result); onBuilt(); return result; } @@ -2904,21 +3044,21 @@ private void buildPartial0(com.google.cloud.dataproc.v1.ClusterConfig result) { : dataprocMetricConfigBuilder_.build(); to_bitField0_ |= 0x00000800; } - if (((from_bitField0_ & 0x00080000) != 0)) { + if (((from_bitField0_ & 0x00100000) != 0)) { result.masterFlexibleConfig_ = masterFlexibleConfigBuilder_ == null ? masterFlexibleConfig_ : masterFlexibleConfigBuilder_.build(); to_bitField0_ |= 0x00001000; } - if (((from_bitField0_ & 0x00100000) != 0)) { + if (((from_bitField0_ & 0x00200000) != 0)) { result.workerFlexibleConfig_ = workerFlexibleConfigBuilder_ == null ? workerFlexibleConfig_ : workerFlexibleConfigBuilder_.build(); to_bitField0_ |= 0x00002000; } - if (((from_bitField0_ & 0x00200000) != 0)) { + if (((from_bitField0_ & 0x00400000) != 0)) { result.secondaryWorkerFlexibleConfig_ = secondaryWorkerFlexibleConfigBuilder_ == null ? secondaryWorkerFlexibleConfig_ @@ -2928,6 +3068,14 @@ private void buildPartial0(com.google.cloud.dataproc.v1.ClusterConfig result) { result.bitField0_ |= to_bitField0_; } + private void buildPartialOneofs(com.google.cloud.dataproc.v1.ClusterConfig result) { + result.provisioningConfigCase_ = provisioningConfigCase_; + result.provisioningConfig_ = this.provisioningConfig_; + if (provisioningConfigCase_ == 26 && schedulingConfigBuilder_ != null) { + result.provisioningConfig_ = schedulingConfigBuilder_.build(); + } + } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.dataproc.v1.ClusterConfig) { @@ -3058,6 +3206,17 @@ public Builder mergeFrom(com.google.cloud.dataproc.v1.ClusterConfig other) { if (other.hasSecondaryWorkerFlexibleConfig()) { mergeSecondaryWorkerFlexibleConfig(other.getSecondaryWorkerFlexibleConfig()); } + switch (other.getProvisioningConfigCase()) { + case SCHEDULING_CONFIG: + { + mergeSchedulingConfig(other.getSchedulingConfig()); + break; + } + case PROVISIONINGCONFIG_NOT_SET: + { + break; + } + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -3208,6 +3367,13 @@ public Builder mergeFrom( } break; } // case 202 + case 210: + { + input.readMessage( + internalGetSchedulingConfigFieldBuilder().getBuilder(), extensionRegistry); + provisioningConfigCase_ = 26; + break; + } // case 210 case 216: { clusterType_ = input.readEnum(); @@ -3230,14 +3396,14 @@ public Builder mergeFrom( { input.readMessage( internalGetMasterFlexibleConfigFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x00080000; + bitField0_ |= 0x00100000; break; } // case 250 case 258: { input.readMessage( internalGetWorkerFlexibleConfigFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x00100000; + bitField0_ |= 0x00200000; break; } // case 258 case 266: @@ -3245,7 +3411,7 @@ public Builder mergeFrom( input.readMessage( internalGetSecondaryWorkerFlexibleConfigFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x00200000; + bitField0_ |= 0x00400000; break; } // case 266 default: @@ -3265,6 +3431,20 @@ public Builder mergeFrom( return this; } + private int provisioningConfigCase_ = 0; + private java.lang.Object provisioningConfig_; + + public ProvisioningConfigCase getProvisioningConfigCase() { + return ProvisioningConfigCase.forNumber(provisioningConfigCase_); + } + + public Builder clearProvisioningConfig() { + provisioningConfigCase_ = 0; + provisioningConfig_ = null; + onChanged(); + return this; + } + private int bitField0_; private int clusterType_ = 0; @@ -7580,6 +7760,252 @@ public com.google.cloud.dataproc.v1.AuxiliaryNodeGroup.Builder addAuxiliaryNodeG return auxiliaryNodeGroupsBuilder_; } + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.dataproc.v1.SchedulingConfig, + com.google.cloud.dataproc.v1.SchedulingConfig.Builder, + com.google.cloud.dataproc.v1.SchedulingConfigOrBuilder> + schedulingConfigBuilder_; + + /** + * + * + *
                      +     * Optional. Config for scheduling the resources to be allocated when
                      +     * available.
                      +     * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the schedulingConfig field is set. + */ + @java.lang.Override + public boolean hasSchedulingConfig() { + return provisioningConfigCase_ == 26; + } + + /** + * + * + *
                      +     * Optional. Config for scheduling the resources to be allocated when
                      +     * available.
                      +     * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The schedulingConfig. + */ + @java.lang.Override + public com.google.cloud.dataproc.v1.SchedulingConfig getSchedulingConfig() { + if (schedulingConfigBuilder_ == null) { + if (provisioningConfigCase_ == 26) { + return (com.google.cloud.dataproc.v1.SchedulingConfig) provisioningConfig_; + } + return com.google.cloud.dataproc.v1.SchedulingConfig.getDefaultInstance(); + } else { + if (provisioningConfigCase_ == 26) { + return schedulingConfigBuilder_.getMessage(); + } + return com.google.cloud.dataproc.v1.SchedulingConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Optional. Config for scheduling the resources to be allocated when
                      +     * available.
                      +     * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setSchedulingConfig(com.google.cloud.dataproc.v1.SchedulingConfig value) { + if (schedulingConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + provisioningConfig_ = value; + onChanged(); + } else { + schedulingConfigBuilder_.setMessage(value); + } + provisioningConfigCase_ = 26; + return this; + } + + /** + * + * + *
                      +     * Optional. Config for scheduling the resources to be allocated when
                      +     * available.
                      +     * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setSchedulingConfig( + com.google.cloud.dataproc.v1.SchedulingConfig.Builder builderForValue) { + if (schedulingConfigBuilder_ == null) { + provisioningConfig_ = builderForValue.build(); + onChanged(); + } else { + schedulingConfigBuilder_.setMessage(builderForValue.build()); + } + provisioningConfigCase_ = 26; + return this; + } + + /** + * + * + *
                      +     * Optional. Config for scheduling the resources to be allocated when
                      +     * available.
                      +     * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeSchedulingConfig(com.google.cloud.dataproc.v1.SchedulingConfig value) { + if (schedulingConfigBuilder_ == null) { + if (provisioningConfigCase_ == 26 + && provisioningConfig_ + != com.google.cloud.dataproc.v1.SchedulingConfig.getDefaultInstance()) { + provisioningConfig_ = + com.google.cloud.dataproc.v1.SchedulingConfig.newBuilder( + (com.google.cloud.dataproc.v1.SchedulingConfig) provisioningConfig_) + .mergeFrom(value) + .buildPartial(); + } else { + provisioningConfig_ = value; + } + onChanged(); + } else { + if (provisioningConfigCase_ == 26) { + schedulingConfigBuilder_.mergeFrom(value); + } else { + schedulingConfigBuilder_.setMessage(value); + } + } + provisioningConfigCase_ = 26; + return this; + } + + /** + * + * + *
                      +     * Optional. Config for scheduling the resources to be allocated when
                      +     * available.
                      +     * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearSchedulingConfig() { + if (schedulingConfigBuilder_ == null) { + if (provisioningConfigCase_ == 26) { + provisioningConfigCase_ = 0; + provisioningConfig_ = null; + onChanged(); + } + } else { + if (provisioningConfigCase_ == 26) { + provisioningConfigCase_ = 0; + provisioningConfig_ = null; + } + schedulingConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. Config for scheduling the resources to be allocated when
                      +     * available.
                      +     * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.dataproc.v1.SchedulingConfig.Builder getSchedulingConfigBuilder() { + return internalGetSchedulingConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. Config for scheduling the resources to be allocated when
                      +     * available.
                      +     * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.dataproc.v1.SchedulingConfigOrBuilder getSchedulingConfigOrBuilder() { + if ((provisioningConfigCase_ == 26) && (schedulingConfigBuilder_ != null)) { + return schedulingConfigBuilder_.getMessageOrBuilder(); + } else { + if (provisioningConfigCase_ == 26) { + return (com.google.cloud.dataproc.v1.SchedulingConfig) provisioningConfig_; + } + return com.google.cloud.dataproc.v1.SchedulingConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                      +     * Optional. Config for scheduling the resources to be allocated when
                      +     * available.
                      +     * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.dataproc.v1.SchedulingConfig, + com.google.cloud.dataproc.v1.SchedulingConfig.Builder, + com.google.cloud.dataproc.v1.SchedulingConfigOrBuilder> + internalGetSchedulingConfigFieldBuilder() { + if (schedulingConfigBuilder_ == null) { + if (!(provisioningConfigCase_ == 26)) { + provisioningConfig_ = com.google.cloud.dataproc.v1.SchedulingConfig.getDefaultInstance(); + } + schedulingConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.dataproc.v1.SchedulingConfig, + com.google.cloud.dataproc.v1.SchedulingConfig.Builder, + com.google.cloud.dataproc.v1.SchedulingConfigOrBuilder>( + (com.google.cloud.dataproc.v1.SchedulingConfig) provisioningConfig_, + getParentForChildren(), + isClean()); + provisioningConfig_ = null; + } + provisioningConfigCase_ = 26; + onChanged(); + return schedulingConfigBuilder_; + } + private com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig masterFlexibleConfig_; private com.google.protobuf.SingleFieldBuilder< com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig, @@ -7615,7 +8041,7 @@ public com.google.cloud.dataproc.v1.AuxiliaryNodeGroup.Builder addAuxiliaryNodeG * @return Whether the masterFlexibleConfig field is set. */ public boolean hasMasterFlexibleConfig() { - return ((bitField0_ & 0x00080000) != 0); + return ((bitField0_ & 0x00100000) != 0); } /** @@ -7690,7 +8116,7 @@ public Builder setMasterFlexibleConfig( } else { masterFlexibleConfigBuilder_.setMessage(value); } - bitField0_ |= 0x00080000; + bitField0_ |= 0x00100000; onChanged(); return this; } @@ -7727,7 +8153,7 @@ public Builder setMasterFlexibleConfig( } else { masterFlexibleConfigBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x00080000; + bitField0_ |= 0x00100000; onChanged(); return this; } @@ -7760,7 +8186,7 @@ public Builder setMasterFlexibleConfig( public Builder mergeMasterFlexibleConfig( com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig value) { if (masterFlexibleConfigBuilder_ == null) { - if (((bitField0_ & 0x00080000) != 0) + if (((bitField0_ & 0x00100000) != 0) && masterFlexibleConfig_ != null && masterFlexibleConfig_ != com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig.getDefaultInstance()) { @@ -7772,7 +8198,7 @@ public Builder mergeMasterFlexibleConfig( masterFlexibleConfigBuilder_.mergeFrom(value); } if (masterFlexibleConfig_ != null) { - bitField0_ |= 0x00080000; + bitField0_ |= 0x00100000; onChanged(); } return this; @@ -7804,7 +8230,7 @@ public Builder mergeMasterFlexibleConfig( * */ public Builder clearMasterFlexibleConfig() { - bitField0_ = (bitField0_ & ~0x00080000); + bitField0_ = (bitField0_ & ~0x00100000); masterFlexibleConfig_ = null; if (masterFlexibleConfigBuilder_ != null) { masterFlexibleConfigBuilder_.dispose(); @@ -7841,7 +8267,7 @@ public Builder clearMasterFlexibleConfig() { */ public com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig.Builder getMasterFlexibleConfigBuilder() { - bitField0_ |= 0x00080000; + bitField0_ |= 0x00100000; onChanged(); return internalGetMasterFlexibleConfigFieldBuilder().getBuilder(); } @@ -7961,7 +8387,7 @@ public Builder clearMasterFlexibleConfig() { * @return Whether the workerFlexibleConfig field is set. */ public boolean hasWorkerFlexibleConfig() { - return ((bitField0_ & 0x00100000) != 0); + return ((bitField0_ & 0x00200000) != 0); } /** @@ -8040,7 +8466,7 @@ public Builder setWorkerFlexibleConfig( } else { workerFlexibleConfigBuilder_.setMessage(value); } - bitField0_ |= 0x00100000; + bitField0_ |= 0x00200000; onChanged(); return this; } @@ -8079,7 +8505,7 @@ public Builder setWorkerFlexibleConfig( } else { workerFlexibleConfigBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x00100000; + bitField0_ |= 0x00200000; onChanged(); return this; } @@ -8114,7 +8540,7 @@ public Builder setWorkerFlexibleConfig( public Builder mergeWorkerFlexibleConfig( com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig value) { if (workerFlexibleConfigBuilder_ == null) { - if (((bitField0_ & 0x00100000) != 0) + if (((bitField0_ & 0x00200000) != 0) && workerFlexibleConfig_ != null && workerFlexibleConfig_ != com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig.getDefaultInstance()) { @@ -8126,7 +8552,7 @@ public Builder mergeWorkerFlexibleConfig( workerFlexibleConfigBuilder_.mergeFrom(value); } if (workerFlexibleConfig_ != null) { - bitField0_ |= 0x00100000; + bitField0_ |= 0x00200000; onChanged(); } return this; @@ -8160,7 +8586,7 @@ public Builder mergeWorkerFlexibleConfig( * */ public Builder clearWorkerFlexibleConfig() { - bitField0_ = (bitField0_ & ~0x00100000); + bitField0_ = (bitField0_ & ~0x00200000); workerFlexibleConfig_ = null; if (workerFlexibleConfigBuilder_ != null) { workerFlexibleConfigBuilder_.dispose(); @@ -8199,7 +8625,7 @@ public Builder clearWorkerFlexibleConfig() { */ public com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig.Builder getWorkerFlexibleConfigBuilder() { - bitField0_ |= 0x00100000; + bitField0_ |= 0x00200000; onChanged(); return internalGetWorkerFlexibleConfigFieldBuilder().getBuilder(); } @@ -8321,7 +8747,7 @@ public Builder clearWorkerFlexibleConfig() { * @return Whether the secondaryWorkerFlexibleConfig field is set. */ public boolean hasSecondaryWorkerFlexibleConfig() { - return ((bitField0_ & 0x00200000) != 0); + return ((bitField0_ & 0x00400000) != 0); } /** @@ -8397,7 +8823,7 @@ public Builder setSecondaryWorkerFlexibleConfig( } else { secondaryWorkerFlexibleConfigBuilder_.setMessage(value); } - bitField0_ |= 0x00200000; + bitField0_ |= 0x00400000; onChanged(); return this; } @@ -8434,7 +8860,7 @@ public Builder setSecondaryWorkerFlexibleConfig( } else { secondaryWorkerFlexibleConfigBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x00200000; + bitField0_ |= 0x00400000; onChanged(); return this; } @@ -8467,7 +8893,7 @@ public Builder setSecondaryWorkerFlexibleConfig( public Builder mergeSecondaryWorkerFlexibleConfig( com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig value) { if (secondaryWorkerFlexibleConfigBuilder_ == null) { - if (((bitField0_ & 0x00200000) != 0) + if (((bitField0_ & 0x00400000) != 0) && secondaryWorkerFlexibleConfig_ != null && secondaryWorkerFlexibleConfig_ != com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig.getDefaultInstance()) { @@ -8479,7 +8905,7 @@ public Builder mergeSecondaryWorkerFlexibleConfig( secondaryWorkerFlexibleConfigBuilder_.mergeFrom(value); } if (secondaryWorkerFlexibleConfig_ != null) { - bitField0_ |= 0x00200000; + bitField0_ |= 0x00400000; onChanged(); } return this; @@ -8511,7 +8937,7 @@ public Builder mergeSecondaryWorkerFlexibleConfig( * */ public Builder clearSecondaryWorkerFlexibleConfig() { - bitField0_ = (bitField0_ & ~0x00200000); + bitField0_ = (bitField0_ & ~0x00400000); secondaryWorkerFlexibleConfig_ = null; if (secondaryWorkerFlexibleConfigBuilder_ != null) { secondaryWorkerFlexibleConfigBuilder_.dispose(); @@ -8548,7 +8974,7 @@ public Builder clearSecondaryWorkerFlexibleConfig() { */ public com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfig.Builder getSecondaryWorkerFlexibleConfigBuilder() { - bitField0_ |= 0x00200000; + bitField0_ |= 0x00400000; onChanged(); return internalGetSecondaryWorkerFlexibleConfigFieldBuilder().getBuilder(); } diff --git a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClusterConfigOrBuilder.java b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClusterConfigOrBuilder.java index a00b884a7084..954a3fedd6d7 100644 --- a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClusterConfigOrBuilder.java +++ b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClusterConfigOrBuilder.java @@ -934,6 +934,52 @@ com.google.cloud.dataproc.v1.NodeInitializationActionOrBuilder getInitialization com.google.cloud.dataproc.v1.AuxiliaryNodeGroupOrBuilder getAuxiliaryNodeGroupsOrBuilder( int index); + /** + * + * + *
                      +   * Optional. Config for scheduling the resources to be allocated when
                      +   * available.
                      +   * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the schedulingConfig field is set. + */ + boolean hasSchedulingConfig(); + + /** + * + * + *
                      +   * Optional. Config for scheduling the resources to be allocated when
                      +   * available.
                      +   * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The schedulingConfig. + */ + com.google.cloud.dataproc.v1.SchedulingConfig getSchedulingConfig(); + + /** + * + * + *
                      +   * Optional. Config for scheduling the resources to be allocated when
                      +   * available.
                      +   * 
                      + * + * + * .google.cloud.dataproc.v1.SchedulingConfig scheduling_config = 26 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.dataproc.v1.SchedulingConfigOrBuilder getSchedulingConfigOrBuilder(); + /** * * @@ -1197,4 +1243,6 @@ com.google.cloud.dataproc.v1.AuxiliaryNodeGroupOrBuilder getAuxiliaryNodeGroupsO */ com.google.cloud.dataproc.v1.FlexibleInstanceGroupConfigOrBuilder getSecondaryWorkerFlexibleConfigOrBuilder(); + + com.google.cloud.dataproc.v1.ClusterConfig.ProvisioningConfigCase getProvisioningConfigCase(); } diff --git a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClustersProto.java b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClustersProto.java index 615466ccd185..7d853fde581f 100644 --- a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClustersProto.java +++ b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ClustersProto.java @@ -224,6 +224,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_dataproc_v1_DataprocMetricConfig_Metric_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_dataproc_v1_DataprocMetricConfig_Metric_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataproc_v1_SchedulingConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_dataproc_v1_SchedulingConfig_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_dataproc_v1_CreateClusterRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -307,7 +311,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "e.cloud.dataproc.v1.ClusterMetricsB\004\342A\001\003\032-\n" + "\013LabelsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" - + "\005value\030\002 \001(\t:\0028\001\"\230\017\n\r" + + "\005value\030\002 \001(\t:\0028\001\"\376\017\n\r" + "ClusterConfig\022O\n" + "\014cluster_type\030\033" + " \001(\01623.google.cloud.dataproc.v1.ClusterConfig.ClusterTypeB\004\342A\001\001\022O\n" @@ -344,13 +348,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\026dataproc_metric_config\030\027 \001(\0132..g" + "oogle.cloud.dataproc.v1.DataprocMetricConfigB\004\342A\001\001\022Q\n" + "\025auxiliary_node_groups\030\031 \003(" - + "\0132,.google.cloud.dataproc.v1.AuxiliaryNodeGroupB\004\342A\001\001\022[\n" + + "\0132,.google.cloud.dataproc.v1.AuxiliaryNodeGroupB\004\342A\001\001\022M\n" + + "\021scheduling_config\030\032 \001(\013" + + "2*.google.cloud.dataproc.v1.SchedulingConfigB\004\342A\001\001H\000\022[\n" + "\026master_flexible_config\030\037" + " \001(\01325.google.cloud.dataproc.v1.FlexibleInstanceGroupConfigB\004\342A\001\001\022[\n" - + "\026worker_flexible_config\030 \001(\01325.google.cloud.datapr" - + "oc.v1.FlexibleInstanceGroupConfigB\004\342A\001\001\022e\n" - + " secondary_worker_flexible_config\030! \001(" - + "\01325.google.cloud.dataproc.v1.FlexibleInstanceGroupConfigB\004\342A\001\001\"Z\n" + + "\026worker_flexible_config\030 \001(\01325.google.cloud.datapro" + + "c.v1.FlexibleInstanceGroupConfigB\004\342A\001\001\022e\n" + + " secondary_worker_flexible_config\030! \001(\013" + + "25.google.cloud.dataproc.v1.FlexibleInstanceGroupConfigB\004\342A\001\001\"Z\n" + "\013ClusterType\022\034\n" + "\030CLUSTER_TYPE_UNSPECIFIED\020\000\022\014\n" + "\010STANDARD\020\001\022\017\n" @@ -363,23 +369,23 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006Engine\022\026\n" + "\022ENGINE_UNSPECIFIED\020\000\022\013\n" + "\007DEFAULT\020\001\022\r\n" - + "\tLIGHTNING\020\002\"\207\002\n" + + "\tLIGHTNING\020\002B\025\n" + + "\023provisioning_config\"\207\002\n" + "\024VirtualClusterConfig\022\034\n" + "\016staging_bucket\030\001 \001(\tB\004\342A\001\001\022\\\n" - + "\031kubernetes_cluster_config\030\006" - + " \001(\01321.google.cloud.dataproc.v1.KubernetesClusterConfigB\004\342A\001\002H\000\022Z\n" - + "\031auxiliary_services_config\030\007" - + " \001(\01321.google.cloud.dataproc.v1.AuxiliaryServicesConfigB\004\342A\001\001B\027\n" + + "\031kubernetes_cluster_config\030\006 \001(\01321.google.clou" + + "d.dataproc.v1.KubernetesClusterConfigB\004\342A\001\002H\000\022Z\n" + + "\031auxiliary_services_config\030\007 \001(\013" + + "21.google.cloud.dataproc.v1.AuxiliaryServicesConfigB\004\342A\001\001B\027\n" + "\025infrastructure_config\"\303\001\n" + "\027AuxiliaryServicesConfig\022I\n" - + "\020metastore_config\030\001 \001(\0132).goo" - + "gle.cloud.dataproc.v1.MetastoreConfigB\004\342A\001\001\022]\n" - + "\033spark_history_server_config\030\002 \001(\013" - + "22.google.cloud.dataproc.v1.SparkHistoryServerConfigB\004\342A\001\001\"\274\001\n" - + "\016EndpointConfig\022Q\n" - + "\n" - + "http_ports\030\001 \003(\01327.google.cloud.datapro" - + "c.v1.EndpointConfig.HttpPortsEntryB\004\342A\001\003\022%\n" + + "\020metastore_config\030\001" + + " \001(\0132).google.cloud.dataproc.v1.MetastoreConfigB\004\342A\001\001\022]\n" + + "\033spark_history_server_config\030\002 \001(\01322.google.cloud.da" + + "taproc.v1.SparkHistoryServerConfigB\004\342A\001\001\"\274\001\n" + + "\016EndpointConfig\022Q\n\n" + + "http_ports\030\001 \003(\0132" + + "7.google.cloud.dataproc.v1.EndpointConfig.HttpPortsEntryB\004\342A\001\003\022%\n" + "\027enable_http_port_access\030\002 \001(\010B\004\342A\001\001\0320\n" + "\016HttpPortsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" @@ -397,23 +403,23 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013network_uri\030\002 \001(\tB\004\342A\001\001\022\034\n" + "\016subnetwork_uri\030\006 \001(\tB\004\342A\001\001\022#\n" + "\020internal_ip_only\030\007 \001(\010B\004\342A\001\001H\000\210\001\001\022l\n" - + "\032private_ipv6_google_access\030\014 \001(\0162B.google.cloud.d" - + "ataproc.v1.GceClusterConfig.PrivateIpv6GoogleAccessB\004\342A\001\001\022\035\n" + + "\032private_ipv6_google_access\030\014 \001(\0162B.google.cloud.dataproc.v1.GceClus" + + "terConfig.PrivateIpv6GoogleAccessB\004\342A\001\001\022\035\n" + "\017service_account\030\010 \001(\tB\004\342A\001\001\022$\n" + "\026service_account_scopes\030\003 \003(\tB\004\342A\001\001\022\014\n" + "\004tags\030\004 \003(\t\022P\n" - + "\010metadata\030\005 \003(\01328" - + ".google.cloud.dataproc.v1.GceClusterConfig.MetadataEntryB\004\342A\001\001\022Q\n" - + "\024reservation_affinity\030\013" - + " \001(\0132-.google.cloud.dataproc.v1.ReservationAffinityB\004\342A\001\001\022N\n" + + "\010metadata\030\005 \003(\01328.google.cloud.data" + + "proc.v1.GceClusterConfig.MetadataEntryB\004\342A\001\001\022Q\n" + + "\024reservation_affinity\030\013 \001(\0132-.goo" + + "gle.cloud.dataproc.v1.ReservationAffinityB\004\342A\001\001\022N\n" + "\023node_group_affinity\030\r" + " \001(\0132+.google.cloud.dataproc.v1.NodeGroupAffinityB\004\342A\001\001\022X\n" - + "\030shielded_instance_config\030\016" - + " \001(\01320.google.cloud.dataproc.v1.ShieldedInstanceConfigB\004\342A\001\001\022`\n" - + "\034confidential_instance_config\030\017 \001(\01324.goog" - + "le.cloud.dataproc.v1.ConfidentialInstanceConfigB\004\342A\001\001\022h\n" - + "\025resource_manager_tags\030\020 \003(\0132C.google.cloud.dataproc.v1.GceClust" - + "erConfig.ResourceManagerTagsEntryB\004\342A\001\001\032/\n\r" + + "\030shielded_instance_config\030\016 \001(" + + "\01320.google.cloud.dataproc.v1.ShieldedInstanceConfigB\004\342A\001\001\022`\n" + + "\034confidential_instance_config\030\017" + + " \001(\01324.google.cloud.dataproc.v1.ConfidentialInstanceConfigB\004\342A\001\001\022h\n" + + "\025resource_manager_tags\030\020 \003(\0132C.google.clou" + + "d.dataproc.v1.GceClusterConfig.ResourceManagerTagsEntryB\004\342A\001\001\032/\n\r" + "MetadataEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001\032:\n" @@ -427,8 +433,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "BIDIRECTIONAL\020\003B\023\n" + "\021_internal_ip_only\"\232\001\n" + "\017MultiZoneConfig\022Q\n" - + "\014target_shape\030\001 \001(\01625.google.cloud" - + ".dataproc.v1.MultiZoneConfig.TargetShapeB\004\342A\001\001\"4\n" + + "\014target_shape\030\001" + + " \001(\01625.google.cloud.dataproc.v1.MultiZoneConfig.TargetShapeB\004\342A\001\001\"4\n" + "\013TargetShape\022\034\n" + "\030TARGET_SHAPE_UNSPECIFIED\020\000\022\007\n" + "\003ANY\020\001\"1\n" @@ -444,9 +450,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\034_enable_integrity_monitoring\"\251\002\n" + "\032ConfidentialInstanceConfig\022+\n" + "\033enable_confidential_compute\030\001 \001(\010B\006\030\001\342A\001\001\022w\n" - + "\032confidential_instance_type\030\002 \001(\016" - + "2M.google.cloud.dataproc.v1.Confidential" - + "InstanceConfig.ConfidentialInstanceTypeB\004\342A\001\001\"e\n" + + "\032confidential_instance_type\030\002 \001(\0162M.google.cloud.da" + + "taproc.v1.ConfidentialInstanceConfig.ConfidentialInstanceTypeB\004\342A\001\001\"e\n" + "\030ConfidentialInstanceType\022*\n" + "&CONFIDENTIAL_INSTANCE_TYPE_UNSPECIFIED\020\000\022\007\n" + "\003SEV\020\001\022\013\n" @@ -455,25 +460,27 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\023InstanceGroupConfig\022\033\n\r" + "num_instances\030\001 \001(\005B\004\342A\001\001\022\034\n" + "\016instance_names\030\002 \003(\tB\004\342A\001\003\022N\n" - + "\023instance_references\030\013" - + " \003(\0132+.google.cloud.dataproc.v1.InstanceReferenceB\004\342A\001\003\022\027\n" + + "\023instance_references\030\013 \003" + + "(\0132+.google.cloud.dataproc.v1.InstanceReferenceB\004\342A\001\003\022\027\n" + "\timage_uri\030\003 \001(\tB\004\342A\001\001\022\036\n" + "\020machine_type_uri\030\004 \001(\tB\004\342A\001\001\022?\n" + "\013disk_config\030\005" + " \001(\0132$.google.cloud.dataproc.v1.DiskConfigB\004\342A\001\001\022\034\n" + "\016is_preemptible\030\006 \001(\010B\004\342A\001\003\022Z\n" + "\016preemptibility\030\n" - + " \001(\0162<.google.cloud.dataproc.v1.InstanceGroupConfig.PreemptibilityB\004\342A\001\001\022P\n" + + " \001(\0162<.google.c" + + "loud.dataproc.v1.InstanceGroupConfig.PreemptibilityB\004\342A\001\001\022P\n" + "\024managed_group_config\030\007" + " \001(\0132,.google.cloud.dataproc.v1.ManagedGroupConfigB\004\342A\001\003\022G\n" - + "\014accelerators\030\010" - + " \003(\0132+.google.cloud.dataproc.v1.AcceleratorConfigB\004\342A\001\001\022\036\n" + + "\014accelerators\030\010 \003(" + + "\0132+.google.cloud.dataproc.v1.AcceleratorConfigB\004\342A\001\001\022\036\n" + "\020min_cpu_platform\030\t \001(\tB\004\342A\001\001\022\037\n" + "\021min_num_instances\030\014 \001(\005B\004\342A\001\001\022^\n" + "\033instance_flexibility_policy\030\r" - + " \001(\01323.google.cloud.dataproc.v1.InstanceFlexibilityPolicyB\004\342A\001\001\022E\n" - + "\016startup_config\030\016" - + " \001(\0132\'.google.cloud.dataproc.v1.StartupConfigB\004\342A\001\001\"`\n" + + " \001(\01323.goo" + + "gle.cloud.dataproc.v1.InstanceFlexibilityPolicyB\004\342A\001\001\022E\n" + + "\016startup_config\030\016 \001(\0132\'." + + "google.cloud.dataproc.v1.StartupConfigB\004\342A\001\001\"`\n" + "\016Preemptibility\022\036\n" + "\032PREEMPTIBILITY_UNSPECIFIED\020\000\022\023\n" + "\017NON_PREEMPTIBLE\020\001\022\017\n" @@ -493,12 +500,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\033instance_group_manager_name\030\002 \001(\tB\004\342A\001\003\022(\n" + "\032instance_group_manager_uri\030\003 \001(\tB\004\342A\001\003\"\260\006\n" + "\031InstanceFlexibilityPolicy\022n\n" - + "\026provisioning_model_mix\030\001 \001(\0132H.google.cloud.da" - + "taproc.v1.InstanceFlexibilityPolicy.ProvisioningModelMixB\004\342A\001\001\022l\n" - + "\027instance_selection_list\030\002 \003(\0132E.google.cloud.dataproc." - + "v1.InstanceFlexibilityPolicy.InstanceSelectionB\004\342A\001\001\022u\n" - + "\032instance_selection_results\030\003 \003(\0132K.google.cloud.dataproc.v1.Inst" - + "anceFlexibilityPolicy.InstanceSelectionResultB\004\342A\001\003\032\276\001\n" + + "\026provisioning_model_mix\030\001 \001(\0132H.google.cloud.dataproc.v1.Instance" + + "FlexibilityPolicy.ProvisioningModelMixB\004\342A\001\001\022l\n" + + "\027instance_selection_list\030\002 \003(\0132E." + + "google.cloud.dataproc.v1.InstanceFlexibilityPolicy.InstanceSelectionB\004\342A\001\001\022u\n" + + "\032instance_selection_results\030\003 \003(\0132K.google." + + "cloud.dataproc.v1.InstanceFlexibilityPolicy.InstanceSelectionResultB\004\342A\001\003\032\276\001\n" + "\024ProvisioningModelMix\022)\n" + "\026standard_capacity_base\030\001 \001(\005B\004\342A\001\001H\000\210\001\001\0227\n" + "$standard_capacity_percent_above_base\030\002" @@ -508,8 +515,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\021InstanceSelection\022\033\n\r" + "machine_types\030\001 \003(\tB\004\342A\001\001\022\022\n" + "\004rank\030\002 \001(\005B\004\342A\001\001\022?\n" - + "\013disk_config\030\003" - + " \001(\0132$.google.cloud.dataproc.v1.DiskConfigB\004\342A\001\001\032u\n" + + "\013disk_config\030\003 \001(\0132$" + + ".google.cloud.dataproc.v1.DiskConfigB\004\342A\001\001\032u\n" + "\027InstanceSelectionResult\022\037\n" + "\014machine_type\030\001 \001(\tB\004\342A\001\003H\000\210\001\001\022\033\n" + "\010vm_count\030\002 \001(\005B\004\342A\001\003H\001\210\001\001B\017\n\r" @@ -519,16 +526,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "num_instances\030\001 \001(\005B\004\342A\001\001\022\030\n\n" + "core_count\030\002 \001(\005B\004\342A\001\001\022\037\n" + "\021boot_disk_size_gb\030\003 \001(\005B\004\342A\001\001\022a\n" - + "\016hardware_class\030\004 \001(\0162C.google.cloud.dataproc.v1.FlexibleI" - + "nstanceGroupConfig.HardwareClassB\004\342A\001\001\"N\n\r" + + "\016hardware_class\030\004 \001(\0162C.google.cloud" + + ".dataproc.v1.FlexibleInstanceGroupConfig.HardwareClassB\004\342A\001\001\"N\n\r" + "HardwareClass\022\036\n" + "\032HARDWARE_CLASS_UNSPECIFIED\020\000\022\014\n" + "\010STANDARD\020\001\022\017\n" + "\013PERFORMANCE\020\002\"L\n" + "\021AcceleratorConfig\022\034\n" + "\024accelerator_type_uri\030\001 \001(\t\022\031\n" - + "\021accelerator_count\030\002 \001(\005\"\207\003\n" - + "\n" + + "\021accelerator_count\030\002 \001(\005\"\207\003\n\n" + "DiskConfig\022\034\n" + "\016boot_disk_type\030\003 \001(\tB\004\342A\001\001\022\037\n" + "\021boot_disk_size_gb\030\001 \001(\005B\004\342A\001\001\022\034\n" @@ -538,13 +544,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\003B\004\342A\001\001H\000\210\001\001\0223\n" + " boot_disk_provisioned_throughput\030\006" + " \001(\003B\004\342A\001\001H\001\210\001\001\022Q\n" - + "\025attached_disk_configs\030\007 \003(\0132,.google." - + "cloud.dataproc.v1.AttachedDiskConfigB\004\342A\001\001B\035\n" + + "\025attached_disk_configs\030\007" + + " \003(\0132,.google.cloud.dataproc.v1.AttachedDiskConfigB\004\342A\001\001B\035\n" + "\033_boot_disk_provisioned_iopsB#\n" + "!_boot_disk_provisioned_throughput\"\203\003\n" + "\022AttachedDiskConfig\022N\n" - + "\tdisk_type\030\001 \001(\01625.googl" - + "e.cloud.dataproc.v1.AttachedDiskConfig.DiskTypeB\004\342A\001\001\022\032\n" + + "\tdisk_type\030\001" + + " \001(\01625.google.cloud.dataproc.v1.AttachedDiskConfig.DiskTypeB\004\342A\001\001\022\032\n" + "\014disk_size_gb\030\002 \001(\005B\004\342A\001\001\022#\n" + "\020provisioned_iops\030\003 \001(\003B\004\342A\001\001H\000\210\001\001\022)\n" + "\026provisioned_throughput\030\004" @@ -563,32 +569,32 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "node_group_id\030\002 \001(\tB\004\342A\001\001\"\300\003\n" + "\tNodeGroup\022\014\n" + "\004name\030\001 \001(\t\022=\n" - + "\005roles\030\002" - + " \003(\0162(.google.cloud.dataproc.v1.NodeGroup.RoleB\004\342A\001\002\022N\n" - + "\021node_group_config\030\003" - + " \001(\0132-.google.cloud.dataproc.v1.InstanceGroupConfigB\004\342A\001\001\022E\n" - + "\006labels\030\004 \003(" - + "\0132/.google.cloud.dataproc.v1.NodeGroup.LabelsEntryB\004\342A\001\001\032-\n" + + "\005roles\030\002 \003(\0162" + + "(.google.cloud.dataproc.v1.NodeGroup.RoleB\004\342A\001\002\022N\n" + + "\021node_group_config\030\003 \001(\0132-.goo" + + "gle.cloud.dataproc.v1.InstanceGroupConfigB\004\342A\001\001\022E\n" + + "\006labels\030\004 \003(\0132/.google.cloud.d" + + "ataproc.v1.NodeGroup.LabelsEntryB\004\342A\001\001\032-\n" + "\013LabelsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001\"(\n" + "\004Role\022\024\n" + "\020ROLE_UNSPECIFIED\020\000\022\n\n" + "\006DRIVER\020\001:v\352As\n" - + "!dataproc.googleapis.com/NodeGroup\022Nprojects/{pro" - + "ject}/regions/{region}/clusters/{cluster}/nodeGroups/{node_group}\"u\n" + + "!dataproc.googleapis.com/NodeGroup\022Nprojects/{project}/regions/{reg" + + "ion}/clusters/{cluster}/nodeGroups/{node_group}\"u\n" + "\030NodeInitializationAction\022\035\n" + "\017executable_file\030\001 \001(\tB\004\342A\001\002\022:\n" + "\021execution_timeout\030\002" + " \001(\0132\031.google.protobuf.DurationB\004\342A\001\001\"\330\003\n\r" + "ClusterStatus\022B\n" - + "\005state\030\001" - + " \001(\0162-.google.cloud.dataproc.v1.ClusterStatus.StateB\004\342A\001\003\022\025\n" + + "\005state\030\001 \001(\0162" + + "-.google.cloud.dataproc.v1.ClusterStatus.StateB\004\342A\001\003\022\025\n" + "\006detail\030\002 \001(\tB\005\342A\002\003\001\022:\n" + "\020state_start_time\030\003" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022H\n" - + "\010substate\030\004" - + " \001(\01620.google.cloud.dataproc.v1.ClusterStatus.SubstateB\004\342A\001\003\"\247\001\n" + + "\010substate\030\004 \001(\01620.goog" + + "le.cloud.dataproc.v1.ClusterStatus.SubstateB\004\342A\001\003\"\247\001\n" + "\005State\022\013\n" + "\007UNKNOWN\020\000\022\014\n" + "\010CREATING\020\001\022\013\n" @@ -609,8 +615,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016SecurityConfig\022G\n" + "\017kerberos_config\030\001" + " \001(\0132(.google.cloud.dataproc.v1.KerberosConfigB\004\342A\001\001\022G\n" - + "\017identity_config\030\002" - + " \001(\0132(.google.cloud.dataproc.v1.IdentityConfigB\004\342A\001\001\"\237\004\n" + + "\017identity_config\030\002 \001(\0132(" + + ".google.cloud.dataproc.v1.IdentityConfigB\004\342A\001\001\"\237\004\n" + "\016KerberosConfig\022\035\n" + "\017enable_kerberos\030\001 \001(\010B\004\342A\001\001\022)\n" + "\033root_principal_password_uri\030\002 \001(\tB\004\342A\001\001\022\031\n" @@ -630,17 +636,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\022tgt_lifetime_hours\030\016 \001(\005B\004\342A\001\001\022\023\n" + "\005realm\030\017 \001(\tB\004\342A\001\001\"\307\001\n" + "\016IdentityConfig\022s\n" - + "\034user_service_account_mapping\030\001 \003(\0132G.google.clo" - + "ud.dataproc.v1.IdentityConfig.UserServiceAccountMappingEntryB\004\342A\001\002\032@\n" + + "\034user_service_account_mapping\030\001 \003(\0132G.google.cloud.dataproc.v1.Ide" + + "ntityConfig.UserServiceAccountMappingEntryB\004\342A\001\002\032@\n" + "\036UserServiceAccountMappingEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001\"\374\001\n" + "\016SoftwareConfig\022\033\n\r" + "image_version\030\001 \001(\tB\004\342A\001\001\022R\n\n" - + "properties\030\002 \003(\013" - + "28.google.cloud.dataproc.v1.SoftwareConfig.PropertiesEntryB\004\342A\001\001\022F\n" - + "\023optional_components\030\003" - + " \003(\0162#.google.cloud.dataproc.v1.ComponentB\004\342A\001\001\0321\n" + + "properties\030\002 \003(\01328.google.cloud.da" + + "taproc.v1.SoftwareConfig.PropertiesEntryB\004\342A\001\001\022F\n" + + "\023optional_components\030\003 \003(\0162#.go" + + "ogle.cloud.dataproc.v1.ComponentB\004\342A\001\001\0321\n" + "\017PropertiesEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001\"\301\003\n" @@ -664,10 +670,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\032dataproc_metastore_service\030\001 \001(\tB)\342A\001\002\372A\"\n" + " metastore.googleapis.com/Service\"\232\002\n" + "\016ClusterMetrics\022O\n" - + "\014hdfs_metrics\030\001" - + " \003(\01329.google.cloud.dataproc.v1.ClusterMetrics.HdfsMetricsEntry\022O\n" - + "\014yarn_metrics\030\002 \003(\01329.google.cloud.datap" - + "roc.v1.ClusterMetrics.YarnMetricsEntry\0322\n" + + "\014hdfs_metrics\030\001 \003(\013" + + "29.google.cloud.dataproc.v1.ClusterMetrics.HdfsMetricsEntry\022O\n" + + "\014yarn_metrics\030\002 \003(" + + "\01329.google.cloud.dataproc.v1.ClusterMetrics.YarnMetricsEntry\0322\n" + "\020HdfsMetricsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\003:\0028\001\0322\n" @@ -675,11 +681,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\003:\0028\001\"\240\003\n" + "\024DataprocMetricConfig\022L\n" - + "\007metrics\030\001 \003(\01325.google.cloud." - + "dataproc.v1.DataprocMetricConfig.MetricB\004\342A\001\002\032\202\001\n" + + "\007metrics\030\001" + + " \003(\01325.google.cloud.dataproc.v1.DataprocMetricConfig.MetricB\004\342A\001\002\032\202\001\n" + "\006Metric\022X\n\r" - + "metric_source\030\001 \001(\0162" - + ";.google.cloud.dataproc.v1.DataprocMetricConfig.MetricSourceB\004\342A\001\002\022\036\n" + + "metric_source\030\001 \001(\0162;.google.cloud.dat" + + "aproc.v1.DataprocMetricConfig.MetricSourceB\004\342A\001\002\022\036\n" + "\020metric_overrides\030\002 \003(\tB\004\342A\001\001\"\264\001\n" + "\014MetricSource\022\035\n" + "\031METRIC_SOURCE_UNSPECIFIED\020\000\022\035\n" @@ -690,15 +696,20 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\024SPARK_HISTORY_SERVER\020\005\022\017\n" + "\013HIVESERVER2\020\006\022\021\n\r" + "HIVEMETASTORE\020\007\022\t\n" - + "\005FLINK\020\010\"\363\001\n" + + "\005FLINK\020\010\"\220\001\n" + + "\020SchedulingConfig\022;\n" + + "\022scheduling_timeout\030\001" + + " \001(\0132\031.google.protobuf.DurationB\004\342A\001\001\022?\n" + + "\026requested_run_duration\030\002" + + " \001(\0132\031.google.protobuf.DurationB\004\342A\001\001\"\363\001\n" + "\024CreateClusterRequest\022\030\n\n" + "project_id\030\001 \001(\tB\004\342A\001\002\022\024\n" + "\006region\030\003 \001(\tB\004\342A\001\002\0228\n" + "\007cluster\030\002" + " \001(\0132!.google.cloud.dataproc.v1.ClusterB\004\342A\001\002\022\030\n\n" + "request_id\030\004 \001(\tB\004\342A\001\001\022W\n" - + " action_on_failed_primary_workers\030\005 \001(\016" - + "2\'.google.cloud.dataproc.v1.FailureActionB\004\342A\001\001\"\265\002\n" + + " action_on_failed_primary_workers\030\005" + + " \001(\0162\'.google.cloud.dataproc.v1.FailureActionB\004\342A\001\001\"\265\002\n" + "\024UpdateClusterRequest\022\030\n\n" + "project_id\030\001 \001(\tB\004\342A\001\002\022\024\n" + "\006region\030\005 \001(\tB\004\342A\001\002\022\032\n" @@ -736,8 +747,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "project_id\030\001 \001(\tB\004\342A\001\002\022\024\n" + "\006region\030\004 \001(\tB\004\342A\001\002\022\024\n" + "\006filter\030\005 \001(\tB\004\342A\001\001\022\027\n" - + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n" - + "\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"p\n" + "\024ListClustersResponse\0229\n" + "\010clusters\030\001" @@ -748,8 +758,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006region\030\003 \001(\tB\004\342A\001\002\022\032\n" + "\014cluster_name\030\002 \001(\tB\004\342A\001\002\022\035\n" + "\017tarball_gcs_dir\030\004 \001(\tB\004\342A\001\001\022\\\n" - + "\016tarball_access\030\005 \001(\0162>.google.cloud.dataproc." - + "v1.DiagnoseClusterRequest.TarballAccessB\004\342A\001\001\0227\n" + + "\016tarball_access\030\005 \001(\0162>.google.cloud." + + "dataproc.v1.DiagnoseClusterRequest.TarballAccessB\004\342A\001\001\0227\n" + "\022diagnosis_interval\030\006" + " \001(\0132\025.google.type.IntervalB\004\342A\001\001\022\022\n" + "\004jobs\030\n" @@ -762,8 +772,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\026DiagnoseClusterResults\022\030\n\n" + "output_uri\030\001 \001(\tB\004\342A\001\003\"\373\001\n" + "\023ReservationAffinity\022Z\n" - + "\030consume_reservation_type\030\001" - + " \001(\01622.google.cloud.dataproc.v1.ReservationAffinity.TypeB\004\342A\001\001\022\021\n" + + "\030consume_reservation_type\030\001 \001(\01622.google.cloud.da" + + "taproc.v1.ReservationAffinity.TypeB\004\342A\001\001\022\021\n" + "\003key\030\002 \001(\tB\004\342A\001\001\022\024\n" + "\006values\030\003 \003(\tB\004\342A\001\001\"_\n" + "\004Type\022\024\n" @@ -772,56 +782,58 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017ANY_RESERVATION\020\002\022\030\n" + "\024SPECIFIC_RESERVATION\020\0032\344\020\n" + "\021ClusterController\022\200\002\n\r" - + "CreateCluster\022..google.cloud.dataproc.v1.Cre" - + "ateClusterRequest\032\035.google.longrunning.Operation\"\237\001\312A<\n" - + "\007Cluster\0221google.cloud.dataproc.v1.ClusterOperationMetadata\332A\031pro" - + "ject_id,region,cluster\202\323\344\223\002>\"3/v1/projec" - + "ts/{project_id}/regions/{region}/clusters:\007cluster\022\250\002\n\r" - + "UpdateCluster\022..google.cl" - + "oud.dataproc.v1.UpdateClusterRequest\032\035.google.longrunning.Operation\"\307\001\312A<\n" - + "\007Cluster\0221google.cloud.dataproc.v1.ClusterOper" - + "ationMetadata\332A2project_id,region,cluste" - + "r_name,cluster,update_mask\202\323\344\223\002M2B/v1/pr" - + "ojects/{project_id}/regions/{region}/clusters/{cluster_name}:\007cluster\022\356\001\n" - + "\013StopCluster\022,.google.cloud.dataproc.v1.StopClu" - + "sterRequest\032\035.google.longrunning.Operation\"\221\001\312A<\n" - + "\007Cluster\0221google.cloud.dataproc" - + ".v1.ClusterOperationMetadata\202\323\344\223\002L\"G/v1/" - + "projects/{project_id}/regions/{region}/clusters/{cluster_name}:stop:\001*\022\361\001\n" - + "\014StartCluster\022-.google.cloud.dataproc.v1.Start" - + "ClusterRequest\032\035.google.longrunning.Operation\"\222\001\312A<\n" - + "\007Cluster\0221google.cloud.datap" - + "roc.v1.ClusterOperationMetadata\202\323\344\223\002M\"H/" - + "v1/projects/{project_id}/regions/{region}/clusters/{cluster_name}:start:\001*\022\231\002\n\r" - + "DeleteCluster\022..google.cloud.dataproc.v1." - + "DeleteClusterRequest\032\035.google.longrunning.Operation\"\270\001\312AJ\n" - + "\025google.protobuf.Empty\0221google.cloud.dataproc.v1.ClusterOperat" - + "ionMetadata\332A\036project_id,region,cluster_" - + "name\202\323\344\223\002D*B/v1/projects/{project_id}/re", - "gions/{region}/clusters/{cluster_name}\022\311" - + "\001\n\nGetCluster\022+.google.cloud.dataproc.v1" - + ".GetClusterRequest\032!.google.cloud.datapr" - + "oc.v1.Cluster\"k\332A\036project_id,region,clus" - + "ter_name\202\323\344\223\002D\022B/v1/projects/{project_id" - + "}/regions/{region}/clusters/{cluster_nam" - + "e}\022\331\001\n\014ListClusters\022-.google.cloud.datap" - + "roc.v1.ListClustersRequest\032..google.clou" - + "d.dataproc.v1.ListClustersResponse\"j\332A\021p" - + "roject_id,region\332A\030project_id,region,fil" - + "ter\202\323\344\223\0025\0223/v1/projects/{project_id}/reg" - + "ions/{region}/clusters\022\252\002\n\017DiagnoseClust" - + "er\0220.google.cloud.dataproc.v1.DiagnoseCl" - + "usterRequest\032\035.google.longrunning.Operat" - + "ion\"\305\001\312AK\n\026DiagnoseClusterResults\0221googl" - + "e.cloud.dataproc.v1.ClusterOperationMeta" - + "data\332A\036project_id,region,cluster_name\202\323\344" - + "\223\002P\"K/v1/projects/{project_id}/regions/{" - + "region}/clusters/{cluster_name}:diagnose" - + ":\001*\032K\312A\027dataproc.googleapis.com\322A.https:" - + "//www.googleapis.com/auth/cloud-platform" - + "Bl\n\034com.google.cloud.dataproc.v1B\rCluste" - + "rsProtoP\001Z;cloud.google.com/go/dataproc/" - + "v2/apiv1/dataprocpb;dataprocpbb\006proto3" + + "CreateCluster\022..google.cloud.datapr" + + "oc.v1.CreateClusterRequest\032\035.google.longrunning.Operation\"\237\001\312A<\n" + + "\007Cluster\0221google.cloud.dataproc.v1.ClusterOperationMetad" + + "ata\332A\031project_id,region,cluster\202\323\344\223\002>\"3/" + + "v1/projects/{project_id}/regions/{region}/clusters:\007cluster\022\250\002\n\r" + + "UpdateCluster\022..google.cloud.dataproc.v1.UpdateClusterRe" + + "quest\032\035.google.longrunning.Operation\"\307\001\312A<\n" + + "\007Cluster\0221google.cloud.dataproc.v1.ClusterOperationMetadata\332A2project_id,regi" + + "on,cluster_name,cluster,update_mask\202\323\344\223\002" + + "M2B/v1/projects/{project_id}/regions/{re" + + "gion}/clusters/{cluster_name}:\007cluster\022\356\001\n" + + "\013StopCluster\022,.google.cloud.dataproc.v" + + "1.StopClusterRequest\032\035.google.longrunning.Operation\"\221\001\312A<\n" + + "\007Cluster\0221google.cloud.dataproc.v1.ClusterOperationMetadata\202\323\344" + + "\223\002L\"G/v1/projects/{project_id}/regions/{" + + "region}/clusters/{cluster_name}:stop:\001*\022\361\001\n" + + "\014StartCluster\022-.google.cloud.dataproc" + + ".v1.StartClusterRequest\032\035.google.longrunning.Operation\"\222\001\312A<\n" + + "\007Cluster\0221google.cloud.dataproc.v1.ClusterOperationMetadata" + + "\202\323\344\223\002M\"H/v1/projects/{project_id}/region" + + "s/{region}/clusters/{cluster_name}:start", + ":\001*\022\231\002\n\rDeleteCluster\022..google.cloud.dat" + + "aproc.v1.DeleteClusterRequest\032\035.google.l" + + "ongrunning.Operation\"\270\001\312AJ\n\025google.proto" + + "buf.Empty\0221google.cloud.dataproc.v1.Clus" + + "terOperationMetadata\332A\036project_id,region" + + ",cluster_name\202\323\344\223\002D*B/v1/projects/{proje" + + "ct_id}/regions/{region}/clusters/{cluste" + + "r_name}\022\311\001\n\nGetCluster\022+.google.cloud.da" + + "taproc.v1.GetClusterRequest\032!.google.clo" + + "ud.dataproc.v1.Cluster\"k\332A\036project_id,re" + + "gion,cluster_name\202\323\344\223\002D\022B/v1/projects/{p" + + "roject_id}/regions/{region}/clusters/{cl" + + "uster_name}\022\331\001\n\014ListClusters\022-.google.cl" + + "oud.dataproc.v1.ListClustersRequest\032..go" + + "ogle.cloud.dataproc.v1.ListClustersRespo" + + "nse\"j\332A\021project_id,region\332A\030project_id,r" + + "egion,filter\202\323\344\223\0025\0223/v1/projects/{projec" + + "t_id}/regions/{region}/clusters\022\252\002\n\017Diag" + + "noseCluster\0220.google.cloud.dataproc.v1.D" + + "iagnoseClusterRequest\032\035.google.longrunni" + + "ng.Operation\"\305\001\312AK\n\026DiagnoseClusterResul" + + "ts\0221google.cloud.dataproc.v1.ClusterOper" + + "ationMetadata\332A\036project_id,region,cluste" + + "r_name\202\323\344\223\002P\"K/v1/projects/{project_id}/" + + "regions/{region}/clusters/{cluster_name}" + + ":diagnose:\001*\032K\312A\027dataproc.googleapis.com" + + "\322A.https://www.googleapis.com/auth/cloud" + + "-platformBl\n\034com.google.cloud.dataproc.v" + + "1B\rClustersProtoP\001Z;cloud.google.com/go/" + + "dataproc/v2/apiv1/dataprocpb;dataprocpbb" + + "\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -889,9 +901,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "MetastoreConfig", "DataprocMetricConfig", "AuxiliaryNodeGroups", + "SchedulingConfig", "MasterFlexibleConfig", "WorkerFlexibleConfig", "SecondaryWorkerFlexibleConfig", + "ProvisioningConfig", }); internal_static_google_cloud_dataproc_v1_VirtualClusterConfig_descriptor = getDescriptor().getMessageType(2); @@ -1298,8 +1312,16 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "MetricSource", "MetricOverrides", }); - internal_static_google_cloud_dataproc_v1_CreateClusterRequest_descriptor = + internal_static_google_cloud_dataproc_v1_SchedulingConfig_descriptor = getDescriptor().getMessageType(33); + internal_static_google_cloud_dataproc_v1_SchedulingConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_dataproc_v1_SchedulingConfig_descriptor, + new java.lang.String[] { + "SchedulingTimeout", "RequestedRunDuration", + }); + internal_static_google_cloud_dataproc_v1_CreateClusterRequest_descriptor = + getDescriptor().getMessageType(34); internal_static_google_cloud_dataproc_v1_CreateClusterRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataproc_v1_CreateClusterRequest_descriptor, @@ -1307,7 +1329,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ProjectId", "Region", "Cluster", "RequestId", "ActionOnFailedPrimaryWorkers", }); internal_static_google_cloud_dataproc_v1_UpdateClusterRequest_descriptor = - getDescriptor().getMessageType(34); + getDescriptor().getMessageType(35); internal_static_google_cloud_dataproc_v1_UpdateClusterRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataproc_v1_UpdateClusterRequest_descriptor, @@ -1321,7 +1343,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "RequestId", }); internal_static_google_cloud_dataproc_v1_StopClusterRequest_descriptor = - getDescriptor().getMessageType(35); + getDescriptor().getMessageType(36); internal_static_google_cloud_dataproc_v1_StopClusterRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataproc_v1_StopClusterRequest_descriptor, @@ -1329,7 +1351,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ProjectId", "Region", "ClusterName", "ClusterUuid", "RequestId", }); internal_static_google_cloud_dataproc_v1_StartClusterRequest_descriptor = - getDescriptor().getMessageType(36); + getDescriptor().getMessageType(37); internal_static_google_cloud_dataproc_v1_StartClusterRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataproc_v1_StartClusterRequest_descriptor, @@ -1337,7 +1359,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ProjectId", "Region", "ClusterName", "ClusterUuid", "RequestId", }); internal_static_google_cloud_dataproc_v1_DeleteClusterRequest_descriptor = - getDescriptor().getMessageType(37); + getDescriptor().getMessageType(38); internal_static_google_cloud_dataproc_v1_DeleteClusterRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataproc_v1_DeleteClusterRequest_descriptor, @@ -1345,7 +1367,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ProjectId", "Region", "ClusterName", "ClusterUuid", "RequestId", }); internal_static_google_cloud_dataproc_v1_GetClusterRequest_descriptor = - getDescriptor().getMessageType(38); + getDescriptor().getMessageType(39); internal_static_google_cloud_dataproc_v1_GetClusterRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataproc_v1_GetClusterRequest_descriptor, @@ -1353,7 +1375,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ProjectId", "Region", "ClusterName", }); internal_static_google_cloud_dataproc_v1_ListClustersRequest_descriptor = - getDescriptor().getMessageType(39); + getDescriptor().getMessageType(40); internal_static_google_cloud_dataproc_v1_ListClustersRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataproc_v1_ListClustersRequest_descriptor, @@ -1361,7 +1383,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ProjectId", "Region", "Filter", "PageSize", "PageToken", }); internal_static_google_cloud_dataproc_v1_ListClustersResponse_descriptor = - getDescriptor().getMessageType(40); + getDescriptor().getMessageType(41); internal_static_google_cloud_dataproc_v1_ListClustersResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataproc_v1_ListClustersResponse_descriptor, @@ -1369,7 +1391,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Clusters", "NextPageToken", }); internal_static_google_cloud_dataproc_v1_DiagnoseClusterRequest_descriptor = - getDescriptor().getMessageType(41); + getDescriptor().getMessageType(42); internal_static_google_cloud_dataproc_v1_DiagnoseClusterRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataproc_v1_DiagnoseClusterRequest_descriptor, @@ -1384,7 +1406,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "YarnApplicationIds", }); internal_static_google_cloud_dataproc_v1_DiagnoseClusterResults_descriptor = - getDescriptor().getMessageType(42); + getDescriptor().getMessageType(43); internal_static_google_cloud_dataproc_v1_DiagnoseClusterResults_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataproc_v1_DiagnoseClusterResults_descriptor, @@ -1392,7 +1414,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "OutputUri", }); internal_static_google_cloud_dataproc_v1_ReservationAffinity_descriptor = - getDescriptor().getMessageType(43); + getDescriptor().getMessageType(44); internal_static_google_cloud_dataproc_v1_ReservationAffinity_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_dataproc_v1_ReservationAffinity_descriptor, diff --git a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ConfidentialInstanceConfig.java b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ConfidentialInstanceConfig.java index 00b8ccbb8e99..885e767406d0 100644 --- a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ConfidentialInstanceConfig.java +++ b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ConfidentialInstanceConfig.java @@ -293,7 +293,7 @@ private ConfidentialInstanceType(int value) { * * * @deprecated google.cloud.dataproc.v1.ConfidentialInstanceConfig.enable_confidential_compute is - * deprecated. See google/cloud/dataproc/v1/clusters.proto;l=756 + * deprecated. See google/cloud/dataproc/v1/clusters.proto;l=764 * @return The enableConfidentialCompute. */ @java.lang.Override @@ -701,7 +701,7 @@ public Builder mergeFrom( * * * @deprecated google.cloud.dataproc.v1.ConfidentialInstanceConfig.enable_confidential_compute - * is deprecated. See google/cloud/dataproc/v1/clusters.proto;l=756 + * is deprecated. See google/cloud/dataproc/v1/clusters.proto;l=764 * @return The enableConfidentialCompute. */ @java.lang.Override @@ -723,7 +723,7 @@ public boolean getEnableConfidentialCompute() { * * * @deprecated google.cloud.dataproc.v1.ConfidentialInstanceConfig.enable_confidential_compute - * is deprecated. See google/cloud/dataproc/v1/clusters.proto;l=756 + * is deprecated. See google/cloud/dataproc/v1/clusters.proto;l=764 * @param value The enableConfidentialCompute to set. * @return This builder for chaining. */ @@ -749,7 +749,7 @@ public Builder setEnableConfidentialCompute(boolean value) { * * * @deprecated google.cloud.dataproc.v1.ConfidentialInstanceConfig.enable_confidential_compute - * is deprecated. See google/cloud/dataproc/v1/clusters.proto;l=756 + * is deprecated. See google/cloud/dataproc/v1/clusters.proto;l=764 * @return This builder for chaining. */ @java.lang.Deprecated diff --git a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ConfidentialInstanceConfigOrBuilder.java b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ConfidentialInstanceConfigOrBuilder.java index 5a781ba8da52..1c701d0b998e 100644 --- a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ConfidentialInstanceConfigOrBuilder.java +++ b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/ConfidentialInstanceConfigOrBuilder.java @@ -39,7 +39,7 @@ public interface ConfidentialInstanceConfigOrBuilder * * * @deprecated google.cloud.dataproc.v1.ConfidentialInstanceConfig.enable_confidential_compute is - * deprecated. See google/cloud/dataproc/v1/clusters.proto;l=756 + * deprecated. See google/cloud/dataproc/v1/clusters.proto;l=764 * @return The enableConfidentialCompute. */ @java.lang.Deprecated diff --git a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/SchedulingConfig.java b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/SchedulingConfig.java new file mode 100644 index 000000000000..2abf9117b6f5 --- /dev/null +++ b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/SchedulingConfig.java @@ -0,0 +1,1095 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/dataproc/v1/clusters.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.dataproc.v1; + +/** + * + * + *
                      + * Config for scheduling the request to create Compute Engine resources for the
                      + * cluster, when available.
                      + * 
                      + * + * Protobuf type {@code google.cloud.dataproc.v1.SchedulingConfig} + */ +@com.google.protobuf.Generated +public final class SchedulingConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataproc.v1.SchedulingConfig) + SchedulingConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "SchedulingConfig"); + } + + // Use SchedulingConfig.newBuilder() to construct. + private SchedulingConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private SchedulingConfig() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataproc.v1.ClustersProto + .internal_static_google_cloud_dataproc_v1_SchedulingConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataproc.v1.ClustersProto + .internal_static_google_cloud_dataproc_v1_SchedulingConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataproc.v1.SchedulingConfig.class, + com.google.cloud.dataproc.v1.SchedulingConfig.Builder.class); + } + + private int bitField0_; + public static final int SCHEDULING_TIMEOUT_FIELD_NUMBER = 1; + private com.google.protobuf.Duration schedulingTimeout_; + + /** + * + * + *
                      +   * Optional. How long to wait for worker resources to be allocated before
                      +   * failing the cluster creation request. Max/Default value: 13 days.
                      +   * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the schedulingTimeout field is set. + */ + @java.lang.Override + public boolean hasSchedulingTimeout() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +   * Optional. How long to wait for worker resources to be allocated before
                      +   * failing the cluster creation request. Max/Default value: 13 days.
                      +   * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The schedulingTimeout. + */ + @java.lang.Override + public com.google.protobuf.Duration getSchedulingTimeout() { + return schedulingTimeout_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : schedulingTimeout_; + } + + /** + * + * + *
                      +   * Optional. How long to wait for worker resources to be allocated before
                      +   * failing the cluster creation request. Max/Default value: 13 days.
                      +   * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getSchedulingTimeoutOrBuilder() { + return schedulingTimeout_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : schedulingTimeout_; + } + + public static final int REQUESTED_RUN_DURATION_FIELD_NUMBER = 2; + private com.google.protobuf.Duration requestedRunDuration_; + + /** + * + * + *
                      +   * Optional. Required lifetime of the resources, once provisioned.
                      +   * Min 10 mins, Max/Default 7 days.
                      +   * Note that the cluster can still be deleted before reaching this time.
                      +   * This time is a maximum amount of time before the cluster is forcibly
                      +   * deleted. Lower times are more likely to start running sooner.
                      +   * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the requestedRunDuration field is set. + */ + @java.lang.Override + public boolean hasRequestedRunDuration() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Optional. Required lifetime of the resources, once provisioned.
                      +   * Min 10 mins, Max/Default 7 days.
                      +   * Note that the cluster can still be deleted before reaching this time.
                      +   * This time is a maximum amount of time before the cluster is forcibly
                      +   * deleted. Lower times are more likely to start running sooner.
                      +   * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The requestedRunDuration. + */ + @java.lang.Override + public com.google.protobuf.Duration getRequestedRunDuration() { + return requestedRunDuration_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : requestedRunDuration_; + } + + /** + * + * + *
                      +   * Optional. Required lifetime of the resources, once provisioned.
                      +   * Min 10 mins, Max/Default 7 days.
                      +   * Note that the cluster can still be deleted before reaching this time.
                      +   * This time is a maximum amount of time before the cluster is forcibly
                      +   * deleted. Lower times are more likely to start running sooner.
                      +   * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getRequestedRunDurationOrBuilder() { + return requestedRunDuration_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : requestedRunDuration_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getSchedulingTimeout()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getRequestedRunDuration()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getSchedulingTimeout()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(2, getRequestedRunDuration()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.dataproc.v1.SchedulingConfig)) { + return super.equals(obj); + } + com.google.cloud.dataproc.v1.SchedulingConfig other = + (com.google.cloud.dataproc.v1.SchedulingConfig) obj; + + if (hasSchedulingTimeout() != other.hasSchedulingTimeout()) return false; + if (hasSchedulingTimeout()) { + if (!getSchedulingTimeout().equals(other.getSchedulingTimeout())) return false; + } + if (hasRequestedRunDuration() != other.hasRequestedRunDuration()) return false; + if (hasRequestedRunDuration()) { + if (!getRequestedRunDuration().equals(other.getRequestedRunDuration())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasSchedulingTimeout()) { + hash = (37 * hash) + SCHEDULING_TIMEOUT_FIELD_NUMBER; + hash = (53 * hash) + getSchedulingTimeout().hashCode(); + } + if (hasRequestedRunDuration()) { + hash = (37 * hash) + REQUESTED_RUN_DURATION_FIELD_NUMBER; + hash = (53 * hash) + getRequestedRunDuration().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.dataproc.v1.SchedulingConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                      +   * Config for scheduling the request to create Compute Engine resources for the
                      +   * cluster, when available.
                      +   * 
                      + * + * Protobuf type {@code google.cloud.dataproc.v1.SchedulingConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataproc.v1.SchedulingConfig) + com.google.cloud.dataproc.v1.SchedulingConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataproc.v1.ClustersProto + .internal_static_google_cloud_dataproc_v1_SchedulingConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataproc.v1.ClustersProto + .internal_static_google_cloud_dataproc_v1_SchedulingConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataproc.v1.SchedulingConfig.class, + com.google.cloud.dataproc.v1.SchedulingConfig.Builder.class); + } + + // Construct using com.google.cloud.dataproc.v1.SchedulingConfig.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetSchedulingTimeoutFieldBuilder(); + internalGetRequestedRunDurationFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + schedulingTimeout_ = null; + if (schedulingTimeoutBuilder_ != null) { + schedulingTimeoutBuilder_.dispose(); + schedulingTimeoutBuilder_ = null; + } + requestedRunDuration_ = null; + if (requestedRunDurationBuilder_ != null) { + requestedRunDurationBuilder_.dispose(); + requestedRunDurationBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataproc.v1.ClustersProto + .internal_static_google_cloud_dataproc_v1_SchedulingConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataproc.v1.SchedulingConfig getDefaultInstanceForType() { + return com.google.cloud.dataproc.v1.SchedulingConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataproc.v1.SchedulingConfig build() { + com.google.cloud.dataproc.v1.SchedulingConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataproc.v1.SchedulingConfig buildPartial() { + com.google.cloud.dataproc.v1.SchedulingConfig result = + new com.google.cloud.dataproc.v1.SchedulingConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataproc.v1.SchedulingConfig result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.schedulingTimeout_ = + schedulingTimeoutBuilder_ == null + ? schedulingTimeout_ + : schedulingTimeoutBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.requestedRunDuration_ = + requestedRunDurationBuilder_ == null + ? requestedRunDuration_ + : requestedRunDurationBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataproc.v1.SchedulingConfig) { + return mergeFrom((com.google.cloud.dataproc.v1.SchedulingConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataproc.v1.SchedulingConfig other) { + if (other == com.google.cloud.dataproc.v1.SchedulingConfig.getDefaultInstance()) return this; + if (other.hasSchedulingTimeout()) { + mergeSchedulingTimeout(other.getSchedulingTimeout()); + } + if (other.hasRequestedRunDuration()) { + mergeRequestedRunDuration(other.getRequestedRunDuration()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetSchedulingTimeoutFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetRequestedRunDurationFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.Duration schedulingTimeout_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + schedulingTimeoutBuilder_; + + /** + * + * + *
                      +     * Optional. How long to wait for worker resources to be allocated before
                      +     * failing the cluster creation request. Max/Default value: 13 days.
                      +     * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the schedulingTimeout field is set. + */ + public boolean hasSchedulingTimeout() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                      +     * Optional. How long to wait for worker resources to be allocated before
                      +     * failing the cluster creation request. Max/Default value: 13 days.
                      +     * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The schedulingTimeout. + */ + public com.google.protobuf.Duration getSchedulingTimeout() { + if (schedulingTimeoutBuilder_ == null) { + return schedulingTimeout_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : schedulingTimeout_; + } else { + return schedulingTimeoutBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. How long to wait for worker resources to be allocated before
                      +     * failing the cluster creation request. Max/Default value: 13 days.
                      +     * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setSchedulingTimeout(com.google.protobuf.Duration value) { + if (schedulingTimeoutBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + schedulingTimeout_ = value; + } else { + schedulingTimeoutBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. How long to wait for worker resources to be allocated before
                      +     * failing the cluster creation request. Max/Default value: 13 days.
                      +     * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setSchedulingTimeout(com.google.protobuf.Duration.Builder builderForValue) { + if (schedulingTimeoutBuilder_ == null) { + schedulingTimeout_ = builderForValue.build(); + } else { + schedulingTimeoutBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. How long to wait for worker resources to be allocated before
                      +     * failing the cluster creation request. Max/Default value: 13 days.
                      +     * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeSchedulingTimeout(com.google.protobuf.Duration value) { + if (schedulingTimeoutBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && schedulingTimeout_ != null + && schedulingTimeout_ != com.google.protobuf.Duration.getDefaultInstance()) { + getSchedulingTimeoutBuilder().mergeFrom(value); + } else { + schedulingTimeout_ = value; + } + } else { + schedulingTimeoutBuilder_.mergeFrom(value); + } + if (schedulingTimeout_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. How long to wait for worker resources to be allocated before
                      +     * failing the cluster creation request. Max/Default value: 13 days.
                      +     * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearSchedulingTimeout() { + bitField0_ = (bitField0_ & ~0x00000001); + schedulingTimeout_ = null; + if (schedulingTimeoutBuilder_ != null) { + schedulingTimeoutBuilder_.dispose(); + schedulingTimeoutBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. How long to wait for worker resources to be allocated before
                      +     * failing the cluster creation request. Max/Default value: 13 days.
                      +     * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.Duration.Builder getSchedulingTimeoutBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetSchedulingTimeoutFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. How long to wait for worker resources to be allocated before
                      +     * failing the cluster creation request. Max/Default value: 13 days.
                      +     * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.DurationOrBuilder getSchedulingTimeoutOrBuilder() { + if (schedulingTimeoutBuilder_ != null) { + return schedulingTimeoutBuilder_.getMessageOrBuilder(); + } else { + return schedulingTimeout_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : schedulingTimeout_; + } + } + + /** + * + * + *
                      +     * Optional. How long to wait for worker resources to be allocated before
                      +     * failing the cluster creation request. Max/Default value: 13 days.
                      +     * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + internalGetSchedulingTimeoutFieldBuilder() { + if (schedulingTimeoutBuilder_ == null) { + schedulingTimeoutBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>( + getSchedulingTimeout(), getParentForChildren(), isClean()); + schedulingTimeout_ = null; + } + return schedulingTimeoutBuilder_; + } + + private com.google.protobuf.Duration requestedRunDuration_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + requestedRunDurationBuilder_; + + /** + * + * + *
                      +     * Optional. Required lifetime of the resources, once provisioned.
                      +     * Min 10 mins, Max/Default 7 days.
                      +     * Note that the cluster can still be deleted before reaching this time.
                      +     * This time is a maximum amount of time before the cluster is forcibly
                      +     * deleted. Lower times are more likely to start running sooner.
                      +     * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the requestedRunDuration field is set. + */ + public boolean hasRequestedRunDuration() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +     * Optional. Required lifetime of the resources, once provisioned.
                      +     * Min 10 mins, Max/Default 7 days.
                      +     * Note that the cluster can still be deleted before reaching this time.
                      +     * This time is a maximum amount of time before the cluster is forcibly
                      +     * deleted. Lower times are more likely to start running sooner.
                      +     * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The requestedRunDuration. + */ + public com.google.protobuf.Duration getRequestedRunDuration() { + if (requestedRunDurationBuilder_ == null) { + return requestedRunDuration_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : requestedRunDuration_; + } else { + return requestedRunDurationBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. Required lifetime of the resources, once provisioned.
                      +     * Min 10 mins, Max/Default 7 days.
                      +     * Note that the cluster can still be deleted before reaching this time.
                      +     * This time is a maximum amount of time before the cluster is forcibly
                      +     * deleted. Lower times are more likely to start running sooner.
                      +     * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setRequestedRunDuration(com.google.protobuf.Duration value) { + if (requestedRunDurationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + requestedRunDuration_ = value; + } else { + requestedRunDurationBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Required lifetime of the resources, once provisioned.
                      +     * Min 10 mins, Max/Default 7 days.
                      +     * Note that the cluster can still be deleted before reaching this time.
                      +     * This time is a maximum amount of time before the cluster is forcibly
                      +     * deleted. Lower times are more likely to start running sooner.
                      +     * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setRequestedRunDuration(com.google.protobuf.Duration.Builder builderForValue) { + if (requestedRunDurationBuilder_ == null) { + requestedRunDuration_ = builderForValue.build(); + } else { + requestedRunDurationBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Required lifetime of the resources, once provisioned.
                      +     * Min 10 mins, Max/Default 7 days.
                      +     * Note that the cluster can still be deleted before reaching this time.
                      +     * This time is a maximum amount of time before the cluster is forcibly
                      +     * deleted. Lower times are more likely to start running sooner.
                      +     * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeRequestedRunDuration(com.google.protobuf.Duration value) { + if (requestedRunDurationBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && requestedRunDuration_ != null + && requestedRunDuration_ != com.google.protobuf.Duration.getDefaultInstance()) { + getRequestedRunDurationBuilder().mergeFrom(value); + } else { + requestedRunDuration_ = value; + } + } else { + requestedRunDurationBuilder_.mergeFrom(value); + } + if (requestedRunDuration_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. Required lifetime of the resources, once provisioned.
                      +     * Min 10 mins, Max/Default 7 days.
                      +     * Note that the cluster can still be deleted before reaching this time.
                      +     * This time is a maximum amount of time before the cluster is forcibly
                      +     * deleted. Lower times are more likely to start running sooner.
                      +     * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearRequestedRunDuration() { + bitField0_ = (bitField0_ & ~0x00000002); + requestedRunDuration_ = null; + if (requestedRunDurationBuilder_ != null) { + requestedRunDurationBuilder_.dispose(); + requestedRunDurationBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Required lifetime of the resources, once provisioned.
                      +     * Min 10 mins, Max/Default 7 days.
                      +     * Note that the cluster can still be deleted before reaching this time.
                      +     * This time is a maximum amount of time before the cluster is forcibly
                      +     * deleted. Lower times are more likely to start running sooner.
                      +     * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.Duration.Builder getRequestedRunDurationBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetRequestedRunDurationFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. Required lifetime of the resources, once provisioned.
                      +     * Min 10 mins, Max/Default 7 days.
                      +     * Note that the cluster can still be deleted before reaching this time.
                      +     * This time is a maximum amount of time before the cluster is forcibly
                      +     * deleted. Lower times are more likely to start running sooner.
                      +     * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.DurationOrBuilder getRequestedRunDurationOrBuilder() { + if (requestedRunDurationBuilder_ != null) { + return requestedRunDurationBuilder_.getMessageOrBuilder(); + } else { + return requestedRunDuration_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : requestedRunDuration_; + } + } + + /** + * + * + *
                      +     * Optional. Required lifetime of the resources, once provisioned.
                      +     * Min 10 mins, Max/Default 7 days.
                      +     * Note that the cluster can still be deleted before reaching this time.
                      +     * This time is a maximum amount of time before the cluster is forcibly
                      +     * deleted. Lower times are more likely to start running sooner.
                      +     * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + internalGetRequestedRunDurationFieldBuilder() { + if (requestedRunDurationBuilder_ == null) { + requestedRunDurationBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>( + getRequestedRunDuration(), getParentForChildren(), isClean()); + requestedRunDuration_ = null; + } + return requestedRunDurationBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataproc.v1.SchedulingConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataproc.v1.SchedulingConfig) + private static final com.google.cloud.dataproc.v1.SchedulingConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataproc.v1.SchedulingConfig(); + } + + public static com.google.cloud.dataproc.v1.SchedulingConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SchedulingConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.dataproc.v1.SchedulingConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/SchedulingConfigOrBuilder.java b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/SchedulingConfigOrBuilder.java new file mode 100644 index 000000000000..452d51237608 --- /dev/null +++ b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/java/com/google/cloud/dataproc/v1/SchedulingConfigOrBuilder.java @@ -0,0 +1,129 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/dataproc/v1/clusters.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.dataproc.v1; + +@com.google.protobuf.Generated +public interface SchedulingConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataproc.v1.SchedulingConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                      +   * Optional. How long to wait for worker resources to be allocated before
                      +   * failing the cluster creation request. Max/Default value: 13 days.
                      +   * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the schedulingTimeout field is set. + */ + boolean hasSchedulingTimeout(); + + /** + * + * + *
                      +   * Optional. How long to wait for worker resources to be allocated before
                      +   * failing the cluster creation request. Max/Default value: 13 days.
                      +   * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The schedulingTimeout. + */ + com.google.protobuf.Duration getSchedulingTimeout(); + + /** + * + * + *
                      +   * Optional. How long to wait for worker resources to be allocated before
                      +   * failing the cluster creation request. Max/Default value: 13 days.
                      +   * 
                      + * + * + * .google.protobuf.Duration scheduling_timeout = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.DurationOrBuilder getSchedulingTimeoutOrBuilder(); + + /** + * + * + *
                      +   * Optional. Required lifetime of the resources, once provisioned.
                      +   * Min 10 mins, Max/Default 7 days.
                      +   * Note that the cluster can still be deleted before reaching this time.
                      +   * This time is a maximum amount of time before the cluster is forcibly
                      +   * deleted. Lower times are more likely to start running sooner.
                      +   * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the requestedRunDuration field is set. + */ + boolean hasRequestedRunDuration(); + + /** + * + * + *
                      +   * Optional. Required lifetime of the resources, once provisioned.
                      +   * Min 10 mins, Max/Default 7 days.
                      +   * Note that the cluster can still be deleted before reaching this time.
                      +   * This time is a maximum amount of time before the cluster is forcibly
                      +   * deleted. Lower times are more likely to start running sooner.
                      +   * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The requestedRunDuration. + */ + com.google.protobuf.Duration getRequestedRunDuration(); + + /** + * + * + *
                      +   * Optional. Required lifetime of the resources, once provisioned.
                      +   * Min 10 mins, Max/Default 7 days.
                      +   * Note that the cluster can still be deleted before reaching this time.
                      +   * This time is a maximum amount of time before the cluster is forcibly
                      +   * deleted. Lower times are more likely to start running sooner.
                      +   * 
                      + * + * + * .google.protobuf.Duration requested_run_duration = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.DurationOrBuilder getRequestedRunDurationOrBuilder(); +} diff --git a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/proto/google/cloud/dataproc/v1/clusters.proto b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/proto/google/cloud/dataproc/v1/clusters.proto index c173c2616ce2..a4b7525b2612 100644 --- a/java-dataproc/proto-google-cloud-dataproc-v1/src/main/proto/google/cloud/dataproc/v1/clusters.proto +++ b/java-dataproc/proto-google-cloud-dataproc-v1/src/main/proto/google/cloud/dataproc/v1/clusters.proto @@ -360,6 +360,14 @@ message ClusterConfig { repeated AuxiliaryNodeGroup auxiliary_node_groups = 25 [(google.api.field_behavior) = OPTIONAL]; + // Config for provisioning the Compute Engine resources. + oneof provisioning_config { + // Optional. Config for scheduling the resources to be allocated when + // available. + SchedulingConfig scheduling_config = 26 + [(google.api.field_behavior) = OPTIONAL]; + } + // Optional. The High Obtainability (HO) config settings for the cluster's // master instances. // @@ -1646,6 +1654,23 @@ message DataprocMetricConfig { repeated Metric metrics = 1 [(google.api.field_behavior) = REQUIRED]; } +// Config for scheduling the request to create Compute Engine resources for the +// cluster, when available. +message SchedulingConfig { + // Optional. How long to wait for worker resources to be allocated before + // failing the cluster creation request. Max/Default value: 13 days. + google.protobuf.Duration scheduling_timeout = 1 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Required lifetime of the resources, once provisioned. + // Min 10 mins, Max/Default 7 days. + // Note that the cluster can still be deleted before reaching this time. + // This time is a maximum amount of time before the cluster is forcibly + // deleted. Lower times are more likely to start running sooner. + google.protobuf.Duration requested_run_duration = 2 + [(google.api.field_behavior) = OPTIONAL]; +} + // A request to create a cluster. message CreateClusterRequest { // Required. The ID of the Google Cloud Platform project that the cluster diff --git a/java-datastore/README.md b/java-datastore/README.md index 0dfde09b4f74..b0e0059245f3 100644 --- a/java-datastore/README.md +++ b/java-datastore/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-datastore - 3.10.0 + 3.11.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-datastore' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-datastore:3.10.0' +implementation 'com.google.cloud:google-cloud-datastore:3.11.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-datastore" % "3.10.0" +libraryDependencies += "com.google.cloud" % "google-cloud-datastore" % "3.11.0" ``` ## Authentication @@ -473,7 +473,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-datastore/latest/history [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-datastore.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-datastore/3.10.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-datastore/3.11.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-datastream/README.md b/java-datastream/README.md index c02f68952e47..2a894446ddff 100644 --- a/java-datastream/README.md +++ b/java-datastream/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-datastream - 1.101.0 + 1.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-datastream' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-datastream:1.101.0' +implementation 'com.google.cloud:google-cloud-datastream:1.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-datastream" % "1.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-datastream" % "1.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-datastream/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-datastream.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-datastream/1.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-datastream/1.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-deploy/README.md b/java-deploy/README.md index ed8c47c7fdb1..3a053961082f 100644 --- a/java-deploy/README.md +++ b/java-deploy/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-deploy - 1.100.0 + 1.101.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-deploy' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-deploy:1.100.0' +implementation 'com.google.cloud:google-cloud-deploy:1.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-deploy" % "1.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-deploy" % "1.101.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-deploy/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-deploy.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-deploy/1.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-deploy/1.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-designcenter/README.md b/java-designcenter/README.md index f534aca4f202..0cebecc83a49 100644 --- a/java-designcenter/README.md +++ b/java-designcenter/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-designcenter - 0.2.0 + 0.3.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-designcenter' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-designcenter:0.2.0' +implementation 'com.google.cloud:google-cloud-designcenter:0.3.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-designcenter" % "0.2.0" +libraryDependencies += "com.google.cloud" % "google-cloud-designcenter" % "0.3.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-designcenter/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-designcenter.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-designcenter/0.2.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-designcenter/0.3.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-developerconnect/README.md b/java-developerconnect/README.md index d27555e83784..77dca94e6931 100644 --- a/java-developerconnect/README.md +++ b/java-developerconnect/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-developerconnect - 0.59.0 + 0.60.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-developerconnect' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-developerconnect:0.59.0' +implementation 'com.google.cloud:google-cloud-developerconnect:0.60.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-developerconnect" % "0.59.0" +libraryDependencies += "com.google.cloud" % "google-cloud-developerconnect" % "0.60.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-developerconnect/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-developerconnect.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-developerconnect/0.59.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-developerconnect/0.60.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-developerknowledge/README.md b/java-developerknowledge/README.md index e3d82c6f7b86..4e0398e36377 100644 --- a/java-developerknowledge/README.md +++ b/java-developerknowledge/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-developer-knowledge - 0.10.0 + 0.11.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-developer-knowledge' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-developer-knowledge:0.10.0' +implementation 'com.google.cloud:google-cloud-developer-knowledge:0.11.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-developer-knowledge" % "0.10.0" +libraryDependencies += "com.google.cloud" % "google-cloud-developer-knowledge" % "0.11.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-developer-knowledge/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-developer-knowledge.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-developer-knowledge/0.10.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-developer-knowledge/0.11.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-devicestreaming/README.md b/java-devicestreaming/README.md index 594f0178477d..fd4fce339c41 100644 --- a/java-devicestreaming/README.md +++ b/java-devicestreaming/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-devicestreaming - 0.42.0 + 0.43.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-devicestreaming' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-devicestreaming:0.42.0' +implementation 'com.google.cloud:google-cloud-devicestreaming:0.43.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-devicestreaming" % "0.42.0" +libraryDependencies += "com.google.cloud" % "google-cloud-devicestreaming" % "0.43.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-devicestreaming/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-devicestreaming.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-devicestreaming/0.42.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-devicestreaming/0.43.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-dialogflow-cx/README.md b/java-dialogflow-cx/README.md index 9a3231552394..611c7fad8fca 100644 --- a/java-dialogflow-cx/README.md +++ b/java-dialogflow-cx/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-dialogflow-cx - 0.113.0 + 0.114.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-dialogflow-cx' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-dialogflow-cx:0.113.0' +implementation 'com.google.cloud:google-cloud-dialogflow-cx:0.114.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-dialogflow-cx" % "0.113.0" +libraryDependencies += "com.google.cloud" % "google-cloud-dialogflow-cx" % "0.114.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-dialogflow-cx/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-dialogflow-cx.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dialogflow-cx/0.113.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dialogflow-cx/0.114.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-dialogflow/README.md b/java-dialogflow/README.md index 8818ee7fe13b..9572589d43fa 100644 --- a/java-dialogflow/README.md +++ b/java-dialogflow/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-dialogflow - 4.108.0 + 4.109.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-dialogflow' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-dialogflow:4.108.0' +implementation 'com.google.cloud:google-cloud-dialogflow:4.109.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-dialogflow" % "4.108.0" +libraryDependencies += "com.google.cloud" % "google-cloud-dialogflow" % "4.109.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-dialogflow/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-dialogflow.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dialogflow/4.108.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dialogflow/4.109.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-discoveryengine/README.md b/java-discoveryengine/README.md index 1f347902444b..82bed1574bc8 100644 --- a/java-discoveryengine/README.md +++ b/java-discoveryengine/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-discoveryengine - 0.98.0 + 0.99.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-discoveryengine' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-discoveryengine:0.98.0' +implementation 'com.google.cloud:google-cloud-discoveryengine:0.99.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-discoveryengine" % "0.98.0" +libraryDependencies += "com.google.cloud" % "google-cloud-discoveryengine" % "0.99.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-discoveryengine/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-discoveryengine.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-discoveryengine/0.98.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-discoveryengine/0.99.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/ProjectServiceClient.java b/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/ProjectServiceClient.java index 480d2b71a4ee..17f8d3cb472d 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/ProjectServiceClient.java +++ b/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/ProjectServiceClient.java @@ -303,6 +303,8 @@ public final OperationFuture provisionProject * .setAcceptDataUseTerms(true) * .setDataUseTermsVersion("dataUseTermsVersion-1913570450") * .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + * .setIdpConfig(IdpConfig.newBuilder().build()) + * .setPreProvisionMode(true) * .build(); * Project response = projectServiceClient.provisionProjectAsync(request).get(); * } @@ -339,6 +341,8 @@ public final OperationFuture provisionProject * .setAcceptDataUseTerms(true) * .setDataUseTermsVersion("dataUseTermsVersion-1913570450") * .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + * .setIdpConfig(IdpConfig.newBuilder().build()) + * .setPreProvisionMode(true) * .build(); * OperationFuture future = * projectServiceClient.provisionProjectOperationCallable().futureCall(request); @@ -375,6 +379,8 @@ public final OperationFuture provisionProject * .setAcceptDataUseTerms(true) * .setDataUseTermsVersion("dataUseTermsVersion-1913570450") * .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + * .setIdpConfig(IdpConfig.newBuilder().build()) + * .setPreProvisionMode(true) * .build(); * ApiFuture future = * projectServiceClient.provisionProjectCallable().futureCall(request); diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1beta/ProjectServiceClient.java b/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1beta/ProjectServiceClient.java index 9196ba76b750..d12e93513407 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1beta/ProjectServiceClient.java +++ b/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1beta/ProjectServiceClient.java @@ -304,6 +304,8 @@ public final OperationFuture provisionProject * .setAcceptDataUseTerms(true) * .setDataUseTermsVersion("dataUseTermsVersion-1913570450") * .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + * .setIdpConfig(IdpConfig.newBuilder().build()) + * .setPreProvisionMode(true) * .build(); * Project response = projectServiceClient.provisionProjectAsync(request).get(); * } @@ -340,6 +342,8 @@ public final OperationFuture provisionProject * .setAcceptDataUseTerms(true) * .setDataUseTermsVersion("dataUseTermsVersion-1913570450") * .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + * .setIdpConfig(IdpConfig.newBuilder().build()) + * .setPreProvisionMode(true) * .build(); * OperationFuture future = * projectServiceClient.provisionProjectOperationCallable().futureCall(request); @@ -376,6 +380,8 @@ public final OperationFuture provisionProject * .setAcceptDataUseTerms(true) * .setDataUseTermsVersion("dataUseTermsVersion-1913570450") * .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + * .setIdpConfig(IdpConfig.newBuilder().build()) + * .setPreProvisionMode(true) * .build(); * ApiFuture future = * projectServiceClient.provisionProjectCallable().futureCall(request); diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1beta/stub/HttpJsonProjectServiceStub.java b/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1beta/stub/HttpJsonProjectServiceStub.java index 30664ec1dd1f..f472517ddd61 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1beta/stub/HttpJsonProjectServiceStub.java +++ b/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1beta/stub/HttpJsonProjectServiceStub.java @@ -82,6 +82,7 @@ public class HttpJsonProjectServiceStub extends ProjectServiceStub { serializer.putPathParam(fields, "name", request.getName()); return fields; }) + .setAdditionalPaths("/v1beta/{name=projects/*/locations/*}:provision") .setQueryParamsExtractor( request -> { Map> fields = new HashMap<>(); diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1/reflect-config.json b/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1/reflect-config.json index ea828c56e486..e24195ab5c74 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1/reflect-config.json +++ b/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1/reflect-config.json @@ -8144,6 +8144,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.discoveryengine.v1.ProvisionProjectRequest$ProvisionIntent", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.discoveryengine.v1.ProvisionProjectRequest$SaasParams", "queryAllDeclaredConstructors": true, diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1beta/reflect-config.json b/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1beta/reflect-config.json index 02a94bb126a6..4dac05a79a23 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1beta/reflect-config.json +++ b/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1beta/reflect-config.json @@ -8171,6 +8171,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest$ProvisionIntent", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest$SaasParams", "queryAllDeclaredConstructors": true, diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProjectServiceProto.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProjectServiceProto.java index aa8d9e327df6..36fc572d4e25 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProjectServiceProto.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProjectServiceProto.java @@ -61,43 +61,49 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { static { java.lang.String[] descriptorData = { - "\n5google/cloud/discoveryengine/v1/projec" - + "t_service.proto\022\037google.cloud.discoverye" + "\n" + + "5google/cloud/discoveryengine/v1/project_service.proto\022\037google.cloud.discoverye" + "ngine.v1\032\034google/api/annotations.proto\032\027" + "google/api/client.proto\032\037google/api/fiel" + "d_behavior.proto\032\031google/api/resource.pr" - + "oto\032-google/cloud/discoveryengine/v1/pro" - + "ject.proto\032#google/longrunning/operation" - + "s.proto\"\305\002\n\027ProvisionProjectRequest\022=\n\004n" - + "ame\030\001 \001(\tB/\342A\001\002\372A(\n&discoveryengine.goog" - + "leapis.com/Project\022#\n\025accept_data_use_te" - + "rms\030\002 \001(\010B\004\342A\001\002\022$\n\026data_use_terms_versio" - + "n\030\003 \001(\tB\004\342A\001\002\022^\n\013saas_params\030\004 \001(\0132C.goo" - + "gle.cloud.discoveryengine.v1.ProvisionPr" - + "ojectRequest.SaasParamsB\004\342A\001\001\032@\n\nSaasPar" - + "ams\022\034\n\016accept_biz_qos\030\001 \001(\010B\004\342A\001\001\022\024\n\006is_" - + "biz\030\002 \001(\010B\004\342A\001\001\"\032\n\030ProvisionProjectMetad" - + "ata2\234\004\n\016ProjectService\022\267\002\n\020ProvisionProj" - + "ect\0228.google.cloud.discoveryengine.v1.Pr" - + "ovisionProjectRequest\032\035.google.longrunni" - + "ng.Operation\"\311\001\312Ac\n\'google.cloud.discove" - + "ryengine.v1.Project\0228google.cloud.discov" - + "eryengine.v1.ProvisionProjectMetadata\332A\004" - + "name\202\323\344\223\002V\"\037/v1/{name=projects/*}:provis" - + "ion:\001*Z0\"+/v1/{name=projects/*/locations" - + "/*}:provision:\001*\032\317\001\312A\036discoveryengine.go" - + "ogleapis.com\322A\252\001https://www.googleapis.c" - + "om/auth/cloud-platform,https://www.googl" - + "eapis.com/auth/discoveryengine.readwrite" - + ",https://www.googleapis.com/auth/discove" - + "ryengine.serving.readwriteB\206\002\n#com.googl" - + "e.cloud.discoveryengine.v1B\023ProjectServi" - + "ceProtoP\001ZMcloud.google.com/go/discovery" - + "engine/apiv1/discoveryenginepb;discovery" - + "enginepb\242\002\017DISCOVERYENGINE\252\002\037Google.Clou" - + "d.DiscoveryEngine.V1\312\002\037Google\\Cloud\\Disc" - + "overyEngine\\V1\352\002\"Google::Cloud::Discover" - + "yEngine::V1b\006proto3" + + "oto\032,google/cloud/discoveryengine/v1/common.proto\032-google/cloud/discoveryengine/" + + "v1/project.proto\032#google/longrunning/operations.proto\"\204\005\n" + + "\027ProvisionProjectRequest\022=\n" + + "\004name\030\001 \001(\tB/\342A\001\002\372A(\n" + + "&discoveryengine.googleapis.com/Project\022#\n" + + "\025accept_data_use_terms\030\002 \001(\010B\004\342A\001\002\022$\n" + + "\026data_use_terms_version\030\003 \001(\tB\004\342A\001\002\022^\n" + + "\013saas_params\030\004 \001(\013" + + "2C.google.cloud.discoveryengine.v1.ProvisionProjectRequest.SaasParamsB\004\342A\001\001\022h\n" + + "\020provision_intent\030\005 \001(\0162H.google.cloud.dis" + + "coveryengine.v1.ProvisionProjectRequest.ProvisionIntentB\004\342A\001\001\022D\n\n" + + "idp_config\030\006 \001(" + + "\0132*.google.cloud.discoveryengine.v1.IdpConfigB\004\342A\001\001\022 \n" + + "\022pre_provision_mode\030\010 \001(\010B\004\342A\001\001\032@\n\n" + + "SaasParams\022\034\n" + + "\016accept_biz_qos\030\001 \001(\010B\004\342A\001\001\022\024\n" + + "\006is_biz\030\002 \001(\010B\004\342A\001\001\"k\n" + + "\017ProvisionIntent\022 \n" + + "\034PROVISION_INTENT_UNSPECIFIED\020\000\022\031\n" + + "\025PROVISION_INTENT_SOBI\020\001\022\033\n" + + "\027PROVISION_INTENT_LEGACY\020\002\"\032\n" + + "\030ProvisionProjectMetadata2\234\004\n" + + "\016ProjectService\022\267\002\n" + + "\020ProvisionProject\0228.google.cloud.discoveryengine." + + "v1.ProvisionProjectRequest\032\035.google.longrunning.Operation\"\311\001\312Ac\n" + + "\'google.cloud.discoveryengine.v1.Project\0228google.cloud.d" + + "iscoveryengine.v1.ProvisionProjectMetada" + + "ta\332A\004name\202\323\344\223\002V\"\037/v1/{name=projects/*}:p" + + "rovision:\001*Z0\"+/v1/{name=projects/*/loca" + + "tions/*}:provision:\001*\032\317\001\312A\036discoveryengi" + + "ne.googleapis.com\322A\252\001https://www.googlea" + + "pis.com/auth/cloud-platform,https://www.googleapis.com/auth/discoveryengine.read" + + "write,https://www.googleapis.com/auth/discoveryengine.serving.readwriteB\206\002\n" + + "#com.google.cloud.discoveryengine.v1B\023Project" + + "ServiceProtoP\001ZMcloud.google.com/go/discoveryengine/apiv1/discoveryenginepb;disc" + + "overyenginepb\242\002\017DISCOVERYENGINE\252\002\037Google" + + ".Cloud.DiscoveryEngine.V1\312\002\037Google\\Cloud" + + "\\DiscoveryEngine\\V1\352\002\"Google::Cloud::DiscoveryEngine::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -107,6 +113,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.ClientProto.getDescriptor(), com.google.api.FieldBehaviorProto.getDescriptor(), com.google.api.ResourceProto.getDescriptor(), + com.google.cloud.discoveryengine.v1.CommonProto.getDescriptor(), com.google.cloud.discoveryengine.v1.ProjectProto.getDescriptor(), com.google.longrunning.OperationsProto.getDescriptor(), }); @@ -116,7 +123,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_discoveryengine_v1_ProvisionProjectRequest_descriptor, new java.lang.String[] { - "Name", "AcceptDataUseTerms", "DataUseTermsVersion", "SaasParams", + "Name", + "AcceptDataUseTerms", + "DataUseTermsVersion", + "SaasParams", + "ProvisionIntent", + "IdpConfig", + "PreProvisionMode", }); internal_static_google_cloud_discoveryengine_v1_ProvisionProjectRequest_SaasParams_descriptor = internal_static_google_cloud_discoveryengine_v1_ProvisionProjectRequest_descriptor @@ -138,6 +151,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.ClientProto.getDescriptor(); com.google.api.FieldBehaviorProto.getDescriptor(); com.google.api.ResourceProto.getDescriptor(); + com.google.cloud.discoveryengine.v1.CommonProto.getDescriptor(); com.google.cloud.discoveryengine.v1.ProjectProto.getDescriptor(); com.google.longrunning.OperationsProto.getDescriptor(); com.google.protobuf.ExtensionRegistry registry = diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProvisionProjectRequest.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProvisionProjectRequest.java index 7ff40d84fdf6..6fc76e54b832 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProvisionProjectRequest.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProvisionProjectRequest.java @@ -56,6 +56,7 @@ private ProvisionProjectRequest(com.google.protobuf.GeneratedMessage.Builder private ProvisionProjectRequest() { name_ = ""; dataUseTermsVersion_ = ""; + provisionIntent_ = 0; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -73,6 +74,181 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.Builder.class); } + /** + * + * + *
                      +   * Which experience the caller is provisioning.
                      +   * 
                      + * + * Protobuf enum {@code google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent} + */ + public enum ProvisionIntent implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                      +     * Unspecified.
                      +     * 
                      + * + * PROVISION_INTENT_UNSPECIFIED = 0; + */ + PROVISION_INTENT_UNSPECIFIED(0), + /** + * + * + *
                      +     * The caller is provisioning for the new Gemini Enterprise experience.
                      +     * 
                      + * + * PROVISION_INTENT_SOBI = 1; + */ + PROVISION_INTENT_SOBI(1), + /** + * + * + *
                      +     * The caller is provisioning for the classic Gemini Enterprise
                      +     * experience.
                      +     * 
                      + * + * PROVISION_INTENT_LEGACY = 2; + */ + PROVISION_INTENT_LEGACY(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ProvisionIntent"); + } + + /** + * + * + *
                      +     * Unspecified.
                      +     * 
                      + * + * PROVISION_INTENT_UNSPECIFIED = 0; + */ + public static final int PROVISION_INTENT_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                      +     * The caller is provisioning for the new Gemini Enterprise experience.
                      +     * 
                      + * + * PROVISION_INTENT_SOBI = 1; + */ + public static final int PROVISION_INTENT_SOBI_VALUE = 1; + + /** + * + * + *
                      +     * The caller is provisioning for the classic Gemini Enterprise
                      +     * experience.
                      +     * 
                      + * + * PROVISION_INTENT_LEGACY = 2; + */ + public static final int PROVISION_INTENT_LEGACY_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ProvisionIntent valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static ProvisionIntent forNumber(int value) { + switch (value) { + case 0: + return PROVISION_INTENT_UNSPECIFIED; + case 1: + return PROVISION_INTENT_SOBI; + case 2: + return PROVISION_INTENT_LEGACY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public ProvisionIntent findValueByNumber(int number) { + return ProvisionIntent.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final ProvisionIntent[] VALUES = values(); + + public static ProvisionIntent valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private ProvisionIntent(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent) + } + public interface SaasParamsOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1.ProvisionProjectRequest.SaasParams) @@ -922,6 +1098,148 @@ public com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.SaasParams ge : saasParams_; } + public static final int PROVISION_INTENT_FIELD_NUMBER = 5; + private int provisionIntent_ = 0; + + /** + * + * + *
                      +   * Optional. The caller states whether the provisioning is for the new or the
                      +   * classic Gemini Enterprise experience.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for provisionIntent. + */ + @java.lang.Override + public int getProvisionIntentValue() { + return provisionIntent_; + } + + /** + * + * + *
                      +   * Optional. The caller states whether the provisioning is for the new or the
                      +   * classic Gemini Enterprise experience.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The provisionIntent. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent + getProvisionIntent() { + com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent result = + com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent.forNumber( + provisionIntent_); + return result == null + ? com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent.UNRECOGNIZED + : result; + } + + public static final int IDP_CONFIG_FIELD_NUMBER = 6; + private com.google.cloud.discoveryengine.v1.IdpConfig idpConfig_; + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the idpConfig field is set. + */ + @java.lang.Override + public boolean hasIdpConfig() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The idpConfig. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1.IdpConfig getIdpConfig() { + return idpConfig_ == null + ? com.google.cloud.discoveryengine.v1.IdpConfig.getDefaultInstance() + : idpConfig_; + } + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1.IdpConfigOrBuilder getIdpConfigOrBuilder() { + return idpConfig_ == null + ? com.google.cloud.discoveryengine.v1.IdpConfig.getDefaultInstance() + : idpConfig_; + } + + public static final int PRE_PROVISION_MODE_FIELD_NUMBER = 8; + private boolean preProvisionMode_ = false; + + /** + * + * + *
                      +   * Optional. Runs only the common project-level pre-provisioning steps
                      +   * (service agents, agent identity pools, project-scoped extension bindings,
                      +   * App Hub registry, Sobi agent default identity, and Sobi default Model Armor
                      +   * template) without reading or writing the Customer, Collection, or UserStore
                      +   * tables, CapabilityConfig, tenant project, default engine, or trial licenses
                      +   * when `true`.
                      +   *
                      +   * Assumes no customer exists yet. Customer-level or non-SOBI fields
                      +   * (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`,
                      +   * `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with
                      +   * `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty
                      +   * response.
                      +   * 
                      + * + * bool pre_provision_mode = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The preProvisionMode. + */ + @java.lang.Override + public boolean getPreProvisionMode() { + return preProvisionMode_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -948,6 +1266,18 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(4, getSaasParams()); } + if (provisionIntent_ + != com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent + .PROVISION_INTENT_UNSPECIFIED + .getNumber()) { + output.writeEnum(5, provisionIntent_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(6, getIdpConfig()); + } + if (preProvisionMode_ != false) { + output.writeBool(8, preProvisionMode_); + } getUnknownFields().writeTo(output); } @@ -969,6 +1299,18 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getSaasParams()); } + if (provisionIntent_ + != com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent + .PROVISION_INTENT_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, provisionIntent_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getIdpConfig()); + } + if (preProvisionMode_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, preProvisionMode_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -992,6 +1334,12 @@ public boolean equals(final java.lang.Object obj) { if (hasSaasParams()) { if (!getSaasParams().equals(other.getSaasParams())) return false; } + if (provisionIntent_ != other.provisionIntent_) return false; + if (hasIdpConfig() != other.hasIdpConfig()) return false; + if (hasIdpConfig()) { + if (!getIdpConfig().equals(other.getIdpConfig())) return false; + } + if (getPreProvisionMode() != other.getPreProvisionMode()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1013,6 +1361,14 @@ public int hashCode() { hash = (37 * hash) + SAAS_PARAMS_FIELD_NUMBER; hash = (53 * hash) + getSaasParams().hashCode(); } + hash = (37 * hash) + PROVISION_INTENT_FIELD_NUMBER; + hash = (53 * hash) + provisionIntent_; + if (hasIdpConfig()) { + hash = (37 * hash) + IDP_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getIdpConfig().hashCode(); + } + hash = (37 * hash) + PRE_PROVISION_MODE_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getPreProvisionMode()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1158,6 +1514,7 @@ private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { internalGetSaasParamsFieldBuilder(); + internalGetIdpConfigFieldBuilder(); } } @@ -1173,6 +1530,13 @@ public Builder clear() { saasParamsBuilder_.dispose(); saasParamsBuilder_ = null; } + provisionIntent_ = 0; + idpConfig_ = null; + if (idpConfigBuilder_ != null) { + idpConfigBuilder_.dispose(); + idpConfigBuilder_ = null; + } + preProvisionMode_ = false; return this; } @@ -1223,6 +1587,16 @@ private void buildPartial0(com.google.cloud.discoveryengine.v1.ProvisionProjectR result.saasParams_ = saasParamsBuilder_ == null ? saasParams_ : saasParamsBuilder_.build(); to_bitField0_ |= 0x00000001; } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.provisionIntent_ = provisionIntent_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.idpConfig_ = idpConfigBuilder_ == null ? idpConfig_ : idpConfigBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.preProvisionMode_ = preProvisionMode_; + } result.bitField0_ |= to_bitField0_; } @@ -1255,6 +1629,15 @@ public Builder mergeFrom(com.google.cloud.discoveryengine.v1.ProvisionProjectReq if (other.hasSaasParams()) { mergeSaasParams(other.getSaasParams()); } + if (other.provisionIntent_ != 0) { + setProvisionIntentValue(other.getProvisionIntentValue()); + } + if (other.hasIdpConfig()) { + mergeIdpConfig(other.getIdpConfig()); + } + if (other.getPreProvisionMode() != false) { + setPreProvisionMode(other.getPreProvisionMode()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1306,6 +1689,25 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 34 + case 40: + { + provisionIntent_ = input.readEnum(); + bitField0_ |= 0x00000010; + break; + } // case 40 + case 50: + { + input.readMessage( + internalGetIdpConfigFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + case 64: + { + preProvisionMode_ = input.readBool(); + bitField0_ |= 0x00000040; + break; + } // case 64 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -1871,6 +2273,441 @@ public Builder clearSaasParams() { return saasParamsBuilder_; } + private int provisionIntent_ = 0; + + /** + * + * + *
                      +     * Optional. The caller states whether the provisioning is for the new or the
                      +     * classic Gemini Enterprise experience.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for provisionIntent. + */ + @java.lang.Override + public int getProvisionIntentValue() { + return provisionIntent_; + } + + /** + * + * + *
                      +     * Optional. The caller states whether the provisioning is for the new or the
                      +     * classic Gemini Enterprise experience.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for provisionIntent to set. + * @return This builder for chaining. + */ + public Builder setProvisionIntentValue(int value) { + provisionIntent_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The caller states whether the provisioning is for the new or the
                      +     * classic Gemini Enterprise experience.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The provisionIntent. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent + getProvisionIntent() { + com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent result = + com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent.forNumber( + provisionIntent_); + return result == null + ? com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent.UNRECOGNIZED + : result; + } + + /** + * + * + *
                      +     * Optional. The caller states whether the provisioning is for the new or the
                      +     * classic Gemini Enterprise experience.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The provisionIntent to set. + * @return This builder for chaining. + */ + public Builder setProvisionIntent( + com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000010; + provisionIntent_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The caller states whether the provisioning is for the new or the
                      +     * classic Gemini Enterprise experience.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearProvisionIntent() { + bitField0_ = (bitField0_ & ~0x00000010); + provisionIntent_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.discoveryengine.v1.IdpConfig idpConfig_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.discoveryengine.v1.IdpConfig, + com.google.cloud.discoveryengine.v1.IdpConfig.Builder, + com.google.cloud.discoveryengine.v1.IdpConfigOrBuilder> + idpConfigBuilder_; + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the idpConfig field is set. + */ + public boolean hasIdpConfig() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The idpConfig. + */ + public com.google.cloud.discoveryengine.v1.IdpConfig getIdpConfig() { + if (idpConfigBuilder_ == null) { + return idpConfig_ == null + ? com.google.cloud.discoveryengine.v1.IdpConfig.getDefaultInstance() + : idpConfig_; + } else { + return idpConfigBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setIdpConfig(com.google.cloud.discoveryengine.v1.IdpConfig value) { + if (idpConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + idpConfig_ = value; + } else { + idpConfigBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setIdpConfig( + com.google.cloud.discoveryengine.v1.IdpConfig.Builder builderForValue) { + if (idpConfigBuilder_ == null) { + idpConfig_ = builderForValue.build(); + } else { + idpConfigBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeIdpConfig(com.google.cloud.discoveryengine.v1.IdpConfig value) { + if (idpConfigBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && idpConfig_ != null + && idpConfig_ != com.google.cloud.discoveryengine.v1.IdpConfig.getDefaultInstance()) { + getIdpConfigBuilder().mergeFrom(value); + } else { + idpConfig_ = value; + } + } else { + idpConfigBuilder_.mergeFrom(value); + } + if (idpConfig_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearIdpConfig() { + bitField0_ = (bitField0_ & ~0x00000020); + idpConfig_ = null; + if (idpConfigBuilder_ != null) { + idpConfigBuilder_.dispose(); + idpConfigBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1.IdpConfig.Builder getIdpConfigBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetIdpConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1.IdpConfigOrBuilder getIdpConfigOrBuilder() { + if (idpConfigBuilder_ != null) { + return idpConfigBuilder_.getMessageOrBuilder(); + } else { + return idpConfig_ == null + ? com.google.cloud.discoveryengine.v1.IdpConfig.getDefaultInstance() + : idpConfig_; + } + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.discoveryengine.v1.IdpConfig, + com.google.cloud.discoveryengine.v1.IdpConfig.Builder, + com.google.cloud.discoveryengine.v1.IdpConfigOrBuilder> + internalGetIdpConfigFieldBuilder() { + if (idpConfigBuilder_ == null) { + idpConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.discoveryengine.v1.IdpConfig, + com.google.cloud.discoveryengine.v1.IdpConfig.Builder, + com.google.cloud.discoveryengine.v1.IdpConfigOrBuilder>( + getIdpConfig(), getParentForChildren(), isClean()); + idpConfig_ = null; + } + return idpConfigBuilder_; + } + + private boolean preProvisionMode_; + + /** + * + * + *
                      +     * Optional. Runs only the common project-level pre-provisioning steps
                      +     * (service agents, agent identity pools, project-scoped extension bindings,
                      +     * App Hub registry, Sobi agent default identity, and Sobi default Model Armor
                      +     * template) without reading or writing the Customer, Collection, or UserStore
                      +     * tables, CapabilityConfig, tenant project, default engine, or trial licenses
                      +     * when `true`.
                      +     *
                      +     * Assumes no customer exists yet. Customer-level or non-SOBI fields
                      +     * (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`,
                      +     * `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with
                      +     * `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty
                      +     * response.
                      +     * 
                      + * + * bool pre_provision_mode = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The preProvisionMode. + */ + @java.lang.Override + public boolean getPreProvisionMode() { + return preProvisionMode_; + } + + /** + * + * + *
                      +     * Optional. Runs only the common project-level pre-provisioning steps
                      +     * (service agents, agent identity pools, project-scoped extension bindings,
                      +     * App Hub registry, Sobi agent default identity, and Sobi default Model Armor
                      +     * template) without reading or writing the Customer, Collection, or UserStore
                      +     * tables, CapabilityConfig, tenant project, default engine, or trial licenses
                      +     * when `true`.
                      +     *
                      +     * Assumes no customer exists yet. Customer-level or non-SOBI fields
                      +     * (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`,
                      +     * `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with
                      +     * `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty
                      +     * response.
                      +     * 
                      + * + * bool pre_provision_mode = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The preProvisionMode to set. + * @return This builder for chaining. + */ + public Builder setPreProvisionMode(boolean value) { + + preProvisionMode_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Runs only the common project-level pre-provisioning steps
                      +     * (service agents, agent identity pools, project-scoped extension bindings,
                      +     * App Hub registry, Sobi agent default identity, and Sobi default Model Armor
                      +     * template) without reading or writing the Customer, Collection, or UserStore
                      +     * tables, CapabilityConfig, tenant project, default engine, or trial licenses
                      +     * when `true`.
                      +     *
                      +     * Assumes no customer exists yet. Customer-level or non-SOBI fields
                      +     * (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`,
                      +     * `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with
                      +     * `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty
                      +     * response.
                      +     * 
                      + * + * bool pre_provision_mode = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPreProvisionMode() { + bitField0_ = (bitField0_ & ~0x00000040); + preProvisionMode_ = false; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.discoveryengine.v1.ProvisionProjectRequest) } diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProvisionProjectRequestOrBuilder.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProvisionProjectRequestOrBuilder.java index dd3d7a45d60c..3193f168cdbc 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProvisionProjectRequestOrBuilder.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/ProvisionProjectRequestOrBuilder.java @@ -152,4 +152,109 @@ public interface ProvisionProjectRequestOrBuilder */ com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.SaasParamsOrBuilder getSaasParamsOrBuilder(); + + /** + * + * + *
                      +   * Optional. The caller states whether the provisioning is for the new or the
                      +   * classic Gemini Enterprise experience.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for provisionIntent. + */ + int getProvisionIntentValue(); + + /** + * + * + *
                      +   * Optional. The caller states whether the provisioning is for the new or the
                      +   * classic Gemini Enterprise experience.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The provisionIntent. + */ + com.google.cloud.discoveryengine.v1.ProvisionProjectRequest.ProvisionIntent getProvisionIntent(); + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the idpConfig field is set. + */ + boolean hasIdpConfig(); + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The idpConfig. + */ + com.google.cloud.discoveryengine.v1.IdpConfig getIdpConfig(); + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.discoveryengine.v1.IdpConfigOrBuilder getIdpConfigOrBuilder(); + + /** + * + * + *
                      +   * Optional. Runs only the common project-level pre-provisioning steps
                      +   * (service agents, agent identity pools, project-scoped extension bindings,
                      +   * App Hub registry, Sobi agent default identity, and Sobi default Model Armor
                      +   * template) without reading or writing the Customer, Collection, or UserStore
                      +   * tables, CapabilityConfig, tenant project, default engine, or trial licenses
                      +   * when `true`.
                      +   *
                      +   * Assumes no customer exists yet. Customer-level or non-SOBI fields
                      +   * (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`,
                      +   * `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with
                      +   * `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty
                      +   * response.
                      +   * 
                      + * + * bool pre_provision_mode = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The preProvisionMode. + */ + boolean getPreProvisionMode(); } diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/proto/google/cloud/discoveryengine/v1/project_service.proto b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/proto/google/cloud/discoveryengine/v1/project_service.proto index 20ded2ab3182..0302691651dd 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/proto/google/cloud/discoveryengine/v1/project_service.proto +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/proto/google/cloud/discoveryengine/v1/project_service.proto @@ -20,6 +20,7 @@ import "google/api/annotations.proto"; import "google/api/client.proto"; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; +import "google/cloud/discoveryengine/v1/common.proto"; import "google/cloud/discoveryengine/v1/project.proto"; import "google/longrunning/operations.proto"; @@ -81,6 +82,19 @@ message ProvisionProjectRequest { bool is_biz = 2 [(google.api.field_behavior) = OPTIONAL]; } + // Which experience the caller is provisioning. + enum ProvisionIntent { + // Unspecified. + PROVISION_INTENT_UNSPECIFIED = 0; + + // The caller is provisioning for the new Gemini Enterprise experience. + PROVISION_INTENT_SOBI = 1; + + // The caller is provisioning for the classic Gemini Enterprise + // experience. + PROVISION_INTENT_LEGACY = 2; + } + // Required. Full resource name of a // [Project][google.cloud.discoveryengine.v1.Project], such as // `projects/{project_id_or_number}`. @@ -105,6 +119,29 @@ message ProvisionProjectRequest { // Optional. Parameters for Agentspace. SaasParams saas_params = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The caller states whether the provisioning is for the new or the + // classic Gemini Enterprise experience. + ProvisionIntent provision_intent = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The identity provider for this location. When provided, the + // location's [AclConfig][google.cloud.discoveryengine.v1.AclConfig] is + // set from it as part of provisioning. + IdpConfig idp_config = 6 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Runs only the common project-level pre-provisioning steps + // (service agents, agent identity pools, project-scoped extension bindings, + // App Hub registry, Sobi agent default identity, and Sobi default Model Armor + // template) without reading or writing the Customer, Collection, or UserStore + // tables, CapabilityConfig, tenant project, default engine, or trial licenses + // when `true`. + // + // Assumes no customer exists yet. Customer-level or non-SOBI fields + // (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`, + // `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with + // `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty + // response. + bool pre_provision_mode = 8 [(google.api.field_behavior) = OPTIONAL]; } // Metadata associated with a project provision operation. diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/ProjectServiceProto.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/ProjectServiceProto.java index df34b2aa5528..dd7028004175 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/ProjectServiceProto.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/ProjectServiceProto.java @@ -61,39 +61,54 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { static { java.lang.String[] descriptorData = { - "\n" - + "9google/cloud/discoveryengine/v1beta/project_service.proto\022#google.cloud.discov" + "\n9google/cloud/discoveryengine/v1beta/pr" + + "oject_service.proto\022#google.cloud.discov" + "eryengine.v1beta\032\034google/api/annotations" + ".proto\032\027google/api/client.proto\032\037google/" + "api/field_behavior.proto\032\031google/api/res" - + "ource.proto\0321google/cloud/discoveryengin" - + "e/v1beta/project.proto\032#google/longrunning/operations.proto\"\311\002\n" - + "\027ProvisionProjectRequest\022=\n" - + "\004name\030\001 \001(\tB/\342A\001\002\372A(\n" - + "&discoveryengine.googleapis.com/Project\022#\n" - + "\025accept_data_use_terms\030\002 \001(\010B\004\342A\001\002\022$\n" - + "\026data_use_terms_version\030\003 \001(\tB\004\342A\001\002\022b\n" - + "\013saas_params\030\004 \001(\0132G.google.cloud.discoveryengine.v1" - + "beta.ProvisionProjectRequest.SaasParamsB\004\342A\001\001\032@\n\n" - + "SaasParams\022\034\n" - + "\016accept_biz_qos\030\001 \001(\010B\004\342A\001\001\022\024\n" - + "\006is_biz\030\002 \001(\010B\004\342A\001\001\"\032\n" - + "\030ProvisionProjectMetadata2\372\003\n" - + "\016ProjectService\022\225\002\n" - + "\020ProvisionProject\022<.google.cloud.disco" - + "veryengine.v1beta.ProvisionProjectRequest\032\035.google.longrunning.Operation\"\243\001\312Ak\n" - + "+google.cloud.discoveryengine.v1beta.Project\022 private ProvisionProjectRequest() { name_ = ""; dataUseTermsVersion_ = ""; + provisionIntent_ = 0; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -73,6 +74,182 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.Builder.class); } + /** + * + * + *
                      +   * Which experience the caller is provisioning.
                      +   * 
                      + * + * Protobuf enum {@code + * google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent} + */ + public enum ProvisionIntent implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                      +     * Unspecified.
                      +     * 
                      + * + * PROVISION_INTENT_UNSPECIFIED = 0; + */ + PROVISION_INTENT_UNSPECIFIED(0), + /** + * + * + *
                      +     * The caller is provisioning for the new Gemini Enterprise experience.
                      +     * 
                      + * + * PROVISION_INTENT_SOBI = 1; + */ + PROVISION_INTENT_SOBI(1), + /** + * + * + *
                      +     * The caller is provisioning for the classic Gemini Enterprise
                      +     * experience.
                      +     * 
                      + * + * PROVISION_INTENT_LEGACY = 2; + */ + PROVISION_INTENT_LEGACY(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ProvisionIntent"); + } + + /** + * + * + *
                      +     * Unspecified.
                      +     * 
                      + * + * PROVISION_INTENT_UNSPECIFIED = 0; + */ + public static final int PROVISION_INTENT_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                      +     * The caller is provisioning for the new Gemini Enterprise experience.
                      +     * 
                      + * + * PROVISION_INTENT_SOBI = 1; + */ + public static final int PROVISION_INTENT_SOBI_VALUE = 1; + + /** + * + * + *
                      +     * The caller is provisioning for the classic Gemini Enterprise
                      +     * experience.
                      +     * 
                      + * + * PROVISION_INTENT_LEGACY = 2; + */ + public static final int PROVISION_INTENT_LEGACY_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ProvisionIntent valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static ProvisionIntent forNumber(int value) { + switch (value) { + case 0: + return PROVISION_INTENT_UNSPECIFIED; + case 1: + return PROVISION_INTENT_SOBI; + case 2: + return PROVISION_INTENT_LEGACY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public ProvisionIntent findValueByNumber(int number) { + return ProvisionIntent.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final ProvisionIntent[] VALUES = values(); + + public static ProvisionIntent valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private ProvisionIntent(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent) + } + public interface SaasParamsOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.SaasParams) @@ -930,6 +1107,149 @@ public boolean hasSaasParams() { : saasParams_; } + public static final int PROVISION_INTENT_FIELD_NUMBER = 5; + private int provisionIntent_ = 0; + + /** + * + * + *
                      +   * Optional. The caller states whether the provisioning is for the new or the
                      +   * classic Gemini Enterprise experience.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for provisionIntent. + */ + @java.lang.Override + public int getProvisionIntentValue() { + return provisionIntent_; + } + + /** + * + * + *
                      +   * Optional. The caller states whether the provisioning is for the new or the
                      +   * classic Gemini Enterprise experience.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The provisionIntent. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent + getProvisionIntent() { + com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent result = + com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent.forNumber( + provisionIntent_); + return result == null + ? com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent + .UNRECOGNIZED + : result; + } + + public static final int IDP_CONFIG_FIELD_NUMBER = 6; + private com.google.cloud.discoveryengine.v1beta.IdpConfig idpConfig_; + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the idpConfig field is set. + */ + @java.lang.Override + public boolean hasIdpConfig() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The idpConfig. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.IdpConfig getIdpConfig() { + return idpConfig_ == null + ? com.google.cloud.discoveryengine.v1beta.IdpConfig.getDefaultInstance() + : idpConfig_; + } + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.IdpConfigOrBuilder getIdpConfigOrBuilder() { + return idpConfig_ == null + ? com.google.cloud.discoveryengine.v1beta.IdpConfig.getDefaultInstance() + : idpConfig_; + } + + public static final int PRE_PROVISION_MODE_FIELD_NUMBER = 8; + private boolean preProvisionMode_ = false; + + /** + * + * + *
                      +   * Optional. Runs only the common project-level pre-provisioning steps
                      +   * (service agents, agent identity pools, project-scoped extension bindings,
                      +   * App Hub registry, Sobi agent default identity, and Sobi default Model Armor
                      +   * template) without reading or writing the Customer, Collection, or UserStore
                      +   * tables, CapabilityConfig, tenant project, default engine, or trial licenses
                      +   * when `true`.
                      +   *
                      +   * Assumes no customer exists yet. Customer-level or non-SOBI fields
                      +   * (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`,
                      +   * `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with
                      +   * `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty
                      +   * response.
                      +   * 
                      + * + * bool pre_provision_mode = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The preProvisionMode. + */ + @java.lang.Override + public boolean getPreProvisionMode() { + return preProvisionMode_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -956,6 +1276,18 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(4, getSaasParams()); } + if (provisionIntent_ + != com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent + .PROVISION_INTENT_UNSPECIFIED + .getNumber()) { + output.writeEnum(5, provisionIntent_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(6, getIdpConfig()); + } + if (preProvisionMode_ != false) { + output.writeBool(8, preProvisionMode_); + } getUnknownFields().writeTo(output); } @@ -977,6 +1309,18 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getSaasParams()); } + if (provisionIntent_ + != com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent + .PROVISION_INTENT_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, provisionIntent_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getIdpConfig()); + } + if (preProvisionMode_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, preProvisionMode_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1000,6 +1344,12 @@ public boolean equals(final java.lang.Object obj) { if (hasSaasParams()) { if (!getSaasParams().equals(other.getSaasParams())) return false; } + if (provisionIntent_ != other.provisionIntent_) return false; + if (hasIdpConfig() != other.hasIdpConfig()) return false; + if (hasIdpConfig()) { + if (!getIdpConfig().equals(other.getIdpConfig())) return false; + } + if (getPreProvisionMode() != other.getPreProvisionMode()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1021,6 +1371,14 @@ public int hashCode() { hash = (37 * hash) + SAAS_PARAMS_FIELD_NUMBER; hash = (53 * hash) + getSaasParams().hashCode(); } + hash = (37 * hash) + PROVISION_INTENT_FIELD_NUMBER; + hash = (53 * hash) + provisionIntent_; + if (hasIdpConfig()) { + hash = (37 * hash) + IDP_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getIdpConfig().hashCode(); + } + hash = (37 * hash) + PRE_PROVISION_MODE_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getPreProvisionMode()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1166,6 +1524,7 @@ private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { internalGetSaasParamsFieldBuilder(); + internalGetIdpConfigFieldBuilder(); } } @@ -1181,6 +1540,13 @@ public Builder clear() { saasParamsBuilder_.dispose(); saasParamsBuilder_ = null; } + provisionIntent_ = 0; + idpConfig_ = null; + if (idpConfigBuilder_ != null) { + idpConfigBuilder_.dispose(); + idpConfigBuilder_ = null; + } + preProvisionMode_ = false; return this; } @@ -1233,6 +1599,16 @@ private void buildPartial0( result.saasParams_ = saasParamsBuilder_ == null ? saasParams_ : saasParamsBuilder_.build(); to_bitField0_ |= 0x00000001; } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.provisionIntent_ = provisionIntent_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.idpConfig_ = idpConfigBuilder_ == null ? idpConfig_ : idpConfigBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.preProvisionMode_ = preProvisionMode_; + } result.bitField0_ |= to_bitField0_; } @@ -1267,6 +1643,15 @@ public Builder mergeFrom( if (other.hasSaasParams()) { mergeSaasParams(other.getSaasParams()); } + if (other.provisionIntent_ != 0) { + setProvisionIntentValue(other.getProvisionIntentValue()); + } + if (other.hasIdpConfig()) { + mergeIdpConfig(other.getIdpConfig()); + } + if (other.getPreProvisionMode() != false) { + setPreProvisionMode(other.getPreProvisionMode()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1318,6 +1703,25 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 34 + case 40: + { + provisionIntent_ = input.readEnum(); + bitField0_ |= 0x00000010; + break; + } // case 40 + case 50: + { + input.readMessage( + internalGetIdpConfigFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + case 64: + { + preProvisionMode_ = input.readBool(); + bitField0_ |= 0x00000040; + break; + } // case 64 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -1884,6 +2288,443 @@ public Builder clearSaasParams() { return saasParamsBuilder_; } + private int provisionIntent_ = 0; + + /** + * + * + *
                      +     * Optional. The caller states whether the provisioning is for the new or the
                      +     * classic Gemini Enterprise experience.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for provisionIntent. + */ + @java.lang.Override + public int getProvisionIntentValue() { + return provisionIntent_; + } + + /** + * + * + *
                      +     * Optional. The caller states whether the provisioning is for the new or the
                      +     * classic Gemini Enterprise experience.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for provisionIntent to set. + * @return This builder for chaining. + */ + public Builder setProvisionIntentValue(int value) { + provisionIntent_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The caller states whether the provisioning is for the new or the
                      +     * classic Gemini Enterprise experience.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The provisionIntent. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent + getProvisionIntent() { + com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent result = + com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent.forNumber( + provisionIntent_); + return result == null + ? com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent + .UNRECOGNIZED + : result; + } + + /** + * + * + *
                      +     * Optional. The caller states whether the provisioning is for the new or the
                      +     * classic Gemini Enterprise experience.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The provisionIntent to set. + * @return This builder for chaining. + */ + public Builder setProvisionIntent( + com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000010; + provisionIntent_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The caller states whether the provisioning is for the new or the
                      +     * classic Gemini Enterprise experience.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearProvisionIntent() { + bitField0_ = (bitField0_ & ~0x00000010); + provisionIntent_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.discoveryengine.v1beta.IdpConfig idpConfig_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.discoveryengine.v1beta.IdpConfig, + com.google.cloud.discoveryengine.v1beta.IdpConfig.Builder, + com.google.cloud.discoveryengine.v1beta.IdpConfigOrBuilder> + idpConfigBuilder_; + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the idpConfig field is set. + */ + public boolean hasIdpConfig() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The idpConfig. + */ + public com.google.cloud.discoveryengine.v1beta.IdpConfig getIdpConfig() { + if (idpConfigBuilder_ == null) { + return idpConfig_ == null + ? com.google.cloud.discoveryengine.v1beta.IdpConfig.getDefaultInstance() + : idpConfig_; + } else { + return idpConfigBuilder_.getMessage(); + } + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setIdpConfig(com.google.cloud.discoveryengine.v1beta.IdpConfig value) { + if (idpConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + idpConfig_ = value; + } else { + idpConfigBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setIdpConfig( + com.google.cloud.discoveryengine.v1beta.IdpConfig.Builder builderForValue) { + if (idpConfigBuilder_ == null) { + idpConfig_ = builderForValue.build(); + } else { + idpConfigBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeIdpConfig(com.google.cloud.discoveryengine.v1beta.IdpConfig value) { + if (idpConfigBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && idpConfig_ != null + && idpConfig_ + != com.google.cloud.discoveryengine.v1beta.IdpConfig.getDefaultInstance()) { + getIdpConfigBuilder().mergeFrom(value); + } else { + idpConfig_ = value; + } + } else { + idpConfigBuilder_.mergeFrom(value); + } + if (idpConfig_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearIdpConfig() { + bitField0_ = (bitField0_ & ~0x00000020); + idpConfig_ = null; + if (idpConfigBuilder_ != null) { + idpConfigBuilder_.dispose(); + idpConfigBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1beta.IdpConfig.Builder getIdpConfigBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetIdpConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1beta.IdpConfigOrBuilder getIdpConfigOrBuilder() { + if (idpConfigBuilder_ != null) { + return idpConfigBuilder_.getMessageOrBuilder(); + } else { + return idpConfig_ == null + ? com.google.cloud.discoveryengine.v1beta.IdpConfig.getDefaultInstance() + : idpConfig_; + } + } + + /** + * + * + *
                      +     * Optional. The identity provider for this location. When provided, the
                      +     * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +     * set from it as part of provisioning.
                      +     * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.discoveryengine.v1beta.IdpConfig, + com.google.cloud.discoveryengine.v1beta.IdpConfig.Builder, + com.google.cloud.discoveryengine.v1beta.IdpConfigOrBuilder> + internalGetIdpConfigFieldBuilder() { + if (idpConfigBuilder_ == null) { + idpConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.discoveryengine.v1beta.IdpConfig, + com.google.cloud.discoveryengine.v1beta.IdpConfig.Builder, + com.google.cloud.discoveryengine.v1beta.IdpConfigOrBuilder>( + getIdpConfig(), getParentForChildren(), isClean()); + idpConfig_ = null; + } + return idpConfigBuilder_; + } + + private boolean preProvisionMode_; + + /** + * + * + *
                      +     * Optional. Runs only the common project-level pre-provisioning steps
                      +     * (service agents, agent identity pools, project-scoped extension bindings,
                      +     * App Hub registry, Sobi agent default identity, and Sobi default Model Armor
                      +     * template) without reading or writing the Customer, Collection, or UserStore
                      +     * tables, CapabilityConfig, tenant project, default engine, or trial licenses
                      +     * when `true`.
                      +     *
                      +     * Assumes no customer exists yet. Customer-level or non-SOBI fields
                      +     * (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`,
                      +     * `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with
                      +     * `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty
                      +     * response.
                      +     * 
                      + * + * bool pre_provision_mode = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The preProvisionMode. + */ + @java.lang.Override + public boolean getPreProvisionMode() { + return preProvisionMode_; + } + + /** + * + * + *
                      +     * Optional. Runs only the common project-level pre-provisioning steps
                      +     * (service agents, agent identity pools, project-scoped extension bindings,
                      +     * App Hub registry, Sobi agent default identity, and Sobi default Model Armor
                      +     * template) without reading or writing the Customer, Collection, or UserStore
                      +     * tables, CapabilityConfig, tenant project, default engine, or trial licenses
                      +     * when `true`.
                      +     *
                      +     * Assumes no customer exists yet. Customer-level or non-SOBI fields
                      +     * (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`,
                      +     * `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with
                      +     * `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty
                      +     * response.
                      +     * 
                      + * + * bool pre_provision_mode = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The preProvisionMode to set. + * @return This builder for chaining. + */ + public Builder setPreProvisionMode(boolean value) { + + preProvisionMode_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
                      +     * Optional. Runs only the common project-level pre-provisioning steps
                      +     * (service agents, agent identity pools, project-scoped extension bindings,
                      +     * App Hub registry, Sobi agent default identity, and Sobi default Model Armor
                      +     * template) without reading or writing the Customer, Collection, or UserStore
                      +     * tables, CapabilityConfig, tenant project, default engine, or trial licenses
                      +     * when `true`.
                      +     *
                      +     * Assumes no customer exists yet. Customer-level or non-SOBI fields
                      +     * (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`,
                      +     * `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with
                      +     * `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty
                      +     * response.
                      +     * 
                      + * + * bool pre_provision_mode = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPreProvisionMode() { + bitField0_ = (bitField0_ & ~0x00000040); + preProvisionMode_ = false; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.discoveryengine.v1beta.ProvisionProjectRequest) } diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/ProvisionProjectRequestOrBuilder.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/ProvisionProjectRequestOrBuilder.java index 8e97767fe992..16fb34797217 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/ProvisionProjectRequestOrBuilder.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/ProvisionProjectRequestOrBuilder.java @@ -152,4 +152,110 @@ public interface ProvisionProjectRequestOrBuilder */ com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.SaasParamsOrBuilder getSaasParamsOrBuilder(); + + /** + * + * + *
                      +   * Optional. The caller states whether the provisioning is for the new or the
                      +   * classic Gemini Enterprise experience.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for provisionIntent. + */ + int getProvisionIntentValue(); + + /** + * + * + *
                      +   * Optional. The caller states whether the provisioning is for the new or the
                      +   * classic Gemini Enterprise experience.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent provision_intent = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The provisionIntent. + */ + com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest.ProvisionIntent + getProvisionIntent(); + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the idpConfig field is set. + */ + boolean hasIdpConfig(); + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The idpConfig. + */ + com.google.cloud.discoveryengine.v1beta.IdpConfig getIdpConfig(); + + /** + * + * + *
                      +   * Optional. The identity provider for this location. When provided, the
                      +   * location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is
                      +   * set from it as part of provisioning.
                      +   * 
                      + * + * + * .google.cloud.discoveryengine.v1beta.IdpConfig idp_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.discoveryengine.v1beta.IdpConfigOrBuilder getIdpConfigOrBuilder(); + + /** + * + * + *
                      +   * Optional. Runs only the common project-level pre-provisioning steps
                      +   * (service agents, agent identity pools, project-scoped extension bindings,
                      +   * App Hub registry, Sobi agent default identity, and Sobi default Model Armor
                      +   * template) without reading or writing the Customer, Collection, or UserStore
                      +   * tables, CapabilityConfig, tenant project, default engine, or trial licenses
                      +   * when `true`.
                      +   *
                      +   * Assumes no customer exists yet. Customer-level or non-SOBI fields
                      +   * (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`,
                      +   * `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with
                      +   * `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty
                      +   * response.
                      +   * 
                      + * + * bool pre_provision_mode = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The preProvisionMode. + */ + boolean getPreProvisionMode(); } diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/proto/google/cloud/discoveryengine/v1beta/project_service.proto b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/proto/google/cloud/discoveryengine/v1beta/project_service.proto index 3a504a551fad..89f24f421dcb 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/proto/google/cloud/discoveryengine/v1beta/project_service.proto +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/proto/google/cloud/discoveryengine/v1beta/project_service.proto @@ -20,6 +20,7 @@ import "google/api/annotations.proto"; import "google/api/client.proto"; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; +import "google/cloud/discoveryengine/v1beta/common.proto"; import "google/cloud/discoveryengine/v1beta/project.proto"; import "google/longrunning/operations.proto"; @@ -52,6 +53,10 @@ service ProjectService { option (google.api.http) = { post: "/v1beta/{name=projects/*}:provision" body: "*" + additional_bindings { + post: "/v1beta/{name=projects/*/locations/*}:provision" + body: "*" + } }; option (google.api.method_signature) = "name"; option (google.longrunning.operation_info) = { @@ -77,6 +82,19 @@ message ProvisionProjectRequest { bool is_biz = 2 [(google.api.field_behavior) = OPTIONAL]; } + // Which experience the caller is provisioning. + enum ProvisionIntent { + // Unspecified. + PROVISION_INTENT_UNSPECIFIED = 0; + + // The caller is provisioning for the new Gemini Enterprise experience. + PROVISION_INTENT_SOBI = 1; + + // The caller is provisioning for the classic Gemini Enterprise + // experience. + PROVISION_INTENT_LEGACY = 2; + } + // Required. Full resource name of a // [Project][google.cloud.discoveryengine.v1beta.Project], such as // `projects/{project_id_or_number}`. @@ -101,6 +119,29 @@ message ProvisionProjectRequest { // Optional. Parameters for Agentspace. SaasParams saas_params = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The caller states whether the provisioning is for the new or the + // classic Gemini Enterprise experience. + ProvisionIntent provision_intent = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The identity provider for this location. When provided, the + // location's [AclConfig][google.cloud.discoveryengine.v1beta.AclConfig] is + // set from it as part of provisioning. + IdpConfig idp_config = 6 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Runs only the common project-level pre-provisioning steps + // (service agents, agent identity pools, project-scoped extension bindings, + // App Hub registry, Sobi agent default identity, and Sobi default Model Armor + // template) without reading or writing the Customer, Collection, or UserStore + // tables, CapabilityConfig, tenant project, default engine, or trial licenses + // when `true`. + // + // Assumes no customer exists yet. Customer-level or non-SOBI fields + // (`accept_data_use_terms`, `data_use_terms_version`, `saas_params`, + // `idp_config`, and `PROVISION_INTENT_LEGACY`) are rejected with + // `INVALID_ARGUMENT`, and the returned completed `Operation` has an empty + // response. + bool pre_provision_mode = 8 [(google.api.field_behavior) = OPTIONAL]; } // Metadata associated with a project provision operation. diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/AsyncProvisionProject.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/AsyncProvisionProject.java index 5565c063ddd3..6aa3e3d5b8f1 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/AsyncProvisionProject.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/AsyncProvisionProject.java @@ -18,6 +18,7 @@ // [START discoveryengine_v1_generated_ProjectService_ProvisionProject_async] import com.google.api.core.ApiFuture; +import com.google.cloud.discoveryengine.v1.IdpConfig; import com.google.cloud.discoveryengine.v1.ProjectName; import com.google.cloud.discoveryengine.v1.ProjectServiceClient; import com.google.cloud.discoveryengine.v1.ProvisionProjectRequest; @@ -42,6 +43,8 @@ public static void asyncProvisionProject() throws Exception { .setAcceptDataUseTerms(true) .setDataUseTermsVersion("dataUseTermsVersion-1913570450") .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + .setIdpConfig(IdpConfig.newBuilder().build()) + .setPreProvisionMode(true) .build(); ApiFuture future = projectServiceClient.provisionProjectCallable().futureCall(request); diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/AsyncProvisionProjectLRO.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/AsyncProvisionProjectLRO.java index 4a6bb2944220..296ed1d269a5 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/AsyncProvisionProjectLRO.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/AsyncProvisionProjectLRO.java @@ -18,6 +18,7 @@ // [START discoveryengine_v1_generated_ProjectService_ProvisionProject_LRO_async] import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.discoveryengine.v1.IdpConfig; import com.google.cloud.discoveryengine.v1.Project; import com.google.cloud.discoveryengine.v1.ProjectName; import com.google.cloud.discoveryengine.v1.ProjectServiceClient; @@ -43,6 +44,8 @@ public static void asyncProvisionProjectLRO() throws Exception { .setAcceptDataUseTerms(true) .setDataUseTermsVersion("dataUseTermsVersion-1913570450") .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + .setIdpConfig(IdpConfig.newBuilder().build()) + .setPreProvisionMode(true) .build(); OperationFuture future = projectServiceClient.provisionProjectOperationCallable().futureCall(request); diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/SyncProvisionProject.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/SyncProvisionProject.java index 467bdfa91692..12368948c285 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/SyncProvisionProject.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/projectservice/provisionproject/SyncProvisionProject.java @@ -17,6 +17,7 @@ package com.google.cloud.discoveryengine.v1.samples; // [START discoveryengine_v1_generated_ProjectService_ProvisionProject_sync] +import com.google.cloud.discoveryengine.v1.IdpConfig; import com.google.cloud.discoveryengine.v1.Project; import com.google.cloud.discoveryengine.v1.ProjectName; import com.google.cloud.discoveryengine.v1.ProjectServiceClient; @@ -41,6 +42,8 @@ public static void syncProvisionProject() throws Exception { .setAcceptDataUseTerms(true) .setDataUseTermsVersion("dataUseTermsVersion-1913570450") .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + .setIdpConfig(IdpConfig.newBuilder().build()) + .setPreProvisionMode(true) .build(); Project response = projectServiceClient.provisionProjectAsync(request).get(); } diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/AsyncProvisionProject.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/AsyncProvisionProject.java index 8d2dbc486fd6..ad2563ec10a2 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/AsyncProvisionProject.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/AsyncProvisionProject.java @@ -18,6 +18,7 @@ // [START discoveryengine_v1beta_generated_ProjectService_ProvisionProject_async] import com.google.api.core.ApiFuture; +import com.google.cloud.discoveryengine.v1beta.IdpConfig; import com.google.cloud.discoveryengine.v1beta.ProjectName; import com.google.cloud.discoveryengine.v1beta.ProjectServiceClient; import com.google.cloud.discoveryengine.v1beta.ProvisionProjectRequest; @@ -42,6 +43,8 @@ public static void asyncProvisionProject() throws Exception { .setAcceptDataUseTerms(true) .setDataUseTermsVersion("dataUseTermsVersion-1913570450") .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + .setIdpConfig(IdpConfig.newBuilder().build()) + .setPreProvisionMode(true) .build(); ApiFuture future = projectServiceClient.provisionProjectCallable().futureCall(request); diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/AsyncProvisionProjectLRO.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/AsyncProvisionProjectLRO.java index 289c6e39437d..62bc19754f9b 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/AsyncProvisionProjectLRO.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/AsyncProvisionProjectLRO.java @@ -18,6 +18,7 @@ // [START discoveryengine_v1beta_generated_ProjectService_ProvisionProject_LRO_async] import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.discoveryengine.v1beta.IdpConfig; import com.google.cloud.discoveryengine.v1beta.Project; import com.google.cloud.discoveryengine.v1beta.ProjectName; import com.google.cloud.discoveryengine.v1beta.ProjectServiceClient; @@ -43,6 +44,8 @@ public static void asyncProvisionProjectLRO() throws Exception { .setAcceptDataUseTerms(true) .setDataUseTermsVersion("dataUseTermsVersion-1913570450") .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + .setIdpConfig(IdpConfig.newBuilder().build()) + .setPreProvisionMode(true) .build(); OperationFuture future = projectServiceClient.provisionProjectOperationCallable().futureCall(request); diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/SyncProvisionProject.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/SyncProvisionProject.java index 59f70629eea0..b25de688a6f3 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/SyncProvisionProject.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1beta/projectservice/provisionproject/SyncProvisionProject.java @@ -17,6 +17,7 @@ package com.google.cloud.discoveryengine.v1beta.samples; // [START discoveryengine_v1beta_generated_ProjectService_ProvisionProject_sync] +import com.google.cloud.discoveryengine.v1beta.IdpConfig; import com.google.cloud.discoveryengine.v1beta.Project; import com.google.cloud.discoveryengine.v1beta.ProjectName; import com.google.cloud.discoveryengine.v1beta.ProjectServiceClient; @@ -41,6 +42,8 @@ public static void syncProvisionProject() throws Exception { .setAcceptDataUseTerms(true) .setDataUseTermsVersion("dataUseTermsVersion-1913570450") .setSaasParams(ProvisionProjectRequest.SaasParams.newBuilder().build()) + .setIdpConfig(IdpConfig.newBuilder().build()) + .setPreProvisionMode(true) .build(); Project response = projectServiceClient.provisionProjectAsync(request).get(); } diff --git a/java-distributedcloudedge/README.md b/java-distributedcloudedge/README.md index fc5e05c6023f..51fc92e7497a 100644 --- a/java-distributedcloudedge/README.md +++ b/java-distributedcloudedge/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-distributedcloudedge - 0.99.0 + 0.100.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-distributedcloudedge' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-distributedcloudedge:0.99.0' +implementation 'com.google.cloud:google-cloud-distributedcloudedge:0.100.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-distributedcloudedge" % "0.99.0" +libraryDependencies += "com.google.cloud" % "google-cloud-distributedcloudedge" % "0.100.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-distributedcloudedge/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-distributedcloudedge.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-distributedcloudedge/0.99.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-distributedcloudedge/0.100.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-dlp/README.md b/java-dlp/README.md index f796ec2ef6f8..7df0a92e3bb8 100644 --- a/java-dlp/README.md +++ b/java-dlp/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-dlp - 3.106.0 + 3.107.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-dlp' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-dlp:3.106.0' +implementation 'com.google.cloud:google-cloud-dlp:3.107.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-dlp" % "3.106.0" +libraryDependencies += "com.google.cloud" % "google-cloud-dlp" % "3.107.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-dlp/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-dlp.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dlp/3.106.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dlp/3.107.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-dms/README.md b/java-dms/README.md index b427ab582826..d816a7d7e71d 100644 --- a/java-dms/README.md +++ b/java-dms/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-dms - 2.101.0 + 2.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-dms' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-dms:2.101.0' +implementation 'com.google.cloud:google-cloud-dms:2.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-dms" % "2.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-dms" % "2.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-dms/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-dms.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dms/2.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-dms/2.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-document-ai/README.md b/java-document-ai/README.md index af98dcf50fda..a76699402330 100644 --- a/java-document-ai/README.md +++ b/java-document-ai/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-document-ai - 2.106.0 + 2.107.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-document-ai' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-document-ai:2.106.0' +implementation 'com.google.cloud:google-cloud-document-ai:2.107.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-document-ai" % "2.106.0" +libraryDependencies += "com.google.cloud" % "google-cloud-document-ai" % "2.107.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-document-ai/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-document-ai.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-document-ai/2.106.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-document-ai/2.107.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-domains/README.md b/java-domains/README.md index 34ee3f0f0f3a..2b90f4c5e502 100644 --- a/java-domains/README.md +++ b/java-domains/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-domains - 1.99.0 + 1.100.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-domains' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-domains:1.99.0' +implementation 'com.google.cloud:google-cloud-domains:1.100.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-domains" % "1.99.0" +libraryDependencies += "com.google.cloud" % "google-cloud-domains" % "1.100.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-domains/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-domains.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-domains/1.99.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-domains/1.100.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-edgenetwork/README.md b/java-edgenetwork/README.md index d4c7fc1addec..e81e054fb40d 100644 --- a/java-edgenetwork/README.md +++ b/java-edgenetwork/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-edgenetwork - 0.70.0 + 0.71.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-edgenetwork' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-edgenetwork:0.70.0' +implementation 'com.google.cloud:google-cloud-edgenetwork:0.71.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-edgenetwork" % "0.70.0" +libraryDependencies += "com.google.cloud" % "google-cloud-edgenetwork" % "0.71.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-edgenetwork/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-edgenetwork.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-edgenetwork/0.70.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-edgenetwork/0.71.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-enterpriseknowledgegraph/README.md b/java-enterpriseknowledgegraph/README.md index 71bd0b11bd19..d7009e631463 100644 --- a/java-enterpriseknowledgegraph/README.md +++ b/java-enterpriseknowledgegraph/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-enterpriseknowledgegraph - 0.98.0 + 0.99.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-enterpriseknowledgegraph' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-enterpriseknowledgegraph:0.98.0' +implementation 'com.google.cloud:google-cloud-enterpriseknowledgegraph:0.99.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-enterpriseknowledgegraph" % "0.98.0" +libraryDependencies += "com.google.cloud" % "google-cloud-enterpriseknowledgegraph" % "0.99.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-enterpriseknowledgegraph/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-enterpriseknowledgegraph.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-enterpriseknowledgegraph/0.98.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-enterpriseknowledgegraph/0.99.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-errorreporting/README.md b/java-errorreporting/README.md index 830beb5a7f20..e11e326b9d81 100644 --- a/java-errorreporting/README.md +++ b/java-errorreporting/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-errorreporting - 0.223.0-beta + 0.224.0-beta ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-errorreporting' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-errorreporting:0.223.0-beta' +implementation 'com.google.cloud:google-cloud-errorreporting:0.224.0-beta' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-errorreporting" % "0.223.0-beta" +libraryDependencies += "com.google.cloud" % "google-cloud-errorreporting" % "0.224.0-beta" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-errorreporting/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-errorreporting.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-errorreporting/0.223.0-beta +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-errorreporting/0.224.0-beta [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-essential-contacts/README.md b/java-essential-contacts/README.md index d1eab1111d07..91e58f84427d 100644 --- a/java-essential-contacts/README.md +++ b/java-essential-contacts/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-essential-contacts - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-essential-contacts' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-essential-contacts:2.102.0' +implementation 'com.google.cloud:google-cloud-essential-contacts:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-essential-contacts" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-essential-contacts" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-essential-contacts/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-essential-contacts.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-essential-contacts/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-essential-contacts/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-eventarc-publishing/README.md b/java-eventarc-publishing/README.md index 98f7be065fee..e2296aa9281e 100644 --- a/java-eventarc-publishing/README.md +++ b/java-eventarc-publishing/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-eventarc-publishing - 0.102.0 + 0.103.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-eventarc-publishing' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-eventarc-publishing:0.102.0' +implementation 'com.google.cloud:google-cloud-eventarc-publishing:0.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-eventarc-publishing" % "0.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-eventarc-publishing" % "0.103.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-eventarc-publishing/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-eventarc-publishing.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-eventarc-publishing/0.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-eventarc-publishing/0.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-eventarc/README.md b/java-eventarc/README.md index 5831c269a71f..74809abdd17e 100644 --- a/java-eventarc/README.md +++ b/java-eventarc/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-eventarc - 1.102.0 + 1.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-eventarc' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-eventarc:1.102.0' +implementation 'com.google.cloud:google-cloud-eventarc:1.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-eventarc" % "1.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-eventarc" % "1.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-eventarc/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-eventarc.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-eventarc/1.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-eventarc/1.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-filestore/README.md b/java-filestore/README.md index 8605aec43c76..a9d0181c746e 100644 --- a/java-filestore/README.md +++ b/java-filestore/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-filestore - 1.103.0 + 1.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-filestore' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-filestore:1.103.0' +implementation 'com.google.cloud:google-cloud-filestore:1.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-filestore" % "1.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-filestore" % "1.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-filestore/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-filestore.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-filestore/1.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-filestore/1.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-financialservices/README.md b/java-financialservices/README.md index 9c9f5656bdae..65e937f7c82d 100644 --- a/java-financialservices/README.md +++ b/java-financialservices/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-financialservices - 0.43.0 + 0.44.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-financialservices' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-financialservices:0.43.0' +implementation 'com.google.cloud:google-cloud-financialservices:0.44.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-financialservices" % "0.43.0" +libraryDependencies += "com.google.cloud" % "google-cloud-financialservices" % "0.44.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-financialservices/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-financialservices.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-financialservices/0.43.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-financialservices/0.44.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-firestore/README.md b/java-firestore/README.md index 5e2c944fd7f7..7c2d696def38 100644 --- a/java-firestore/README.md +++ b/java-firestore/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-firestore - 3.52.0 + 3.53.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-firestore' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-firestore:3.52.0' +implementation 'com.google.cloud:google-cloud-firestore:3.53.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-firestore" % "3.52.0" +libraryDependencies += "com.google.cloud" % "google-cloud-firestore" % "3.53.0" ``` ## Authentication @@ -197,7 +197,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-firestore/latest/history [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-firestore.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-firestore/3.52.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-firestore/3.53.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-ftp/README.md b/java-ftp/README.md index a912d2f890df..80e8a1c440ff 100644 --- a/java-ftp/README.md +++ b/java-ftp/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-ftp - 0.7.0 + 0.8.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-ftp' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-ftp:0.7.0' +implementation 'com.google.cloud:google-cloud-ftp:0.8.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-ftp" % "0.7.0" +libraryDependencies += "com.google.cloud" % "google-cloud-ftp" % "0.8.0" ``` ## Authentication @@ -187,7 +187,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-ftp/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-ftp.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-ftp/0.7.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-ftp/0.8.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-functions/README.md b/java-functions/README.md index d9167c6c1855..bc11854ae8ba 100644 --- a/java-functions/README.md +++ b/java-functions/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-functions - 2.104.0 + 2.105.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-functions' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-functions:2.104.0' +implementation 'com.google.cloud:google-cloud-functions:2.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-functions" % "2.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-functions" % "2.105.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-functions/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-functions.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-functions/2.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-functions/2.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-gdchardwaremanagement/README.md b/java-gdchardwaremanagement/README.md index a90ccfe13e17..43ce1c46fd7e 100644 --- a/java-gdchardwaremanagement/README.md +++ b/java-gdchardwaremanagement/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-gdchardwaremanagement - 0.57.0 + 0.58.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-gdchardwaremanagement' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-gdchardwaremanagement:0.57.0' +implementation 'com.google.cloud:google-cloud-gdchardwaremanagement:0.58.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-gdchardwaremanagement" % "0.57.0" +libraryDependencies += "com.google.cloud" % "google-cloud-gdchardwaremanagement" % "0.58.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-gdchardwaremanagement/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-gdchardwaremanagement.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gdchardwaremanagement/0.57.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gdchardwaremanagement/0.58.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-geminidataanalytics/README.md b/java-geminidataanalytics/README.md index 9f494c4623b7..7304e376c860 100644 --- a/java-geminidataanalytics/README.md +++ b/java-geminidataanalytics/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-geminidataanalytics - 0.30.0 + 0.31.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-geminidataanalytics' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-geminidataanalytics:0.30.0' +implementation 'com.google.cloud:google-cloud-geminidataanalytics:0.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-geminidataanalytics" % "0.30.0" +libraryDependencies += "com.google.cloud" % "google-cloud-geminidataanalytics" % "0.31.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-geminidataanalytics/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-geminidataanalytics.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-geminidataanalytics/0.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-geminidataanalytics/0.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-gke-backup/README.md b/java-gke-backup/README.md index 3c36240861cd..96982d258be6 100644 --- a/java-gke-backup/README.md +++ b/java-gke-backup/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-gke-backup - 0.101.0 + 0.102.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-gke-backup' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-gke-backup:0.101.0' +implementation 'com.google.cloud:google-cloud-gke-backup:0.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-gke-backup" % "0.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-gke-backup" % "0.102.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-gke-backup/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-gke-backup.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gke-backup/0.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gke-backup/0.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-gke-connect-gateway/README.md b/java-gke-connect-gateway/README.md index 394496df6e90..750b1b77d61b 100644 --- a/java-gke-connect-gateway/README.md +++ b/java-gke-connect-gateway/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-gke-connect-gateway - 0.103.0 + 0.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-gke-connect-gateway' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-gke-connect-gateway:0.103.0' +implementation 'com.google.cloud:google-cloud-gke-connect-gateway:0.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-gke-connect-gateway" % "0.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-gke-connect-gateway" % "0.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-gke-connect-gateway/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-gke-connect-gateway.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gke-connect-gateway/0.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gke-connect-gateway/0.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-gke-multi-cloud/README.md b/java-gke-multi-cloud/README.md index 2079d0039319..095ac831e4e3 100644 --- a/java-gke-multi-cloud/README.md +++ b/java-gke-multi-cloud/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-gke-multi-cloud - 0.101.0 + 0.102.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-gke-multi-cloud' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-gke-multi-cloud:0.101.0' +implementation 'com.google.cloud:google-cloud-gke-multi-cloud:0.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-gke-multi-cloud" % "0.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-gke-multi-cloud" % "0.102.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-gke-multi-cloud/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-gke-multi-cloud.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gke-multi-cloud/0.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gke-multi-cloud/0.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-gkehub/README.md b/java-gkehub/README.md index edee32b2009f..6e37ab3df0f8 100644 --- a/java-gkehub/README.md +++ b/java-gkehub/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-gkehub - 1.102.0 + 1.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-gkehub' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-gkehub:1.102.0' +implementation 'com.google.cloud:google-cloud-gkehub:1.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-gkehub" % "1.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-gkehub" % "1.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-gkehub/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-gkehub.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gkehub/1.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gkehub/1.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-gkerecommender/README.md b/java-gkerecommender/README.md index 0eeb951576cd..9a1b0e605378 100644 --- a/java-gkerecommender/README.md +++ b/java-gkerecommender/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-gkerecommender - 0.22.0 + 0.23.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-gkerecommender' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-gkerecommender:0.22.0' +implementation 'com.google.cloud:google-cloud-gkerecommender:0.23.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-gkerecommender" % "0.22.0" +libraryDependencies += "com.google.cloud" % "google-cloud-gkerecommender" % "0.23.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-gkerecommender/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-gkerecommender.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gkerecommender/0.22.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gkerecommender/0.23.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-grafeas/README.md b/java-grafeas/README.md index dab5e906e921..71fab33476e7 100644 --- a/java-grafeas/README.md +++ b/java-grafeas/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: io.grafeas grafeas - 2.103.0 + 2.104.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'io.grafeas:grafeas:2.103.0' +implementation 'io.grafeas:grafeas:2.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "io.grafeas" % "grafeas" % "2.103.0" +libraryDependencies += "io.grafeas" % "grafeas" % "2.104.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/grafeas/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/io.grafeas/grafeas.svg -[maven-version-link]: https://central.sonatype.com/artifact/io.grafeas/grafeas/2.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/io.grafeas/grafeas/2.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-gsuite-addons/README.md b/java-gsuite-addons/README.md index a4273fce9e68..3bce8ff537d6 100644 --- a/java-gsuite-addons/README.md +++ b/java-gsuite-addons/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-gsuite-addons - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-gsuite-addons' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-gsuite-addons:2.102.0' +implementation 'com.google.cloud:google-cloud-gsuite-addons:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-gsuite-addons" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-gsuite-addons" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-gsuite-addons/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-gsuite-addons.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gsuite-addons/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-gsuite-addons/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClient.java b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClient.java index 83135068cb11..dce02fc71107 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClient.java +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClient.java @@ -28,6 +28,7 @@ import com.google.cloud.gsuiteaddons.v1.stub.GSuiteAddOnsStubSettings; import com.google.common.util.concurrent.MoreExecutors; import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; import java.io.IOException; import java.util.List; import java.util.concurrent.TimeUnit; @@ -37,28 +38,7 @@ // AUTO-GENERATED DOCUMENTATION AND CLASS. /** - * Service Description: A service for managing Google Workspace add-ons deployments. - * - *

                      A Google Workspace add-on is a third-party embedded component that can be installed in Google - * Workspace Applications like Gmail, Calendar, Drive, and the Google Docs, Sheets, and Slides - * editors. Google Workspace add-ons can display UI cards, receive contextual information from the - * host application, and perform actions in the host application (See: - * https://developers.google.com/gsuite/add-ons/overview for more information). - * - *

                      A Google Workspace add-on deployment resource specifies metadata about the add-on, including a - * specification of the entry points in the host application that trigger add-on executions (see: - * https://developers.google.com/gsuite/add-ons/concepts/gsuite-manifests). Add-on deployments - * defined via the Google Workspace add-ons API define their entrypoints using HTTPS URLs (See: - * https://developers.google.com/gsuite/add-ons/guides/alternate-runtimes), - * - *

                      A Google Workspace add-on deployment can be installed in developer mode, which allows an - * add-on developer to test the experience an end-user would see when installing and running the - * add-on in their G Suite applications. When running in developer mode, more detailed error - * messages are exposed in the add-on UI to aid in debugging. - * - *

                      A Google Workspace add-on deployment can be published to Google Workspace Marketplace, which - * allows other Google Workspace users to discover and install the add-on. See: - * https://developers.google.com/gsuite/add-ons/how-tos/publish-add-on-overview for details. + * Service Description: A service for managing Google Workspace add-ons. * *

                      This class provides the ability to make remote calls to the backing service through method * calls that map to API methods. Sample code to get started: @@ -256,6 +236,45 @@ *

                    * * + * + *

                    GetChatAppConfig + *

                    Gets the Chat app configuration of a project. Only Chat apps built as Google Workspace add-ons are supported. Each Google Cloud project has exactly one Chat app configuration. + *

                    Requires authenticating and authorizing with user credentials and the `gsuiteaddons.chatAppConfigs.get` and `chat.bots.get` IAM permissions on the project. + * + *

                    Request object method variants only take one parameter, a request object, which must be constructed before the call.

                    + *
                      + *
                    • getChatAppConfig(GetChatAppConfigRequest request) + *

                    + *

                    "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

                    + *
                      + *
                    • getChatAppConfig(ChatAppConfigName name) + *

                    • getChatAppConfig(String name) + *

                    + *

                    Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

                    + *
                      + *
                    • getChatAppConfigCallable() + *

                    + * + * + * + *

                    UpdateChatAppConfig + *

                    Updates the Chat app configuration of a project. Only Chat apps built as Google Workspace add-ons are supported. Each Google Cloud project has exactly one Chat app configuration. + *

                    Requires authenticating and authorizing with user credentials and the `gsuiteaddons.chatAppConfigs.update`, `chat.bots.update` and `chat.bots.get` IAM permissions on the project. + * + *

                    Request object method variants only take one parameter, a request object, which must be constructed before the call.

                    + *
                      + *
                    • updateChatAppConfig(UpdateChatAppConfigRequest request) + *

                    + *

                    "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

                    + *
                      + *
                    • updateChatAppConfig(ChatAppConfig chatAppConfig, FieldMask updateMask) + *

                    + *

                    Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

                    + *
                      + *
                    • updateChatAppConfigCallable() + *

                    + * + * * * *

                    See the individual methods for example code. @@ -1425,6 +1444,244 @@ public final UnaryCallable getInstallSta return stub.getInstallStatusCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the Chat app configuration of a project. Only Chat apps built as Google Workspace add-ons + * are supported. Each Google Cloud project has exactly one Chat app configuration. + * + *

                    Requires authenticating and authorizing with user credentials and the + * `gsuiteaddons.chatAppConfigs.get` and `chat.bots.get` IAM permissions on the project. + * + *

                    Sample code: + * + *

                    {@code
                    +   * // This snippet has been automatically generated and should be regarded as a code template only.
                    +   * // It will require modifications to work:
                    +   * // - It may require correct/in-range values for request initialization.
                    +   * // - It may require specifying regional endpoints when creating the service client as shown in
                    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                    +   * try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) {
                    +   *   ChatAppConfigName name = ChatAppConfigName.of("[PROJECT]");
                    +   *   ChatAppConfig response = gSuiteAddOnsClient.getChatAppConfig(name);
                    +   * }
                    +   * }
                    + * + * @param name Required. Resource name of the Chat app configuration. + *

                    Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google Cloud + * project number. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ChatAppConfig getChatAppConfig(@Nullable ChatAppConfigName name) { + GetChatAppConfigRequest request = + GetChatAppConfigRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getChatAppConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the Chat app configuration of a project. Only Chat apps built as Google Workspace add-ons + * are supported. Each Google Cloud project has exactly one Chat app configuration. + * + *

                    Requires authenticating and authorizing with user credentials and the + * `gsuiteaddons.chatAppConfigs.get` and `chat.bots.get` IAM permissions on the project. + * + *

                    Sample code: + * + *

                    {@code
                    +   * // This snippet has been automatically generated and should be regarded as a code template only.
                    +   * // It will require modifications to work:
                    +   * // - It may require correct/in-range values for request initialization.
                    +   * // - It may require specifying regional endpoints when creating the service client as shown in
                    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                    +   * try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) {
                    +   *   String name = ChatAppConfigName.of("[PROJECT]").toString();
                    +   *   ChatAppConfig response = gSuiteAddOnsClient.getChatAppConfig(name);
                    +   * }
                    +   * }
                    + * + * @param name Required. Resource name of the Chat app configuration. + *

                    Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google Cloud + * project number. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ChatAppConfig getChatAppConfig(String name) { + GetChatAppConfigRequest request = GetChatAppConfigRequest.newBuilder().setName(name).build(); + return getChatAppConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the Chat app configuration of a project. Only Chat apps built as Google Workspace add-ons + * are supported. Each Google Cloud project has exactly one Chat app configuration. + * + *

                    Requires authenticating and authorizing with user credentials and the + * `gsuiteaddons.chatAppConfigs.get` and `chat.bots.get` IAM permissions on the project. + * + *

                    Sample code: + * + *

                    {@code
                    +   * // This snippet has been automatically generated and should be regarded as a code template only.
                    +   * // It will require modifications to work:
                    +   * // - It may require correct/in-range values for request initialization.
                    +   * // - It may require specifying regional endpoints when creating the service client as shown in
                    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                    +   * try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) {
                    +   *   GetChatAppConfigRequest request =
                    +   *       GetChatAppConfigRequest.newBuilder()
                    +   *           .setName(ChatAppConfigName.of("[PROJECT]").toString())
                    +   *           .build();
                    +   *   ChatAppConfig response = gSuiteAddOnsClient.getChatAppConfig(request);
                    +   * }
                    +   * }
                    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ChatAppConfig getChatAppConfig(GetChatAppConfigRequest request) { + return getChatAppConfigCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the Chat app configuration of a project. Only Chat apps built as Google Workspace add-ons + * are supported. Each Google Cloud project has exactly one Chat app configuration. + * + *

                    Requires authenticating and authorizing with user credentials and the + * `gsuiteaddons.chatAppConfigs.get` and `chat.bots.get` IAM permissions on the project. + * + *

                    Sample code: + * + *

                    {@code
                    +   * // This snippet has been automatically generated and should be regarded as a code template only.
                    +   * // It will require modifications to work:
                    +   * // - It may require correct/in-range values for request initialization.
                    +   * // - It may require specifying regional endpoints when creating the service client as shown in
                    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                    +   * try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) {
                    +   *   GetChatAppConfigRequest request =
                    +   *       GetChatAppConfigRequest.newBuilder()
                    +   *           .setName(ChatAppConfigName.of("[PROJECT]").toString())
                    +   *           .build();
                    +   *   ApiFuture future =
                    +   *       gSuiteAddOnsClient.getChatAppConfigCallable().futureCall(request);
                    +   *   // Do something.
                    +   *   ChatAppConfig response = future.get();
                    +   * }
                    +   * }
                    + */ + public final UnaryCallable getChatAppConfigCallable() { + return stub.getChatAppConfigCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the Chat app configuration of a project. Only Chat apps built as Google Workspace + * add-ons are supported. Each Google Cloud project has exactly one Chat app configuration. + * + *

                    Requires authenticating and authorizing with user credentials and the + * `gsuiteaddons.chatAppConfigs.update`, `chat.bots.update` and `chat.bots.get` IAM permissions on + * the project. + * + *

                    Sample code: + * + *

                    {@code
                    +   * // This snippet has been automatically generated and should be regarded as a code template only.
                    +   * // It will require modifications to work:
                    +   * // - It may require correct/in-range values for request initialization.
                    +   * // - It may require specifying regional endpoints when creating the service client as shown in
                    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                    +   * try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) {
                    +   *   ChatAppConfig chatAppConfig = ChatAppConfig.newBuilder().build();
                    +   *   FieldMask updateMask = FieldMask.newBuilder().build();
                    +   *   ChatAppConfig response = gSuiteAddOnsClient.updateChatAppConfig(chatAppConfig, updateMask);
                    +   * }
                    +   * }
                    + * + * @param chatAppConfig Required. The app configuration to update. + * @param updateMask Optional. The list of fields to update. + *

                    If omitted, only the fields with non-empty values in the provided Chat app configuration + * are updated. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ChatAppConfig updateChatAppConfig( + ChatAppConfig chatAppConfig, FieldMask updateMask) { + UpdateChatAppConfigRequest request = + UpdateChatAppConfigRequest.newBuilder() + .setChatAppConfig(chatAppConfig) + .setUpdateMask(updateMask) + .build(); + return updateChatAppConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the Chat app configuration of a project. Only Chat apps built as Google Workspace + * add-ons are supported. Each Google Cloud project has exactly one Chat app configuration. + * + *

                    Requires authenticating and authorizing with user credentials and the + * `gsuiteaddons.chatAppConfigs.update`, `chat.bots.update` and `chat.bots.get` IAM permissions on + * the project. + * + *

                    Sample code: + * + *

                    {@code
                    +   * // This snippet has been automatically generated and should be regarded as a code template only.
                    +   * // It will require modifications to work:
                    +   * // - It may require correct/in-range values for request initialization.
                    +   * // - It may require specifying regional endpoints when creating the service client as shown in
                    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                    +   * try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) {
                    +   *   UpdateChatAppConfigRequest request =
                    +   *       UpdateChatAppConfigRequest.newBuilder()
                    +   *           .setChatAppConfig(ChatAppConfig.newBuilder().build())
                    +   *           .setUpdateMask(FieldMask.newBuilder().build())
                    +   *           .build();
                    +   *   ChatAppConfig response = gSuiteAddOnsClient.updateChatAppConfig(request);
                    +   * }
                    +   * }
                    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ChatAppConfig updateChatAppConfig(UpdateChatAppConfigRequest request) { + return updateChatAppConfigCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the Chat app configuration of a project. Only Chat apps built as Google Workspace + * add-ons are supported. Each Google Cloud project has exactly one Chat app configuration. + * + *

                    Requires authenticating and authorizing with user credentials and the + * `gsuiteaddons.chatAppConfigs.update`, `chat.bots.update` and `chat.bots.get` IAM permissions on + * the project. + * + *

                    Sample code: + * + *

                    {@code
                    +   * // This snippet has been automatically generated and should be regarded as a code template only.
                    +   * // It will require modifications to work:
                    +   * // - It may require correct/in-range values for request initialization.
                    +   * // - It may require specifying regional endpoints when creating the service client as shown in
                    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
                    +   * try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) {
                    +   *   UpdateChatAppConfigRequest request =
                    +   *       UpdateChatAppConfigRequest.newBuilder()
                    +   *           .setChatAppConfig(ChatAppConfig.newBuilder().build())
                    +   *           .setUpdateMask(FieldMask.newBuilder().build())
                    +   *           .build();
                    +   *   ApiFuture future =
                    +   *       gSuiteAddOnsClient.updateChatAppConfigCallable().futureCall(request);
                    +   *   // Do something.
                    +   *   ChatAppConfig response = future.get();
                    +   * }
                    +   * }
                    + */ + public final UnaryCallable + updateChatAppConfigCallable() { + return stub.updateChatAppConfigCallable(); + } + @Override public final void close() { stub.close(); diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsSettings.java b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsSettings.java index 49a3576a7a93..b8c084edbcc6 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsSettings.java +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsSettings.java @@ -138,6 +138,17 @@ public UnaryCallSettings getInstallStatu return ((GSuiteAddOnsStubSettings) getStubSettings()).getInstallStatusSettings(); } + /** Returns the object with the settings used for calls to getChatAppConfig. */ + public UnaryCallSettings getChatAppConfigSettings() { + return ((GSuiteAddOnsStubSettings) getStubSettings()).getChatAppConfigSettings(); + } + + /** Returns the object with the settings used for calls to updateChatAppConfig. */ + public UnaryCallSettings + updateChatAppConfigSettings() { + return ((GSuiteAddOnsStubSettings) getStubSettings()).updateChatAppConfigSettings(); + } + public static final GSuiteAddOnsSettings create(GSuiteAddOnsStubSettings stub) throws IOException { return new GSuiteAddOnsSettings.Builder(stub.toBuilder()).build(); @@ -302,6 +313,18 @@ public UnaryCallSettings.Builder installDeploym return getStubSettingsBuilder().getInstallStatusSettings(); } + /** Returns the builder for the settings used for calls to getChatAppConfig. */ + public UnaryCallSettings.Builder + getChatAppConfigSettings() { + return getStubSettingsBuilder().getChatAppConfigSettings(); + } + + /** Returns the builder for the settings used for calls to updateChatAppConfig. */ + public UnaryCallSettings.Builder + updateChatAppConfigSettings() { + return getStubSettingsBuilder().updateChatAppConfigSettings(); + } + @Override public GSuiteAddOnsSettings build() throws IOException { return new GSuiteAddOnsSettings(this); diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/gapic_metadata.json b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/gapic_metadata.json index e85874e1f11c..521b736ca2af 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/gapic_metadata.json +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/gapic_metadata.json @@ -19,6 +19,9 @@ "GetAuthorization": { "methods": ["getAuthorization", "getAuthorization", "getAuthorization", "getAuthorizationCallable"] }, + "GetChatAppConfig": { + "methods": ["getChatAppConfig", "getChatAppConfig", "getChatAppConfig", "getChatAppConfigCallable"] + }, "GetDeployment": { "methods": ["getDeployment", "getDeployment", "getDeployment", "getDeploymentCallable"] }, @@ -36,6 +39,9 @@ }, "UninstallDeployment": { "methods": ["uninstallDeployment", "uninstallDeployment", "uninstallDeployment", "uninstallDeploymentCallable"] + }, + "UpdateChatAppConfig": { + "methods": ["updateChatAppConfig", "updateChatAppConfig", "updateChatAppConfigCallable"] } } } diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/package-info.java b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/package-info.java index 31a3067b5360..5250529e7a9e 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/package-info.java +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/package-info.java @@ -21,28 +21,7 @@ * *

                    ======================= GSuiteAddOnsClient ======================= * - *

                    Service Description: A service for managing Google Workspace add-ons deployments. - * - *

                    A Google Workspace add-on is a third-party embedded component that can be installed in Google - * Workspace Applications like Gmail, Calendar, Drive, and the Google Docs, Sheets, and Slides - * editors. Google Workspace add-ons can display UI cards, receive contextual information from the - * host application, and perform actions in the host application (See: - * https://developers.google.com/gsuite/add-ons/overview for more information). - * - *

                    A Google Workspace add-on deployment resource specifies metadata about the add-on, including a - * specification of the entry points in the host application that trigger add-on executions (see: - * https://developers.google.com/gsuite/add-ons/concepts/gsuite-manifests). Add-on deployments - * defined via the Google Workspace add-ons API define their entrypoints using HTTPS URLs (See: - * https://developers.google.com/gsuite/add-ons/guides/alternate-runtimes), - * - *

                    A Google Workspace add-on deployment can be installed in developer mode, which allows an - * add-on developer to test the experience an end-user would see when installing and running the - * add-on in their G Suite applications. When running in developer mode, more detailed error - * messages are exposed in the add-on UI to aid in debugging. - * - *

                    A Google Workspace add-on deployment can be published to Google Workspace Marketplace, which - * allows other Google Workspace users to discover and install the add-on. See: - * https://developers.google.com/gsuite/add-ons/how-tos/publish-add-on-overview for details. + *

                    Service Description: A service for managing Google Workspace add-ons. * *

                    Sample for GSuiteAddOnsClient: * diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GSuiteAddOnsStub.java b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GSuiteAddOnsStub.java index dd8a6560dad2..35ea2f7efcba 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GSuiteAddOnsStub.java +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GSuiteAddOnsStub.java @@ -21,10 +21,12 @@ import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.gsuiteaddons.v1.Authorization; +import com.google.cloud.gsuiteaddons.v1.ChatAppConfig; import com.google.cloud.gsuiteaddons.v1.CreateDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.DeleteDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.Deployment; import com.google.cloud.gsuiteaddons.v1.GetAuthorizationRequest; +import com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest; import com.google.cloud.gsuiteaddons.v1.GetDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.GetInstallStatusRequest; import com.google.cloud.gsuiteaddons.v1.InstallDeploymentRequest; @@ -33,6 +35,7 @@ import com.google.cloud.gsuiteaddons.v1.ListDeploymentsResponse; import com.google.cloud.gsuiteaddons.v1.ReplaceDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.UninstallDeploymentRequest; +import com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest; import com.google.protobuf.Empty; import javax.annotation.Generated; import org.jspecify.annotations.NullMarked; @@ -88,6 +91,14 @@ public UnaryCallable getInstallStatusCal throw new UnsupportedOperationException("Not implemented: getInstallStatusCallable()"); } + public UnaryCallable getChatAppConfigCallable() { + throw new UnsupportedOperationException("Not implemented: getChatAppConfigCallable()"); + } + + public UnaryCallable updateChatAppConfigCallable() { + throw new UnsupportedOperationException("Not implemented: updateChatAppConfigCallable()"); + } + @Override public abstract void close(); } diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GSuiteAddOnsStubSettings.java b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GSuiteAddOnsStubSettings.java index 38f1705e8e33..3081f2f592e1 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GSuiteAddOnsStubSettings.java +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GSuiteAddOnsStubSettings.java @@ -46,10 +46,12 @@ import com.google.api.gax.rpc.UnaryCallSettings; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.gsuiteaddons.v1.Authorization; +import com.google.cloud.gsuiteaddons.v1.ChatAppConfig; import com.google.cloud.gsuiteaddons.v1.CreateDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.DeleteDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.Deployment; import com.google.cloud.gsuiteaddons.v1.GetAuthorizationRequest; +import com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest; import com.google.cloud.gsuiteaddons.v1.GetDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.GetInstallStatusRequest; import com.google.cloud.gsuiteaddons.v1.InstallDeploymentRequest; @@ -58,6 +60,7 @@ import com.google.cloud.gsuiteaddons.v1.ListDeploymentsResponse; import com.google.cloud.gsuiteaddons.v1.ReplaceDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.UninstallDeploymentRequest; +import com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest; import com.google.common.collect.ImmutableList; import com.google.common.collect.ImmutableMap; import com.google.common.collect.ImmutableSet; @@ -126,7 +129,10 @@ public class GSuiteAddOnsStubSettings extends StubSettings { /** The default scopes of the service. */ private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + ImmutableList.builder() + .add("https://www.googleapis.com/auth/cloud-platform") + .add("https://www.googleapis.com/auth/cloud-platform.read-only") + .build(); private final UnaryCallSettings getAuthorizationSettings; private final UnaryCallSettings createDeploymentSettings; @@ -139,6 +145,9 @@ public class GSuiteAddOnsStubSettings extends StubSettings installDeploymentSettings; private final UnaryCallSettings uninstallDeploymentSettings; private final UnaryCallSettings getInstallStatusSettings; + private final UnaryCallSettings getChatAppConfigSettings; + private final UnaryCallSettings + updateChatAppConfigSettings; private static final PagedListDescriptor< ListDeploymentsRequest, ListDeploymentsResponse, Deployment> @@ -241,6 +250,17 @@ public UnaryCallSettings getInstallStatu return getInstallStatusSettings; } + /** Returns the object with the settings used for calls to getChatAppConfig. */ + public UnaryCallSettings getChatAppConfigSettings() { + return getChatAppConfigSettings; + } + + /** Returns the object with the settings used for calls to updateChatAppConfig. */ + public UnaryCallSettings + updateChatAppConfigSettings() { + return updateChatAppConfigSettings; + } + public GSuiteAddOnsStub createStub() throws IOException { if (getTransportChannelProvider() .getTransportName() @@ -361,6 +381,8 @@ protected GSuiteAddOnsStubSettings(Builder settingsBuilder) throws IOException { installDeploymentSettings = settingsBuilder.installDeploymentSettings().build(); uninstallDeploymentSettings = settingsBuilder.uninstallDeploymentSettings().build(); getInstallStatusSettings = settingsBuilder.getInstallStatusSettings().build(); + getChatAppConfigSettings = settingsBuilder.getChatAppConfigSettings().build(); + updateChatAppConfigSettings = settingsBuilder.updateChatAppConfigSettings().build(); } @Override @@ -393,6 +415,10 @@ public static class Builder extends StubSettings.Builder getInstallStatusSettings; + private final UnaryCallSettings.Builder + getChatAppConfigSettings; + private final UnaryCallSettings.Builder + updateChatAppConfigSettings; private static final ImmutableMap> RETRYABLE_CODE_DEFINITIONS; @@ -462,6 +488,8 @@ protected Builder(@Nullable ClientContext clientContext) { installDeploymentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); uninstallDeploymentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); getInstallStatusSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + getChatAppConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateChatAppConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); unaryMethodSettingsBuilders = ImmutableList.>of( @@ -473,7 +501,9 @@ protected Builder(@Nullable ClientContext clientContext) { deleteDeploymentSettings, installDeploymentSettings, uninstallDeploymentSettings, - getInstallStatusSettings); + getInstallStatusSettings, + getChatAppConfigSettings, + updateChatAppConfigSettings); initDefaults(this); } @@ -489,6 +519,8 @@ protected Builder(GSuiteAddOnsStubSettings settings) { installDeploymentSettings = settings.installDeploymentSettings.toBuilder(); uninstallDeploymentSettings = settings.uninstallDeploymentSettings.toBuilder(); getInstallStatusSettings = settings.getInstallStatusSettings.toBuilder(); + getChatAppConfigSettings = settings.getChatAppConfigSettings.toBuilder(); + updateChatAppConfigSettings = settings.updateChatAppConfigSettings.toBuilder(); unaryMethodSettingsBuilders = ImmutableList.>of( @@ -500,7 +532,9 @@ protected Builder(GSuiteAddOnsStubSettings settings) { deleteDeploymentSettings, installDeploymentSettings, uninstallDeploymentSettings, - getInstallStatusSettings); + getInstallStatusSettings, + getChatAppConfigSettings, + updateChatAppConfigSettings); } private static Builder createDefault() { @@ -573,6 +607,16 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + builder + .getChatAppConfigSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .updateChatAppConfigSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + return builder; } @@ -643,6 +687,18 @@ public UnaryCallSettings.Builder installDeploym return getInstallStatusSettings; } + /** Returns the builder for the settings used for calls to getChatAppConfig. */ + public UnaryCallSettings.Builder + getChatAppConfigSettings() { + return getChatAppConfigSettings; + } + + /** Returns the builder for the settings used for calls to updateChatAppConfig. */ + public UnaryCallSettings.Builder + updateChatAppConfigSettings() { + return updateChatAppConfigSettings; + } + @Override public GSuiteAddOnsStubSettings build() throws IOException { return new GSuiteAddOnsStubSettings(this); diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GrpcGSuiteAddOnsStub.java b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GrpcGSuiteAddOnsStub.java index 1619a7cbca96..fabf6f7042fe 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GrpcGSuiteAddOnsStub.java +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/GrpcGSuiteAddOnsStub.java @@ -26,10 +26,12 @@ import com.google.api.gax.rpc.RequestParamsBuilder; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.gsuiteaddons.v1.Authorization; +import com.google.cloud.gsuiteaddons.v1.ChatAppConfig; import com.google.cloud.gsuiteaddons.v1.CreateDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.DeleteDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.Deployment; import com.google.cloud.gsuiteaddons.v1.GetAuthorizationRequest; +import com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest; import com.google.cloud.gsuiteaddons.v1.GetDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.GetInstallStatusRequest; import com.google.cloud.gsuiteaddons.v1.InstallDeploymentRequest; @@ -38,6 +40,7 @@ import com.google.cloud.gsuiteaddons.v1.ListDeploymentsResponse; import com.google.cloud.gsuiteaddons.v1.ReplaceDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.UninstallDeploymentRequest; +import com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest; import com.google.longrunning.stub.GrpcOperationsStub; import com.google.protobuf.Empty; import io.grpc.MethodDescriptor; @@ -156,6 +159,28 @@ public class GrpcGSuiteAddOnsStub extends GSuiteAddOnsStub { .setSampledToLocalTracing(true) .build(); + private static final MethodDescriptor + getChatAppConfigMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.gsuiteaddons.v1.GSuiteAddOns/GetChatAppConfig") + .setRequestMarshaller( + ProtoUtils.marshaller(GetChatAppConfigRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(ChatAppConfig.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + updateChatAppConfigMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.gsuiteaddons.v1.GSuiteAddOns/UpdateChatAppConfig") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateChatAppConfigRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(ChatAppConfig.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + private final UnaryCallable getAuthorizationCallable; private final UnaryCallable createDeploymentCallable; private final UnaryCallable replaceDeploymentCallable; @@ -168,6 +193,9 @@ public class GrpcGSuiteAddOnsStub extends GSuiteAddOnsStub { private final UnaryCallable installDeploymentCallable; private final UnaryCallable uninstallDeploymentCallable; private final UnaryCallable getInstallStatusCallable; + private final UnaryCallable getChatAppConfigCallable; + private final UnaryCallable + updateChatAppConfigCallable; private final BackgroundResource backgroundResources; private final GrpcOperationsStub operationsStub; @@ -310,6 +338,30 @@ protected GrpcGSuiteAddOnsStub( }) .setResourceNameExtractor(request -> request.getName()) .build(); + GrpcCallSettings getChatAppConfigTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getChatAppConfigMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + updateChatAppConfigTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateChatAppConfigMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add( + "chat_app_config.name", + String.valueOf(request.getChatAppConfig().getName())); + return builder.build(); + }) + .build(); this.getAuthorizationCallable = callableFactory.createUnaryCallable( @@ -347,6 +399,14 @@ protected GrpcGSuiteAddOnsStub( this.getInstallStatusCallable = callableFactory.createUnaryCallable( getInstallStatusTransportSettings, settings.getInstallStatusSettings(), clientContext); + this.getChatAppConfigCallable = + callableFactory.createUnaryCallable( + getChatAppConfigTransportSettings, settings.getChatAppConfigSettings(), clientContext); + this.updateChatAppConfigCallable = + callableFactory.createUnaryCallable( + updateChatAppConfigTransportSettings, + settings.updateChatAppConfigSettings(), + clientContext); this.backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); @@ -407,6 +467,16 @@ public UnaryCallable getInstallStatusCal return getInstallStatusCallable; } + @Override + public UnaryCallable getChatAppConfigCallable() { + return getChatAppConfigCallable; + } + + @Override + public UnaryCallable updateChatAppConfigCallable() { + return updateChatAppConfigCallable; + } + @Override public final void close() { try { diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/HttpJsonGSuiteAddOnsStub.java b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/HttpJsonGSuiteAddOnsStub.java index b4cf43188474..4dce73e2b1e6 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/HttpJsonGSuiteAddOnsStub.java +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/java/com/google/cloud/gsuiteaddons/v1/stub/HttpJsonGSuiteAddOnsStub.java @@ -31,10 +31,12 @@ import com.google.api.gax.rpc.RequestParamsBuilder; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.gsuiteaddons.v1.Authorization; +import com.google.cloud.gsuiteaddons.v1.ChatAppConfig; import com.google.cloud.gsuiteaddons.v1.CreateDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.DeleteDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.Deployment; import com.google.cloud.gsuiteaddons.v1.GetAuthorizationRequest; +import com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest; import com.google.cloud.gsuiteaddons.v1.GetDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.GetInstallStatusRequest; import com.google.cloud.gsuiteaddons.v1.InstallDeploymentRequest; @@ -43,6 +45,7 @@ import com.google.cloud.gsuiteaddons.v1.ListDeploymentsResponse; import com.google.cloud.gsuiteaddons.v1.ReplaceDeploymentRequest; import com.google.cloud.gsuiteaddons.v1.UninstallDeploymentRequest; +import com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest; import com.google.protobuf.Empty; import com.google.protobuf.TypeRegistry; import java.io.IOException; @@ -389,6 +392,80 @@ public class HttpJsonGSuiteAddOnsStub extends GSuiteAddOnsStub { .build()) .build(); + private static final ApiMethodDescriptor + getChatAppConfigMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.gsuiteaddons.v1.GSuiteAddOns/GetChatAppConfig") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/chatAppConfig}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "view", request.getViewValue()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ChatAppConfig.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + updateChatAppConfigMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.gsuiteaddons.v1.GSuiteAddOns/UpdateChatAppConfig") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{chatAppConfig.name=projects/*/chatAppConfig}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, "chatAppConfig.name", request.getChatAppConfig().getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("chatAppConfig", request.getChatAppConfig(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ChatAppConfig.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + private final UnaryCallable getAuthorizationCallable; private final UnaryCallable createDeploymentCallable; private final UnaryCallable replaceDeploymentCallable; @@ -401,6 +478,9 @@ public class HttpJsonGSuiteAddOnsStub extends GSuiteAddOnsStub { private final UnaryCallable installDeploymentCallable; private final UnaryCallable uninstallDeploymentCallable; private final UnaryCallable getInstallStatusCallable; + private final UnaryCallable getChatAppConfigCallable; + private final UnaryCallable + updateChatAppConfigCallable; private final BackgroundResource backgroundResources; private final HttpJsonStubCallableFactory callableFactory; @@ -552,6 +632,32 @@ protected HttpJsonGSuiteAddOnsStub( }) .setResourceNameExtractor(request -> request.getName()) .build(); + HttpJsonCallSettings getChatAppConfigTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getChatAppConfigMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings + updateChatAppConfigTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateChatAppConfigMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add( + "chat_app_config.name", + String.valueOf(request.getChatAppConfig().getName())); + return builder.build(); + }) + .build(); this.getAuthorizationCallable = callableFactory.createUnaryCallable( @@ -589,6 +695,14 @@ protected HttpJsonGSuiteAddOnsStub( this.getInstallStatusCallable = callableFactory.createUnaryCallable( getInstallStatusTransportSettings, settings.getInstallStatusSettings(), clientContext); + this.getChatAppConfigCallable = + callableFactory.createUnaryCallable( + getChatAppConfigTransportSettings, settings.getChatAppConfigSettings(), clientContext); + this.updateChatAppConfigCallable = + callableFactory.createUnaryCallable( + updateChatAppConfigTransportSettings, + settings.updateChatAppConfigSettings(), + clientContext); this.backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); @@ -606,6 +720,8 @@ public static List getMethodDescriptors() { methodDescriptors.add(installDeploymentMethodDescriptor); methodDescriptors.add(uninstallDeploymentMethodDescriptor); methodDescriptors.add(getInstallStatusMethodDescriptor); + methodDescriptors.add(getChatAppConfigMethodDescriptor); + methodDescriptors.add(updateChatAppConfigMethodDescriptor); return methodDescriptors; } @@ -660,6 +776,16 @@ public UnaryCallable getInstallStatusCal return getInstallStatusCallable; } + @Override + public UnaryCallable getChatAppConfigCallable() { + return getChatAppConfigCallable; + } + + @Override + public UnaryCallable updateChatAppConfigCallable() { + return updateChatAppConfigCallable; + } + @Override public final void close() { try { diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/resources/META-INF/native-image/com.google.cloud.gsuiteaddons.v1/reflect-config.json b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/resources/META-INF/native-image/com.google.cloud.gsuiteaddons.v1/reflect-config.json index e0dd2533eec9..af03de8c8dbd 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/main/resources/META-INF/native-image/com.google.cloud.gsuiteaddons.v1/reflect-config.json +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/main/resources/META-INF/native-image/com.google.cloud.gsuiteaddons.v1/reflect-config.json @@ -944,6 +944,69 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.gsuiteaddons.v1.AppCommand", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.AppCommand$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.AppCommand$CommandType", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.gsuiteaddons.v1.Authorization", "queryAllDeclaredConstructors": true, @@ -962,6 +1025,78 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.gsuiteaddons.v1.ChatAppConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.ChatAppConfig$AppState", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.ChatAppConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.ChatAppConfig$MarkupSyntax", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.ConnectionConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.ConnectionConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.gsuiteaddons.v1.CreateDeploymentRequest", "queryAllDeclaredConstructors": true, @@ -1016,6 +1151,33 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig$DialogflowEdition", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.gsuiteaddons.v1.GetAuthorizationRequest", "queryAllDeclaredConstructors": true, @@ -1034,6 +1196,33 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest$ChatAppConfigView", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.gsuiteaddons.v1.GetDeploymentRequest", "queryAllDeclaredConstructors": true, @@ -1070,6 +1259,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.gsuiteaddons.v1.InstallDeploymentRequest", "queryAllDeclaredConstructors": true, @@ -1106,6 +1331,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.gsuiteaddons.v1.ListDeploymentsRequest", "queryAllDeclaredConstructors": true, @@ -1178,6 +1421,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.UrlPattern", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.gsuiteaddons.v1.UrlPattern$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.protobuf.BoolValue", "queryAllDeclaredConstructors": true, @@ -2060,6 +2339,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.protobuf.FieldMask", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.protobuf.FieldMask$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.protobuf.FloatValue", "queryAllDeclaredConstructors": true, diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClientHttpJsonTest.java b/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClientHttpJsonTest.java index e495b1789838..ba643eaa1abc 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClientHttpJsonTest.java +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClientHttpJsonTest.java @@ -31,6 +31,7 @@ import com.google.common.collect.Lists; import com.google.protobuf.BoolValue; import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; import java.io.IOException; import java.util.ArrayList; import java.util.Arrays; @@ -854,4 +855,169 @@ public void getInstallStatusExceptionTest2() throws Exception { // Expected exception. } } + + @Test + public void getChatAppConfigTest() throws Exception { + ChatAppConfig expectedResponse = + ChatAppConfig.newBuilder() + .setName(ChatAppConfigName.of("[PROJECT]").toString()) + .setDisplayName("displayName1714148973") + .setAvatarUri("avatarUri-428646061") + .setDescription("description-1724546052") + .setInteractiveFeatureConfig(InteractiveFeatureConfig.newBuilder().build()) + .setErrorLoggingEnabled(true) + .build(); + mockService.addResponse(expectedResponse); + + ChatAppConfigName name = ChatAppConfigName.of("[PROJECT]"); + + ChatAppConfig actualResponse = client.getChatAppConfig(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getChatAppConfigExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + ChatAppConfigName name = ChatAppConfigName.of("[PROJECT]"); + client.getChatAppConfig(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getChatAppConfigTest2() throws Exception { + ChatAppConfig expectedResponse = + ChatAppConfig.newBuilder() + .setName(ChatAppConfigName.of("[PROJECT]").toString()) + .setDisplayName("displayName1714148973") + .setAvatarUri("avatarUri-428646061") + .setDescription("description-1724546052") + .setInteractiveFeatureConfig(InteractiveFeatureConfig.newBuilder().build()) + .setErrorLoggingEnabled(true) + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-5924/chatAppConfig"; + + ChatAppConfig actualResponse = client.getChatAppConfig(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getChatAppConfigExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-5924/chatAppConfig"; + client.getChatAppConfig(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateChatAppConfigTest() throws Exception { + ChatAppConfig expectedResponse = + ChatAppConfig.newBuilder() + .setName(ChatAppConfigName.of("[PROJECT]").toString()) + .setDisplayName("displayName1714148973") + .setAvatarUri("avatarUri-428646061") + .setDescription("description-1724546052") + .setInteractiveFeatureConfig(InteractiveFeatureConfig.newBuilder().build()) + .setErrorLoggingEnabled(true) + .build(); + mockService.addResponse(expectedResponse); + + ChatAppConfig chatAppConfig = + ChatAppConfig.newBuilder() + .setName(ChatAppConfigName.of("[PROJECT]").toString()) + .setDisplayName("displayName1714148973") + .setAvatarUri("avatarUri-428646061") + .setDescription("description-1724546052") + .setInteractiveFeatureConfig(InteractiveFeatureConfig.newBuilder().build()) + .setErrorLoggingEnabled(true) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + ChatAppConfig actualResponse = client.updateChatAppConfig(chatAppConfig, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void updateChatAppConfigExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + ChatAppConfig chatAppConfig = + ChatAppConfig.newBuilder() + .setName(ChatAppConfigName.of("[PROJECT]").toString()) + .setDisplayName("displayName1714148973") + .setAvatarUri("avatarUri-428646061") + .setDescription("description-1724546052") + .setInteractiveFeatureConfig(InteractiveFeatureConfig.newBuilder().build()) + .setErrorLoggingEnabled(true) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateChatAppConfig(chatAppConfig, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } } diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClientTest.java b/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClientTest.java index 2d62cc42fab0..7f3ecbab56bd 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClientTest.java +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsClientTest.java @@ -29,6 +29,7 @@ import com.google.protobuf.AbstractMessage; import com.google.protobuf.BoolValue; import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; import io.grpc.StatusRuntimeException; import java.io.IOException; import java.util.ArrayList; @@ -747,4 +748,136 @@ public void getInstallStatusExceptionTest2() throws Exception { // Expected exception. } } + + @Test + public void getChatAppConfigTest() throws Exception { + ChatAppConfig expectedResponse = + ChatAppConfig.newBuilder() + .setName(ChatAppConfigName.of("[PROJECT]").toString()) + .setDisplayName("displayName1714148973") + .setAvatarUri("avatarUri-428646061") + .setDescription("description-1724546052") + .setInteractiveFeatureConfig(InteractiveFeatureConfig.newBuilder().build()) + .setErrorLoggingEnabled(true) + .build(); + mockGSuiteAddOns.addResponse(expectedResponse); + + ChatAppConfigName name = ChatAppConfigName.of("[PROJECT]"); + + ChatAppConfig actualResponse = client.getChatAppConfig(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockGSuiteAddOns.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetChatAppConfigRequest actualRequest = ((GetChatAppConfigRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getChatAppConfigExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockGSuiteAddOns.addException(exception); + + try { + ChatAppConfigName name = ChatAppConfigName.of("[PROJECT]"); + client.getChatAppConfig(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getChatAppConfigTest2() throws Exception { + ChatAppConfig expectedResponse = + ChatAppConfig.newBuilder() + .setName(ChatAppConfigName.of("[PROJECT]").toString()) + .setDisplayName("displayName1714148973") + .setAvatarUri("avatarUri-428646061") + .setDescription("description-1724546052") + .setInteractiveFeatureConfig(InteractiveFeatureConfig.newBuilder().build()) + .setErrorLoggingEnabled(true) + .build(); + mockGSuiteAddOns.addResponse(expectedResponse); + + String name = "name3373707"; + + ChatAppConfig actualResponse = client.getChatAppConfig(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockGSuiteAddOns.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetChatAppConfigRequest actualRequest = ((GetChatAppConfigRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getChatAppConfigExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockGSuiteAddOns.addException(exception); + + try { + String name = "name3373707"; + client.getChatAppConfig(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateChatAppConfigTest() throws Exception { + ChatAppConfig expectedResponse = + ChatAppConfig.newBuilder() + .setName(ChatAppConfigName.of("[PROJECT]").toString()) + .setDisplayName("displayName1714148973") + .setAvatarUri("avatarUri-428646061") + .setDescription("description-1724546052") + .setInteractiveFeatureConfig(InteractiveFeatureConfig.newBuilder().build()) + .setErrorLoggingEnabled(true) + .build(); + mockGSuiteAddOns.addResponse(expectedResponse); + + ChatAppConfig chatAppConfig = ChatAppConfig.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + ChatAppConfig actualResponse = client.updateChatAppConfig(chatAppConfig, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockGSuiteAddOns.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateChatAppConfigRequest actualRequest = ((UpdateChatAppConfigRequest) actualRequests.get(0)); + + Assert.assertEquals(chatAppConfig, actualRequest.getChatAppConfig()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateChatAppConfigExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockGSuiteAddOns.addException(exception); + + try { + ChatAppConfig chatAppConfig = ChatAppConfig.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateChatAppConfig(chatAppConfig, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } } diff --git a/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/MockGSuiteAddOnsImpl.java b/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/MockGSuiteAddOnsImpl.java index 565b43f4e97f..3cd72ce02f3f 100644 --- a/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/MockGSuiteAddOnsImpl.java +++ b/java-gsuite-addons/google-cloud-gsuite-addons/src/test/java/com/google/cloud/gsuiteaddons/v1/MockGSuiteAddOnsImpl.java @@ -247,4 +247,46 @@ public void getInstallStatus( Exception.class.getName()))); } } + + @Override + public void getChatAppConfig( + GetChatAppConfigRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ChatAppConfig) { + requests.add(request); + responseObserver.onNext(((ChatAppConfig) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetChatAppConfig, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ChatAppConfig.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void updateChatAppConfig( + UpdateChatAppConfigRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ChatAppConfig) { + requests.add(request); + responseObserver.onNext(((ChatAppConfig) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method UpdateChatAppConfig, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ChatAppConfig.class.getName(), + Exception.class.getName()))); + } + } } diff --git a/java-gsuite-addons/grpc-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsGrpc.java b/java-gsuite-addons/grpc-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsGrpc.java index 611d73a02fc1..75776fd3b851 100644 --- a/java-gsuite-addons/grpc-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsGrpc.java +++ b/java-gsuite-addons/grpc-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsGrpc.java @@ -21,30 +21,7 @@ * * *

                    - * A service for managing Google Workspace add-ons deployments.
                    - * A Google Workspace add-on is a third-party embedded component that can be
                    - * installed in Google Workspace Applications like Gmail, Calendar, Drive, and
                    - * the Google Docs, Sheets, and Slides editors. Google Workspace add-ons can
                    - * display UI cards, receive contextual information from the host application,
                    - * and perform actions in the host application (See:
                    - * https://developers.google.com/gsuite/add-ons/overview for more information).
                    - * A Google Workspace add-on deployment resource specifies metadata about the
                    - * add-on, including a specification of the entry points in the host application
                    - * that trigger add-on executions (see:
                    - * https://developers.google.com/gsuite/add-ons/concepts/gsuite-manifests).
                    - * Add-on deployments defined via the Google Workspace add-ons API define their
                    - * entrypoints using HTTPS URLs (See:
                    - * https://developers.google.com/gsuite/add-ons/guides/alternate-runtimes),
                    - * A Google Workspace add-on deployment can be installed in developer mode,
                    - * which allows an add-on developer to test the experience an end-user would see
                    - * when installing and running the add-on in their G Suite applications.  When
                    - * running in developer mode, more detailed error messages are exposed in the
                    - * add-on UI to aid in debugging.
                    - * A Google Workspace add-on deployment can be published to Google Workspace
                    - * Marketplace, which allows other Google Workspace users to discover and
                    - * install the add-on.  See:
                    - * https://developers.google.com/gsuite/add-ons/how-tos/publish-add-on-overview
                    - * for details.
                    + * A service for managing Google Workspace add-ons.
                      * 
                    */ @io.grpc.stub.annotations.GrpcGenerated @@ -463,6 +440,100 @@ private GSuiteAddOnsGrpc() {} return getGetInstallStatusMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig> + getGetChatAppConfigMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetChatAppConfig", + requestType = com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.class, + responseType = com.google.cloud.gsuiteaddons.v1.ChatAppConfig.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig> + getGetChatAppConfigMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig> + getGetChatAppConfigMethod; + if ((getGetChatAppConfigMethod = GSuiteAddOnsGrpc.getGetChatAppConfigMethod) == null) { + synchronized (GSuiteAddOnsGrpc.class) { + if ((getGetChatAppConfigMethod = GSuiteAddOnsGrpc.getGetChatAppConfigMethod) == null) { + GSuiteAddOnsGrpc.getGetChatAppConfigMethod = + getGetChatAppConfigMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetChatAppConfig")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.getDefaultInstance())) + .setSchemaDescriptor( + new GSuiteAddOnsMethodDescriptorSupplier("GetChatAppConfig")) + .build(); + } + } + } + return getGetChatAppConfigMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig> + getUpdateChatAppConfigMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateChatAppConfig", + requestType = com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest.class, + responseType = com.google.cloud.gsuiteaddons.v1.ChatAppConfig.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig> + getUpdateChatAppConfigMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig> + getUpdateChatAppConfigMethod; + if ((getUpdateChatAppConfigMethod = GSuiteAddOnsGrpc.getUpdateChatAppConfigMethod) == null) { + synchronized (GSuiteAddOnsGrpc.class) { + if ((getUpdateChatAppConfigMethod = GSuiteAddOnsGrpc.getUpdateChatAppConfigMethod) + == null) { + GSuiteAddOnsGrpc.getUpdateChatAppConfigMethod = + getUpdateChatAppConfigMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "UpdateChatAppConfig")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.getDefaultInstance())) + .setSchemaDescriptor( + new GSuiteAddOnsMethodDescriptorSupplier("UpdateChatAppConfig")) + .build(); + } + } + } + return getUpdateChatAppConfigMethod; + } + /** Creates a new async stub that supports all call types for the service */ public static GSuiteAddOnsStub newStub(io.grpc.Channel channel) { io.grpc.stub.AbstractStub.StubFactory factory = @@ -521,30 +592,7 @@ public GSuiteAddOnsFutureStub newStub( * * *
                    -   * A service for managing Google Workspace add-ons deployments.
                    -   * A Google Workspace add-on is a third-party embedded component that can be
                    -   * installed in Google Workspace Applications like Gmail, Calendar, Drive, and
                    -   * the Google Docs, Sheets, and Slides editors. Google Workspace add-ons can
                    -   * display UI cards, receive contextual information from the host application,
                    -   * and perform actions in the host application (See:
                    -   * https://developers.google.com/gsuite/add-ons/overview for more information).
                    -   * A Google Workspace add-on deployment resource specifies metadata about the
                    -   * add-on, including a specification of the entry points in the host application
                    -   * that trigger add-on executions (see:
                    -   * https://developers.google.com/gsuite/add-ons/concepts/gsuite-manifests).
                    -   * Add-on deployments defined via the Google Workspace add-ons API define their
                    -   * entrypoints using HTTPS URLs (See:
                    -   * https://developers.google.com/gsuite/add-ons/guides/alternate-runtimes),
                    -   * A Google Workspace add-on deployment can be installed in developer mode,
                    -   * which allows an add-on developer to test the experience an end-user would see
                    -   * when installing and running the add-on in their G Suite applications.  When
                    -   * running in developer mode, more detailed error messages are exposed in the
                    -   * add-on UI to aid in debugging.
                    -   * A Google Workspace add-on deployment can be published to Google Workspace
                    -   * Marketplace, which allows other Google Workspace users to discover and
                    -   * install the add-on.  See:
                    -   * https://developers.google.com/gsuite/add-ons/how-tos/publish-add-on-overview
                    -   * for details.
                    +   * A service for managing Google Workspace add-ons.
                        * 
                    */ public interface AsyncService { @@ -681,36 +729,53 @@ default void getInstallStatus( io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( getGetInstallStatusMethod(), responseObserver); } + + /** + * + * + *
                    +     * Gets the Chat app configuration of a project. Only Chat apps built as
                    +     * Google Workspace add-ons are supported. Each Google Cloud project has
                    +     * exactly one Chat app configuration.
                    +     * Requires authenticating and authorizing with user credentials and the
                    +     * `gsuiteaddons.chatAppConfigs.get` and `chat.bots.get` IAM permissions on
                    +     * the project.
                    +     * 
                    + */ + default void getChatAppConfig( + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetChatAppConfigMethod(), responseObserver); + } + + /** + * + * + *
                    +     * Updates the Chat app configuration of a project. Only Chat apps built as
                    +     * Google Workspace add-ons are supported. Each Google Cloud project has
                    +     * exactly one Chat app configuration.
                    +     * Requires authenticating and authorizing with user credentials and the
                    +     * `gsuiteaddons.chatAppConfigs.update`, `chat.bots.update` and
                    +     * `chat.bots.get` IAM permissions on the project.
                    +     * 
                    + */ + default void updateChatAppConfig( + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateChatAppConfigMethod(), responseObserver); + } } /** * Base class for the server implementation of the service GSuiteAddOns. * *
                    -   * A service for managing Google Workspace add-ons deployments.
                    -   * A Google Workspace add-on is a third-party embedded component that can be
                    -   * installed in Google Workspace Applications like Gmail, Calendar, Drive, and
                    -   * the Google Docs, Sheets, and Slides editors. Google Workspace add-ons can
                    -   * display UI cards, receive contextual information from the host application,
                    -   * and perform actions in the host application (See:
                    -   * https://developers.google.com/gsuite/add-ons/overview for more information).
                    -   * A Google Workspace add-on deployment resource specifies metadata about the
                    -   * add-on, including a specification of the entry points in the host application
                    -   * that trigger add-on executions (see:
                    -   * https://developers.google.com/gsuite/add-ons/concepts/gsuite-manifests).
                    -   * Add-on deployments defined via the Google Workspace add-ons API define their
                    -   * entrypoints using HTTPS URLs (See:
                    -   * https://developers.google.com/gsuite/add-ons/guides/alternate-runtimes),
                    -   * A Google Workspace add-on deployment can be installed in developer mode,
                    -   * which allows an add-on developer to test the experience an end-user would see
                    -   * when installing and running the add-on in their G Suite applications.  When
                    -   * running in developer mode, more detailed error messages are exposed in the
                    -   * add-on UI to aid in debugging.
                    -   * A Google Workspace add-on deployment can be published to Google Workspace
                    -   * Marketplace, which allows other Google Workspace users to discover and
                    -   * install the add-on.  See:
                    -   * https://developers.google.com/gsuite/add-ons/how-tos/publish-add-on-overview
                    -   * for details.
                    +   * A service for managing Google Workspace add-ons.
                        * 
                    */ public abstract static class GSuiteAddOnsImplBase @@ -726,30 +791,7 @@ public final io.grpc.ServerServiceDefinition bindService() { * A stub to allow clients to do asynchronous rpc calls to service GSuiteAddOns. * *
                    -   * A service for managing Google Workspace add-ons deployments.
                    -   * A Google Workspace add-on is a third-party embedded component that can be
                    -   * installed in Google Workspace Applications like Gmail, Calendar, Drive, and
                    -   * the Google Docs, Sheets, and Slides editors. Google Workspace add-ons can
                    -   * display UI cards, receive contextual information from the host application,
                    -   * and perform actions in the host application (See:
                    -   * https://developers.google.com/gsuite/add-ons/overview for more information).
                    -   * A Google Workspace add-on deployment resource specifies metadata about the
                    -   * add-on, including a specification of the entry points in the host application
                    -   * that trigger add-on executions (see:
                    -   * https://developers.google.com/gsuite/add-ons/concepts/gsuite-manifests).
                    -   * Add-on deployments defined via the Google Workspace add-ons API define their
                    -   * entrypoints using HTTPS URLs (See:
                    -   * https://developers.google.com/gsuite/add-ons/guides/alternate-runtimes),
                    -   * A Google Workspace add-on deployment can be installed in developer mode,
                    -   * which allows an add-on developer to test the experience an end-user would see
                    -   * when installing and running the add-on in their G Suite applications.  When
                    -   * running in developer mode, more detailed error messages are exposed in the
                    -   * add-on UI to aid in debugging.
                    -   * A Google Workspace add-on deployment can be published to Google Workspace
                    -   * Marketplace, which allows other Google Workspace users to discover and
                    -   * install the add-on.  See:
                    -   * https://developers.google.com/gsuite/add-ons/how-tos/publish-add-on-overview
                    -   * for details.
                    +   * A service for managing Google Workspace add-ons.
                        * 
                    */ public static final class GSuiteAddOnsStub @@ -913,36 +955,57 @@ public void getInstallStatus( request, responseObserver); } + + /** + * + * + *
                    +     * Gets the Chat app configuration of a project. Only Chat apps built as
                    +     * Google Workspace add-ons are supported. Each Google Cloud project has
                    +     * exactly one Chat app configuration.
                    +     * Requires authenticating and authorizing with user credentials and the
                    +     * `gsuiteaddons.chatAppConfigs.get` and `chat.bots.get` IAM permissions on
                    +     * the project.
                    +     * 
                    + */ + public void getChatAppConfig( + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetChatAppConfigMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
                    +     * Updates the Chat app configuration of a project. Only Chat apps built as
                    +     * Google Workspace add-ons are supported. Each Google Cloud project has
                    +     * exactly one Chat app configuration.
                    +     * Requires authenticating and authorizing with user credentials and the
                    +     * `gsuiteaddons.chatAppConfigs.update`, `chat.bots.update` and
                    +     * `chat.bots.get` IAM permissions on the project.
                    +     * 
                    + */ + public void updateChatAppConfig( + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateChatAppConfigMethod(), getCallOptions()), + request, + responseObserver); + } } /** * A stub to allow clients to do synchronous rpc calls to service GSuiteAddOns. * *
                    -   * A service for managing Google Workspace add-ons deployments.
                    -   * A Google Workspace add-on is a third-party embedded component that can be
                    -   * installed in Google Workspace Applications like Gmail, Calendar, Drive, and
                    -   * the Google Docs, Sheets, and Slides editors. Google Workspace add-ons can
                    -   * display UI cards, receive contextual information from the host application,
                    -   * and perform actions in the host application (See:
                    -   * https://developers.google.com/gsuite/add-ons/overview for more information).
                    -   * A Google Workspace add-on deployment resource specifies metadata about the
                    -   * add-on, including a specification of the entry points in the host application
                    -   * that trigger add-on executions (see:
                    -   * https://developers.google.com/gsuite/add-ons/concepts/gsuite-manifests).
                    -   * Add-on deployments defined via the Google Workspace add-ons API define their
                    -   * entrypoints using HTTPS URLs (See:
                    -   * https://developers.google.com/gsuite/add-ons/guides/alternate-runtimes),
                    -   * A Google Workspace add-on deployment can be installed in developer mode,
                    -   * which allows an add-on developer to test the experience an end-user would see
                    -   * when installing and running the add-on in their G Suite applications.  When
                    -   * running in developer mode, more detailed error messages are exposed in the
                    -   * add-on UI to aid in debugging.
                    -   * A Google Workspace add-on deployment can be published to Google Workspace
                    -   * Marketplace, which allows other Google Workspace users to discover and
                    -   * install the add-on.  See:
                    -   * https://developers.google.com/gsuite/add-ons/how-tos/publish-add-on-overview
                    -   * for details.
                    +   * A service for managing Google Workspace add-ons.
                        * 
                    */ public static final class GSuiteAddOnsBlockingV2Stub @@ -1086,36 +1149,51 @@ public com.google.cloud.gsuiteaddons.v1.InstallStatus getInstallStatus( return io.grpc.stub.ClientCalls.blockingV2UnaryCall( getChannel(), getGetInstallStatusMethod(), getCallOptions(), request); } + + /** + * + * + *
                    +     * Gets the Chat app configuration of a project. Only Chat apps built as
                    +     * Google Workspace add-ons are supported. Each Google Cloud project has
                    +     * exactly one Chat app configuration.
                    +     * Requires authenticating and authorizing with user credentials and the
                    +     * `gsuiteaddons.chatAppConfigs.get` and `chat.bots.get` IAM permissions on
                    +     * the project.
                    +     * 
                    + */ + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig getChatAppConfig( + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetChatAppConfigMethod(), getCallOptions(), request); + } + + /** + * + * + *
                    +     * Updates the Chat app configuration of a project. Only Chat apps built as
                    +     * Google Workspace add-ons are supported. Each Google Cloud project has
                    +     * exactly one Chat app configuration.
                    +     * Requires authenticating and authorizing with user credentials and the
                    +     * `gsuiteaddons.chatAppConfigs.update`, `chat.bots.update` and
                    +     * `chat.bots.get` IAM permissions on the project.
                    +     * 
                    + */ + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig updateChatAppConfig( + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getUpdateChatAppConfigMethod(), getCallOptions(), request); + } } /** * A stub to allow clients to do limited synchronous rpc calls to service GSuiteAddOns. * *
                    -   * A service for managing Google Workspace add-ons deployments.
                    -   * A Google Workspace add-on is a third-party embedded component that can be
                    -   * installed in Google Workspace Applications like Gmail, Calendar, Drive, and
                    -   * the Google Docs, Sheets, and Slides editors. Google Workspace add-ons can
                    -   * display UI cards, receive contextual information from the host application,
                    -   * and perform actions in the host application (See:
                    -   * https://developers.google.com/gsuite/add-ons/overview for more information).
                    -   * A Google Workspace add-on deployment resource specifies metadata about the
                    -   * add-on, including a specification of the entry points in the host application
                    -   * that trigger add-on executions (see:
                    -   * https://developers.google.com/gsuite/add-ons/concepts/gsuite-manifests).
                    -   * Add-on deployments defined via the Google Workspace add-ons API define their
                    -   * entrypoints using HTTPS URLs (See:
                    -   * https://developers.google.com/gsuite/add-ons/guides/alternate-runtimes),
                    -   * A Google Workspace add-on deployment can be installed in developer mode,
                    -   * which allows an add-on developer to test the experience an end-user would see
                    -   * when installing and running the add-on in their G Suite applications.  When
                    -   * running in developer mode, more detailed error messages are exposed in the
                    -   * add-on UI to aid in debugging.
                    -   * A Google Workspace add-on deployment can be published to Google Workspace
                    -   * Marketplace, which allows other Google Workspace users to discover and
                    -   * install the add-on.  See:
                    -   * https://developers.google.com/gsuite/add-ons/how-tos/publish-add-on-overview
                    -   * for details.
                    +   * A service for managing Google Workspace add-ons.
                        * 
                    */ public static final class GSuiteAddOnsBlockingStub @@ -1250,36 +1328,49 @@ public com.google.cloud.gsuiteaddons.v1.InstallStatus getInstallStatus( return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetInstallStatusMethod(), getCallOptions(), request); } + + /** + * + * + *
                    +     * Gets the Chat app configuration of a project. Only Chat apps built as
                    +     * Google Workspace add-ons are supported. Each Google Cloud project has
                    +     * exactly one Chat app configuration.
                    +     * Requires authenticating and authorizing with user credentials and the
                    +     * `gsuiteaddons.chatAppConfigs.get` and `chat.bots.get` IAM permissions on
                    +     * the project.
                    +     * 
                    + */ + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig getChatAppConfig( + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetChatAppConfigMethod(), getCallOptions(), request); + } + + /** + * + * + *
                    +     * Updates the Chat app configuration of a project. Only Chat apps built as
                    +     * Google Workspace add-ons are supported. Each Google Cloud project has
                    +     * exactly one Chat app configuration.
                    +     * Requires authenticating and authorizing with user credentials and the
                    +     * `gsuiteaddons.chatAppConfigs.update`, `chat.bots.update` and
                    +     * `chat.bots.get` IAM permissions on the project.
                    +     * 
                    + */ + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig updateChatAppConfig( + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateChatAppConfigMethod(), getCallOptions(), request); + } } /** * A stub to allow clients to do ListenableFuture-style rpc calls to service GSuiteAddOns. * *
                    -   * A service for managing Google Workspace add-ons deployments.
                    -   * A Google Workspace add-on is a third-party embedded component that can be
                    -   * installed in Google Workspace Applications like Gmail, Calendar, Drive, and
                    -   * the Google Docs, Sheets, and Slides editors. Google Workspace add-ons can
                    -   * display UI cards, receive contextual information from the host application,
                    -   * and perform actions in the host application (See:
                    -   * https://developers.google.com/gsuite/add-ons/overview for more information).
                    -   * A Google Workspace add-on deployment resource specifies metadata about the
                    -   * add-on, including a specification of the entry points in the host application
                    -   * that trigger add-on executions (see:
                    -   * https://developers.google.com/gsuite/add-ons/concepts/gsuite-manifests).
                    -   * Add-on deployments defined via the Google Workspace add-ons API define their
                    -   * entrypoints using HTTPS URLs (See:
                    -   * https://developers.google.com/gsuite/add-ons/guides/alternate-runtimes),
                    -   * A Google Workspace add-on deployment can be installed in developer mode,
                    -   * which allows an add-on developer to test the experience an end-user would see
                    -   * when installing and running the add-on in their G Suite applications.  When
                    -   * running in developer mode, more detailed error messages are exposed in the
                    -   * add-on UI to aid in debugging.
                    -   * A Google Workspace add-on deployment can be published to Google Workspace
                    -   * Marketplace, which allows other Google Workspace users to discover and
                    -   * install the add-on.  See:
                    -   * https://developers.google.com/gsuite/add-ons/how-tos/publish-add-on-overview
                    -   * for details.
                    +   * A service for managing Google Workspace add-ons.
                        * 
                    */ public static final class GSuiteAddOnsFutureStub @@ -1420,6 +1511,44 @@ protected GSuiteAddOnsFutureStub build( return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetInstallStatusMethod(), getCallOptions()), request); } + + /** + * + * + *
                    +     * Gets the Chat app configuration of a project. Only Chat apps built as
                    +     * Google Workspace add-ons are supported. Each Google Cloud project has
                    +     * exactly one Chat app configuration.
                    +     * Requires authenticating and authorizing with user credentials and the
                    +     * `gsuiteaddons.chatAppConfigs.get` and `chat.bots.get` IAM permissions on
                    +     * the project.
                    +     * 
                    + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.gsuiteaddons.v1.ChatAppConfig> + getChatAppConfig(com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetChatAppConfigMethod(), getCallOptions()), request); + } + + /** + * + * + *
                    +     * Updates the Chat app configuration of a project. Only Chat apps built as
                    +     * Google Workspace add-ons are supported. Each Google Cloud project has
                    +     * exactly one Chat app configuration.
                    +     * Requires authenticating and authorizing with user credentials and the
                    +     * `gsuiteaddons.chatAppConfigs.update`, `chat.bots.update` and
                    +     * `chat.bots.get` IAM permissions on the project.
                    +     * 
                    + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.gsuiteaddons.v1.ChatAppConfig> + updateChatAppConfig(com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateChatAppConfigMethod(), getCallOptions()), request); + } } private static final int METHODID_GET_AUTHORIZATION = 0; @@ -1431,6 +1560,8 @@ protected GSuiteAddOnsFutureStub build( private static final int METHODID_INSTALL_DEPLOYMENT = 6; private static final int METHODID_UNINSTALL_DEPLOYMENT = 7; private static final int METHODID_GET_INSTALL_STATUS = 8; + private static final int METHODID_GET_CHAT_APP_CONFIG = 9; + private static final int METHODID_UPDATE_CHAT_APP_CONFIG = 10; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -1501,6 +1632,18 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_GET_CHAT_APP_CONFIG: + serviceImpl.getChatAppConfig( + (com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_UPDATE_CHAT_APP_CONFIG: + serviceImpl.updateChatAppConfig( + (com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; default: throw new AssertionError(); } @@ -1578,6 +1721,20 @@ public static final io.grpc.ServerServiceDefinition bindService(AsyncService ser com.google.cloud.gsuiteaddons.v1.GetInstallStatusRequest, com.google.cloud.gsuiteaddons.v1.InstallStatus>( service, METHODID_GET_INSTALL_STATUS))) + .addMethod( + getGetChatAppConfigMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig>( + service, METHODID_GET_CHAT_APP_CONFIG))) + .addMethod( + getUpdateChatAppConfigMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig>( + service, METHODID_UPDATE_CHAT_APP_CONFIG))) .build(); } @@ -1638,6 +1795,8 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getInstallDeploymentMethod()) .addMethod(getUninstallDeploymentMethod()) .addMethod(getGetInstallStatusMethod()) + .addMethod(getGetChatAppConfigMethod()) + .addMethod(getUpdateChatAppConfigMethod()) .build(); } } diff --git a/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/MeetAddOnManifest.java b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/MeetAddOnManifest.java new file mode 100644 index 000000000000..be6dd1d08c38 --- /dev/null +++ b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/MeetAddOnManifest.java @@ -0,0 +1,1314 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/apps/script/type/meet/meet_addon_manifest.proto +// Protobuf Java Version: 4.33.6 + +package com.google.apps.script.type.meet; + +/** + * + * + *
                    + * Meet add-on manifest.
                    + * 
                    + * + * Protobuf type {@code google.apps.script.type.meet.MeetAddOnManifest} + */ +@com.google.protobuf.Generated +public final class MeetAddOnManifest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.apps.script.type.meet.MeetAddOnManifest) + MeetAddOnManifestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "MeetAddOnManifest"); + } + + // Use MeetAddOnManifest.newBuilder() to construct. + private MeetAddOnManifest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private MeetAddOnManifest() { + termsUri_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.apps.script.type.meet.MeetAddOnManifestProto + .internal_static_google_apps_script_type_meet_MeetAddOnManifest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.apps.script.type.meet.MeetAddOnManifestProto + .internal_static_google_apps_script_type_meet_MeetAddOnManifest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.apps.script.type.meet.MeetAddOnManifest.class, + com.google.apps.script.type.meet.MeetAddOnManifest.Builder.class); + } + + private int bitField0_; + public static final int HOMEPAGE_TRIGGER_FIELD_NUMBER = 2; + private com.google.apps.script.type.HomepageExtensionPoint homepageTrigger_; + + /** + * + * + *
                    +   * If present, this overrides the configuration from
                    +   * `addOns.common.homepageTrigger`.
                    +   * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + * + * @return Whether the homepageTrigger field is set. + */ + @java.lang.Override + public boolean hasHomepageTrigger() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                    +   * If present, this overrides the configuration from
                    +   * `addOns.common.homepageTrigger`.
                    +   * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + * + * @return The homepageTrigger. + */ + @java.lang.Override + public com.google.apps.script.type.HomepageExtensionPoint getHomepageTrigger() { + return homepageTrigger_ == null + ? com.google.apps.script.type.HomepageExtensionPoint.getDefaultInstance() + : homepageTrigger_; + } + + /** + * + * + *
                    +   * If present, this overrides the configuration from
                    +   * `addOns.common.homepageTrigger`.
                    +   * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + */ + @java.lang.Override + public com.google.apps.script.type.HomepageExtensionPointOrBuilder getHomepageTriggerOrBuilder() { + return homepageTrigger_ == null + ? com.google.apps.script.type.HomepageExtensionPoint.getDefaultInstance() + : homepageTrigger_; + } + + public static final int WEB_FIELD_NUMBER = 3; + private com.google.apps.script.type.meet.Web web_; + + /** + * + * + *
                    +   * Details for addons that enhance the Meet web client.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + * + * @return Whether the web field is set. + */ + @java.lang.Override + public boolean hasWeb() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                    +   * Details for addons that enhance the Meet web client.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + * + * @return The web. + */ + @java.lang.Override + public com.google.apps.script.type.meet.Web getWeb() { + return web_ == null ? com.google.apps.script.type.meet.Web.getDefaultInstance() : web_; + } + + /** + * + * + *
                    +   * Details for addons that enhance the Meet web client.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + */ + @java.lang.Override + public com.google.apps.script.type.meet.WebOrBuilder getWebOrBuilder() { + return web_ == null ? com.google.apps.script.type.meet.Web.getDefaultInstance() : web_; + } + + public static final int TERMS_URI_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private volatile java.lang.Object termsUri_ = ""; + + /** + * + * + *
                    +   * A link to the terms of service for the add-on, if any should be shown.
                    +   * 
                    + * + * optional string terms_uri = 6; + * + * @return Whether the termsUri field is set. + */ + @java.lang.Override + public boolean hasTermsUri() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                    +   * A link to the terms of service for the add-on, if any should be shown.
                    +   * 
                    + * + * optional string terms_uri = 6; + * + * @return The termsUri. + */ + @java.lang.Override + public java.lang.String getTermsUri() { + java.lang.Object ref = termsUri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + termsUri_ = s; + return s; + } + } + + /** + * + * + *
                    +   * A link to the terms of service for the add-on, if any should be shown.
                    +   * 
                    + * + * optional string terms_uri = 6; + * + * @return The bytes for termsUri. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTermsUriBytes() { + java.lang.Object ref = termsUri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + termsUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SUPPORTS_COLLABORATION_FIELD_NUMBER = 7; + private boolean supportsCollaboration_ = false; + + /** + * + * + *
                    +   * Whether the addon supports collaboration or inviting others into the addon
                    +   * experience.
                    +   * 
                    + * + * bool supports_collaboration = 7; + * + * @return The supportsCollaboration. + */ + @java.lang.Override + public boolean getSupportsCollaboration() { + return supportsCollaboration_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getHomepageTrigger()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(3, getWeb()); + } + if (((bitField0_ & 0x00000004) != 0)) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, termsUri_); + } + if (supportsCollaboration_ != false) { + output.writeBool(7, supportsCollaboration_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getHomepageTrigger()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getWeb()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(6, termsUri_); + } + if (supportsCollaboration_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(7, supportsCollaboration_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.apps.script.type.meet.MeetAddOnManifest)) { + return super.equals(obj); + } + com.google.apps.script.type.meet.MeetAddOnManifest other = + (com.google.apps.script.type.meet.MeetAddOnManifest) obj; + + if (hasHomepageTrigger() != other.hasHomepageTrigger()) return false; + if (hasHomepageTrigger()) { + if (!getHomepageTrigger().equals(other.getHomepageTrigger())) return false; + } + if (hasWeb() != other.hasWeb()) return false; + if (hasWeb()) { + if (!getWeb().equals(other.getWeb())) return false; + } + if (hasTermsUri() != other.hasTermsUri()) return false; + if (hasTermsUri()) { + if (!getTermsUri().equals(other.getTermsUri())) return false; + } + if (getSupportsCollaboration() != other.getSupportsCollaboration()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasHomepageTrigger()) { + hash = (37 * hash) + HOMEPAGE_TRIGGER_FIELD_NUMBER; + hash = (53 * hash) + getHomepageTrigger().hashCode(); + } + if (hasWeb()) { + hash = (37 * hash) + WEB_FIELD_NUMBER; + hash = (53 * hash) + getWeb().hashCode(); + } + if (hasTermsUri()) { + hash = (37 * hash) + TERMS_URI_FIELD_NUMBER; + hash = (53 * hash) + getTermsUri().hashCode(); + } + hash = (37 * hash) + SUPPORTS_COLLABORATION_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSupportsCollaboration()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.apps.script.type.meet.MeetAddOnManifest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Meet add-on manifest.
                    +   * 
                    + * + * Protobuf type {@code google.apps.script.type.meet.MeetAddOnManifest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.apps.script.type.meet.MeetAddOnManifest) + com.google.apps.script.type.meet.MeetAddOnManifestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.apps.script.type.meet.MeetAddOnManifestProto + .internal_static_google_apps_script_type_meet_MeetAddOnManifest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.apps.script.type.meet.MeetAddOnManifestProto + .internal_static_google_apps_script_type_meet_MeetAddOnManifest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.apps.script.type.meet.MeetAddOnManifest.class, + com.google.apps.script.type.meet.MeetAddOnManifest.Builder.class); + } + + // Construct using com.google.apps.script.type.meet.MeetAddOnManifest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetHomepageTriggerFieldBuilder(); + internalGetWebFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + homepageTrigger_ = null; + if (homepageTriggerBuilder_ != null) { + homepageTriggerBuilder_.dispose(); + homepageTriggerBuilder_ = null; + } + web_ = null; + if (webBuilder_ != null) { + webBuilder_.dispose(); + webBuilder_ = null; + } + termsUri_ = ""; + supportsCollaboration_ = false; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.apps.script.type.meet.MeetAddOnManifestProto + .internal_static_google_apps_script_type_meet_MeetAddOnManifest_descriptor; + } + + @java.lang.Override + public com.google.apps.script.type.meet.MeetAddOnManifest getDefaultInstanceForType() { + return com.google.apps.script.type.meet.MeetAddOnManifest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.apps.script.type.meet.MeetAddOnManifest build() { + com.google.apps.script.type.meet.MeetAddOnManifest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.apps.script.type.meet.MeetAddOnManifest buildPartial() { + com.google.apps.script.type.meet.MeetAddOnManifest result = + new com.google.apps.script.type.meet.MeetAddOnManifest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.apps.script.type.meet.MeetAddOnManifest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.homepageTrigger_ = + homepageTriggerBuilder_ == null ? homepageTrigger_ : homepageTriggerBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.web_ = webBuilder_ == null ? web_ : webBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.termsUri_ = termsUri_; + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.supportsCollaboration_ = supportsCollaboration_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.apps.script.type.meet.MeetAddOnManifest) { + return mergeFrom((com.google.apps.script.type.meet.MeetAddOnManifest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.apps.script.type.meet.MeetAddOnManifest other) { + if (other == com.google.apps.script.type.meet.MeetAddOnManifest.getDefaultInstance()) + return this; + if (other.hasHomepageTrigger()) { + mergeHomepageTrigger(other.getHomepageTrigger()); + } + if (other.hasWeb()) { + mergeWeb(other.getWeb()); + } + if (other.hasTermsUri()) { + termsUri_ = other.termsUri_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.getSupportsCollaboration() != false) { + setSupportsCollaboration(other.getSupportsCollaboration()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 18: + { + input.readMessage( + internalGetHomepageTriggerFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 18 + case 26: + { + input.readMessage(internalGetWebFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 26 + case 50: + { + termsUri_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 50 + case 56: + { + supportsCollaboration_ = input.readBool(); + bitField0_ |= 0x00000008; + break; + } // case 56 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.apps.script.type.HomepageExtensionPoint homepageTrigger_; + private com.google.protobuf.SingleFieldBuilder< + com.google.apps.script.type.HomepageExtensionPoint, + com.google.apps.script.type.HomepageExtensionPoint.Builder, + com.google.apps.script.type.HomepageExtensionPointOrBuilder> + homepageTriggerBuilder_; + + /** + * + * + *
                    +     * If present, this overrides the configuration from
                    +     * `addOns.common.homepageTrigger`.
                    +     * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + * + * @return Whether the homepageTrigger field is set. + */ + public boolean hasHomepageTrigger() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                    +     * If present, this overrides the configuration from
                    +     * `addOns.common.homepageTrigger`.
                    +     * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + * + * @return The homepageTrigger. + */ + public com.google.apps.script.type.HomepageExtensionPoint getHomepageTrigger() { + if (homepageTriggerBuilder_ == null) { + return homepageTrigger_ == null + ? com.google.apps.script.type.HomepageExtensionPoint.getDefaultInstance() + : homepageTrigger_; + } else { + return homepageTriggerBuilder_.getMessage(); + } + } + + /** + * + * + *
                    +     * If present, this overrides the configuration from
                    +     * `addOns.common.homepageTrigger`.
                    +     * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + */ + public Builder setHomepageTrigger(com.google.apps.script.type.HomepageExtensionPoint value) { + if (homepageTriggerBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + homepageTrigger_ = value; + } else { + homepageTriggerBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * If present, this overrides the configuration from
                    +     * `addOns.common.homepageTrigger`.
                    +     * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + */ + public Builder setHomepageTrigger( + com.google.apps.script.type.HomepageExtensionPoint.Builder builderForValue) { + if (homepageTriggerBuilder_ == null) { + homepageTrigger_ = builderForValue.build(); + } else { + homepageTriggerBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * If present, this overrides the configuration from
                    +     * `addOns.common.homepageTrigger`.
                    +     * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + */ + public Builder mergeHomepageTrigger(com.google.apps.script.type.HomepageExtensionPoint value) { + if (homepageTriggerBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && homepageTrigger_ != null + && homepageTrigger_ + != com.google.apps.script.type.HomepageExtensionPoint.getDefaultInstance()) { + getHomepageTriggerBuilder().mergeFrom(value); + } else { + homepageTrigger_ = value; + } + } else { + homepageTriggerBuilder_.mergeFrom(value); + } + if (homepageTrigger_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
                    +     * If present, this overrides the configuration from
                    +     * `addOns.common.homepageTrigger`.
                    +     * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + */ + public Builder clearHomepageTrigger() { + bitField0_ = (bitField0_ & ~0x00000001); + homepageTrigger_ = null; + if (homepageTriggerBuilder_ != null) { + homepageTriggerBuilder_.dispose(); + homepageTriggerBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                    +     * If present, this overrides the configuration from
                    +     * `addOns.common.homepageTrigger`.
                    +     * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + */ + public com.google.apps.script.type.HomepageExtensionPoint.Builder getHomepageTriggerBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetHomepageTriggerFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * If present, this overrides the configuration from
                    +     * `addOns.common.homepageTrigger`.
                    +     * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + */ + public com.google.apps.script.type.HomepageExtensionPointOrBuilder + getHomepageTriggerOrBuilder() { + if (homepageTriggerBuilder_ != null) { + return homepageTriggerBuilder_.getMessageOrBuilder(); + } else { + return homepageTrigger_ == null + ? com.google.apps.script.type.HomepageExtensionPoint.getDefaultInstance() + : homepageTrigger_; + } + } + + /** + * + * + *
                    +     * If present, this overrides the configuration from
                    +     * `addOns.common.homepageTrigger`.
                    +     * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.apps.script.type.HomepageExtensionPoint, + com.google.apps.script.type.HomepageExtensionPoint.Builder, + com.google.apps.script.type.HomepageExtensionPointOrBuilder> + internalGetHomepageTriggerFieldBuilder() { + if (homepageTriggerBuilder_ == null) { + homepageTriggerBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.apps.script.type.HomepageExtensionPoint, + com.google.apps.script.type.HomepageExtensionPoint.Builder, + com.google.apps.script.type.HomepageExtensionPointOrBuilder>( + getHomepageTrigger(), getParentForChildren(), isClean()); + homepageTrigger_ = null; + } + return homepageTriggerBuilder_; + } + + private com.google.apps.script.type.meet.Web web_; + private com.google.protobuf.SingleFieldBuilder< + com.google.apps.script.type.meet.Web, + com.google.apps.script.type.meet.Web.Builder, + com.google.apps.script.type.meet.WebOrBuilder> + webBuilder_; + + /** + * + * + *
                    +     * Details for addons that enhance the Meet web client.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + * + * @return Whether the web field is set. + */ + public boolean hasWeb() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                    +     * Details for addons that enhance the Meet web client.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + * + * @return The web. + */ + public com.google.apps.script.type.meet.Web getWeb() { + if (webBuilder_ == null) { + return web_ == null ? com.google.apps.script.type.meet.Web.getDefaultInstance() : web_; + } else { + return webBuilder_.getMessage(); + } + } + + /** + * + * + *
                    +     * Details for addons that enhance the Meet web client.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + */ + public Builder setWeb(com.google.apps.script.type.meet.Web value) { + if (webBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + web_ = value; + } else { + webBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Details for addons that enhance the Meet web client.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + */ + public Builder setWeb(com.google.apps.script.type.meet.Web.Builder builderForValue) { + if (webBuilder_ == null) { + web_ = builderForValue.build(); + } else { + webBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Details for addons that enhance the Meet web client.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + */ + public Builder mergeWeb(com.google.apps.script.type.meet.Web value) { + if (webBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && web_ != null + && web_ != com.google.apps.script.type.meet.Web.getDefaultInstance()) { + getWebBuilder().mergeFrom(value); + } else { + web_ = value; + } + } else { + webBuilder_.mergeFrom(value); + } + if (web_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
                    +     * Details for addons that enhance the Meet web client.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + */ + public Builder clearWeb() { + bitField0_ = (bitField0_ & ~0x00000002); + web_ = null; + if (webBuilder_ != null) { + webBuilder_.dispose(); + webBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Details for addons that enhance the Meet web client.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + */ + public com.google.apps.script.type.meet.Web.Builder getWebBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetWebFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * Details for addons that enhance the Meet web client.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + */ + public com.google.apps.script.type.meet.WebOrBuilder getWebOrBuilder() { + if (webBuilder_ != null) { + return webBuilder_.getMessageOrBuilder(); + } else { + return web_ == null ? com.google.apps.script.type.meet.Web.getDefaultInstance() : web_; + } + } + + /** + * + * + *
                    +     * Details for addons that enhance the Meet web client.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.apps.script.type.meet.Web, + com.google.apps.script.type.meet.Web.Builder, + com.google.apps.script.type.meet.WebOrBuilder> + internalGetWebFieldBuilder() { + if (webBuilder_ == null) { + webBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.apps.script.type.meet.Web, + com.google.apps.script.type.meet.Web.Builder, + com.google.apps.script.type.meet.WebOrBuilder>( + getWeb(), getParentForChildren(), isClean()); + web_ = null; + } + return webBuilder_; + } + + private java.lang.Object termsUri_ = ""; + + /** + * + * + *
                    +     * A link to the terms of service for the add-on, if any should be shown.
                    +     * 
                    + * + * optional string terms_uri = 6; + * + * @return Whether the termsUri field is set. + */ + public boolean hasTermsUri() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                    +     * A link to the terms of service for the add-on, if any should be shown.
                    +     * 
                    + * + * optional string terms_uri = 6; + * + * @return The termsUri. + */ + public java.lang.String getTermsUri() { + java.lang.Object ref = termsUri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + termsUri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * A link to the terms of service for the add-on, if any should be shown.
                    +     * 
                    + * + * optional string terms_uri = 6; + * + * @return The bytes for termsUri. + */ + public com.google.protobuf.ByteString getTermsUriBytes() { + java.lang.Object ref = termsUri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + termsUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * A link to the terms of service for the add-on, if any should be shown.
                    +     * 
                    + * + * optional string terms_uri = 6; + * + * @param value The termsUri to set. + * @return This builder for chaining. + */ + public Builder setTermsUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + termsUri_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * A link to the terms of service for the add-on, if any should be shown.
                    +     * 
                    + * + * optional string terms_uri = 6; + * + * @return This builder for chaining. + */ + public Builder clearTermsUri() { + termsUri_ = getDefaultInstance().getTermsUri(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * A link to the terms of service for the add-on, if any should be shown.
                    +     * 
                    + * + * optional string terms_uri = 6; + * + * @param value The bytes for termsUri to set. + * @return This builder for chaining. + */ + public Builder setTermsUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + termsUri_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private boolean supportsCollaboration_; + + /** + * + * + *
                    +     * Whether the addon supports collaboration or inviting others into the addon
                    +     * experience.
                    +     * 
                    + * + * bool supports_collaboration = 7; + * + * @return The supportsCollaboration. + */ + @java.lang.Override + public boolean getSupportsCollaboration() { + return supportsCollaboration_; + } + + /** + * + * + *
                    +     * Whether the addon supports collaboration or inviting others into the addon
                    +     * experience.
                    +     * 
                    + * + * bool supports_collaboration = 7; + * + * @param value The supportsCollaboration to set. + * @return This builder for chaining. + */ + public Builder setSupportsCollaboration(boolean value) { + + supportsCollaboration_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Whether the addon supports collaboration or inviting others into the addon
                    +     * experience.
                    +     * 
                    + * + * bool supports_collaboration = 7; + * + * @return This builder for chaining. + */ + public Builder clearSupportsCollaboration() { + bitField0_ = (bitField0_ & ~0x00000008); + supportsCollaboration_ = false; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.apps.script.type.meet.MeetAddOnManifest) + } + + // @@protoc_insertion_point(class_scope:google.apps.script.type.meet.MeetAddOnManifest) + private static final com.google.apps.script.type.meet.MeetAddOnManifest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.apps.script.type.meet.MeetAddOnManifest(); + } + + public static com.google.apps.script.type.meet.MeetAddOnManifest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public MeetAddOnManifest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.apps.script.type.meet.MeetAddOnManifest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/MeetAddOnManifestOrBuilder.java b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/MeetAddOnManifestOrBuilder.java new file mode 100644 index 000000000000..b840e91cb1b3 --- /dev/null +++ b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/MeetAddOnManifestOrBuilder.java @@ -0,0 +1,158 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/apps/script/type/meet/meet_addon_manifest.proto +// Protobuf Java Version: 4.33.6 + +package com.google.apps.script.type.meet; + +@com.google.protobuf.Generated +public interface MeetAddOnManifestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.apps.script.type.meet.MeetAddOnManifest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * If present, this overrides the configuration from
                    +   * `addOns.common.homepageTrigger`.
                    +   * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + * + * @return Whether the homepageTrigger field is set. + */ + boolean hasHomepageTrigger(); + + /** + * + * + *
                    +   * If present, this overrides the configuration from
                    +   * `addOns.common.homepageTrigger`.
                    +   * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + * + * @return The homepageTrigger. + */ + com.google.apps.script.type.HomepageExtensionPoint getHomepageTrigger(); + + /** + * + * + *
                    +   * If present, this overrides the configuration from
                    +   * `addOns.common.homepageTrigger`.
                    +   * 
                    + * + * .google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + */ + com.google.apps.script.type.HomepageExtensionPointOrBuilder getHomepageTriggerOrBuilder(); + + /** + * + * + *
                    +   * Details for addons that enhance the Meet web client.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + * + * @return Whether the web field is set. + */ + boolean hasWeb(); + + /** + * + * + *
                    +   * Details for addons that enhance the Meet web client.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + * + * @return The web. + */ + com.google.apps.script.type.meet.Web getWeb(); + + /** + * + * + *
                    +   * Details for addons that enhance the Meet web client.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web web = 3; + */ + com.google.apps.script.type.meet.WebOrBuilder getWebOrBuilder(); + + /** + * + * + *
                    +   * A link to the terms of service for the add-on, if any should be shown.
                    +   * 
                    + * + * optional string terms_uri = 6; + * + * @return Whether the termsUri field is set. + */ + boolean hasTermsUri(); + + /** + * + * + *
                    +   * A link to the terms of service for the add-on, if any should be shown.
                    +   * 
                    + * + * optional string terms_uri = 6; + * + * @return The termsUri. + */ + java.lang.String getTermsUri(); + + /** + * + * + *
                    +   * A link to the terms of service for the add-on, if any should be shown.
                    +   * 
                    + * + * optional string terms_uri = 6; + * + * @return The bytes for termsUri. + */ + com.google.protobuf.ByteString getTermsUriBytes(); + + /** + * + * + *
                    +   * Whether the addon supports collaboration or inviting others into the addon
                    +   * experience.
                    +   * 
                    + * + * bool supports_collaboration = 7; + * + * @return The supportsCollaboration. + */ + boolean getSupportsCollaboration(); +} diff --git a/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/MeetAddOnManifestProto.java b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/MeetAddOnManifestProto.java new file mode 100644 index 000000000000..3b4d9caba737 --- /dev/null +++ b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/MeetAddOnManifestProto.java @@ -0,0 +1,139 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/apps/script/type/meet/meet_addon_manifest.proto +// Protobuf Java Version: 4.33.6 + +package com.google.apps.script.type.meet; + +@com.google.protobuf.Generated +public final class MeetAddOnManifestProto extends com.google.protobuf.GeneratedFile { + private MeetAddOnManifestProto() {} + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "MeetAddOnManifestProto"); + } + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_apps_script_type_meet_MeetAddOnManifest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_apps_script_type_meet_MeetAddOnManifest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_apps_script_type_meet_Web_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_apps_script_type_meet_Web_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n" + + "6google/apps/script/type/meet/meet_addon_manifest.proto\022\034google.apps.script.typ" + + "e.meet\032-google/apps/script/type/extension_point.proto\"\324\001\n" + + "\021MeetAddOnManifest\022I\n" + + "\020homepage_trigger\030\002" + + " \001(\0132/.google.apps.script.type.HomepageExtensionPoint\022.\n" + + "\003web\030\003 \001(\0132!.google.apps.script.type.meet.Web\022\026\n" + + "\tterms_uri\030\006 \001(\tH\000\210\001\001\022\036\n" + + "\026supports_collaboration\030\007 \001(\010B\014\n\n" + + "_terms_uri\"\366\004\n" + + "\003Web\022\032\n" + + "\016side_panel_uri\030\001 \001(\tB\002\030\001\022\026\n" + + "\016side_panel_url\030\014 \001(\t\022\032\n" + + "\016main_stage_uri\030\002 \001(\tB\002\030\001\022\037\n" + + "\027supports_screen_sharing\030\003 \001(\010\022\"\n" + + "\026supports_collaboration\030\004 \001(\010B\002\030\001\022\030\n" + + "\020supports_pop_out\030\005 \001(\010\022\030\n" + + "\014host_origins\030\006 \003(\tB\002\030\001\022\026\n" + + "\016add_on_origins\030\013 \003(\t\022;\n\n" + + "open_state\030\007 \001(\0162\'.google.apps.script.type.meet.Web.State\022,\n" + + "$supports_collaboration_host_controls\030\010 \001(\010\022\020\n" + + "\010logo_url\030\t \001(\t\022\032\n" + + "\022dark_mode_logo_url\030\r" + + " \001(\t\022G\n" + + "\014display_flow\030\n" + + " \001(\0162-.google.apps.script.type.meet.Web.DisplayFlowB\002\030\001\"g\n" + + "\005State\022\025\n" + + "\021STATE_UNSPECIFIED\020\000\022\023\n" + + "\017SIDE_PANEL_ONLY\020\001\022\023\n" + + "\017MAIN_STAGE_ONLY\020\002\022\035\n" + + "\031SIDE_PANEL_AND_MAIN_STAGE\020\003\"C\n" + + "\013DisplayFlow\022\034\n" + + "\030DISPLAY_FLOW_UNSPECIFIED\020\000\022\t\n" + + "\005FOCUS\020\001\022\013\n" + + "\007AUGMENT\020\002B\332\001\n" + + " com.google.apps.script.type.meetB\026MeetAddOnManifestPro" + + "toP\001Z;google.golang.org/genproto/googlea" + + "pis/apps/script/type/meet\252\002\034Google.Apps." + + "Script.Type.Meet\312\002\034Google\\Apps\\Script\\Type\\Meet\352\002" + + " Google::Apps::Script::Type::Meetb\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.apps.script.type.ExtensionPoint.getDescriptor(), + }); + internal_static_google_apps_script_type_meet_MeetAddOnManifest_descriptor = + getDescriptor().getMessageType(0); + internal_static_google_apps_script_type_meet_MeetAddOnManifest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_apps_script_type_meet_MeetAddOnManifest_descriptor, + new java.lang.String[] { + "HomepageTrigger", "Web", "TermsUri", "SupportsCollaboration", + }); + internal_static_google_apps_script_type_meet_Web_descriptor = getDescriptor().getMessageType(1); + internal_static_google_apps_script_type_meet_Web_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_apps_script_type_meet_Web_descriptor, + new java.lang.String[] { + "SidePanelUri", + "SidePanelUrl", + "MainStageUri", + "SupportsScreenSharing", + "SupportsCollaboration", + "SupportsPopOut", + "HostOrigins", + "AddOnOrigins", + "OpenState", + "SupportsCollaborationHostControls", + "LogoUrl", + "DarkModeLogoUrl", + "DisplayFlow", + }); + descriptor.resolveAllFeaturesImmutable(); + com.google.apps.script.type.ExtensionPoint.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/Web.java b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/Web.java new file mode 100644 index 000000000000..d6f8919243dc --- /dev/null +++ b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/Web.java @@ -0,0 +1,3171 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/apps/script/type/meet/meet_addon_manifest.proto +// Protobuf Java Version: 4.33.6 + +package com.google.apps.script.type.meet; + +/** + * + * + *
                    + * Details for addons that enhance the Meet web client.
                    + * 
                    + * + * Protobuf type {@code google.apps.script.type.meet.Web} + */ +@com.google.protobuf.Generated +public final class Web extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.apps.script.type.meet.Web) + WebOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Web"); + } + + // Use Web.newBuilder() to construct. + private Web(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Web() { + sidePanelUri_ = ""; + sidePanelUrl_ = ""; + mainStageUri_ = ""; + hostOrigins_ = com.google.protobuf.LazyStringArrayList.emptyList(); + addOnOrigins_ = com.google.protobuf.LazyStringArrayList.emptyList(); + openState_ = 0; + logoUrl_ = ""; + darkModeLogoUrl_ = ""; + displayFlow_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.apps.script.type.meet.MeetAddOnManifestProto + .internal_static_google_apps_script_type_meet_Web_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.apps.script.type.meet.MeetAddOnManifestProto + .internal_static_google_apps_script_type_meet_Web_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.apps.script.type.meet.Web.class, + com.google.apps.script.type.meet.Web.Builder.class); + } + + /** + * + * + *
                    +   * Enum for specifying initial addon opening state.
                    +   * 
                    + * + * Protobuf enum {@code google.apps.script.type.meet.Web.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                    +     * Initial state has not been specified with the addon.
                    +     * 
                    + * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
                    +     * The addon opens with only the side panel active.
                    +     * 
                    + * + * SIDE_PANEL_ONLY = 1; + */ + SIDE_PANEL_ONLY(1), + /** + * + * + *
                    +     * The addon opens with only the main stage active.
                    +     * 
                    + * + * MAIN_STAGE_ONLY = 2; + */ + MAIN_STAGE_ONLY(2), + /** + * + * + *
                    +     * The addon opens with both the side panel and the main stage active.
                    +     * 
                    + * + * SIDE_PANEL_AND_MAIN_STAGE = 3; + */ + SIDE_PANEL_AND_MAIN_STAGE(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "State"); + } + + /** + * + * + *
                    +     * Initial state has not been specified with the addon.
                    +     * 
                    + * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                    +     * The addon opens with only the side panel active.
                    +     * 
                    + * + * SIDE_PANEL_ONLY = 1; + */ + public static final int SIDE_PANEL_ONLY_VALUE = 1; + + /** + * + * + *
                    +     * The addon opens with only the main stage active.
                    +     * 
                    + * + * MAIN_STAGE_ONLY = 2; + */ + public static final int MAIN_STAGE_ONLY_VALUE = 2; + + /** + * + * + *
                    +     * The addon opens with both the side panel and the main stage active.
                    +     * 
                    + * + * SIDE_PANEL_AND_MAIN_STAGE = 3; + */ + public static final int SIDE_PANEL_AND_MAIN_STAGE_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return SIDE_PANEL_ONLY; + case 2: + return MAIN_STAGE_ONLY; + case 3: + return SIDE_PANEL_AND_MAIN_STAGE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public State findValueByNumber(int number) { + return State.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.apps.script.type.meet.Web.getDescriptor().getEnumTypes().get(0); + } + + private static final State[] VALUES = values(); + + public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private State(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.apps.script.type.meet.Web.State) + } + + /** + * + * + *
                    +   * Enum for specifying the display flow the add-on will follow when launched
                    +   * 
                    + * + * Protobuf enum {@code google.apps.script.type.meet.Web.DisplayFlow} + */ + public enum DisplayFlow implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                    +     * Display flow has not been specified.
                    +     * 
                    + * + * DISPLAY_FLOW_UNSPECIFIED = 0; + */ + DISPLAY_FLOW_UNSPECIFIED(0), + /** + * + * + *
                    +     * Add-on should launch in the "focus" display flow.
                    +     * 
                    + * + * FOCUS = 1; + */ + FOCUS(1), + /** + * + * + *
                    +     * Add-on should launch in the "augment" display flow.
                    +     * 
                    + * + * AUGMENT = 2; + */ + AUGMENT(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DisplayFlow"); + } + + /** + * + * + *
                    +     * Display flow has not been specified.
                    +     * 
                    + * + * DISPLAY_FLOW_UNSPECIFIED = 0; + */ + public static final int DISPLAY_FLOW_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                    +     * Add-on should launch in the "focus" display flow.
                    +     * 
                    + * + * FOCUS = 1; + */ + public static final int FOCUS_VALUE = 1; + + /** + * + * + *
                    +     * Add-on should launch in the "augment" display flow.
                    +     * 
                    + * + * AUGMENT = 2; + */ + public static final int AUGMENT_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static DisplayFlow valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static DisplayFlow forNumber(int value) { + switch (value) { + case 0: + return DISPLAY_FLOW_UNSPECIFIED; + case 1: + return FOCUS; + case 2: + return AUGMENT; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public DisplayFlow findValueByNumber(int number) { + return DisplayFlow.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.apps.script.type.meet.Web.getDescriptor().getEnumTypes().get(1); + } + + private static final DisplayFlow[] VALUES = values(); + + public static DisplayFlow valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private DisplayFlow(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.apps.script.type.meet.Web.DisplayFlow) + } + + public static final int SIDE_PANEL_URI_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object sidePanelUri_ = ""; + + /** + * + * + *
                    +   * The URI for the side panel iframe.
                    +   * 
                    + * + * string side_panel_uri = 1 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.side_panel_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=77 + * @return The sidePanelUri. + */ + @java.lang.Override + @java.lang.Deprecated + public java.lang.String getSidePanelUri() { + java.lang.Object ref = sidePanelUri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sidePanelUri_ = s; + return s; + } + } + + /** + * + * + *
                    +   * The URI for the side panel iframe.
                    +   * 
                    + * + * string side_panel_uri = 1 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.side_panel_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=77 + * @return The bytes for sidePanelUri. + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.protobuf.ByteString getSidePanelUriBytes() { + java.lang.Object ref = sidePanelUri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sidePanelUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SIDE_PANEL_URL_FIELD_NUMBER = 12; + + @SuppressWarnings("serial") + private volatile java.lang.Object sidePanelUrl_ = ""; + + /** + * + * + *
                    +   * The URL for the side panel iframe.
                    +   * 
                    + * + * string side_panel_url = 12; + * + * @return The sidePanelUrl. + */ + @java.lang.Override + public java.lang.String getSidePanelUrl() { + java.lang.Object ref = sidePanelUrl_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sidePanelUrl_ = s; + return s; + } + } + + /** + * + * + *
                    +   * The URL for the side panel iframe.
                    +   * 
                    + * + * string side_panel_url = 12; + * + * @return The bytes for sidePanelUrl. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSidePanelUrlBytes() { + java.lang.Object ref = sidePanelUrl_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sidePanelUrl_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int MAIN_STAGE_URI_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object mainStageUri_ = ""; + + /** + * + * + *
                    +   * The URI for the "main stage" iframe.
                    +   * 
                    + * + * string main_stage_uri = 2 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.main_stage_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=83 + * @return The mainStageUri. + */ + @java.lang.Override + @java.lang.Deprecated + public java.lang.String getMainStageUri() { + java.lang.Object ref = mainStageUri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + mainStageUri_ = s; + return s; + } + } + + /** + * + * + *
                    +   * The URI for the "main stage" iframe.
                    +   * 
                    + * + * string main_stage_uri = 2 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.main_stage_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=83 + * @return The bytes for mainStageUri. + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.protobuf.ByteString getMainStageUriBytes() { + java.lang.Object ref = mainStageUri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + mainStageUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SUPPORTS_SCREEN_SHARING_FIELD_NUMBER = 3; + private boolean supportsScreenSharing_ = false; + + /** + * + * + *
                    +   * Whether the addon supports screen sharing the main stage.
                    +   * 
                    + * + * bool supports_screen_sharing = 3; + * + * @return The supportsScreenSharing. + */ + @java.lang.Override + public boolean getSupportsScreenSharing() { + return supportsScreenSharing_; + } + + public static final int SUPPORTS_COLLABORATION_FIELD_NUMBER = 4; + private boolean supportsCollaboration_ = false; + + /** + * + * + *
                    +   * Whether the addon supports collaboration or inviting others into the addon
                    +   * experience. This field is deprecated now, please use the top level field in
                    +   * MeetAddOnManifest.
                    +   * 
                    + * + * bool supports_collaboration = 4 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.supports_collaboration is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=91 + * @return The supportsCollaboration. + */ + @java.lang.Override + @java.lang.Deprecated + public boolean getSupportsCollaboration() { + return supportsCollaboration_; + } + + public static final int SUPPORTS_POP_OUT_FIELD_NUMBER = 5; + private boolean supportsPopOut_ = false; + + /** + * + * + *
                    +   * Whether the addon supports popping out to a browser PiP experience.
                    +   * 
                    + * + * bool supports_pop_out = 5; + * + * @return The supportsPopOut. + */ + @java.lang.Override + public boolean getSupportsPopOut() { + return supportsPopOut_; + } + + public static final int HOST_ORIGINS_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList hostOrigins_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
                    +   * Deprecated, legacy name. Origins that should be added to the frame-src
                    +   * property of the iframe containing the third party site. Use add_on_origins
                    +   * instead.
                    +   * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @return A list containing the hostOrigins. + */ + @java.lang.Deprecated + public com.google.protobuf.ProtocolStringList getHostOriginsList() { + return hostOrigins_; + } + + /** + * + * + *
                    +   * Deprecated, legacy name. Origins that should be added to the frame-src
                    +   * property of the iframe containing the third party site. Use add_on_origins
                    +   * instead.
                    +   * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @return The count of hostOrigins. + */ + @java.lang.Deprecated + public int getHostOriginsCount() { + return hostOrigins_.size(); + } + + /** + * + * + *
                    +   * Deprecated, legacy name. Origins that should be added to the frame-src
                    +   * property of the iframe containing the third party site. Use add_on_origins
                    +   * instead.
                    +   * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @param index The index of the element to return. + * @return The hostOrigins at the given index. + */ + @java.lang.Deprecated + public java.lang.String getHostOrigins(int index) { + return hostOrigins_.get(index); + } + + /** + * + * + *
                    +   * Deprecated, legacy name. Origins that should be added to the frame-src
                    +   * property of the iframe containing the third party site. Use add_on_origins
                    +   * instead.
                    +   * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @param index The index of the value to return. + * @return The bytes of the hostOrigins at the given index. + */ + @java.lang.Deprecated + public com.google.protobuf.ByteString getHostOriginsBytes(int index) { + return hostOrigins_.getByteString(index); + } + + public static final int ADD_ON_ORIGINS_FIELD_NUMBER = 11; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList addOnOrigins_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
                    +   * Origins that should be added to the frame-src property of the iframe
                    +   * containing the third party site.
                    +   * 
                    + * + * repeated string add_on_origins = 11; + * + * @return A list containing the addOnOrigins. + */ + public com.google.protobuf.ProtocolStringList getAddOnOriginsList() { + return addOnOrigins_; + } + + /** + * + * + *
                    +   * Origins that should be added to the frame-src property of the iframe
                    +   * containing the third party site.
                    +   * 
                    + * + * repeated string add_on_origins = 11; + * + * @return The count of addOnOrigins. + */ + public int getAddOnOriginsCount() { + return addOnOrigins_.size(); + } + + /** + * + * + *
                    +   * Origins that should be added to the frame-src property of the iframe
                    +   * containing the third party site.
                    +   * 
                    + * + * repeated string add_on_origins = 11; + * + * @param index The index of the element to return. + * @return The addOnOrigins at the given index. + */ + public java.lang.String getAddOnOrigins(int index) { + return addOnOrigins_.get(index); + } + + /** + * + * + *
                    +   * Origins that should be added to the frame-src property of the iframe
                    +   * containing the third party site.
                    +   * 
                    + * + * repeated string add_on_origins = 11; + * + * @param index The index of the value to return. + * @return The bytes of the addOnOrigins at the given index. + */ + public com.google.protobuf.ByteString getAddOnOriginsBytes(int index) { + return addOnOrigins_.getByteString(index); + } + + public static final int OPEN_STATE_FIELD_NUMBER = 7; + private int openState_ = 0; + + /** + * + * + *
                    +   * The initial state when the addon is opened.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web.State open_state = 7; + * + * @return The enum numeric value on the wire for openState. + */ + @java.lang.Override + public int getOpenStateValue() { + return openState_; + } + + /** + * + * + *
                    +   * The initial state when the addon is opened.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web.State open_state = 7; + * + * @return The openState. + */ + @java.lang.Override + public com.google.apps.script.type.meet.Web.State getOpenState() { + com.google.apps.script.type.meet.Web.State result = + com.google.apps.script.type.meet.Web.State.forNumber(openState_); + return result == null ? com.google.apps.script.type.meet.Web.State.UNRECOGNIZED : result; + } + + public static final int SUPPORTS_COLLABORATION_HOST_CONTROLS_FIELD_NUMBER = 8; + private boolean supportsCollaborationHostControls_ = false; + + /** + * + * + *
                    +   * Whether the collaboration add-on supports host controls.
                    +   * 
                    + * + * bool supports_collaboration_host_controls = 8; + * + * @return The supportsCollaborationHostControls. + */ + @java.lang.Override + public boolean getSupportsCollaborationHostControls() { + return supportsCollaborationHostControls_; + } + + public static final int LOGO_URL_FIELD_NUMBER = 9; + + @SuppressWarnings("serial") + private volatile java.lang.Object logoUrl_ = ""; + + /** + * + * + *
                    +   * The URL of the logo to be displayed for the addon. If not specified, the
                    +   * logo defaults to the logo in the common section of the manifest.
                    +   * 
                    + * + * string logo_url = 9; + * + * @return The logoUrl. + */ + @java.lang.Override + public java.lang.String getLogoUrl() { + java.lang.Object ref = logoUrl_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + logoUrl_ = s; + return s; + } + } + + /** + * + * + *
                    +   * The URL of the logo to be displayed for the addon. If not specified, the
                    +   * logo defaults to the logo in the common section of the manifest.
                    +   * 
                    + * + * string logo_url = 9; + * + * @return The bytes for logoUrl. + */ + @java.lang.Override + public com.google.protobuf.ByteString getLogoUrlBytes() { + java.lang.Object ref = logoUrl_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + logoUrl_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DARK_MODE_LOGO_URL_FIELD_NUMBER = 13; + + @SuppressWarnings("serial") + private volatile java.lang.Object darkModeLogoUrl_ = ""; + + /** + * + * + *
                    +   * A dark mode version of the logo_url.
                    +   * 
                    + * + * string dark_mode_logo_url = 13; + * + * @return The darkModeLogoUrl. + */ + @java.lang.Override + public java.lang.String getDarkModeLogoUrl() { + java.lang.Object ref = darkModeLogoUrl_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + darkModeLogoUrl_ = s; + return s; + } + } + + /** + * + * + *
                    +   * A dark mode version of the logo_url.
                    +   * 
                    + * + * string dark_mode_logo_url = 13; + * + * @return The bytes for darkModeLogoUrl. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDarkModeLogoUrlBytes() { + java.lang.Object ref = darkModeLogoUrl_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + darkModeLogoUrl_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_FLOW_FIELD_NUMBER = 10; + private int displayFlow_ = 0; + + /** + * + * + *
                    +   * The display flow the add-on will follow when launched.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web.DisplayFlow display_flow = 10 [deprecated = true]; + * + * + * @deprecated google.apps.script.type.meet.Web.display_flow is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=119 + * @return The enum numeric value on the wire for displayFlow. + */ + @java.lang.Override + @java.lang.Deprecated + public int getDisplayFlowValue() { + return displayFlow_; + } + + /** + * + * + *
                    +   * The display flow the add-on will follow when launched.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web.DisplayFlow display_flow = 10 [deprecated = true]; + * + * + * @deprecated google.apps.script.type.meet.Web.display_flow is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=119 + * @return The displayFlow. + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.apps.script.type.meet.Web.DisplayFlow getDisplayFlow() { + com.google.apps.script.type.meet.Web.DisplayFlow result = + com.google.apps.script.type.meet.Web.DisplayFlow.forNumber(displayFlow_); + return result == null ? com.google.apps.script.type.meet.Web.DisplayFlow.UNRECOGNIZED : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sidePanelUri_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, sidePanelUri_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(mainStageUri_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, mainStageUri_); + } + if (supportsScreenSharing_ != false) { + output.writeBool(3, supportsScreenSharing_); + } + if (supportsCollaboration_ != false) { + output.writeBool(4, supportsCollaboration_); + } + if (supportsPopOut_ != false) { + output.writeBool(5, supportsPopOut_); + } + for (int i = 0; i < hostOrigins_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, hostOrigins_.getRaw(i)); + } + if (openState_ != com.google.apps.script.type.meet.Web.State.STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(7, openState_); + } + if (supportsCollaborationHostControls_ != false) { + output.writeBool(8, supportsCollaborationHostControls_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(logoUrl_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 9, logoUrl_); + } + if (displayFlow_ + != com.google.apps.script.type.meet.Web.DisplayFlow.DISPLAY_FLOW_UNSPECIFIED.getNumber()) { + output.writeEnum(10, displayFlow_); + } + for (int i = 0; i < addOnOrigins_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 11, addOnOrigins_.getRaw(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sidePanelUrl_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 12, sidePanelUrl_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(darkModeLogoUrl_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 13, darkModeLogoUrl_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sidePanelUri_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, sidePanelUri_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(mainStageUri_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, mainStageUri_); + } + if (supportsScreenSharing_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, supportsScreenSharing_); + } + if (supportsCollaboration_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, supportsCollaboration_); + } + if (supportsPopOut_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(5, supportsPopOut_); + } + { + int dataSize = 0; + for (int i = 0; i < hostOrigins_.size(); i++) { + dataSize += computeStringSizeNoTag(hostOrigins_.getRaw(i)); + } + size += dataSize; + size += 1 * getHostOriginsList().size(); + } + if (openState_ != com.google.apps.script.type.meet.Web.State.STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, openState_); + } + if (supportsCollaborationHostControls_ != false) { + size += + com.google.protobuf.CodedOutputStream.computeBoolSize( + 8, supportsCollaborationHostControls_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(logoUrl_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(9, logoUrl_); + } + if (displayFlow_ + != com.google.apps.script.type.meet.Web.DisplayFlow.DISPLAY_FLOW_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(10, displayFlow_); + } + { + int dataSize = 0; + for (int i = 0; i < addOnOrigins_.size(); i++) { + dataSize += computeStringSizeNoTag(addOnOrigins_.getRaw(i)); + } + size += dataSize; + size += 1 * getAddOnOriginsList().size(); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sidePanelUrl_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(12, sidePanelUrl_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(darkModeLogoUrl_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(13, darkModeLogoUrl_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.apps.script.type.meet.Web)) { + return super.equals(obj); + } + com.google.apps.script.type.meet.Web other = (com.google.apps.script.type.meet.Web) obj; + + if (!getSidePanelUri().equals(other.getSidePanelUri())) return false; + if (!getSidePanelUrl().equals(other.getSidePanelUrl())) return false; + if (!getMainStageUri().equals(other.getMainStageUri())) return false; + if (getSupportsScreenSharing() != other.getSupportsScreenSharing()) return false; + if (getSupportsCollaboration() != other.getSupportsCollaboration()) return false; + if (getSupportsPopOut() != other.getSupportsPopOut()) return false; + if (!getHostOriginsList().equals(other.getHostOriginsList())) return false; + if (!getAddOnOriginsList().equals(other.getAddOnOriginsList())) return false; + if (openState_ != other.openState_) return false; + if (getSupportsCollaborationHostControls() != other.getSupportsCollaborationHostControls()) + return false; + if (!getLogoUrl().equals(other.getLogoUrl())) return false; + if (!getDarkModeLogoUrl().equals(other.getDarkModeLogoUrl())) return false; + if (displayFlow_ != other.displayFlow_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + SIDE_PANEL_URI_FIELD_NUMBER; + hash = (53 * hash) + getSidePanelUri().hashCode(); + hash = (37 * hash) + SIDE_PANEL_URL_FIELD_NUMBER; + hash = (53 * hash) + getSidePanelUrl().hashCode(); + hash = (37 * hash) + MAIN_STAGE_URI_FIELD_NUMBER; + hash = (53 * hash) + getMainStageUri().hashCode(); + hash = (37 * hash) + SUPPORTS_SCREEN_SHARING_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSupportsScreenSharing()); + hash = (37 * hash) + SUPPORTS_COLLABORATION_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSupportsCollaboration()); + hash = (37 * hash) + SUPPORTS_POP_OUT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSupportsPopOut()); + if (getHostOriginsCount() > 0) { + hash = (37 * hash) + HOST_ORIGINS_FIELD_NUMBER; + hash = (53 * hash) + getHostOriginsList().hashCode(); + } + if (getAddOnOriginsCount() > 0) { + hash = (37 * hash) + ADD_ON_ORIGINS_FIELD_NUMBER; + hash = (53 * hash) + getAddOnOriginsList().hashCode(); + } + hash = (37 * hash) + OPEN_STATE_FIELD_NUMBER; + hash = (53 * hash) + openState_; + hash = (37 * hash) + SUPPORTS_COLLABORATION_HOST_CONTROLS_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashBoolean(getSupportsCollaborationHostControls()); + hash = (37 * hash) + LOGO_URL_FIELD_NUMBER; + hash = (53 * hash) + getLogoUrl().hashCode(); + hash = (37 * hash) + DARK_MODE_LOGO_URL_FIELD_NUMBER; + hash = (53 * hash) + getDarkModeLogoUrl().hashCode(); + hash = (37 * hash) + DISPLAY_FLOW_FIELD_NUMBER; + hash = (53 * hash) + displayFlow_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.apps.script.type.meet.Web parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.apps.script.type.meet.Web parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.apps.script.type.meet.Web parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.apps.script.type.meet.Web parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.apps.script.type.meet.Web parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.apps.script.type.meet.Web parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.apps.script.type.meet.Web parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.apps.script.type.meet.Web parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.apps.script.type.meet.Web parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.apps.script.type.meet.Web parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.apps.script.type.meet.Web parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.apps.script.type.meet.Web parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.apps.script.type.meet.Web prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Details for addons that enhance the Meet web client.
                    +   * 
                    + * + * Protobuf type {@code google.apps.script.type.meet.Web} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.apps.script.type.meet.Web) + com.google.apps.script.type.meet.WebOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.apps.script.type.meet.MeetAddOnManifestProto + .internal_static_google_apps_script_type_meet_Web_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.apps.script.type.meet.MeetAddOnManifestProto + .internal_static_google_apps_script_type_meet_Web_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.apps.script.type.meet.Web.class, + com.google.apps.script.type.meet.Web.Builder.class); + } + + // Construct using com.google.apps.script.type.meet.Web.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + sidePanelUri_ = ""; + sidePanelUrl_ = ""; + mainStageUri_ = ""; + supportsScreenSharing_ = false; + supportsCollaboration_ = false; + supportsPopOut_ = false; + hostOrigins_ = com.google.protobuf.LazyStringArrayList.emptyList(); + addOnOrigins_ = com.google.protobuf.LazyStringArrayList.emptyList(); + openState_ = 0; + supportsCollaborationHostControls_ = false; + logoUrl_ = ""; + darkModeLogoUrl_ = ""; + displayFlow_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.apps.script.type.meet.MeetAddOnManifestProto + .internal_static_google_apps_script_type_meet_Web_descriptor; + } + + @java.lang.Override + public com.google.apps.script.type.meet.Web getDefaultInstanceForType() { + return com.google.apps.script.type.meet.Web.getDefaultInstance(); + } + + @java.lang.Override + public com.google.apps.script.type.meet.Web build() { + com.google.apps.script.type.meet.Web result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.apps.script.type.meet.Web buildPartial() { + com.google.apps.script.type.meet.Web result = new com.google.apps.script.type.meet.Web(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.apps.script.type.meet.Web result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.sidePanelUri_ = sidePanelUri_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.sidePanelUrl_ = sidePanelUrl_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.mainStageUri_ = mainStageUri_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.supportsScreenSharing_ = supportsScreenSharing_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.supportsCollaboration_ = supportsCollaboration_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.supportsPopOut_ = supportsPopOut_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + hostOrigins_.makeImmutable(); + result.hostOrigins_ = hostOrigins_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + addOnOrigins_.makeImmutable(); + result.addOnOrigins_ = addOnOrigins_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.openState_ = openState_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.supportsCollaborationHostControls_ = supportsCollaborationHostControls_; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + result.logoUrl_ = logoUrl_; + } + if (((from_bitField0_ & 0x00000800) != 0)) { + result.darkModeLogoUrl_ = darkModeLogoUrl_; + } + if (((from_bitField0_ & 0x00001000) != 0)) { + result.displayFlow_ = displayFlow_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.apps.script.type.meet.Web) { + return mergeFrom((com.google.apps.script.type.meet.Web) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.apps.script.type.meet.Web other) { + if (other == com.google.apps.script.type.meet.Web.getDefaultInstance()) return this; + if (!other.getSidePanelUri().isEmpty()) { + sidePanelUri_ = other.sidePanelUri_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getSidePanelUrl().isEmpty()) { + sidePanelUrl_ = other.sidePanelUrl_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getMainStageUri().isEmpty()) { + mainStageUri_ = other.mainStageUri_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.getSupportsScreenSharing() != false) { + setSupportsScreenSharing(other.getSupportsScreenSharing()); + } + if (other.getSupportsCollaboration() != false) { + setSupportsCollaboration(other.getSupportsCollaboration()); + } + if (other.getSupportsPopOut() != false) { + setSupportsPopOut(other.getSupportsPopOut()); + } + if (!other.hostOrigins_.isEmpty()) { + if (hostOrigins_.isEmpty()) { + hostOrigins_ = other.hostOrigins_; + bitField0_ |= 0x00000040; + } else { + ensureHostOriginsIsMutable(); + hostOrigins_.addAll(other.hostOrigins_); + } + onChanged(); + } + if (!other.addOnOrigins_.isEmpty()) { + if (addOnOrigins_.isEmpty()) { + addOnOrigins_ = other.addOnOrigins_; + bitField0_ |= 0x00000080; + } else { + ensureAddOnOriginsIsMutable(); + addOnOrigins_.addAll(other.addOnOrigins_); + } + onChanged(); + } + if (other.openState_ != 0) { + setOpenStateValue(other.getOpenStateValue()); + } + if (other.getSupportsCollaborationHostControls() != false) { + setSupportsCollaborationHostControls(other.getSupportsCollaborationHostControls()); + } + if (!other.getLogoUrl().isEmpty()) { + logoUrl_ = other.logoUrl_; + bitField0_ |= 0x00000400; + onChanged(); + } + if (!other.getDarkModeLogoUrl().isEmpty()) { + darkModeLogoUrl_ = other.darkModeLogoUrl_; + bitField0_ |= 0x00000800; + onChanged(); + } + if (other.displayFlow_ != 0) { + setDisplayFlowValue(other.getDisplayFlowValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + sidePanelUri_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + mainStageUri_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 18 + case 24: + { + supportsScreenSharing_ = input.readBool(); + bitField0_ |= 0x00000008; + break; + } // case 24 + case 32: + { + supportsCollaboration_ = input.readBool(); + bitField0_ |= 0x00000010; + break; + } // case 32 + case 40: + { + supportsPopOut_ = input.readBool(); + bitField0_ |= 0x00000020; + break; + } // case 40 + case 50: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureHostOriginsIsMutable(); + hostOrigins_.add(s); + break; + } // case 50 + case 56: + { + openState_ = input.readEnum(); + bitField0_ |= 0x00000100; + break; + } // case 56 + case 64: + { + supportsCollaborationHostControls_ = input.readBool(); + bitField0_ |= 0x00000200; + break; + } // case 64 + case 74: + { + logoUrl_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000400; + break; + } // case 74 + case 80: + { + displayFlow_ = input.readEnum(); + bitField0_ |= 0x00001000; + break; + } // case 80 + case 90: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureAddOnOriginsIsMutable(); + addOnOrigins_.add(s); + break; + } // case 90 + case 98: + { + sidePanelUrl_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 98 + case 106: + { + darkModeLogoUrl_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000800; + break; + } // case 106 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object sidePanelUri_ = ""; + + /** + * + * + *
                    +     * The URI for the side panel iframe.
                    +     * 
                    + * + * string side_panel_uri = 1 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.side_panel_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=77 + * @return The sidePanelUri. + */ + @java.lang.Deprecated + public java.lang.String getSidePanelUri() { + java.lang.Object ref = sidePanelUri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sidePanelUri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * The URI for the side panel iframe.
                    +     * 
                    + * + * string side_panel_uri = 1 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.side_panel_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=77 + * @return The bytes for sidePanelUri. + */ + @java.lang.Deprecated + public com.google.protobuf.ByteString getSidePanelUriBytes() { + java.lang.Object ref = sidePanelUri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sidePanelUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * The URI for the side panel iframe.
                    +     * 
                    + * + * string side_panel_uri = 1 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.side_panel_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=77 + * @param value The sidePanelUri to set. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder setSidePanelUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sidePanelUri_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The URI for the side panel iframe.
                    +     * 
                    + * + * string side_panel_uri = 1 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.side_panel_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=77 + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder clearSidePanelUri() { + sidePanelUri_ = getDefaultInstance().getSidePanelUri(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The URI for the side panel iframe.
                    +     * 
                    + * + * string side_panel_uri = 1 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.side_panel_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=77 + * @param value The bytes for sidePanelUri to set. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder setSidePanelUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sidePanelUri_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object sidePanelUrl_ = ""; + + /** + * + * + *
                    +     * The URL for the side panel iframe.
                    +     * 
                    + * + * string side_panel_url = 12; + * + * @return The sidePanelUrl. + */ + public java.lang.String getSidePanelUrl() { + java.lang.Object ref = sidePanelUrl_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sidePanelUrl_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * The URL for the side panel iframe.
                    +     * 
                    + * + * string side_panel_url = 12; + * + * @return The bytes for sidePanelUrl. + */ + public com.google.protobuf.ByteString getSidePanelUrlBytes() { + java.lang.Object ref = sidePanelUrl_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sidePanelUrl_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * The URL for the side panel iframe.
                    +     * 
                    + * + * string side_panel_url = 12; + * + * @param value The sidePanelUrl to set. + * @return This builder for chaining. + */ + public Builder setSidePanelUrl(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sidePanelUrl_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The URL for the side panel iframe.
                    +     * 
                    + * + * string side_panel_url = 12; + * + * @return This builder for chaining. + */ + public Builder clearSidePanelUrl() { + sidePanelUrl_ = getDefaultInstance().getSidePanelUrl(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The URL for the side panel iframe.
                    +     * 
                    + * + * string side_panel_url = 12; + * + * @param value The bytes for sidePanelUrl to set. + * @return This builder for chaining. + */ + public Builder setSidePanelUrlBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sidePanelUrl_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object mainStageUri_ = ""; + + /** + * + * + *
                    +     * The URI for the "main stage" iframe.
                    +     * 
                    + * + * string main_stage_uri = 2 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.main_stage_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=83 + * @return The mainStageUri. + */ + @java.lang.Deprecated + public java.lang.String getMainStageUri() { + java.lang.Object ref = mainStageUri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + mainStageUri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * The URI for the "main stage" iframe.
                    +     * 
                    + * + * string main_stage_uri = 2 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.main_stage_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=83 + * @return The bytes for mainStageUri. + */ + @java.lang.Deprecated + public com.google.protobuf.ByteString getMainStageUriBytes() { + java.lang.Object ref = mainStageUri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + mainStageUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * The URI for the "main stage" iframe.
                    +     * 
                    + * + * string main_stage_uri = 2 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.main_stage_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=83 + * @param value The mainStageUri to set. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder setMainStageUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + mainStageUri_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The URI for the "main stage" iframe.
                    +     * 
                    + * + * string main_stage_uri = 2 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.main_stage_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=83 + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder clearMainStageUri() { + mainStageUri_ = getDefaultInstance().getMainStageUri(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The URI for the "main stage" iframe.
                    +     * 
                    + * + * string main_stage_uri = 2 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.main_stage_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=83 + * @param value The bytes for mainStageUri to set. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder setMainStageUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + mainStageUri_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private boolean supportsScreenSharing_; + + /** + * + * + *
                    +     * Whether the addon supports screen sharing the main stage.
                    +     * 
                    + * + * bool supports_screen_sharing = 3; + * + * @return The supportsScreenSharing. + */ + @java.lang.Override + public boolean getSupportsScreenSharing() { + return supportsScreenSharing_; + } + + /** + * + * + *
                    +     * Whether the addon supports screen sharing the main stage.
                    +     * 
                    + * + * bool supports_screen_sharing = 3; + * + * @param value The supportsScreenSharing to set. + * @return This builder for chaining. + */ + public Builder setSupportsScreenSharing(boolean value) { + + supportsScreenSharing_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Whether the addon supports screen sharing the main stage.
                    +     * 
                    + * + * bool supports_screen_sharing = 3; + * + * @return This builder for chaining. + */ + public Builder clearSupportsScreenSharing() { + bitField0_ = (bitField0_ & ~0x00000008); + supportsScreenSharing_ = false; + onChanged(); + return this; + } + + private boolean supportsCollaboration_; + + /** + * + * + *
                    +     * Whether the addon supports collaboration or inviting others into the addon
                    +     * experience. This field is deprecated now, please use the top level field in
                    +     * MeetAddOnManifest.
                    +     * 
                    + * + * bool supports_collaboration = 4 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.supports_collaboration is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=91 + * @return The supportsCollaboration. + */ + @java.lang.Override + @java.lang.Deprecated + public boolean getSupportsCollaboration() { + return supportsCollaboration_; + } + + /** + * + * + *
                    +     * Whether the addon supports collaboration or inviting others into the addon
                    +     * experience. This field is deprecated now, please use the top level field in
                    +     * MeetAddOnManifest.
                    +     * 
                    + * + * bool supports_collaboration = 4 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.supports_collaboration is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=91 + * @param value The supportsCollaboration to set. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder setSupportsCollaboration(boolean value) { + + supportsCollaboration_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Whether the addon supports collaboration or inviting others into the addon
                    +     * experience. This field is deprecated now, please use the top level field in
                    +     * MeetAddOnManifest.
                    +     * 
                    + * + * bool supports_collaboration = 4 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.supports_collaboration is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=91 + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder clearSupportsCollaboration() { + bitField0_ = (bitField0_ & ~0x00000010); + supportsCollaboration_ = false; + onChanged(); + return this; + } + + private boolean supportsPopOut_; + + /** + * + * + *
                    +     * Whether the addon supports popping out to a browser PiP experience.
                    +     * 
                    + * + * bool supports_pop_out = 5; + * + * @return The supportsPopOut. + */ + @java.lang.Override + public boolean getSupportsPopOut() { + return supportsPopOut_; + } + + /** + * + * + *
                    +     * Whether the addon supports popping out to a browser PiP experience.
                    +     * 
                    + * + * bool supports_pop_out = 5; + * + * @param value The supportsPopOut to set. + * @return This builder for chaining. + */ + public Builder setSupportsPopOut(boolean value) { + + supportsPopOut_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Whether the addon supports popping out to a browser PiP experience.
                    +     * 
                    + * + * bool supports_pop_out = 5; + * + * @return This builder for chaining. + */ + public Builder clearSupportsPopOut() { + bitField0_ = (bitField0_ & ~0x00000020); + supportsPopOut_ = false; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList hostOrigins_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureHostOriginsIsMutable() { + if (!hostOrigins_.isModifiable()) { + hostOrigins_ = new com.google.protobuf.LazyStringArrayList(hostOrigins_); + } + bitField0_ |= 0x00000040; + } + + /** + * + * + *
                    +     * Deprecated, legacy name. Origins that should be added to the frame-src
                    +     * property of the iframe containing the third party site. Use add_on_origins
                    +     * instead.
                    +     * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @return A list containing the hostOrigins. + */ + @java.lang.Deprecated + public com.google.protobuf.ProtocolStringList getHostOriginsList() { + hostOrigins_.makeImmutable(); + return hostOrigins_; + } + + /** + * + * + *
                    +     * Deprecated, legacy name. Origins that should be added to the frame-src
                    +     * property of the iframe containing the third party site. Use add_on_origins
                    +     * instead.
                    +     * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @return The count of hostOrigins. + */ + @java.lang.Deprecated + public int getHostOriginsCount() { + return hostOrigins_.size(); + } + + /** + * + * + *
                    +     * Deprecated, legacy name. Origins that should be added to the frame-src
                    +     * property of the iframe containing the third party site. Use add_on_origins
                    +     * instead.
                    +     * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @param index The index of the element to return. + * @return The hostOrigins at the given index. + */ + @java.lang.Deprecated + public java.lang.String getHostOrigins(int index) { + return hostOrigins_.get(index); + } + + /** + * + * + *
                    +     * Deprecated, legacy name. Origins that should be added to the frame-src
                    +     * property of the iframe containing the third party site. Use add_on_origins
                    +     * instead.
                    +     * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @param index The index of the value to return. + * @return The bytes of the hostOrigins at the given index. + */ + @java.lang.Deprecated + public com.google.protobuf.ByteString getHostOriginsBytes(int index) { + return hostOrigins_.getByteString(index); + } + + /** + * + * + *
                    +     * Deprecated, legacy name. Origins that should be added to the frame-src
                    +     * property of the iframe containing the third party site. Use add_on_origins
                    +     * instead.
                    +     * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @param index The index to set the value at. + * @param value The hostOrigins to set. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder setHostOrigins(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureHostOriginsIsMutable(); + hostOrigins_.set(index, value); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Deprecated, legacy name. Origins that should be added to the frame-src
                    +     * property of the iframe containing the third party site. Use add_on_origins
                    +     * instead.
                    +     * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @param value The hostOrigins to add. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder addHostOrigins(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureHostOriginsIsMutable(); + hostOrigins_.add(value); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Deprecated, legacy name. Origins that should be added to the frame-src
                    +     * property of the iframe containing the third party site. Use add_on_origins
                    +     * instead.
                    +     * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @param values The hostOrigins to add. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder addAllHostOrigins(java.lang.Iterable values) { + ensureHostOriginsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, hostOrigins_); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Deprecated, legacy name. Origins that should be added to the frame-src
                    +     * property of the iframe containing the third party site. Use add_on_origins
                    +     * instead.
                    +     * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder clearHostOrigins() { + hostOrigins_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000040); + ; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Deprecated, legacy name. Origins that should be added to the frame-src
                    +     * property of the iframe containing the third party site. Use add_on_origins
                    +     * instead.
                    +     * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @param value The bytes of the hostOrigins to add. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder addHostOriginsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureHostOriginsIsMutable(); + hostOrigins_.add(value); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList addOnOrigins_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureAddOnOriginsIsMutable() { + if (!addOnOrigins_.isModifiable()) { + addOnOrigins_ = new com.google.protobuf.LazyStringArrayList(addOnOrigins_); + } + bitField0_ |= 0x00000080; + } + + /** + * + * + *
                    +     * Origins that should be added to the frame-src property of the iframe
                    +     * containing the third party site.
                    +     * 
                    + * + * repeated string add_on_origins = 11; + * + * @return A list containing the addOnOrigins. + */ + public com.google.protobuf.ProtocolStringList getAddOnOriginsList() { + addOnOrigins_.makeImmutable(); + return addOnOrigins_; + } + + /** + * + * + *
                    +     * Origins that should be added to the frame-src property of the iframe
                    +     * containing the third party site.
                    +     * 
                    + * + * repeated string add_on_origins = 11; + * + * @return The count of addOnOrigins. + */ + public int getAddOnOriginsCount() { + return addOnOrigins_.size(); + } + + /** + * + * + *
                    +     * Origins that should be added to the frame-src property of the iframe
                    +     * containing the third party site.
                    +     * 
                    + * + * repeated string add_on_origins = 11; + * + * @param index The index of the element to return. + * @return The addOnOrigins at the given index. + */ + public java.lang.String getAddOnOrigins(int index) { + return addOnOrigins_.get(index); + } + + /** + * + * + *
                    +     * Origins that should be added to the frame-src property of the iframe
                    +     * containing the third party site.
                    +     * 
                    + * + * repeated string add_on_origins = 11; + * + * @param index The index of the value to return. + * @return The bytes of the addOnOrigins at the given index. + */ + public com.google.protobuf.ByteString getAddOnOriginsBytes(int index) { + return addOnOrigins_.getByteString(index); + } + + /** + * + * + *
                    +     * Origins that should be added to the frame-src property of the iframe
                    +     * containing the third party site.
                    +     * 
                    + * + * repeated string add_on_origins = 11; + * + * @param index The index to set the value at. + * @param value The addOnOrigins to set. + * @return This builder for chaining. + */ + public Builder setAddOnOrigins(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureAddOnOriginsIsMutable(); + addOnOrigins_.set(index, value); + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Origins that should be added to the frame-src property of the iframe
                    +     * containing the third party site.
                    +     * 
                    + * + * repeated string add_on_origins = 11; + * + * @param value The addOnOrigins to add. + * @return This builder for chaining. + */ + public Builder addAddOnOrigins(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureAddOnOriginsIsMutable(); + addOnOrigins_.add(value); + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Origins that should be added to the frame-src property of the iframe
                    +     * containing the third party site.
                    +     * 
                    + * + * repeated string add_on_origins = 11; + * + * @param values The addOnOrigins to add. + * @return This builder for chaining. + */ + public Builder addAllAddOnOrigins(java.lang.Iterable values) { + ensureAddOnOriginsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, addOnOrigins_); + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Origins that should be added to the frame-src property of the iframe
                    +     * containing the third party site.
                    +     * 
                    + * + * repeated string add_on_origins = 11; + * + * @return This builder for chaining. + */ + public Builder clearAddOnOrigins() { + addOnOrigins_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000080); + ; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Origins that should be added to the frame-src property of the iframe
                    +     * containing the third party site.
                    +     * 
                    + * + * repeated string add_on_origins = 11; + * + * @param value The bytes of the addOnOrigins to add. + * @return This builder for chaining. + */ + public Builder addAddOnOriginsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureAddOnOriginsIsMutable(); + addOnOrigins_.add(value); + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + private int openState_ = 0; + + /** + * + * + *
                    +     * The initial state when the addon is opened.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web.State open_state = 7; + * + * @return The enum numeric value on the wire for openState. + */ + @java.lang.Override + public int getOpenStateValue() { + return openState_; + } + + /** + * + * + *
                    +     * The initial state when the addon is opened.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web.State open_state = 7; + * + * @param value The enum numeric value on the wire for openState to set. + * @return This builder for chaining. + */ + public Builder setOpenStateValue(int value) { + openState_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The initial state when the addon is opened.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web.State open_state = 7; + * + * @return The openState. + */ + @java.lang.Override + public com.google.apps.script.type.meet.Web.State getOpenState() { + com.google.apps.script.type.meet.Web.State result = + com.google.apps.script.type.meet.Web.State.forNumber(openState_); + return result == null ? com.google.apps.script.type.meet.Web.State.UNRECOGNIZED : result; + } + + /** + * + * + *
                    +     * The initial state when the addon is opened.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web.State open_state = 7; + * + * @param value The openState to set. + * @return This builder for chaining. + */ + public Builder setOpenState(com.google.apps.script.type.meet.Web.State value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000100; + openState_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The initial state when the addon is opened.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web.State open_state = 7; + * + * @return This builder for chaining. + */ + public Builder clearOpenState() { + bitField0_ = (bitField0_ & ~0x00000100); + openState_ = 0; + onChanged(); + return this; + } + + private boolean supportsCollaborationHostControls_; + + /** + * + * + *
                    +     * Whether the collaboration add-on supports host controls.
                    +     * 
                    + * + * bool supports_collaboration_host_controls = 8; + * + * @return The supportsCollaborationHostControls. + */ + @java.lang.Override + public boolean getSupportsCollaborationHostControls() { + return supportsCollaborationHostControls_; + } + + /** + * + * + *
                    +     * Whether the collaboration add-on supports host controls.
                    +     * 
                    + * + * bool supports_collaboration_host_controls = 8; + * + * @param value The supportsCollaborationHostControls to set. + * @return This builder for chaining. + */ + public Builder setSupportsCollaborationHostControls(boolean value) { + + supportsCollaborationHostControls_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Whether the collaboration add-on supports host controls.
                    +     * 
                    + * + * bool supports_collaboration_host_controls = 8; + * + * @return This builder for chaining. + */ + public Builder clearSupportsCollaborationHostControls() { + bitField0_ = (bitField0_ & ~0x00000200); + supportsCollaborationHostControls_ = false; + onChanged(); + return this; + } + + private java.lang.Object logoUrl_ = ""; + + /** + * + * + *
                    +     * The URL of the logo to be displayed for the addon. If not specified, the
                    +     * logo defaults to the logo in the common section of the manifest.
                    +     * 
                    + * + * string logo_url = 9; + * + * @return The logoUrl. + */ + public java.lang.String getLogoUrl() { + java.lang.Object ref = logoUrl_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + logoUrl_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * The URL of the logo to be displayed for the addon. If not specified, the
                    +     * logo defaults to the logo in the common section of the manifest.
                    +     * 
                    + * + * string logo_url = 9; + * + * @return The bytes for logoUrl. + */ + public com.google.protobuf.ByteString getLogoUrlBytes() { + java.lang.Object ref = logoUrl_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + logoUrl_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * The URL of the logo to be displayed for the addon. If not specified, the
                    +     * logo defaults to the logo in the common section of the manifest.
                    +     * 
                    + * + * string logo_url = 9; + * + * @param value The logoUrl to set. + * @return This builder for chaining. + */ + public Builder setLogoUrl(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + logoUrl_ = value; + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The URL of the logo to be displayed for the addon. If not specified, the
                    +     * logo defaults to the logo in the common section of the manifest.
                    +     * 
                    + * + * string logo_url = 9; + * + * @return This builder for chaining. + */ + public Builder clearLogoUrl() { + logoUrl_ = getDefaultInstance().getLogoUrl(); + bitField0_ = (bitField0_ & ~0x00000400); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The URL of the logo to be displayed for the addon. If not specified, the
                    +     * logo defaults to the logo in the common section of the manifest.
                    +     * 
                    + * + * string logo_url = 9; + * + * @param value The bytes for logoUrl to set. + * @return This builder for chaining. + */ + public Builder setLogoUrlBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + logoUrl_ = value; + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + + private java.lang.Object darkModeLogoUrl_ = ""; + + /** + * + * + *
                    +     * A dark mode version of the logo_url.
                    +     * 
                    + * + * string dark_mode_logo_url = 13; + * + * @return The darkModeLogoUrl. + */ + public java.lang.String getDarkModeLogoUrl() { + java.lang.Object ref = darkModeLogoUrl_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + darkModeLogoUrl_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * A dark mode version of the logo_url.
                    +     * 
                    + * + * string dark_mode_logo_url = 13; + * + * @return The bytes for darkModeLogoUrl. + */ + public com.google.protobuf.ByteString getDarkModeLogoUrlBytes() { + java.lang.Object ref = darkModeLogoUrl_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + darkModeLogoUrl_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * A dark mode version of the logo_url.
                    +     * 
                    + * + * string dark_mode_logo_url = 13; + * + * @param value The darkModeLogoUrl to set. + * @return This builder for chaining. + */ + public Builder setDarkModeLogoUrl(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + darkModeLogoUrl_ = value; + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * A dark mode version of the logo_url.
                    +     * 
                    + * + * string dark_mode_logo_url = 13; + * + * @return This builder for chaining. + */ + public Builder clearDarkModeLogoUrl() { + darkModeLogoUrl_ = getDefaultInstance().getDarkModeLogoUrl(); + bitField0_ = (bitField0_ & ~0x00000800); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * A dark mode version of the logo_url.
                    +     * 
                    + * + * string dark_mode_logo_url = 13; + * + * @param value The bytes for darkModeLogoUrl to set. + * @return This builder for chaining. + */ + public Builder setDarkModeLogoUrlBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + darkModeLogoUrl_ = value; + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + private int displayFlow_ = 0; + + /** + * + * + *
                    +     * The display flow the add-on will follow when launched.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web.DisplayFlow display_flow = 10 [deprecated = true]; + * + * + * @deprecated google.apps.script.type.meet.Web.display_flow is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=119 + * @return The enum numeric value on the wire for displayFlow. + */ + @java.lang.Override + @java.lang.Deprecated + public int getDisplayFlowValue() { + return displayFlow_; + } + + /** + * + * + *
                    +     * The display flow the add-on will follow when launched.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web.DisplayFlow display_flow = 10 [deprecated = true]; + * + * + * @deprecated google.apps.script.type.meet.Web.display_flow is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=119 + * @param value The enum numeric value on the wire for displayFlow to set. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder setDisplayFlowValue(int value) { + displayFlow_ = value; + bitField0_ |= 0x00001000; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The display flow the add-on will follow when launched.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web.DisplayFlow display_flow = 10 [deprecated = true]; + * + * + * @deprecated google.apps.script.type.meet.Web.display_flow is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=119 + * @return The displayFlow. + */ + @java.lang.Override + @java.lang.Deprecated + public com.google.apps.script.type.meet.Web.DisplayFlow getDisplayFlow() { + com.google.apps.script.type.meet.Web.DisplayFlow result = + com.google.apps.script.type.meet.Web.DisplayFlow.forNumber(displayFlow_); + return result == null + ? com.google.apps.script.type.meet.Web.DisplayFlow.UNRECOGNIZED + : result; + } + + /** + * + * + *
                    +     * The display flow the add-on will follow when launched.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web.DisplayFlow display_flow = 10 [deprecated = true]; + * + * + * @deprecated google.apps.script.type.meet.Web.display_flow is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=119 + * @param value The displayFlow to set. + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder setDisplayFlow(com.google.apps.script.type.meet.Web.DisplayFlow value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00001000; + displayFlow_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * The display flow the add-on will follow when launched.
                    +     * 
                    + * + * .google.apps.script.type.meet.Web.DisplayFlow display_flow = 10 [deprecated = true]; + * + * + * @deprecated google.apps.script.type.meet.Web.display_flow is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=119 + * @return This builder for chaining. + */ + @java.lang.Deprecated + public Builder clearDisplayFlow() { + bitField0_ = (bitField0_ & ~0x00001000); + displayFlow_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.apps.script.type.meet.Web) + } + + // @@protoc_insertion_point(class_scope:google.apps.script.type.meet.Web) + private static final com.google.apps.script.type.meet.Web DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.apps.script.type.meet.Web(); + } + + public static com.google.apps.script.type.meet.Web getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Web parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.apps.script.type.meet.Web getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/WebOrBuilder.java b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/WebOrBuilder.java new file mode 100644 index 000000000000..c6b1ee0f8279 --- /dev/null +++ b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/java/com/google/apps/script/type/meet/WebOrBuilder.java @@ -0,0 +1,421 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/apps/script/type/meet/meet_addon_manifest.proto +// Protobuf Java Version: 4.33.6 + +package com.google.apps.script.type.meet; + +@com.google.protobuf.Generated +public interface WebOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.apps.script.type.meet.Web) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * The URI for the side panel iframe.
                    +   * 
                    + * + * string side_panel_uri = 1 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.side_panel_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=77 + * @return The sidePanelUri. + */ + @java.lang.Deprecated + java.lang.String getSidePanelUri(); + + /** + * + * + *
                    +   * The URI for the side panel iframe.
                    +   * 
                    + * + * string side_panel_uri = 1 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.side_panel_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=77 + * @return The bytes for sidePanelUri. + */ + @java.lang.Deprecated + com.google.protobuf.ByteString getSidePanelUriBytes(); + + /** + * + * + *
                    +   * The URL for the side panel iframe.
                    +   * 
                    + * + * string side_panel_url = 12; + * + * @return The sidePanelUrl. + */ + java.lang.String getSidePanelUrl(); + + /** + * + * + *
                    +   * The URL for the side panel iframe.
                    +   * 
                    + * + * string side_panel_url = 12; + * + * @return The bytes for sidePanelUrl. + */ + com.google.protobuf.ByteString getSidePanelUrlBytes(); + + /** + * + * + *
                    +   * The URI for the "main stage" iframe.
                    +   * 
                    + * + * string main_stage_uri = 2 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.main_stage_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=83 + * @return The mainStageUri. + */ + @java.lang.Deprecated + java.lang.String getMainStageUri(); + + /** + * + * + *
                    +   * The URI for the "main stage" iframe.
                    +   * 
                    + * + * string main_stage_uri = 2 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.main_stage_uri is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=83 + * @return The bytes for mainStageUri. + */ + @java.lang.Deprecated + com.google.protobuf.ByteString getMainStageUriBytes(); + + /** + * + * + *
                    +   * Whether the addon supports screen sharing the main stage.
                    +   * 
                    + * + * bool supports_screen_sharing = 3; + * + * @return The supportsScreenSharing. + */ + boolean getSupportsScreenSharing(); + + /** + * + * + *
                    +   * Whether the addon supports collaboration or inviting others into the addon
                    +   * experience. This field is deprecated now, please use the top level field in
                    +   * MeetAddOnManifest.
                    +   * 
                    + * + * bool supports_collaboration = 4 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.supports_collaboration is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=91 + * @return The supportsCollaboration. + */ + @java.lang.Deprecated + boolean getSupportsCollaboration(); + + /** + * + * + *
                    +   * Whether the addon supports popping out to a browser PiP experience.
                    +   * 
                    + * + * bool supports_pop_out = 5; + * + * @return The supportsPopOut. + */ + boolean getSupportsPopOut(); + + /** + * + * + *
                    +   * Deprecated, legacy name. Origins that should be added to the frame-src
                    +   * property of the iframe containing the third party site. Use add_on_origins
                    +   * instead.
                    +   * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @return A list containing the hostOrigins. + */ + @java.lang.Deprecated + java.util.List getHostOriginsList(); + + /** + * + * + *
                    +   * Deprecated, legacy name. Origins that should be added to the frame-src
                    +   * property of the iframe containing the third party site. Use add_on_origins
                    +   * instead.
                    +   * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @return The count of hostOrigins. + */ + @java.lang.Deprecated + int getHostOriginsCount(); + + /** + * + * + *
                    +   * Deprecated, legacy name. Origins that should be added to the frame-src
                    +   * property of the iframe containing the third party site. Use add_on_origins
                    +   * instead.
                    +   * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @param index The index of the element to return. + * @return The hostOrigins at the given index. + */ + @java.lang.Deprecated + java.lang.String getHostOrigins(int index); + + /** + * + * + *
                    +   * Deprecated, legacy name. Origins that should be added to the frame-src
                    +   * property of the iframe containing the third party site. Use add_on_origins
                    +   * instead.
                    +   * 
                    + * + * repeated string host_origins = 6 [deprecated = true]; + * + * @deprecated google.apps.script.type.meet.Web.host_origins is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=99 + * @param index The index of the value to return. + * @return The bytes of the hostOrigins at the given index. + */ + @java.lang.Deprecated + com.google.protobuf.ByteString getHostOriginsBytes(int index); + + /** + * + * + *
                    +   * Origins that should be added to the frame-src property of the iframe
                    +   * containing the third party site.
                    +   * 
                    + * + * repeated string add_on_origins = 11; + * + * @return A list containing the addOnOrigins. + */ + java.util.List getAddOnOriginsList(); + + /** + * + * + *
                    +   * Origins that should be added to the frame-src property of the iframe
                    +   * containing the third party site.
                    +   * 
                    + * + * repeated string add_on_origins = 11; + * + * @return The count of addOnOrigins. + */ + int getAddOnOriginsCount(); + + /** + * + * + *
                    +   * Origins that should be added to the frame-src property of the iframe
                    +   * containing the third party site.
                    +   * 
                    + * + * repeated string add_on_origins = 11; + * + * @param index The index of the element to return. + * @return The addOnOrigins at the given index. + */ + java.lang.String getAddOnOrigins(int index); + + /** + * + * + *
                    +   * Origins that should be added to the frame-src property of the iframe
                    +   * containing the third party site.
                    +   * 
                    + * + * repeated string add_on_origins = 11; + * + * @param index The index of the value to return. + * @return The bytes of the addOnOrigins at the given index. + */ + com.google.protobuf.ByteString getAddOnOriginsBytes(int index); + + /** + * + * + *
                    +   * The initial state when the addon is opened.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web.State open_state = 7; + * + * @return The enum numeric value on the wire for openState. + */ + int getOpenStateValue(); + + /** + * + * + *
                    +   * The initial state when the addon is opened.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web.State open_state = 7; + * + * @return The openState. + */ + com.google.apps.script.type.meet.Web.State getOpenState(); + + /** + * + * + *
                    +   * Whether the collaboration add-on supports host controls.
                    +   * 
                    + * + * bool supports_collaboration_host_controls = 8; + * + * @return The supportsCollaborationHostControls. + */ + boolean getSupportsCollaborationHostControls(); + + /** + * + * + *
                    +   * The URL of the logo to be displayed for the addon. If not specified, the
                    +   * logo defaults to the logo in the common section of the manifest.
                    +   * 
                    + * + * string logo_url = 9; + * + * @return The logoUrl. + */ + java.lang.String getLogoUrl(); + + /** + * + * + *
                    +   * The URL of the logo to be displayed for the addon. If not specified, the
                    +   * logo defaults to the logo in the common section of the manifest.
                    +   * 
                    + * + * string logo_url = 9; + * + * @return The bytes for logoUrl. + */ + com.google.protobuf.ByteString getLogoUrlBytes(); + + /** + * + * + *
                    +   * A dark mode version of the logo_url.
                    +   * 
                    + * + * string dark_mode_logo_url = 13; + * + * @return The darkModeLogoUrl. + */ + java.lang.String getDarkModeLogoUrl(); + + /** + * + * + *
                    +   * A dark mode version of the logo_url.
                    +   * 
                    + * + * string dark_mode_logo_url = 13; + * + * @return The bytes for darkModeLogoUrl. + */ + com.google.protobuf.ByteString getDarkModeLogoUrlBytes(); + + /** + * + * + *
                    +   * The display flow the add-on will follow when launched.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web.DisplayFlow display_flow = 10 [deprecated = true]; + * + * + * @deprecated google.apps.script.type.meet.Web.display_flow is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=119 + * @return The enum numeric value on the wire for displayFlow. + */ + @java.lang.Deprecated + int getDisplayFlowValue(); + + /** + * + * + *
                    +   * The display flow the add-on will follow when launched.
                    +   * 
                    + * + * .google.apps.script.type.meet.Web.DisplayFlow display_flow = 10 [deprecated = true]; + * + * + * @deprecated google.apps.script.type.meet.Web.display_flow is deprecated. See + * google/apps/script/type/meet/meet_addon_manifest.proto;l=119 + * @return The displayFlow. + */ + @java.lang.Deprecated + com.google.apps.script.type.meet.Web.DisplayFlow getDisplayFlow(); +} diff --git a/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/proto/google/apps/script/type/meet/meet_addon_manifest.proto b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/proto/google/apps/script/type/meet/meet_addon_manifest.proto new file mode 100644 index 000000000000..eefcf334676b --- /dev/null +++ b/java-gsuite-addons/proto-google-apps-script-type-protos/src/main/proto/google/apps/script/type/meet/meet_addon_manifest.proto @@ -0,0 +1,121 @@ +// Copyright 2026 Google LLC +// +// 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. + +syntax = "proto3"; + +package google.apps.script.type.meet; + +import "google/apps/script/type/extension_point.proto"; + +option csharp_namespace = "Google.Apps.Script.Type.Meet"; +option go_package = "google.golang.org/genproto/googleapis/apps/script/type/meet"; +option java_multiple_files = true; +option java_outer_classname = "MeetAddOnManifestProto"; +option java_package = "com.google.apps.script.type.meet"; +option php_namespace = "Google\\Apps\\Script\\Type\\Meet"; +option ruby_package = "Google::Apps::Script::Type::Meet"; + +// Manifest section specific to Meet add-ons. + +// Meet add-on manifest. +message MeetAddOnManifest { + // If present, this overrides the configuration from + // `addOns.common.homepageTrigger`. + google.apps.script.type.HomepageExtensionPoint homepage_trigger = 2; + + // Details for addons that enhance the Meet web client. + Web web = 3; + + // A link to the terms of service for the add-on, if any should be shown. + optional string terms_uri = 6; + + // Whether the addon supports collaboration or inviting others into the addon + // experience. + bool supports_collaboration = 7; +} + +// Details for addons that enhance the Meet web client. +message Web { + // Enum for specifying initial addon opening state. + enum State { + // Initial state has not been specified with the addon. + STATE_UNSPECIFIED = 0; + + // The addon opens with only the side panel active. + SIDE_PANEL_ONLY = 1; + + // The addon opens with only the main stage active. + MAIN_STAGE_ONLY = 2; + + // The addon opens with both the side panel and the main stage active. + SIDE_PANEL_AND_MAIN_STAGE = 3; + } + + // Enum for specifying the display flow the add-on will follow when launched + enum DisplayFlow { + // Display flow has not been specified. + DISPLAY_FLOW_UNSPECIFIED = 0; + + // Add-on should launch in the "focus" display flow. + FOCUS = 1; + + // Add-on should launch in the "augment" display flow. + AUGMENT = 2; + } + + // The URI for the side panel iframe. + string side_panel_uri = 1 [deprecated = true]; + + // The URL for the side panel iframe. + string side_panel_url = 12; + + // The URI for the "main stage" iframe. + string main_stage_uri = 2 [deprecated = true]; + + // Whether the addon supports screen sharing the main stage. + bool supports_screen_sharing = 3; + + // Whether the addon supports collaboration or inviting others into the addon + // experience. This field is deprecated now, please use the top level field in + // MeetAddOnManifest. + bool supports_collaboration = 4 [deprecated = true]; + + // Whether the addon supports popping out to a browser PiP experience. + bool supports_pop_out = 5; + + // Deprecated, legacy name. Origins that should be added to the frame-src + // property of the iframe containing the third party site. Use add_on_origins + // instead. + repeated string host_origins = 6 [deprecated = true]; + + // Origins that should be added to the frame-src property of the iframe + // containing the third party site. + repeated string add_on_origins = 11; + + // The initial state when the addon is opened. + State open_state = 7; + + // Whether the collaboration add-on supports host controls. + bool supports_collaboration_host_controls = 8; + + // The URL of the logo to be displayed for the addon. If not specified, the + // logo defaults to the logo in the common section of the manifest. + string logo_url = 9; + + // A dark mode version of the logo_url. + string dark_mode_logo_url = 13; + + // The display flow the add-on will follow when launched. + DisplayFlow display_flow = 10 [deprecated = true]; +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppCommand.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppCommand.java new file mode 100644 index 000000000000..5ca76c4914dc --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppCommand.java @@ -0,0 +1,1763 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * Configuration for an [app
                    + * command](https://developers.google.com/workspace/chat/commands).
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.AppCommand} + */ +@com.google.protobuf.Generated +public final class AppCommand extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.AppCommand) + AppCommandOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AppCommand"); + } + + // Use AppCommand.newBuilder() to construct. + private AppCommand(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AppCommand() { + commandType_ = 0; + command_ = ""; + displayName_ = ""; + description_ = ""; + loadingNotificationMessage_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppCommand_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppCommand_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.AppCommand.class, + com.google.cloud.gsuiteaddons.v1.AppCommand.Builder.class); + } + + /** + * + * + *
                    +   * The type of the App Command.
                    +   * 
                    + * + * Protobuf enum {@code google.cloud.gsuiteaddons.v1.AppCommand.CommandType} + */ + public enum CommandType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                    +     * Default value. Unspecified.
                    +     * 
                    + * + * COMMAND_TYPE_UNSPECIFIED = 0; + */ + COMMAND_TYPE_UNSPECIFIED(0), + /** + * + * + *
                    +     * A command invoked by typing a '/' followed by the command name.
                    +     * It may accept additional arguments in the message text.
                    +     * 
                    + * + * SLASH_COMMAND = 1; + */ + SLASH_COMMAND(1), + /** + * + * + *
                    +     * A quick command invoked from the message compose context menu.
                    +     * Quick commands do not accept additional arguments.
                    +     * 
                    + * + * QUICK_COMMAND = 2; + */ + QUICK_COMMAND(2), + /** + * + * + *
                    +     * A command invoked from a message context menu.
                    +     * 
                    + * + * MESSAGE_ACTION = 3; + */ + MESSAGE_ACTION(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "CommandType"); + } + + /** + * + * + *
                    +     * Default value. Unspecified.
                    +     * 
                    + * + * COMMAND_TYPE_UNSPECIFIED = 0; + */ + public static final int COMMAND_TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                    +     * A command invoked by typing a '/' followed by the command name.
                    +     * It may accept additional arguments in the message text.
                    +     * 
                    + * + * SLASH_COMMAND = 1; + */ + public static final int SLASH_COMMAND_VALUE = 1; + + /** + * + * + *
                    +     * A quick command invoked from the message compose context menu.
                    +     * Quick commands do not accept additional arguments.
                    +     * 
                    + * + * QUICK_COMMAND = 2; + */ + public static final int QUICK_COMMAND_VALUE = 2; + + /** + * + * + *
                    +     * A command invoked from a message context menu.
                    +     * 
                    + * + * MESSAGE_ACTION = 3; + */ + public static final int MESSAGE_ACTION_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static CommandType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static CommandType forNumber(int value) { + switch (value) { + case 0: + return COMMAND_TYPE_UNSPECIFIED; + case 1: + return SLASH_COMMAND; + case 2: + return QUICK_COMMAND; + case 3: + return MESSAGE_ACTION; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public CommandType findValueByNumber(int number) { + return CommandType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.AppCommand.getDescriptor().getEnumTypes().get(0); + } + + private static final CommandType[] VALUES = values(); + + public static CommandType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private CommandType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.gsuiteaddons.v1.AppCommand.CommandType) + } + + public static final int COMMAND_TYPE_FIELD_NUMBER = 1; + private int commandType_ = 0; + + /** + * + * + *
                    +   * Required. The type of this command.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppCommand.CommandType command_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for commandType. + */ + @java.lang.Override + public int getCommandTypeValue() { + return commandType_; + } + + /** + * + * + *
                    +   * Required. The type of this command.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppCommand.CommandType command_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The commandType. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType getCommandType() { + com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType result = + com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType.forNumber(commandType_); + return result == null + ? com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType.UNRECOGNIZED + : result; + } + + public static final int COMMAND_ID_FIELD_NUMBER = 2; + private int commandId_ = 0; + + /** + * + * + *
                    +   * Required. The ID of the command (1-1000). Must be unique within the app.
                    +   * 
                    + * + * int32 command_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The commandId. + */ + @java.lang.Override + public int getCommandId() { + return commandId_; + } + + public static final int COMMAND_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object command_ = ""; + + /** + * + * + *
                    +   * Optional. The name of the command. Required for SLASH_COMMAND, do not set
                    +   * for other command types. Must start with a "/", e.g., "/command".
                    +   * 
                    + * + * string command = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The command. + */ + @java.lang.Override + public java.lang.String getCommand() { + java.lang.Object ref = command_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + command_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Optional. The name of the command. Required for SLASH_COMMAND, do not set
                    +   * for other command types. Must start with a "/", e.g., "/command".
                    +   * 
                    + * + * string command = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for command. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCommandBytes() { + java.lang.Object ref = command_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + command_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object displayName_ = ""; + + /** + * + * + *
                    +   * Optional. The user-friendly display name of the command. Required for
                    +   * MESSAGE_ACTION and QUICK_COMMAND, do not set for SLASH_COMMAND.
                    +   * 
                    + * + * string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Optional. The user-friendly display name of the command. Required for
                    +   * MESSAGE_ACTION and QUICK_COMMAND, do not set for SLASH_COMMAND.
                    +   * 
                    + * + * string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object description_ = ""; + + /** + * + * + *
                    +   * Required. A short description of the command.
                    +   * 
                    + * + * string description = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. A short description of the command.
                    +   * 
                    + * + * string description = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DIALOG_ENABLED_FIELD_NUMBER = 6; + private boolean dialogEnabled_ = false; + + /** + * + * + *
                    +   * Optional. Whether this command should trigger a dialog. Defaults to
                    +   * `false`, if not specified.
                    +   * 
                    + * + * bool dialog_enabled = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The dialogEnabled. + */ + @java.lang.Override + public boolean getDialogEnabled() { + return dialogEnabled_; + } + + public static final int LOADING_NOTIFICATION_MESSAGE_FIELD_NUMBER = 7; + + @SuppressWarnings("serial") + private volatile java.lang.Object loadingNotificationMessage_ = ""; + + /** + * + * + *
                    +   * Optional. A notification to be sent to the user when they trigger the
                    +   * message action. Only supported for MESSAGE_ACTION commands.
                    +   * 
                    + * + * string loading_notification_message = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The loadingNotificationMessage. + */ + @java.lang.Override + public java.lang.String getLoadingNotificationMessage() { + java.lang.Object ref = loadingNotificationMessage_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + loadingNotificationMessage_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Optional. A notification to be sent to the user when they trigger the
                    +   * message action. Only supported for MESSAGE_ACTION commands.
                    +   * 
                    + * + * string loading_notification_message = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for loadingNotificationMessage. + */ + @java.lang.Override + public com.google.protobuf.ByteString getLoadingNotificationMessageBytes() { + java.lang.Object ref = loadingNotificationMessage_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + loadingNotificationMessage_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (commandType_ + != com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType.COMMAND_TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, commandType_); + } + if (commandId_ != 0) { + output.writeInt32(2, commandId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(command_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, command_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, displayName_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, description_); + } + if (dialogEnabled_ != false) { + output.writeBool(6, dialogEnabled_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(loadingNotificationMessage_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 7, loadingNotificationMessage_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (commandType_ + != com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType.COMMAND_TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, commandType_); + } + if (commandId_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, commandId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(command_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, command_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, displayName_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, description_); + } + if (dialogEnabled_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, dialogEnabled_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(loadingNotificationMessage_)) { + size += + com.google.protobuf.GeneratedMessage.computeStringSize(7, loadingNotificationMessage_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.AppCommand)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.AppCommand other = + (com.google.cloud.gsuiteaddons.v1.AppCommand) obj; + + if (commandType_ != other.commandType_) return false; + if (getCommandId() != other.getCommandId()) return false; + if (!getCommand().equals(other.getCommand())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (getDialogEnabled() != other.getDialogEnabled()) return false; + if (!getLoadingNotificationMessage().equals(other.getLoadingNotificationMessage())) + return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + COMMAND_TYPE_FIELD_NUMBER; + hash = (53 * hash) + commandType_; + hash = (37 * hash) + COMMAND_ID_FIELD_NUMBER; + hash = (53 * hash) + getCommandId(); + hash = (37 * hash) + COMMAND_FIELD_NUMBER; + hash = (53 * hash) + getCommand().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + hash = (37 * hash) + DIALOG_ENABLED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getDialogEnabled()); + hash = (37 * hash) + LOADING_NOTIFICATION_MESSAGE_FIELD_NUMBER; + hash = (53 * hash) + getLoadingNotificationMessage().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.gsuiteaddons.v1.AppCommand prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Configuration for an [app
                    +   * command](https://developers.google.com/workspace/chat/commands).
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.AppCommand} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.AppCommand) + com.google.cloud.gsuiteaddons.v1.AppCommandOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppCommand_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppCommand_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.AppCommand.class, + com.google.cloud.gsuiteaddons.v1.AppCommand.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.AppCommand.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + commandType_ = 0; + commandId_ = 0; + command_ = ""; + displayName_ = ""; + description_ = ""; + dialogEnabled_ = false; + loadingNotificationMessage_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppCommand_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppCommand getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.AppCommand.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppCommand build() { + com.google.cloud.gsuiteaddons.v1.AppCommand result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppCommand buildPartial() { + com.google.cloud.gsuiteaddons.v1.AppCommand result = + new com.google.cloud.gsuiteaddons.v1.AppCommand(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.AppCommand result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.commandType_ = commandType_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.commandId_ = commandId_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.command_ = command_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.displayName_ = displayName_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.description_ = description_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.dialogEnabled_ = dialogEnabled_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.loadingNotificationMessage_ = loadingNotificationMessage_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.AppCommand) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.AppCommand) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.AppCommand other) { + if (other == com.google.cloud.gsuiteaddons.v1.AppCommand.getDefaultInstance()) return this; + if (other.commandType_ != 0) { + setCommandTypeValue(other.getCommandTypeValue()); + } + if (other.getCommandId() != 0) { + setCommandId(other.getCommandId()); + } + if (!other.getCommand().isEmpty()) { + command_ = other.command_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + bitField0_ |= 0x00000010; + onChanged(); + } + if (other.getDialogEnabled() != false) { + setDialogEnabled(other.getDialogEnabled()); + } + if (!other.getLoadingNotificationMessage().isEmpty()) { + loadingNotificationMessage_ = other.loadingNotificationMessage_; + bitField0_ |= 0x00000040; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + commandType_ = input.readEnum(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 16: + { + commandId_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + command_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 48: + { + dialogEnabled_ = input.readBool(); + bitField0_ |= 0x00000020; + break; + } // case 48 + case 58: + { + loadingNotificationMessage_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000040; + break; + } // case 58 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int commandType_ = 0; + + /** + * + * + *
                    +     * Required. The type of this command.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppCommand.CommandType command_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for commandType. + */ + @java.lang.Override + public int getCommandTypeValue() { + return commandType_; + } + + /** + * + * + *
                    +     * Required. The type of this command.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppCommand.CommandType command_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The enum numeric value on the wire for commandType to set. + * @return This builder for chaining. + */ + public Builder setCommandTypeValue(int value) { + commandType_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The type of this command.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppCommand.CommandType command_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The commandType. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType getCommandType() { + com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType result = + com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType.forNumber(commandType_); + return result == null + ? com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType.UNRECOGNIZED + : result; + } + + /** + * + * + *
                    +     * Required. The type of this command.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppCommand.CommandType command_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The commandType to set. + * @return This builder for chaining. + */ + public Builder setCommandType(com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + commandType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The type of this command.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppCommand.CommandType command_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearCommandType() { + bitField0_ = (bitField0_ & ~0x00000001); + commandType_ = 0; + onChanged(); + return this; + } + + private int commandId_; + + /** + * + * + *
                    +     * Required. The ID of the command (1-1000). Must be unique within the app.
                    +     * 
                    + * + * int32 command_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The commandId. + */ + @java.lang.Override + public int getCommandId() { + return commandId_; + } + + /** + * + * + *
                    +     * Required. The ID of the command (1-1000). Must be unique within the app.
                    +     * 
                    + * + * int32 command_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The commandId to set. + * @return This builder for chaining. + */ + public Builder setCommandId(int value) { + + commandId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The ID of the command (1-1000). Must be unique within the app.
                    +     * 
                    + * + * int32 command_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearCommandId() { + bitField0_ = (bitField0_ & ~0x00000002); + commandId_ = 0; + onChanged(); + return this; + } + + private java.lang.Object command_ = ""; + + /** + * + * + *
                    +     * Optional. The name of the command. Required for SLASH_COMMAND, do not set
                    +     * for other command types. Must start with a "/", e.g., "/command".
                    +     * 
                    + * + * string command = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The command. + */ + public java.lang.String getCommand() { + java.lang.Object ref = command_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + command_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Optional. The name of the command. Required for SLASH_COMMAND, do not set
                    +     * for other command types. Must start with a "/", e.g., "/command".
                    +     * 
                    + * + * string command = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for command. + */ + public com.google.protobuf.ByteString getCommandBytes() { + java.lang.Object ref = command_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + command_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Optional. The name of the command. Required for SLASH_COMMAND, do not set
                    +     * for other command types. Must start with a "/", e.g., "/command".
                    +     * 
                    + * + * string command = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The command to set. + * @return This builder for chaining. + */ + public Builder setCommand(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + command_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The name of the command. Required for SLASH_COMMAND, do not set
                    +     * for other command types. Must start with a "/", e.g., "/command".
                    +     * 
                    + * + * string command = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearCommand() { + command_ = getDefaultInstance().getCommand(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The name of the command. Required for SLASH_COMMAND, do not set
                    +     * for other command types. Must start with a "/", e.g., "/command".
                    +     * 
                    + * + * string command = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for command to set. + * @return This builder for chaining. + */ + public Builder setCommandBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + command_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + + /** + * + * + *
                    +     * Optional. The user-friendly display name of the command. Required for
                    +     * MESSAGE_ACTION and QUICK_COMMAND, do not set for SLASH_COMMAND.
                    +     * 
                    + * + * string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Optional. The user-friendly display name of the command. Required for
                    +     * MESSAGE_ACTION and QUICK_COMMAND, do not set for SLASH_COMMAND.
                    +     * 
                    + * + * string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Optional. The user-friendly display name of the command. Required for
                    +     * MESSAGE_ACTION and QUICK_COMMAND, do not set for SLASH_COMMAND.
                    +     * 
                    + * + * string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + displayName_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The user-friendly display name of the command. Required for
                    +     * MESSAGE_ACTION and QUICK_COMMAND, do not set for SLASH_COMMAND.
                    +     * 
                    + * + * string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + displayName_ = getDefaultInstance().getDisplayName(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The user-friendly display name of the command. Required for
                    +     * MESSAGE_ACTION and QUICK_COMMAND, do not set for SLASH_COMMAND.
                    +     * 
                    + * + * string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + displayName_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + + /** + * + * + *
                    +     * Required. A short description of the command.
                    +     * 
                    + * + * string description = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. A short description of the command.
                    +     * 
                    + * + * string description = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. A short description of the command.
                    +     * 
                    + * + * string description = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + description_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. A short description of the command.
                    +     * 
                    + * + * string description = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + description_ = getDefaultInstance().getDescription(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. A short description of the command.
                    +     * 
                    + * + * string description = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private boolean dialogEnabled_; + + /** + * + * + *
                    +     * Optional. Whether this command should trigger a dialog. Defaults to
                    +     * `false`, if not specified.
                    +     * 
                    + * + * bool dialog_enabled = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The dialogEnabled. + */ + @java.lang.Override + public boolean getDialogEnabled() { + return dialogEnabled_; + } + + /** + * + * + *
                    +     * Optional. Whether this command should trigger a dialog. Defaults to
                    +     * `false`, if not specified.
                    +     * 
                    + * + * bool dialog_enabled = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The dialogEnabled to set. + * @return This builder for chaining. + */ + public Builder setDialogEnabled(boolean value) { + + dialogEnabled_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Whether this command should trigger a dialog. Defaults to
                    +     * `false`, if not specified.
                    +     * 
                    + * + * bool dialog_enabled = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDialogEnabled() { + bitField0_ = (bitField0_ & ~0x00000020); + dialogEnabled_ = false; + onChanged(); + return this; + } + + private java.lang.Object loadingNotificationMessage_ = ""; + + /** + * + * + *
                    +     * Optional. A notification to be sent to the user when they trigger the
                    +     * message action. Only supported for MESSAGE_ACTION commands.
                    +     * 
                    + * + * string loading_notification_message = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The loadingNotificationMessage. + */ + public java.lang.String getLoadingNotificationMessage() { + java.lang.Object ref = loadingNotificationMessage_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + loadingNotificationMessage_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Optional. A notification to be sent to the user when they trigger the
                    +     * message action. Only supported for MESSAGE_ACTION commands.
                    +     * 
                    + * + * string loading_notification_message = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The bytes for loadingNotificationMessage. + */ + public com.google.protobuf.ByteString getLoadingNotificationMessageBytes() { + java.lang.Object ref = loadingNotificationMessage_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + loadingNotificationMessage_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Optional. A notification to be sent to the user when they trigger the
                    +     * message action. Only supported for MESSAGE_ACTION commands.
                    +     * 
                    + * + * string loading_notification_message = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The loadingNotificationMessage to set. + * @return This builder for chaining. + */ + public Builder setLoadingNotificationMessage(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + loadingNotificationMessage_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. A notification to be sent to the user when they trigger the
                    +     * message action. Only supported for MESSAGE_ACTION commands.
                    +     * 
                    + * + * string loading_notification_message = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearLoadingNotificationMessage() { + loadingNotificationMessage_ = getDefaultInstance().getLoadingNotificationMessage(); + bitField0_ = (bitField0_ & ~0x00000040); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. A notification to be sent to the user when they trigger the
                    +     * message action. Only supported for MESSAGE_ACTION commands.
                    +     * 
                    + * + * string loading_notification_message = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes for loadingNotificationMessage to set. + * @return This builder for chaining. + */ + public Builder setLoadingNotificationMessageBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + loadingNotificationMessage_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.AppCommand) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.AppCommand) + private static final com.google.cloud.gsuiteaddons.v1.AppCommand DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.AppCommand(); + } + + public static com.google.cloud.gsuiteaddons.v1.AppCommand getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AppCommand parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppCommand getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppCommandOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppCommandOrBuilder.java new file mode 100644 index 000000000000..b476f1024570 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppCommandOrBuilder.java @@ -0,0 +1,195 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface AppCommandOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.AppCommand) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Required. The type of this command.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppCommand.CommandType command_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for commandType. + */ + int getCommandTypeValue(); + + /** + * + * + *
                    +   * Required. The type of this command.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppCommand.CommandType command_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The commandType. + */ + com.google.cloud.gsuiteaddons.v1.AppCommand.CommandType getCommandType(); + + /** + * + * + *
                    +   * Required. The ID of the command (1-1000). Must be unique within the app.
                    +   * 
                    + * + * int32 command_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The commandId. + */ + int getCommandId(); + + /** + * + * + *
                    +   * Optional. The name of the command. Required for SLASH_COMMAND, do not set
                    +   * for other command types. Must start with a "/", e.g., "/command".
                    +   * 
                    + * + * string command = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The command. + */ + java.lang.String getCommand(); + + /** + * + * + *
                    +   * Optional. The name of the command. Required for SLASH_COMMAND, do not set
                    +   * for other command types. Must start with a "/", e.g., "/command".
                    +   * 
                    + * + * string command = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for command. + */ + com.google.protobuf.ByteString getCommandBytes(); + + /** + * + * + *
                    +   * Optional. The user-friendly display name of the command. Required for
                    +   * MESSAGE_ACTION and QUICK_COMMAND, do not set for SLASH_COMMAND.
                    +   * 
                    + * + * string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
                    +   * Optional. The user-friendly display name of the command. Required for
                    +   * MESSAGE_ACTION and QUICK_COMMAND, do not set for SLASH_COMMAND.
                    +   * 
                    + * + * string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
                    +   * Required. A short description of the command.
                    +   * 
                    + * + * string description = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
                    +   * Required. A short description of the command.
                    +   * 
                    + * + * string description = 5 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
                    +   * Optional. Whether this command should trigger a dialog. Defaults to
                    +   * `false`, if not specified.
                    +   * 
                    + * + * bool dialog_enabled = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The dialogEnabled. + */ + boolean getDialogEnabled(); + + /** + * + * + *
                    +   * Optional. A notification to be sent to the user when they trigger the
                    +   * message action. Only supported for MESSAGE_ACTION commands.
                    +   * 
                    + * + * string loading_notification_message = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The loadingNotificationMessage. + */ + java.lang.String getLoadingNotificationMessage(); + + /** + * + * + *
                    +   * Optional. A notification to be sent to the user when they trigger the
                    +   * message action. Only supported for MESSAGE_ACTION commands.
                    +   * 
                    + * + * string loading_notification_message = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for loadingNotificationMessage. + */ + com.google.protobuf.ByteString getLoadingNotificationMessageBytes(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptEndpointConfig.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptEndpointConfig.java new file mode 100644 index 000000000000..203c685cb160 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptEndpointConfig.java @@ -0,0 +1,953 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * Apps Script endpoint configuration.
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig} + */ +@com.google.protobuf.Generated +public final class AppsScriptEndpointConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) + AppsScriptEndpointConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AppsScriptEndpointConfig"); + } + + // Use AppsScriptEndpointConfig.newBuilder() to construct. + private AppsScriptEndpointConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AppsScriptEndpointConfig() { + deploymentId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppsScriptEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppsScriptEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.Builder.class); + } + + private int bitField0_; + public static final int DEPLOYMENT_ID_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object deploymentId_ = ""; + + /** + * + * + *
                    +   * Required. The Apps Script deployment ID.
                    +   * 
                    + * + * string deployment_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The deploymentId. + */ + @java.lang.Override + public java.lang.String getDeploymentId() { + java.lang.Object ref = deploymentId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + deploymentId_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. The Apps Script deployment ID.
                    +   * 
                    + * + * string deployment_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for deploymentId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDeploymentIdBytes() { + java.lang.Object ref = deploymentId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + deploymentId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PER_EVENT_ENDPOINT_CONFIG_FIELD_NUMBER = 2; + private com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig perEventEndpointConfig_; + + /** + * + * + *
                    +   * Optional. The names of the Apps Script functions that Google Chat calls
                    +   * for each type of interactive event. If not specified, Chat calls the
                    +   * default function for each event type.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the perEventEndpointConfig field is set. + */ + @java.lang.Override + public boolean hasPerEventEndpointConfig() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                    +   * Optional. The names of the Apps Script functions that Google Chat calls
                    +   * for each type of interactive event. If not specified, Chat calls the
                    +   * default function for each event type.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The perEventEndpointConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig + getPerEventEndpointConfig() { + return perEventEndpointConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.getDefaultInstance() + : perEventEndpointConfig_; + } + + /** + * + * + *
                    +   * Optional. The names of the Apps Script functions that Google Chat calls
                    +   * for each type of interactive event. If not specified, Chat calls the
                    +   * default function for each event type.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfigOrBuilder + getPerEventEndpointConfigOrBuilder() { + return perEventEndpointConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.getDefaultInstance() + : perEventEndpointConfig_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(deploymentId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, deploymentId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getPerEventEndpointConfig()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(deploymentId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, deploymentId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(2, getPerEventEndpointConfig()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig other = + (com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) obj; + + if (!getDeploymentId().equals(other.getDeploymentId())) return false; + if (hasPerEventEndpointConfig() != other.hasPerEventEndpointConfig()) return false; + if (hasPerEventEndpointConfig()) { + if (!getPerEventEndpointConfig().equals(other.getPerEventEndpointConfig())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + DEPLOYMENT_ID_FIELD_NUMBER; + hash = (53 * hash) + getDeploymentId().hashCode(); + if (hasPerEventEndpointConfig()) { + hash = (37 * hash) + PER_EVENT_ENDPOINT_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getPerEventEndpointConfig().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Apps Script endpoint configuration.
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppsScriptEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppsScriptEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetPerEventEndpointConfigFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + deploymentId_ = ""; + perEventEndpointConfig_ = null; + if (perEventEndpointConfigBuilder_ != null) { + perEventEndpointConfigBuilder_.dispose(); + perEventEndpointConfigBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppsScriptEndpointConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig build() { + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig buildPartial() { + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig result = + new com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.deploymentId_ = deploymentId_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.perEventEndpointConfig_ = + perEventEndpointConfigBuilder_ == null + ? perEventEndpointConfig_ + : perEventEndpointConfigBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig other) { + if (other == com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.getDefaultInstance()) + return this; + if (!other.getDeploymentId().isEmpty()) { + deploymentId_ = other.deploymentId_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.hasPerEventEndpointConfig()) { + mergePerEventEndpointConfig(other.getPerEventEndpointConfig()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + deploymentId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetPerEventEndpointConfigFieldBuilder().getBuilder(), + extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object deploymentId_ = ""; + + /** + * + * + *
                    +     * Required. The Apps Script deployment ID.
                    +     * 
                    + * + * string deployment_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The deploymentId. + */ + public java.lang.String getDeploymentId() { + java.lang.Object ref = deploymentId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + deploymentId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. The Apps Script deployment ID.
                    +     * 
                    + * + * string deployment_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for deploymentId. + */ + public com.google.protobuf.ByteString getDeploymentIdBytes() { + java.lang.Object ref = deploymentId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + deploymentId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. The Apps Script deployment ID.
                    +     * 
                    + * + * string deployment_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The deploymentId to set. + * @return This builder for chaining. + */ + public Builder setDeploymentId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + deploymentId_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The Apps Script deployment ID.
                    +     * 
                    + * + * string deployment_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDeploymentId() { + deploymentId_ = getDefaultInstance().getDeploymentId(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The Apps Script deployment ID.
                    +     * 
                    + * + * string deployment_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for deploymentId to set. + * @return This builder for chaining. + */ + public Builder setDeploymentIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + deploymentId_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig + perEventEndpointConfig_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig, + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfigOrBuilder> + perEventEndpointConfigBuilder_; + + /** + * + * + *
                    +     * Optional. The names of the Apps Script functions that Google Chat calls
                    +     * for each type of interactive event. If not specified, Chat calls the
                    +     * default function for each event type.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the perEventEndpointConfig field is set. + */ + public boolean hasPerEventEndpointConfig() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                    +     * Optional. The names of the Apps Script functions that Google Chat calls
                    +     * for each type of interactive event. If not specified, Chat calls the
                    +     * default function for each event type.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The perEventEndpointConfig. + */ + public com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig + getPerEventEndpointConfig() { + if (perEventEndpointConfigBuilder_ == null) { + return perEventEndpointConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.getDefaultInstance() + : perEventEndpointConfig_; + } else { + return perEventEndpointConfigBuilder_.getMessage(); + } + } + + /** + * + * + *
                    +     * Optional. The names of the Apps Script functions that Google Chat calls
                    +     * for each type of interactive event. If not specified, Chat calls the
                    +     * default function for each event type.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setPerEventEndpointConfig( + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig value) { + if (perEventEndpointConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + perEventEndpointConfig_ = value; + } else { + perEventEndpointConfigBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The names of the Apps Script functions that Google Chat calls
                    +     * for each type of interactive event. If not specified, Chat calls the
                    +     * default function for each event type.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setPerEventEndpointConfig( + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.Builder builderForValue) { + if (perEventEndpointConfigBuilder_ == null) { + perEventEndpointConfig_ = builderForValue.build(); + } else { + perEventEndpointConfigBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The names of the Apps Script functions that Google Chat calls
                    +     * for each type of interactive event. If not specified, Chat calls the
                    +     * default function for each event type.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergePerEventEndpointConfig( + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig value) { + if (perEventEndpointConfigBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && perEventEndpointConfig_ != null + && perEventEndpointConfig_ + != com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig + .getDefaultInstance()) { + getPerEventEndpointConfigBuilder().mergeFrom(value); + } else { + perEventEndpointConfig_ = value; + } + } else { + perEventEndpointConfigBuilder_.mergeFrom(value); + } + if (perEventEndpointConfig_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
                    +     * Optional. The names of the Apps Script functions that Google Chat calls
                    +     * for each type of interactive event. If not specified, Chat calls the
                    +     * default function for each event type.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearPerEventEndpointConfig() { + bitField0_ = (bitField0_ & ~0x00000002); + perEventEndpointConfig_ = null; + if (perEventEndpointConfigBuilder_ != null) { + perEventEndpointConfigBuilder_.dispose(); + perEventEndpointConfigBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The names of the Apps Script functions that Google Chat calls
                    +     * for each type of interactive event. If not specified, Chat calls the
                    +     * default function for each event type.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.Builder + getPerEventEndpointConfigBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetPerEventEndpointConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * Optional. The names of the Apps Script functions that Google Chat calls
                    +     * for each type of interactive event. If not specified, Chat calls the
                    +     * default function for each event type.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfigOrBuilder + getPerEventEndpointConfigOrBuilder() { + if (perEventEndpointConfigBuilder_ != null) { + return perEventEndpointConfigBuilder_.getMessageOrBuilder(); + } else { + return perEventEndpointConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.getDefaultInstance() + : perEventEndpointConfig_; + } + } + + /** + * + * + *
                    +     * Optional. The names of the Apps Script functions that Google Chat calls
                    +     * for each type of interactive event. If not specified, Chat calls the
                    +     * default function for each event type.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig, + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfigOrBuilder> + internalGetPerEventEndpointConfigFieldBuilder() { + if (perEventEndpointConfigBuilder_ == null) { + perEventEndpointConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig, + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfigOrBuilder>( + getPerEventEndpointConfig(), getParentForChildren(), isClean()); + perEventEndpointConfig_ = null; + } + return perEventEndpointConfigBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) + private static final com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig(); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AppsScriptEndpointConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptEndpointConfigOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptEndpointConfigOrBuilder.java new file mode 100644 index 000000000000..c47fc4026100 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptEndpointConfigOrBuilder.java @@ -0,0 +1,104 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface AppsScriptEndpointConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Required. The Apps Script deployment ID.
                    +   * 
                    + * + * string deployment_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The deploymentId. + */ + java.lang.String getDeploymentId(); + + /** + * + * + *
                    +   * Required. The Apps Script deployment ID.
                    +   * 
                    + * + * string deployment_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for deploymentId. + */ + com.google.protobuf.ByteString getDeploymentIdBytes(); + + /** + * + * + *
                    +   * Optional. The names of the Apps Script functions that Google Chat calls
                    +   * for each type of interactive event. If not specified, Chat calls the
                    +   * default function for each event type.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the perEventEndpointConfig field is set. + */ + boolean hasPerEventEndpointConfig(); + + /** + * + * + *
                    +   * Optional. The names of the Apps Script functions that Google Chat calls
                    +   * for each type of interactive event. If not specified, Chat calls the
                    +   * default function for each event type.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The perEventEndpointConfig. + */ + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig getPerEventEndpointConfig(); + + /** + * + * + *
                    +   * Optional. The names of the Apps Script functions that Google Chat calls
                    +   * for each type of interactive event. If not specified, Chat calls the
                    +   * default function for each event type.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfigOrBuilder + getPerEventEndpointConfigOrBuilder(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptPerEventEndpointConfig.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptPerEventEndpointConfig.java new file mode 100644 index 000000000000..10bd0376bfbb --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptPerEventEndpointConfig.java @@ -0,0 +1,1397 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * Apps Script endpoint configuration for specific event types.
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig} + */ +@com.google.protobuf.Generated +public final class AppsScriptPerEventEndpointConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig) + AppsScriptPerEventEndpointConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AppsScriptPerEventEndpointConfig"); + } + + // Use AppsScriptPerEventEndpointConfig.newBuilder() to construct. + private AppsScriptPerEventEndpointConfig( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private AppsScriptPerEventEndpointConfig() { + appCommandEndpoint_ = ""; + addedToSpaceEndpoint_ = ""; + messageEndpoint_ = ""; + removedFromSpaceEndpoint_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppsScriptPerEventEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppsScriptPerEventEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.Builder.class); + } + + private int bitField0_; + public static final int APP_COMMAND_ENDPOINT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object appCommandEndpoint_ = ""; + + /** + * + * + *
                    +   * Optional. Function name for app command events. If not specified, the
                    +   * default `onAppCommand` function name will be used.
                    +   * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the appCommandEndpoint field is set. + */ + @java.lang.Override + public boolean hasAppCommandEndpoint() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                    +   * Optional. Function name for app command events. If not specified, the
                    +   * default `onAppCommand` function name will be used.
                    +   * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The appCommandEndpoint. + */ + @java.lang.Override + public java.lang.String getAppCommandEndpoint() { + java.lang.Object ref = appCommandEndpoint_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + appCommandEndpoint_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Optional. Function name for app command events. If not specified, the
                    +   * default `onAppCommand` function name will be used.
                    +   * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The bytes for appCommandEndpoint. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAppCommandEndpointBytes() { + java.lang.Object ref = appCommandEndpoint_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + appCommandEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ADDED_TO_SPACE_ENDPOINT_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object addedToSpaceEndpoint_ = ""; + + /** + * + * + *
                    +   * Optional. Function name for added to space events. If not specified, the
                    +   * default `onAddedToSpace` function name will be used.
                    +   * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the addedToSpaceEndpoint field is set. + */ + @java.lang.Override + public boolean hasAddedToSpaceEndpoint() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                    +   * Optional. Function name for added to space events. If not specified, the
                    +   * default `onAddedToSpace` function name will be used.
                    +   * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The addedToSpaceEndpoint. + */ + @java.lang.Override + public java.lang.String getAddedToSpaceEndpoint() { + java.lang.Object ref = addedToSpaceEndpoint_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + addedToSpaceEndpoint_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Optional. Function name for added to space events. If not specified, the
                    +   * default `onAddedToSpace` function name will be used.
                    +   * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The bytes for addedToSpaceEndpoint. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAddedToSpaceEndpointBytes() { + java.lang.Object ref = addedToSpaceEndpoint_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + addedToSpaceEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int MESSAGE_ENDPOINT_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object messageEndpoint_ = ""; + + /** + * + * + *
                    +   * Optional. Function name for message events. If not specified, the default
                    +   * `onMessage` function name will be used.
                    +   * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the messageEndpoint field is set. + */ + @java.lang.Override + public boolean hasMessageEndpoint() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                    +   * Optional. Function name for message events. If not specified, the default
                    +   * `onMessage` function name will be used.
                    +   * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The messageEndpoint. + */ + @java.lang.Override + public java.lang.String getMessageEndpoint() { + java.lang.Object ref = messageEndpoint_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + messageEndpoint_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Optional. Function name for message events. If not specified, the default
                    +   * `onMessage` function name will be used.
                    +   * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for messageEndpoint. + */ + @java.lang.Override + public com.google.protobuf.ByteString getMessageEndpointBytes() { + java.lang.Object ref = messageEndpoint_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + messageEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int REMOVED_FROM_SPACE_ENDPOINT_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object removedFromSpaceEndpoint_ = ""; + + /** + * + * + *
                    +   * Optional. Function name for removed from space events. If not specified,
                    +   * the default `onRemovedFromSpace` function name will be used.
                    +   * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the removedFromSpaceEndpoint field is set. + */ + @java.lang.Override + public boolean hasRemovedFromSpaceEndpoint() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
                    +   * Optional. Function name for removed from space events. If not specified,
                    +   * the default `onRemovedFromSpace` function name will be used.
                    +   * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The removedFromSpaceEndpoint. + */ + @java.lang.Override + public java.lang.String getRemovedFromSpaceEndpoint() { + java.lang.Object ref = removedFromSpaceEndpoint_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + removedFromSpaceEndpoint_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Optional. Function name for removed from space events. If not specified,
                    +   * the default `onRemovedFromSpace` function name will be used.
                    +   * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The bytes for removedFromSpaceEndpoint. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRemovedFromSpaceEndpointBytes() { + java.lang.Object ref = removedFromSpaceEndpoint_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + removedFromSpaceEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, appCommandEndpoint_); + } + if (((bitField0_ & 0x00000002) != 0)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, addedToSpaceEndpoint_); + } + if (((bitField0_ & 0x00000004) != 0)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, messageEndpoint_); + } + if (((bitField0_ & 0x00000008) != 0)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, removedFromSpaceEndpoint_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, appCommandEndpoint_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, addedToSpaceEndpoint_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, messageEndpoint_); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, removedFromSpaceEndpoint_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig other = + (com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig) obj; + + if (hasAppCommandEndpoint() != other.hasAppCommandEndpoint()) return false; + if (hasAppCommandEndpoint()) { + if (!getAppCommandEndpoint().equals(other.getAppCommandEndpoint())) return false; + } + if (hasAddedToSpaceEndpoint() != other.hasAddedToSpaceEndpoint()) return false; + if (hasAddedToSpaceEndpoint()) { + if (!getAddedToSpaceEndpoint().equals(other.getAddedToSpaceEndpoint())) return false; + } + if (hasMessageEndpoint() != other.hasMessageEndpoint()) return false; + if (hasMessageEndpoint()) { + if (!getMessageEndpoint().equals(other.getMessageEndpoint())) return false; + } + if (hasRemovedFromSpaceEndpoint() != other.hasRemovedFromSpaceEndpoint()) return false; + if (hasRemovedFromSpaceEndpoint()) { + if (!getRemovedFromSpaceEndpoint().equals(other.getRemovedFromSpaceEndpoint())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasAppCommandEndpoint()) { + hash = (37 * hash) + APP_COMMAND_ENDPOINT_FIELD_NUMBER; + hash = (53 * hash) + getAppCommandEndpoint().hashCode(); + } + if (hasAddedToSpaceEndpoint()) { + hash = (37 * hash) + ADDED_TO_SPACE_ENDPOINT_FIELD_NUMBER; + hash = (53 * hash) + getAddedToSpaceEndpoint().hashCode(); + } + if (hasMessageEndpoint()) { + hash = (37 * hash) + MESSAGE_ENDPOINT_FIELD_NUMBER; + hash = (53 * hash) + getMessageEndpoint().hashCode(); + } + if (hasRemovedFromSpaceEndpoint()) { + hash = (37 * hash) + REMOVED_FROM_SPACE_ENDPOINT_FIELD_NUMBER; + hash = (53 * hash) + getRemovedFromSpaceEndpoint().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Apps Script endpoint configuration for specific event types.
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig) + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppsScriptPerEventEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppsScriptPerEventEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.Builder.class); + } + + // Construct using + // com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + appCommandEndpoint_ = ""; + addedToSpaceEndpoint_ = ""; + messageEndpoint_ = ""; + removedFromSpaceEndpoint_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_AppsScriptPerEventEndpointConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig + getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig build() { + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig buildPartial() { + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig result = + new com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.appCommandEndpoint_ = appCommandEndpoint_; + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.addedToSpaceEndpoint_ = addedToSpaceEndpoint_; + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.messageEndpoint_ = messageEndpoint_; + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.removedFromSpaceEndpoint_ = removedFromSpaceEndpoint_; + to_bitField0_ |= 0x00000008; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig other) { + if (other + == com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig.getDefaultInstance()) + return this; + if (other.hasAppCommandEndpoint()) { + appCommandEndpoint_ = other.appCommandEndpoint_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.hasAddedToSpaceEndpoint()) { + addedToSpaceEndpoint_ = other.addedToSpaceEndpoint_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasMessageEndpoint()) { + messageEndpoint_ = other.messageEndpoint_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.hasRemovedFromSpaceEndpoint()) { + removedFromSpaceEndpoint_ = other.removedFromSpaceEndpoint_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + appCommandEndpoint_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + addedToSpaceEndpoint_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + messageEndpoint_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + removedFromSpaceEndpoint_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object appCommandEndpoint_ = ""; + + /** + * + * + *
                    +     * Optional. Function name for app command events. If not specified, the
                    +     * default `onAppCommand` function name will be used.
                    +     * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the appCommandEndpoint field is set. + */ + public boolean hasAppCommandEndpoint() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                    +     * Optional. Function name for app command events. If not specified, the
                    +     * default `onAppCommand` function name will be used.
                    +     * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The appCommandEndpoint. + */ + public java.lang.String getAppCommandEndpoint() { + java.lang.Object ref = appCommandEndpoint_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + appCommandEndpoint_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Optional. Function name for app command events. If not specified, the
                    +     * default `onAppCommand` function name will be used.
                    +     * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The bytes for appCommandEndpoint. + */ + public com.google.protobuf.ByteString getAppCommandEndpointBytes() { + java.lang.Object ref = appCommandEndpoint_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + appCommandEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Optional. Function name for app command events. If not specified, the
                    +     * default `onAppCommand` function name will be used.
                    +     * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The appCommandEndpoint to set. + * @return This builder for chaining. + */ + public Builder setAppCommandEndpoint(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + appCommandEndpoint_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Function name for app command events. If not specified, the
                    +     * default `onAppCommand` function name will be used.
                    +     * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearAppCommandEndpoint() { + appCommandEndpoint_ = getDefaultInstance().getAppCommandEndpoint(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Function name for app command events. If not specified, the
                    +     * default `onAppCommand` function name will be used.
                    +     * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes for appCommandEndpoint to set. + * @return This builder for chaining. + */ + public Builder setAppCommandEndpointBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + appCommandEndpoint_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object addedToSpaceEndpoint_ = ""; + + /** + * + * + *
                    +     * Optional. Function name for added to space events. If not specified, the
                    +     * default `onAddedToSpace` function name will be used.
                    +     * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the addedToSpaceEndpoint field is set. + */ + public boolean hasAddedToSpaceEndpoint() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                    +     * Optional. Function name for added to space events. If not specified, the
                    +     * default `onAddedToSpace` function name will be used.
                    +     * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The addedToSpaceEndpoint. + */ + public java.lang.String getAddedToSpaceEndpoint() { + java.lang.Object ref = addedToSpaceEndpoint_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + addedToSpaceEndpoint_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Optional. Function name for added to space events. If not specified, the
                    +     * default `onAddedToSpace` function name will be used.
                    +     * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The bytes for addedToSpaceEndpoint. + */ + public com.google.protobuf.ByteString getAddedToSpaceEndpointBytes() { + java.lang.Object ref = addedToSpaceEndpoint_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + addedToSpaceEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Optional. Function name for added to space events. If not specified, the
                    +     * default `onAddedToSpace` function name will be used.
                    +     * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The addedToSpaceEndpoint to set. + * @return This builder for chaining. + */ + public Builder setAddedToSpaceEndpoint(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + addedToSpaceEndpoint_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Function name for added to space events. If not specified, the
                    +     * default `onAddedToSpace` function name will be used.
                    +     * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearAddedToSpaceEndpoint() { + addedToSpaceEndpoint_ = getDefaultInstance().getAddedToSpaceEndpoint(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Function name for added to space events. If not specified, the
                    +     * default `onAddedToSpace` function name will be used.
                    +     * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes for addedToSpaceEndpoint to set. + * @return This builder for chaining. + */ + public Builder setAddedToSpaceEndpointBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + addedToSpaceEndpoint_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object messageEndpoint_ = ""; + + /** + * + * + *
                    +     * Optional. Function name for message events. If not specified, the default
                    +     * `onMessage` function name will be used.
                    +     * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the messageEndpoint field is set. + */ + public boolean hasMessageEndpoint() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                    +     * Optional. Function name for message events. If not specified, the default
                    +     * `onMessage` function name will be used.
                    +     * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The messageEndpoint. + */ + public java.lang.String getMessageEndpoint() { + java.lang.Object ref = messageEndpoint_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + messageEndpoint_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Optional. Function name for message events. If not specified, the default
                    +     * `onMessage` function name will be used.
                    +     * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for messageEndpoint. + */ + public com.google.protobuf.ByteString getMessageEndpointBytes() { + java.lang.Object ref = messageEndpoint_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + messageEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Optional. Function name for message events. If not specified, the default
                    +     * `onMessage` function name will be used.
                    +     * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The messageEndpoint to set. + * @return This builder for chaining. + */ + public Builder setMessageEndpoint(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + messageEndpoint_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Function name for message events. If not specified, the default
                    +     * `onMessage` function name will be used.
                    +     * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearMessageEndpoint() { + messageEndpoint_ = getDefaultInstance().getMessageEndpoint(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Function name for message events. If not specified, the default
                    +     * `onMessage` function name will be used.
                    +     * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for messageEndpoint to set. + * @return This builder for chaining. + */ + public Builder setMessageEndpointBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + messageEndpoint_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object removedFromSpaceEndpoint_ = ""; + + /** + * + * + *
                    +     * Optional. Function name for removed from space events. If not specified,
                    +     * the default `onRemovedFromSpace` function name will be used.
                    +     * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the removedFromSpaceEndpoint field is set. + */ + public boolean hasRemovedFromSpaceEndpoint() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
                    +     * Optional. Function name for removed from space events. If not specified,
                    +     * the default `onRemovedFromSpace` function name will be used.
                    +     * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The removedFromSpaceEndpoint. + */ + public java.lang.String getRemovedFromSpaceEndpoint() { + java.lang.Object ref = removedFromSpaceEndpoint_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + removedFromSpaceEndpoint_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Optional. Function name for removed from space events. If not specified,
                    +     * the default `onRemovedFromSpace` function name will be used.
                    +     * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The bytes for removedFromSpaceEndpoint. + */ + public com.google.protobuf.ByteString getRemovedFromSpaceEndpointBytes() { + java.lang.Object ref = removedFromSpaceEndpoint_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + removedFromSpaceEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Optional. Function name for removed from space events. If not specified,
                    +     * the default `onRemovedFromSpace` function name will be used.
                    +     * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The removedFromSpaceEndpoint to set. + * @return This builder for chaining. + */ + public Builder setRemovedFromSpaceEndpoint(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + removedFromSpaceEndpoint_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Function name for removed from space events. If not specified,
                    +     * the default `onRemovedFromSpace` function name will be used.
                    +     * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearRemovedFromSpaceEndpoint() { + removedFromSpaceEndpoint_ = getDefaultInstance().getRemovedFromSpaceEndpoint(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Function name for removed from space events. If not specified,
                    +     * the default `onRemovedFromSpace` function name will be used.
                    +     * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes for removedFromSpaceEndpoint to set. + * @return This builder for chaining. + */ + public Builder setRemovedFromSpaceEndpointBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + removedFromSpaceEndpoint_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig) + private static final com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig(); + } + + public static com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AppsScriptPerEventEndpointConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptPerEventEndpointConfigOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptPerEventEndpointConfigOrBuilder.java new file mode 100644 index 000000000000..061329afa36e --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/AppsScriptPerEventEndpointConfigOrBuilder.java @@ -0,0 +1,208 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface AppsScriptPerEventEndpointConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Optional. Function name for app command events. If not specified, the
                    +   * default `onAppCommand` function name will be used.
                    +   * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the appCommandEndpoint field is set. + */ + boolean hasAppCommandEndpoint(); + + /** + * + * + *
                    +   * Optional. Function name for app command events. If not specified, the
                    +   * default `onAppCommand` function name will be used.
                    +   * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The appCommandEndpoint. + */ + java.lang.String getAppCommandEndpoint(); + + /** + * + * + *
                    +   * Optional. Function name for app command events. If not specified, the
                    +   * default `onAppCommand` function name will be used.
                    +   * 
                    + * + * optional string app_command_endpoint = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The bytes for appCommandEndpoint. + */ + com.google.protobuf.ByteString getAppCommandEndpointBytes(); + + /** + * + * + *
                    +   * Optional. Function name for added to space events. If not specified, the
                    +   * default `onAddedToSpace` function name will be used.
                    +   * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the addedToSpaceEndpoint field is set. + */ + boolean hasAddedToSpaceEndpoint(); + + /** + * + * + *
                    +   * Optional. Function name for added to space events. If not specified, the
                    +   * default `onAddedToSpace` function name will be used.
                    +   * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The addedToSpaceEndpoint. + */ + java.lang.String getAddedToSpaceEndpoint(); + + /** + * + * + *
                    +   * Optional. Function name for added to space events. If not specified, the
                    +   * default `onAddedToSpace` function name will be used.
                    +   * 
                    + * + * optional string added_to_space_endpoint = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The bytes for addedToSpaceEndpoint. + */ + com.google.protobuf.ByteString getAddedToSpaceEndpointBytes(); + + /** + * + * + *
                    +   * Optional. Function name for message events. If not specified, the default
                    +   * `onMessage` function name will be used.
                    +   * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the messageEndpoint field is set. + */ + boolean hasMessageEndpoint(); + + /** + * + * + *
                    +   * Optional. Function name for message events. If not specified, the default
                    +   * `onMessage` function name will be used.
                    +   * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The messageEndpoint. + */ + java.lang.String getMessageEndpoint(); + + /** + * + * + *
                    +   * Optional. Function name for message events. If not specified, the default
                    +   * `onMessage` function name will be used.
                    +   * 
                    + * + * optional string message_endpoint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for messageEndpoint. + */ + com.google.protobuf.ByteString getMessageEndpointBytes(); + + /** + * + * + *
                    +   * Optional. Function name for removed from space events. If not specified,
                    +   * the default `onRemovedFromSpace` function name will be used.
                    +   * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the removedFromSpaceEndpoint field is set. + */ + boolean hasRemovedFromSpaceEndpoint(); + + /** + * + * + *
                    +   * Optional. Function name for removed from space events. If not specified,
                    +   * the default `onRemovedFromSpace` function name will be used.
                    +   * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The removedFromSpaceEndpoint. + */ + java.lang.String getRemovedFromSpaceEndpoint(); + + /** + * + * + *
                    +   * Optional. Function name for removed from space events. If not specified,
                    +   * the default `onRemovedFromSpace` function name will be used.
                    +   * 
                    + * + * + * optional string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The bytes for removedFromSpaceEndpoint. + */ + com.google.protobuf.ByteString getRemovedFromSpaceEndpointBytes(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ChatAppConfig.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ChatAppConfig.java new file mode 100644 index 000000000000..b82db01c36e2 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ChatAppConfig.java @@ -0,0 +1,2568 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * Represents the configuration of a Google Chat app built as a Google Workspace
                    + * add-on.
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.ChatAppConfig} + */ +@com.google.protobuf.Generated +public final class ChatAppConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.ChatAppConfig) + ChatAppConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ChatAppConfig"); + } + + // Use ChatAppConfig.newBuilder() to construct. + private ChatAppConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ChatAppConfig() { + name_ = ""; + displayName_ = ""; + avatarUri_ = ""; + description_ = ""; + state_ = 0; + markupSyntax_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_ChatAppConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_ChatAppConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.class, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.Builder.class); + } + + /** + * + * + *
                    +   * The current state of the Chat app.
                    +   * 
                    + * + * Protobuf enum {@code google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState} + */ + public enum AppState implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                    +     * Default value. Unspecified.
                    +     * 
                    + * + * APP_STATE_UNSPECIFIED = 0; + */ + APP_STATE_UNSPECIFIED(0), + /** + * + * + *
                    +     * Maps to LIVE in the Chat API configuration page.
                    +     * The app is active, it can be found and used by people with visibility.
                    +     * 
                    + * + * ACTIVE = 1; + */ + ACTIVE(1), + /** + * + * + *
                    +     * The app is disabled, it can no longer be found by anyone, and nobody can
                    +     * talk to the app any more.
                    +     * 
                    + * + * DISABLED = 2; + */ + DISABLED(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "AppState"); + } + + /** + * + * + *
                    +     * Default value. Unspecified.
                    +     * 
                    + * + * APP_STATE_UNSPECIFIED = 0; + */ + public static final int APP_STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                    +     * Maps to LIVE in the Chat API configuration page.
                    +     * The app is active, it can be found and used by people with visibility.
                    +     * 
                    + * + * ACTIVE = 1; + */ + public static final int ACTIVE_VALUE = 1; + + /** + * + * + *
                    +     * The app is disabled, it can no longer be found by anyone, and nobody can
                    +     * talk to the app any more.
                    +     * 
                    + * + * DISABLED = 2; + */ + public static final int DISABLED_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static AppState valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static AppState forNumber(int value) { + switch (value) { + case 0: + return APP_STATE_UNSPECIFIED; + case 1: + return ACTIVE; + case 2: + return DISABLED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public AppState findValueByNumber(int number) { + return AppState.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.ChatAppConfig.getDescriptor().getEnumTypes().get(0); + } + + private static final AppState[] VALUES = values(); + + public static AppState valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private AppState(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState) + } + + /** + * + * + *
                    +   * The markup syntax used to format message text for this Chat app.
                    +   * 
                    + * + * Protobuf enum {@code google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax} + */ + public enum MarkupSyntax implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                    +     * Default value. Unspecified. Existing Chat apps created before
                    +     * `markup_syntax` was introduced have this value and use
                    +     * `MARKUP_SYNTAX_CHAT` until explicitly updated.
                    +     * 
                    + * + * MARKUP_SYNTAX_UNSPECIFIED = 0; + */ + MARKUP_SYNTAX_UNSPECIFIED(0), + /** + * + * + *
                    +     * Uses Google Chat's markup syntax.
                    +     * See
                    +     * https://developers.google.com/workspace/chat/format-messages#format-texts
                    +     * for more information.
                    +     * 
                    + * + * MARKUP_SYNTAX_CHAT = 1; + */ + MARKUP_SYNTAX_CHAT(1), + /** + * + * + *
                    +     * Uses Markdown syntax. This syntax is based on the
                    +     * [CommonMark](https://commonmark.org/help/) specification, with additional
                    +     * extensions.
                    +     * See
                    +     * https://developers.google.com/workspace/chat/format-messages#format-texts
                    +     * for more information.
                    +     * 
                    + * + * MARKUP_SYNTAX_MARKDOWN = 2; + */ + MARKUP_SYNTAX_MARKDOWN(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "MarkupSyntax"); + } + + /** + * + * + *
                    +     * Default value. Unspecified. Existing Chat apps created before
                    +     * `markup_syntax` was introduced have this value and use
                    +     * `MARKUP_SYNTAX_CHAT` until explicitly updated.
                    +     * 
                    + * + * MARKUP_SYNTAX_UNSPECIFIED = 0; + */ + public static final int MARKUP_SYNTAX_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                    +     * Uses Google Chat's markup syntax.
                    +     * See
                    +     * https://developers.google.com/workspace/chat/format-messages#format-texts
                    +     * for more information.
                    +     * 
                    + * + * MARKUP_SYNTAX_CHAT = 1; + */ + public static final int MARKUP_SYNTAX_CHAT_VALUE = 1; + + /** + * + * + *
                    +     * Uses Markdown syntax. This syntax is based on the
                    +     * [CommonMark](https://commonmark.org/help/) specification, with additional
                    +     * extensions.
                    +     * See
                    +     * https://developers.google.com/workspace/chat/format-messages#format-texts
                    +     * for more information.
                    +     * 
                    + * + * MARKUP_SYNTAX_MARKDOWN = 2; + */ + public static final int MARKUP_SYNTAX_MARKDOWN_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static MarkupSyntax valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static MarkupSyntax forNumber(int value) { + switch (value) { + case 0: + return MARKUP_SYNTAX_UNSPECIFIED; + case 1: + return MARKUP_SYNTAX_CHAT; + case 2: + return MARKUP_SYNTAX_MARKDOWN; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public MarkupSyntax findValueByNumber(int number) { + return MarkupSyntax.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.ChatAppConfig.getDescriptor().getEnumTypes().get(1); + } + + private static final MarkupSyntax[] VALUES = values(); + + public static MarkupSyntax valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private MarkupSyntax(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax) + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
                    +   * Required. Identifier. Resource name of the Chat app configuration.
                    +   *
                    +   * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +   * Cloud project number.
                    +   * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. Identifier. Resource name of the Chat app configuration.
                    +   *
                    +   * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +   * Cloud project number.
                    +   * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object displayName_ = ""; + + /** + * + * + *
                    +   * Required. The display name of the Chat app. Length should be between 3 and
                    +   * 25 characters.
                    +   * 
                    + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. The display name of the Chat app. Length should be between 3 and
                    +   * 25 characters.
                    +   * 
                    + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int AVATAR_URI_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object avatarUri_ = ""; + + /** + * + * + *
                    +   * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +   * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +   * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +   * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the avatarUri field is set. + */ + @java.lang.Override + public boolean hasAvatarUri() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                    +   * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +   * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +   * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +   * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The avatarUri. + */ + @java.lang.Override + public java.lang.String getAvatarUri() { + java.lang.Object ref = avatarUri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + avatarUri_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +   * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +   * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +   * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for avatarUri. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAvatarUriBytes() { + java.lang.Object ref = avatarUri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + avatarUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object description_ = ""; + + /** + * + * + *
                    +   * Required. A short description of the Chat app.
                    +   * Should be between 1 and 40 characters.
                    +   * 
                    + * + * string description = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. A short description of the Chat app.
                    +   * Should be between 1 and 40 characters.
                    +   * 
                    + * + * string description = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STATE_FIELD_NUMBER = 5; + private int state_ = 0; + + /** + * + * + *
                    +   * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the state field is set. + */ + @java.lang.Override + public boolean hasState() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                    +   * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
                    +   * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState getState() { + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState result = + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState.forNumber(state_); + return result == null + ? com.google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState.UNRECOGNIZED + : result; + } + + public static final int INTERACTIVE_FEATURE_CONFIG_FIELD_NUMBER = 6; + private com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactiveFeatureConfig_; + + /** + * + * + *
                    +   * Optional. The settings for interactive features of the app. If this is not
                    +   * provided, the app will be non-interactive, meaning that it can use the Chat
                    +   * API, but users can't interact with the app.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the interactiveFeatureConfig field is set. + */ + @java.lang.Override + public boolean hasInteractiveFeatureConfig() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                    +   * Optional. The settings for interactive features of the app. If this is not
                    +   * provided, the app will be non-interactive, meaning that it can use the Chat
                    +   * API, but users can't interact with the app.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The interactiveFeatureConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig getInteractiveFeatureConfig() { + return interactiveFeatureConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.getDefaultInstance() + : interactiveFeatureConfig_; + } + + /** + * + * + *
                    +   * Optional. The settings for interactive features of the app. If this is not
                    +   * provided, the app will be non-interactive, meaning that it can use the Chat
                    +   * API, but users can't interact with the app.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfigOrBuilder + getInteractiveFeatureConfigOrBuilder() { + return interactiveFeatureConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.getDefaultInstance() + : interactiveFeatureConfig_; + } + + public static final int ERROR_LOGGING_ENABLED_FIELD_NUMBER = 7; + private boolean errorLoggingEnabled_ = false; + + /** + * + * + *
                    +   * Optional. Whether to log errors to Cloud Logging. Defaults to `false` if
                    +   * not specified.
                    +   * 
                    + * + * optional bool error_logging_enabled = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the errorLoggingEnabled field is set. + */ + @java.lang.Override + public boolean hasErrorLoggingEnabled() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
                    +   * Optional. Whether to log errors to Cloud Logging. Defaults to `false` if
                    +   * not specified.
                    +   * 
                    + * + * optional bool error_logging_enabled = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The errorLoggingEnabled. + */ + @java.lang.Override + public boolean getErrorLoggingEnabled() { + return errorLoggingEnabled_; + } + + public static final int MARKUP_SYNTAX_FIELD_NUMBER = 8; + private int markupSyntax_ = 0; + + /** + * + * + *
                    +   * Optional. The default markup syntax for messages sent or read by this Chat
                    +   * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the markupSyntax field is set. + */ + @java.lang.Override + public boolean hasMarkupSyntax() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
                    +   * Optional. The default markup syntax for messages sent or read by this Chat
                    +   * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for markupSyntax. + */ + @java.lang.Override + public int getMarkupSyntaxValue() { + return markupSyntax_; + } + + /** + * + * + *
                    +   * Optional. The default markup syntax for messages sent or read by this Chat
                    +   * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The markupSyntax. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax getMarkupSyntax() { + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax result = + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax.forNumber(markupSyntax_); + return result == null + ? com.google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, displayName_); + } + if (((bitField0_ & 0x00000001) != 0)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, avatarUri_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, description_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeEnum(5, state_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(6, getInteractiveFeatureConfig()); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeBool(7, errorLoggingEnabled_); + } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeEnum(8, markupSyntax_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, displayName_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, avatarUri_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, description_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, state_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 6, getInteractiveFeatureConfig()); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(7, errorLoggingEnabled_); + } + if (((bitField0_ & 0x00000010) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(8, markupSyntax_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.ChatAppConfig)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.ChatAppConfig other = + (com.google.cloud.gsuiteaddons.v1.ChatAppConfig) obj; + + if (!getName().equals(other.getName())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (hasAvatarUri() != other.hasAvatarUri()) return false; + if (hasAvatarUri()) { + if (!getAvatarUri().equals(other.getAvatarUri())) return false; + } + if (!getDescription().equals(other.getDescription())) return false; + if (hasState() != other.hasState()) return false; + if (hasState()) { + if (state_ != other.state_) return false; + } + if (hasInteractiveFeatureConfig() != other.hasInteractiveFeatureConfig()) return false; + if (hasInteractiveFeatureConfig()) { + if (!getInteractiveFeatureConfig().equals(other.getInteractiveFeatureConfig())) return false; + } + if (hasErrorLoggingEnabled() != other.hasErrorLoggingEnabled()) return false; + if (hasErrorLoggingEnabled()) { + if (getErrorLoggingEnabled() != other.getErrorLoggingEnabled()) return false; + } + if (hasMarkupSyntax() != other.hasMarkupSyntax()) return false; + if (hasMarkupSyntax()) { + if (markupSyntax_ != other.markupSyntax_) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + if (hasAvatarUri()) { + hash = (37 * hash) + AVATAR_URI_FIELD_NUMBER; + hash = (53 * hash) + getAvatarUri().hashCode(); + } + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + if (hasState()) { + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + } + if (hasInteractiveFeatureConfig()) { + hash = (37 * hash) + INTERACTIVE_FEATURE_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getInteractiveFeatureConfig().hashCode(); + } + if (hasErrorLoggingEnabled()) { + hash = (37 * hash) + ERROR_LOGGING_ENABLED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getErrorLoggingEnabled()); + } + if (hasMarkupSyntax()) { + hash = (37 * hash) + MARKUP_SYNTAX_FIELD_NUMBER; + hash = (53 * hash) + markupSyntax_; + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.gsuiteaddons.v1.ChatAppConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Represents the configuration of a Google Chat app built as a Google Workspace
                    +   * add-on.
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.ChatAppConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.ChatAppConfig) + com.google.cloud.gsuiteaddons.v1.ChatAppConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_ChatAppConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_ChatAppConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.class, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.ChatAppConfig.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetInteractiveFeatureConfigFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + displayName_ = ""; + avatarUri_ = ""; + description_ = ""; + state_ = 0; + interactiveFeatureConfig_ = null; + if (interactiveFeatureConfigBuilder_ != null) { + interactiveFeatureConfigBuilder_.dispose(); + interactiveFeatureConfigBuilder_ = null; + } + errorLoggingEnabled_ = false; + markupSyntax_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_ChatAppConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.ChatAppConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig build() { + com.google.cloud.gsuiteaddons.v1.ChatAppConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig buildPartial() { + com.google.cloud.gsuiteaddons.v1.ChatAppConfig result = + new com.google.cloud.gsuiteaddons.v1.ChatAppConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.ChatAppConfig result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.displayName_ = displayName_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.avatarUri_ = avatarUri_; + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.description_ = description_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.state_ = state_; + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.interactiveFeatureConfig_ = + interactiveFeatureConfigBuilder_ == null + ? interactiveFeatureConfig_ + : interactiveFeatureConfigBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.errorLoggingEnabled_ = errorLoggingEnabled_; + to_bitField0_ |= 0x00000008; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.markupSyntax_ = markupSyntax_; + to_bitField0_ |= 0x00000010; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.ChatAppConfig) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.ChatAppConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.ChatAppConfig other) { + if (other == com.google.cloud.gsuiteaddons.v1.ChatAppConfig.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasAvatarUri()) { + avatarUri_ = other.avatarUri_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (other.hasState()) { + setStateValue(other.getStateValue()); + } + if (other.hasInteractiveFeatureConfig()) { + mergeInteractiveFeatureConfig(other.getInteractiveFeatureConfig()); + } + if (other.hasErrorLoggingEnabled()) { + setErrorLoggingEnabled(other.getErrorLoggingEnabled()); + } + if (other.hasMarkupSyntax()) { + setMarkupSyntaxValue(other.getMarkupSyntaxValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + avatarUri_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 40: + { + state_ = input.readEnum(); + bitField0_ |= 0x00000010; + break; + } // case 40 + case 50: + { + input.readMessage( + internalGetInteractiveFeatureConfigFieldBuilder().getBuilder(), + extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + case 56: + { + errorLoggingEnabled_ = input.readBool(); + bitField0_ |= 0x00000040; + break; + } // case 56 + case 64: + { + markupSyntax_ = input.readEnum(); + bitField0_ |= 0x00000080; + break; + } // case 64 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
                    +     * Required. Identifier. Resource name of the Chat app configuration.
                    +     *
                    +     * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +     * Cloud project number.
                    +     * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. Identifier. Resource name of the Chat app configuration.
                    +     *
                    +     * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +     * Cloud project number.
                    +     * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. Identifier. Resource name of the Chat app configuration.
                    +     *
                    +     * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +     * Cloud project number.
                    +     * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. Identifier. Resource name of the Chat app configuration.
                    +     *
                    +     * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +     * Cloud project number.
                    +     * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. Identifier. Resource name of the Chat app configuration.
                    +     *
                    +     * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +     * Cloud project number.
                    +     * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + + /** + * + * + *
                    +     * Required. The display name of the Chat app. Length should be between 3 and
                    +     * 25 characters.
                    +     * 
                    + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. The display name of the Chat app. Length should be between 3 and
                    +     * 25 characters.
                    +     * 
                    + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. The display name of the Chat app. Length should be between 3 and
                    +     * 25 characters.
                    +     * 
                    + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The display name of the Chat app. Length should be between 3 and
                    +     * 25 characters.
                    +     * 
                    + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + displayName_ = getDefaultInstance().getDisplayName(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The display name of the Chat app. Length should be between 3 and
                    +     * 25 characters.
                    +     * 
                    + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + displayName_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object avatarUri_ = ""; + + /** + * + * + *
                    +     * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +     * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +     * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +     * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the avatarUri field is set. + */ + public boolean hasAvatarUri() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
                    +     * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +     * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +     * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +     * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The avatarUri. + */ + public java.lang.String getAvatarUri() { + java.lang.Object ref = avatarUri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + avatarUri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +     * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +     * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +     * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for avatarUri. + */ + public com.google.protobuf.ByteString getAvatarUriBytes() { + java.lang.Object ref = avatarUri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + avatarUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +     * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +     * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +     * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The avatarUri to set. + * @return This builder for chaining. + */ + public Builder setAvatarUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + avatarUri_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +     * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +     * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +     * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearAvatarUri() { + avatarUri_ = getDefaultInstance().getAvatarUri(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +     * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +     * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +     * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for avatarUri to set. + * @return This builder for chaining. + */ + public Builder setAvatarUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + avatarUri_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + + /** + * + * + *
                    +     * Required. A short description of the Chat app.
                    +     * Should be between 1 and 40 characters.
                    +     * 
                    + * + * string description = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. A short description of the Chat app.
                    +     * Should be between 1 and 40 characters.
                    +     * 
                    + * + * string description = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. A short description of the Chat app.
                    +     * Should be between 1 and 40 characters.
                    +     * 
                    + * + * string description = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + description_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. A short description of the Chat app.
                    +     * Should be between 1 and 40 characters.
                    +     * 
                    + * + * string description = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + description_ = getDefaultInstance().getDescription(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. A short description of the Chat app.
                    +     * Should be between 1 and 40 characters.
                    +     * 
                    + * + * string description = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private int state_ = 0; + + /** + * + * + *
                    +     * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the state field is set. + */ + @java.lang.Override + public boolean hasState() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
                    +     * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
                    +     * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState getState() { + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState result = + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState.forNumber(state_); + return result == null + ? com.google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState.UNRECOGNIZED + : result; + } + + /** + * + * + *
                    +     * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000010; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000010); + state_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactiveFeatureConfig_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig, + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.Builder, + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfigOrBuilder> + interactiveFeatureConfigBuilder_; + + /** + * + * + *
                    +     * Optional. The settings for interactive features of the app. If this is not
                    +     * provided, the app will be non-interactive, meaning that it can use the Chat
                    +     * API, but users can't interact with the app.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the interactiveFeatureConfig field is set. + */ + public boolean hasInteractiveFeatureConfig() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
                    +     * Optional. The settings for interactive features of the app. If this is not
                    +     * provided, the app will be non-interactive, meaning that it can use the Chat
                    +     * API, but users can't interact with the app.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The interactiveFeatureConfig. + */ + public com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig getInteractiveFeatureConfig() { + if (interactiveFeatureConfigBuilder_ == null) { + return interactiveFeatureConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.getDefaultInstance() + : interactiveFeatureConfig_; + } else { + return interactiveFeatureConfigBuilder_.getMessage(); + } + } + + /** + * + * + *
                    +     * Optional. The settings for interactive features of the app. If this is not
                    +     * provided, the app will be non-interactive, meaning that it can use the Chat
                    +     * API, but users can't interact with the app.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setInteractiveFeatureConfig( + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig value) { + if (interactiveFeatureConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + interactiveFeatureConfig_ = value; + } else { + interactiveFeatureConfigBuilder_.setMessage(value); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The settings for interactive features of the app. If this is not
                    +     * provided, the app will be non-interactive, meaning that it can use the Chat
                    +     * API, but users can't interact with the app.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setInteractiveFeatureConfig( + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.Builder builderForValue) { + if (interactiveFeatureConfigBuilder_ == null) { + interactiveFeatureConfig_ = builderForValue.build(); + } else { + interactiveFeatureConfigBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The settings for interactive features of the app. If this is not
                    +     * provided, the app will be non-interactive, meaning that it can use the Chat
                    +     * API, but users can't interact with the app.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeInteractiveFeatureConfig( + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig value) { + if (interactiveFeatureConfigBuilder_ == null) { + if (((bitField0_ & 0x00000020) != 0) + && interactiveFeatureConfig_ != null + && interactiveFeatureConfig_ + != com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.getDefaultInstance()) { + getInteractiveFeatureConfigBuilder().mergeFrom(value); + } else { + interactiveFeatureConfig_ = value; + } + } else { + interactiveFeatureConfigBuilder_.mergeFrom(value); + } + if (interactiveFeatureConfig_ != null) { + bitField0_ |= 0x00000020; + onChanged(); + } + return this; + } + + /** + * + * + *
                    +     * Optional. The settings for interactive features of the app. If this is not
                    +     * provided, the app will be non-interactive, meaning that it can use the Chat
                    +     * API, but users can't interact with the app.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearInteractiveFeatureConfig() { + bitField0_ = (bitField0_ & ~0x00000020); + interactiveFeatureConfig_ = null; + if (interactiveFeatureConfigBuilder_ != null) { + interactiveFeatureConfigBuilder_.dispose(); + interactiveFeatureConfigBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The settings for interactive features of the app. If this is not
                    +     * provided, the app will be non-interactive, meaning that it can use the Chat
                    +     * API, but users can't interact with the app.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.Builder + getInteractiveFeatureConfigBuilder() { + bitField0_ |= 0x00000020; + onChanged(); + return internalGetInteractiveFeatureConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * Optional. The settings for interactive features of the app. If this is not
                    +     * provided, the app will be non-interactive, meaning that it can use the Chat
                    +     * API, but users can't interact with the app.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfigOrBuilder + getInteractiveFeatureConfigOrBuilder() { + if (interactiveFeatureConfigBuilder_ != null) { + return interactiveFeatureConfigBuilder_.getMessageOrBuilder(); + } else { + return interactiveFeatureConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.getDefaultInstance() + : interactiveFeatureConfig_; + } + } + + /** + * + * + *
                    +     * Optional. The settings for interactive features of the app. If this is not
                    +     * provided, the app will be non-interactive, meaning that it can use the Chat
                    +     * API, but users can't interact with the app.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig, + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.Builder, + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfigOrBuilder> + internalGetInteractiveFeatureConfigFieldBuilder() { + if (interactiveFeatureConfigBuilder_ == null) { + interactiveFeatureConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig, + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.Builder, + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfigOrBuilder>( + getInteractiveFeatureConfig(), getParentForChildren(), isClean()); + interactiveFeatureConfig_ = null; + } + return interactiveFeatureConfigBuilder_; + } + + private boolean errorLoggingEnabled_; + + /** + * + * + *
                    +     * Optional. Whether to log errors to Cloud Logging. Defaults to `false` if
                    +     * not specified.
                    +     * 
                    + * + * optional bool error_logging_enabled = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the errorLoggingEnabled field is set. + */ + @java.lang.Override + public boolean hasErrorLoggingEnabled() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
                    +     * Optional. Whether to log errors to Cloud Logging. Defaults to `false` if
                    +     * not specified.
                    +     * 
                    + * + * optional bool error_logging_enabled = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The errorLoggingEnabled. + */ + @java.lang.Override + public boolean getErrorLoggingEnabled() { + return errorLoggingEnabled_; + } + + /** + * + * + *
                    +     * Optional. Whether to log errors to Cloud Logging. Defaults to `false` if
                    +     * not specified.
                    +     * 
                    + * + * optional bool error_logging_enabled = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The errorLoggingEnabled to set. + * @return This builder for chaining. + */ + public Builder setErrorLoggingEnabled(boolean value) { + + errorLoggingEnabled_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Whether to log errors to Cloud Logging. Defaults to `false` if
                    +     * not specified.
                    +     * 
                    + * + * optional bool error_logging_enabled = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearErrorLoggingEnabled() { + bitField0_ = (bitField0_ & ~0x00000040); + errorLoggingEnabled_ = false; + onChanged(); + return this; + } + + private int markupSyntax_ = 0; + + /** + * + * + *
                    +     * Optional. The default markup syntax for messages sent or read by this Chat
                    +     * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the markupSyntax field is set. + */ + @java.lang.Override + public boolean hasMarkupSyntax() { + return ((bitField0_ & 0x00000080) != 0); + } + + /** + * + * + *
                    +     * Optional. The default markup syntax for messages sent or read by this Chat
                    +     * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for markupSyntax. + */ + @java.lang.Override + public int getMarkupSyntaxValue() { + return markupSyntax_; + } + + /** + * + * + *
                    +     * Optional. The default markup syntax for messages sent or read by this Chat
                    +     * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for markupSyntax to set. + * @return This builder for chaining. + */ + public Builder setMarkupSyntaxValue(int value) { + markupSyntax_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The default markup syntax for messages sent or read by this Chat
                    +     * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The markupSyntax. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax getMarkupSyntax() { + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax result = + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax.forNumber(markupSyntax_); + return result == null + ? com.google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax.UNRECOGNIZED + : result; + } + + /** + * + * + *
                    +     * Optional. The default markup syntax for messages sent or read by this Chat
                    +     * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The markupSyntax to set. + * @return This builder for chaining. + */ + public Builder setMarkupSyntax( + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000080; + markupSyntax_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The default markup syntax for messages sent or read by this Chat
                    +     * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +     * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearMarkupSyntax() { + bitField0_ = (bitField0_ & ~0x00000080); + markupSyntax_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.ChatAppConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.ChatAppConfig) + private static final com.google.cloud.gsuiteaddons.v1.ChatAppConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.ChatAppConfig(); + } + + public static com.google.cloud.gsuiteaddons.v1.ChatAppConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ChatAppConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ChatAppConfigName.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ChatAppConfigName.java new file mode 100644 index 000000000000..375ebc4ff5c2 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ChatAppConfigName.java @@ -0,0 +1,171 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.gsuiteaddons.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class ChatAppConfigName implements ResourceName { + private static final PathTemplate PROJECT = + PathTemplate.createWithoutUrlEncoding("projects/{project}/chatAppConfig"); + private volatile Map fieldValuesMap; + private final String project; + + @Deprecated + protected ChatAppConfigName() { + project = null; + } + + private ChatAppConfigName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + } + + public String getProject() { + return project; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static ChatAppConfigName of(String project) { + return newBuilder().setProject(project).build(); + } + + public static String format(String project) { + return newBuilder().setProject(project).build().toString(); + } + + public static @Nullable ChatAppConfigName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT.validatedMatch( + formattedString, "ChatAppConfigName.parse: formattedString not in valid format"); + return of(matchMap.get("project")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable ChatAppConfigName> values) { + List list = new ArrayList<>(values.size()); + for (ChatAppConfigName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT.instantiate("project", project); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + ChatAppConfigName that = ((ChatAppConfigName) o); + return Objects.equals(this.project, that.project); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + return h; + } + + /** Builder for projects/{project}/chatAppConfig. */ + public static class Builder { + private String project; + + protected Builder() {} + + public String getProject() { + return project; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + private Builder(ChatAppConfigName chatAppConfigName) { + this.project = chatAppConfigName.project; + } + + public ChatAppConfigName build() { + return new ChatAppConfigName(this); + } + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ChatAppConfigOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ChatAppConfigOrBuilder.java new file mode 100644 index 000000000000..fa3a5277195e --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ChatAppConfigOrBuilder.java @@ -0,0 +1,336 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface ChatAppConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.ChatAppConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Required. Identifier. Resource name of the Chat app configuration.
                    +   *
                    +   * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +   * Cloud project number.
                    +   * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
                    +   * Required. Identifier. Resource name of the Chat app configuration.
                    +   *
                    +   * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +   * Cloud project number.
                    +   * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
                    +   * Required. The display name of the Chat app. Length should be between 3 and
                    +   * 25 characters.
                    +   * 
                    + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
                    +   * Required. The display name of the Chat app. Length should be between 3 and
                    +   * 25 characters.
                    +   * 
                    + * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
                    +   * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +   * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +   * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +   * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the avatarUri field is set. + */ + boolean hasAvatarUri(); + + /** + * + * + *
                    +   * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +   * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +   * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +   * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The avatarUri. + */ + java.lang.String getAvatarUri(); + + /** + * + * + *
                    +   * Optional. The URL for the app's avatar image. Must be an HTTPS URL that
                    +   * hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size:
                    +   * 256 by 256 pixels. A default app avatar will be used if not specified.
                    +   * 
                    + * + * optional string avatar_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for avatarUri. + */ + com.google.protobuf.ByteString getAvatarUriBytes(); + + /** + * + * + *
                    +   * Required. A short description of the Chat app.
                    +   * Should be between 1 and 40 characters.
                    +   * 
                    + * + * string description = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
                    +   * Required. A short description of the Chat app.
                    +   * Should be between 1 and 40 characters.
                    +   * 
                    + * + * string description = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
                    +   * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the state field is set. + */ + boolean hasState(); + + /** + * + * + *
                    +   * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
                    +   * Optional. The state of the app. Defaults to `ACTIVE` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState state = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The state. + */ + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.AppState getState(); + + /** + * + * + *
                    +   * Optional. The settings for interactive features of the app. If this is not
                    +   * provided, the app will be non-interactive, meaning that it can use the Chat
                    +   * API, but users can't interact with the app.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the interactiveFeatureConfig field is set. + */ + boolean hasInteractiveFeatureConfig(); + + /** + * + * + *
                    +   * Optional. The settings for interactive features of the app. If this is not
                    +   * provided, the app will be non-interactive, meaning that it can use the Chat
                    +   * API, but users can't interact with the app.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The interactiveFeatureConfig. + */ + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig getInteractiveFeatureConfig(); + + /** + * + * + *
                    +   * Optional. The settings for interactive features of the app. If this is not
                    +   * provided, the app will be non-interactive, meaning that it can use the Chat
                    +   * API, but users can't interact with the app.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig interactive_feature_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfigOrBuilder + getInteractiveFeatureConfigOrBuilder(); + + /** + * + * + *
                    +   * Optional. Whether to log errors to Cloud Logging. Defaults to `false` if
                    +   * not specified.
                    +   * 
                    + * + * optional bool error_logging_enabled = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the errorLoggingEnabled field is set. + */ + boolean hasErrorLoggingEnabled(); + + /** + * + * + *
                    +   * Optional. Whether to log errors to Cloud Logging. Defaults to `false` if
                    +   * not specified.
                    +   * 
                    + * + * optional bool error_logging_enabled = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The errorLoggingEnabled. + */ + boolean getErrorLoggingEnabled(); + + /** + * + * + *
                    +   * Optional. The default markup syntax for messages sent or read by this Chat
                    +   * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the markupSyntax field is set. + */ + boolean hasMarkupSyntax(); + + /** + * + * + *
                    +   * Optional. The default markup syntax for messages sent or read by this Chat
                    +   * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for markupSyntax. + */ + int getMarkupSyntaxValue(); + + /** + * + * + *
                    +   * Optional. The default markup syntax for messages sent or read by this Chat
                    +   * app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified.
                    +   * 
                    + * + * + * optional .google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax markup_syntax = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The markupSyntax. + */ + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.MarkupSyntax getMarkupSyntax(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/CloudPubSubEndpointConfig.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/CloudPubSubEndpointConfig.java new file mode 100644 index 000000000000..2f2e4c26ad18 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/CloudPubSubEndpointConfig.java @@ -0,0 +1,653 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * Pub/Sub endpoint configuration.
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig} + */ +@com.google.protobuf.Generated +public final class CloudPubSubEndpointConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) + CloudPubSubEndpointConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "CloudPubSubEndpointConfig"); + } + + // Use CloudPubSubEndpointConfig.newBuilder() to construct. + private CloudPubSubEndpointConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private CloudPubSubEndpointConfig() { + topic_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_CloudPubSubEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_CloudPubSubEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.Builder.class); + } + + public static final int TOPIC_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object topic_ = ""; + + /** + * + * + *
                    +   * Required. The Pub/Sub topic to which Google Chat publishes all interactive
                    +   * events. The topic must be in the same Google Cloud project as the app, and
                    +   * Chat must have permission to publish messages to the topic. For details,
                    +   * see [Build a Google Chat app with
                    +   * Pub/Sub](https://developers.google.com/workspace/chat/quickstart/pub-sub#configure-chat-app).
                    +   *
                    +   * Format: `projects/{project}/topics/{topic}`
                    +   * 
                    + * + * + * string topic = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The topic. + */ + @java.lang.Override + public java.lang.String getTopic() { + java.lang.Object ref = topic_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + topic_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. The Pub/Sub topic to which Google Chat publishes all interactive
                    +   * events. The topic must be in the same Google Cloud project as the app, and
                    +   * Chat must have permission to publish messages to the topic. For details,
                    +   * see [Build a Google Chat app with
                    +   * Pub/Sub](https://developers.google.com/workspace/chat/quickstart/pub-sub#configure-chat-app).
                    +   *
                    +   * Format: `projects/{project}/topics/{topic}`
                    +   * 
                    + * + * + * string topic = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for topic. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTopicBytes() { + java.lang.Object ref = topic_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + topic_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(topic_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, topic_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(topic_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, topic_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig other = + (com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) obj; + + if (!getTopic().equals(other.getTopic())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TOPIC_FIELD_NUMBER; + hash = (53 * hash) + getTopic().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Pub/Sub endpoint configuration.
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_CloudPubSubEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_CloudPubSubEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + topic_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_CloudPubSubEndpointConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig build() { + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig buildPartial() { + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig result = + new com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.topic_ = topic_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig other) { + if (other == com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.getDefaultInstance()) + return this; + if (!other.getTopic().isEmpty()) { + topic_ = other.topic_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + topic_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object topic_ = ""; + + /** + * + * + *
                    +     * Required. The Pub/Sub topic to which Google Chat publishes all interactive
                    +     * events. The topic must be in the same Google Cloud project as the app, and
                    +     * Chat must have permission to publish messages to the topic. For details,
                    +     * see [Build a Google Chat app with
                    +     * Pub/Sub](https://developers.google.com/workspace/chat/quickstart/pub-sub#configure-chat-app).
                    +     *
                    +     * Format: `projects/{project}/topics/{topic}`
                    +     * 
                    + * + * + * string topic = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The topic. + */ + public java.lang.String getTopic() { + java.lang.Object ref = topic_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + topic_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. The Pub/Sub topic to which Google Chat publishes all interactive
                    +     * events. The topic must be in the same Google Cloud project as the app, and
                    +     * Chat must have permission to publish messages to the topic. For details,
                    +     * see [Build a Google Chat app with
                    +     * Pub/Sub](https://developers.google.com/workspace/chat/quickstart/pub-sub#configure-chat-app).
                    +     *
                    +     * Format: `projects/{project}/topics/{topic}`
                    +     * 
                    + * + * + * string topic = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for topic. + */ + public com.google.protobuf.ByteString getTopicBytes() { + java.lang.Object ref = topic_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + topic_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. The Pub/Sub topic to which Google Chat publishes all interactive
                    +     * events. The topic must be in the same Google Cloud project as the app, and
                    +     * Chat must have permission to publish messages to the topic. For details,
                    +     * see [Build a Google Chat app with
                    +     * Pub/Sub](https://developers.google.com/workspace/chat/quickstart/pub-sub#configure-chat-app).
                    +     *
                    +     * Format: `projects/{project}/topics/{topic}`
                    +     * 
                    + * + * + * string topic = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The topic to set. + * @return This builder for chaining. + */ + public Builder setTopic(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + topic_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The Pub/Sub topic to which Google Chat publishes all interactive
                    +     * events. The topic must be in the same Google Cloud project as the app, and
                    +     * Chat must have permission to publish messages to the topic. For details,
                    +     * see [Build a Google Chat app with
                    +     * Pub/Sub](https://developers.google.com/workspace/chat/quickstart/pub-sub#configure-chat-app).
                    +     *
                    +     * Format: `projects/{project}/topics/{topic}`
                    +     * 
                    + * + * + * string topic = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearTopic() { + topic_ = getDefaultInstance().getTopic(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The Pub/Sub topic to which Google Chat publishes all interactive
                    +     * events. The topic must be in the same Google Cloud project as the app, and
                    +     * Chat must have permission to publish messages to the topic. For details,
                    +     * see [Build a Google Chat app with
                    +     * Pub/Sub](https://developers.google.com/workspace/chat/quickstart/pub-sub#configure-chat-app).
                    +     *
                    +     * Format: `projects/{project}/topics/{topic}`
                    +     * 
                    + * + * + * string topic = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for topic to set. + * @return This builder for chaining. + */ + public Builder setTopicBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + topic_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) + private static final com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig(); + } + + public static com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CloudPubSubEndpointConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/CloudPubSubEndpointConfigOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/CloudPubSubEndpointConfigOrBuilder.java new file mode 100644 index 000000000000..5c702ca08f31 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/CloudPubSubEndpointConfigOrBuilder.java @@ -0,0 +1,70 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface CloudPubSubEndpointConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Required. The Pub/Sub topic to which Google Chat publishes all interactive
                    +   * events. The topic must be in the same Google Cloud project as the app, and
                    +   * Chat must have permission to publish messages to the topic. For details,
                    +   * see [Build a Google Chat app with
                    +   * Pub/Sub](https://developers.google.com/workspace/chat/quickstart/pub-sub#configure-chat-app).
                    +   *
                    +   * Format: `projects/{project}/topics/{topic}`
                    +   * 
                    + * + * + * string topic = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The topic. + */ + java.lang.String getTopic(); + + /** + * + * + *
                    +   * Required. The Pub/Sub topic to which Google Chat publishes all interactive
                    +   * events. The topic must be in the same Google Cloud project as the app, and
                    +   * Chat must have permission to publish messages to the topic. For details,
                    +   * see [Build a Google Chat app with
                    +   * Pub/Sub](https://developers.google.com/workspace/chat/quickstart/pub-sub#configure-chat-app).
                    +   *
                    +   * Format: `projects/{project}/topics/{topic}`
                    +   * 
                    + * + * + * string topic = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for topic. + */ + com.google.protobuf.ByteString getTopicBytes(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ConnectionConfig.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ConnectionConfig.java new file mode 100644 index 000000000000..90f70a5391d7 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ConnectionConfig.java @@ -0,0 +1,1799 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * How the app receives events.
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.ConnectionConfig} + */ +@com.google.protobuf.Generated +public final class ConnectionConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.ConnectionConfig) + ConnectionConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ConnectionConfig"); + } + + // Use ConnectionConfig.newBuilder() to construct. + private ConnectionConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ConnectionConfig() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_ConnectionConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_ConnectionConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.ConnectionConfig.class, + com.google.cloud.gsuiteaddons.v1.ConnectionConfig.Builder.class); + } + + private int configCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object config_; + + public enum ConfigCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + HTTP_ENDPOINT_CONFIG(1), + APPS_SCRIPT_ENDPOINT_CONFIG(2), + CLOUD_PUB_SUB_ENDPOINT_CONFIG(3), + DIALOGFLOW_ENDPOINT_CONFIG(4), + CONFIG_NOT_SET(0); + private final int value; + + private ConfigCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ConfigCase valueOf(int value) { + return forNumber(value); + } + + public static ConfigCase forNumber(int value) { + switch (value) { + case 1: + return HTTP_ENDPOINT_CONFIG; + case 2: + return APPS_SCRIPT_ENDPOINT_CONFIG; + case 3: + return CLOUD_PUB_SUB_ENDPOINT_CONFIG; + case 4: + return DIALOGFLOW_ENDPOINT_CONFIG; + case 0: + return CONFIG_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ConfigCase getConfigCase() { + return ConfigCase.forNumber(configCase_); + } + + public static final int HTTP_ENDPOINT_CONFIG_FIELD_NUMBER = 1; + + /** + * + * + *
                    +   * HTTP endpoint configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + * + * @return Whether the httpEndpointConfig field is set. + */ + @java.lang.Override + public boolean hasHttpEndpointConfig() { + return configCase_ == 1; + } + + /** + * + * + *
                    +   * HTTP endpoint configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + * + * @return The httpEndpointConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig getHttpEndpointConfig() { + if (configCase_ == 1) { + return (com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.getDefaultInstance(); + } + + /** + * + * + *
                    +   * HTTP endpoint configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpEndpointConfigOrBuilder + getHttpEndpointConfigOrBuilder() { + if (configCase_ == 1) { + return (com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.getDefaultInstance(); + } + + public static final int APPS_SCRIPT_ENDPOINT_CONFIG_FIELD_NUMBER = 2; + + /** + * + * + *
                    +   * Apps Script deployment configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + * + * @return Whether the appsScriptEndpointConfig field is set. + */ + @java.lang.Override + public boolean hasAppsScriptEndpointConfig() { + return configCase_ == 2; + } + + /** + * + * + *
                    +   * Apps Script deployment configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + * + * @return The appsScriptEndpointConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig getAppsScriptEndpointConfig() { + if (configCase_ == 2) { + return (com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.getDefaultInstance(); + } + + /** + * + * + *
                    +   * Apps Script deployment configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfigOrBuilder + getAppsScriptEndpointConfigOrBuilder() { + if (configCase_ == 2) { + return (com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.getDefaultInstance(); + } + + public static final int CLOUD_PUB_SUB_ENDPOINT_CONFIG_FIELD_NUMBER = 3; + + /** + * + * + *
                    +   * Pub/Sub topic configuration.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + * + * @return Whether the cloudPubSubEndpointConfig field is set. + */ + @java.lang.Override + public boolean hasCloudPubSubEndpointConfig() { + return configCase_ == 3; + } + + /** + * + * + *
                    +   * Pub/Sub topic configuration.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + * + * @return The cloudPubSubEndpointConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig getCloudPubSubEndpointConfig() { + if (configCase_ == 3) { + return (com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.getDefaultInstance(); + } + + /** + * + * + *
                    +   * Pub/Sub topic configuration.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfigOrBuilder + getCloudPubSubEndpointConfigOrBuilder() { + if (configCase_ == 3) { + return (com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.getDefaultInstance(); + } + + public static final int DIALOGFLOW_ENDPOINT_CONFIG_FIELD_NUMBER = 4; + + /** + * + * + *
                    +   * Dialogflow configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + * + * @return Whether the dialogflowEndpointConfig field is set. + */ + @java.lang.Override + public boolean hasDialogflowEndpointConfig() { + return configCase_ == 4; + } + + /** + * + * + *
                    +   * Dialogflow configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + * + * @return The dialogflowEndpointConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig getDialogflowEndpointConfig() { + if (configCase_ == 4) { + return (com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.getDefaultInstance(); + } + + /** + * + * + *
                    +   * Dialogflow configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfigOrBuilder + getDialogflowEndpointConfigOrBuilder() { + if (configCase_ == 4) { + return (com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (configCase_ == 1) { + output.writeMessage(1, (com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig) config_); + } + if (configCase_ == 2) { + output.writeMessage(2, (com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) config_); + } + if (configCase_ == 3) { + output.writeMessage(3, (com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) config_); + } + if (configCase_ == 4) { + output.writeMessage(4, (com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) config_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (configCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig) config_); + } + if (configCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) config_); + } + if (configCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) config_); + } + if (configCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) config_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.ConnectionConfig)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.ConnectionConfig other = + (com.google.cloud.gsuiteaddons.v1.ConnectionConfig) obj; + + if (!getConfigCase().equals(other.getConfigCase())) return false; + switch (configCase_) { + case 1: + if (!getHttpEndpointConfig().equals(other.getHttpEndpointConfig())) return false; + break; + case 2: + if (!getAppsScriptEndpointConfig().equals(other.getAppsScriptEndpointConfig())) + return false; + break; + case 3: + if (!getCloudPubSubEndpointConfig().equals(other.getCloudPubSubEndpointConfig())) + return false; + break; + case 4: + if (!getDialogflowEndpointConfig().equals(other.getDialogflowEndpointConfig())) + return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (configCase_) { + case 1: + hash = (37 * hash) + HTTP_ENDPOINT_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getHttpEndpointConfig().hashCode(); + break; + case 2: + hash = (37 * hash) + APPS_SCRIPT_ENDPOINT_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getAppsScriptEndpointConfig().hashCode(); + break; + case 3: + hash = (37 * hash) + CLOUD_PUB_SUB_ENDPOINT_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getCloudPubSubEndpointConfig().hashCode(); + break; + case 4: + hash = (37 * hash) + DIALOGFLOW_ENDPOINT_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getDialogflowEndpointConfig().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.gsuiteaddons.v1.ConnectionConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * How the app receives events.
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.ConnectionConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.ConnectionConfig) + com.google.cloud.gsuiteaddons.v1.ConnectionConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_ConnectionConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_ConnectionConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.ConnectionConfig.class, + com.google.cloud.gsuiteaddons.v1.ConnectionConfig.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.ConnectionConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (httpEndpointConfigBuilder_ != null) { + httpEndpointConfigBuilder_.clear(); + } + if (appsScriptEndpointConfigBuilder_ != null) { + appsScriptEndpointConfigBuilder_.clear(); + } + if (cloudPubSubEndpointConfigBuilder_ != null) { + cloudPubSubEndpointConfigBuilder_.clear(); + } + if (dialogflowEndpointConfigBuilder_ != null) { + dialogflowEndpointConfigBuilder_.clear(); + } + configCase_ = 0; + config_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_ConnectionConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ConnectionConfig getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.ConnectionConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ConnectionConfig build() { + com.google.cloud.gsuiteaddons.v1.ConnectionConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ConnectionConfig buildPartial() { + com.google.cloud.gsuiteaddons.v1.ConnectionConfig result = + new com.google.cloud.gsuiteaddons.v1.ConnectionConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.ConnectionConfig result) { + int from_bitField0_ = bitField0_; + } + + private void buildPartialOneofs(com.google.cloud.gsuiteaddons.v1.ConnectionConfig result) { + result.configCase_ = configCase_; + result.config_ = this.config_; + if (configCase_ == 1 && httpEndpointConfigBuilder_ != null) { + result.config_ = httpEndpointConfigBuilder_.build(); + } + if (configCase_ == 2 && appsScriptEndpointConfigBuilder_ != null) { + result.config_ = appsScriptEndpointConfigBuilder_.build(); + } + if (configCase_ == 3 && cloudPubSubEndpointConfigBuilder_ != null) { + result.config_ = cloudPubSubEndpointConfigBuilder_.build(); + } + if (configCase_ == 4 && dialogflowEndpointConfigBuilder_ != null) { + result.config_ = dialogflowEndpointConfigBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.ConnectionConfig) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.ConnectionConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.ConnectionConfig other) { + if (other == com.google.cloud.gsuiteaddons.v1.ConnectionConfig.getDefaultInstance()) + return this; + switch (other.getConfigCase()) { + case HTTP_ENDPOINT_CONFIG: + { + mergeHttpEndpointConfig(other.getHttpEndpointConfig()); + break; + } + case APPS_SCRIPT_ENDPOINT_CONFIG: + { + mergeAppsScriptEndpointConfig(other.getAppsScriptEndpointConfig()); + break; + } + case CLOUD_PUB_SUB_ENDPOINT_CONFIG: + { + mergeCloudPubSubEndpointConfig(other.getCloudPubSubEndpointConfig()); + break; + } + case DIALOGFLOW_ENDPOINT_CONFIG: + { + mergeDialogflowEndpointConfig(other.getDialogflowEndpointConfig()); + break; + } + case CONFIG_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetHttpEndpointConfigFieldBuilder().getBuilder(), extensionRegistry); + configCase_ = 1; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetAppsScriptEndpointConfigFieldBuilder().getBuilder(), + extensionRegistry); + configCase_ = 2; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetCloudPubSubEndpointConfigFieldBuilder().getBuilder(), + extensionRegistry); + configCase_ = 3; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetDialogflowEndpointConfigFieldBuilder().getBuilder(), + extensionRegistry); + configCase_ = 4; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int configCase_ = 0; + private java.lang.Object config_; + + public ConfigCase getConfigCase() { + return ConfigCase.forNumber(configCase_); + } + + public Builder clearConfig() { + configCase_ = 0; + config_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig, + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfigOrBuilder> + httpEndpointConfigBuilder_; + + /** + * + * + *
                    +     * HTTP endpoint configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + * + * @return Whether the httpEndpointConfig field is set. + */ + @java.lang.Override + public boolean hasHttpEndpointConfig() { + return configCase_ == 1; + } + + /** + * + * + *
                    +     * HTTP endpoint configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + * + * @return The httpEndpointConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig getHttpEndpointConfig() { + if (httpEndpointConfigBuilder_ == null) { + if (configCase_ == 1) { + return (com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.getDefaultInstance(); + } else { + if (configCase_ == 1) { + return httpEndpointConfigBuilder_.getMessage(); + } + return com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                    +     * HTTP endpoint configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + */ + public Builder setHttpEndpointConfig( + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig value) { + if (httpEndpointConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + httpEndpointConfigBuilder_.setMessage(value); + } + configCase_ = 1; + return this; + } + + /** + * + * + *
                    +     * HTTP endpoint configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + */ + public Builder setHttpEndpointConfig( + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.Builder builderForValue) { + if (httpEndpointConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + httpEndpointConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 1; + return this; + } + + /** + * + * + *
                    +     * HTTP endpoint configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + */ + public Builder mergeHttpEndpointConfig( + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig value) { + if (httpEndpointConfigBuilder_ == null) { + if (configCase_ == 1 + && config_ + != com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.getDefaultInstance()) { + config_ = + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.newBuilder( + (com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 1) { + httpEndpointConfigBuilder_.mergeFrom(value); + } else { + httpEndpointConfigBuilder_.setMessage(value); + } + } + configCase_ = 1; + return this; + } + + /** + * + * + *
                    +     * HTTP endpoint configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + */ + public Builder clearHttpEndpointConfig() { + if (httpEndpointConfigBuilder_ == null) { + if (configCase_ == 1) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 1) { + configCase_ = 0; + config_ = null; + } + httpEndpointConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                    +     * HTTP endpoint configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + */ + public com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.Builder + getHttpEndpointConfigBuilder() { + return internalGetHttpEndpointConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * HTTP endpoint configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpEndpointConfigOrBuilder + getHttpEndpointConfigOrBuilder() { + if ((configCase_ == 1) && (httpEndpointConfigBuilder_ != null)) { + return httpEndpointConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 1) { + return (com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                    +     * HTTP endpoint configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig, + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfigOrBuilder> + internalGetHttpEndpointConfigFieldBuilder() { + if (httpEndpointConfigBuilder_ == null) { + if (!(configCase_ == 1)) { + config_ = com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.getDefaultInstance(); + } + httpEndpointConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig, + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfigOrBuilder>( + (com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 1; + onChanged(); + return httpEndpointConfigBuilder_; + } + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig, + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfigOrBuilder> + appsScriptEndpointConfigBuilder_; + + /** + * + * + *
                    +     * Apps Script deployment configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + * + * @return Whether the appsScriptEndpointConfig field is set. + */ + @java.lang.Override + public boolean hasAppsScriptEndpointConfig() { + return configCase_ == 2; + } + + /** + * + * + *
                    +     * Apps Script deployment configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + * + * @return The appsScriptEndpointConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig getAppsScriptEndpointConfig() { + if (appsScriptEndpointConfigBuilder_ == null) { + if (configCase_ == 2) { + return (com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.getDefaultInstance(); + } else { + if (configCase_ == 2) { + return appsScriptEndpointConfigBuilder_.getMessage(); + } + return com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                    +     * Apps Script deployment configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + */ + public Builder setAppsScriptEndpointConfig( + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig value) { + if (appsScriptEndpointConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + appsScriptEndpointConfigBuilder_.setMessage(value); + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                    +     * Apps Script deployment configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + */ + public Builder setAppsScriptEndpointConfig( + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.Builder builderForValue) { + if (appsScriptEndpointConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + appsScriptEndpointConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                    +     * Apps Script deployment configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + */ + public Builder mergeAppsScriptEndpointConfig( + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig value) { + if (appsScriptEndpointConfigBuilder_ == null) { + if (configCase_ == 2 + && config_ + != com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.getDefaultInstance()) { + config_ = + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.newBuilder( + (com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 2) { + appsScriptEndpointConfigBuilder_.mergeFrom(value); + } else { + appsScriptEndpointConfigBuilder_.setMessage(value); + } + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                    +     * Apps Script deployment configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + */ + public Builder clearAppsScriptEndpointConfig() { + if (appsScriptEndpointConfigBuilder_ == null) { + if (configCase_ == 2) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 2) { + configCase_ = 0; + config_ = null; + } + appsScriptEndpointConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                    +     * Apps Script deployment configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + */ + public com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.Builder + getAppsScriptEndpointConfigBuilder() { + return internalGetAppsScriptEndpointConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * Apps Script deployment configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfigOrBuilder + getAppsScriptEndpointConfigOrBuilder() { + if ((configCase_ == 2) && (appsScriptEndpointConfigBuilder_ != null)) { + return appsScriptEndpointConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 2) { + return (com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                    +     * Apps Script deployment configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig, + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfigOrBuilder> + internalGetAppsScriptEndpointConfigFieldBuilder() { + if (appsScriptEndpointConfigBuilder_ == null) { + if (!(configCase_ == 2)) { + config_ = com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.getDefaultInstance(); + } + appsScriptEndpointConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig, + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfigOrBuilder>( + (com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 2; + onChanged(); + return appsScriptEndpointConfigBuilder_; + } + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig, + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfigOrBuilder> + cloudPubSubEndpointConfigBuilder_; + + /** + * + * + *
                    +     * Pub/Sub topic configuration.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + * + * @return Whether the cloudPubSubEndpointConfig field is set. + */ + @java.lang.Override + public boolean hasCloudPubSubEndpointConfig() { + return configCase_ == 3; + } + + /** + * + * + *
                    +     * Pub/Sub topic configuration.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + * + * @return The cloudPubSubEndpointConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig + getCloudPubSubEndpointConfig() { + if (cloudPubSubEndpointConfigBuilder_ == null) { + if (configCase_ == 3) { + return (com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.getDefaultInstance(); + } else { + if (configCase_ == 3) { + return cloudPubSubEndpointConfigBuilder_.getMessage(); + } + return com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                    +     * Pub/Sub topic configuration.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + */ + public Builder setCloudPubSubEndpointConfig( + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig value) { + if (cloudPubSubEndpointConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + cloudPubSubEndpointConfigBuilder_.setMessage(value); + } + configCase_ = 3; + return this; + } + + /** + * + * + *
                    +     * Pub/Sub topic configuration.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + */ + public Builder setCloudPubSubEndpointConfig( + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.Builder builderForValue) { + if (cloudPubSubEndpointConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + cloudPubSubEndpointConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 3; + return this; + } + + /** + * + * + *
                    +     * Pub/Sub topic configuration.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + */ + public Builder mergeCloudPubSubEndpointConfig( + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig value) { + if (cloudPubSubEndpointConfigBuilder_ == null) { + if (configCase_ == 3 + && config_ + != com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig + .getDefaultInstance()) { + config_ = + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.newBuilder( + (com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 3) { + cloudPubSubEndpointConfigBuilder_.mergeFrom(value); + } else { + cloudPubSubEndpointConfigBuilder_.setMessage(value); + } + } + configCase_ = 3; + return this; + } + + /** + * + * + *
                    +     * Pub/Sub topic configuration.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + */ + public Builder clearCloudPubSubEndpointConfig() { + if (cloudPubSubEndpointConfigBuilder_ == null) { + if (configCase_ == 3) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 3) { + configCase_ = 0; + config_ = null; + } + cloudPubSubEndpointConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                    +     * Pub/Sub topic configuration.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + */ + public com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.Builder + getCloudPubSubEndpointConfigBuilder() { + return internalGetCloudPubSubEndpointConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * Pub/Sub topic configuration.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfigOrBuilder + getCloudPubSubEndpointConfigOrBuilder() { + if ((configCase_ == 3) && (cloudPubSubEndpointConfigBuilder_ != null)) { + return cloudPubSubEndpointConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 3) { + return (com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                    +     * Pub/Sub topic configuration.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig, + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfigOrBuilder> + internalGetCloudPubSubEndpointConfigFieldBuilder() { + if (cloudPubSubEndpointConfigBuilder_ == null) { + if (!(configCase_ == 3)) { + config_ = com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.getDefaultInstance(); + } + cloudPubSubEndpointConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig, + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfigOrBuilder>( + (com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 3; + onChanged(); + return cloudPubSubEndpointConfigBuilder_; + } + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig, + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfigOrBuilder> + dialogflowEndpointConfigBuilder_; + + /** + * + * + *
                    +     * Dialogflow configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + * + * @return Whether the dialogflowEndpointConfig field is set. + */ + @java.lang.Override + public boolean hasDialogflowEndpointConfig() { + return configCase_ == 4; + } + + /** + * + * + *
                    +     * Dialogflow configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + * + * @return The dialogflowEndpointConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig getDialogflowEndpointConfig() { + if (dialogflowEndpointConfigBuilder_ == null) { + if (configCase_ == 4) { + return (com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.getDefaultInstance(); + } else { + if (configCase_ == 4) { + return dialogflowEndpointConfigBuilder_.getMessage(); + } + return com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                    +     * Dialogflow configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + */ + public Builder setDialogflowEndpointConfig( + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig value) { + if (dialogflowEndpointConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + dialogflowEndpointConfigBuilder_.setMessage(value); + } + configCase_ = 4; + return this; + } + + /** + * + * + *
                    +     * Dialogflow configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + */ + public Builder setDialogflowEndpointConfig( + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.Builder builderForValue) { + if (dialogflowEndpointConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + dialogflowEndpointConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 4; + return this; + } + + /** + * + * + *
                    +     * Dialogflow configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + */ + public Builder mergeDialogflowEndpointConfig( + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig value) { + if (dialogflowEndpointConfigBuilder_ == null) { + if (configCase_ == 4 + && config_ + != com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.getDefaultInstance()) { + config_ = + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.newBuilder( + (com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 4) { + dialogflowEndpointConfigBuilder_.mergeFrom(value); + } else { + dialogflowEndpointConfigBuilder_.setMessage(value); + } + } + configCase_ = 4; + return this; + } + + /** + * + * + *
                    +     * Dialogflow configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + */ + public Builder clearDialogflowEndpointConfig() { + if (dialogflowEndpointConfigBuilder_ == null) { + if (configCase_ == 4) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 4) { + configCase_ = 0; + config_ = null; + } + dialogflowEndpointConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                    +     * Dialogflow configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + */ + public com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.Builder + getDialogflowEndpointConfigBuilder() { + return internalGetDialogflowEndpointConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * Dialogflow configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfigOrBuilder + getDialogflowEndpointConfigOrBuilder() { + if ((configCase_ == 4) && (dialogflowEndpointConfigBuilder_ != null)) { + return dialogflowEndpointConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 4) { + return (com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                    +     * Dialogflow configuration.
                    +     * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig, + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfigOrBuilder> + internalGetDialogflowEndpointConfigFieldBuilder() { + if (dialogflowEndpointConfigBuilder_ == null) { + if (!(configCase_ == 4)) { + config_ = com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.getDefaultInstance(); + } + dialogflowEndpointConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig, + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfigOrBuilder>( + (com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 4; + onChanged(); + return dialogflowEndpointConfigBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.ConnectionConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.ConnectionConfig) + private static final com.google.cloud.gsuiteaddons.v1.ConnectionConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.ConnectionConfig(); + } + + public static com.google.cloud.gsuiteaddons.v1.ConnectionConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ConnectionConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ConnectionConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ConnectionConfigOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ConnectionConfigOrBuilder.java new file mode 100644 index 000000000000..58ed3e9c1f51 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/ConnectionConfigOrBuilder.java @@ -0,0 +1,193 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface ConnectionConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.ConnectionConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * HTTP endpoint configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + * + * @return Whether the httpEndpointConfig field is set. + */ + boolean hasHttpEndpointConfig(); + + /** + * + * + *
                    +   * HTTP endpoint configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + * + * @return The httpEndpointConfig. + */ + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig getHttpEndpointConfig(); + + /** + * + * + *
                    +   * HTTP endpoint configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.HttpEndpointConfig http_endpoint_config = 1; + */ + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfigOrBuilder getHttpEndpointConfigOrBuilder(); + + /** + * + * + *
                    +   * Apps Script deployment configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + * + * @return Whether the appsScriptEndpointConfig field is set. + */ + boolean hasAppsScriptEndpointConfig(); + + /** + * + * + *
                    +   * Apps Script deployment configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + * + * @return The appsScriptEndpointConfig. + */ + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig getAppsScriptEndpointConfig(); + + /** + * + * + *
                    +   * Apps Script deployment configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfig apps_script_endpoint_config = 2; + * + */ + com.google.cloud.gsuiteaddons.v1.AppsScriptEndpointConfigOrBuilder + getAppsScriptEndpointConfigOrBuilder(); + + /** + * + * + *
                    +   * Pub/Sub topic configuration.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + * + * @return Whether the cloudPubSubEndpointConfig field is set. + */ + boolean hasCloudPubSubEndpointConfig(); + + /** + * + * + *
                    +   * Pub/Sub topic configuration.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + * + * @return The cloudPubSubEndpointConfig. + */ + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig getCloudPubSubEndpointConfig(); + + /** + * + * + *
                    +   * Pub/Sub topic configuration.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + * + */ + com.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfigOrBuilder + getCloudPubSubEndpointConfigOrBuilder(); + + /** + * + * + *
                    +   * Dialogflow configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + * + * @return Whether the dialogflowEndpointConfig field is set. + */ + boolean hasDialogflowEndpointConfig(); + + /** + * + * + *
                    +   * Dialogflow configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + * + * @return The dialogflowEndpointConfig. + */ + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig getDialogflowEndpointConfig(); + + /** + * + * + *
                    +   * Dialogflow configuration.
                    +   * 
                    + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig dialogflow_endpoint_config = 4; + * + */ + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfigOrBuilder + getDialogflowEndpointConfigOrBuilder(); + + com.google.cloud.gsuiteaddons.v1.ConnectionConfig.ConfigCase getConfigCase(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/DialogflowEndpointConfig.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/DialogflowEndpointConfig.java new file mode 100644 index 000000000000..ebdf1abca97f --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/DialogflowEndpointConfig.java @@ -0,0 +1,1039 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * Dialogflow endpoint configuration.
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig} + */ +@com.google.protobuf.Generated +public final class DialogflowEndpointConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) + DialogflowEndpointConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DialogflowEndpointConfig"); + } + + // Use DialogflowEndpointConfig.newBuilder() to construct. + private DialogflowEndpointConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DialogflowEndpointConfig() { + dialogflowEdition_ = 0; + agent_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_DialogflowEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_DialogflowEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.Builder.class); + } + + /** + * + * + *
                    +   * Dialogflow edition type.
                    +   * 
                    + * + * Protobuf enum {@code google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition} + */ + public enum DialogflowEdition implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                    +     * Default value. Unspecified.
                    +     * 
                    + * + * DIALOGFLOW_EDITION_UNSPECIFIED = 0; + */ + DIALOGFLOW_EDITION_UNSPECIFIED(0), + /** + * + * + *
                    +     * Dialogflow ES edition. To use this edition, a Dialogflow ES agent must
                    +     * exist in the same Google Cloud project as the app. Google Chat sends all
                    +     * interactive events to that agent.
                    +     * 
                    + * + * ES = 1; + */ + ES(1), + /** + * + * + *
                    +     * Dialogflow CX edition. To use this edition, a Dialogflow CX agent must
                    +     * exist in the same Google Cloud project as the app and be specified in the
                    +     * `agent` field. Google Chat sends all interactive events to that agent.
                    +     * 
                    + * + * CX = 2; + */ + CX(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DialogflowEdition"); + } + + /** + * + * + *
                    +     * Default value. Unspecified.
                    +     * 
                    + * + * DIALOGFLOW_EDITION_UNSPECIFIED = 0; + */ + public static final int DIALOGFLOW_EDITION_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                    +     * Dialogflow ES edition. To use this edition, a Dialogflow ES agent must
                    +     * exist in the same Google Cloud project as the app. Google Chat sends all
                    +     * interactive events to that agent.
                    +     * 
                    + * + * ES = 1; + */ + public static final int ES_VALUE = 1; + + /** + * + * + *
                    +     * Dialogflow CX edition. To use this edition, a Dialogflow CX agent must
                    +     * exist in the same Google Cloud project as the app and be specified in the
                    +     * `agent` field. Google Chat sends all interactive events to that agent.
                    +     * 
                    + * + * CX = 2; + */ + public static final int CX_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static DialogflowEdition valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static DialogflowEdition forNumber(int value) { + switch (value) { + case 0: + return DIALOGFLOW_EDITION_UNSPECIFIED; + case 1: + return ES; + case 2: + return CX; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap + internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public DialogflowEdition findValueByNumber(int number) { + return DialogflowEdition.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final DialogflowEdition[] VALUES = values(); + + public static DialogflowEdition valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private DialogflowEdition(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition) + } + + private int bitField0_; + public static final int DIALOGFLOW_EDITION_FIELD_NUMBER = 1; + private int dialogflowEdition_ = 0; + + /** + * + * + *
                    +   * Required. The Dialogflow edition.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition dialogflow_edition = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for dialogflowEdition. + */ + @java.lang.Override + public int getDialogflowEditionValue() { + return dialogflowEdition_; + } + + /** + * + * + *
                    +   * Required. The Dialogflow edition.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition dialogflow_edition = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The dialogflowEdition. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition + getDialogflowEdition() { + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition result = + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition.forNumber( + dialogflowEdition_); + return result == null + ? com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition.UNRECOGNIZED + : result; + } + + public static final int AGENT_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object agent_ = ""; + + /** + * + * + *
                    +   * Optional. The Dialogflow CX agent or environment name.
                    +   * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +   *
                    +   * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +   * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +   * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the agent field is set. + */ + @java.lang.Override + public boolean hasAgent() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                    +   * Optional. The Dialogflow CX agent or environment name.
                    +   * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +   *
                    +   * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +   * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +   * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The agent. + */ + @java.lang.Override + public java.lang.String getAgent() { + java.lang.Object ref = agent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agent_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Optional. The Dialogflow CX agent or environment name.
                    +   * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +   *
                    +   * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +   * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +   * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for agent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAgentBytes() { + java.lang.Object ref = agent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (dialogflowEdition_ + != com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition + .DIALOGFLOW_EDITION_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, dialogflowEdition_); + } + if (((bitField0_ & 0x00000001) != 0)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, agent_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (dialogflowEdition_ + != com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition + .DIALOGFLOW_EDITION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, dialogflowEdition_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, agent_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig other = + (com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) obj; + + if (dialogflowEdition_ != other.dialogflowEdition_) return false; + if (hasAgent() != other.hasAgent()) return false; + if (hasAgent()) { + if (!getAgent().equals(other.getAgent())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + DIALOGFLOW_EDITION_FIELD_NUMBER; + hash = (53 * hash) + dialogflowEdition_; + if (hasAgent()) { + hash = (37 * hash) + AGENT_FIELD_NUMBER; + hash = (53 * hash) + getAgent().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Dialogflow endpoint configuration.
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_DialogflowEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_DialogflowEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + dialogflowEdition_ = 0; + agent_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_DialogflowEndpointConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig build() { + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig buildPartial() { + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig result = + new com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.dialogflowEdition_ = dialogflowEdition_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.agent_ = agent_; + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig other) { + if (other == com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.getDefaultInstance()) + return this; + if (other.dialogflowEdition_ != 0) { + setDialogflowEditionValue(other.getDialogflowEditionValue()); + } + if (other.hasAgent()) { + agent_ = other.agent_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + dialogflowEdition_ = input.readEnum(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 18: + { + agent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int dialogflowEdition_ = 0; + + /** + * + * + *
                    +     * Required. The Dialogflow edition.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition dialogflow_edition = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for dialogflowEdition. + */ + @java.lang.Override + public int getDialogflowEditionValue() { + return dialogflowEdition_; + } + + /** + * + * + *
                    +     * Required. The Dialogflow edition.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition dialogflow_edition = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The enum numeric value on the wire for dialogflowEdition to set. + * @return This builder for chaining. + */ + public Builder setDialogflowEditionValue(int value) { + dialogflowEdition_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The Dialogflow edition.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition dialogflow_edition = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The dialogflowEdition. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition + getDialogflowEdition() { + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition result = + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition.forNumber( + dialogflowEdition_); + return result == null + ? com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition.UNRECOGNIZED + : result; + } + + /** + * + * + *
                    +     * Required. The Dialogflow edition.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition dialogflow_edition = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The dialogflowEdition to set. + * @return This builder for chaining. + */ + public Builder setDialogflowEdition( + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + dialogflowEdition_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The Dialogflow edition.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition dialogflow_edition = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearDialogflowEdition() { + bitField0_ = (bitField0_ & ~0x00000001); + dialogflowEdition_ = 0; + onChanged(); + return this; + } + + private java.lang.Object agent_ = ""; + + /** + * + * + *
                    +     * Optional. The Dialogflow CX agent or environment name.
                    +     * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +     *
                    +     * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +     * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +     * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the agent field is set. + */ + public boolean hasAgent() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                    +     * Optional. The Dialogflow CX agent or environment name.
                    +     * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +     *
                    +     * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +     * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +     * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The agent. + */ + public java.lang.String getAgent() { + java.lang.Object ref = agent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + agent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Optional. The Dialogflow CX agent or environment name.
                    +     * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +     *
                    +     * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +     * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +     * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for agent. + */ + public com.google.protobuf.ByteString getAgentBytes() { + java.lang.Object ref = agent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + agent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Optional. The Dialogflow CX agent or environment name.
                    +     * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +     *
                    +     * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +     * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +     * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The agent to set. + * @return This builder for chaining. + */ + public Builder setAgent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + agent_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The Dialogflow CX agent or environment name.
                    +     * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +     *
                    +     * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +     * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +     * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearAgent() { + agent_ = getDefaultInstance().getAgent(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The Dialogflow CX agent or environment name.
                    +     * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +     *
                    +     * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +     * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +     * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for agent to set. + * @return This builder for chaining. + */ + public Builder setAgentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + agent_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) + private static final com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig(); + } + + public static com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DialogflowEndpointConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/DialogflowEndpointConfigOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/DialogflowEndpointConfigOrBuilder.java new file mode 100644 index 000000000000..8881f9c696b5 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/DialogflowEndpointConfigOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface DialogflowEndpointConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Required. The Dialogflow edition.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition dialogflow_edition = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The enum numeric value on the wire for dialogflowEdition. + */ + int getDialogflowEditionValue(); + + /** + * + * + *
                    +   * Required. The Dialogflow edition.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition dialogflow_edition = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The dialogflowEdition. + */ + com.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfig.DialogflowEdition + getDialogflowEdition(); + + /** + * + * + *
                    +   * Optional. The Dialogflow CX agent or environment name.
                    +   * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +   *
                    +   * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +   * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +   * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the agent field is set. + */ + boolean hasAgent(); + + /** + * + * + *
                    +   * Optional. The Dialogflow CX agent or environment name.
                    +   * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +   *
                    +   * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +   * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +   * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The agent. + */ + java.lang.String getAgent(); + + /** + * + * + *
                    +   * Optional. The Dialogflow CX agent or environment name.
                    +   * Required for Dialogflow CX. Do not set for Dialogflow ES.
                    +   *
                    +   * Format: `projects/{project}/locations/{location}/agents/{agent}` or
                    +   * `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`.
                    +   * 
                    + * + * optional string agent = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for agent. + */ + com.google.protobuf.ByteString getAgentBytes(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsProto.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsProto.java index 05c2cd38ad95..a8a4ca05c5c4 100644 --- a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsProto.java +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GSuiteAddOnsProto.java @@ -96,6 +96,58 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_gsuiteaddons_v1_AddOns_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_gsuiteaddons_v1_AddOns_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_GetChatAppConfigRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_GetChatAppConfigRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_UpdateChatAppConfigRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_UpdateChatAppConfigRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_ChatAppConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_ChatAppConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_InteractiveFeatureConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_InteractiveFeatureConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_ConnectionConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_ConnectionConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_HttpEndpointConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_HttpEndpointConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_HttpPerEventEndpointConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_HttpPerEventEndpointConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_AppsScriptEndpointConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_AppsScriptEndpointConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_AppsScriptPerEventEndpointConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_AppsScriptPerEventEndpointConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_CloudPubSubEndpointConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_CloudPubSubEndpointConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_DialogflowEndpointConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_DialogflowEndpointConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_AppCommand_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_AppCommand_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_gsuiteaddons_v1_UrlPattern_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_gsuiteaddons_v1_UrlPattern_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -105,127 +157,249 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { static { java.lang.String[] descriptorData = { - "\n/google/cloud/gsuiteaddons/v1/gsuiteadd" + "\n" + + "/google/cloud/gsuiteaddons/v1/gsuiteadd" + "ons.proto\022\034google.cloud.gsuiteaddons.v1\032" + "\034google/api/annotations.proto\032\027google/ap" + "i/client.proto\032\037google/api/field_behavio" + "r.proto\032\031google/api/resource.proto\032>goog" - + "le/apps/script/type/calendar/calendar_ad" - + "don_manifest.proto\0326google/apps/script/t" - + "ype/docs/docs_addon_manifest.proto\0328goog" - + "le/apps/script/type/drive/drive_addon_ma" - + "nifest.proto\0328google/apps/script/type/gm" - + "ail/gmail_addon_manifest.proto\032-google/a" - + "pps/script/type/script_manifest.proto\032:g" - + "oogle/apps/script/type/sheets/sheets_add" + + "le/apps/script/type/calendar/calendar_addon_manifest.proto\0326google/apps/script/t" + + "ype/docs/docs_addon_manifest.proto\0328google/apps/script/type/drive/drive_addon_ma" + + "nifest.proto\0328google/apps/script/type/gmail/gmail_addon_manifest.proto\032-google/a" + + "pps/script/type/script_manifest.proto\032:google/apps/script/type/sheets/sheets_add" + "on_manifest.proto\032:google/apps/script/ty" - + "pe/slides/slides_addon_manifest.proto\032\033g" - + "oogle/protobuf/empty.proto\032\036google/proto" - + "buf/wrappers.proto\"[\n\027GetAuthorizationRe" - + "quest\022@\n\004name\030\002 \001(\tB2\342A\001\002\372A+\n)gsuiteaddo" - + "ns.googleapis.com/Authorization\"\247\001\n\rAuth" - + "orization\022\014\n\004name\030\001 \001(\t\022\035\n\025service_accou" - + "nt_email\030\002 \001(\t\022\027\n\017oauth_client_id\030\003 \001(\t:" - + "P\352AM\n)gsuiteaddons.googleapis.com/Author" - + "ization\022 projects/{project}/authorizatio" - + "n\"\300\001\n\027CreateDeploymentRequest\022D\n\006parent\030" - + "\001 \001(\tB4\342A\001\002\372A-\n+cloudresourcemanager.goo" - + "gleapis.com/Project\022\033\n\rdeployment_id\030\002 \001" - + "(\tB\004\342A\001\002\022B\n\ndeployment\030\003 \001(\0132(.google.cl" - + "oud.gsuiteaddons.v1.DeploymentB\004\342A\001\002\"^\n\030" - + "ReplaceDeploymentRequest\022B\n\ndeployment\030\002" - + " \001(\0132(.google.cloud.gsuiteaddons.v1.Depl" - + "oymentB\004\342A\001\002\"U\n\024GetDeploymentRequest\022=\n\004" - + "name\030\001 \001(\tB/\342A\001\002\372A(\n&gsuiteaddons.google" - + "apis.com/Deployment\"\205\001\n\026ListDeploymentsR" - + "equest\022D\n\006parent\030\001 \001(\tB4\342A\001\002\372A-\n+cloudre" - + "sourcemanager.googleapis.com/Project\022\021\n\t" - + "page_size\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\"q\n\027L" - + "istDeploymentsResponse\022=\n\013deployments\030\001 " - + "\003(\0132(.google.cloud.gsuiteaddons.v1.Deplo" - + "yment\022\027\n\017next_page_token\030\002 \001(\t\"f\n\027Delete" - + "DeploymentRequest\022=\n\004name\030\001 \001(\tB/\342A\001\002\372A(" - + "\n&gsuiteaddons.googleapis.com/Deployment" - + "\022\014\n\004etag\030\002 \001(\t\"Y\n\030InstallDeploymentReque" - + "st\022=\n\004name\030\001 \001(\tB/\342A\001\002\372A(\n&gsuiteaddons." - + "googleapis.com/Deployment\"[\n\032UninstallDe" - + "ploymentRequest\022=\n\004name\030\001 \001(\tB/\342A\001\002\372A(\n&" - + "gsuiteaddons.googleapis.com/Deployment\"[" - + "\n\027GetInstallStatusRequest\022@\n\004name\030\001 \001(\tB" - + "2\342A\001\002\372A+\n)gsuiteaddons.googleapis.com/In" - + "stallStatus\"\267\001\n\rInstallStatus\022\014\n\004name\030\001 " - + "\001(\t\022-\n\tinstalled\030\002 \001(\0132\032.google.protobuf" - + ".BoolValue:i\352Af\n)gsuiteaddons.googleapis" - + ".com/InstallStatus\0229projects/{project}/d" - + "eployments/{deployment}/installStatus\"\317\001" - + "\n\nDeployment\022\014\n\004name\030\001 \001(\t\022\024\n\014oauth_scop" - + "es\030\002 \003(\t\0225\n\007add_ons\030\003 \001(\0132$.google.cloud" - + ".gsuiteaddons.v1.AddOns\022\014\n\004etag\030\005 \001(\t:X\352" - + "AU\n&gsuiteaddons.googleapis.com/Deployme" - + "nt\022+projects/{project}/deployments/{depl" - + "oyment}\"\232\004\n\006AddOns\022<\n\006common\030\001 \001(\0132,.goo" - + "gle.apps.script.type.CommonAddOnManifest" - + "\022@\n\005gmail\030\002 \001(\01321.google.apps.script.typ" - + "e.gmail.GmailAddOnManifest\022@\n\005drive\030\005 \001(" - + "\01321.google.apps.script.type.drive.DriveA" - + "ddOnManifest\022I\n\010calendar\030\006 \001(\01327.google." - + "apps.script.type.calendar.CalendarAddOnM" - + "anifest\022=\n\004docs\030\007 \001(\0132/.google.apps.scri" - + "pt.type.docs.DocsAddOnManifest\022C\n\006sheets" - + "\030\010 \001(\01323.google.apps.script.type.sheets." - + "SheetsAddOnManifest\022C\n\006slides\030\n \001(\01323.go" - + "ogle.apps.script.type.slides.SlidesAddOn" - + "Manifest\022:\n\014http_options\030\017 \001(\0132$.google." - + "apps.script.type.HttpOptions2\244\r\n\014GSuiteA" - + "ddOns\022\252\001\n\020GetAuthorization\0225.google.clou" - + "d.gsuiteaddons.v1.GetAuthorizationReques" - + "t\032+.google.cloud.gsuiteaddons.v1.Authori" - + "zation\"2\332A\004name\202\323\344\223\002%\022#/v1/{name=project" - + "s/*/authorization}\022\316\001\n\020CreateDeployment\022" - + "5.google.cloud.gsuiteaddons.v1.CreateDep" - + "loymentRequest\032(.google.cloud.gsuiteaddo" - + "ns.v1.Deployment\"Y\332A\037parent,deployment,d" - + "eployment_id\202\323\344\223\0021\"#/v1/{parent=projects" - + "/*}/deployments:\ndeployment\022\306\001\n\021ReplaceD" - + "eployment\0226.google.cloud.gsuiteaddons.v1" - + ".ReplaceDeploymentRequest\032(.google.cloud" - + ".gsuiteaddons.v1.Deployment\"O\332A\ndeployme" - + "nt\202\323\344\223\002<\032./v1/{deployment.name=projects/" - + "*/deployments/*}:\ndeployment\022\241\001\n\rGetDepl" - + "oyment\0222.google.cloud.gsuiteaddons.v1.Ge" - + "tDeploymentRequest\032(.google.cloud.gsuite" - + "addons.v1.Deployment\"2\332A\004name\202\323\344\223\002%\022#/v1" - + "/{name=projects/*/deployments/*}\022\264\001\n\017Lis" - + "tDeployments\0224.google.cloud.gsuiteaddons" - + ".v1.ListDeploymentsRequest\0325.google.clou" - + "d.gsuiteaddons.v1.ListDeploymentsRespons" - + "e\"4\332A\006parent\202\323\344\223\002%\022#/v1/{parent=projects" - + "/*}/deployments\022\225\001\n\020DeleteDeployment\0225.g" - + "oogle.cloud.gsuiteaddons.v1.DeleteDeploy" - + "mentRequest\032\026.google.protobuf.Empty\"2\332A\004" - + "name\202\323\344\223\002%*#/v1/{name=projects/*/deploym" - + "ents/*}\022\242\001\n\021InstallDeployment\0226.google.c" - + "loud.gsuiteaddons.v1.InstallDeploymentRe" - + "quest\032\026.google.protobuf.Empty\"=\332A\004name\202\323" - + "\344\223\0020\"+/v1/{name=projects/*/deployments/*" - + "}:install:\001*\022\250\001\n\023UninstallDeployment\0228.g" - + "oogle.cloud.gsuiteaddons.v1.UninstallDep" - + "loymentRequest\032\026.google.protobuf.Empty\"?" - + "\332A\004name\202\323\344\223\0022\"-/v1/{name=projects/*/depl" - + "oyments/*}:uninstall:\001*\022\270\001\n\020GetInstallSt" - + "atus\0225.google.cloud.gsuiteaddons.v1.GetI" - + "nstallStatusRequest\032+.google.cloud.gsuit" - + "eaddons.v1.InstallStatus\"@\332A\004name\202\323\344\223\0023\022" - + "1/v1/{name=projects/*/deployments/*/inst" - + "allStatus}\032O\312A\033gsuiteaddons.googleapis.c" - + "om\322A.https://www.googleapis.com/auth/clo" - + "ud-platformB\335\001\n com.google.cloud.gsuitea" - + "ddons.v1B\021GSuiteAddOnsProtoP\001ZDcloud.goo" - + "gle.com/go/gsuiteaddons/apiv1/gsuiteaddo" - + "nspb;gsuiteaddonspb\252\002\034Google.Cloud.GSuit" - + "eAddOns.V1\312\002\034Google\\Cloud\\GSuiteAddOns\\V" - + "1\352\002\037Google::Cloud::GSuiteAddOns::V1b\006pro" - + "to3" + + "pe/slides/slides_addon_manifest.proto\032\033google/protobuf/empty.proto\032" + + " google/protobuf/field_mask.proto\032\036google/protobuf/wrappers.proto\"[\n" + + "\027GetAuthorizationRequest\022@\n" + + "\004name\030\002 \001(\tB2\342A\001\002\372A+\n" + + ")gsuiteaddons.googleapis.com/Authorization\"\247\001\n\r" + + "Authorization\022\014\n" + + "\004name\030\001 \001(\t\022\035\n" + + "\025service_account_email\030\002 \001(\t\022\027\n" + + "\017oauth_client_id\030\003 \001(\t:P\352AM\n" + + ")gsuiteaddons.googleapis.com/Authorization\022" + + " projects/{project}/authorization\"\300\001\n" + + "\027CreateDeploymentRequest\022D\n" + + "\006parent\030\001 \001(\tB4\342A\001\002\372A-\n" + + "+cloudresourcemanager.googleapis.com/Project\022\033\n\r" + + "deployment_id\030\002 \001(\tB\004\342A\001\002\022B\n\n" + + "deployment\030\003" + + " \001(\0132(.google.cloud.gsuiteaddons.v1.DeploymentB\004\342A\001\002\"^\n" + + "\030ReplaceDeploymentRequest\022B\n\n" + + "deployment\030\002 \001(\0132(" + + ".google.cloud.gsuiteaddons.v1.DeploymentB\004\342A\001\002\"U\n" + + "\024GetDeploymentRequest\022=\n" + + "\004name\030\001 \001(\tB/\342A\001\002\372A(\n" + + "&gsuiteaddons.googleapis.com/Deployment\"\205\001\n" + + "\026ListDeploymentsRequest\022D\n" + + "\006parent\030\001 \001(\tB4\342A\001\002\372A-\n" + + "+cloudresourcemanager.googleapis.com/Project\022\021\n" + + "\tpage_size\030\002 \001(\005\022\022\n\n" + + "page_token\030\003 \001(\t\"q\n" + + "\027ListDeploymentsResponse\022=\n" + + "\013deployments\030\001 \003(\0132(.google.cloud.gsuiteaddons.v1.Deployment\022\027\n" + + "\017next_page_token\030\002 \001(\t\"f\n" + + "\027DeleteDeploymentRequest\022=\n" + + "\004name\030\001 \001(\tB/\342A\001\002\372A(\n" + + "&gsuiteaddons.googleapis.com/Deployment\022\014\n" + + "\004etag\030\002 \001(\t\"Y\n" + + "\030InstallDeploymentRequest\022=\n" + + "\004name\030\001 \001(\tB/\342A\001\002\372A(\n" + + "&gsuiteaddons.googleapis.com/Deployment\"[\n" + + "\032UninstallDeploymentRequest\022=\n" + + "\004name\030\001 \001(\tB/\342A\001\002\372A(\n" + + "&gsuiteaddons.googleapis.com/Deployment\"[\n" + + "\027GetInstallStatusRequest\022@\n" + + "\004name\030\001 \001(\tB2\342A\001\002\372A+\n" + + ")gsuiteaddons.googleapis.com/InstallStatus\"\267\001\n\r" + + "InstallStatus\022\014\n" + + "\004name\030\001 \001(\t\022-\n" + + "\tinstalled\030\002 \001(\0132\032.google.protobuf.BoolValue:i\352Af\n" + + ")gsuiteaddons.googleapis.com/I" + + "nstallStatus\0229projects/{project}/deployments/{deployment}/installStatus\"\317\001\n\n" + + "Deployment\022\014\n" + + "\004name\030\001 \001(\t\022\024\n" + + "\014oauth_scopes\030\002 \003(\t\0225\n" + + "\007add_ons\030\003 \001(\0132$.google.cloud.gsuiteaddons.v1.AddOns\022\014\n" + + "\004etag\030\005 \001(\t:X\352AU\n" + + "&gsuiteaddons.googleapis.com/Deployment\022+pr" + + "ojects/{project}/deployments/{deployment}\"\232\004\n" + + "\006AddOns\022<\n" + + "\006common\030\001 \001(\0132,.google.apps.script.type.CommonAddOnManifest\022@\n" + + "\005gmail\030\002 \001(\01321.google.apps.script.type.gmail.GmailAddOnManifest\022@\n" + + "\005drive\030\005 \001(\01321.google.apps.script.type.drive.DriveAddOnManifest\022I\n" + + "\010calendar\030\006 \001(\01327.google.apps.s" + + "cript.type.calendar.CalendarAddOnManifest\022=\n" + + "\004docs\030\007 \001(\0132/.google.apps.script.type.docs.DocsAddOnManifest\022C\n" + + "\006sheets\030\010 \001(\013" + + "23.google.apps.script.type.sheets.SheetsAddOnManifest\022C\n" + + "\006slides\030\n" + + " \001(\01323.google.apps.script.type.slides.SlidesAddOnManifest\022:\n" + + "\014http_options\030\017 \001(\0132$.google.apps.script.type.HttpOptions\"\210\002\n" + + "\027GetChatAppConfigRequest\022@\n" + + "\004name\030\001 \001(\tB2\342A\001\002\372A+\n" + + ")gsuiteaddons.googleapis.com/ChatAppConfig\022[\n" + + "\004view\030\002 \001(\0162G.google.cloud.gsuiteaddons.v" + + "1.GetChatAppConfigRequest.ChatAppConfigViewB\004\342A\001\001\"N\n" + + "\021ChatAppConfigView\022$\n" + + " CHAT_APP_CONFIG_VIEW_UNSPECIFIED\020\000\022\t\n" + + "\005BASIC\020\001\022\010\n" + + "\004FULL\020\002\"\237\001\n" + + "\032UpdateChatAppConfigRequest\022J\n" + + "\017chat_app_config\030\001" + + " \001(\0132+.google.cloud.gsuiteaddons.v1.ChatAppConfigB\004\342A\001\002\0225\n" + + "\013update_mask\030\002" + + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\"\214\006\n\r" + + "ChatAppConfig\022\023\n" + + "\004name\030\001 \001(\tB\005\342A\002\002\010\022\032\n" + + "\014display_name\030\002 \001(\tB\004\342A\001\002\022\035\n\n" + + "avatar_uri\030\003 \001(\tB\004\342A\001\001H\000\210\001\001\022\031\n" + + "\013description\030\004 \001(\tB\004\342A\001\002\022N\n" + + "\005state\030\005 \001(\01624.google" + + ".cloud.gsuiteaddons.v1.ChatAppConfig.AppStateB\004\342A\001\001H\001\210\001\001\022`\n" + + "\032interactive_feature_config\030\006" + + " \001(\01326.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfigB\004\342A\001\001\022(\n" + + "\025error_logging_enabled\030\007" + + " \001(\010B\004\342A\001\001H\002\210\001\001\022Z\n\r" + + "markup_syntax\030\010 \001(\01628.google.cloud.gsuit" + + "eaddons.v1.ChatAppConfig.MarkupSyntaxB\004\342A\001\001H\003\210\001\001\"?\n" + + "\010AppState\022\031\n" + + "\025APP_STATE_UNSPECIFIED\020\000\022\n\n" + + "\006ACTIVE\020\001\022\014\n" + + "\010DISABLED\020\002\"a\n" + + "\014MarkupSyntax\022\035\n" + + "\031MARKUP_SYNTAX_UNSPECIFIED\020\000\022\026\n" + + "\022MARKUP_SYNTAX_CHAT\020\001\022\032\n" + + "\026MARKUP_SYNTAX_MARKDOWN\020\002:o\352Al\n" + + ")gsuiteaddons.googleapis.com/ChatAppConfig\022" + + " projects/{project}/chatAppConfig*\016chatAppConfigs2\r" + + "chatAppConfigB\r\n" + + "\013_avatar_uriB\010\n" + + "\006_stateB\030\n" + + "\026_error_logging_enabledB\020\n" + + "\016_markup_syntax\"\361\002\n" + + "\030InteractiveFeatureConfig\022,\n" + + "\031supports_multiuser_spaces\030\001" + + " \001(\010B\004\342A\001\001H\000\210\001\001\022O\n" + + "\021connection_config\030\002" + + " \001(\0132..google.cloud.gsuiteaddons.v1.ConnectionConfigB\004\342A\001\002\022D\n" + + "\014app_commands\030\003" + + " \003(\0132(.google.cloud.gsuiteaddons.v1.AppCommandB\004\342A\001\001\022D\n" + + "\014url_patterns\030\004 \003" + + "(\0132(.google.cloud.gsuiteaddons.v1.UrlPatternB\004\342A\001\001\022,\n" + + "\036allowlisted_testing_principals\030\005 \003(\tB\004\342A\001\001B\034\n" + + "\032_supports_multiuser_spaces\"\215\003\n" + + "\020ConnectionConfig\022P\n" + + "\024http_endpoint_config\030\001" + + " \001(\01320.google.cloud.gsuiteaddons.v1.HttpEndpointConfigH\000\022]\n" + + "\033apps_script_endpoint_config\030\002 \001(\01326.google.clou" + + "d.gsuiteaddons.v1.AppsScriptEndpointConfigH\000\022`\n" + + "\035cloud_pub_sub_endpoint_config\030\003 " + + "\001(\01327.google.cloud.gsuiteaddons.v1.CloudPubSubEndpointConfigH\000\022\\\n" + + "\032dialogflow_endpoint_config\030\004" + + " \001(\01326.google.cloud.gsuiteaddons.v1.DialogflowEndpointConfigH\000B\010\n" + + "\006config\"\237\001\n" + + "\022HttpEndpointConfig\022\032\n\n" + + "common_url\030\001 \001(\tB\004\342A\001\001H\000\022c\n" + + "\031per_event_endpoint_config\030\002 \001(\01328.google.cloud.gsuiteaddons" + + ".v1.HttpPerEventEndpointConfigB\004\342A\001\001H\000B\010\n" + + "\006config\"\262\001\n" + + "\032HttpPerEventEndpointConfig\022\"\n" + + "\024app_command_endpoint\030\001 \001(\tB\004\342A\001\002\022%\n" + + "\027added_to_space_endpoint\030\002 \001(\tB\004\342A\001\002\022\036\n" + + "\020message_endpoint\030\003 \001(\tB\004\342A\001\002\022)\n" + + "\033removed_from_space_endpoint\030\004 \001(\tB\004\342A\001\002\"\240\001\n" + + "\030AppsScriptEndpointConfig\022\033\n\r" + + "deployment_id\030\001 \001(\tB\004\342A\001\002\022g\n" + + "\031per_event_endpoint_config\030\002 \001" + + "(\0132>.google.cloud.gsuiteaddons.v1.AppsScriptPerEventEndpointConfigB\004\342A\001\001\"\266\002\n" + + " AppsScriptPerEventEndpointConfig\022\'\n" + + "\024app_command_endpoint\030\001 \001(\tB\004\342A\001\001H\000\210\001\001\022*\n" + + "\027added_to_space_endpoint\030\002 \001(\tB\004\342A\001\001H\001\210\001\001\022#\n" + + "\020message_endpoint\030\003 \001(\tB\004\342A\001\001H\002\210\001\001\022.\n" + + "\033removed_from_space_endpoint\030\004 \001(" + + "\tB\004\342A\001\001H\003\210\001\001B\027\n" + + "\025_app_command_endpointB\032\n" + + "\030_added_to_space_endpointB\023\n" + + "\021_message_endpointB\036\n" + + "\034_removed_from_space_endpoint\"P\n" + + "\031CloudPubSubEndpointConfig\0223\n" + + "\005topic\030\001 \001(\tB$\342A\001\002\372A\035\n" + + "\033pubsub.googleapis.com/Topic\"\363\001\n" + + "\030DialogflowEndpointConfig\022j\n" + + "\022dialogflow_edition\030\001 \001(\0162H.google.cloud.gsuiteaddons.v1.Dial" + + "ogflowEndpointConfig.DialogflowEditionB\004\342A\001\002\022\030\n" + + "\005agent\030\002 \001(\tB\004\342A\001\001H\000\210\001\001\"G\n" + + "\021DialogflowEdition\022\"\n" + + "\036DIALOGFLOW_EDITION_UNSPECIFIED\020\000\022\006\n" + + "\002ES\020\001\022\006\n" + + "\002CX\020\002B\010\n" + + "\006_agent\"\367\002\n\n" + + "AppCommand\022P\n" + + "\014command_type\030\001 \001(\01624.google." + + "cloud.gsuiteaddons.v1.AppCommand.CommandTypeB\004\342A\001\002\022\030\n\n" + + "command_id\030\002 \001(\005B\004\342A\001\002\022\025\n" + + "\007command\030\003 \001(\tB\004\342A\001\001\022\032\n" + + "\014display_name\030\004 \001(\tB\004\342A\001\001\022\031\n" + + "\013description\030\005 \001(\tB\004\342A\001\002\022\034\n" + + "\016dialog_enabled\030\006 \001(\010B\004\342A\001\001\022*\n" + + "\034loading_notification_message\030\007 \001(\tB\004\342A\001\001\"e\n" + + "\013CommandType\022\034\n" + + "\030COMMAND_TYPE_UNSPECIFIED\020\000\022\021\n\r" + + "SLASH_COMMAND\020\001\022\021\n\r" + + "QUICK_COMMAND\020\002\022\022\n" + + "\016MESSAGE_ACTION\020\003\"C\n\n" + + "UrlPattern\022\032\n" + + "\014host_pattern\030\001 \001(\tB\004\342A\001\002\022\031\n" + + "\013path_prefix\030\002 \001(\tB\004\342A\001\0012\366\020\n" + + "\014GSuiteAddOns\022\252\001\n" + + "\020GetAuthorization\0225.google.cloud.gsuiteaddons.v1.GetAuthori" + + "zationRequest\032+.google.cloud.gsuiteaddon" + + "s.v1.Authorization\"2\332A\004name\202\323\344\223\002%\022#/v1/{name=projects/*/authorization}\022\316\001\n" + + "\020CreateDeployment\0225.google.cloud.gsuiteaddons." + + "v1.CreateDeploymentRequest\032(.google.clou" + + "d.gsuiteaddons.v1.Deployment\"Y\332A\037parent," + + "deployment,deployment_id\202\323\344\223\0021\"#/v1/{parent=projects/*}/deployments:\n" + + "deployment\022\306\001\n" + + "\021ReplaceDeployment\0226.google.cloud.gsuiteaddons.v1.ReplaceDeploymentRequest\032(." + + "google.cloud.gsuiteaddons.v1.Deployment\"O\332A\n" + + "deployment\202\323\344\223\002<\032./v1/{deployment.name=projects/*/deployments/*}:\n" + + "deployment\022\241\001\n\r" + + "GetDeployment\0222.google.cloud.gsuiteaddons.v1.GetDeploymentRequest\032(.google." + + "cloud.gsuiteaddons.v1.Deployment\"2\332A\004nam" + + "e\202\323\344\223\002%\022#/v1/{name=projects/*/deployments/*}\022\264\001\n" + + "\017ListDeployments\0224.google.cloud.gsuiteaddons.v1.ListDeploymentsRequest\0325" + + ".google.cloud.gsuiteaddons.v1.ListDeploy" + + "mentsResponse\"4\332A\006parent\202\323\344\223\002%\022#/v1/{parent=projects/*}/deployments\022\225\001\n" + + "\020DeleteDeployment\0225.google.cloud.gsuiteaddons.v1." + + "DeleteDeploymentRequest\032\026.google.protobu" + + "f.Empty\"2\332A\004name\202\323\344\223\002%*#/v1/{name=projects/*/deployments/*}\022\242\001\n" + + "\021InstallDeployment\0226.google.cloud.gsuiteaddons.v1.Install" + + "DeploymentRequest\032\026.google.protobuf.Empt" + + "y\"=\332A\004name\202\323\344\223\0020\"+/v1/{name=projects/*/deployments/*}:install:\001*\022\250\001\n" + + "\023UninstallDeployment\0228.google.cloud.gsuiteaddons.v1." + + "UninstallDeploymentRequest\032\026.google.prot" + + "obuf.Empty\"?\332A\004name\202\323\344\223\0022\"-/v1/{name=projects/*/deployments/*}:uninstall:\001*\022\270\001\n" + + "\020GetInstallStatus\0225.google.cloud.gsuitead" + + "dons.v1.GetInstallStatusRequest\032+.google" + + ".cloud.gsuiteaddons.v1.InstallStatus\"@\332A" + + "\004name\202\323\344\223\0023\0221/v1/{name=projects/*/deployments/*/installStatus}\022\252\001\n" + + "\020GetChatAppConfig\0225.google.cloud.gsuiteaddons.v1.GetCh" + + "atAppConfigRequest\032+.google.cloud.gsuite" + + "addons.v1.ChatAppConfig\"2\332A\004name\202\323\344\223\002%\022#/v1/{name=projects/*/chatAppConfig}\022\350\001\n" + + "\023UpdateChatAppConfig\0228.google.cloud.gsuit" + + "eaddons.v1.UpdateChatAppConfigRequest\032+.google.cloud.gsuiteaddons.v1.ChatAppConf" + + "ig\"j\332A\033chat_app_config,update_mask\202\323\344\223\002F" + + "23/v1/{chat_app_config.name=projects/*/c" + + "hatAppConfig}:\017chat_app_config\032\210\001\312A\033gsui" + + "teaddons.googleapis.com\322Aghttps://www.googleapis.com/auth/cloud-platform,https:/" + + "/www.googleapis.com/auth/cloud-platform.read-onlyB\257\002\n" + + " com.google.cloud.gsuiteaddons.v1B\021GSuiteAddOnsProtoP\001ZDcloud.googl" + + "e.com/go/gsuiteaddons/apiv1/gsuiteaddons" + + "pb;gsuiteaddonspb\252\002\034Google.Cloud.GSuiteA" + + "ddOns.V1\312\002\034Google\\Cloud\\GSuiteAddOns\\V1\352\002\037Google::Cloud::GSuiteAddOns::V1\352AO\n" + + "\033pubsub.googleapis.com/Topic\022!projects/{pro" + + "ject}/topics/{topic}*\006topics2\005topicb\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -243,6 +417,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.apps.script.type.sheets.SheetsAddOnManifestProto.getDescriptor(), com.google.apps.script.type.slides.SlidesAddOnManifestProto.getDescriptor(), com.google.protobuf.EmptyProto.getDescriptor(), + com.google.protobuf.FieldMaskProto.getDescriptor(), com.google.protobuf.WrappersProto.getDescriptor(), }); internal_static_google_cloud_gsuiteaddons_v1_GetAuthorizationRequest_descriptor = @@ -357,6 +532,137 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Common", "Gmail", "Drive", "Calendar", "Docs", "Sheets", "Slides", "HttpOptions", }); + internal_static_google_cloud_gsuiteaddons_v1_GetChatAppConfigRequest_descriptor = + getDescriptor().getMessageType(14); + internal_static_google_cloud_gsuiteaddons_v1_GetChatAppConfigRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_GetChatAppConfigRequest_descriptor, + new java.lang.String[] { + "Name", "View", + }); + internal_static_google_cloud_gsuiteaddons_v1_UpdateChatAppConfigRequest_descriptor = + getDescriptor().getMessageType(15); + internal_static_google_cloud_gsuiteaddons_v1_UpdateChatAppConfigRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_UpdateChatAppConfigRequest_descriptor, + new java.lang.String[] { + "ChatAppConfig", "UpdateMask", + }); + internal_static_google_cloud_gsuiteaddons_v1_ChatAppConfig_descriptor = + getDescriptor().getMessageType(16); + internal_static_google_cloud_gsuiteaddons_v1_ChatAppConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_ChatAppConfig_descriptor, + new java.lang.String[] { + "Name", + "DisplayName", + "AvatarUri", + "Description", + "State", + "InteractiveFeatureConfig", + "ErrorLoggingEnabled", + "MarkupSyntax", + }); + internal_static_google_cloud_gsuiteaddons_v1_InteractiveFeatureConfig_descriptor = + getDescriptor().getMessageType(17); + internal_static_google_cloud_gsuiteaddons_v1_InteractiveFeatureConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_InteractiveFeatureConfig_descriptor, + new java.lang.String[] { + "SupportsMultiuserSpaces", + "ConnectionConfig", + "AppCommands", + "UrlPatterns", + "AllowlistedTestingPrincipals", + }); + internal_static_google_cloud_gsuiteaddons_v1_ConnectionConfig_descriptor = + getDescriptor().getMessageType(18); + internal_static_google_cloud_gsuiteaddons_v1_ConnectionConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_ConnectionConfig_descriptor, + new java.lang.String[] { + "HttpEndpointConfig", + "AppsScriptEndpointConfig", + "CloudPubSubEndpointConfig", + "DialogflowEndpointConfig", + "Config", + }); + internal_static_google_cloud_gsuiteaddons_v1_HttpEndpointConfig_descriptor = + getDescriptor().getMessageType(19); + internal_static_google_cloud_gsuiteaddons_v1_HttpEndpointConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_HttpEndpointConfig_descriptor, + new java.lang.String[] { + "CommonUrl", "PerEventEndpointConfig", "Config", + }); + internal_static_google_cloud_gsuiteaddons_v1_HttpPerEventEndpointConfig_descriptor = + getDescriptor().getMessageType(20); + internal_static_google_cloud_gsuiteaddons_v1_HttpPerEventEndpointConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_HttpPerEventEndpointConfig_descriptor, + new java.lang.String[] { + "AppCommandEndpoint", + "AddedToSpaceEndpoint", + "MessageEndpoint", + "RemovedFromSpaceEndpoint", + }); + internal_static_google_cloud_gsuiteaddons_v1_AppsScriptEndpointConfig_descriptor = + getDescriptor().getMessageType(21); + internal_static_google_cloud_gsuiteaddons_v1_AppsScriptEndpointConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_AppsScriptEndpointConfig_descriptor, + new java.lang.String[] { + "DeploymentId", "PerEventEndpointConfig", + }); + internal_static_google_cloud_gsuiteaddons_v1_AppsScriptPerEventEndpointConfig_descriptor = + getDescriptor().getMessageType(22); + internal_static_google_cloud_gsuiteaddons_v1_AppsScriptPerEventEndpointConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_AppsScriptPerEventEndpointConfig_descriptor, + new java.lang.String[] { + "AppCommandEndpoint", + "AddedToSpaceEndpoint", + "MessageEndpoint", + "RemovedFromSpaceEndpoint", + }); + internal_static_google_cloud_gsuiteaddons_v1_CloudPubSubEndpointConfig_descriptor = + getDescriptor().getMessageType(23); + internal_static_google_cloud_gsuiteaddons_v1_CloudPubSubEndpointConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_CloudPubSubEndpointConfig_descriptor, + new java.lang.String[] { + "Topic", + }); + internal_static_google_cloud_gsuiteaddons_v1_DialogflowEndpointConfig_descriptor = + getDescriptor().getMessageType(24); + internal_static_google_cloud_gsuiteaddons_v1_DialogflowEndpointConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_DialogflowEndpointConfig_descriptor, + new java.lang.String[] { + "DialogflowEdition", "Agent", + }); + internal_static_google_cloud_gsuiteaddons_v1_AppCommand_descriptor = + getDescriptor().getMessageType(25); + internal_static_google_cloud_gsuiteaddons_v1_AppCommand_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_AppCommand_descriptor, + new java.lang.String[] { + "CommandType", + "CommandId", + "Command", + "DisplayName", + "Description", + "DialogEnabled", + "LoadingNotificationMessage", + }); + internal_static_google_cloud_gsuiteaddons_v1_UrlPattern_descriptor = + getDescriptor().getMessageType(26); + internal_static_google_cloud_gsuiteaddons_v1_UrlPattern_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_gsuiteaddons_v1_UrlPattern_descriptor, + new java.lang.String[] { + "HostPattern", "PathPrefix", + }); descriptor.resolveAllFeaturesImmutable(); com.google.api.AnnotationsProto.getDescriptor(); com.google.api.ClientProto.getDescriptor(); @@ -370,6 +676,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.apps.script.type.sheets.SheetsAddOnManifestProto.getDescriptor(); com.google.apps.script.type.slides.SlidesAddOnManifestProto.getDescriptor(); com.google.protobuf.EmptyProto.getDescriptor(); + com.google.protobuf.FieldMaskProto.getDescriptor(); com.google.protobuf.WrappersProto.getDescriptor(); com.google.protobuf.ExtensionRegistry registry = com.google.protobuf.ExtensionRegistry.newInstance(); @@ -379,6 +686,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { registry.add(com.google.api.ClientProto.methodSignature); registry.add(com.google.api.ClientProto.oauthScopes); registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceDefinition); registry.add(com.google.api.ResourceProto.resourceReference); com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( descriptor, registry); diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GetChatAppConfigRequest.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GetChatAppConfigRequest.java new file mode 100644 index 000000000000..cc2aca0bb9de --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GetChatAppConfigRequest.java @@ -0,0 +1,1001 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * Request message to get the Chat app configuration.
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest} + */ +@com.google.protobuf.Generated +public final class GetChatAppConfigRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest) + GetChatAppConfigRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetChatAppConfigRequest"); + } + + // Use GetChatAppConfigRequest.newBuilder() to construct. + private GetChatAppConfigRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetChatAppConfigRequest() { + name_ = ""; + view_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_GetChatAppConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_GetChatAppConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.class, + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.Builder.class); + } + + /** + * + * + *
                    +   * A view that specifies which fields should be populated in the ChatAppConfig
                    +   * resource.
                    +   * 
                    + * + * Protobuf enum {@code google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView} + */ + public enum ChatAppConfigView implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
                    +     * The default or unset value. Defaults to `BASIC`.
                    +     * 
                    + * + * CHAT_APP_CONFIG_VIEW_UNSPECIFIED = 0; + */ + CHAT_APP_CONFIG_VIEW_UNSPECIFIED(0), + /** + * + * + *
                    +     * Populates only the basic metadata about the app configuration, without
                    +     * the interactive feature configuration.
                    +     * This is the default value.
                    +     * 
                    + * + * BASIC = 1; + */ + BASIC(1), + /** + * + * + *
                    +     * Populates all the fields including the interactive feature
                    +     * configurations.
                    +     * 
                    + * + * FULL = 2; + */ + FULL(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ChatAppConfigView"); + } + + /** + * + * + *
                    +     * The default or unset value. Defaults to `BASIC`.
                    +     * 
                    + * + * CHAT_APP_CONFIG_VIEW_UNSPECIFIED = 0; + */ + public static final int CHAT_APP_CONFIG_VIEW_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
                    +     * Populates only the basic metadata about the app configuration, without
                    +     * the interactive feature configuration.
                    +     * This is the default value.
                    +     * 
                    + * + * BASIC = 1; + */ + public static final int BASIC_VALUE = 1; + + /** + * + * + *
                    +     * Populates all the fields including the interactive feature
                    +     * configurations.
                    +     * 
                    + * + * FULL = 2; + */ + public static final int FULL_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ChatAppConfigView valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static ChatAppConfigView forNumber(int value) { + switch (value) { + case 0: + return CHAT_APP_CONFIG_VIEW_UNSPECIFIED; + case 1: + return BASIC; + case 2: + return FULL; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap + internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public ChatAppConfigView findValueByNumber(int number) { + return ChatAppConfigView.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final ChatAppConfigView[] VALUES = values(); + + public static ChatAppConfigView valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private ChatAppConfigView(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView) + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
                    +   * Required. Resource name of the Chat app configuration.
                    +   *
                    +   * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +   * Cloud project number.
                    +   * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. Resource name of the Chat app configuration.
                    +   *
                    +   * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +   * Cloud project number.
                    +   * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VIEW_FIELD_NUMBER = 2; + private int view_ = 0; + + /** + * + * + *
                    +   * Optional. The view of the ChatAppConfig to return. If unspecified, defaults
                    +   * to `BASIC`.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for view. + */ + @java.lang.Override + public int getViewValue() { + return view_; + } + + /** + * + * + *
                    +   * Optional. The view of the ChatAppConfig to return. If unspecified, defaults
                    +   * to `BASIC`.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The view. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView getView() { + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView result = + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView.forNumber(view_); + return result == null + ? com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (view_ + != com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView + .CHAT_APP_CONFIG_VIEW_UNSPECIFIED + .getNumber()) { + output.writeEnum(2, view_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (view_ + != com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView + .CHAT_APP_CONFIG_VIEW_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, view_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest other = + (com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (view_ != other.view_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + VIEW_FIELD_NUMBER; + hash = (53 * hash) + view_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Request message to get the Chat app configuration.
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest) + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_GetChatAppConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_GetChatAppConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.class, + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + view_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_GetChatAppConfigRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest build() { + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest buildPartial() { + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest result = + new com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.view_ = view_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest other) { + if (other == com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.view_ != 0) { + setViewValue(other.getViewValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + view_ = input.readEnum(); + bitField0_ |= 0x00000002; + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
                    +     * Required. Resource name of the Chat app configuration.
                    +     *
                    +     * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +     * Cloud project number.
                    +     * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. Resource name of the Chat app configuration.
                    +     *
                    +     * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +     * Cloud project number.
                    +     * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. Resource name of the Chat app configuration.
                    +     *
                    +     * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +     * Cloud project number.
                    +     * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. Resource name of the Chat app configuration.
                    +     *
                    +     * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +     * Cloud project number.
                    +     * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. Resource name of the Chat app configuration.
                    +     *
                    +     * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +     * Cloud project number.
                    +     * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int view_ = 0; + + /** + * + * + *
                    +     * Optional. The view of the ChatAppConfig to return. If unspecified, defaults
                    +     * to `BASIC`.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for view. + */ + @java.lang.Override + public int getViewValue() { + return view_; + } + + /** + * + * + *
                    +     * Optional. The view of the ChatAppConfig to return. If unspecified, defaults
                    +     * to `BASIC`.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for view to set. + * @return This builder for chaining. + */ + public Builder setViewValue(int value) { + view_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The view of the ChatAppConfig to return. If unspecified, defaults
                    +     * to `BASIC`.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The view. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView getView() { + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView result = + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView.forNumber( + view_); + return result == null + ? com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView.UNRECOGNIZED + : result; + } + + /** + * + * + *
                    +     * Optional. The view of the ChatAppConfig to return. If unspecified, defaults
                    +     * to `BASIC`.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The view to set. + * @return This builder for chaining. + */ + public Builder setView( + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000002; + view_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The view of the ChatAppConfig to return. If unspecified, defaults
                    +     * to `BASIC`.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearView() { + bitField0_ = (bitField0_ & ~0x00000002); + view_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest) + private static final com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest(); + } + + public static com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetChatAppConfigRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GetChatAppConfigRequestOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GetChatAppConfigRequestOrBuilder.java new file mode 100644 index 000000000000..a6ef29299012 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/GetChatAppConfigRequestOrBuilder.java @@ -0,0 +1,96 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface GetChatAppConfigRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Required. Resource name of the Chat app configuration.
                    +   *
                    +   * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +   * Cloud project number.
                    +   * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
                    +   * Required. Resource name of the Chat app configuration.
                    +   *
                    +   * Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google
                    +   * Cloud project number.
                    +   * 
                    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
                    +   * Optional. The view of the ChatAppConfig to return. If unspecified, defaults
                    +   * to `BASIC`.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for view. + */ + int getViewValue(); + + /** + * + * + *
                    +   * Optional. The view of the ChatAppConfig to return. If unspecified, defaults
                    +   * to `BASIC`.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView view = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The view. + */ + com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest.ChatAppConfigView getView(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpEndpointConfig.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpEndpointConfig.java new file mode 100644 index 000000000000..a89f252cd4d8 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpEndpointConfig.java @@ -0,0 +1,1091 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * HTTP endpoint configuration.
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.HttpEndpointConfig} + */ +@com.google.protobuf.Generated +public final class HttpEndpointConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.HttpEndpointConfig) + HttpEndpointConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "HttpEndpointConfig"); + } + + // Use HttpEndpointConfig.newBuilder() to construct. + private HttpEndpointConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private HttpEndpointConfig() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_HttpEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_HttpEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.Builder.class); + } + + private int configCase_ = 0; + + @SuppressWarnings("serial") + private java.lang.Object config_; + + public enum ConfigCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + COMMON_URL(1), + PER_EVENT_ENDPOINT_CONFIG(2), + CONFIG_NOT_SET(0); + private final int value; + + private ConfigCase(int value) { + this.value = value; + } + + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ConfigCase valueOf(int value) { + return forNumber(value); + } + + public static ConfigCase forNumber(int value) { + switch (value) { + case 1: + return COMMON_URL; + case 2: + return PER_EVENT_ENDPOINT_CONFIG; + case 0: + return CONFIG_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ConfigCase getConfigCase() { + return ConfigCase.forNumber(configCase_); + } + + public static final int COMMON_URL_FIELD_NUMBER = 1; + + /** + * + * + *
                    +   * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +   * events.
                    +   * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the commonUrl field is set. + */ + public boolean hasCommonUrl() { + return configCase_ == 1; + } + + /** + * + * + *
                    +   * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +   * events.
                    +   * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The commonUrl. + */ + public java.lang.String getCommonUrl() { + java.lang.Object ref = ""; + if (configCase_ == 1) { + ref = config_; + } + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (configCase_ == 1) { + config_ = s; + } + return s; + } + } + + /** + * + * + *
                    +   * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +   * events.
                    +   * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for commonUrl. + */ + public com.google.protobuf.ByteString getCommonUrlBytes() { + java.lang.Object ref = ""; + if (configCase_ == 1) { + ref = config_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (configCase_ == 1) { + config_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PER_EVENT_ENDPOINT_CONFIG_FIELD_NUMBER = 2; + + /** + * + * + *
                    +   * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +   * interactive event.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the perEventEndpointConfig field is set. + */ + @java.lang.Override + public boolean hasPerEventEndpointConfig() { + return configCase_ == 2; + } + + /** + * + * + *
                    +   * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +   * interactive event.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The perEventEndpointConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig getPerEventEndpointConfig() { + if (configCase_ == 2) { + return (com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.getDefaultInstance(); + } + + /** + * + * + *
                    +   * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +   * interactive event.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfigOrBuilder + getPerEventEndpointConfigOrBuilder() { + if (configCase_ == 2) { + return (com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (configCase_ == 1) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, config_); + } + if (configCase_ == 2) { + output.writeMessage(2, (com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) config_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (configCase_ == 1) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, config_); + } + if (configCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) config_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig other = + (com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig) obj; + + if (!getConfigCase().equals(other.getConfigCase())) return false; + switch (configCase_) { + case 1: + if (!getCommonUrl().equals(other.getCommonUrl())) return false; + break; + case 2: + if (!getPerEventEndpointConfig().equals(other.getPerEventEndpointConfig())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (configCase_) { + case 1: + hash = (37 * hash) + COMMON_URL_FIELD_NUMBER; + hash = (53 * hash) + getCommonUrl().hashCode(); + break; + case 2: + hash = (37 * hash) + PER_EVENT_ENDPOINT_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getPerEventEndpointConfig().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * HTTP endpoint configuration.
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.HttpEndpointConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.HttpEndpointConfig) + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_HttpEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_HttpEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (perEventEndpointConfigBuilder_ != null) { + perEventEndpointConfigBuilder_.clear(); + } + configCase_ = 0; + config_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_HttpEndpointConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig build() { + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig buildPartial() { + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig result = + new com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + buildPartialOneofs(result); + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig result) { + int from_bitField0_ = bitField0_; + } + + private void buildPartialOneofs(com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig result) { + result.configCase_ = configCase_; + result.config_ = this.config_; + if (configCase_ == 2 && perEventEndpointConfigBuilder_ != null) { + result.config_ = perEventEndpointConfigBuilder_.build(); + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig other) { + if (other == com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.getDefaultInstance()) + return this; + switch (other.getConfigCase()) { + case COMMON_URL: + { + configCase_ = 1; + config_ = other.config_; + onChanged(); + break; + } + case PER_EVENT_ENDPOINT_CONFIG: + { + mergePerEventEndpointConfig(other.getPerEventEndpointConfig()); + break; + } + case CONFIG_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + configCase_ = 1; + config_ = s; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetPerEventEndpointConfigFieldBuilder().getBuilder(), + extensionRegistry); + configCase_ = 2; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int configCase_ = 0; + private java.lang.Object config_; + + public ConfigCase getConfigCase() { + return ConfigCase.forNumber(configCase_); + } + + public Builder clearConfig() { + configCase_ = 0; + config_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + /** + * + * + *
                    +     * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +     * events.
                    +     * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the commonUrl field is set. + */ + @java.lang.Override + public boolean hasCommonUrl() { + return configCase_ == 1; + } + + /** + * + * + *
                    +     * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +     * events.
                    +     * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The commonUrl. + */ + @java.lang.Override + public java.lang.String getCommonUrl() { + java.lang.Object ref = ""; + if (configCase_ == 1) { + ref = config_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (configCase_ == 1) { + config_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +     * events.
                    +     * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for commonUrl. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCommonUrlBytes() { + java.lang.Object ref = ""; + if (configCase_ == 1) { + ref = config_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (configCase_ == 1) { + config_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +     * events.
                    +     * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The commonUrl to set. + * @return This builder for chaining. + */ + public Builder setCommonUrl(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + configCase_ = 1; + config_ = value; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +     * events.
                    +     * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearCommonUrl() { + if (configCase_ == 1) { + configCase_ = 0; + config_ = null; + onChanged(); + } + return this; + } + + /** + * + * + *
                    +     * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +     * events.
                    +     * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for commonUrl to set. + * @return This builder for chaining. + */ + public Builder setCommonUrlBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + configCase_ = 1; + config_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig, + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfigOrBuilder> + perEventEndpointConfigBuilder_; + + /** + * + * + *
                    +     * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +     * interactive event.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the perEventEndpointConfig field is set. + */ + @java.lang.Override + public boolean hasPerEventEndpointConfig() { + return configCase_ == 2; + } + + /** + * + * + *
                    +     * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +     * interactive event.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The perEventEndpointConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig getPerEventEndpointConfig() { + if (perEventEndpointConfigBuilder_ == null) { + if (configCase_ == 2) { + return (com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.getDefaultInstance(); + } else { + if (configCase_ == 2) { + return perEventEndpointConfigBuilder_.getMessage(); + } + return com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                    +     * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +     * interactive event.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setPerEventEndpointConfig( + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig value) { + if (perEventEndpointConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + perEventEndpointConfigBuilder_.setMessage(value); + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                    +     * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +     * interactive event.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setPerEventEndpointConfig( + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.Builder builderForValue) { + if (perEventEndpointConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + perEventEndpointConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                    +     * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +     * interactive event.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergePerEventEndpointConfig( + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig value) { + if (perEventEndpointConfigBuilder_ == null) { + if (configCase_ == 2 + && config_ + != com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig + .getDefaultInstance()) { + config_ = + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.newBuilder( + (com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 2) { + perEventEndpointConfigBuilder_.mergeFrom(value); + } else { + perEventEndpointConfigBuilder_.setMessage(value); + } + } + configCase_ = 2; + return this; + } + + /** + * + * + *
                    +     * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +     * interactive event.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearPerEventEndpointConfig() { + if (perEventEndpointConfigBuilder_ == null) { + if (configCase_ == 2) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 2) { + configCase_ = 0; + config_ = null; + } + perEventEndpointConfigBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +     * interactive event.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.Builder + getPerEventEndpointConfigBuilder() { + return internalGetPerEventEndpointConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +     * interactive event.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfigOrBuilder + getPerEventEndpointConfigOrBuilder() { + if ((configCase_ == 2) && (perEventEndpointConfigBuilder_ != null)) { + return perEventEndpointConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 2) { + return (com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) config_; + } + return com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.getDefaultInstance(); + } + } + + /** + * + * + *
                    +     * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +     * interactive event.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig, + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfigOrBuilder> + internalGetPerEventEndpointConfigFieldBuilder() { + if (perEventEndpointConfigBuilder_ == null) { + if (!(configCase_ == 2)) { + config_ = + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.getDefaultInstance(); + } + perEventEndpointConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig, + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.Builder, + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfigOrBuilder>( + (com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 2; + onChanged(); + return perEventEndpointConfigBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.HttpEndpointConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.HttpEndpointConfig) + private static final com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig(); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public HttpEndpointConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpEndpointConfigOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpEndpointConfigOrBuilder.java new file mode 100644 index 000000000000..9f8c6792df71 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpEndpointConfigOrBuilder.java @@ -0,0 +1,119 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface HttpEndpointConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.HttpEndpointConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +   * events.
                    +   * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the commonUrl field is set. + */ + boolean hasCommonUrl(); + + /** + * + * + *
                    +   * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +   * events.
                    +   * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The commonUrl. + */ + java.lang.String getCommonUrl(); + + /** + * + * + *
                    +   * Optional. The HTTPS URL to which Google Chat sends all interactive
                    +   * events.
                    +   * 
                    + * + * string common_url = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for commonUrl. + */ + com.google.protobuf.ByteString getCommonUrlBytes(); + + /** + * + * + *
                    +   * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +   * interactive event.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the perEventEndpointConfig field is set. + */ + boolean hasPerEventEndpointConfig(); + + /** + * + * + *
                    +   * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +   * interactive event.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The perEventEndpointConfig. + */ + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig getPerEventEndpointConfig(); + + /** + * + * + *
                    +   * Optional. Separate HTTPS URLs to which Google Chat sends each type of
                    +   * interactive event.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig per_event_endpoint_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfigOrBuilder + getPerEventEndpointConfigOrBuilder(); + + com.google.cloud.gsuiteaddons.v1.HttpEndpointConfig.ConfigCase getConfigCase(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpPerEventEndpointConfig.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpPerEventEndpointConfig.java new file mode 100644 index 000000000000..83041b89221b --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpPerEventEndpointConfig.java @@ -0,0 +1,1169 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * HTTP endpoint configuration for specific event types.
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig} + */ +@com.google.protobuf.Generated +public final class HttpPerEventEndpointConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) + HttpPerEventEndpointConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "HttpPerEventEndpointConfig"); + } + + // Use HttpPerEventEndpointConfig.newBuilder() to construct. + private HttpPerEventEndpointConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private HttpPerEventEndpointConfig() { + appCommandEndpoint_ = ""; + addedToSpaceEndpoint_ = ""; + messageEndpoint_ = ""; + removedFromSpaceEndpoint_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_HttpPerEventEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_HttpPerEventEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.Builder.class); + } + + public static final int APP_COMMAND_ENDPOINT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object appCommandEndpoint_ = ""; + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for app command events.
                    +   * 
                    + * + * string app_command_endpoint = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The appCommandEndpoint. + */ + @java.lang.Override + public java.lang.String getAppCommandEndpoint() { + java.lang.Object ref = appCommandEndpoint_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + appCommandEndpoint_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for app command events.
                    +   * 
                    + * + * string app_command_endpoint = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for appCommandEndpoint. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAppCommandEndpointBytes() { + java.lang.Object ref = appCommandEndpoint_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + appCommandEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ADDED_TO_SPACE_ENDPOINT_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object addedToSpaceEndpoint_ = ""; + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for added to space events.
                    +   * 
                    + * + * string added_to_space_endpoint = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The addedToSpaceEndpoint. + */ + @java.lang.Override + public java.lang.String getAddedToSpaceEndpoint() { + java.lang.Object ref = addedToSpaceEndpoint_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + addedToSpaceEndpoint_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for added to space events.
                    +   * 
                    + * + * string added_to_space_endpoint = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for addedToSpaceEndpoint. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAddedToSpaceEndpointBytes() { + java.lang.Object ref = addedToSpaceEndpoint_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + addedToSpaceEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int MESSAGE_ENDPOINT_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object messageEndpoint_ = ""; + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for message events.
                    +   * 
                    + * + * string message_endpoint = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The messageEndpoint. + */ + @java.lang.Override + public java.lang.String getMessageEndpoint() { + java.lang.Object ref = messageEndpoint_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + messageEndpoint_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for message events.
                    +   * 
                    + * + * string message_endpoint = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for messageEndpoint. + */ + @java.lang.Override + public com.google.protobuf.ByteString getMessageEndpointBytes() { + java.lang.Object ref = messageEndpoint_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + messageEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int REMOVED_FROM_SPACE_ENDPOINT_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object removedFromSpaceEndpoint_ = ""; + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for removed from space events.
                    +   * 
                    + * + * string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The removedFromSpaceEndpoint. + */ + @java.lang.Override + public java.lang.String getRemovedFromSpaceEndpoint() { + java.lang.Object ref = removedFromSpaceEndpoint_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + removedFromSpaceEndpoint_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for removed from space events.
                    +   * 
                    + * + * string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for removedFromSpaceEndpoint. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRemovedFromSpaceEndpointBytes() { + java.lang.Object ref = removedFromSpaceEndpoint_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + removedFromSpaceEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(appCommandEndpoint_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, appCommandEndpoint_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(addedToSpaceEndpoint_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, addedToSpaceEndpoint_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(messageEndpoint_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, messageEndpoint_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(removedFromSpaceEndpoint_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, removedFromSpaceEndpoint_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(appCommandEndpoint_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, appCommandEndpoint_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(addedToSpaceEndpoint_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, addedToSpaceEndpoint_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(messageEndpoint_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, messageEndpoint_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(removedFromSpaceEndpoint_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, removedFromSpaceEndpoint_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig other = + (com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) obj; + + if (!getAppCommandEndpoint().equals(other.getAppCommandEndpoint())) return false; + if (!getAddedToSpaceEndpoint().equals(other.getAddedToSpaceEndpoint())) return false; + if (!getMessageEndpoint().equals(other.getMessageEndpoint())) return false; + if (!getRemovedFromSpaceEndpoint().equals(other.getRemovedFromSpaceEndpoint())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + APP_COMMAND_ENDPOINT_FIELD_NUMBER; + hash = (53 * hash) + getAppCommandEndpoint().hashCode(); + hash = (37 * hash) + ADDED_TO_SPACE_ENDPOINT_FIELD_NUMBER; + hash = (53 * hash) + getAddedToSpaceEndpoint().hashCode(); + hash = (37 * hash) + MESSAGE_ENDPOINT_FIELD_NUMBER; + hash = (53 * hash) + getMessageEndpoint().hashCode(); + hash = (37 * hash) + REMOVED_FROM_SPACE_ENDPOINT_FIELD_NUMBER; + hash = (53 * hash) + getRemovedFromSpaceEndpoint().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * HTTP endpoint configuration for specific event types.
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_HttpPerEventEndpointConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_HttpPerEventEndpointConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.class, + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + appCommandEndpoint_ = ""; + addedToSpaceEndpoint_ = ""; + messageEndpoint_ = ""; + removedFromSpaceEndpoint_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_HttpPerEventEndpointConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig build() { + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig buildPartial() { + com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig result = + new com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.appCommandEndpoint_ = appCommandEndpoint_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.addedToSpaceEndpoint_ = addedToSpaceEndpoint_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.messageEndpoint_ = messageEndpoint_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.removedFromSpaceEndpoint_ = removedFromSpaceEndpoint_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig other) { + if (other == com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig.getDefaultInstance()) + return this; + if (!other.getAppCommandEndpoint().isEmpty()) { + appCommandEndpoint_ = other.appCommandEndpoint_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getAddedToSpaceEndpoint().isEmpty()) { + addedToSpaceEndpoint_ = other.addedToSpaceEndpoint_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getMessageEndpoint().isEmpty()) { + messageEndpoint_ = other.messageEndpoint_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getRemovedFromSpaceEndpoint().isEmpty()) { + removedFromSpaceEndpoint_ = other.removedFromSpaceEndpoint_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + appCommandEndpoint_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + addedToSpaceEndpoint_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + messageEndpoint_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + removedFromSpaceEndpoint_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object appCommandEndpoint_ = ""; + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for app command events.
                    +     * 
                    + * + * string app_command_endpoint = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The appCommandEndpoint. + */ + public java.lang.String getAppCommandEndpoint() { + java.lang.Object ref = appCommandEndpoint_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + appCommandEndpoint_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for app command events.
                    +     * 
                    + * + * string app_command_endpoint = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for appCommandEndpoint. + */ + public com.google.protobuf.ByteString getAppCommandEndpointBytes() { + java.lang.Object ref = appCommandEndpoint_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + appCommandEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for app command events.
                    +     * 
                    + * + * string app_command_endpoint = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The appCommandEndpoint to set. + * @return This builder for chaining. + */ + public Builder setAppCommandEndpoint(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + appCommandEndpoint_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for app command events.
                    +     * 
                    + * + * string app_command_endpoint = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearAppCommandEndpoint() { + appCommandEndpoint_ = getDefaultInstance().getAppCommandEndpoint(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for app command events.
                    +     * 
                    + * + * string app_command_endpoint = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for appCommandEndpoint to set. + * @return This builder for chaining. + */ + public Builder setAppCommandEndpointBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + appCommandEndpoint_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object addedToSpaceEndpoint_ = ""; + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for added to space events.
                    +     * 
                    + * + * string added_to_space_endpoint = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The addedToSpaceEndpoint. + */ + public java.lang.String getAddedToSpaceEndpoint() { + java.lang.Object ref = addedToSpaceEndpoint_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + addedToSpaceEndpoint_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for added to space events.
                    +     * 
                    + * + * string added_to_space_endpoint = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for addedToSpaceEndpoint. + */ + public com.google.protobuf.ByteString getAddedToSpaceEndpointBytes() { + java.lang.Object ref = addedToSpaceEndpoint_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + addedToSpaceEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for added to space events.
                    +     * 
                    + * + * string added_to_space_endpoint = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The addedToSpaceEndpoint to set. + * @return This builder for chaining. + */ + public Builder setAddedToSpaceEndpoint(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + addedToSpaceEndpoint_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for added to space events.
                    +     * 
                    + * + * string added_to_space_endpoint = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearAddedToSpaceEndpoint() { + addedToSpaceEndpoint_ = getDefaultInstance().getAddedToSpaceEndpoint(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for added to space events.
                    +     * 
                    + * + * string added_to_space_endpoint = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for addedToSpaceEndpoint to set. + * @return This builder for chaining. + */ + public Builder setAddedToSpaceEndpointBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + addedToSpaceEndpoint_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object messageEndpoint_ = ""; + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for message events.
                    +     * 
                    + * + * string message_endpoint = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The messageEndpoint. + */ + public java.lang.String getMessageEndpoint() { + java.lang.Object ref = messageEndpoint_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + messageEndpoint_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for message events.
                    +     * 
                    + * + * string message_endpoint = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for messageEndpoint. + */ + public com.google.protobuf.ByteString getMessageEndpointBytes() { + java.lang.Object ref = messageEndpoint_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + messageEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for message events.
                    +     * 
                    + * + * string message_endpoint = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The messageEndpoint to set. + * @return This builder for chaining. + */ + public Builder setMessageEndpoint(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + messageEndpoint_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for message events.
                    +     * 
                    + * + * string message_endpoint = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearMessageEndpoint() { + messageEndpoint_ = getDefaultInstance().getMessageEndpoint(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for message events.
                    +     * 
                    + * + * string message_endpoint = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for messageEndpoint to set. + * @return This builder for chaining. + */ + public Builder setMessageEndpointBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + messageEndpoint_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object removedFromSpaceEndpoint_ = ""; + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for removed from space events.
                    +     * 
                    + * + * string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The removedFromSpaceEndpoint. + */ + public java.lang.String getRemovedFromSpaceEndpoint() { + java.lang.Object ref = removedFromSpaceEndpoint_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + removedFromSpaceEndpoint_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for removed from space events.
                    +     * 
                    + * + * string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The bytes for removedFromSpaceEndpoint. + */ + public com.google.protobuf.ByteString getRemovedFromSpaceEndpointBytes() { + java.lang.Object ref = removedFromSpaceEndpoint_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + removedFromSpaceEndpoint_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for removed from space events.
                    +     * 
                    + * + * string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The removedFromSpaceEndpoint to set. + * @return This builder for chaining. + */ + public Builder setRemovedFromSpaceEndpoint(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + removedFromSpaceEndpoint_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for removed from space events.
                    +     * 
                    + * + * string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearRemovedFromSpaceEndpoint() { + removedFromSpaceEndpoint_ = getDefaultInstance().getRemovedFromSpaceEndpoint(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. HTTPS URL endpoint for removed from space events.
                    +     * 
                    + * + * string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The bytes for removedFromSpaceEndpoint to set. + * @return This builder for chaining. + */ + public Builder setRemovedFromSpaceEndpointBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + removedFromSpaceEndpoint_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) + private static final com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig(); + } + + public static com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public HttpPerEventEndpointConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpPerEventEndpointConfigOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpPerEventEndpointConfigOrBuilder.java new file mode 100644 index 000000000000..2335d47af7db --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/HttpPerEventEndpointConfigOrBuilder.java @@ -0,0 +1,132 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface HttpPerEventEndpointConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.HttpPerEventEndpointConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for app command events.
                    +   * 
                    + * + * string app_command_endpoint = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The appCommandEndpoint. + */ + java.lang.String getAppCommandEndpoint(); + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for app command events.
                    +   * 
                    + * + * string app_command_endpoint = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for appCommandEndpoint. + */ + com.google.protobuf.ByteString getAppCommandEndpointBytes(); + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for added to space events.
                    +   * 
                    + * + * string added_to_space_endpoint = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The addedToSpaceEndpoint. + */ + java.lang.String getAddedToSpaceEndpoint(); + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for added to space events.
                    +   * 
                    + * + * string added_to_space_endpoint = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for addedToSpaceEndpoint. + */ + com.google.protobuf.ByteString getAddedToSpaceEndpointBytes(); + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for message events.
                    +   * 
                    + * + * string message_endpoint = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The messageEndpoint. + */ + java.lang.String getMessageEndpoint(); + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for message events.
                    +   * 
                    + * + * string message_endpoint = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for messageEndpoint. + */ + com.google.protobuf.ByteString getMessageEndpointBytes(); + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for removed from space events.
                    +   * 
                    + * + * string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The removedFromSpaceEndpoint. + */ + java.lang.String getRemovedFromSpaceEndpoint(); + + /** + * + * + *
                    +   * Required. HTTPS URL endpoint for removed from space events.
                    +   * 
                    + * + * string removed_from_space_endpoint = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for removedFromSpaceEndpoint. + */ + com.google.protobuf.ByteString getRemovedFromSpaceEndpointBytes(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/InteractiveFeatureConfig.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/InteractiveFeatureConfig.java new file mode 100644 index 000000000000..fa7752579abd --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/InteractiveFeatureConfig.java @@ -0,0 +1,2334 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * Settings for the [interactive
                    + * features](https://developers.google.com/workspace/chat/interact-users-overview)
                    + * of the app.
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig} + */ +@com.google.protobuf.Generated +public final class InteractiveFeatureConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig) + InteractiveFeatureConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "InteractiveFeatureConfig"); + } + + // Use InteractiveFeatureConfig.newBuilder() to construct. + private InteractiveFeatureConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private InteractiveFeatureConfig() { + appCommands_ = java.util.Collections.emptyList(); + urlPatterns_ = java.util.Collections.emptyList(); + allowlistedTestingPrincipals_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_InteractiveFeatureConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_InteractiveFeatureConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.class, + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.Builder.class); + } + + private int bitField0_; + public static final int SUPPORTS_MULTIUSER_SPACES_FIELD_NUMBER = 1; + private boolean supportsMultiuserSpaces_ = false; + + /** + * + * + *
                    +   * Optional. Whether the app can be added to 1:1 human DMs, group chats and
                    +   * spaces. Defaults to `false` if not specified.
                    +   * 
                    + * + * optional bool supports_multiuser_spaces = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the supportsMultiuserSpaces field is set. + */ + @java.lang.Override + public boolean hasSupportsMultiuserSpaces() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                    +   * Optional. Whether the app can be added to 1:1 human DMs, group chats and
                    +   * spaces. Defaults to `false` if not specified.
                    +   * 
                    + * + * optional bool supports_multiuser_spaces = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The supportsMultiuserSpaces. + */ + @java.lang.Override + public boolean getSupportsMultiuserSpaces() { + return supportsMultiuserSpaces_; + } + + public static final int CONNECTION_CONFIG_FIELD_NUMBER = 2; + private com.google.cloud.gsuiteaddons.v1.ConnectionConfig connectionConfig_; + + /** + * + * + *
                    +   * Required. How the app receives events from Google Chat.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the connectionConfig field is set. + */ + @java.lang.Override + public boolean hasConnectionConfig() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                    +   * Required. How the app receives events from Google Chat.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The connectionConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ConnectionConfig getConnectionConfig() { + return connectionConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.ConnectionConfig.getDefaultInstance() + : connectionConfig_; + } + + /** + * + * + *
                    +   * Required. How the app receives events from Google Chat.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ConnectionConfigOrBuilder getConnectionConfigOrBuilder() { + return connectionConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.ConnectionConfig.getDefaultInstance() + : connectionConfig_; + } + + public static final int APP_COMMANDS_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private java.util.List appCommands_; + + /** + * + * + *
                    +   * Optional. Configuration for app commands.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List getAppCommandsList() { + return appCommands_; + } + + /** + * + * + *
                    +   * Optional. Configuration for app commands.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List + getAppCommandsOrBuilderList() { + return appCommands_; + } + + /** + * + * + *
                    +   * Optional. Configuration for app commands.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public int getAppCommandsCount() { + return appCommands_.size(); + } + + /** + * + * + *
                    +   * Optional. Configuration for app commands.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppCommand getAppCommands(int index) { + return appCommands_.get(index); + } + + /** + * + * + *
                    +   * Optional. Configuration for app commands.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.AppCommandOrBuilder getAppCommandsOrBuilder(int index) { + return appCommands_.get(index); + } + + public static final int URL_PATTERNS_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private java.util.List urlPatterns_; + + /** + * + * + *
                    +   * Optional. Configuration for link previews.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List getUrlPatternsList() { + return urlPatterns_; + } + + /** + * + * + *
                    +   * Optional. Configuration for link previews.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List + getUrlPatternsOrBuilderList() { + return urlPatterns_; + } + + /** + * + * + *
                    +   * Optional. Configuration for link previews.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public int getUrlPatternsCount() { + return urlPatterns_.size(); + } + + /** + * + * + *
                    +   * Optional. Configuration for link previews.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.UrlPattern getUrlPatterns(int index) { + return urlPatterns_.get(index); + } + + /** + * + * + *
                    +   * Optional. Configuration for link previews.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.UrlPatternOrBuilder getUrlPatternsOrBuilder(int index) { + return urlPatterns_.get(index); + } + + public static final int ALLOWLISTED_TESTING_PRINCIPALS_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList allowlistedTestingPrincipals_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
                    +   * Optional. The email addresses of users and groups in your Google Workspace
                    +   * domain who can find and use the app.
                    +   * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the allowlistedTestingPrincipals. + */ + public com.google.protobuf.ProtocolStringList getAllowlistedTestingPrincipalsList() { + return allowlistedTestingPrincipals_; + } + + /** + * + * + *
                    +   * Optional. The email addresses of users and groups in your Google Workspace
                    +   * domain who can find and use the app.
                    +   * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of allowlistedTestingPrincipals. + */ + public int getAllowlistedTestingPrincipalsCount() { + return allowlistedTestingPrincipals_.size(); + } + + /** + * + * + *
                    +   * Optional. The email addresses of users and groups in your Google Workspace
                    +   * domain who can find and use the app.
                    +   * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The allowlistedTestingPrincipals at the given index. + */ + public java.lang.String getAllowlistedTestingPrincipals(int index) { + return allowlistedTestingPrincipals_.get(index); + } + + /** + * + * + *
                    +   * Optional. The email addresses of users and groups in your Google Workspace
                    +   * domain who can find and use the app.
                    +   * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the allowlistedTestingPrincipals at the given index. + */ + public com.google.protobuf.ByteString getAllowlistedTestingPrincipalsBytes(int index) { + return allowlistedTestingPrincipals_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeBool(1, supportsMultiuserSpaces_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getConnectionConfig()); + } + for (int i = 0; i < appCommands_.size(); i++) { + output.writeMessage(3, appCommands_.get(i)); + } + for (int i = 0; i < urlPatterns_.size(); i++) { + output.writeMessage(4, urlPatterns_.get(i)); + } + for (int i = 0; i < allowlistedTestingPrincipals_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 5, allowlistedTestingPrincipals_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, supportsMultiuserSpaces_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getConnectionConfig()); + } + for (int i = 0; i < appCommands_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, appCommands_.get(i)); + } + for (int i = 0; i < urlPatterns_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, urlPatterns_.get(i)); + } + { + int dataSize = 0; + for (int i = 0; i < allowlistedTestingPrincipals_.size(); i++) { + dataSize += computeStringSizeNoTag(allowlistedTestingPrincipals_.getRaw(i)); + } + size += dataSize; + size += 1 * getAllowlistedTestingPrincipalsList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig other = + (com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig) obj; + + if (hasSupportsMultiuserSpaces() != other.hasSupportsMultiuserSpaces()) return false; + if (hasSupportsMultiuserSpaces()) { + if (getSupportsMultiuserSpaces() != other.getSupportsMultiuserSpaces()) return false; + } + if (hasConnectionConfig() != other.hasConnectionConfig()) return false; + if (hasConnectionConfig()) { + if (!getConnectionConfig().equals(other.getConnectionConfig())) return false; + } + if (!getAppCommandsList().equals(other.getAppCommandsList())) return false; + if (!getUrlPatternsList().equals(other.getUrlPatternsList())) return false; + if (!getAllowlistedTestingPrincipalsList().equals(other.getAllowlistedTestingPrincipalsList())) + return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasSupportsMultiuserSpaces()) { + hash = (37 * hash) + SUPPORTS_MULTIUSER_SPACES_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSupportsMultiuserSpaces()); + } + if (hasConnectionConfig()) { + hash = (37 * hash) + CONNECTION_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getConnectionConfig().hashCode(); + } + if (getAppCommandsCount() > 0) { + hash = (37 * hash) + APP_COMMANDS_FIELD_NUMBER; + hash = (53 * hash) + getAppCommandsList().hashCode(); + } + if (getUrlPatternsCount() > 0) { + hash = (37 * hash) + URL_PATTERNS_FIELD_NUMBER; + hash = (53 * hash) + getUrlPatternsList().hashCode(); + } + if (getAllowlistedTestingPrincipalsCount() > 0) { + hash = (37 * hash) + ALLOWLISTED_TESTING_PRINCIPALS_FIELD_NUMBER; + hash = (53 * hash) + getAllowlistedTestingPrincipalsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Settings for the [interactive
                    +   * features](https://developers.google.com/workspace/chat/interact-users-overview)
                    +   * of the app.
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig) + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_InteractiveFeatureConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_InteractiveFeatureConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.class, + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetConnectionConfigFieldBuilder(); + internalGetAppCommandsFieldBuilder(); + internalGetUrlPatternsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + supportsMultiuserSpaces_ = false; + connectionConfig_ = null; + if (connectionConfigBuilder_ != null) { + connectionConfigBuilder_.dispose(); + connectionConfigBuilder_ = null; + } + if (appCommandsBuilder_ == null) { + appCommands_ = java.util.Collections.emptyList(); + } else { + appCommands_ = null; + appCommandsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000004); + if (urlPatternsBuilder_ == null) { + urlPatterns_ = java.util.Collections.emptyList(); + } else { + urlPatterns_ = null; + urlPatternsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000008); + allowlistedTestingPrincipals_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_InteractiveFeatureConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig build() { + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig buildPartial() { + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig result = + new com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig result) { + if (appCommandsBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0)) { + appCommands_ = java.util.Collections.unmodifiableList(appCommands_); + bitField0_ = (bitField0_ & ~0x00000004); + } + result.appCommands_ = appCommands_; + } else { + result.appCommands_ = appCommandsBuilder_.build(); + } + if (urlPatternsBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0)) { + urlPatterns_ = java.util.Collections.unmodifiableList(urlPatterns_); + bitField0_ = (bitField0_ & ~0x00000008); + } + result.urlPatterns_ = urlPatterns_; + } else { + result.urlPatterns_ = urlPatternsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.supportsMultiuserSpaces_ = supportsMultiuserSpaces_; + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.connectionConfig_ = + connectionConfigBuilder_ == null ? connectionConfig_ : connectionConfigBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + allowlistedTestingPrincipals_.makeImmutable(); + result.allowlistedTestingPrincipals_ = allowlistedTestingPrincipals_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig other) { + if (other == com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig.getDefaultInstance()) + return this; + if (other.hasSupportsMultiuserSpaces()) { + setSupportsMultiuserSpaces(other.getSupportsMultiuserSpaces()); + } + if (other.hasConnectionConfig()) { + mergeConnectionConfig(other.getConnectionConfig()); + } + if (appCommandsBuilder_ == null) { + if (!other.appCommands_.isEmpty()) { + if (appCommands_.isEmpty()) { + appCommands_ = other.appCommands_; + bitField0_ = (bitField0_ & ~0x00000004); + } else { + ensureAppCommandsIsMutable(); + appCommands_.addAll(other.appCommands_); + } + onChanged(); + } + } else { + if (!other.appCommands_.isEmpty()) { + if (appCommandsBuilder_.isEmpty()) { + appCommandsBuilder_.dispose(); + appCommandsBuilder_ = null; + appCommands_ = other.appCommands_; + bitField0_ = (bitField0_ & ~0x00000004); + appCommandsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetAppCommandsFieldBuilder() + : null; + } else { + appCommandsBuilder_.addAllMessages(other.appCommands_); + } + } + } + if (urlPatternsBuilder_ == null) { + if (!other.urlPatterns_.isEmpty()) { + if (urlPatterns_.isEmpty()) { + urlPatterns_ = other.urlPatterns_; + bitField0_ = (bitField0_ & ~0x00000008); + } else { + ensureUrlPatternsIsMutable(); + urlPatterns_.addAll(other.urlPatterns_); + } + onChanged(); + } + } else { + if (!other.urlPatterns_.isEmpty()) { + if (urlPatternsBuilder_.isEmpty()) { + urlPatternsBuilder_.dispose(); + urlPatternsBuilder_ = null; + urlPatterns_ = other.urlPatterns_; + bitField0_ = (bitField0_ & ~0x00000008); + urlPatternsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetUrlPatternsFieldBuilder() + : null; + } else { + urlPatternsBuilder_.addAllMessages(other.urlPatterns_); + } + } + } + if (!other.allowlistedTestingPrincipals_.isEmpty()) { + if (allowlistedTestingPrincipals_.isEmpty()) { + allowlistedTestingPrincipals_ = other.allowlistedTestingPrincipals_; + bitField0_ |= 0x00000010; + } else { + ensureAllowlistedTestingPrincipalsIsMutable(); + allowlistedTestingPrincipals_.addAll(other.allowlistedTestingPrincipals_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + supportsMultiuserSpaces_ = input.readBool(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 18: + { + input.readMessage( + internalGetConnectionConfigFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + com.google.cloud.gsuiteaddons.v1.AppCommand m = + input.readMessage( + com.google.cloud.gsuiteaddons.v1.AppCommand.parser(), extensionRegistry); + if (appCommandsBuilder_ == null) { + ensureAppCommandsIsMutable(); + appCommands_.add(m); + } else { + appCommandsBuilder_.addMessage(m); + } + break; + } // case 26 + case 34: + { + com.google.cloud.gsuiteaddons.v1.UrlPattern m = + input.readMessage( + com.google.cloud.gsuiteaddons.v1.UrlPattern.parser(), extensionRegistry); + if (urlPatternsBuilder_ == null) { + ensureUrlPatternsIsMutable(); + urlPatterns_.add(m); + } else { + urlPatternsBuilder_.addMessage(m); + } + break; + } // case 34 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureAllowlistedTestingPrincipalsIsMutable(); + allowlistedTestingPrincipals_.add(s); + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private boolean supportsMultiuserSpaces_; + + /** + * + * + *
                    +     * Optional. Whether the app can be added to 1:1 human DMs, group chats and
                    +     * spaces. Defaults to `false` if not specified.
                    +     * 
                    + * + * optional bool supports_multiuser_spaces = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the supportsMultiuserSpaces field is set. + */ + @java.lang.Override + public boolean hasSupportsMultiuserSpaces() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                    +     * Optional. Whether the app can be added to 1:1 human DMs, group chats and
                    +     * spaces. Defaults to `false` if not specified.
                    +     * 
                    + * + * optional bool supports_multiuser_spaces = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The supportsMultiuserSpaces. + */ + @java.lang.Override + public boolean getSupportsMultiuserSpaces() { + return supportsMultiuserSpaces_; + } + + /** + * + * + *
                    +     * Optional. Whether the app can be added to 1:1 human DMs, group chats and
                    +     * spaces. Defaults to `false` if not specified.
                    +     * 
                    + * + * optional bool supports_multiuser_spaces = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The supportsMultiuserSpaces to set. + * @return This builder for chaining. + */ + public Builder setSupportsMultiuserSpaces(boolean value) { + + supportsMultiuserSpaces_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Whether the app can be added to 1:1 human DMs, group chats and
                    +     * spaces. Defaults to `false` if not specified.
                    +     * 
                    + * + * optional bool supports_multiuser_spaces = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearSupportsMultiuserSpaces() { + bitField0_ = (bitField0_ & ~0x00000001); + supportsMultiuserSpaces_ = false; + onChanged(); + return this; + } + + private com.google.cloud.gsuiteaddons.v1.ConnectionConfig connectionConfig_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.ConnectionConfig, + com.google.cloud.gsuiteaddons.v1.ConnectionConfig.Builder, + com.google.cloud.gsuiteaddons.v1.ConnectionConfigOrBuilder> + connectionConfigBuilder_; + + /** + * + * + *
                    +     * Required. How the app receives events from Google Chat.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the connectionConfig field is set. + */ + public boolean hasConnectionConfig() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                    +     * Required. How the app receives events from Google Chat.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The connectionConfig. + */ + public com.google.cloud.gsuiteaddons.v1.ConnectionConfig getConnectionConfig() { + if (connectionConfigBuilder_ == null) { + return connectionConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.ConnectionConfig.getDefaultInstance() + : connectionConfig_; + } else { + return connectionConfigBuilder_.getMessage(); + } + } + + /** + * + * + *
                    +     * Required. How the app receives events from Google Chat.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setConnectionConfig(com.google.cloud.gsuiteaddons.v1.ConnectionConfig value) { + if (connectionConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + connectionConfig_ = value; + } else { + connectionConfigBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. How the app receives events from Google Chat.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setConnectionConfig( + com.google.cloud.gsuiteaddons.v1.ConnectionConfig.Builder builderForValue) { + if (connectionConfigBuilder_ == null) { + connectionConfig_ = builderForValue.build(); + } else { + connectionConfigBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. How the app receives events from Google Chat.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeConnectionConfig(com.google.cloud.gsuiteaddons.v1.ConnectionConfig value) { + if (connectionConfigBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && connectionConfig_ != null + && connectionConfig_ + != com.google.cloud.gsuiteaddons.v1.ConnectionConfig.getDefaultInstance()) { + getConnectionConfigBuilder().mergeFrom(value); + } else { + connectionConfig_ = value; + } + } else { + connectionConfigBuilder_.mergeFrom(value); + } + if (connectionConfig_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
                    +     * Required. How the app receives events from Google Chat.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearConnectionConfig() { + bitField0_ = (bitField0_ & ~0x00000002); + connectionConfig_ = null; + if (connectionConfigBuilder_ != null) { + connectionConfigBuilder_.dispose(); + connectionConfigBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. How the app receives events from Google Chat.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.gsuiteaddons.v1.ConnectionConfig.Builder getConnectionConfigBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetConnectionConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * Required. How the app receives events from Google Chat.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.gsuiteaddons.v1.ConnectionConfigOrBuilder + getConnectionConfigOrBuilder() { + if (connectionConfigBuilder_ != null) { + return connectionConfigBuilder_.getMessageOrBuilder(); + } else { + return connectionConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.ConnectionConfig.getDefaultInstance() + : connectionConfig_; + } + } + + /** + * + * + *
                    +     * Required. How the app receives events from Google Chat.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.ConnectionConfig, + com.google.cloud.gsuiteaddons.v1.ConnectionConfig.Builder, + com.google.cloud.gsuiteaddons.v1.ConnectionConfigOrBuilder> + internalGetConnectionConfigFieldBuilder() { + if (connectionConfigBuilder_ == null) { + connectionConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.ConnectionConfig, + com.google.cloud.gsuiteaddons.v1.ConnectionConfig.Builder, + com.google.cloud.gsuiteaddons.v1.ConnectionConfigOrBuilder>( + getConnectionConfig(), getParentForChildren(), isClean()); + connectionConfig_ = null; + } + return connectionConfigBuilder_; + } + + private java.util.List appCommands_ = + java.util.Collections.emptyList(); + + private void ensureAppCommandsIsMutable() { + if (!((bitField0_ & 0x00000004) != 0)) { + appCommands_ = + new java.util.ArrayList(appCommands_); + bitField0_ |= 0x00000004; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.gsuiteaddons.v1.AppCommand, + com.google.cloud.gsuiteaddons.v1.AppCommand.Builder, + com.google.cloud.gsuiteaddons.v1.AppCommandOrBuilder> + appCommandsBuilder_; + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List getAppCommandsList() { + if (appCommandsBuilder_ == null) { + return java.util.Collections.unmodifiableList(appCommands_); + } else { + return appCommandsBuilder_.getMessageList(); + } + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public int getAppCommandsCount() { + if (appCommandsBuilder_ == null) { + return appCommands_.size(); + } else { + return appCommandsBuilder_.getCount(); + } + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.AppCommand getAppCommands(int index) { + if (appCommandsBuilder_ == null) { + return appCommands_.get(index); + } else { + return appCommandsBuilder_.getMessage(index); + } + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setAppCommands(int index, com.google.cloud.gsuiteaddons.v1.AppCommand value) { + if (appCommandsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAppCommandsIsMutable(); + appCommands_.set(index, value); + onChanged(); + } else { + appCommandsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setAppCommands( + int index, com.google.cloud.gsuiteaddons.v1.AppCommand.Builder builderForValue) { + if (appCommandsBuilder_ == null) { + ensureAppCommandsIsMutable(); + appCommands_.set(index, builderForValue.build()); + onChanged(); + } else { + appCommandsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addAppCommands(com.google.cloud.gsuiteaddons.v1.AppCommand value) { + if (appCommandsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAppCommandsIsMutable(); + appCommands_.add(value); + onChanged(); + } else { + appCommandsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addAppCommands(int index, com.google.cloud.gsuiteaddons.v1.AppCommand value) { + if (appCommandsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureAppCommandsIsMutable(); + appCommands_.add(index, value); + onChanged(); + } else { + appCommandsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addAppCommands( + com.google.cloud.gsuiteaddons.v1.AppCommand.Builder builderForValue) { + if (appCommandsBuilder_ == null) { + ensureAppCommandsIsMutable(); + appCommands_.add(builderForValue.build()); + onChanged(); + } else { + appCommandsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addAppCommands( + int index, com.google.cloud.gsuiteaddons.v1.AppCommand.Builder builderForValue) { + if (appCommandsBuilder_ == null) { + ensureAppCommandsIsMutable(); + appCommands_.add(index, builderForValue.build()); + onChanged(); + } else { + appCommandsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addAllAppCommands( + java.lang.Iterable values) { + if (appCommandsBuilder_ == null) { + ensureAppCommandsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, appCommands_); + onChanged(); + } else { + appCommandsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearAppCommands() { + if (appCommandsBuilder_ == null) { + appCommands_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + } else { + appCommandsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeAppCommands(int index) { + if (appCommandsBuilder_ == null) { + ensureAppCommandsIsMutable(); + appCommands_.remove(index); + onChanged(); + } else { + appCommandsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.AppCommand.Builder getAppCommandsBuilder(int index) { + return internalGetAppCommandsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.AppCommandOrBuilder getAppCommandsOrBuilder(int index) { + if (appCommandsBuilder_ == null) { + return appCommands_.get(index); + } else { + return appCommandsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List + getAppCommandsOrBuilderList() { + if (appCommandsBuilder_ != null) { + return appCommandsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(appCommands_); + } + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.AppCommand.Builder addAppCommandsBuilder() { + return internalGetAppCommandsFieldBuilder() + .addBuilder(com.google.cloud.gsuiteaddons.v1.AppCommand.getDefaultInstance()); + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.AppCommand.Builder addAppCommandsBuilder(int index) { + return internalGetAppCommandsFieldBuilder() + .addBuilder(index, com.google.cloud.gsuiteaddons.v1.AppCommand.getDefaultInstance()); + } + + /** + * + * + *
                    +     * Optional. Configuration for app commands.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List + getAppCommandsBuilderList() { + return internalGetAppCommandsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.gsuiteaddons.v1.AppCommand, + com.google.cloud.gsuiteaddons.v1.AppCommand.Builder, + com.google.cloud.gsuiteaddons.v1.AppCommandOrBuilder> + internalGetAppCommandsFieldBuilder() { + if (appCommandsBuilder_ == null) { + appCommandsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.gsuiteaddons.v1.AppCommand, + com.google.cloud.gsuiteaddons.v1.AppCommand.Builder, + com.google.cloud.gsuiteaddons.v1.AppCommandOrBuilder>( + appCommands_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); + appCommands_ = null; + } + return appCommandsBuilder_; + } + + private java.util.List urlPatterns_ = + java.util.Collections.emptyList(); + + private void ensureUrlPatternsIsMutable() { + if (!((bitField0_ & 0x00000008) != 0)) { + urlPatterns_ = + new java.util.ArrayList(urlPatterns_); + bitField0_ |= 0x00000008; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.gsuiteaddons.v1.UrlPattern, + com.google.cloud.gsuiteaddons.v1.UrlPattern.Builder, + com.google.cloud.gsuiteaddons.v1.UrlPatternOrBuilder> + urlPatternsBuilder_; + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List getUrlPatternsList() { + if (urlPatternsBuilder_ == null) { + return java.util.Collections.unmodifiableList(urlPatterns_); + } else { + return urlPatternsBuilder_.getMessageList(); + } + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public int getUrlPatternsCount() { + if (urlPatternsBuilder_ == null) { + return urlPatterns_.size(); + } else { + return urlPatternsBuilder_.getCount(); + } + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.UrlPattern getUrlPatterns(int index) { + if (urlPatternsBuilder_ == null) { + return urlPatterns_.get(index); + } else { + return urlPatternsBuilder_.getMessage(index); + } + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUrlPatterns(int index, com.google.cloud.gsuiteaddons.v1.UrlPattern value) { + if (urlPatternsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureUrlPatternsIsMutable(); + urlPatterns_.set(index, value); + onChanged(); + } else { + urlPatternsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUrlPatterns( + int index, com.google.cloud.gsuiteaddons.v1.UrlPattern.Builder builderForValue) { + if (urlPatternsBuilder_ == null) { + ensureUrlPatternsIsMutable(); + urlPatterns_.set(index, builderForValue.build()); + onChanged(); + } else { + urlPatternsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addUrlPatterns(com.google.cloud.gsuiteaddons.v1.UrlPattern value) { + if (urlPatternsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureUrlPatternsIsMutable(); + urlPatterns_.add(value); + onChanged(); + } else { + urlPatternsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addUrlPatterns(int index, com.google.cloud.gsuiteaddons.v1.UrlPattern value) { + if (urlPatternsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureUrlPatternsIsMutable(); + urlPatterns_.add(index, value); + onChanged(); + } else { + urlPatternsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addUrlPatterns( + com.google.cloud.gsuiteaddons.v1.UrlPattern.Builder builderForValue) { + if (urlPatternsBuilder_ == null) { + ensureUrlPatternsIsMutable(); + urlPatterns_.add(builderForValue.build()); + onChanged(); + } else { + urlPatternsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addUrlPatterns( + int index, com.google.cloud.gsuiteaddons.v1.UrlPattern.Builder builderForValue) { + if (urlPatternsBuilder_ == null) { + ensureUrlPatternsIsMutable(); + urlPatterns_.add(index, builderForValue.build()); + onChanged(); + } else { + urlPatternsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addAllUrlPatterns( + java.lang.Iterable values) { + if (urlPatternsBuilder_ == null) { + ensureUrlPatternsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, urlPatterns_); + onChanged(); + } else { + urlPatternsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearUrlPatterns() { + if (urlPatternsBuilder_ == null) { + urlPatterns_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + } else { + urlPatternsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeUrlPatterns(int index) { + if (urlPatternsBuilder_ == null) { + ensureUrlPatternsIsMutable(); + urlPatterns_.remove(index); + onChanged(); + } else { + urlPatternsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.UrlPattern.Builder getUrlPatternsBuilder(int index) { + return internalGetUrlPatternsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.UrlPatternOrBuilder getUrlPatternsOrBuilder(int index) { + if (urlPatternsBuilder_ == null) { + return urlPatterns_.get(index); + } else { + return urlPatternsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List + getUrlPatternsOrBuilderList() { + if (urlPatternsBuilder_ != null) { + return urlPatternsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(urlPatterns_); + } + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.UrlPattern.Builder addUrlPatternsBuilder() { + return internalGetUrlPatternsFieldBuilder() + .addBuilder(com.google.cloud.gsuiteaddons.v1.UrlPattern.getDefaultInstance()); + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.gsuiteaddons.v1.UrlPattern.Builder addUrlPatternsBuilder(int index) { + return internalGetUrlPatternsFieldBuilder() + .addBuilder(index, com.google.cloud.gsuiteaddons.v1.UrlPattern.getDefaultInstance()); + } + + /** + * + * + *
                    +     * Optional. Configuration for link previews.
                    +     * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List + getUrlPatternsBuilderList() { + return internalGetUrlPatternsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.gsuiteaddons.v1.UrlPattern, + com.google.cloud.gsuiteaddons.v1.UrlPattern.Builder, + com.google.cloud.gsuiteaddons.v1.UrlPatternOrBuilder> + internalGetUrlPatternsFieldBuilder() { + if (urlPatternsBuilder_ == null) { + urlPatternsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.gsuiteaddons.v1.UrlPattern, + com.google.cloud.gsuiteaddons.v1.UrlPattern.Builder, + com.google.cloud.gsuiteaddons.v1.UrlPatternOrBuilder>( + urlPatterns_, ((bitField0_ & 0x00000008) != 0), getParentForChildren(), isClean()); + urlPatterns_ = null; + } + return urlPatternsBuilder_; + } + + private com.google.protobuf.LazyStringArrayList allowlistedTestingPrincipals_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureAllowlistedTestingPrincipalsIsMutable() { + if (!allowlistedTestingPrincipals_.isModifiable()) { + allowlistedTestingPrincipals_ = + new com.google.protobuf.LazyStringArrayList(allowlistedTestingPrincipals_); + } + bitField0_ |= 0x00000010; + } + + /** + * + * + *
                    +     * Optional. The email addresses of users and groups in your Google Workspace
                    +     * domain who can find and use the app.
                    +     * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the allowlistedTestingPrincipals. + */ + public com.google.protobuf.ProtocolStringList getAllowlistedTestingPrincipalsList() { + allowlistedTestingPrincipals_.makeImmutable(); + return allowlistedTestingPrincipals_; + } + + /** + * + * + *
                    +     * Optional. The email addresses of users and groups in your Google Workspace
                    +     * domain who can find and use the app.
                    +     * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of allowlistedTestingPrincipals. + */ + public int getAllowlistedTestingPrincipalsCount() { + return allowlistedTestingPrincipals_.size(); + } + + /** + * + * + *
                    +     * Optional. The email addresses of users and groups in your Google Workspace
                    +     * domain who can find and use the app.
                    +     * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The allowlistedTestingPrincipals at the given index. + */ + public java.lang.String getAllowlistedTestingPrincipals(int index) { + return allowlistedTestingPrincipals_.get(index); + } + + /** + * + * + *
                    +     * Optional. The email addresses of users and groups in your Google Workspace
                    +     * domain who can find and use the app.
                    +     * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the allowlistedTestingPrincipals at the given index. + */ + public com.google.protobuf.ByteString getAllowlistedTestingPrincipalsBytes(int index) { + return allowlistedTestingPrincipals_.getByteString(index); + } + + /** + * + * + *
                    +     * Optional. The email addresses of users and groups in your Google Workspace
                    +     * domain who can find and use the app.
                    +     * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The allowlistedTestingPrincipals to set. + * @return This builder for chaining. + */ + public Builder setAllowlistedTestingPrincipals(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureAllowlistedTestingPrincipalsIsMutable(); + allowlistedTestingPrincipals_.set(index, value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The email addresses of users and groups in your Google Workspace
                    +     * domain who can find and use the app.
                    +     * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The allowlistedTestingPrincipals to add. + * @return This builder for chaining. + */ + public Builder addAllowlistedTestingPrincipals(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureAllowlistedTestingPrincipalsIsMutable(); + allowlistedTestingPrincipals_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The email addresses of users and groups in your Google Workspace
                    +     * domain who can find and use the app.
                    +     * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The allowlistedTestingPrincipals to add. + * @return This builder for chaining. + */ + public Builder addAllAllowlistedTestingPrincipals(java.lang.Iterable values) { + ensureAllowlistedTestingPrincipalsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, allowlistedTestingPrincipals_); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The email addresses of users and groups in your Google Workspace
                    +     * domain who can find and use the app.
                    +     * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearAllowlistedTestingPrincipals() { + allowlistedTestingPrincipals_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000010); + ; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The email addresses of users and groups in your Google Workspace
                    +     * domain who can find and use the app.
                    +     * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the allowlistedTestingPrincipals to add. + * @return This builder for chaining. + */ + public Builder addAllowlistedTestingPrincipalsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureAllowlistedTestingPrincipalsIsMutable(); + allowlistedTestingPrincipals_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig) + private static final com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig(); + } + + public static com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public InteractiveFeatureConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/InteractiveFeatureConfigOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/InteractiveFeatureConfigOrBuilder.java new file mode 100644 index 000000000000..c5161b6f5f57 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/InteractiveFeatureConfigOrBuilder.java @@ -0,0 +1,299 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface InteractiveFeatureConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.InteractiveFeatureConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Optional. Whether the app can be added to 1:1 human DMs, group chats and
                    +   * spaces. Defaults to `false` if not specified.
                    +   * 
                    + * + * optional bool supports_multiuser_spaces = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the supportsMultiuserSpaces field is set. + */ + boolean hasSupportsMultiuserSpaces(); + + /** + * + * + *
                    +   * Optional. Whether the app can be added to 1:1 human DMs, group chats and
                    +   * spaces. Defaults to `false` if not specified.
                    +   * 
                    + * + * optional bool supports_multiuser_spaces = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The supportsMultiuserSpaces. + */ + boolean getSupportsMultiuserSpaces(); + + /** + * + * + *
                    +   * Required. How the app receives events from Google Chat.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the connectionConfig field is set. + */ + boolean hasConnectionConfig(); + + /** + * + * + *
                    +   * Required. How the app receives events from Google Chat.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The connectionConfig. + */ + com.google.cloud.gsuiteaddons.v1.ConnectionConfig getConnectionConfig(); + + /** + * + * + *
                    +   * Required. How the app receives events from Google Chat.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ConnectionConfig connection_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.gsuiteaddons.v1.ConnectionConfigOrBuilder getConnectionConfigOrBuilder(); + + /** + * + * + *
                    +   * Optional. Configuration for app commands.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List getAppCommandsList(); + + /** + * + * + *
                    +   * Optional. Configuration for app commands.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.gsuiteaddons.v1.AppCommand getAppCommands(int index); + + /** + * + * + *
                    +   * Optional. Configuration for app commands.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + int getAppCommandsCount(); + + /** + * + * + *
                    +   * Optional. Configuration for app commands.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List + getAppCommandsOrBuilderList(); + + /** + * + * + *
                    +   * Optional. Configuration for app commands.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.AppCommand app_commands = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.gsuiteaddons.v1.AppCommandOrBuilder getAppCommandsOrBuilder(int index); + + /** + * + * + *
                    +   * Optional. Configuration for link previews.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List getUrlPatternsList(); + + /** + * + * + *
                    +   * Optional. Configuration for link previews.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.gsuiteaddons.v1.UrlPattern getUrlPatterns(int index); + + /** + * + * + *
                    +   * Optional. Configuration for link previews.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + int getUrlPatternsCount(); + + /** + * + * + *
                    +   * Optional. Configuration for link previews.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List + getUrlPatternsOrBuilderList(); + + /** + * + * + *
                    +   * Optional. Configuration for link previews.
                    +   * 
                    + * + * + * repeated .google.cloud.gsuiteaddons.v1.UrlPattern url_patterns = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.gsuiteaddons.v1.UrlPatternOrBuilder getUrlPatternsOrBuilder(int index); + + /** + * + * + *
                    +   * Optional. The email addresses of users and groups in your Google Workspace
                    +   * domain who can find and use the app.
                    +   * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the allowlistedTestingPrincipals. + */ + java.util.List getAllowlistedTestingPrincipalsList(); + + /** + * + * + *
                    +   * Optional. The email addresses of users and groups in your Google Workspace
                    +   * domain who can find and use the app.
                    +   * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of allowlistedTestingPrincipals. + */ + int getAllowlistedTestingPrincipalsCount(); + + /** + * + * + *
                    +   * Optional. The email addresses of users and groups in your Google Workspace
                    +   * domain who can find and use the app.
                    +   * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The allowlistedTestingPrincipals at the given index. + */ + java.lang.String getAllowlistedTestingPrincipals(int index); + + /** + * + * + *
                    +   * Optional. The email addresses of users and groups in your Google Workspace
                    +   * domain who can find and use the app.
                    +   * 
                    + * + * + * repeated string allowlisted_testing_principals = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the allowlistedTestingPrincipals at the given index. + */ + com.google.protobuf.ByteString getAllowlistedTestingPrincipalsBytes(int index); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UpdateChatAppConfigRequest.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UpdateChatAppConfigRequest.java new file mode 100644 index 000000000000..00766428c511 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UpdateChatAppConfigRequest.java @@ -0,0 +1,1051 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * Request message for UpdateChatAppConfig.
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest} + */ +@com.google.protobuf.Generated +public final class UpdateChatAppConfigRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest) + UpdateChatAppConfigRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "UpdateChatAppConfigRequest"); + } + + // Use UpdateChatAppConfigRequest.newBuilder() to construct. + private UpdateChatAppConfigRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private UpdateChatAppConfigRequest() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_UpdateChatAppConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_UpdateChatAppConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest.class, + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest.Builder.class); + } + + private int bitField0_; + public static final int CHAT_APP_CONFIG_FIELD_NUMBER = 1; + private com.google.cloud.gsuiteaddons.v1.ChatAppConfig chatAppConfig_; + + /** + * + * + *
                    +   * Required. The app configuration to update.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the chatAppConfig field is set. + */ + @java.lang.Override + public boolean hasChatAppConfig() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                    +   * Required. The app configuration to update.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The chatAppConfig. + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig getChatAppConfig() { + return chatAppConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.ChatAppConfig.getDefaultInstance() + : chatAppConfig_; + } + + /** + * + * + *
                    +   * Required. The app configuration to update.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.ChatAppConfigOrBuilder getChatAppConfigOrBuilder() { + return chatAppConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.ChatAppConfig.getDefaultInstance() + : chatAppConfig_; + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + + /** + * + * + *
                    +   * Optional. The list of fields to update.
                    +   *
                    +   * If omitted, only the fields with non-empty values in the provided Chat app
                    +   * configuration are updated.
                    +   * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                    +   * Optional. The list of fields to update.
                    +   *
                    +   * If omitted, only the fields with non-empty values in the provided Chat app
                    +   * configuration are updated.
                    +   * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + /** + * + * + *
                    +   * Optional. The list of fields to update.
                    +   *
                    +   * If omitted, only the fields with non-empty values in the provided Chat app
                    +   * configuration are updated.
                    +   * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getChatAppConfig()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getUpdateMask()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getChatAppConfig()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest other = + (com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest) obj; + + if (hasChatAppConfig() != other.hasChatAppConfig()) return false; + if (hasChatAppConfig()) { + if (!getChatAppConfig().equals(other.getChatAppConfig())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasChatAppConfig()) { + hash = (37 * hash) + CHAT_APP_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getChatAppConfig().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Request message for UpdateChatAppConfig.
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest) + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_UpdateChatAppConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_UpdateChatAppConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest.class, + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetChatAppConfigFieldBuilder(); + internalGetUpdateMaskFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + chatAppConfig_ = null; + if (chatAppConfigBuilder_ != null) { + chatAppConfigBuilder_.dispose(); + chatAppConfigBuilder_ = null; + } + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_UpdateChatAppConfigRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest build() { + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest buildPartial() { + com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest result = + new com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.chatAppConfig_ = + chatAppConfigBuilder_ == null ? chatAppConfig_ : chatAppConfigBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.updateMask_ = updateMaskBuilder_ == null ? updateMask_ : updateMaskBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest other) { + if (other == com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest.getDefaultInstance()) + return this; + if (other.hasChatAppConfig()) { + mergeChatAppConfig(other.getChatAppConfig()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetChatAppConfigFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.cloud.gsuiteaddons.v1.ChatAppConfig chatAppConfig_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.ChatAppConfig, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.Builder, + com.google.cloud.gsuiteaddons.v1.ChatAppConfigOrBuilder> + chatAppConfigBuilder_; + + /** + * + * + *
                    +     * Required. The app configuration to update.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the chatAppConfig field is set. + */ + public boolean hasChatAppConfig() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
                    +     * Required. The app configuration to update.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The chatAppConfig. + */ + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig getChatAppConfig() { + if (chatAppConfigBuilder_ == null) { + return chatAppConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.ChatAppConfig.getDefaultInstance() + : chatAppConfig_; + } else { + return chatAppConfigBuilder_.getMessage(); + } + } + + /** + * + * + *
                    +     * Required. The app configuration to update.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setChatAppConfig(com.google.cloud.gsuiteaddons.v1.ChatAppConfig value) { + if (chatAppConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + chatAppConfig_ = value; + } else { + chatAppConfigBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The app configuration to update.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setChatAppConfig( + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.Builder builderForValue) { + if (chatAppConfigBuilder_ == null) { + chatAppConfig_ = builderForValue.build(); + } else { + chatAppConfigBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The app configuration to update.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeChatAppConfig(com.google.cloud.gsuiteaddons.v1.ChatAppConfig value) { + if (chatAppConfigBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && chatAppConfig_ != null + && chatAppConfig_ + != com.google.cloud.gsuiteaddons.v1.ChatAppConfig.getDefaultInstance()) { + getChatAppConfigBuilder().mergeFrom(value); + } else { + chatAppConfig_ = value; + } + } else { + chatAppConfigBuilder_.mergeFrom(value); + } + if (chatAppConfig_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
                    +     * Required. The app configuration to update.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearChatAppConfig() { + bitField0_ = (bitField0_ & ~0x00000001); + chatAppConfig_ = null; + if (chatAppConfigBuilder_ != null) { + chatAppConfigBuilder_.dispose(); + chatAppConfigBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The app configuration to update.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.gsuiteaddons.v1.ChatAppConfig.Builder getChatAppConfigBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetChatAppConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * Required. The app configuration to update.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.gsuiteaddons.v1.ChatAppConfigOrBuilder getChatAppConfigOrBuilder() { + if (chatAppConfigBuilder_ != null) { + return chatAppConfigBuilder_.getMessageOrBuilder(); + } else { + return chatAppConfig_ == null + ? com.google.cloud.gsuiteaddons.v1.ChatAppConfig.getDefaultInstance() + : chatAppConfig_; + } + } + + /** + * + * + *
                    +     * Required. The app configuration to update.
                    +     * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.ChatAppConfig, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.Builder, + com.google.cloud.gsuiteaddons.v1.ChatAppConfigOrBuilder> + internalGetChatAppConfigFieldBuilder() { + if (chatAppConfigBuilder_ == null) { + chatAppConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.gsuiteaddons.v1.ChatAppConfig, + com.google.cloud.gsuiteaddons.v1.ChatAppConfig.Builder, + com.google.cloud.gsuiteaddons.v1.ChatAppConfigOrBuilder>( + getChatAppConfig(), getParentForChildren(), isClean()); + chatAppConfig_ = null; + } + return chatAppConfigBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + + /** + * + * + *
                    +     * Optional. The list of fields to update.
                    +     *
                    +     * If omitted, only the fields with non-empty values in the provided Chat app
                    +     * configuration are updated.
                    +     * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
                    +     * Optional. The list of fields to update.
                    +     *
                    +     * If omitted, only the fields with non-empty values in the provided Chat app
                    +     * configuration are updated.
                    +     * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + + /** + * + * + *
                    +     * Optional. The list of fields to update.
                    +     *
                    +     * If omitted, only the fields with non-empty values in the provided Chat app
                    +     * configuration are updated.
                    +     * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + } else { + updateMaskBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The list of fields to update.
                    +     *
                    +     * If omitted, only the fields with non-empty values in the provided Chat app
                    +     * configuration are updated.
                    +     * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The list of fields to update.
                    +     *
                    +     * If omitted, only the fields with non-empty values in the provided Chat app
                    +     * configuration are updated.
                    +     * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && updateMask_ != null + && updateMask_ != com.google.protobuf.FieldMask.getDefaultInstance()) { + getUpdateMaskBuilder().mergeFrom(value); + } else { + updateMask_ = value; + } + } else { + updateMaskBuilder_.mergeFrom(value); + } + if (updateMask_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
                    +     * Optional. The list of fields to update.
                    +     *
                    +     * If omitted, only the fields with non-empty values in the provided Chat app
                    +     * configuration are updated.
                    +     * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearUpdateMask() { + bitField0_ = (bitField0_ & ~0x00000002); + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. The list of fields to update.
                    +     *
                    +     * If omitted, only the fields with non-empty values in the provided Chat app
                    +     * configuration are updated.
                    +     * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetUpdateMaskFieldBuilder().getBuilder(); + } + + /** + * + * + *
                    +     * Optional. The list of fields to update.
                    +     *
                    +     * If omitted, only the fields with non-empty values in the provided Chat app
                    +     * configuration are updated.
                    +     * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + + /** + * + * + *
                    +     * Optional. The list of fields to update.
                    +     *
                    +     * If omitted, only the fields with non-empty values in the provided Chat app
                    +     * configuration are updated.
                    +     * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + internalGetUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest) + private static final com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest(); + } + + public static com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateChatAppConfigRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UpdateChatAppConfigRequestOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UpdateChatAppConfigRequestOrBuilder.java new file mode 100644 index 000000000000..a33d037788b9 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UpdateChatAppConfigRequestOrBuilder.java @@ -0,0 +1,120 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface UpdateChatAppConfigRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Required. The app configuration to update.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the chatAppConfig field is set. + */ + boolean hasChatAppConfig(); + + /** + * + * + *
                    +   * Required. The app configuration to update.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The chatAppConfig. + */ + com.google.cloud.gsuiteaddons.v1.ChatAppConfig getChatAppConfig(); + + /** + * + * + *
                    +   * Required. The app configuration to update.
                    +   * 
                    + * + * + * .google.cloud.gsuiteaddons.v1.ChatAppConfig chat_app_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.gsuiteaddons.v1.ChatAppConfigOrBuilder getChatAppConfigOrBuilder(); + + /** + * + * + *
                    +   * Optional. The list of fields to update.
                    +   *
                    +   * If omitted, only the fields with non-empty values in the provided Chat app
                    +   * configuration are updated.
                    +   * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + + /** + * + * + *
                    +   * Optional. The list of fields to update.
                    +   *
                    +   * If omitted, only the fields with non-empty values in the provided Chat app
                    +   * configuration are updated.
                    +   * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + + /** + * + * + *
                    +   * Optional. The list of fields to update.
                    +   *
                    +   * If omitted, only the fields with non-empty values in the provided Chat app
                    +   * configuration are updated.
                    +   * 
                    + * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UrlPattern.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UrlPattern.java new file mode 100644 index 000000000000..9b57f06d5980 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UrlPattern.java @@ -0,0 +1,835 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +/** + * + * + *
                    + * Configuration for a [link
                    + * preview](https://developers.google.com/workspace/chat/preview-links).
                    + * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.UrlPattern} + */ +@com.google.protobuf.Generated +public final class UrlPattern extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.gsuiteaddons.v1.UrlPattern) + UrlPatternOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "UrlPattern"); + } + + // Use UrlPattern.newBuilder() to construct. + private UrlPattern(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private UrlPattern() { + hostPattern_ = ""; + pathPrefix_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_UrlPattern_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_UrlPattern_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.UrlPattern.class, + com.google.cloud.gsuiteaddons.v1.UrlPattern.Builder.class); + } + + public static final int HOST_PATTERN_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object hostPattern_ = ""; + + /** + * + * + *
                    +   * Required. The domain to match.
                    +   * Match a specific subdomain, like "subdomain.example.com", or an entire
                    +   * domain by including an asterisk (*) as a leading wildcard character. For
                    +   * example, "*.example.com" matches "https://subdomain.example.com" and
                    +   * "https://any.number.of.subdomains.example.com".
                    +   * 
                    + * + * string host_pattern = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The hostPattern. + */ + @java.lang.Override + public java.lang.String getHostPattern() { + java.lang.Object ref = hostPattern_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + hostPattern_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Required. The domain to match.
                    +   * Match a specific subdomain, like "subdomain.example.com", or an entire
                    +   * domain by including an asterisk (*) as a leading wildcard character. For
                    +   * example, "*.example.com" matches "https://subdomain.example.com" and
                    +   * "https://any.number.of.subdomains.example.com".
                    +   * 
                    + * + * string host_pattern = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for hostPattern. + */ + @java.lang.Override + public com.google.protobuf.ByteString getHostPatternBytes() { + java.lang.Object ref = hostPattern_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + hostPattern_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PATH_PREFIX_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object pathPrefix_ = ""; + + /** + * + * + *
                    +   * Optional. Path prefix appended to the host pattern. If blank, matches all
                    +   * URLs in the host pattern. For example, when paired with the host pattern
                    +   * "subdomain.example.com", specify "path/" to match page URLs that begin with
                    +   * "https://subdomain.example.com/path/".
                    +   * 
                    + * + * string path_prefix = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pathPrefix. + */ + @java.lang.Override + public java.lang.String getPathPrefix() { + java.lang.Object ref = pathPrefix_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pathPrefix_ = s; + return s; + } + } + + /** + * + * + *
                    +   * Optional. Path prefix appended to the host pattern. If blank, matches all
                    +   * URLs in the host pattern. For example, when paired with the host pattern
                    +   * "subdomain.example.com", specify "path/" to match page URLs that begin with
                    +   * "https://subdomain.example.com/path/".
                    +   * 
                    + * + * string path_prefix = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pathPrefix. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPathPrefixBytes() { + java.lang.Object ref = pathPrefix_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pathPrefix_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(hostPattern_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, hostPattern_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pathPrefix_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, pathPrefix_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(hostPattern_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, hostPattern_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pathPrefix_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, pathPrefix_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.gsuiteaddons.v1.UrlPattern)) { + return super.equals(obj); + } + com.google.cloud.gsuiteaddons.v1.UrlPattern other = + (com.google.cloud.gsuiteaddons.v1.UrlPattern) obj; + + if (!getHostPattern().equals(other.getHostPattern())) return false; + if (!getPathPrefix().equals(other.getPathPrefix())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + HOST_PATTERN_FIELD_NUMBER; + hash = (53 * hash) + getHostPattern().hashCode(); + hash = (37 * hash) + PATH_PREFIX_FIELD_NUMBER; + hash = (53 * hash) + getPathPrefix().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.gsuiteaddons.v1.UrlPattern prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
                    +   * Configuration for a [link
                    +   * preview](https://developers.google.com/workspace/chat/preview-links).
                    +   * 
                    + * + * Protobuf type {@code google.cloud.gsuiteaddons.v1.UrlPattern} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.gsuiteaddons.v1.UrlPattern) + com.google.cloud.gsuiteaddons.v1.UrlPatternOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_UrlPattern_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_UrlPattern_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.gsuiteaddons.v1.UrlPattern.class, + com.google.cloud.gsuiteaddons.v1.UrlPattern.Builder.class); + } + + // Construct using com.google.cloud.gsuiteaddons.v1.UrlPattern.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + hostPattern_ = ""; + pathPrefix_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsProto + .internal_static_google_cloud_gsuiteaddons_v1_UrlPattern_descriptor; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.UrlPattern getDefaultInstanceForType() { + return com.google.cloud.gsuiteaddons.v1.UrlPattern.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.UrlPattern build() { + com.google.cloud.gsuiteaddons.v1.UrlPattern result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.UrlPattern buildPartial() { + com.google.cloud.gsuiteaddons.v1.UrlPattern result = + new com.google.cloud.gsuiteaddons.v1.UrlPattern(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.gsuiteaddons.v1.UrlPattern result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.hostPattern_ = hostPattern_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pathPrefix_ = pathPrefix_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.gsuiteaddons.v1.UrlPattern) { + return mergeFrom((com.google.cloud.gsuiteaddons.v1.UrlPattern) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.gsuiteaddons.v1.UrlPattern other) { + if (other == com.google.cloud.gsuiteaddons.v1.UrlPattern.getDefaultInstance()) return this; + if (!other.getHostPattern().isEmpty()) { + hostPattern_ = other.hostPattern_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getPathPrefix().isEmpty()) { + pathPrefix_ = other.pathPrefix_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + hostPattern_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + pathPrefix_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object hostPattern_ = ""; + + /** + * + * + *
                    +     * Required. The domain to match.
                    +     * Match a specific subdomain, like "subdomain.example.com", or an entire
                    +     * domain by including an asterisk (*) as a leading wildcard character. For
                    +     * example, "*.example.com" matches "https://subdomain.example.com" and
                    +     * "https://any.number.of.subdomains.example.com".
                    +     * 
                    + * + * string host_pattern = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The hostPattern. + */ + public java.lang.String getHostPattern() { + java.lang.Object ref = hostPattern_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + hostPattern_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Required. The domain to match.
                    +     * Match a specific subdomain, like "subdomain.example.com", or an entire
                    +     * domain by including an asterisk (*) as a leading wildcard character. For
                    +     * example, "*.example.com" matches "https://subdomain.example.com" and
                    +     * "https://any.number.of.subdomains.example.com".
                    +     * 
                    + * + * string host_pattern = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for hostPattern. + */ + public com.google.protobuf.ByteString getHostPatternBytes() { + java.lang.Object ref = hostPattern_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + hostPattern_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Required. The domain to match.
                    +     * Match a specific subdomain, like "subdomain.example.com", or an entire
                    +     * domain by including an asterisk (*) as a leading wildcard character. For
                    +     * example, "*.example.com" matches "https://subdomain.example.com" and
                    +     * "https://any.number.of.subdomains.example.com".
                    +     * 
                    + * + * string host_pattern = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The hostPattern to set. + * @return This builder for chaining. + */ + public Builder setHostPattern(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + hostPattern_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The domain to match.
                    +     * Match a specific subdomain, like "subdomain.example.com", or an entire
                    +     * domain by including an asterisk (*) as a leading wildcard character. For
                    +     * example, "*.example.com" matches "https://subdomain.example.com" and
                    +     * "https://any.number.of.subdomains.example.com".
                    +     * 
                    + * + * string host_pattern = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearHostPattern() { + hostPattern_ = getDefaultInstance().getHostPattern(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Required. The domain to match.
                    +     * Match a specific subdomain, like "subdomain.example.com", or an entire
                    +     * domain by including an asterisk (*) as a leading wildcard character. For
                    +     * example, "*.example.com" matches "https://subdomain.example.com" and
                    +     * "https://any.number.of.subdomains.example.com".
                    +     * 
                    + * + * string host_pattern = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for hostPattern to set. + * @return This builder for chaining. + */ + public Builder setHostPatternBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + hostPattern_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object pathPrefix_ = ""; + + /** + * + * + *
                    +     * Optional. Path prefix appended to the host pattern. If blank, matches all
                    +     * URLs in the host pattern. For example, when paired with the host pattern
                    +     * "subdomain.example.com", specify "path/" to match page URLs that begin with
                    +     * "https://subdomain.example.com/path/".
                    +     * 
                    + * + * string path_prefix = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pathPrefix. + */ + public java.lang.String getPathPrefix() { + java.lang.Object ref = pathPrefix_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pathPrefix_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
                    +     * Optional. Path prefix appended to the host pattern. If blank, matches all
                    +     * URLs in the host pattern. For example, when paired with the host pattern
                    +     * "subdomain.example.com", specify "path/" to match page URLs that begin with
                    +     * "https://subdomain.example.com/path/".
                    +     * 
                    + * + * string path_prefix = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pathPrefix. + */ + public com.google.protobuf.ByteString getPathPrefixBytes() { + java.lang.Object ref = pathPrefix_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pathPrefix_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
                    +     * Optional. Path prefix appended to the host pattern. If blank, matches all
                    +     * URLs in the host pattern. For example, when paired with the host pattern
                    +     * "subdomain.example.com", specify "path/" to match page URLs that begin with
                    +     * "https://subdomain.example.com/path/".
                    +     * 
                    + * + * string path_prefix = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pathPrefix to set. + * @return This builder for chaining. + */ + public Builder setPathPrefix(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pathPrefix_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Path prefix appended to the host pattern. If blank, matches all
                    +     * URLs in the host pattern. For example, when paired with the host pattern
                    +     * "subdomain.example.com", specify "path/" to match page URLs that begin with
                    +     * "https://subdomain.example.com/path/".
                    +     * 
                    + * + * string path_prefix = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPathPrefix() { + pathPrefix_ = getDefaultInstance().getPathPrefix(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
                    +     * Optional. Path prefix appended to the host pattern. If blank, matches all
                    +     * URLs in the host pattern. For example, when paired with the host pattern
                    +     * "subdomain.example.com", specify "path/" to match page URLs that begin with
                    +     * "https://subdomain.example.com/path/".
                    +     * 
                    + * + * string path_prefix = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pathPrefix to set. + * @return This builder for chaining. + */ + public Builder setPathPrefixBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pathPrefix_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.gsuiteaddons.v1.UrlPattern) + } + + // @@protoc_insertion_point(class_scope:google.cloud.gsuiteaddons.v1.UrlPattern) + private static final com.google.cloud.gsuiteaddons.v1.UrlPattern DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.gsuiteaddons.v1.UrlPattern(); + } + + public static com.google.cloud.gsuiteaddons.v1.UrlPattern getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UrlPattern parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.gsuiteaddons.v1.UrlPattern getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UrlPatternOrBuilder.java b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UrlPatternOrBuilder.java new file mode 100644 index 000000000000..af8c7a9423a5 --- /dev/null +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/java/com/google/cloud/gsuiteaddons/v1/UrlPatternOrBuilder.java @@ -0,0 +1,94 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.gsuiteaddons.v1; + +@com.google.protobuf.Generated +public interface UrlPatternOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.gsuiteaddons.v1.UrlPattern) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
                    +   * Required. The domain to match.
                    +   * Match a specific subdomain, like "subdomain.example.com", or an entire
                    +   * domain by including an asterisk (*) as a leading wildcard character. For
                    +   * example, "*.example.com" matches "https://subdomain.example.com" and
                    +   * "https://any.number.of.subdomains.example.com".
                    +   * 
                    + * + * string host_pattern = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The hostPattern. + */ + java.lang.String getHostPattern(); + + /** + * + * + *
                    +   * Required. The domain to match.
                    +   * Match a specific subdomain, like "subdomain.example.com", or an entire
                    +   * domain by including an asterisk (*) as a leading wildcard character. For
                    +   * example, "*.example.com" matches "https://subdomain.example.com" and
                    +   * "https://any.number.of.subdomains.example.com".
                    +   * 
                    + * + * string host_pattern = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for hostPattern. + */ + com.google.protobuf.ByteString getHostPatternBytes(); + + /** + * + * + *
                    +   * Optional. Path prefix appended to the host pattern. If blank, matches all
                    +   * URLs in the host pattern. For example, when paired with the host pattern
                    +   * "subdomain.example.com", specify "path/" to match page URLs that begin with
                    +   * "https://subdomain.example.com/path/".
                    +   * 
                    + * + * string path_prefix = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pathPrefix. + */ + java.lang.String getPathPrefix(); + + /** + * + * + *
                    +   * Optional. Path prefix appended to the host pattern. If blank, matches all
                    +   * URLs in the host pattern. For example, when paired with the host pattern
                    +   * "subdomain.example.com", specify "path/" to match page URLs that begin with
                    +   * "https://subdomain.example.com/path/".
                    +   * 
                    + * + * string path_prefix = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pathPrefix. + */ + com.google.protobuf.ByteString getPathPrefixBytes(); +} diff --git a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/proto/google/cloud/gsuiteaddons/v1/gsuiteaddons.proto b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/proto/google/cloud/gsuiteaddons/v1/gsuiteaddons.proto index 2828d220f865..73c1545a61e2 100644 --- a/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/proto/google/cloud/gsuiteaddons/v1/gsuiteaddons.proto +++ b/java-gsuite-addons/proto-google-cloud-gsuite-addons-v1/src/main/proto/google/cloud/gsuiteaddons/v1/gsuiteaddons.proto @@ -28,6 +28,7 @@ import "google/apps/script/type/script_manifest.proto"; import "google/apps/script/type/sheets/sheets_addon_manifest.proto"; import "google/apps/script/type/slides/slides_addon_manifest.proto"; import "google/protobuf/empty.proto"; +import "google/protobuf/field_mask.proto"; import "google/protobuf/wrappers.proto"; option csharp_namespace = "Google.Cloud.GSuiteAddOns.V1"; @@ -37,39 +38,19 @@ option java_outer_classname = "GSuiteAddOnsProto"; option java_package = "com.google.cloud.gsuiteaddons.v1"; option php_namespace = "Google\\Cloud\\GSuiteAddOns\\V1"; option ruby_package = "Google::Cloud::GSuiteAddOns::V1"; - -// A service for managing Google Workspace add-ons deployments. -// -// A Google Workspace add-on is a third-party embedded component that can be -// installed in Google Workspace Applications like Gmail, Calendar, Drive, and -// the Google Docs, Sheets, and Slides editors. Google Workspace add-ons can -// display UI cards, receive contextual information from the host application, -// and perform actions in the host application (See: -// https://developers.google.com/gsuite/add-ons/overview for more information). -// -// A Google Workspace add-on deployment resource specifies metadata about the -// add-on, including a specification of the entry points in the host application -// that trigger add-on executions (see: -// https://developers.google.com/gsuite/add-ons/concepts/gsuite-manifests). -// Add-on deployments defined via the Google Workspace add-ons API define their -// entrypoints using HTTPS URLs (See: -// https://developers.google.com/gsuite/add-ons/guides/alternate-runtimes), -// -// A Google Workspace add-on deployment can be installed in developer mode, -// which allows an add-on developer to test the experience an end-user would see -// when installing and running the add-on in their G Suite applications. When -// running in developer mode, more detailed error messages are exposed in the -// add-on UI to aid in debugging. -// -// A Google Workspace add-on deployment can be published to Google Workspace -// Marketplace, which allows other Google Workspace users to discover and -// install the add-on. See: -// https://developers.google.com/gsuite/add-ons/how-tos/publish-add-on-overview -// for details. +option (google.api.resource_definition) = { + type: "pubsub.googleapis.com/Topic" + pattern: "projects/{project}/topics/{topic}" + plural: "topics" + singular: "topic" +}; + +// A service for managing Google Workspace add-ons. service GSuiteAddOns { option (google.api.default_host) = "gsuiteaddons.googleapis.com"; option (google.api.oauth_scopes) = - "https://www.googleapis.com/auth/cloud-platform"; + "https://www.googleapis.com/auth/cloud-platform," + "https://www.googleapis.com/auth/cloud-platform.read-only"; // Gets the authorization information for deployments in a given project. rpc GetAuthorization(GetAuthorizationRequest) returns (Authorization) { @@ -154,6 +135,35 @@ service GSuiteAddOns { }; option (google.api.method_signature) = "name"; } + + // Gets the Chat app configuration of a project. Only Chat apps built as + // Google Workspace add-ons are supported. Each Google Cloud project has + // exactly one Chat app configuration. + // + // Requires authenticating and authorizing with user credentials and the + // `gsuiteaddons.chatAppConfigs.get` and `chat.bots.get` IAM permissions on + // the project. + rpc GetChatAppConfig(GetChatAppConfigRequest) returns (ChatAppConfig) { + option (google.api.http) = { + get: "/v1/{name=projects/*/chatAppConfig}" + }; + option (google.api.method_signature) = "name"; + } + + // Updates the Chat app configuration of a project. Only Chat apps built as + // Google Workspace add-ons are supported. Each Google Cloud project has + // exactly one Chat app configuration. + // + // Requires authenticating and authorizing with user credentials and the + // `gsuiteaddons.chatAppConfigs.update`, `chat.bots.update` and + // `chat.bots.get` IAM permissions on the project. + rpc UpdateChatAppConfig(UpdateChatAppConfigRequest) returns (ChatAppConfig) { + option (google.api.http) = { + patch: "/v1/{chat_app_config.name=projects/*/chatAppConfig}" + body: "chat_app_config" + }; + option (google.api.method_signature) = "chat_app_config,update_mask"; + } } // Request message to get Google Workspace add-ons authorization information. @@ -387,3 +397,355 @@ message AddOns { // Options for sending requests to add-on HTTP endpoints google.apps.script.type.HttpOptions http_options = 15; } + +// Request message to get the Chat app configuration. +message GetChatAppConfigRequest { + // A view that specifies which fields should be populated in the ChatAppConfig + // resource. + enum ChatAppConfigView { + // The default or unset value. Defaults to `BASIC`. + CHAT_APP_CONFIG_VIEW_UNSPECIFIED = 0; + + // Populates only the basic metadata about the app configuration, without + // the interactive feature configuration. + // This is the default value. + BASIC = 1; + + // Populates all the fields including the interactive feature + // configurations. + FULL = 2; + } + + // Required. Resource name of the Chat app configuration. + // + // Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google + // Cloud project number. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "gsuiteaddons.googleapis.com/ChatAppConfig" + } + ]; + + // Optional. The view of the ChatAppConfig to return. If unspecified, defaults + // to `BASIC`. + ChatAppConfigView view = 2 [(google.api.field_behavior) = OPTIONAL]; +} + +// Request message for UpdateChatAppConfig. +message UpdateChatAppConfigRequest { + // Required. The app configuration to update. + ChatAppConfig chat_app_config = 1 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The list of fields to update. + // + // If omitted, only the fields with non-empty values in the provided Chat app + // configuration are updated. + google.protobuf.FieldMask update_mask = 2 + [(google.api.field_behavior) = OPTIONAL]; +} + +// Represents the configuration of a Google Chat app built as a Google Workspace +// add-on. +message ChatAppConfig { + option (google.api.resource) = { + type: "gsuiteaddons.googleapis.com/ChatAppConfig" + pattern: "projects/{project}/chatAppConfig" + plural: "chatAppConfigs" + singular: "chatAppConfig" + }; + + // The current state of the Chat app. + enum AppState { + // Default value. Unspecified. + APP_STATE_UNSPECIFIED = 0; + + // Maps to LIVE in the Chat API configuration page. + // The app is active, it can be found and used by people with visibility. + ACTIVE = 1; + + // The app is disabled, it can no longer be found by anyone, and nobody can + // talk to the app any more. + DISABLED = 2; + } + + // The markup syntax used to format message text for this Chat app. + enum MarkupSyntax { + // Default value. Unspecified. Existing Chat apps created before + // `markup_syntax` was introduced have this value and use + // `MARKUP_SYNTAX_CHAT` until explicitly updated. + MARKUP_SYNTAX_UNSPECIFIED = 0; + + // Uses Google Chat's markup syntax. + // See + // https://developers.google.com/workspace/chat/format-messages#format-texts + // for more information. + MARKUP_SYNTAX_CHAT = 1; + + // Uses Markdown syntax. This syntax is based on the + // [CommonMark](https://commonmark.org/help/) specification, with additional + // extensions. + // See + // https://developers.google.com/workspace/chat/format-messages#format-texts + // for more information. + MARKUP_SYNTAX_MARKDOWN = 2; + } + + // Required. Identifier. Resource name of the Chat app configuration. + // + // Format: `projects/{project}/chatAppConfig`, where `{project}` is the Google + // Cloud project number. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.field_behavior) = IDENTIFIER + ]; + + // Required. The display name of the Chat app. Length should be between 3 and + // 25 characters. + string display_name = 2 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The URL for the app's avatar image. Must be an HTTPS URL that + // hosts a square (aspect ratio of 1:1) PNG image. Recommended minimum size: + // 256 by 256 pixels. A default app avatar will be used if not specified. + optional string avatar_uri = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Required. A short description of the Chat app. + // Should be between 1 and 40 characters. + string description = 4 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The state of the app. Defaults to `ACTIVE` if not specified. + optional AppState state = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The settings for interactive features of the app. If this is not + // provided, the app will be non-interactive, meaning that it can use the Chat + // API, but users can't interact with the app. + InteractiveFeatureConfig interactive_feature_config = 6 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Whether to log errors to Cloud Logging. Defaults to `false` if + // not specified. + optional bool error_logging_enabled = 7 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The default markup syntax for messages sent or read by this Chat + // app. Defaults to `MARKUP_SYNTAX_MARKDOWN` if not specified. + optional MarkupSyntax markup_syntax = 8 + [(google.api.field_behavior) = OPTIONAL]; +} + +// Settings for the [interactive +// features](https://developers.google.com/workspace/chat/interact-users-overview) +// of the app. +message InteractiveFeatureConfig { + // Optional. Whether the app can be added to 1:1 human DMs, group chats and + // spaces. Defaults to `false` if not specified. + optional bool supports_multiuser_spaces = 1 + [(google.api.field_behavior) = OPTIONAL]; + + // Required. How the app receives events from Google Chat. + ConnectionConfig connection_config = 2 + [(google.api.field_behavior) = REQUIRED]; + + // Optional. Configuration for app commands. + repeated AppCommand app_commands = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Configuration for link previews. + repeated UrlPattern url_patterns = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The email addresses of users and groups in your Google Workspace + // domain who can find and use the app. + repeated string allowlisted_testing_principals = 5 + [(google.api.field_behavior) = OPTIONAL]; +} + +// How the app receives events. +message ConnectionConfig { + // The type of connection. + oneof config { + // HTTP endpoint configuration. + HttpEndpointConfig http_endpoint_config = 1; + + // Apps Script deployment configuration. + AppsScriptEndpointConfig apps_script_endpoint_config = 2; + + // Pub/Sub topic configuration. + CloudPubSubEndpointConfig cloud_pub_sub_endpoint_config = 3; + + // Dialogflow configuration. + DialogflowEndpointConfig dialogflow_endpoint_config = 4; + } +} + +// HTTP endpoint configuration. +message HttpEndpointConfig { + // The HTTP endpoint URL configuration. + oneof config { + // Optional. The HTTPS URL to which Google Chat sends all interactive + // events. + string common_url = 1 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Separate HTTPS URLs to which Google Chat sends each type of + // interactive event. + HttpPerEventEndpointConfig per_event_endpoint_config = 2 + [(google.api.field_behavior) = OPTIONAL]; + } +} + +// HTTP endpoint configuration for specific event types. +message HttpPerEventEndpointConfig { + // Required. HTTPS URL endpoint for app command events. + string app_command_endpoint = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. HTTPS URL endpoint for added to space events. + string added_to_space_endpoint = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. HTTPS URL endpoint for message events. + string message_endpoint = 3 [(google.api.field_behavior) = REQUIRED]; + + // Required. HTTPS URL endpoint for removed from space events. + string removed_from_space_endpoint = 4 + [(google.api.field_behavior) = REQUIRED]; +} + +// Apps Script endpoint configuration. +message AppsScriptEndpointConfig { + // Required. The Apps Script deployment ID. + string deployment_id = 1 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The names of the Apps Script functions that Google Chat calls + // for each type of interactive event. If not specified, Chat calls the + // default function for each event type. + AppsScriptPerEventEndpointConfig per_event_endpoint_config = 2 + [(google.api.field_behavior) = OPTIONAL]; +} + +// Apps Script endpoint configuration for specific event types. +message AppsScriptPerEventEndpointConfig { + // Optional. Function name for app command events. If not specified, the + // default `onAppCommand` function name will be used. + optional string app_command_endpoint = 1 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Function name for added to space events. If not specified, the + // default `onAddedToSpace` function name will be used. + optional string added_to_space_endpoint = 2 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Function name for message events. If not specified, the default + // `onMessage` function name will be used. + optional string message_endpoint = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Function name for removed from space events. If not specified, + // the default `onRemovedFromSpace` function name will be used. + optional string removed_from_space_endpoint = 4 + [(google.api.field_behavior) = OPTIONAL]; +} + +// Pub/Sub endpoint configuration. +message CloudPubSubEndpointConfig { + // Required. The Pub/Sub topic to which Google Chat publishes all interactive + // events. The topic must be in the same Google Cloud project as the app, and + // Chat must have permission to publish messages to the topic. For details, + // see [Build a Google Chat app with + // Pub/Sub](https://developers.google.com/workspace/chat/quickstart/pub-sub#configure-chat-app). + // + // Format: `projects/{project}/topics/{topic}` + string topic = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { type: "pubsub.googleapis.com/Topic" } + ]; +} + +// Dialogflow endpoint configuration. +message DialogflowEndpointConfig { + // Dialogflow edition type. + enum DialogflowEdition { + // Default value. Unspecified. + DIALOGFLOW_EDITION_UNSPECIFIED = 0; + + // Dialogflow ES edition. To use this edition, a Dialogflow ES agent must + // exist in the same Google Cloud project as the app. Google Chat sends all + // interactive events to that agent. + ES = 1; + + // Dialogflow CX edition. To use this edition, a Dialogflow CX agent must + // exist in the same Google Cloud project as the app and be specified in the + // `agent` field. Google Chat sends all interactive events to that agent. + CX = 2; + } + + // Required. The Dialogflow edition. + DialogflowEdition dialogflow_edition = 1 + [(google.api.field_behavior) = REQUIRED]; + + // Optional. The Dialogflow CX agent or environment name. + // Required for Dialogflow CX. Do not set for Dialogflow ES. + // + // Format: `projects/{project}/locations/{location}/agents/{agent}` or + // `projects/{project}/locations/{location}/agents/{agent}/environments/{environment}`. + optional string agent = 2 [(google.api.field_behavior) = OPTIONAL]; +} + +// Configuration for an [app +// command](https://developers.google.com/workspace/chat/commands). +message AppCommand { + // The type of the App Command. + enum CommandType { + // Default value. Unspecified. + COMMAND_TYPE_UNSPECIFIED = 0; + + // A command invoked by typing a '/' followed by the command name. + // It may accept additional arguments in the message text. + SLASH_COMMAND = 1; + + // A quick command invoked from the message compose context menu. + // Quick commands do not accept additional arguments. + QUICK_COMMAND = 2; + + // A command invoked from a message context menu. + MESSAGE_ACTION = 3; + } + + // Required. The type of this command. + CommandType command_type = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The ID of the command (1-1000). Must be unique within the app. + int32 command_id = 2 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The name of the command. Required for SLASH_COMMAND, do not set + // for other command types. Must start with a "/", e.g., "/command". + string command = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The user-friendly display name of the command. Required for + // MESSAGE_ACTION and QUICK_COMMAND, do not set for SLASH_COMMAND. + string display_name = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Required. A short description of the command. + string description = 5 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Whether this command should trigger a dialog. Defaults to + // `false`, if not specified. + bool dialog_enabled = 6 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A notification to be sent to the user when they trigger the + // message action. Only supported for MESSAGE_ACTION commands. + string loading_notification_message = 7 + [(google.api.field_behavior) = OPTIONAL]; +} + +// Configuration for a [link +// preview](https://developers.google.com/workspace/chat/preview-links). +message UrlPattern { + // Required. The domain to match. + // Match a specific subdomain, like "subdomain.example.com", or an entire + // domain by including an asterisk (*) as a leading wildcard character. For + // example, "*.example.com" matches "https://subdomain.example.com" and + // "https://any.number.of.subdomains.example.com". + string host_pattern = 1 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Path prefix appended to the host pattern. If blank, matches all + // URLs in the host pattern. For example, when paired with the host pattern + // "subdomain.example.com", specify "path/" to match page URLs that begin with + // "https://subdomain.example.com/path/". + string path_prefix = 2 [(google.api.field_behavior) = OPTIONAL]; +} diff --git a/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/AsyncGetChatAppConfig.java b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/AsyncGetChatAppConfig.java new file mode 100644 index 000000000000..83c52de650f5 --- /dev/null +++ b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/AsyncGetChatAppConfig.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.gsuiteaddons.v1.samples; + +// [START gsuiteaddons_v1_generated_GSuiteAddOns_GetChatAppConfig_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.gsuiteaddons.v1.ChatAppConfig; +import com.google.cloud.gsuiteaddons.v1.ChatAppConfigName; +import com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsClient; +import com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest; + +public class AsyncGetChatAppConfig { + + public static void main(String[] args) throws Exception { + asyncGetChatAppConfig(); + } + + public static void asyncGetChatAppConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) { + GetChatAppConfigRequest request = + GetChatAppConfigRequest.newBuilder() + .setName(ChatAppConfigName.of("[PROJECT]").toString()) + .build(); + ApiFuture future = + gSuiteAddOnsClient.getChatAppConfigCallable().futureCall(request); + // Do something. + ChatAppConfig response = future.get(); + } + } +} +// [END gsuiteaddons_v1_generated_GSuiteAddOns_GetChatAppConfig_async] diff --git a/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/SyncGetChatAppConfig.java b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/SyncGetChatAppConfig.java new file mode 100644 index 000000000000..46c3ab4254ad --- /dev/null +++ b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/SyncGetChatAppConfig.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.gsuiteaddons.v1.samples; + +// [START gsuiteaddons_v1_generated_GSuiteAddOns_GetChatAppConfig_sync] +import com.google.cloud.gsuiteaddons.v1.ChatAppConfig; +import com.google.cloud.gsuiteaddons.v1.ChatAppConfigName; +import com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsClient; +import com.google.cloud.gsuiteaddons.v1.GetChatAppConfigRequest; + +public class SyncGetChatAppConfig { + + public static void main(String[] args) throws Exception { + syncGetChatAppConfig(); + } + + public static void syncGetChatAppConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) { + GetChatAppConfigRequest request = + GetChatAppConfigRequest.newBuilder() + .setName(ChatAppConfigName.of("[PROJECT]").toString()) + .build(); + ChatAppConfig response = gSuiteAddOnsClient.getChatAppConfig(request); + } + } +} +// [END gsuiteaddons_v1_generated_GSuiteAddOns_GetChatAppConfig_sync] diff --git a/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/SyncGetChatAppConfigChatappconfigname.java b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/SyncGetChatAppConfigChatappconfigname.java new file mode 100644 index 000000000000..0da77c650daa --- /dev/null +++ b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/SyncGetChatAppConfigChatappconfigname.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.gsuiteaddons.v1.samples; + +// [START gsuiteaddons_v1_generated_GSuiteAddOns_GetChatAppConfig_Chatappconfigname_sync] +import com.google.cloud.gsuiteaddons.v1.ChatAppConfig; +import com.google.cloud.gsuiteaddons.v1.ChatAppConfigName; +import com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsClient; + +public class SyncGetChatAppConfigChatappconfigname { + + public static void main(String[] args) throws Exception { + syncGetChatAppConfigChatappconfigname(); + } + + public static void syncGetChatAppConfigChatappconfigname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) { + ChatAppConfigName name = ChatAppConfigName.of("[PROJECT]"); + ChatAppConfig response = gSuiteAddOnsClient.getChatAppConfig(name); + } + } +} +// [END gsuiteaddons_v1_generated_GSuiteAddOns_GetChatAppConfig_Chatappconfigname_sync] diff --git a/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/SyncGetChatAppConfigString.java b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/SyncGetChatAppConfigString.java new file mode 100644 index 000000000000..67bf5c8968ff --- /dev/null +++ b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/getchatappconfig/SyncGetChatAppConfigString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.gsuiteaddons.v1.samples; + +// [START gsuiteaddons_v1_generated_GSuiteAddOns_GetChatAppConfig_String_sync] +import com.google.cloud.gsuiteaddons.v1.ChatAppConfig; +import com.google.cloud.gsuiteaddons.v1.ChatAppConfigName; +import com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsClient; + +public class SyncGetChatAppConfigString { + + public static void main(String[] args) throws Exception { + syncGetChatAppConfigString(); + } + + public static void syncGetChatAppConfigString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) { + String name = ChatAppConfigName.of("[PROJECT]").toString(); + ChatAppConfig response = gSuiteAddOnsClient.getChatAppConfig(name); + } + } +} +// [END gsuiteaddons_v1_generated_GSuiteAddOns_GetChatAppConfig_String_sync] diff --git a/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/updatechatappconfig/AsyncUpdateChatAppConfig.java b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/updatechatappconfig/AsyncUpdateChatAppConfig.java new file mode 100644 index 000000000000..bf87821ffce7 --- /dev/null +++ b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/updatechatappconfig/AsyncUpdateChatAppConfig.java @@ -0,0 +1,51 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.gsuiteaddons.v1.samples; + +// [START gsuiteaddons_v1_generated_GSuiteAddOns_UpdateChatAppConfig_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.gsuiteaddons.v1.ChatAppConfig; +import com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsClient; +import com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateChatAppConfig { + + public static void main(String[] args) throws Exception { + asyncUpdateChatAppConfig(); + } + + public static void asyncUpdateChatAppConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) { + UpdateChatAppConfigRequest request = + UpdateChatAppConfigRequest.newBuilder() + .setChatAppConfig(ChatAppConfig.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ApiFuture future = + gSuiteAddOnsClient.updateChatAppConfigCallable().futureCall(request); + // Do something. + ChatAppConfig response = future.get(); + } + } +} +// [END gsuiteaddons_v1_generated_GSuiteAddOns_UpdateChatAppConfig_async] diff --git a/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/updatechatappconfig/SyncUpdateChatAppConfig.java b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/updatechatappconfig/SyncUpdateChatAppConfig.java new file mode 100644 index 000000000000..9f0f66c30d49 --- /dev/null +++ b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/updatechatappconfig/SyncUpdateChatAppConfig.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.gsuiteaddons.v1.samples; + +// [START gsuiteaddons_v1_generated_GSuiteAddOns_UpdateChatAppConfig_sync] +import com.google.cloud.gsuiteaddons.v1.ChatAppConfig; +import com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsClient; +import com.google.cloud.gsuiteaddons.v1.UpdateChatAppConfigRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateChatAppConfig { + + public static void main(String[] args) throws Exception { + syncUpdateChatAppConfig(); + } + + public static void syncUpdateChatAppConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) { + UpdateChatAppConfigRequest request = + UpdateChatAppConfigRequest.newBuilder() + .setChatAppConfig(ChatAppConfig.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ChatAppConfig response = gSuiteAddOnsClient.updateChatAppConfig(request); + } + } +} +// [END gsuiteaddons_v1_generated_GSuiteAddOns_UpdateChatAppConfig_sync] diff --git a/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/updatechatappconfig/SyncUpdateChatAppConfigChatappconfigFieldmask.java b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/updatechatappconfig/SyncUpdateChatAppConfigChatappconfigFieldmask.java new file mode 100644 index 000000000000..db6054224364 --- /dev/null +++ b/java-gsuite-addons/samples/snippets/generated/com/google/cloud/gsuiteaddons/v1/gsuiteaddons/updatechatappconfig/SyncUpdateChatAppConfigChatappconfigFieldmask.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.gsuiteaddons.v1.samples; + +// [START gsuiteaddons_v1_generated_GSuiteAddOns_UpdateChatAppConfig_ChatappconfigFieldmask_sync] +import com.google.cloud.gsuiteaddons.v1.ChatAppConfig; +import com.google.cloud.gsuiteaddons.v1.GSuiteAddOnsClient; +import com.google.protobuf.FieldMask; + +public class SyncUpdateChatAppConfigChatappconfigFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateChatAppConfigChatappconfigFieldmask(); + } + + public static void syncUpdateChatAppConfigChatappconfigFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (GSuiteAddOnsClient gSuiteAddOnsClient = GSuiteAddOnsClient.create()) { + ChatAppConfig chatAppConfig = ChatAppConfig.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + ChatAppConfig response = gSuiteAddOnsClient.updateChatAppConfig(chatAppConfig, updateMask); + } + } +} +// [END gsuiteaddons_v1_generated_GSuiteAddOns_UpdateChatAppConfig_ChatappconfigFieldmask_sync] diff --git a/java-health/README.md b/java-health/README.md index 8db1f43be2c4..b4e2dff4a353 100644 --- a/java-health/README.md +++ b/java-health/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-health - 0.11.0 + 0.12.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-health' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-health:0.11.0' +implementation 'com.google.cloud:google-cloud-health:0.12.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-health" % "0.11.0" +libraryDependencies += "com.google.cloud" % "google-cloud-health" % "0.12.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-health/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-health.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-health/0.11.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-health/0.12.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceClient.java b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceClient.java index 384313fc3867..b4410dd2d888 100644 --- a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceClient.java +++ b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceClient.java @@ -203,6 +203,7 @@ *
                  *

                  Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

                  *
                    + *
                  • dailyRollUpDataPointsPagedCallable() *

                  • dailyRollUpDataPointsCallable() *

                  * @@ -211,7 +212,9 @@ *

                  ExportExerciseTcx *

                  Exports exercise data in TCX format. *

                  **IMPORTANT:** HTTP clients must append `?alt=media` to the request URL to download the raw TCX file. - *

                  Example: `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + *

                  ## Examples: + *

                  ## `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + *

                  `https://health.googleapis.com/v4/users/1234567890/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` *

                  Without `alt=media`, the server returns a JSON response (`ExportExerciseTcxResponse`) which is intended primarily for gRPC clients. *

                  **Note:** While the Authorization section below states that any one of the listed scopes is accepted, this specific method requires the user to provide both one of the `activity_and_fitness` scopes (`normal` or `readonly`) AND one of the `location` scopes (`normal` or `readonly`) in their access token to succeed. * @@ -384,6 +387,12 @@ public final OperationsClient getHttpJsonOperationsClient() { * * @param name Required. The name of the data point to retrieve. *

                  Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + *

                  ## Examples: + *

                  ## `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + *

                  `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + *

                  The `{user}` can be either the alias `me` or the authenticated user's numeric Health + * User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *

                  See [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] for examples * and possible values. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -414,6 +423,12 @@ public final DataPoint getDataPoint(@Nullable DataPointName name) { * * @param name Required. The name of the data point to retrieve. *

                  Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + *

                  ## Examples: + *

                  ## `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + *

                  `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + *

                  The `{user}` can be either the alias `me` or the authenticated user's numeric Health + * User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *

                  See [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] for examples * and possible values. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -500,8 +515,12 @@ public final UnaryCallable getDataPointCallable( * }

                  * * @param parent Required. Parent data type of the Data Point collection. - *

                  Format: `users/me/dataTypes/{data_type}`, e.g.: - *

                  - `users/me/dataTypes/steps` - `users/me/dataTypes/weight` + *

                  Format: `users/{user}/dataTypes/{data_type}`, e.g.: + *

                  - `users/me/dataTypes/steps` - `users/1234567890/dataTypes/steps` - + * `users/me/dataTypes/weight` - `users/1234567890/dataTypes/weight` + *

                  The `{user}` can be either the alias `me` or the authenticated user's numeric Health + * User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *

                  For a list of the supported data types see the [DataPoint * data][google.devicesandservices.health.v4.DataPoint] union field. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -535,8 +554,12 @@ public final ListDataPointsPagedResponse listDataPoints(@Nullable DataTypeName p * }

                  * * @param parent Required. Parent data type of the Data Point collection. - *

                  Format: `users/me/dataTypes/{data_type}`, e.g.: - *

                  - `users/me/dataTypes/steps` - `users/me/dataTypes/weight` + *

                  Format: `users/{user}/dataTypes/{data_type}`, e.g.: + *

                  - `users/me/dataTypes/steps` - `users/1234567890/dataTypes/steps` - + * `users/me/dataTypes/weight` - `users/1234567890/dataTypes/weight` + *

                  The `{user}` can be either the alias `me` or the authenticated user's numeric Health + * User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *

                  For a list of the supported data types see the [DataPoint * data][google.devicesandservices.health.v4.DataPoint] union field. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -565,6 +588,7 @@ public final ListDataPointsPagedResponse listDataPoints(String parent) { * .setPageSize(883849137) * .setPageToken("pageToken873572522") * .setFilter("filter-1274492040") + * .setDataSourceFamily("dataSourceFamily586548265") * .build(); * for (DataPoint element : dataPointsServiceClient.listDataPoints(request).iterateAll()) { * // doThingsWith(element); @@ -598,6 +622,7 @@ public final ListDataPointsPagedResponse listDataPoints(ListDataPointsRequest re * .setPageSize(883849137) * .setPageToken("pageToken873572522") * .setFilter("filter-1274492040") + * .setDataSourceFamily("dataSourceFamily586548265") * .build(); * ApiFuture future = * dataPointsServiceClient.listDataPointsPagedCallable().futureCall(request); @@ -632,6 +657,7 @@ public final ListDataPointsPagedResponse listDataPoints(ListDataPointsRequest re * .setPageSize(883849137) * .setPageToken("pageToken873572522") * .setFilter("filter-1274492040") + * .setDataSourceFamily("dataSourceFamily586548265") * .build(); * while (true) { * ListDataPointsResponse response = @@ -673,8 +699,12 @@ public final ListDataPointsPagedResponse listDataPoints(ListDataPointsRequest re * } * }

                  * - * @param parent Required. The parent resource name where the data point will be created. Format: - * `users/{user}/dataTypes/{data_type}` + * @param parent Required. The parent resource name where the data point will be created. + *

                  Format: `users/{user}/dataTypes/{data_type}`, e.g.: + *

                  - `users/me/dataTypes/steps` - `users/1234567890/dataTypes/steps` + *

                  The `{user}` can be either the alias `me` or the authenticated user's numeric Health + * User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * @param dataPoint Required. The data point to create. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -707,8 +737,12 @@ public final OperationFuture create * } * }

              * - * @param parent Required. The parent resource name where the data point will be created. Format: - * `users/{user}/dataTypes/{data_type}` + * @param parent Required. The parent resource name where the data point will be created. + *

              Format: `users/{user}/dataTypes/{data_type}`, e.g.: + *

              - `users/me/dataTypes/steps` - `users/1234567890/dataTypes/steps` + *

              The `{user}` can be either the alias `me` or the authenticated user's numeric Health + * User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * @param dataPoint Required. The data point to create. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -831,6 +865,12 @@ public final UnaryCallable createDataPointCal * @param dataPoint Required. The data point to update *

              The data point's `name` field is used to identify the data point to update. *

              Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + *

              ## Examples: + *

              ## `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + *

              `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + *

              The `{user}` can be either the alias `me` or the authenticated user's numeric Health + * User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final OperationFuture updateDataPointAsync( @@ -1270,17 +1310,19 @@ public final RollUpDataPointsPagedResponse rollUpDataPoints(RollUpDataPointsRequ * .setPageToken("pageToken873572522") * .setDataSourceFamily("dataSourceFamily586548265") * .build(); - * DailyRollUpDataPointsResponse response = - * dataPointsServiceClient.dailyRollUpDataPoints(request); + * for (DailyRollupDataPoint element : + * dataPointsServiceClient.dailyRollUpDataPoints(request).iterateAll()) { + * // doThingsWith(element); + * } * } * }

              * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final DailyRollUpDataPointsResponse dailyRollUpDataPoints( + public final DailyRollUpDataPointsPagedResponse dailyRollUpDataPoints( DailyRollUpDataPointsRequest request) { - return dailyRollUpDataPointsCallable().call(request); + return dailyRollUpDataPointsPagedCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. @@ -1305,10 +1347,55 @@ public final DailyRollUpDataPointsResponse dailyRollUpDataPoints( * .setPageToken("pageToken873572522") * .setDataSourceFamily("dataSourceFamily586548265") * .build(); - * ApiFuture future = - * dataPointsServiceClient.dailyRollUpDataPointsCallable().futureCall(request); + * ApiFuture future = + * dataPointsServiceClient.dailyRollUpDataPointsPagedCallable().futureCall(request); * // Do something. - * DailyRollUpDataPointsResponse response = future.get(); + * for (DailyRollupDataPoint element : future.get().iterateAll()) { + * // doThingsWith(element); + * } + * } + * }
              + */ + public final UnaryCallable + dailyRollUpDataPointsPagedCallable() { + return stub.dailyRollUpDataPointsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Roll up data points over civil time intervals for supported data types. + * + *

              Sample code: + * + *

              {@code
              +   * // This snippet has been automatically generated and should be regarded as a code template only.
              +   * // It will require modifications to work:
              +   * // - It may require correct/in-range values for request initialization.
              +   * // - It may require specifying regional endpoints when creating the service client as shown in
              +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
              +   * try (DataPointsServiceClient dataPointsServiceClient = DataPointsServiceClient.create()) {
              +   *   DailyRollUpDataPointsRequest request =
              +   *       DailyRollUpDataPointsRequest.newBuilder()
              +   *           .setParent(DataTypeName.of("[USER]", "[DATA_TYPE]").toString())
              +   *           .setRange(CivilTimeInterval.newBuilder().build())
              +   *           .setWindowSizeDays(1064520774)
              +   *           .setPageSize(883849137)
              +   *           .setPageToken("pageToken873572522")
              +   *           .setDataSourceFamily("dataSourceFamily586548265")
              +   *           .build();
              +   *   while (true) {
              +   *     DailyRollUpDataPointsResponse response =
              +   *         dataPointsServiceClient.dailyRollUpDataPointsCallable().call(request);
              +   *     for (DailyRollupDataPoint element : response.getRollupDataPointsList()) {
              +   *       // doThingsWith(element);
              +   *     }
              +   *     String nextPageToken = response.getNextPageToken();
              +   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
              +   *       request = request.toBuilder().setPageToken(nextPageToken).build();
              +   *     } else {
              +   *       break;
              +   *     }
              +   *   }
                  * }
                  * }
              */ @@ -1324,9 +1411,13 @@ public final DailyRollUpDataPointsResponse dailyRollUpDataPoints( *

              **IMPORTANT:** HTTP clients must append `?alt=media` to the request URL to * download the raw TCX file. * - *

              Example: + *

              ## Examples: + * + *

              ## * `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` * + *

              `https://health.googleapis.com/v4/users/1234567890/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + * *

              Without `alt=media`, the server returns a JSON response (`ExportExerciseTcxResponse`) which * is intended primarily for gRPC clients. * @@ -1350,9 +1441,12 @@ public final DailyRollUpDataPointsResponse dailyRollUpDataPoints( * }

            * * @param name Required. The resource name of the exercise data point to export. - *

            Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` Example: - * `users/me/dataTypes/exercise/dataPoints/2026443605080188808` - *

            The `{user}` is the alias `"me"` currently. Future versions may support user IDs. The + *

            Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` + *

            Examples: - `users/me/dataTypes/exercise/dataPoints/2026443605080188808` - + * `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808` + *

            The `{user}` can be either the alias `me` or the authenticated user's numeric Health + * User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). The * `{data_point}` ID maps to the exercise ID, which is a long integer. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -1371,9 +1465,13 @@ public final ExportExerciseTcxResponse exportExerciseTcx(@Nullable DataPointName *

            **IMPORTANT:** HTTP clients must append `?alt=media` to the request URL to * download the raw TCX file. * - *

            Example: + *

            ## Examples: + * + *

            ## * `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` * + *

            `https://health.googleapis.com/v4/users/1234567890/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + * *

            Without `alt=media`, the server returns a JSON response (`ExportExerciseTcxResponse`) which * is intended primarily for gRPC clients. * @@ -1397,9 +1495,12 @@ public final ExportExerciseTcxResponse exportExerciseTcx(@Nullable DataPointName * }

            * * @param name Required. The resource name of the exercise data point to export. - *

            Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` Example: - * `users/me/dataTypes/exercise/dataPoints/2026443605080188808` - *

            The `{user}` is the alias `"me"` currently. Future versions may support user IDs. The + *

            Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` + *

            Examples: - `users/me/dataTypes/exercise/dataPoints/2026443605080188808` - + * `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808` + *

            The `{user}` can be either the alias `me` or the authenticated user's numeric Health + * User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). The * `{data_point}` ID maps to the exercise ID, which is a long integer. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -1415,9 +1516,13 @@ public final ExportExerciseTcxResponse exportExerciseTcx(String name) { *

            **IMPORTANT:** HTTP clients must append `?alt=media` to the request URL to * download the raw TCX file. * - *

            Example: + *

            ## Examples: + * + *

            ## * `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` * + *

            `https://health.googleapis.com/v4/users/1234567890/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + * *

            Without `alt=media`, the server returns a JSON response (`ExportExerciseTcxResponse`) which * is intended primarily for gRPC clients. * @@ -1458,9 +1563,13 @@ public final ExportExerciseTcxResponse exportExerciseTcx(ExportExerciseTcxReques *

            **IMPORTANT:** HTTP clients must append `?alt=media` to the request URL to * download the raw TCX file. * - *

            Example: + *

            ## Examples: + * + *

            ## * `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` * + *

            `https://health.googleapis.com/v4/users/1234567890/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + * *

            Without `alt=media`, the server returns a JSON response (`ExportExerciseTcxResponse`) which * is intended primarily for gRPC clients. * @@ -1774,4 +1883,95 @@ protected RollUpDataPointsFixedSizeCollection createCollection( return new RollUpDataPointsFixedSizeCollection(pages, collectionSize); } } + + public static class DailyRollUpDataPointsPagedResponse + extends AbstractPagedListResponse< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollupDataPoint, + DailyRollUpDataPointsPage, + DailyRollUpDataPointsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext< + DailyRollUpDataPointsRequest, DailyRollUpDataPointsResponse, DailyRollupDataPoint> + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + DailyRollUpDataPointsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new DailyRollUpDataPointsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private DailyRollUpDataPointsPagedResponse(DailyRollUpDataPointsPage page) { + super(page, DailyRollUpDataPointsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class DailyRollUpDataPointsPage + extends AbstractPage< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollupDataPoint, + DailyRollUpDataPointsPage> { + + private DailyRollUpDataPointsPage( + @Nullable + PageContext< + DailyRollUpDataPointsRequest, DailyRollUpDataPointsResponse, DailyRollupDataPoint> + context, + @Nullable DailyRollUpDataPointsResponse response) { + super(context, response); + } + + private static DailyRollUpDataPointsPage createEmptyPage() { + return new DailyRollUpDataPointsPage(null, null); + } + + @Override + protected DailyRollUpDataPointsPage createPage( + @Nullable + PageContext< + DailyRollUpDataPointsRequest, DailyRollUpDataPointsResponse, DailyRollupDataPoint> + context, + @Nullable DailyRollUpDataPointsResponse response) { + return new DailyRollUpDataPointsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable + PageContext< + DailyRollUpDataPointsRequest, DailyRollUpDataPointsResponse, DailyRollupDataPoint> + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class DailyRollUpDataPointsFixedSizeCollection + extends AbstractFixedSizeCollection< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollupDataPoint, + DailyRollUpDataPointsPage, + DailyRollUpDataPointsFixedSizeCollection> { + + private DailyRollUpDataPointsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static DailyRollUpDataPointsFixedSizeCollection createEmptyCollection() { + return new DailyRollUpDataPointsFixedSizeCollection(null, 0); + } + + @Override + protected DailyRollUpDataPointsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new DailyRollUpDataPointsFixedSizeCollection(pages, collectionSize); + } + } } diff --git a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceSettings.java b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceSettings.java index 389ffe2332b7..23798036b1e3 100644 --- a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceSettings.java +++ b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceSettings.java @@ -16,6 +16,7 @@ package com.google.devicesandservices.health.v4; +import static com.google.devicesandservices.health.v4.DataPointsServiceClient.DailyRollUpDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ListDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ReconcileDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.RollUpDataPointsPagedResponse; @@ -186,7 +187,10 @@ public UnaryCallSettings updateDataPointSetti } /** Returns the object with the settings used for calls to dailyRollUpDataPoints. */ - public UnaryCallSettings + public PagedCallSettings< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollUpDataPointsPagedResponse> dailyRollUpDataPointsSettings() { return ((DataPointsServiceStubSettings) getStubSettings()).dailyRollUpDataPointsSettings(); } @@ -377,7 +381,10 @@ public UnaryCallSettings.Builder updateDataPo } /** Returns the builder for the settings used for calls to dailyRollUpDataPoints. */ - public UnaryCallSettings.Builder + public PagedCallSettings.Builder< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollUpDataPointsPagedResponse> dailyRollUpDataPointsSettings() { return getStubSettingsBuilder().dailyRollUpDataPointsSettings(); } diff --git a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/gapic_metadata.json b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/gapic_metadata.json index a74b30e8959a..22a042b66b80 100644 --- a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/gapic_metadata.json +++ b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/gapic_metadata.json @@ -17,7 +17,7 @@ "methods": ["createDataPointAsync", "createDataPointAsync", "createDataPointAsync", "createDataPointOperationCallable", "createDataPointCallable"] }, "DailyRollUpDataPoints": { - "methods": ["dailyRollUpDataPoints", "dailyRollUpDataPointsCallable"] + "methods": ["dailyRollUpDataPoints", "dailyRollUpDataPointsPagedCallable", "dailyRollUpDataPointsCallable"] }, "ExportExerciseTcx": { "methods": ["exportExerciseTcx", "exportExerciseTcx", "exportExerciseTcx", "exportExerciseTcxCallable"] diff --git a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/DataPointsServiceStub.java b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/DataPointsServiceStub.java index 7266e8a6573b..93203769a3ea 100644 --- a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/DataPointsServiceStub.java +++ b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/DataPointsServiceStub.java @@ -16,6 +16,7 @@ package com.google.devicesandservices.health.v4.stub; +import static com.google.devicesandservices.health.v4.DataPointsServiceClient.DailyRollUpDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ListDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ReconcileDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.RollUpDataPointsPagedResponse; @@ -131,6 +132,12 @@ public UnaryCallable batchDeleteDataPoi throw new UnsupportedOperationException("Not implemented: rollUpDataPointsCallable()"); } + public UnaryCallable + dailyRollUpDataPointsPagedCallable() { + throw new UnsupportedOperationException( + "Not implemented: dailyRollUpDataPointsPagedCallable()"); + } + public UnaryCallable dailyRollUpDataPointsCallable() { throw new UnsupportedOperationException("Not implemented: dailyRollUpDataPointsCallable()"); diff --git a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/DataPointsServiceStubSettings.java b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/DataPointsServiceStubSettings.java index a5127768155b..3cd0fb8bed42 100644 --- a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/DataPointsServiceStubSettings.java +++ b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/DataPointsServiceStubSettings.java @@ -16,6 +16,7 @@ package com.google.devicesandservices.health.v4.stub; +import static com.google.devicesandservices.health.v4.DataPointsServiceClient.DailyRollUpDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ListDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ReconcileDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.RollUpDataPointsPagedResponse; @@ -62,6 +63,7 @@ import com.google.devicesandservices.health.v4.CreateDataPointRequest; import com.google.devicesandservices.health.v4.DailyRollUpDataPointsRequest; import com.google.devicesandservices.health.v4.DailyRollUpDataPointsResponse; +import com.google.devicesandservices.health.v4.DailyRollupDataPoint; import com.google.devicesandservices.health.v4.DataPoint; import com.google.devicesandservices.health.v4.ExportExerciseTcxRequest; import com.google.devicesandservices.health.v4.ExportExerciseTcxResponse; @@ -170,10 +172,12 @@ public class DataPointsServiceStubSettings extends StubSettingsbuilder() .add("https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly") .add("https://www.googleapis.com/auth/googlehealth.activity_and_fitness.writeonly") + .add("https://www.googleapis.com/auth/googlehealth.ecg.readonly") .add( "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.readonly") .add( "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.writeonly") + .add("https://www.googleapis.com/auth/googlehealth.irn.readonly") .add("https://www.googleapis.com/auth/googlehealth.location.readonly") .add("https://www.googleapis.com/auth/googlehealth.logged_symptoms.readonly") .add("https://www.googleapis.com/auth/googlehealth.logged_symptoms.writeonly") @@ -211,7 +215,10 @@ public class DataPointsServiceStubSettings extends StubSettings rollUpDataPointsSettings; - private final UnaryCallSettings + private final PagedCallSettings< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollUpDataPointsPagedResponse> dailyRollUpDataPointsSettings; private final UnaryCallSettings exportExerciseTcxSettings; @@ -328,6 +335,45 @@ public Iterable extractResources(RollUpDataPointsResponse paylo } }; + private static final PagedListDescriptor< + DailyRollUpDataPointsRequest, DailyRollUpDataPointsResponse, DailyRollupDataPoint> + DAILY_ROLL_UP_DATA_POINTS_PAGE_STR_DESC = + new PagedListDescriptor< + DailyRollUpDataPointsRequest, DailyRollUpDataPointsResponse, DailyRollupDataPoint>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public DailyRollUpDataPointsRequest injectToken( + DailyRollUpDataPointsRequest payload, String token) { + return DailyRollUpDataPointsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public DailyRollUpDataPointsRequest injectPageSize( + DailyRollUpDataPointsRequest payload, int pageSize) { + return DailyRollUpDataPointsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(DailyRollUpDataPointsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(DailyRollUpDataPointsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources( + DailyRollUpDataPointsResponse payload) { + return payload.getRollupDataPointsList(); + } + }; + private static final PagedListResponseFactory< ListDataPointsRequest, ListDataPointsResponse, ListDataPointsPagedResponse> LIST_DATA_POINTS_PAGE_STR_FACT = @@ -386,6 +432,32 @@ public ApiFuture getFuturePagedResponse( } }; + private static final PagedListResponseFactory< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollUpDataPointsPagedResponse> + DAILY_ROLL_UP_DATA_POINTS_PAGE_STR_FACT = + new PagedListResponseFactory< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollUpDataPointsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + DailyRollUpDataPointsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollupDataPoint> + pageContext = + PageContext.create( + callable, DAILY_ROLL_UP_DATA_POINTS_PAGE_STR_DESC, request, context); + return DailyRollUpDataPointsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + /** Returns the object with the settings used for calls to getDataPoint. */ public UnaryCallSettings getDataPointSettings() { return getDataPointSettings; @@ -450,7 +522,10 @@ public UnaryCallSettings updateDataPointSetti } /** Returns the object with the settings used for calls to dailyRollUpDataPoints. */ - public UnaryCallSettings + public PagedCallSettings< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollUpDataPointsPagedResponse> dailyRollUpDataPointsSettings() { return dailyRollUpDataPointsSettings; } @@ -628,8 +703,10 @@ public static class Builder extends StubSettings.Builder rollUpDataPointsSettings; - private final UnaryCallSettings.Builder< - DailyRollUpDataPointsRequest, DailyRollUpDataPointsResponse> + private final PagedCallSettings.Builder< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollUpDataPointsPagedResponse> dailyRollUpDataPointsSettings; private final UnaryCallSettings.Builder exportExerciseTcxSettings; @@ -692,7 +769,8 @@ protected Builder(@Nullable ClientContext clientContext) { reconcileDataPointsSettings = PagedCallSettings.newBuilder(RECONCILE_DATA_POINTS_PAGE_STR_FACT); rollUpDataPointsSettings = PagedCallSettings.newBuilder(ROLL_UP_DATA_POINTS_PAGE_STR_FACT); - dailyRollUpDataPointsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + dailyRollUpDataPointsSettings = + PagedCallSettings.newBuilder(DAILY_ROLL_UP_DATA_POINTS_PAGE_STR_FACT); exportExerciseTcxSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); unaryMethodSettingsBuilders = @@ -971,7 +1049,10 @@ public UnaryCallSettings.Builder updateDataPo } /** Returns the builder for the settings used for calls to dailyRollUpDataPoints. */ - public UnaryCallSettings.Builder + public PagedCallSettings.Builder< + DailyRollUpDataPointsRequest, + DailyRollUpDataPointsResponse, + DailyRollUpDataPointsPagedResponse> dailyRollUpDataPointsSettings() { return dailyRollUpDataPointsSettings; } diff --git a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/GrpcDataPointsServiceStub.java b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/GrpcDataPointsServiceStub.java index 64ce9137d81a..b93a2f323962 100644 --- a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/GrpcDataPointsServiceStub.java +++ b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/GrpcDataPointsServiceStub.java @@ -16,6 +16,7 @@ package com.google.devicesandservices.health.v4.stub; +import static com.google.devicesandservices.health.v4.DataPointsServiceClient.DailyRollUpDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ListDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ReconcileDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.RollUpDataPointsPagedResponse; @@ -206,6 +207,8 @@ public class GrpcDataPointsServiceStub extends DataPointsServiceStub { rollUpDataPointsPagedCallable; private final UnaryCallable dailyRollUpDataPointsCallable; + private final UnaryCallable + dailyRollUpDataPointsPagedCallable; private final UnaryCallable exportExerciseTcxCallable; @@ -417,6 +420,11 @@ protected GrpcDataPointsServiceStub( dailyRollUpDataPointsTransportSettings, settings.dailyRollUpDataPointsSettings(), clientContext); + this.dailyRollUpDataPointsPagedCallable = + callableFactory.createPagedCallable( + dailyRollUpDataPointsTransportSettings, + settings.dailyRollUpDataPointsSettings(), + clientContext); this.exportExerciseTcxCallable = callableFactory.createUnaryCallable( exportExerciseTcxTransportSettings, @@ -513,6 +521,12 @@ public UnaryCallable batchDeleteDataPoi return dailyRollUpDataPointsCallable; } + @Override + public UnaryCallable + dailyRollUpDataPointsPagedCallable() { + return dailyRollUpDataPointsPagedCallable; + } + @Override public UnaryCallable exportExerciseTcxCallable() { diff --git a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/HealthProfileServiceStubSettings.java b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/HealthProfileServiceStubSettings.java index 46ad1c49ceba..f722c31f4a39 100644 --- a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/HealthProfileServiceStubSettings.java +++ b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/HealthProfileServiceStubSettings.java @@ -130,18 +130,27 @@ public class HealthProfileServiceStubSettings private static final ImmutableList DEFAULT_SERVICE_SCOPES = ImmutableList.builder() .add("https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly") + .add("https://www.googleapis.com/auth/googlehealth.activity_and_fitness.writeonly") .add("https://www.googleapis.com/auth/googlehealth.ecg.readonly") .add( "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.readonly") + .add( + "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.writeonly") .add("https://www.googleapis.com/auth/googlehealth.irn.readonly") + .add("https://www.googleapis.com/auth/googlehealth.location.readonly") .add("https://www.googleapis.com/auth/googlehealth.logged_symptoms.readonly") + .add("https://www.googleapis.com/auth/googlehealth.logged_symptoms.writeonly") .add("https://www.googleapis.com/auth/googlehealth.mindfulness.readonly") + .add("https://www.googleapis.com/auth/googlehealth.mindfulness.writeonly") + .add("https://www.googleapis.com/auth/googlehealth.nutrition.writeonly") .add("https://www.googleapis.com/auth/googlehealth.profile.readonly") .add("https://www.googleapis.com/auth/googlehealth.profile.writeonly") .add("https://www.googleapis.com/auth/googlehealth.reproductive_health.readonly") + .add("https://www.googleapis.com/auth/googlehealth.reproductive_health.writeonly") .add("https://www.googleapis.com/auth/googlehealth.settings.readonly") .add("https://www.googleapis.com/auth/googlehealth.settings.writeonly") .add("https://www.googleapis.com/auth/googlehealth.sleep.readonly") + .add("https://www.googleapis.com/auth/googlehealth.sleep.writeonly") .build(); private final UnaryCallSettings getProfileSettings; diff --git a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/HttpJsonDataPointsServiceStub.java b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/HttpJsonDataPointsServiceStub.java index 289026269a48..340d8617b98d 100644 --- a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/HttpJsonDataPointsServiceStub.java +++ b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4/stub/HttpJsonDataPointsServiceStub.java @@ -16,6 +16,7 @@ package com.google.devicesandservices.health.v4.stub; +import static com.google.devicesandservices.health.v4.DataPointsServiceClient.DailyRollUpDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ListDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ReconcileDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.RollUpDataPointsPagedResponse; @@ -141,6 +142,8 @@ public class HttpJsonDataPointsServiceStub extends DataPointsServiceStub { Map> fields = new HashMap<>(); ProtoRestSerializer serializer = ProtoRestSerializer.create(); + serializer.putQueryParam( + fields, "dataSourceFamily", request.getDataSourceFamily()); serializer.putQueryParam(fields, "filter", request.getFilter()); serializer.putQueryParam(fields, "pageSize", request.getPageSize()); serializer.putQueryParam(fields, "pageToken", request.getPageToken()); @@ -464,6 +467,8 @@ public class HttpJsonDataPointsServiceStub extends DataPointsServiceStub { rollUpDataPointsPagedCallable; private final UnaryCallable dailyRollUpDataPointsCallable; + private final UnaryCallable + dailyRollUpDataPointsPagedCallable; private final UnaryCallable exportExerciseTcxCallable; @@ -686,6 +691,11 @@ protected HttpJsonDataPointsServiceStub( dailyRollUpDataPointsTransportSettings, settings.dailyRollUpDataPointsSettings(), clientContext); + this.dailyRollUpDataPointsPagedCallable = + callableFactory.createPagedCallable( + dailyRollUpDataPointsTransportSettings, + settings.dailyRollUpDataPointsSettings(), + clientContext); this.exportExerciseTcxCallable = callableFactory.createUnaryCallable( exportExerciseTcxTransportSettings, @@ -797,6 +807,12 @@ public UnaryCallable batchDeleteDataPoi return dailyRollUpDataPointsCallable; } + @Override + public UnaryCallable + dailyRollUpDataPointsPagedCallable() { + return dailyRollUpDataPointsPagedCallable; + } + @Override public UnaryCallable exportExerciseTcxCallable() { diff --git a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4beta/stub/HealthProfileServiceStubSettings.java b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4beta/stub/HealthProfileServiceStubSettings.java index 03d7404801ec..5e6929ddc31c 100644 --- a/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4beta/stub/HealthProfileServiceStubSettings.java +++ b/java-health/google-cloud-health/src/main/java/com/google/devicesandservices/health/v4beta/stub/HealthProfileServiceStubSettings.java @@ -131,18 +131,27 @@ public class HealthProfileServiceStubSettings private static final ImmutableList DEFAULT_SERVICE_SCOPES = ImmutableList.builder() .add("https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly") + .add("https://www.googleapis.com/auth/googlehealth.activity_and_fitness.writeonly") .add("https://www.googleapis.com/auth/googlehealth.ecg.readonly") .add( "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.readonly") + .add( + "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.writeonly") .add("https://www.googleapis.com/auth/googlehealth.irn.readonly") + .add("https://www.googleapis.com/auth/googlehealth.location.readonly") .add("https://www.googleapis.com/auth/googlehealth.logged_symptoms.readonly") + .add("https://www.googleapis.com/auth/googlehealth.logged_symptoms.writeonly") .add("https://www.googleapis.com/auth/googlehealth.mindfulness.readonly") + .add("https://www.googleapis.com/auth/googlehealth.mindfulness.writeonly") + .add("https://www.googleapis.com/auth/googlehealth.nutrition.writeonly") .add("https://www.googleapis.com/auth/googlehealth.profile.readonly") .add("https://www.googleapis.com/auth/googlehealth.profile.writeonly") .add("https://www.googleapis.com/auth/googlehealth.reproductive_health.readonly") + .add("https://www.googleapis.com/auth/googlehealth.reproductive_health.writeonly") .add("https://www.googleapis.com/auth/googlehealth.settings.readonly") .add("https://www.googleapis.com/auth/googlehealth.settings.writeonly") .add("https://www.googleapis.com/auth/googlehealth.sleep.readonly") + .add("https://www.googleapis.com/auth/googlehealth.sleep.writeonly") .build(); private final UnaryCallSettings getProfileSettings; diff --git a/java-health/google-cloud-health/src/main/resources/META-INF/native-image/com.google.devicesandservices.health.v4/reflect-config.json b/java-health/google-cloud-health/src/main/resources/META-INF/native-image/com.google.devicesandservices.health.v4/reflect-config.json index 25d8b4bfbb44..b983590c46af 100644 --- a/java-health/google-cloud-health/src/main/resources/META-INF/native-image/com.google.devicesandservices.health.v4/reflect-config.json +++ b/java-health/google-cloud-health/src/main/resources/META-INF/native-image/com.google.devicesandservices.health.v4/reflect-config.json @@ -2780,6 +2780,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.devicesandservices.health.v4.OvulationTest$TestType", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.devicesandservices.health.v4.OvulationTestResult", "queryAllDeclaredConstructors": true, diff --git a/java-health/google-cloud-health/src/main/resources/META-INF/native-image/com.google.devicesandservices.health.v4beta/reflect-config.json b/java-health/google-cloud-health/src/main/resources/META-INF/native-image/com.google.devicesandservices.health.v4beta/reflect-config.json index 71498f6fd023..888c265dd21b 100644 --- a/java-health/google-cloud-health/src/main/resources/META-INF/native-image/com.google.devicesandservices.health.v4beta/reflect-config.json +++ b/java-health/google-cloud-health/src/main/resources/META-INF/native-image/com.google.devicesandservices.health.v4beta/reflect-config.json @@ -2780,6 +2780,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.devicesandservices.health.v4beta.OvulationTest$TestType", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.devicesandservices.health.v4beta.OvulationTestResult", "queryAllDeclaredConstructors": true, diff --git a/java-health/google-cloud-health/src/test/java/com/google/devicesandservices/health/v4/DataPointsServiceClientHttpJsonTest.java b/java-health/google-cloud-health/src/test/java/com/google/devicesandservices/health/v4/DataPointsServiceClientHttpJsonTest.java index ec88eae5a849..0e737cf60015 100644 --- a/java-health/google-cloud-health/src/test/java/com/google/devicesandservices/health/v4/DataPointsServiceClientHttpJsonTest.java +++ b/java-health/google-cloud-health/src/test/java/com/google/devicesandservices/health/v4/DataPointsServiceClientHttpJsonTest.java @@ -16,6 +16,7 @@ package com.google.devicesandservices.health.v4; +import static com.google.devicesandservices.health.v4.DataPointsServiceClient.DailyRollUpDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ListDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ReconcileDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.RollUpDataPointsPagedResponse; @@ -624,9 +625,11 @@ public void rollUpDataPointsExceptionTest() throws Exception { @Test public void dailyRollUpDataPointsTest() throws Exception { + DailyRollupDataPoint responsesElement = DailyRollupDataPoint.newBuilder().build(); DailyRollUpDataPointsResponse expectedResponse = DailyRollUpDataPointsResponse.newBuilder() - .addAllRollupDataPoints(new ArrayList()) + .setNextPageToken("") + .addAllRollupDataPoints(Arrays.asList(responsesElement)) .build(); mockService.addResponse(expectedResponse); @@ -640,8 +643,12 @@ public void dailyRollUpDataPointsTest() throws Exception { .setDataSourceFamily("dataSourceFamily586548265") .build(); - DailyRollUpDataPointsResponse actualResponse = client.dailyRollUpDataPoints(request); - Assert.assertEquals(expectedResponse, actualResponse); + DailyRollUpDataPointsPagedResponse pagedListResponse = client.dailyRollUpDataPoints(request); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getRollupDataPointsList().get(0), resources.get(0)); List actualRequests = mockService.getRequestPaths(); Assert.assertEquals(1, actualRequests.size()); diff --git a/java-health/google-cloud-health/src/test/java/com/google/devicesandservices/health/v4/DataPointsServiceClientTest.java b/java-health/google-cloud-health/src/test/java/com/google/devicesandservices/health/v4/DataPointsServiceClientTest.java index 27752ec040c3..642f8b2c83ef 100644 --- a/java-health/google-cloud-health/src/test/java/com/google/devicesandservices/health/v4/DataPointsServiceClientTest.java +++ b/java-health/google-cloud-health/src/test/java/com/google/devicesandservices/health/v4/DataPointsServiceClientTest.java @@ -16,6 +16,7 @@ package com.google.devicesandservices.health.v4; +import static com.google.devicesandservices.health.v4.DataPointsServiceClient.DailyRollUpDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ListDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.ReconcileDataPointsPagedResponse; import static com.google.devicesandservices.health.v4.DataPointsServiceClient.RollUpDataPointsPagedResponse; @@ -585,9 +586,11 @@ public void rollUpDataPointsExceptionTest() throws Exception { @Test public void dailyRollUpDataPointsTest() throws Exception { + DailyRollupDataPoint responsesElement = DailyRollupDataPoint.newBuilder().build(); DailyRollUpDataPointsResponse expectedResponse = DailyRollUpDataPointsResponse.newBuilder() - .addAllRollupDataPoints(new ArrayList()) + .setNextPageToken("") + .addAllRollupDataPoints(Arrays.asList(responsesElement)) .build(); mockDataPointsService.addResponse(expectedResponse); @@ -601,8 +604,12 @@ public void dailyRollUpDataPointsTest() throws Exception { .setDataSourceFamily("dataSourceFamily586548265") .build(); - DailyRollUpDataPointsResponse actualResponse = client.dailyRollUpDataPoints(request); - Assert.assertEquals(expectedResponse, actualResponse); + DailyRollUpDataPointsPagedResponse pagedListResponse = client.dailyRollUpDataPoints(request); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getRollupDataPointsList().get(0), resources.get(0)); List actualRequests = mockDataPointsService.getRequests(); Assert.assertEquals(1, actualRequests.size()); diff --git a/java-health/grpc-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceGrpc.java b/java-health/grpc-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceGrpc.java index 6e33d13018b2..181870d29d8a 100644 --- a/java-health/grpc-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceGrpc.java +++ b/java-health/grpc-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointsServiceGrpc.java @@ -656,8 +656,10 @@ default void dailyRollUpDataPoints( * Exports exercise data in TCX format. * **IMPORTANT:** HTTP clients must append `?alt=media` to the * request URL to download the raw TCX file. - * Example: + * ## Examples: + * ## * `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + * `https://health.googleapis.com/v4/users/1234567890/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` * Without `alt=media`, the server returns a JSON response * (`ExportExerciseTcxResponse`) * which is intended primarily for gRPC clients. @@ -859,8 +861,10 @@ public void dailyRollUpDataPoints( * Exports exercise data in TCX format. * **IMPORTANT:** HTTP clients must append `?alt=media` to the * request URL to download the raw TCX file. - * Example: + * ## Examples: + * ## * `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + * `https://health.googleapis.com/v4/users/1234567890/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` * Without `alt=media`, the server returns a JSON response * (`ExportExerciseTcxResponse`) * which is intended primarily for gRPC clients. @@ -1025,8 +1029,10 @@ public com.google.devicesandservices.health.v4.RollUpDataPointsResponse rollUpDa * Exports exercise data in TCX format. * **IMPORTANT:** HTTP clients must append `?alt=media` to the * request URL to download the raw TCX file. - * Example: + * ## Examples: + * ## * `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + * `https://health.googleapis.com/v4/users/1234567890/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` * Without `alt=media`, the server returns a JSON response * (`ExportExerciseTcxResponse`) * which is intended primarily for gRPC clients. @@ -1179,8 +1185,10 @@ public com.google.devicesandservices.health.v4.RollUpDataPointsResponse rollUpDa * Exports exercise data in TCX format. * **IMPORTANT:** HTTP clients must append `?alt=media` to the * request URL to download the raw TCX file. - * Example: + * ## Examples: + * ## * `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + * `https://health.googleapis.com/v4/users/1234567890/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` * Without `alt=media`, the server returns a JSON response * (`ExportExerciseTcxResponse`) * which is intended primarily for gRPC clients. @@ -1338,8 +1346,10 @@ protected DataPointsServiceFutureStub build( * Exports exercise data in TCX format. * **IMPORTANT:** HTTP clients must append `?alt=media` to the * request URL to download the raw TCX file. - * Example: + * ## Examples: + * ## * `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + * `https://health.googleapis.com/v4/users/1234567890/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` * Without `alt=media`, the server returns a JSON response * (`ExportExerciseTcxResponse`) * which is intended primarily for gRPC clients. diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/BatchDeleteDataPointsRequest.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/BatchDeleteDataPointsRequest.java index 88063d8fb194..535a698e7878 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/BatchDeleteDataPointsRequest.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/BatchDeleteDataPointsRequest.java @@ -81,10 +81,17 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * *

                * Optional. Parent (data type) for the Data Point collection
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   *
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/-`
            +   * - `users/1234567890/dataTypes/-`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the
                * [DataPoint
            @@ -122,10 +129,17 @@ public java.lang.String getParent() {
                *
                * 
                * Optional. Parent (data type) for the Data Point collection
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   *
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/-`
            +   * - `users/1234567890/dataTypes/-`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the
                * [DataPoint
            @@ -602,10 +616,17 @@ public Builder mergeFrom(
                  *
                  * 
                  * Optional. Parent (data type) for the Data Point collection
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     *
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/-`
            +     * - `users/1234567890/dataTypes/-`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the
                  * [DataPoint
            @@ -642,10 +663,17 @@ public java.lang.String getParent() {
                  *
                  * 
                  * Optional. Parent (data type) for the Data Point collection
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     *
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/-`
            +     * - `users/1234567890/dataTypes/-`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the
                  * [DataPoint
            @@ -682,10 +710,17 @@ public com.google.protobuf.ByteString getParentBytes() {
                  *
                  * 
                  * Optional. Parent (data type) for the Data Point collection
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     *
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/-`
            +     * - `users/1234567890/dataTypes/-`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the
                  * [DataPoint
            @@ -721,10 +756,17 @@ public Builder setParent(java.lang.String value) {
                  *
                  * 
                  * Optional. Parent (data type) for the Data Point collection
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     *
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/-`
            +     * - `users/1234567890/dataTypes/-`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the
                  * [DataPoint
            @@ -756,10 +798,17 @@ public Builder clearParent() {
                  *
                  * 
                  * Optional. Parent (data type) for the Data Point collection
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     *
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/-`
            +     * - `users/1234567890/dataTypes/-`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the
                  * [DataPoint
            diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/BatchDeleteDataPointsRequestOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/BatchDeleteDataPointsRequestOrBuilder.java
            index 7328177bcedb..b6909b20fba2 100644
            --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/BatchDeleteDataPointsRequestOrBuilder.java
            +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/BatchDeleteDataPointsRequestOrBuilder.java
            @@ -31,10 +31,17 @@ public interface BatchDeleteDataPointsRequestOrBuilder
                *
                * 
                * Optional. Parent (data type) for the Data Point collection
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   *
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/-`
            +   * - `users/1234567890/dataTypes/-`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the
                * [DataPoint
            @@ -61,10 +68,17 @@ public interface BatchDeleteDataPointsRequestOrBuilder
                *
                * 
                * Optional. Parent (data type) for the Data Point collection
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   *
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/-`
            +   * - `users/1234567890/dataTypes/-`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the
                * [DataPoint
            diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/CreateDataPointRequest.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/CreateDataPointRequest.java
            index 527d274b225c..328a033d20ae 100644
            --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/CreateDataPointRequest.java
            +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/CreateDataPointRequest.java
            @@ -81,7 +81,15 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
                *
                * 
                * Required. The parent resource name where the data point will be created.
            -   * Format: `users/{user}/dataTypes/{data_type}`
            +   *
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +   *
            +   * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                * 
            * * @@ -108,7 +116,15 @@ public java.lang.String getParent() { * *
                * Required. The parent resource name where the data point will be created.
            -   * Format: `users/{user}/dataTypes/{data_type}`
            +   *
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +   *
            +   * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                * 
            * * @@ -554,7 +570,15 @@ public Builder mergeFrom( * *
                  * Required. The parent resource name where the data point will be created.
            -     * Format: `users/{user}/dataTypes/{data_type}`
            +     *
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +     *
            +     * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  * 
            * * @@ -580,7 +604,15 @@ public java.lang.String getParent() { * *
                  * Required. The parent resource name where the data point will be created.
            -     * Format: `users/{user}/dataTypes/{data_type}`
            +     *
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +     *
            +     * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  * 
            * * @@ -606,7 +638,15 @@ public com.google.protobuf.ByteString getParentBytes() { * *
                  * Required. The parent resource name where the data point will be created.
            -     * Format: `users/{user}/dataTypes/{data_type}`
            +     *
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +     *
            +     * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  * 
            * * @@ -631,7 +671,15 @@ public Builder setParent(java.lang.String value) { * *
                  * Required. The parent resource name where the data point will be created.
            -     * Format: `users/{user}/dataTypes/{data_type}`
            +     *
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +     *
            +     * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  * 
            * * @@ -652,7 +700,15 @@ public Builder clearParent() { * *
                  * Required. The parent resource name where the data point will be created.
            -     * Format: `users/{user}/dataTypes/{data_type}`
            +     *
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +     *
            +     * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  * 
            * * diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/CreateDataPointRequestOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/CreateDataPointRequestOrBuilder.java index 479151a4f957..45ccad509b44 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/CreateDataPointRequestOrBuilder.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/CreateDataPointRequestOrBuilder.java @@ -31,7 +31,15 @@ public interface CreateDataPointRequestOrBuilder * *
                * Required. The parent resource name where the data point will be created.
            -   * Format: `users/{user}/dataTypes/{data_type}`
            +   *
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +   *
            +   * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                * 
            * * @@ -47,7 +55,15 @@ public interface CreateDataPointRequestOrBuilder * *
                * Required. The parent resource name where the data point will be created.
            -   * Format: `users/{user}/dataTypes/{data_type}`
            +   *
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +   *
            +   * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                * 
            * * diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsRequest.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsRequest.java index c961e8d51f1a..f68453f04fa2 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsRequest.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsRequest.java @@ -87,7 +87,13 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * Format: `users/{user}/dataTypes/{data_type}`, e.g.: * * - `users/me/dataTypes/steps` + * - `users/1234567890/dataTypes/steps` * - `users/me/dataTypes/distance` + * - `users/1234567890/dataTypes/distance` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * * For a list of the supported data types see the [DailyRollupDataPoint * value][google.devicesandservices.health.v4.DailyRollupDataPoint] @@ -122,7 +128,13 @@ public java.lang.String getParent() { * Format: `users/{user}/dataTypes/{data_type}`, e.g.: * * - `users/me/dataTypes/steps` + * - `users/1234567890/dataTypes/steps` * - `users/me/dataTypes/distance` + * - `users/1234567890/dataTypes/distance` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * * For a list of the supported data types see the [DailyRollupDataPoint * value][google.devicesandservices.health.v4.DailyRollupDataPoint] @@ -251,9 +263,10 @@ public int getWindowSizeDays() { * *
                * Optional. The maximum number of data points to return.
            -   * If unspecified, at most 1440 data points will be returned.
            -   * The maximum page size is 10000; values above that will be truncated
            -   * accordingly.
            +   * If unspecified, at most `90` data points will be returned.
            +   * The maximum page size is `90`.
            +   * For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and
            +   * `total-calories`, the default and maximum page size is `14`.
                * 
            * * int32 page_size = 4 [(.google.api.field_behavior) = OPTIONAL]; @@ -274,7 +287,7 @@ public int getPageSize() { * * *
            -   * Optional. The `next_page_token` from a previous request, if any.
            +   * Optional. The next_page_token from a previous request, if any.
                * All other request fields need to be the same as in the initial request
                * when the page token is specified.
                * 
            @@ -300,7 +313,7 @@ public java.lang.String getPageToken() { * * *
            -   * Optional. The `next_page_token` from a previous request, if any.
            +   * Optional. The next_page_token from a previous request, if any.
                * All other request fields need to be the same as in the initial request
                * when the page token is specified.
                * 
            @@ -334,20 +347,26 @@ public com.google.protobuf.ByteString getPageTokenBytes() { * Optional. The data source family name to roll up. * If empty, data points from all available data sources will be rolled up. * - * Format: `users/me/dataSourceFamilies/{data_source_family}` + * Format: `users/{user}/dataSourceFamilies/{data_source_family}` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (e.g. `users/me/dataSourceFamilies/...` or + * `users/1234567890/dataSourceFamilies/...`). * * The supported values are: * - * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - * from all available data sources. - * - `users/me/dataSourceFamilies/google-wearables` - Includes data from + * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + * data from all available data sources. + * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel * Watch). Excludes manually logged data. - * - `users/me/dataSourceFamilies/google-sources` - Includes first-party + * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party * Google data, such as data from tracker devices, manually logged data, and * Health Connect. - * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - * calling client wrote through this API, that is, data points whose data + * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + * the calling client wrote through this API, that is, data points whose data * source was registered through this API with the same OAuth client ID as * the caller. * @@ -384,20 +403,26 @@ public java.lang.String getDataSourceFamily() { * Optional. The data source family name to roll up. * If empty, data points from all available data sources will be rolled up. * - * Format: `users/me/dataSourceFamilies/{data_source_family}` + * Format: `users/{user}/dataSourceFamilies/{data_source_family}` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (e.g. `users/me/dataSourceFamilies/...` or + * `users/1234567890/dataSourceFamilies/...`). * * The supported values are: * - * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - * from all available data sources. - * - `users/me/dataSourceFamilies/google-wearables` - Includes data from + * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + * data from all available data sources. + * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel * Watch). Excludes manually logged data. - * - `users/me/dataSourceFamilies/google-sources` - Includes first-party + * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party * Google data, such as data from tracker devices, manually logged data, and * Health Connect. - * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - * calling client wrote through this API, that is, data points whose data + * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + * the calling client wrote through this API, that is, data points whose data * source was registered through this API with the same OAuth client ID as * the caller. * @@ -892,7 +917,13 @@ public Builder mergeFrom( * Format: `users/{user}/dataTypes/{data_type}`, e.g.: * * - `users/me/dataTypes/steps` + * - `users/1234567890/dataTypes/steps` * - `users/me/dataTypes/distance` + * - `users/1234567890/dataTypes/distance` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * * For a list of the supported data types see the [DailyRollupDataPoint * value][google.devicesandservices.health.v4.DailyRollupDataPoint] @@ -926,7 +957,13 @@ public java.lang.String getParent() { * Format: `users/{user}/dataTypes/{data_type}`, e.g.: * * - `users/me/dataTypes/steps` + * - `users/1234567890/dataTypes/steps` * - `users/me/dataTypes/distance` + * - `users/1234567890/dataTypes/distance` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * * For a list of the supported data types see the [DailyRollupDataPoint * value][google.devicesandservices.health.v4.DailyRollupDataPoint] @@ -960,7 +997,13 @@ public com.google.protobuf.ByteString getParentBytes() { * Format: `users/{user}/dataTypes/{data_type}`, e.g.: * * - `users/me/dataTypes/steps` + * - `users/1234567890/dataTypes/steps` * - `users/me/dataTypes/distance` + * - `users/1234567890/dataTypes/distance` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * * For a list of the supported data types see the [DailyRollupDataPoint * value][google.devicesandservices.health.v4.DailyRollupDataPoint] @@ -993,7 +1036,13 @@ public Builder setParent(java.lang.String value) { * Format: `users/{user}/dataTypes/{data_type}`, e.g.: * * - `users/me/dataTypes/steps` + * - `users/1234567890/dataTypes/steps` * - `users/me/dataTypes/distance` + * - `users/1234567890/dataTypes/distance` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * * For a list of the supported data types see the [DailyRollupDataPoint * value][google.devicesandservices.health.v4.DailyRollupDataPoint] @@ -1022,7 +1071,13 @@ public Builder clearParent() { * Format: `users/{user}/dataTypes/{data_type}`, e.g.: * * - `users/me/dataTypes/steps` + * - `users/1234567890/dataTypes/steps` * - `users/me/dataTypes/distance` + * - `users/1234567890/dataTypes/distance` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * * For a list of the supported data types see the [DailyRollupDataPoint * value][google.devicesandservices.health.v4.DailyRollupDataPoint] @@ -1375,9 +1430,10 @@ public Builder clearWindowSizeDays() { * *
                  * Optional. The maximum number of data points to return.
            -     * If unspecified, at most 1440 data points will be returned.
            -     * The maximum page size is 10000; values above that will be truncated
            -     * accordingly.
            +     * If unspecified, at most `90` data points will be returned.
            +     * The maximum page size is `90`.
            +     * For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and
            +     * `total-calories`, the default and maximum page size is `14`.
                  * 
            * * int32 page_size = 4 [(.google.api.field_behavior) = OPTIONAL]; @@ -1394,9 +1450,10 @@ public int getPageSize() { * *
                  * Optional. The maximum number of data points to return.
            -     * If unspecified, at most 1440 data points will be returned.
            -     * The maximum page size is 10000; values above that will be truncated
            -     * accordingly.
            +     * If unspecified, at most `90` data points will be returned.
            +     * The maximum page size is `90`.
            +     * For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and
            +     * `total-calories`, the default and maximum page size is `14`.
                  * 
            * * int32 page_size = 4 [(.google.api.field_behavior) = OPTIONAL]; @@ -1417,9 +1474,10 @@ public Builder setPageSize(int value) { * *
                  * Optional. The maximum number of data points to return.
            -     * If unspecified, at most 1440 data points will be returned.
            -     * The maximum page size is 10000; values above that will be truncated
            -     * accordingly.
            +     * If unspecified, at most `90` data points will be returned.
            +     * The maximum page size is `90`.
            +     * For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and
            +     * `total-calories`, the default and maximum page size is `14`.
                  * 
            * * int32 page_size = 4 [(.google.api.field_behavior) = OPTIONAL]; @@ -1439,7 +1497,7 @@ public Builder clearPageSize() { * * *
            -     * Optional. The `next_page_token` from a previous request, if any.
            +     * Optional. The next_page_token from a previous request, if any.
                  * All other request fields need to be the same as in the initial request
                  * when the page token is specified.
                  * 
            @@ -1464,7 +1522,7 @@ public java.lang.String getPageToken() { * * *
            -     * Optional. The `next_page_token` from a previous request, if any.
            +     * Optional. The next_page_token from a previous request, if any.
                  * All other request fields need to be the same as in the initial request
                  * when the page token is specified.
                  * 
            @@ -1489,7 +1547,7 @@ public com.google.protobuf.ByteString getPageTokenBytes() { * * *
            -     * Optional. The `next_page_token` from a previous request, if any.
            +     * Optional. The next_page_token from a previous request, if any.
                  * All other request fields need to be the same as in the initial request
                  * when the page token is specified.
                  * 
            @@ -1513,7 +1571,7 @@ public Builder setPageToken(java.lang.String value) { * * *
            -     * Optional. The `next_page_token` from a previous request, if any.
            +     * Optional. The next_page_token from a previous request, if any.
                  * All other request fields need to be the same as in the initial request
                  * when the page token is specified.
                  * 
            @@ -1533,7 +1591,7 @@ public Builder clearPageToken() { * * *
            -     * Optional. The `next_page_token` from a previous request, if any.
            +     * Optional. The next_page_token from a previous request, if any.
                  * All other request fields need to be the same as in the initial request
                  * when the page token is specified.
                  * 
            @@ -1563,20 +1621,26 @@ public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { * Optional. The data source family name to roll up. * If empty, data points from all available data sources will be rolled up. * - * Format: `users/me/dataSourceFamilies/{data_source_family}` + * Format: `users/{user}/dataSourceFamilies/{data_source_family}` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (e.g. `users/me/dataSourceFamilies/...` or + * `users/1234567890/dataSourceFamilies/...`). * * The supported values are: * - * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - * from all available data sources. - * - `users/me/dataSourceFamilies/google-wearables` - Includes data from + * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + * data from all available data sources. + * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel * Watch). Excludes manually logged data. - * - `users/me/dataSourceFamilies/google-sources` - Includes first-party + * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party * Google data, such as data from tracker devices, manually logged data, and * Health Connect. - * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - * calling client wrote through this API, that is, data points whose data + * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + * the calling client wrote through this API, that is, data points whose data * source was registered through this API with the same OAuth client ID as * the caller. * @@ -1612,20 +1676,26 @@ public java.lang.String getDataSourceFamily() { * Optional. The data source family name to roll up. * If empty, data points from all available data sources will be rolled up. * - * Format: `users/me/dataSourceFamilies/{data_source_family}` + * Format: `users/{user}/dataSourceFamilies/{data_source_family}` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (e.g. `users/me/dataSourceFamilies/...` or + * `users/1234567890/dataSourceFamilies/...`). * * The supported values are: * - * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - * from all available data sources. - * - `users/me/dataSourceFamilies/google-wearables` - Includes data from + * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + * data from all available data sources. + * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel * Watch). Excludes manually logged data. - * - `users/me/dataSourceFamilies/google-sources` - Includes first-party + * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party * Google data, such as data from tracker devices, manually logged data, and * Health Connect. - * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - * calling client wrote through this API, that is, data points whose data + * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + * the calling client wrote through this API, that is, data points whose data * source was registered through this API with the same OAuth client ID as * the caller. * @@ -1661,20 +1731,26 @@ public com.google.protobuf.ByteString getDataSourceFamilyBytes() { * Optional. The data source family name to roll up. * If empty, data points from all available data sources will be rolled up. * - * Format: `users/me/dataSourceFamilies/{data_source_family}` + * Format: `users/{user}/dataSourceFamilies/{data_source_family}` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (e.g. `users/me/dataSourceFamilies/...` or + * `users/1234567890/dataSourceFamilies/...`). * * The supported values are: * - * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - * from all available data sources. - * - `users/me/dataSourceFamilies/google-wearables` - Includes data from + * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + * data from all available data sources. + * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel * Watch). Excludes manually logged data. - * - `users/me/dataSourceFamilies/google-sources` - Includes first-party + * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party * Google data, such as data from tracker devices, manually logged data, and * Health Connect. - * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - * calling client wrote through this API, that is, data points whose data + * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + * the calling client wrote through this API, that is, data points whose data * source was registered through this API with the same OAuth client ID as * the caller. * @@ -1709,20 +1785,26 @@ public Builder setDataSourceFamily(java.lang.String value) { * Optional. The data source family name to roll up. * If empty, data points from all available data sources will be rolled up. * - * Format: `users/me/dataSourceFamilies/{data_source_family}` + * Format: `users/{user}/dataSourceFamilies/{data_source_family}` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (e.g. `users/me/dataSourceFamilies/...` or + * `users/1234567890/dataSourceFamilies/...`). * * The supported values are: * - * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - * from all available data sources. - * - `users/me/dataSourceFamilies/google-wearables` - Includes data from + * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + * data from all available data sources. + * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel * Watch). Excludes manually logged data. - * - `users/me/dataSourceFamilies/google-sources` - Includes first-party + * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party * Google data, such as data from tracker devices, manually logged data, and * Health Connect. - * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - * calling client wrote through this API, that is, data points whose data + * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + * the calling client wrote through this API, that is, data points whose data * source was registered through this API with the same OAuth client ID as * the caller. * @@ -1753,20 +1835,26 @@ public Builder clearDataSourceFamily() { * Optional. The data source family name to roll up. * If empty, data points from all available data sources will be rolled up. * - * Format: `users/me/dataSourceFamilies/{data_source_family}` + * Format: `users/{user}/dataSourceFamilies/{data_source_family}` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (e.g. `users/me/dataSourceFamilies/...` or + * `users/1234567890/dataSourceFamilies/...`). * * The supported values are: * - * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - * from all available data sources. - * - `users/me/dataSourceFamilies/google-wearables` - Includes data from + * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + * data from all available data sources. + * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel * Watch). Excludes manually logged data. - * - `users/me/dataSourceFamilies/google-sources` - Includes first-party + * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party * Google data, such as data from tracker devices, manually logged data, and * Health Connect. - * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - * calling client wrote through this API, that is, data points whose data + * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + * the calling client wrote through this API, that is, data points whose data * source was registered through this API with the same OAuth client ID as * the caller. * diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsRequestOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsRequestOrBuilder.java index eb5034108b4c..fd7a8ff8143d 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsRequestOrBuilder.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsRequestOrBuilder.java @@ -35,7 +35,13 @@ public interface DailyRollUpDataPointsRequestOrBuilder * Format: `users/{user}/dataTypes/{data_type}`, e.g.: * * - `users/me/dataTypes/steps` + * - `users/1234567890/dataTypes/steps` * - `users/me/dataTypes/distance` + * - `users/1234567890/dataTypes/distance` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * * For a list of the supported data types see the [DailyRollupDataPoint * value][google.devicesandservices.health.v4.DailyRollupDataPoint] @@ -59,7 +65,13 @@ public interface DailyRollUpDataPointsRequestOrBuilder * Format: `users/{user}/dataTypes/{data_type}`, e.g.: * * - `users/me/dataTypes/steps` + * - `users/1234567890/dataTypes/steps` * - `users/me/dataTypes/distance` + * - `users/1234567890/dataTypes/distance` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * * For a list of the supported data types see the [DailyRollupDataPoint * value][google.devicesandservices.health.v4.DailyRollupDataPoint] @@ -152,9 +164,10 @@ public interface DailyRollUpDataPointsRequestOrBuilder * *
                * Optional. The maximum number of data points to return.
            -   * If unspecified, at most 1440 data points will be returned.
            -   * The maximum page size is 10000; values above that will be truncated
            -   * accordingly.
            +   * If unspecified, at most `90` data points will be returned.
            +   * The maximum page size is `90`.
            +   * For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and
            +   * `total-calories`, the default and maximum page size is `14`.
                * 
            * * int32 page_size = 4 [(.google.api.field_behavior) = OPTIONAL]; @@ -167,7 +180,7 @@ public interface DailyRollUpDataPointsRequestOrBuilder * * *
            -   * Optional. The `next_page_token` from a previous request, if any.
            +   * Optional. The next_page_token from a previous request, if any.
                * All other request fields need to be the same as in the initial request
                * when the page token is specified.
                * 
            @@ -182,7 +195,7 @@ public interface DailyRollUpDataPointsRequestOrBuilder * * *
            -   * Optional. The `next_page_token` from a previous request, if any.
            +   * Optional. The next_page_token from a previous request, if any.
                * All other request fields need to be the same as in the initial request
                * when the page token is specified.
                * 
            @@ -200,20 +213,26 @@ public interface DailyRollUpDataPointsRequestOrBuilder * Optional. The data source family name to roll up. * If empty, data points from all available data sources will be rolled up. * - * Format: `users/me/dataSourceFamilies/{data_source_family}` + * Format: `users/{user}/dataSourceFamilies/{data_source_family}` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (e.g. `users/me/dataSourceFamilies/...` or + * `users/1234567890/dataSourceFamilies/...`). * * The supported values are: * - * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - * from all available data sources. - * - `users/me/dataSourceFamilies/google-wearables` - Includes data from + * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + * data from all available data sources. + * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel * Watch). Excludes manually logged data. - * - `users/me/dataSourceFamilies/google-sources` - Includes first-party + * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party * Google data, such as data from tracker devices, manually logged data, and * Health Connect. - * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - * calling client wrote through this API, that is, data points whose data + * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + * the calling client wrote through this API, that is, data points whose data * source was registered through this API with the same OAuth client ID as * the caller. * @@ -239,20 +258,26 @@ public interface DailyRollUpDataPointsRequestOrBuilder * Optional. The data source family name to roll up. * If empty, data points from all available data sources will be rolled up. * - * Format: `users/me/dataSourceFamilies/{data_source_family}` + * Format: `users/{user}/dataSourceFamilies/{data_source_family}` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (e.g. `users/me/dataSourceFamilies/...` or + * `users/1234567890/dataSourceFamilies/...`). * * The supported values are: * - * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - * from all available data sources. - * - `users/me/dataSourceFamilies/google-wearables` - Includes data from + * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + * data from all available data sources. + * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel * Watch). Excludes manually logged data. - * - `users/me/dataSourceFamilies/google-sources` - Includes first-party + * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party * Google data, such as data from tracker devices, manually logged data, and * Health Connect. - * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - * calling client wrote through this API, that is, data points whose data + * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + * the calling client wrote through this API, that is, data points whose data * source was registered through this API with the same OAuth client ID as * the caller. * diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsResponse.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsResponse.java index b9c3d5142dbc..5b94ff181c29 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsResponse.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsResponse.java @@ -53,6 +53,7 @@ private DailyRollUpDataPointsResponse(com.google.protobuf.GeneratedMessage.Build private DailyRollUpDataPointsResponse() { rollupDataPoints_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -161,6 +162,61 @@ public com.google.devicesandservices.health.v4.DailyRollupDataPoint getRollupDat return rollupDataPoints_.get(index); } + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
            +   * A token, which can be sent as `page_token` to retrieve the next page.
            +   * If this field is omitted, there are no subsequent pages.
            +   * 
            + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
            +   * A token, which can be sent as `page_token` to retrieve the next page.
            +   * If this field is omitted, there are no subsequent pages.
            +   * 
            + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -178,6 +234,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < rollupDataPoints_.size(); i++) { output.writeMessage(1, rollupDataPoints_.get(i)); } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } getUnknownFields().writeTo(output); } @@ -190,6 +249,9 @@ public int getSerializedSize() { for (int i = 0; i < rollupDataPoints_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, rollupDataPoints_.get(i)); } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -207,6 +269,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.devicesandservices.health.v4.DailyRollUpDataPointsResponse) obj; if (!getRollupDataPointsList().equals(other.getRollupDataPointsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -222,6 +285,8 @@ public int hashCode() { hash = (37 * hash) + ROLLUP_DATA_POINTS_FIELD_NUMBER; hash = (53 * hash) + getRollupDataPointsList().hashCode(); } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -372,6 +437,7 @@ public Builder clear() { rollupDataPointsBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; return this; } @@ -425,6 +491,9 @@ private void buildPartialRepeatedFields( private void buildPartial0( com.google.devicesandservices.health.v4.DailyRollUpDataPointsResponse result) { int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } } @java.lang.Override @@ -470,6 +539,11 @@ public Builder mergeFrom( } } } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -510,6 +584,12 @@ public Builder mergeFrom( } break; } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -953,6 +1033,122 @@ public Builder removeRollupDataPoints(int index) { return rollupDataPointsBuilder_; } + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
            +     * A token, which can be sent as `page_token` to retrieve the next page.
            +     * If this field is omitted, there are no subsequent pages.
            +     * 
            + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * A token, which can be sent as `page_token` to retrieve the next page.
            +     * If this field is omitted, there are no subsequent pages.
            +     * 
            + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * A token, which can be sent as `page_token` to retrieve the next page.
            +     * If this field is omitted, there are no subsequent pages.
            +     * 
            + * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
            +     * A token, which can be sent as `page_token` to retrieve the next page.
            +     * If this field is omitted, there are no subsequent pages.
            +     * 
            + * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
            +     * A token, which can be sent as `page_token` to retrieve the next page.
            +     * If this field is omitted, there are no subsequent pages.
            +     * 
            + * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.devicesandservices.health.v4.DailyRollUpDataPointsResponse) } diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsResponseOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsResponseOrBuilder.java index 8099e52182c3..f37927e656fd 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsResponseOrBuilder.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DailyRollUpDataPointsResponseOrBuilder.java @@ -93,4 +93,32 @@ public interface DailyRollUpDataPointsResponseOrBuilder */ com.google.devicesandservices.health.v4.DailyRollupDataPointOrBuilder getRollupDataPointsOrBuilder(int index); + + /** + * + * + *
            +   * A token, which can be sent as `page_token` to retrieve the next page.
            +   * If this field is omitted, there are no subsequent pages.
            +   * 
            + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
            +   * A token, which can be sent as `page_token` to retrieve the next page.
            +   * If this field is omitted, there are no subsequent pages.
            +   * 
            + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); } diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataModelProto.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataModelProto.java index 5bf72ab72c21..005c3a0f1c97 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataModelProto.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataModelProto.java @@ -1485,18 +1485,25 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017MenstrualPeriod\022T\n" + "\010interval\030\002 " + "\001(\0132<.google.devicesandservices.health.v4.ObservationTimeIntervalB\004\342A\001\002\022\023\n" - + "\005notes\030\004 \001(\tB\004\342A\001\001\"\266\001\n\r" + + "\005notes\030\004 \001(\tB\004\342A\001\001\"\333\002\n\r" + "OvulationTest\022U\n" + "\013sample_time\030\002" + " \001(\0132:.google.devicesandservices.health.v4.ObservationSampleTimeB\004\342A\001\002\022N\n" + "\006result\030\003" - + " \001(\01628.google.devicesandservices.health.v4.OvulationTestResultB\004\342A\001\002\"\251\n" - + "\n" + + " \001(\01628.google.devicesandservices.health.v4.OvulationTestResultB\004\342A\001\002\022T\n" + + "\ttest_type\030\004 \001(\0162;.google.devicesandserv" + + "ices.health.v4.OvulationTest.TestTypeB\004\342A\001\001\"M\n" + + "\010TestType\022\031\n" + + "\025TEST_TYPE_UNSPECIFIED\020\000\022\t\n" + + "\005STRIP\020\001\022\013\n" + + "\007DIGITAL\020\002\022\016\n\n" + + "OWN_METHOD\020\003\"\346\n\n" + "\010Symptoms\022U\n" - + "\013sample_time\030\001 \001(\0132:.google" - + ".devicesandservices.health.v4.ObservationSampleTimeB\004\342A\001\002\022R\n" - + "\010symptoms\030\002 \003(\0162:.go" - + "ogle.devicesandservices.health.v4.Symptoms.SymptomValueB\004\342A\001\002\"\361\010\n" + + "\013sample_time\030\001 \001(\0132:.g" + + "oogle.devicesandservices.health.v4.ObservationSampleTimeB\004\342A\001\002\022R\n" + + "\010symptoms\030\002 \003(\016" + + "2:.google.devicesandservices.health.v4.Symptoms.SymptomValueB\004\342A\001\002\"\256" + + "\t\n" + "\014SymptomValue\022\035\n" + "\031SYMPTOM_VALUE_UNSPECIFIED\020\000\022\n\n" + "\006CRAMPS\020\001\022\014\n" @@ -1558,22 +1565,25 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006NAUSEA\0207\022\020\n" + "\014NIGHT_SWEATS\0208\022\024\n" + "\020NORMAL_DIGESTION\0209\022\020\n" - + "\014NORMAL_STOOL\020:\022\021\n" - + "\r" + + "\014NORMAL_STOOL\020:\022\021\n\r" + "PERINEUM_PAIN\020;\022\016\n\n" - + "SLEEPINESS\020<\022\021\n\r" + + "SLEEPINESS\020<\022\021\n" + + "\r" + "STRETCH_MARKS\020=\022\014\n" + "\010SWELLING\020>\022\023\n" + "\017VAGINAL_DRYNESS\020?\022\023\n" + "\017VAGINAL_ITCHING\020@\022\014\n" - + "\010VOMITING\020A\"\223\n\n" + + "\010VOMITING\020A\022\022\n" + + "\016LIMBS_SWELLING\020L\022\021\n\r" + + "FACE_SWELLING\020M\022\024\n" + + "\020NASAL_CONGESTION\020N\"\223\n\n" + "\005Moods\022U\n" - + "\013sample_time\030\002 \001(\0132:.googl" - + "e.devicesandservices.health.v4.ObservationSampleTimeB\004\342A\001\002\022D\n" - + "\005moods\030\003 \003(\0162/.goog" - + "le.devicesandservices.health.v4.Moods.MoodB\004\342A\001\002\022J\n" - + "\010valences\030\005 \003(\01622.google.devi" - + "cesandservices.health.v4.Moods.ValenceB\004\342A\001\001\"\320\007\n" + + "\013sample_time\030\002 \001(\0132:.google.devicesandse" + + "rvices.health.v4.ObservationSampleTimeB\004\342A\001\002\022D\n" + + "\005moods\030\003 \003(\0162/.google.devicesands", + "ervices.health.v4.Moods.MoodB\004\342A\001\002\022J\n" + + "\010valences\030\005" + + " \003(\01622.google.devicesandservices.health.v4.Moods.ValenceB\004\342A\001\001\"\320\007\n" + "\004Mood\022\024\n" + "\020MOOD_UNSPECIFIED\020\000\022\n\n" + "\006AMAZED\020\001\022\n\n" @@ -1582,8 +1592,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\007ANNOYED\020\004\022\013\n" + "\007ANXIOUS\020\005\022\t\n" + "\005HAPPY\020\006\022\013\n" - + "\007CONTENT\020\007", - "\022\007\n" + + "\007CONTENT\020\007\022\007\n" + "\003SAD\020\010\022\013\n" + "\007WORRIED\020\t\022\016\n\n" + "FRUSTRATED\020\n" @@ -1606,7 +1615,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010HOPELESS\020\031\022\017\n" + "\013INDIFFERENT\020\032\022\r\n" + "\tIRRITATED\020\033\022\013\n" - + "\007JEALOUS\020\034\022\n\n" + + "\007JEALOUS\020\034\022\n" + + "\n" + "\006JOYFUL\020\035\022\n\n" + "\006LONELY\020\036\022\017\n" + "\013OVERWHELMED\020\037\022\016\n\n" @@ -1692,7 +1702,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006COPPER\020\010\022\021\n\r" + "DIETARY_FIBER\020\t\022\016\n\n" + "FOLIC_ACID\020\n" - + "\022\n\n" + + "\022\n" + + "\n" + "\006IODINE\020\013\022\010\n" + "\004IRON\020\014\022\r\n" + "\tMAGNESIUM\020\r" @@ -1742,19 +1753,20 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005LITER\020\005\022\016\n\n" + "MILLILITER\020\006\022\021\n\r" + "PINT_IMPERIAL\020\007\022\013\n" - + "\007PINT_US\020\010*\236\001\n" + + "\007PINT_US\020\010*\256\001\n" + "\023OvulationTestResult\022%\n" + "!OVULATION_TEST_RESULT_UNSPECIFIED\020\000\022\014\n" + "\010NEGATIVE\020\001\022\035\n" + "\031LUTEINIZING_HORMONE_SURGE\020\002\022\022\n" + "\016ESTROGEN_SURGE\020\003\022\014\n" + "\010POSITIVE\020\004\022\021\n\r" - + "INDETERMINATE\020\005B\200\002\n" - + "\'com.google.devicesandservices.health.v4B\016DataModelP" - + "rotoP\001ZNgoogle.golang.org/genproto/googleapis/devicesandservices/health/apiv4;he" - + "althpb\252\002#Google.DevicesAndServices.Healt" - + "h.V4\312\002#Google\\DevicesAndServices\\Health\\" - + "V4\352\002&Google::DevicesAndServices::Health::V4b\006proto3" + + "INDETERMINATE\020\005\022\016\n\n" + + "OWN_METHOD\020\006B\200\002\n" + + "\'com.google.devicesandservices.health.v4B\016DataMode" + + "lProtoP\001ZNgoogle.golang.org/genproto/googleapis/devicesandservices/health/apiv4;" + + "healthpb\252\002#Google.DevicesAndServices.Hea" + + "lth.V4\312\002#Google\\DevicesAndServices\\Healt" + + "h\\V4\352\002&Google::DevicesAndServices::Health::V4b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -2666,7 +2678,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_devicesandservices_health_v4_OvulationTest_descriptor, new java.lang.String[] { - "SampleTime", "Result", + "SampleTime", "Result", "TestType", }); internal_static_google_devicesandservices_health_v4_Symptoms_descriptor = getDescriptor().getMessageType(68); diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPoint.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPoint.java index ceff6de37ba4..bfa29a4f1da7 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPoint.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPoint.java @@ -2898,11 +2898,18 @@ public com.google.devicesandservices.health.v4.MoodsOrBuilder getMoodsOrBuilder( * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * - * Example: - * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * ## Examples: * - * The `{user}` ID is a system-generated identifier, as described in - * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]. + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, which can be retrieved by calling + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (see + * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]). * * The `{data_type}` ID corresponds to the kebab-case version of the field * names in the [DataPoint @@ -2941,11 +2948,18 @@ public java.lang.String getName() { * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * - * Example: - * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` * - * The `{user}` ID is a system-generated identifier, as described in - * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]. + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, which can be retrieved by calling + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (see + * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]). * * The `{data_type}` ID corresponds to the kebab-case version of the field * names in the [DataPoint @@ -15176,11 +15190,18 @@ public com.google.devicesandservices.health.v4.MoodsOrBuilder getMoodsOrBuilder( * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * - * Example: - * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * ## Examples: * - * The `{user}` ID is a system-generated identifier, as described in - * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]. + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, which can be retrieved by calling + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (see + * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]). * * The `{data_type}` ID corresponds to the kebab-case version of the field * names in the [DataPoint @@ -15218,11 +15239,18 @@ public java.lang.String getName() { * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * - * Example: - * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` * - * The `{user}` ID is a system-generated identifier, as described in - * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]. + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, which can be retrieved by calling + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (see + * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]). * * The `{data_type}` ID corresponds to the kebab-case version of the field * names in the [DataPoint @@ -15260,11 +15288,18 @@ public com.google.protobuf.ByteString getNameBytes() { * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * - * Example: - * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` * - * The `{user}` ID is a system-generated identifier, as described in - * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]. + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, which can be retrieved by calling + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (see + * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]). * * The `{data_type}` ID corresponds to the kebab-case version of the field * names in the [DataPoint @@ -15301,11 +15336,18 @@ public Builder setName(java.lang.String value) { * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * - * Example: - * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` * - * The `{user}` ID is a system-generated identifier, as described in - * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]. + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, which can be retrieved by calling + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (see + * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]). * * The `{data_type}` ID corresponds to the kebab-case version of the field * names in the [DataPoint @@ -15338,11 +15380,18 @@ public Builder clearName() { * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * - * Example: - * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` * - * The `{user}` ID is a system-generated identifier, as described in - * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]. + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, which can be retrieved by calling + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (see + * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]). * * The `{data_type}` ID corresponds to the kebab-case version of the field * names in the [DataPoint diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointOrBuilder.java index b43748ee19af..8bae68842924 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointOrBuilder.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointOrBuilder.java @@ -1954,11 +1954,18 @@ public interface DataPointOrBuilder * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * - * Example: - * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * ## Examples: * - * The `{user}` ID is a system-generated identifier, as described in - * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]. + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, which can be retrieved by calling + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (see + * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]). * * The `{data_type}` ID corresponds to the kebab-case version of the field * names in the [DataPoint @@ -1986,11 +1993,18 @@ public interface DataPointOrBuilder * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * - * Example: - * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` * - * The `{user}` ID is a system-generated identifier, as described in - * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]. + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID, which can be retrieved by calling + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + * (see + * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]). * * The `{data_type}` ID corresponds to the kebab-case version of the field * names in the [DataPoint diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointsProto.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointsProto.java index 1dd3012b560e..06506cd19e92 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointsProto.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataPointsProto.java @@ -417,13 +417,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005value\"M\n" + "\023GetDataPointRequest\0226\n" + "\004name\030\001 \001(\tB(\342A\001\002\372A!\n" - + "\037health.googleapis.com/DataPoint\"\231\001\n" + + "\037health.googleapis.com/DataPoint\"\273\001\n" + "\025ListDataPointsRequest\0227\n" + "\006parent\030\001 \001(\tB\'\342A\001\002\372A \n" + "\036health.googleapis.com/DataType\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" - + "\006filter\030\004 \001(\tB\004\342A\001\001\"v\n" + + "\006filter\030\004 \001(\tB\004\342A\001\001\022 \n" + + "\022data_source_family\030\005 \001(\tB\004\342A\001\001\"v\n" + "\026ListDataPointsResponse\022C\n" + "\013data_points\030\001" + " \003(\0132..google.devicesandservices.health.v4.DataPoint\022\027\n" @@ -431,12 +432,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\026CreateDataPointRequest\0228\n" + "\006parent\030\001 \001(" + "\tB(\342A\001\002\372A!\022\037health.googleapis.com/DataPoint\022H\n\n" - + "data_point\030\002 \001(\0132..google" - + ".devicesandservices.health.v4.DataPointB\004\342A\001\002\"\"\n" + + "data_point\030\002 \001(\0132..google.devic" + + "esandservices.health.v4.DataPointB\004\342A\001\002\"\"\n" + " CreateDataPointOperationMetadata\"b\n" + "\026UpdateDataPointRequest\022H\n\n" - + "data_point\030\001" - + " \001(\0132..google.devicesandservices.health.v4.DataPointB\004\342A\001\002\"\"\n" + + "data_point\030\001 \001(" + + "\0132..google.devicesandservices.health.v4.DataPointB\004\342A\001\002\"\"\n" + " UpdateDataPointOperationMetadata\"\220\001\n" + "\034BatchDeleteDataPointsRequest\0227\n" + "\006parent\030\001 \001(\tB\'\342A\001\001\372A \n" @@ -447,8 +448,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013data_points\030\001" + " \003(\0132..google.devicesandservices.health.v4.DataPoint\"\355\001\n" + "&BatchDeleteDataPointsOperationMetadata\022x\n" - + "\017failed_requests\030\001 \003(\0132_.google.devicesandservic" - + "es.health.v4.BatchDeleteDataPointsOperationMetadata.FailedRequestsEntry\032I\n" + + "\017failed_requests\030\001 \003(\0132_.google.devicesandservices.hea" + + "lth.v4.BatchDeleteDataPointsOperationMetadata.FailedRequestsEntry\032I\n" + "\023FailedRequestsEntry\022\013\n" + "\003key\030\001 \001(\005\022!\n" + "\005value\030\002 \001(\0132\022.google.rpc.Status:\0028\001\"\235\001\n" @@ -459,8 +460,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006filter\030\004 \001(\tB\004\342A\001\001\022 \n" + "\022data_source_family\030\005 \001(\tB\004\342A\001\001\"\205\001\n" + "\033ReconcileDataPointsResponse\022M\n" - + "\013data_points\030\001 \003(\0132" - + "8.google.devicesandservices.health.v4.ReconciledDataPoint\022\027\n" + + "\013data_points\030\001 \003(\01328.goog" + + "le.devicesandservices.health.v4.ReconciledDataPoint\022\027\n" + "\017next_page_token\030\002 \001(\t\"\211\002\n" + "\027RollUpDataPointsRequest\0227\n" + "\006parent\030\001 \001(\tB\'\342A\001\002\372A \n" @@ -472,21 +473,22 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "page_token\030\005 \001(\tB\004\342A\001\001\022 \n" + "\022data_source_family\030\007 \001(\tB\004\342A\001\001\"\205\001\n" + "\030RollUpDataPointsResponse\022P\n" - + "\022rollup_data_points\030\001" - + " \003(\01324.google.devicesandservices.health.v4.RollupDataPoint\022\027\n" + + "\022rollup_data_points\030\001 \003(" + + "\01324.google.devicesandservices.health.v4.RollupDataPoint\022\027\n" + "\017next_page_token\030\002 \001(\t\"\231\002\n" + "\034DailyRollUpDataPointsRequest\0227\n" + "\006parent\030\001 \001(\tB\'\342A\001\002\372A \n" + "\036health.googleapis.com/DataType\022K\n" - + "\005range\030\002 \001(\01326.google" - + ".devicesandservices.health.v4.CivilTimeIntervalB\004\342A\001\002\022\036\n" + + "\005range\030\002 \001(\01326.google.devic" + + "esandservices.health.v4.CivilTimeIntervalB\004\342A\001\002\022\036\n" + "\020window_size_days\030\003 \001(\005B\004\342A\001\001\022\027\n" + "\tpage_size\030\004 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\005 \001(\tB\004\342A\001\001\022 \n" - + "\022data_source_family\030\007 \001(\tB\004\342A\001\001\"v\n" + + "\022data_source_family\030\007 \001(\tB\004\342A\001\001\"\217\001\n" + "\035DailyRollUpDataPointsResponse\022U\n" - + "\022rollup_data_points\030\001 \003(\01329.google" - + ".devicesandservices.health.v4.DailyRollupDataPoint\"|\n" + + "\022rollup_data_points\030\001 \003(\01329.google.devi" + + "cesandservices.health.v4.DailyRollupDataPoint\022\027\n" + + "\017next_page_token\030\002 \001(\t\"|\n" + "\010DataType\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010:\\\352AY\n" + "\036health.googleapis.com/DataType\022\"users/{user}/dataTypes/{data_type}*" @@ -496,79 +498,83 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\037health.googleapis.com/DataPoint\022\032\n" + "\014partial_data\030\002 \001(\010B\004\342A\001\001\"-\n" + "\031ExportExerciseTcxResponse\022\020\n" - + "\010tcx_data\030\002 \001(\t2\204\030\n" + + "\010tcx_data\030\002 \001(\t2\370\030\n" + "\021DataPointsService\022\264\001\n" - + "\014GetDataPoint\0228.google.devicesandservic" - + "es.health.v4.GetDataPointRequest\032..google.devicesandservices.health.v4.DataPoint" - + "\":\332A\004name\202\323\344\223\002-\022+/v4/{name=users/*/dataTypes/*/dataPoints/*}\022\307\001\n" - + "\016ListDataPoints\022:.google.devicesandservices.health.v4.Li" - + "stDataPointsRequest\032;.google.devicesandservices.health.v4.ListDataPointsResponse" - + "\"<\332A\006parent\202\323\344\223\002-\022+/v4/{parent=users/*/dataTypes/*}/dataPoints\022\363\001\n" - + "\017CreateDataPoint\022;.google.devicesandservices.health.v4" - + ".CreateDataPointRequest\032\035.google.longrunning.Operation\"\203\001\312A-\n" - + "\tDataPoint\022 CreateDataPointOperationMetadata\332A\021parent,data_" - + "point\202\323\344\223\0029\"+/v4/{parent=users/*/dataTypes/*}/dataPoints:\n" + + "\014GetDataPoint\0228.google.devicesandservices.health.v4.GetData" + + "PointRequest\032..google.devicesandservices" + + ".health.v4.DataPoint\":\332A\004name\202\323\344\223\002-\022+/v4" + + "/{name=users/*/dataTypes/*/dataPoints/*}\022\307\001\n" + + "\016ListDataPoints\022:.google.devicesandservices.health.v4.ListDataPointsRequest\032" + + ";.google.devicesandservices.health.v4.Li" + + "stDataPointsResponse\"<\332A\006parent\202\323\344\223\002-\022+/" + + "v4/{parent=users/*/dataTypes/*}/dataPoints\022\363\001\n" + + "\017CreateDataPoint\022;.google.devicesandservices.health.v4.CreateDataPointRequ" + + "est\032\035.google.longrunning.Operation\"\203\001\312A-\n" + + "\tDataPoint\022 CreateDataPointOperationMet" + + "adata\332A\021parent,data_point\202\323\344\223\0029\"+/v4/{parent=users/*/dataTypes/*}/dataPoints:\n" + "data_point\022\367\001\n" - + "\017UpdateDataPoint\022;.google.devicesandservices.hea" - + "lth.v4.UpdateDataPointRequest\032\035.google.longrunning.Operation\"\207\001\312A-\n" + + "\017UpdateDataPoint\022;.google.devicesandservices.health.v4.UpdateDataPoi" + + "ntRequest\032\035.google.longrunning.Operation\"\207\001\312A-\n" + "\tDataPoint\022 UpdateDataPointOperationMetadata\332A\n" - + "data_p" - + "oint\202\323\344\223\002D26/v4/{data_point.name=users/*/dataTypes/*/dataPoints/*}:\n" + + "data_point\202\323\344\223\002D26/v4/{dat" + + "a_point.name=users/*/dataTypes/*/dataPoints/*}:\n" + "data_point\022\210\002\n" - + "\025BatchDeleteDataPoints\022A.google.devicesandservices.health.v4.BatchDeleteDataPo" - + "intsRequest\032\035.google.longrunning.Operation\"\214\001\312AG\n" - + "\035BatchDeleteDataPointsResponse\022&BatchDeleteDataPointsOperationMetadata\202" - + "\323\344\223\002<\"7/v4/{parent=users/*/dataTypes/*}/dataPoints:batchDelete:\001*\022\327\001\n" - + "\023ReconcileDataPoints\022?.google.devicesandservices.he" - + "alth.v4.ReconcileDataPointsRequest\032@.google.devicesandservices.health.v4.Reconci" - + "leDataPointsResponse\"=\202\323\344\223\0027\0225/v4/{paren" - + "t=users/*/dataTypes/*}/dataPoints:reconcile\022\316\001\n" - + "\020RollUpDataPoints\022<.google.devicesandservices.health.v4.RollUpDataPointsR" - + "equest\032=.google.devicesandservices.healt" - + "h.v4.RollUpDataPointsResponse\"=\202\323\344\223\0027\"2/" - + "v4/{parent=users/*/dataTypes/*}/dataPoints:rollUp:\001*\022\342\001\n" - + "\025DailyRollUpDataPoints\022A.google.devicesandservices.health.v4.Dai" - + "lyRollUpDataPointsRequest\032B.google.devicesandservices.health.v4.DailyRollUpDataP" - + "ointsResponse\"B\202\323\344\223\002<\"7/v4/{parent=users" - + "/*/dataTypes/*}/dataPoints:dailyRollUp:\001*\022\340\001\n" - + "\021ExportExerciseTcx\022=.google.devicesandservices.health.v4.ExportExerciseTcxR" - + "equest\032>.google.devicesandservices.healt" - + "h.v4.ExportExerciseTcxResponse\"L\332A\004name\202", - "\323\344\223\002?\022=/v4/{name=users/*/dataTypes/*/dat" - + "aPoints/*}:exportExerciseTcx\032\377\007\312A\025health" - + ".googleapis.com\322A\343\007https://www.googleapi" - + "s.com/auth/googlehealth.activity_and_fit" - + "ness.readonly,https://www.googleapis.com" - + "/auth/googlehealth.activity_and_fitness." - + "writeonly,https://www.googleapis.com/aut" - + "h/googlehealth.health_metrics_and_measur" - + "ements.readonly,https://www.googleapis.c" - + "om/auth/googlehealth.health_metrics_and_" - + "measurements.writeonly,https://www.googl" - + "eapis.com/auth/googlehealth.location.rea" - + "donly,https://www.googleapis.com/auth/go" - + "oglehealth.logged_symptoms.readonly,http" - + "s://www.googleapis.com/auth/googlehealth" - + ".logged_symptoms.writeonly,https://www.g" - + "oogleapis.com/auth/googlehealth.mindfuln" - + "ess.readonly,https://www.googleapis.com/" - + "auth/googlehealth.mindfulness.writeonly," - + "https://www.googleapis.com/auth/googlehe" - + "alth.nutrition.writeonly,https://www.goo" - + "gleapis.com/auth/googlehealth.reproducti" - + "ve_health.readonly,https://www.googleapi" - + "s.com/auth/googlehealth.reproductive_hea" - + "lth.writeonly,https://www.googleapis.com" - + "/auth/googlehealth.sleep.readonly,https:" - + "//www.googleapis.com/auth/googlehealth.s" - + "leep.writeonlyB\201\002\n\'com.google.devicesand" - + "services.health.v4B\017DataPointsProtoP\001ZNg" - + "oogle.golang.org/genproto/googleapis/dev" - + "icesandservices/health/apiv4;healthpb\252\002#" - + "Google.DevicesAndServices.Health.V4\312\002#Go" - + "ogle\\DevicesAndServices\\Health\\V4\352\002&Goog" - + "le::DevicesAndServices::Health::V4b\006prot" - + "o3" + + "\025BatchDeleteDataPoints\022A.google.devicesandservices.health." + + "v4.BatchDeleteDataPointsRequest\032\035.google.longrunning.Operation\"\214\001\312AG\n" + + "\035BatchDeleteDataPointsResponse\022&BatchDeleteDataPoin" + + "tsOperationMetadata\202\323\344\223\002<\"7/v4/{parent=u" + + "sers/*/dataTypes/*}/dataPoints:batchDelete:\001*\022\327\001\n" + + "\023ReconcileDataPoints\022?.google.devicesandservices.health.v4.ReconcileDat" + + "aPointsRequest\032@.google.devicesandservices.health.v4.ReconcileDataPointsResponse" + + "\"=\202\323\344\223\0027\0225/v4/{parent=users/*/dataTypes/*}/dataPoints:reconcile\022\316\001\n" + + "\020RollUpDataPoints\022<.google.devicesandservices.health." + + "v4.RollUpDataPointsRequest\032=.google.devicesandservices.health.v4.RollUpDataPoint" + + "sResponse\"=\202\323\344\223\0027\"2/v4/{parent=users/*/dataTypes/*}/dataPoints:rollUp:\001*\022\342\001\n" + + "\025DailyRollUpDataPoints\022A.google.devicesandse" + + "rvices.health.v4.DailyRollUpDataPointsRequest\032B.google.devicesandservices.health" + + ".v4.DailyRollUpDataPointsResponse\"B\202\323\344\223\002" + + "<\"7/v4/{parent=users/*/dataTypes/*}/dataPoints:dailyRollUp:\001*\022\340\001\n" + + "\021ExportExerciseTcx\022=.google.devicesandservices.health.v" + + "4.ExportExerciseTcxRequest\032>.google.devi", + "cesandservices.health.v4.ExportExerciseT" + + "cxResponse\"L\332A\004name\202\323\344\223\002?\022=/v4/{name=use" + + "rs/*/dataTypes/*/dataPoints/*}:exportExe" + + "rciseTcx\032\363\010\312A\025health.googleapis.com\322A\327\010h" + + "ttps://www.googleapis.com/auth/googlehea" + + "lth.activity_and_fitness.readonly,https:" + + "//www.googleapis.com/auth/googlehealth.a" + + "ctivity_and_fitness.writeonly,https://ww" + + "w.googleapis.com/auth/googlehealth.ecg.r" + + "eadonly,https://www.googleapis.com/auth/" + + "googlehealth.health_metrics_and_measurem" + + "ents.readonly,https://www.googleapis.com" + + "/auth/googlehealth.health_metrics_and_me" + + "asurements.writeonly,https://www.googlea" + + "pis.com/auth/googlehealth.irn.readonly,h" + + "ttps://www.googleapis.com/auth/googlehea" + + "lth.location.readonly,https://www.google" + + "apis.com/auth/googlehealth.logged_sympto" + + "ms.readonly,https://www.googleapis.com/a" + + "uth/googlehealth.logged_symptoms.writeon" + + "ly,https://www.googleapis.com/auth/googl" + + "ehealth.mindfulness.readonly,https://www" + + ".googleapis.com/auth/googlehealth.mindfu" + + "lness.writeonly,https://www.googleapis.c" + + "om/auth/googlehealth.nutrition.writeonly" + + ",https://www.googleapis.com/auth/googleh" + + "ealth.reproductive_health.readonly,https" + + "://www.googleapis.com/auth/googlehealth." + + "reproductive_health.writeonly,https://ww" + + "w.googleapis.com/auth/googlehealth.sleep" + + ".readonly,https://www.googleapis.com/aut" + + "h/googlehealth.sleep.writeonlyB\201\002\n\'com.g" + + "oogle.devicesandservices.health.v4B\017Data" + + "PointsProtoP\001ZNgoogle.golang.org/genprot" + + "o/googleapis/devicesandservices/health/a" + + "piv4;healthpb\252\002#Google.DevicesAndService" + + "s.Health.V4\312\002#Google\\DevicesAndServices\\" + + "Health\\V4\352\002&Google::DevicesAndServices::" + + "Health::V4b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -760,7 +766,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_devicesandservices_health_v4_ListDataPointsRequest_descriptor, new java.lang.String[] { - "Parent", "PageSize", "PageToken", "Filter", + "Parent", "PageSize", "PageToken", "Filter", "DataSourceFamily", }); internal_static_google_devicesandservices_health_v4_ListDataPointsResponse_descriptor = getDescriptor().getMessageType(6); @@ -877,7 +883,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_devicesandservices_health_v4_DailyRollUpDataPointsResponse_descriptor, new java.lang.String[] { - "RollupDataPoints", + "RollupDataPoints", "NextPageToken", }); internal_static_google_devicesandservices_health_v4_DataType_descriptor = getDescriptor().getMessageType(20); diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataType.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataType.java index 36c8cf27fb2f..e649ab4d49d1 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataType.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataType.java @@ -85,7 +85,14 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { *
                * Identifier. The resource name of the data type.
                *
            -   * Format: `users/{user}/dataTypes/{data_type}`
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +   *
            +   * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * See
                * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name]
            @@ -115,7 +122,14 @@ public java.lang.String getName() {
                * 
                * Identifier. The resource name of the data type.
                *
            -   * Format: `users/{user}/dataTypes/{data_type}`
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +   *
            +   * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * See
                * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name]
            @@ -461,7 +475,14 @@ public Builder mergeFrom(
                  * 
                  * Identifier. The resource name of the data type.
                  *
            -     * Format: `users/{user}/dataTypes/{data_type}`
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +     *
            +     * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * See
                  * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name]
            @@ -490,7 +511,14 @@ public java.lang.String getName() {
                  * 
                  * Identifier. The resource name of the data type.
                  *
            -     * Format: `users/{user}/dataTypes/{data_type}`
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +     *
            +     * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * See
                  * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name]
            @@ -519,7 +547,14 @@ public com.google.protobuf.ByteString getNameBytes() {
                  * 
                  * Identifier. The resource name of the data type.
                  *
            -     * Format: `users/{user}/dataTypes/{data_type}`
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +     *
            +     * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * See
                  * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name]
            @@ -547,7 +582,14 @@ public Builder setName(java.lang.String value) {
                  * 
                  * Identifier. The resource name of the data type.
                  *
            -     * Format: `users/{user}/dataTypes/{data_type}`
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +     *
            +     * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * See
                  * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name]
            @@ -571,7 +613,14 @@ public Builder clearName() {
                  * 
                  * Identifier. The resource name of the data type.
                  *
            -     * Format: `users/{user}/dataTypes/{data_type}`
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +     *
            +     * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * See
                  * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name]
            diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataTypeOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataTypeOrBuilder.java
            index e9d3d2f6a045..c23e61cde9d7 100644
            --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataTypeOrBuilder.java
            +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/DataTypeOrBuilder.java
            @@ -32,7 +32,14 @@ public interface DataTypeOrBuilder
                * 
                * Identifier. The resource name of the data type.
                *
            -   * Format: `users/{user}/dataTypes/{data_type}`
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +   *
            +   * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * See
                * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name]
            @@ -51,7 +58,14 @@ public interface DataTypeOrBuilder
                * 
                * Identifier. The resource name of the data type.
                *
            -   * Format: `users/{user}/dataTypes/{data_type}`
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
            +   *
            +   * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * See
                * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name]
            diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ExportExerciseTcxRequest.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ExportExerciseTcxRequest.java
            index 82fcb4d38d3d..f3fc810070b4 100644
            --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ExportExerciseTcxRequest.java
            +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ExportExerciseTcxRequest.java
            @@ -82,10 +82,14 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
                * Required. The resource name of the exercise data point to export.
                *
                * Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}`
            -   * Example: `users/me/dataTypes/exercise/dataPoints/2026443605080188808`
                *
            -   * The `{user}` is the alias `"me"` currently. Future versions may support
            -   * user IDs.
            +   * Examples:
            +   * - `users/me/dataTypes/exercise/dataPoints/2026443605080188808`
            +   * - `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                * The `{data_point}` ID maps to the exercise ID, which is a long integer.
                * 
            * @@ -115,10 +119,14 @@ public java.lang.String getName() { * Required. The resource name of the exercise data point to export. * * Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` - * Example: `users/me/dataTypes/exercise/dataPoints/2026443605080188808` * - * The `{user}` is the alias `"me"` currently. Future versions may support - * user IDs. + * Examples: + * - `users/me/dataTypes/exercise/dataPoints/2026443605080188808` + * - `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * The `{data_point}` ID maps to the exercise ID, which is a long integer. *
            * @@ -508,10 +516,14 @@ public Builder mergeFrom( * Required. The resource name of the exercise data point to export. * * Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` - * Example: `users/me/dataTypes/exercise/dataPoints/2026443605080188808` * - * The `{user}` is the alias `"me"` currently. Future versions may support - * user IDs. + * Examples: + * - `users/me/dataTypes/exercise/dataPoints/2026443605080188808` + * - `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * The `{data_point}` ID maps to the exercise ID, which is a long integer. *
            * @@ -540,10 +552,14 @@ public java.lang.String getName() { * Required. The resource name of the exercise data point to export. * * Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` - * Example: `users/me/dataTypes/exercise/dataPoints/2026443605080188808` * - * The `{user}` is the alias `"me"` currently. Future versions may support - * user IDs. + * Examples: + * - `users/me/dataTypes/exercise/dataPoints/2026443605080188808` + * - `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * The `{data_point}` ID maps to the exercise ID, which is a long integer. *
            * @@ -572,10 +588,14 @@ public com.google.protobuf.ByteString getNameBytes() { * Required. The resource name of the exercise data point to export. * * Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` - * Example: `users/me/dataTypes/exercise/dataPoints/2026443605080188808` * - * The `{user}` is the alias `"me"` currently. Future versions may support - * user IDs. + * Examples: + * - `users/me/dataTypes/exercise/dataPoints/2026443605080188808` + * - `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * The `{data_point}` ID maps to the exercise ID, which is a long integer. *
            * @@ -603,10 +623,14 @@ public Builder setName(java.lang.String value) { * Required. The resource name of the exercise data point to export. * * Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` - * Example: `users/me/dataTypes/exercise/dataPoints/2026443605080188808` * - * The `{user}` is the alias `"me"` currently. Future versions may support - * user IDs. + * Examples: + * - `users/me/dataTypes/exercise/dataPoints/2026443605080188808` + * - `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * The `{data_point}` ID maps to the exercise ID, which is a long integer. *
            * @@ -630,10 +654,14 @@ public Builder clearName() { * Required. The resource name of the exercise data point to export. * * Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` - * Example: `users/me/dataTypes/exercise/dataPoints/2026443605080188808` * - * The `{user}` is the alias `"me"` currently. Future versions may support - * user IDs. + * Examples: + * - `users/me/dataTypes/exercise/dataPoints/2026443605080188808` + * - `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * The `{data_point}` ID maps to the exercise ID, which is a long integer. *
            * diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ExportExerciseTcxRequestOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ExportExerciseTcxRequestOrBuilder.java index 9864df4b2d9d..bfd169a77f41 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ExportExerciseTcxRequestOrBuilder.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ExportExerciseTcxRequestOrBuilder.java @@ -33,10 +33,14 @@ public interface ExportExerciseTcxRequestOrBuilder * Required. The resource name of the exercise data point to export. * * Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` - * Example: `users/me/dataTypes/exercise/dataPoints/2026443605080188808` * - * The `{user}` is the alias `"me"` currently. Future versions may support - * user IDs. + * Examples: + * - `users/me/dataTypes/exercise/dataPoints/2026443605080188808` + * - `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * The `{data_point}` ID maps to the exercise ID, which is a long integer. *
            * @@ -55,10 +59,14 @@ public interface ExportExerciseTcxRequestOrBuilder * Required. The resource name of the exercise data point to export. * * Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` - * Example: `users/me/dataTypes/exercise/dataPoints/2026443605080188808` * - * The `{user}` is the alias `"me"` currently. Future versions may support - * user IDs. + * Examples: + * - `users/me/dataTypes/exercise/dataPoints/2026443605080188808` + * - `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). * The `{data_point}` ID maps to the exercise ID, which is a long integer. *
            * diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/GetDataPointRequest.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/GetDataPointRequest.java index 6b9d7bb4e0c2..b01df418cc32 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/GetDataPointRequest.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/GetDataPointRequest.java @@ -83,6 +83,17 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). + * * See * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] * for examples and possible values. @@ -115,6 +126,17 @@ public java.lang.String getName() { * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). + * * See * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] * for examples and possible values. @@ -460,6 +482,17 @@ public Builder mergeFrom( * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). + * * See * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] * for examples and possible values. @@ -491,6 +524,17 @@ public java.lang.String getName() { * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). + * * See * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] * for examples and possible values. @@ -522,6 +566,17 @@ public com.google.protobuf.ByteString getNameBytes() { * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). + * * See * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] * for examples and possible values. @@ -552,6 +607,17 @@ public Builder setName(java.lang.String value) { * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). + * * See * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] * for examples and possible values. @@ -578,6 +644,17 @@ public Builder clearName() { * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). + * * See * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] * for examples and possible values. diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/GetDataPointRequestOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/GetDataPointRequestOrBuilder.java index 06e718cb4807..99a1c6c448ad 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/GetDataPointRequestOrBuilder.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/GetDataPointRequestOrBuilder.java @@ -34,6 +34,17 @@ public interface GetDataPointRequestOrBuilder * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). + * * See * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] * for examples and possible values. @@ -55,6 +66,17 @@ public interface GetDataPointRequestOrBuilder * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). + * * See * [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] * for examples and possible values. diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/HealthProfileProto.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/HealthProfileProto.java index a0d3a47c1010..f673bbcc516d 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/HealthProfileProto.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/HealthProfileProto.java @@ -267,7 +267,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\031ListPairedDevicesResponse\022I\n" + "\016paired_devices\030\001" + " \003(\01321.google.devicesandservices.health.v4.PairedDevice\022\027\n" - + "\017next_page_token\030\002 \001(\t2\373\021\n" + + "\017next_page_token\030\002 \001(\t2\260\026\n" + "\024HealthProfileService\022\235\001\n\n" + "GetProfile\0226.google.devicesandservices.health.v4" + ".GetProfileRequest\032,.google.devicesandse" @@ -295,24 +295,31 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "health.v4.PairedDevice\"1\332A\004name\202\323\344\223\002$\022\"/v4/{name=users/*/pairedDevices/*}\022\307\001\n" + "\021ListPairedDevices\022=.google.devicesandservi" + "ces.health.v4.ListPairedDevicesRequest\032>.google.devicesandservices.health.v4.Lis" - + "tPairedDevicesResponse\"3\332A\006parent\202\323\344\223\002$\022" - + "\"/v4/{parent=users/*}/pairedDevices\032\272\006\312A" - + "\025health.googleapis.com\322A\236\006https://www.go" - + "ogleapis.com/auth/googlehealth.activity_and_fitness.readonly,https://www.googlea" - + "pis.com/auth/googlehealth.ecg.readonly,https://www.googleapis.com/auth/googlehea" - + "lth.health_metrics_and_measurements.readonly,https://www.googleapis.com/auth/goo" - + "glehealth.irn.readonly,https://www.googleapis.com/auth/googlehealth.logged_sympt" - + "oms.readonly,https://www.googleapis.com/auth/googlehealth.mindfulness.readonly,h" - + "ttps://www.googleapis.com/auth/googlehealth.profile.readonly,https://www.googlea" - + "pis.com/auth/googlehealth.profile.writeonly,https://www.googleapis.com/auth/goog" - + "lehealth.reproductive_health.readonly,https://www.googleapis.com/auth/googleheal" - + "th.settings.readonly,https://www.googleapis.com/auth/googlehealth.settings.write" - + "only,https://www.googleapis.com/auth/googlehealth.sleep.readonlyB\204\002\n" - + "\'com.google.devicesandservices.health.v4B\022HealthProf" - + "ileProtoP\001ZNgoogle.golang.org/genproto/googleapis/devicesandservices/health/apiv" - + "4;healthpb\252\002#Google.DevicesAndServices.H" - + "ealth.V4\312\002#Google\\DevicesAndServices\\Hea" - + "lth\\V4\352\002&Google::DevicesAndServices::Health::V4b\006proto3" + + "tPairedDevicesResponse\"3\332A\006parent\202\323\344\223\002$\022\"/v4/{parent=users/*}/pairedDevices\032\357\n" + + "\312A\025health.googleapis.com\322A\323\n" + + "https://www.googleapis.com/auth/googlehealth.activity_" + + "and_fitness.readonly,https://www.googleapis.com/auth/googlehealth.activity_and_f" + + "itness.writeonly,https://www.googleapis.com/auth/googlehealth.ecg.readonly,https" + + "://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.readonly" + + ",https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.wr" + + "iteonly,https://www.googleapis.com/auth/googlehealth.irn.readonly,https://www.go" + + "ogleapis.com/auth/googlehealth.location.readonly,https://www.googleapis.com/auth" + + "/googlehealth.logged_symptoms.readonly,https://www.googleapis.com/auth/googlehea" + + "lth.logged_symptoms.writeonly,https://www.googleapis.com/auth/googlehealth.mindf" + + "ulness.readonly,https://www.googleapis.com/auth/googlehealth.mindfulness.writeon" + + "ly,https://www.googleapis.com/auth/googlehealth.nutrition.writeonly,https://www." + + "googleapis.com/auth/googlehealth.profile.readonly,https://www.googleapis.com/aut" + + "h/googlehealth.profile.writeonly,https://www.googleapis.com/auth/googlehealth.re" + + "productive_health.readonly,https://www.googleapis.com/auth/googlehealth.reproduc" + + "tive_health.writeonly,https://www.googleapis.com/auth/googlehealth.settings.read" + + "only,https://www.googleapis.com/auth/googlehealth.settings.writeonly,https://www" + + ".googleapis.com/auth/googlehealth.sleep." + + "readonly,https://www.googleapis.com/auth/googlehealth.sleep.writeonlyB\204\002\n" + + "\'com.google.devicesandservices.health.v4B\022Healt" + + "hProfileProtoP\001ZNgoogle.golang.org/genproto/googleapis/devicesandservices/health" + + "/apiv4;healthpb\252\002#Google.DevicesAndServi" + + "ces.Health.V4\312\002#Google\\DevicesAndService" + + "s\\Health\\V4\352\002&Google::DevicesAndServices::Health::V4b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ListDataPointsRequest.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ListDataPointsRequest.java index 23b855a137ba..6dd72c2273e9 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ListDataPointsRequest.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ListDataPointsRequest.java @@ -55,6 +55,7 @@ private ListDataPointsRequest() { parent_ = ""; pageToken_ = ""; filter_ = ""; + dataSourceFamily_ = ""; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -83,10 +84,16 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { *
                * Required. Parent data type of the Data Point collection.
                *
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/weight`
            +   * - `users/1234567890/dataTypes/weight`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the [DataPoint
                * data][google.devicesandservices.health.v4.DataPoint] union
            @@ -118,10 +125,16 @@ public java.lang.String getParent() {
                * 
                * Required. Parent data type of the Data Point collection.
                *
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/weight`
            +   * - `users/1234567890/dataTypes/weight`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the [DataPoint
                * data][google.devicesandservices.health.v4.DataPoint] union
            @@ -481,6 +494,143 @@ public com.google.protobuf.ByteString getFilterBytes() {
                 }
               }
             
            +  public static final int DATA_SOURCE_FAMILY_FIELD_NUMBER = 5;
            +
            +  @SuppressWarnings("serial")
            +  private volatile java.lang.Object dataSourceFamily_ = "";
            +
            +  /**
            +   *
            +   *
            +   * 
            +   * Optional. The data source family name to filter by.
            +   *
            +   * If empty, data points from all available data sources will be returned.
            +   *
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
            +   *
            +   * The supported values are:
            +   *
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
            +   * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
            +   * Watch). Excludes manually logged data.
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
            +   * Google data, such as data from tracker devices, manually logged data, and
            +   * Health Connect.
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
            +   * source was registered through this API with the same OAuth client ID as
            +   * the caller.
            +   *
            +   * Callers that were only granted write scopes for the requested data types
            +   * may only read the data they wrote themselves: their requests are
            +   * implicitly restricted to `self-sources`, and requesting any other data
            +   * source family fails with `PERMISSION_DENIED`.
            +   *
            +   * If no data point matches the requested data source family, the response is
            +   * an empty list rather than an error.
            +   *
            +   * Filtering by data source family is not supported for the `sleep`, `food`
            +   * and `food-measurement-unit` data types, because the underlying listing
            +   * implementation cannot restrict results by data source. Such requests fail
            +   * with `INVALID_ARGUMENT` when the data source family is set explicitly, and
            +   * with `PERMISSION_DENIED` when the restriction is only implied by the
            +   * caller's scopes. For `sleep`, use
            +   * [ReconcileDataPoints][google.devicesandservices.health.v4.DataPointsService.ReconcileDataPoints]
            +   * instead.
            +   * 
            + * + * string data_source_family = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The dataSourceFamily. + */ + @java.lang.Override + public java.lang.String getDataSourceFamily() { + java.lang.Object ref = dataSourceFamily_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + dataSourceFamily_ = s; + return s; + } + } + + /** + * + * + *
            +   * Optional. The data source family name to filter by.
            +   *
            +   * If empty, data points from all available data sources will be returned.
            +   *
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
            +   *
            +   * The supported values are:
            +   *
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
            +   * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
            +   * Watch). Excludes manually logged data.
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
            +   * Google data, such as data from tracker devices, manually logged data, and
            +   * Health Connect.
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
            +   * source was registered through this API with the same OAuth client ID as
            +   * the caller.
            +   *
            +   * Callers that were only granted write scopes for the requested data types
            +   * may only read the data they wrote themselves: their requests are
            +   * implicitly restricted to `self-sources`, and requesting any other data
            +   * source family fails with `PERMISSION_DENIED`.
            +   *
            +   * If no data point matches the requested data source family, the response is
            +   * an empty list rather than an error.
            +   *
            +   * Filtering by data source family is not supported for the `sleep`, `food`
            +   * and `food-measurement-unit` data types, because the underlying listing
            +   * implementation cannot restrict results by data source. Such requests fail
            +   * with `INVALID_ARGUMENT` when the data source family is set explicitly, and
            +   * with `PERMISSION_DENIED` when the restriction is only implied by the
            +   * caller's scopes. For `sleep`, use
            +   * [ReconcileDataPoints][google.devicesandservices.health.v4.DataPointsService.ReconcileDataPoints]
            +   * instead.
            +   * 
            + * + * string data_source_family = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for dataSourceFamily. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDataSourceFamilyBytes() { + java.lang.Object ref = dataSourceFamily_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + dataSourceFamily_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -507,6 +657,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { com.google.protobuf.GeneratedMessage.writeString(output, 4, filter_); } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(dataSourceFamily_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, dataSourceFamily_); + } getUnknownFields().writeTo(output); } @@ -528,6 +681,9 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { size += com.google.protobuf.GeneratedMessage.computeStringSize(4, filter_); } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(dataSourceFamily_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, dataSourceFamily_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -548,6 +704,7 @@ public boolean equals(final java.lang.Object obj) { if (getPageSize() != other.getPageSize()) return false; if (!getPageToken().equals(other.getPageToken())) return false; if (!getFilter().equals(other.getFilter())) return false; + if (!getDataSourceFamily().equals(other.getDataSourceFamily())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -567,6 +724,8 @@ public int hashCode() { hash = (53 * hash) + getPageToken().hashCode(); hash = (37 * hash) + FILTER_FIELD_NUMBER; hash = (53 * hash) + getFilter().hashCode(); + hash = (37 * hash) + DATA_SOURCE_FAMILY_FIELD_NUMBER; + hash = (53 * hash) + getDataSourceFamily().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -712,6 +871,7 @@ public Builder clear() { pageSize_ = 0; pageToken_ = ""; filter_ = ""; + dataSourceFamily_ = ""; return this; } @@ -762,6 +922,9 @@ private void buildPartial0( if (((from_bitField0_ & 0x00000008) != 0)) { result.filter_ = filter_; } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.dataSourceFamily_ = dataSourceFamily_; + } } @java.lang.Override @@ -796,6 +959,11 @@ public Builder mergeFrom(com.google.devicesandservices.health.v4.ListDataPointsR bitField0_ |= 0x00000008; onChanged(); } + if (!other.getDataSourceFamily().isEmpty()) { + dataSourceFamily_ = other.dataSourceFamily_; + bitField0_ |= 0x00000010; + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -846,6 +1014,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 34 + case 42: + { + dataSourceFamily_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -873,10 +1047,16 @@ public Builder mergeFrom( *
                  * Required. Parent data type of the Data Point collection.
                  *
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/weight`
            +     * - `users/1234567890/dataTypes/weight`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the [DataPoint
                  * data][google.devicesandservices.health.v4.DataPoint] union
            @@ -907,10 +1087,16 @@ public java.lang.String getParent() {
                  * 
                  * Required. Parent data type of the Data Point collection.
                  *
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/weight`
            +     * - `users/1234567890/dataTypes/weight`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the [DataPoint
                  * data][google.devicesandservices.health.v4.DataPoint] union
            @@ -941,10 +1127,16 @@ public com.google.protobuf.ByteString getParentBytes() {
                  * 
                  * Required. Parent data type of the Data Point collection.
                  *
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/weight`
            +     * - `users/1234567890/dataTypes/weight`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the [DataPoint
                  * data][google.devicesandservices.health.v4.DataPoint] union
            @@ -974,10 +1166,16 @@ public Builder setParent(java.lang.String value) {
                  * 
                  * Required. Parent data type of the Data Point collection.
                  *
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/weight`
            +     * - `users/1234567890/dataTypes/weight`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the [DataPoint
                  * data][google.devicesandservices.health.v4.DataPoint] union
            @@ -1003,10 +1201,16 @@ public Builder clearParent() {
                  * 
                  * Required. Parent data type of the Data Point collection.
                  *
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/weight`
            +     * - `users/1234567890/dataTypes/weight`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the [DataPoint
                  * data][google.devicesandservices.health.v4.DataPoint] union
            @@ -1834,6 +2038,327 @@ public Builder setFilterBytes(com.google.protobuf.ByteString value) {
                   return this;
                 }
             
            +    private java.lang.Object dataSourceFamily_ = "";
            +
            +    /**
            +     *
            +     *
            +     * 
            +     * Optional. The data source family name to filter by.
            +     *
            +     * If empty, data points from all available data sources will be returned.
            +     *
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
            +     *
            +     * The supported values are:
            +     *
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
            +     * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
            +     * Watch). Excludes manually logged data.
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
            +     * Google data, such as data from tracker devices, manually logged data, and
            +     * Health Connect.
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
            +     * source was registered through this API with the same OAuth client ID as
            +     * the caller.
            +     *
            +     * Callers that were only granted write scopes for the requested data types
            +     * may only read the data they wrote themselves: their requests are
            +     * implicitly restricted to `self-sources`, and requesting any other data
            +     * source family fails with `PERMISSION_DENIED`.
            +     *
            +     * If no data point matches the requested data source family, the response is
            +     * an empty list rather than an error.
            +     *
            +     * Filtering by data source family is not supported for the `sleep`, `food`
            +     * and `food-measurement-unit` data types, because the underlying listing
            +     * implementation cannot restrict results by data source. Such requests fail
            +     * with `INVALID_ARGUMENT` when the data source family is set explicitly, and
            +     * with `PERMISSION_DENIED` when the restriction is only implied by the
            +     * caller's scopes. For `sleep`, use
            +     * [ReconcileDataPoints][google.devicesandservices.health.v4.DataPointsService.ReconcileDataPoints]
            +     * instead.
            +     * 
            + * + * string data_source_family = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The dataSourceFamily. + */ + public java.lang.String getDataSourceFamily() { + java.lang.Object ref = dataSourceFamily_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + dataSourceFamily_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * Optional. The data source family name to filter by.
            +     *
            +     * If empty, data points from all available data sources will be returned.
            +     *
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
            +     *
            +     * The supported values are:
            +     *
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
            +     * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
            +     * Watch). Excludes manually logged data.
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
            +     * Google data, such as data from tracker devices, manually logged data, and
            +     * Health Connect.
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
            +     * source was registered through this API with the same OAuth client ID as
            +     * the caller.
            +     *
            +     * Callers that were only granted write scopes for the requested data types
            +     * may only read the data they wrote themselves: their requests are
            +     * implicitly restricted to `self-sources`, and requesting any other data
            +     * source family fails with `PERMISSION_DENIED`.
            +     *
            +     * If no data point matches the requested data source family, the response is
            +     * an empty list rather than an error.
            +     *
            +     * Filtering by data source family is not supported for the `sleep`, `food`
            +     * and `food-measurement-unit` data types, because the underlying listing
            +     * implementation cannot restrict results by data source. Such requests fail
            +     * with `INVALID_ARGUMENT` when the data source family is set explicitly, and
            +     * with `PERMISSION_DENIED` when the restriction is only implied by the
            +     * caller's scopes. For `sleep`, use
            +     * [ReconcileDataPoints][google.devicesandservices.health.v4.DataPointsService.ReconcileDataPoints]
            +     * instead.
            +     * 
            + * + * string data_source_family = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for dataSourceFamily. + */ + public com.google.protobuf.ByteString getDataSourceFamilyBytes() { + java.lang.Object ref = dataSourceFamily_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + dataSourceFamily_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * Optional. The data source family name to filter by.
            +     *
            +     * If empty, data points from all available data sources will be returned.
            +     *
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
            +     *
            +     * The supported values are:
            +     *
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
            +     * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
            +     * Watch). Excludes manually logged data.
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
            +     * Google data, such as data from tracker devices, manually logged data, and
            +     * Health Connect.
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
            +     * source was registered through this API with the same OAuth client ID as
            +     * the caller.
            +     *
            +     * Callers that were only granted write scopes for the requested data types
            +     * may only read the data they wrote themselves: their requests are
            +     * implicitly restricted to `self-sources`, and requesting any other data
            +     * source family fails with `PERMISSION_DENIED`.
            +     *
            +     * If no data point matches the requested data source family, the response is
            +     * an empty list rather than an error.
            +     *
            +     * Filtering by data source family is not supported for the `sleep`, `food`
            +     * and `food-measurement-unit` data types, because the underlying listing
            +     * implementation cannot restrict results by data source. Such requests fail
            +     * with `INVALID_ARGUMENT` when the data source family is set explicitly, and
            +     * with `PERMISSION_DENIED` when the restriction is only implied by the
            +     * caller's scopes. For `sleep`, use
            +     * [ReconcileDataPoints][google.devicesandservices.health.v4.DataPointsService.ReconcileDataPoints]
            +     * instead.
            +     * 
            + * + * string data_source_family = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The dataSourceFamily to set. + * @return This builder for chaining. + */ + public Builder setDataSourceFamily(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + dataSourceFamily_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. The data source family name to filter by.
            +     *
            +     * If empty, data points from all available data sources will be returned.
            +     *
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
            +     *
            +     * The supported values are:
            +     *
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
            +     * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
            +     * Watch). Excludes manually logged data.
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
            +     * Google data, such as data from tracker devices, manually logged data, and
            +     * Health Connect.
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
            +     * source was registered through this API with the same OAuth client ID as
            +     * the caller.
            +     *
            +     * Callers that were only granted write scopes for the requested data types
            +     * may only read the data they wrote themselves: their requests are
            +     * implicitly restricted to `self-sources`, and requesting any other data
            +     * source family fails with `PERMISSION_DENIED`.
            +     *
            +     * If no data point matches the requested data source family, the response is
            +     * an empty list rather than an error.
            +     *
            +     * Filtering by data source family is not supported for the `sleep`, `food`
            +     * and `food-measurement-unit` data types, because the underlying listing
            +     * implementation cannot restrict results by data source. Such requests fail
            +     * with `INVALID_ARGUMENT` when the data source family is set explicitly, and
            +     * with `PERMISSION_DENIED` when the restriction is only implied by the
            +     * caller's scopes. For `sleep`, use
            +     * [ReconcileDataPoints][google.devicesandservices.health.v4.DataPointsService.ReconcileDataPoints]
            +     * instead.
            +     * 
            + * + * string data_source_family = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDataSourceFamily() { + dataSourceFamily_ = getDefaultInstance().getDataSourceFamily(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. The data source family name to filter by.
            +     *
            +     * If empty, data points from all available data sources will be returned.
            +     *
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
            +     *
            +     * The supported values are:
            +     *
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
            +     * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
            +     * Watch). Excludes manually logged data.
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
            +     * Google data, such as data from tracker devices, manually logged data, and
            +     * Health Connect.
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
            +     * source was registered through this API with the same OAuth client ID as
            +     * the caller.
            +     *
            +     * Callers that were only granted write scopes for the requested data types
            +     * may only read the data they wrote themselves: their requests are
            +     * implicitly restricted to `self-sources`, and requesting any other data
            +     * source family fails with `PERMISSION_DENIED`.
            +     *
            +     * If no data point matches the requested data source family, the response is
            +     * an empty list rather than an error.
            +     *
            +     * Filtering by data source family is not supported for the `sleep`, `food`
            +     * and `food-measurement-unit` data types, because the underlying listing
            +     * implementation cannot restrict results by data source. Such requests fail
            +     * with `INVALID_ARGUMENT` when the data source family is set explicitly, and
            +     * with `PERMISSION_DENIED` when the restriction is only implied by the
            +     * caller's scopes. For `sleep`, use
            +     * [ReconcileDataPoints][google.devicesandservices.health.v4.DataPointsService.ReconcileDataPoints]
            +     * instead.
            +     * 
            + * + * string data_source_family = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for dataSourceFamily to set. + * @return This builder for chaining. + */ + public Builder setDataSourceFamilyBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + dataSourceFamily_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.devicesandservices.health.v4.ListDataPointsRequest) } diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ListDataPointsRequestOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ListDataPointsRequestOrBuilder.java index fa8a5547962b..e8059058c4d5 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ListDataPointsRequestOrBuilder.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ListDataPointsRequestOrBuilder.java @@ -32,10 +32,16 @@ public interface ListDataPointsRequestOrBuilder *
                * Required. Parent data type of the Data Point collection.
                *
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/weight`
            +   * - `users/1234567890/dataTypes/weight`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the [DataPoint
                * data][google.devicesandservices.health.v4.DataPoint] union
            @@ -56,10 +62,16 @@ public interface ListDataPointsRequestOrBuilder
                * 
                * Required. Parent data type of the Data Point collection.
                *
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/weight`
            +   * - `users/1234567890/dataTypes/weight`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the [DataPoint
                * data][google.devicesandservices.health.v4.DataPoint] union
            @@ -347,4 +359,114 @@ public interface ListDataPointsRequestOrBuilder
                * @return The bytes for filter.
                */
               com.google.protobuf.ByteString getFilterBytes();
            +
            +  /**
            +   *
            +   *
            +   * 
            +   * Optional. The data source family name to filter by.
            +   *
            +   * If empty, data points from all available data sources will be returned.
            +   *
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
            +   *
            +   * The supported values are:
            +   *
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
            +   * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
            +   * Watch). Excludes manually logged data.
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
            +   * Google data, such as data from tracker devices, manually logged data, and
            +   * Health Connect.
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
            +   * source was registered through this API with the same OAuth client ID as
            +   * the caller.
            +   *
            +   * Callers that were only granted write scopes for the requested data types
            +   * may only read the data they wrote themselves: their requests are
            +   * implicitly restricted to `self-sources`, and requesting any other data
            +   * source family fails with `PERMISSION_DENIED`.
            +   *
            +   * If no data point matches the requested data source family, the response is
            +   * an empty list rather than an error.
            +   *
            +   * Filtering by data source family is not supported for the `sleep`, `food`
            +   * and `food-measurement-unit` data types, because the underlying listing
            +   * implementation cannot restrict results by data source. Such requests fail
            +   * with `INVALID_ARGUMENT` when the data source family is set explicitly, and
            +   * with `PERMISSION_DENIED` when the restriction is only implied by the
            +   * caller's scopes. For `sleep`, use
            +   * [ReconcileDataPoints][google.devicesandservices.health.v4.DataPointsService.ReconcileDataPoints]
            +   * instead.
            +   * 
            + * + * string data_source_family = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The dataSourceFamily. + */ + java.lang.String getDataSourceFamily(); + + /** + * + * + *
            +   * Optional. The data source family name to filter by.
            +   *
            +   * If empty, data points from all available data sources will be returned.
            +   *
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
            +   *
            +   * The supported values are:
            +   *
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
            +   * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
            +   * Watch). Excludes manually logged data.
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
            +   * Google data, such as data from tracker devices, manually logged data, and
            +   * Health Connect.
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
            +   * source was registered through this API with the same OAuth client ID as
            +   * the caller.
            +   *
            +   * Callers that were only granted write scopes for the requested data types
            +   * may only read the data they wrote themselves: their requests are
            +   * implicitly restricted to `self-sources`, and requesting any other data
            +   * source family fails with `PERMISSION_DENIED`.
            +   *
            +   * If no data point matches the requested data source family, the response is
            +   * an empty list rather than an error.
            +   *
            +   * Filtering by data source family is not supported for the `sleep`, `food`
            +   * and `food-measurement-unit` data types, because the underlying listing
            +   * implementation cannot restrict results by data source. Such requests fail
            +   * with `INVALID_ARGUMENT` when the data source family is set explicitly, and
            +   * with `PERMISSION_DENIED` when the restriction is only implied by the
            +   * caller's scopes. For `sleep`, use
            +   * [ReconcileDataPoints][google.devicesandservices.health.v4.DataPointsService.ReconcileDataPoints]
            +   * instead.
            +   * 
            + * + * string data_source_family = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for dataSourceFamily. + */ + com.google.protobuf.ByteString getDataSourceFamilyBytes(); } diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTest.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTest.java index 6c21908dc7da..75fa266a3664 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTest.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTest.java @@ -53,6 +53,7 @@ private OvulationTest(com.google.protobuf.GeneratedMessage.Builder builder) { private OvulationTest() { result_ = 0; + testType_ = 0; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -70,6 +71,200 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { com.google.devicesandservices.health.v4.OvulationTest.Builder.class); } + /** + * + * + *
            +   * Ovulation test type.
            +   * 
            + * + * Protobuf enum {@code google.devicesandservices.health.v4.OvulationTest.TestType} + */ + public enum TestType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
            +     * Unspecified test type.
            +     * 
            + * + * TEST_TYPE_UNSPECIFIED = 0; + */ + TEST_TYPE_UNSPECIFIED(0), + /** + * + * + *
            +     * Test strip.
            +     * 
            + * + * STRIP = 1; + */ + STRIP(1), + /** + * + * + *
            +     * Digital test.
            +     * 
            + * + * DIGITAL = 2; + */ + DIGITAL(2), + /** + * + * + *
            +     * The user's own method, not a test kit.
            +     * 
            + * + * OWN_METHOD = 3; + */ + OWN_METHOD(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "TestType"); + } + + /** + * + * + *
            +     * Unspecified test type.
            +     * 
            + * + * TEST_TYPE_UNSPECIFIED = 0; + */ + public static final int TEST_TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
            +     * Test strip.
            +     * 
            + * + * STRIP = 1; + */ + public static final int STRIP_VALUE = 1; + + /** + * + * + *
            +     * Digital test.
            +     * 
            + * + * DIGITAL = 2; + */ + public static final int DIGITAL_VALUE = 2; + + /** + * + * + *
            +     * The user's own method, not a test kit.
            +     * 
            + * + * OWN_METHOD = 3; + */ + public static final int OWN_METHOD_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static TestType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static TestType forNumber(int value) { + switch (value) { + case 0: + return TEST_TYPE_UNSPECIFIED; + case 1: + return STRIP; + case 2: + return DIGITAL; + case 3: + return OWN_METHOD; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public TestType findValueByNumber(int number) { + return TestType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.devicesandservices.health.v4.OvulationTest.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final TestType[] VALUES = values(); + + public static TestType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private TestType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.devicesandservices.health.v4.OvulationTest.TestType) + } + private int bitField0_; public static final int SAMPLE_TIME_FIELD_NUMBER = 2; private com.google.devicesandservices.health.v4.ObservationSampleTime sampleTime_; @@ -174,6 +369,49 @@ public com.google.devicesandservices.health.v4.OvulationTestResult getResult() { : result; } + public static final int TEST_TYPE_FIELD_NUMBER = 4; + private int testType_ = 0; + + /** + * + * + *
            +   * Optional. The type of ovulation test.
            +   * 
            + * + * + * .google.devicesandservices.health.v4.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for testType. + */ + @java.lang.Override + public int getTestTypeValue() { + return testType_; + } + + /** + * + * + *
            +   * Optional. The type of ovulation test.
            +   * 
            + * + * + * .google.devicesandservices.health.v4.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The testType. + */ + @java.lang.Override + public com.google.devicesandservices.health.v4.OvulationTest.TestType getTestType() { + com.google.devicesandservices.health.v4.OvulationTest.TestType result = + com.google.devicesandservices.health.v4.OvulationTest.TestType.forNumber(testType_); + return result == null + ? com.google.devicesandservices.health.v4.OvulationTest.TestType.UNRECOGNIZED + : result; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -197,6 +435,11 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io .getNumber()) { output.writeEnum(3, result_); } + if (testType_ + != com.google.devicesandservices.health.v4.OvulationTest.TestType.TEST_TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(4, testType_); + } getUnknownFields().writeTo(output); } @@ -215,6 +458,11 @@ public int getSerializedSize() { .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, result_); } + if (testType_ + != com.google.devicesandservices.health.v4.OvulationTest.TestType.TEST_TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, testType_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -236,6 +484,7 @@ public boolean equals(final java.lang.Object obj) { if (!getSampleTime().equals(other.getSampleTime())) return false; } if (result_ != other.result_) return false; + if (testType_ != other.testType_) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -253,6 +502,8 @@ public int hashCode() { } hash = (37 * hash) + RESULT_FIELD_NUMBER; hash = (53 * hash) + result_; + hash = (37 * hash) + TEST_TYPE_FIELD_NUMBER; + hash = (53 * hash) + testType_; hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -409,6 +660,7 @@ public Builder clear() { sampleTimeBuilder_ = null; } result_ = 0; + testType_ = 0; return this; } @@ -453,6 +705,9 @@ private void buildPartial0(com.google.devicesandservices.health.v4.OvulationTest if (((from_bitField0_ & 0x00000002) != 0)) { result.result_ = result_; } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.testType_ = testType_; + } result.bitField0_ |= to_bitField0_; } @@ -475,6 +730,9 @@ public Builder mergeFrom(com.google.devicesandservices.health.v4.OvulationTest o if (other.result_ != 0) { setResultValue(other.getResultValue()); } + if (other.testType_ != 0) { + setTestTypeValue(other.getTestTypeValue()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -514,6 +772,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000002; break; } // case 24 + case 32: + { + testType_ = input.readEnum(); + bitField0_ |= 0x00000004; + break; + } // case 32 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -859,6 +1123,114 @@ public Builder clearResult() { return this; } + private int testType_ = 0; + + /** + * + * + *
            +     * Optional. The type of ovulation test.
            +     * 
            + * + * + * .google.devicesandservices.health.v4.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for testType. + */ + @java.lang.Override + public int getTestTypeValue() { + return testType_; + } + + /** + * + * + *
            +     * Optional. The type of ovulation test.
            +     * 
            + * + * + * .google.devicesandservices.health.v4.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for testType to set. + * @return This builder for chaining. + */ + public Builder setTestTypeValue(int value) { + testType_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. The type of ovulation test.
            +     * 
            + * + * + * .google.devicesandservices.health.v4.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The testType. + */ + @java.lang.Override + public com.google.devicesandservices.health.v4.OvulationTest.TestType getTestType() { + com.google.devicesandservices.health.v4.OvulationTest.TestType result = + com.google.devicesandservices.health.v4.OvulationTest.TestType.forNumber(testType_); + return result == null + ? com.google.devicesandservices.health.v4.OvulationTest.TestType.UNRECOGNIZED + : result; + } + + /** + * + * + *
            +     * Optional. The type of ovulation test.
            +     * 
            + * + * + * .google.devicesandservices.health.v4.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The testType to set. + * @return This builder for chaining. + */ + public Builder setTestType( + com.google.devicesandservices.health.v4.OvulationTest.TestType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000004; + testType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. The type of ovulation test.
            +     * 
            + * + * + * .google.devicesandservices.health.v4.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearTestType() { + bitField0_ = (bitField0_ & ~0x00000004); + testType_ = 0; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.devicesandservices.health.v4.OvulationTest) } diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTestOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTestOrBuilder.java index cf259af90f1e..4393161a5189 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTestOrBuilder.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTestOrBuilder.java @@ -98,4 +98,34 @@ public interface OvulationTestOrBuilder * @return The result. */ com.google.devicesandservices.health.v4.OvulationTestResult getResult(); + + /** + * + * + *
            +   * Optional. The type of ovulation test.
            +   * 
            + * + * + * .google.devicesandservices.health.v4.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for testType. + */ + int getTestTypeValue(); + + /** + * + * + *
            +   * Optional. The type of ovulation test.
            +   * 
            + * + * + * .google.devicesandservices.health.v4.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The testType. + */ + com.google.devicesandservices.health.v4.OvulationTest.TestType getTestType(); } diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTestResult.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTestResult.java index 87832128980f..12ef3a2f9f0b 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTestResult.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/OvulationTestResult.java @@ -91,6 +91,16 @@ public enum OvulationTestResult implements com.google.protobuf.ProtocolMessageEn * INDETERMINATE = 5; */ INDETERMINATE(5), + /** + * + * + *
            +   * Ovulation day the user identified by their own method, not a test kit.
            +   * 
            + * + * OWN_METHOD = 6; + */ + OWN_METHOD(6), UNRECOGNIZED(-1), ; @@ -170,6 +180,17 @@ public enum OvulationTestResult implements com.google.protobuf.ProtocolMessageEn */ public static final int INDETERMINATE_VALUE = 5; + /** + * + * + *
            +   * Ovulation day the user identified by their own method, not a test kit.
            +   * 
            + * + * OWN_METHOD = 6; + */ + public static final int OWN_METHOD_VALUE = 6; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -206,6 +227,8 @@ public static OvulationTestResult forNumber(int value) { return POSITIVE; case 5: return INDETERMINATE; + case 6: + return OWN_METHOD; default: return null; } diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconcileDataPointsRequest.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconcileDataPointsRequest.java index 6af1ec2f30db..0ec48bfb24f1 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconcileDataPointsRequest.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconcileDataPointsRequest.java @@ -84,10 +84,16 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { *
                * Required. Parent data type of the Data Point collection.
                *
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/heart-rate`
            +   * - `users/1234567890/dataTypes/heart-rate`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the
                * [DataPoint
            @@ -118,10 +124,16 @@ public java.lang.String getParent() {
                * 
                * Required. Parent data type of the Data Point collection.
                *
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/heart-rate`
            +   * - `users/1234567890/dataTypes/heart-rate`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the
                * [DataPoint
            @@ -299,18 +311,26 @@ public com.google.protobuf.ByteString getFilterBytes() {
                *
                * If empty, data points from all data sources will be reconciled.
                *
            -   * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
                *
            -   * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -   * from all available data sources.
            -   * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +   * The supported values are:
            +   *
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                * Watch). Excludes manually logged data.
            -   * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                * Google data, such as data from tracker devices, manually logged data, and
                * Health Connect.
            -   * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -   * calling client wrote through this API, that is, data points whose data
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
                * source was registered through this API with the same OAuth client ID as
                * the caller.
                *
            @@ -348,18 +368,26 @@ public java.lang.String getDataSourceFamily() {
                *
                * If empty, data points from all data sources will be reconciled.
                *
            -   * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
            +   *
            +   * The supported values are:
                *
            -   * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -   * from all available data sources.
            -   * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                * Watch). Excludes manually logged data.
            -   * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                * Google data, such as data from tracker devices, manually logged data, and
                * Health Connect.
            -   * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -   * calling client wrote through this API, that is, data points whose data
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
                * source was registered through this API with the same OAuth client ID as
                * the caller.
                *
            @@ -810,10 +838,16 @@ public Builder mergeFrom(
                  * 
                  * Required. Parent data type of the Data Point collection.
                  *
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/heart-rate`
            +     * - `users/1234567890/dataTypes/heart-rate`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the
                  * [DataPoint
            @@ -843,10 +877,16 @@ public java.lang.String getParent() {
                  * 
                  * Required. Parent data type of the Data Point collection.
                  *
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/heart-rate`
            +     * - `users/1234567890/dataTypes/heart-rate`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the
                  * [DataPoint
            @@ -876,10 +916,16 @@ public com.google.protobuf.ByteString getParentBytes() {
                  * 
                  * Required. Parent data type of the Data Point collection.
                  *
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/heart-rate`
            +     * - `users/1234567890/dataTypes/heart-rate`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the
                  * [DataPoint
            @@ -908,10 +954,16 @@ public Builder setParent(java.lang.String value) {
                  * 
                  * Required. Parent data type of the Data Point collection.
                  *
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/heart-rate`
            +     * - `users/1234567890/dataTypes/heart-rate`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the
                  * [DataPoint
            @@ -936,10 +988,16 @@ public Builder clearParent() {
                  * 
                  * Required. Parent data type of the Data Point collection.
                  *
            -     * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +     * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/heart-rate`
            +     * - `users/1234567890/dataTypes/heart-rate`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the
                  * [DataPoint
            @@ -1291,18 +1349,26 @@ public Builder setFilterBytes(com.google.protobuf.ByteString value) {
                  *
                  * If empty, data points from all data sources will be reconciled.
                  *
            -     * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
                  *
            -     * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -     * from all available data sources.
            -     * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
            +     *
            +     * The supported values are:
            +     *
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                  * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                  * Watch). Excludes manually logged data.
            -     * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                  * Google data, such as data from tracker devices, manually logged data, and
                  * Health Connect.
            -     * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -     * calling client wrote through this API, that is, data points whose data
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
                  * source was registered through this API with the same OAuth client ID as
                  * the caller.
                  *
            @@ -1339,18 +1405,26 @@ public java.lang.String getDataSourceFamily() {
                  *
                  * If empty, data points from all data sources will be reconciled.
                  *
            -     * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
                  *
            -     * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -     * from all available data sources.
            -     * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +     * The supported values are:
            +     *
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                  * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                  * Watch). Excludes manually logged data.
            -     * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                  * Google data, such as data from tracker devices, manually logged data, and
                  * Health Connect.
            -     * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -     * calling client wrote through this API, that is, data points whose data
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
                  * source was registered through this API with the same OAuth client ID as
                  * the caller.
                  *
            @@ -1387,18 +1461,26 @@ public com.google.protobuf.ByteString getDataSourceFamilyBytes() {
                  *
                  * If empty, data points from all data sources will be reconciled.
                  *
            -     * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
                  *
            -     * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -     * from all available data sources.
            -     * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +     * The supported values are:
            +     *
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                  * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                  * Watch). Excludes manually logged data.
            -     * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                  * Google data, such as data from tracker devices, manually logged data, and
                  * Health Connect.
            -     * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -     * calling client wrote through this API, that is, data points whose data
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
                  * source was registered through this API with the same OAuth client ID as
                  * the caller.
                  *
            @@ -1434,18 +1516,26 @@ public Builder setDataSourceFamily(java.lang.String value) {
                  *
                  * If empty, data points from all data sources will be reconciled.
                  *
            -     * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
            +     *
            +     * The supported values are:
                  *
            -     * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -     * from all available data sources.
            -     * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                  * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                  * Watch). Excludes manually logged data.
            -     * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                  * Google data, such as data from tracker devices, manually logged data, and
                  * Health Connect.
            -     * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -     * calling client wrote through this API, that is, data points whose data
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
                  * source was registered through this API with the same OAuth client ID as
                  * the caller.
                  *
            @@ -1477,18 +1567,26 @@ public Builder clearDataSourceFamily() {
                  *
                  * If empty, data points from all data sources will be reconciled.
                  *
            -     * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
            +     *
            +     * The supported values are:
                  *
            -     * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -     * from all available data sources.
            -     * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                  * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                  * Watch). Excludes manually logged data.
            -     * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                  * Google data, such as data from tracker devices, manually logged data, and
                  * Health Connect.
            -     * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -     * calling client wrote through this API, that is, data points whose data
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
                  * source was registered through this API with the same OAuth client ID as
                  * the caller.
                  *
            diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconcileDataPointsRequestOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconcileDataPointsRequestOrBuilder.java
            index 354de80da02a..d98dbe7d0380 100644
            --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconcileDataPointsRequestOrBuilder.java
            +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconcileDataPointsRequestOrBuilder.java
            @@ -32,10 +32,16 @@ public interface ReconcileDataPointsRequestOrBuilder
                * 
                * Required. Parent data type of the Data Point collection.
                *
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/heart-rate`
            +   * - `users/1234567890/dataTypes/heart-rate`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the
                * [DataPoint
            @@ -55,10 +61,16 @@ public interface ReconcileDataPointsRequestOrBuilder
                * 
                * Required. Parent data type of the Data Point collection.
                *
            -   * Format: `users/me/dataTypes/{data_type}`, e.g.:
            +   * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/heart-rate`
            +   * - `users/1234567890/dataTypes/heart-rate`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the
                * [DataPoint
            @@ -160,18 +172,26 @@ public interface ReconcileDataPointsRequestOrBuilder
                *
                * If empty, data points from all data sources will be reconciled.
                *
            -   * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
                *
            -   * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -   * from all available data sources.
            -   * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +   * The supported values are:
            +   *
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                * Watch). Excludes manually logged data.
            -   * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                * Google data, such as data from tracker devices, manually logged data, and
                * Health Connect.
            -   * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -   * calling client wrote through this API, that is, data points whose data
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
                * source was registered through this API with the same OAuth client ID as
                * the caller.
                *
            @@ -198,18 +218,26 @@ public interface ReconcileDataPointsRequestOrBuilder
                *
                * If empty, data points from all data sources will be reconciled.
                *
            -   * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
            +   *
            +   * The supported values are:
                *
            -   * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -   * from all available data sources.
            -   * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                * Watch). Excludes manually logged data.
            -   * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                * Google data, such as data from tracker devices, manually logged data, and
                * Health Connect.
            -   * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -   * calling client wrote through this API, that is, data points whose data
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
                * source was registered through this API with the same OAuth client ID as
                * the caller.
                *
            diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconciledDataPoint.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconciledDataPoint.java
            index 33035d3ec01a..b7e3096600af 100644
            --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconciledDataPoint.java
            +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconciledDataPoint.java
            @@ -2168,11 +2168,18 @@ public com.google.devicesandservices.health.v4.BloodGlucoseOrBuilder getBloodGlu
                *
                * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}`
                *
            -   * Example:
            -   * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +   * ## Examples:
                *
            -   * The `{user}` ID is a system-generated identifier, as described in
            -   * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id].
            +   * ##
            +   * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +   *
            +   * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, which can be retrieved by calling
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (see
            +   * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]).
                *
                * The `{data_type}` ID corresponds to the kebab-case version of the field
                * names in the [DataPoint
            @@ -2211,11 +2218,18 @@ public java.lang.String getDataPointName() {
                *
                * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}`
                *
            -   * Example:
            -   * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +   * ## Examples:
            +   *
            +   * ##
            +   * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +   *
            +   * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
                *
            -   * The `{user}` ID is a system-generated identifier, as described in
            -   * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id].
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, which can be retrieved by calling
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (see
            +   * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]).
                *
                * The `{data_type}` ID corresponds to the kebab-case version of the field
                * names in the [DataPoint
            @@ -11533,11 +11547,18 @@ public com.google.devicesandservices.health.v4.BloodGlucose.Builder getBloodGluc
                  *
                  * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}`
                  *
            -     * Example:
            -     * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +     * ## Examples:
                  *
            -     * The `{user}` ID is a system-generated identifier, as described in
            -     * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id].
            +     * ##
            +     * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +     *
            +     * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, which can be retrieved by calling
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (see
            +     * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]).
                  *
                  * The `{data_type}` ID corresponds to the kebab-case version of the field
                  * names in the [DataPoint
            @@ -11575,11 +11596,18 @@ public java.lang.String getDataPointName() {
                  *
                  * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}`
                  *
            -     * Example:
            -     * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +     * ## Examples:
            +     *
            +     * ##
            +     * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
                  *
            -     * The `{user}` ID is a system-generated identifier, as described in
            -     * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id].
            +     * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, which can be retrieved by calling
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (see
            +     * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]).
                  *
                  * The `{data_type}` ID corresponds to the kebab-case version of the field
                  * names in the [DataPoint
            @@ -11617,11 +11645,18 @@ public com.google.protobuf.ByteString getDataPointNameBytes() {
                  *
                  * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}`
                  *
            -     * Example:
            -     * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +     * ## Examples:
            +     *
            +     * ##
            +     * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
                  *
            -     * The `{user}` ID is a system-generated identifier, as described in
            -     * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id].
            +     * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, which can be retrieved by calling
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (see
            +     * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]).
                  *
                  * The `{data_type}` ID corresponds to the kebab-case version of the field
                  * names in the [DataPoint
            @@ -11658,11 +11693,18 @@ public Builder setDataPointName(java.lang.String value) {
                  *
                  * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}`
                  *
            -     * Example:
            -     * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +     * ## Examples:
            +     *
            +     * ##
            +     * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
                  *
            -     * The `{user}` ID is a system-generated identifier, as described in
            -     * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id].
            +     * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, which can be retrieved by calling
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (see
            +     * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]).
                  *
                  * The `{data_type}` ID corresponds to the kebab-case version of the field
                  * names in the [DataPoint
            @@ -11695,11 +11737,18 @@ public Builder clearDataPointName() {
                  *
                  * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}`
                  *
            -     * Example:
            -     * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +     * ## Examples:
            +     *
            +     * ##
            +     * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +     *
            +     * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
                  *
            -     * The `{user}` ID is a system-generated identifier, as described in
            -     * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id].
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, which can be retrieved by calling
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (see
            +     * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]).
                  *
                  * The `{data_type}` ID corresponds to the kebab-case version of the field
                  * names in the [DataPoint
            diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconciledDataPointOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconciledDataPointOrBuilder.java
            index 795d75b63e60..18885272e867 100644
            --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconciledDataPointOrBuilder.java
            +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/ReconciledDataPointOrBuilder.java
            @@ -1387,11 +1387,18 @@ public interface ReconciledDataPointOrBuilder
                *
                * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}`
                *
            -   * Example:
            -   * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +   * ## Examples:
                *
            -   * The `{user}` ID is a system-generated identifier, as described in
            -   * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id].
            +   * ##
            +   * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +   *
            +   * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, which can be retrieved by calling
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (see
            +   * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]).
                *
                * The `{data_type}` ID corresponds to the kebab-case version of the field
                * names in the [DataPoint
            @@ -1419,11 +1426,18 @@ public interface ReconciledDataPointOrBuilder
                *
                * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}`
                *
            -   * Example:
            -   * `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +   * ## Examples:
            +   *
            +   * ##
            +   * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
            +   *
            +   * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef`
                *
            -   * The `{user}` ID is a system-generated identifier, as described in
            -   * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id].
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, which can be retrieved by calling
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (see
            +   * [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]).
                *
                * The `{data_type}` ID corresponds to the kebab-case version of the field
                * names in the [DataPoint
            diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/RollUpDataPointsRequest.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/RollUpDataPointsRequest.java
            index a4eb05e00a57..fb149610f929 100644
            --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/RollUpDataPointsRequest.java
            +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/RollUpDataPointsRequest.java
            @@ -87,7 +87,13 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
                * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/distance`
            +   * - `users/1234567890/dataTypes/distance`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the [RollupDataPoint
                * value][google.devicesandservices.health.v4.RollupDataPoint]
            @@ -122,7 +128,13 @@ public java.lang.String getParent() {
                * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/distance`
            +   * - `users/1234567890/dataTypes/distance`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the [RollupDataPoint
                * value][google.devicesandservices.health.v4.RollupDataPoint]
            @@ -365,20 +377,26 @@ public com.google.protobuf.ByteString getPageTokenBytes() {
                *
                * If empty, data points from all available data sources will be rolled up.
                *
            -   * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
                *
                * The supported values are:
                *
            -   * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -   * from all available data sources.
            -   * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                * Watch). Excludes manually logged data.
            -   * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                * Google data, such as data from tracker devices, manually logged data, and
                * Health Connect.
            -   * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -   * calling client wrote through this API, that is, data points whose data
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
                * source was registered through this API with the same OAuth client ID as
                * the caller.
                *
            @@ -416,20 +434,26 @@ public java.lang.String getDataSourceFamily() {
                *
                * If empty, data points from all available data sources will be rolled up.
                *
            -   * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
                *
                * The supported values are:
                *
            -   * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -   * from all available data sources.
            -   * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                * Watch). Excludes manually logged data.
            -   * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                * Google data, such as data from tracker devices, manually logged data, and
                * Health Connect.
            -   * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -   * calling client wrote through this API, that is, data points whose data
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
                * source was registered through this API with the same OAuth client ID as
                * the caller.
                *
            @@ -932,7 +956,13 @@ public Builder mergeFrom(
                  * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/distance`
            +     * - `users/1234567890/dataTypes/distance`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the [RollupDataPoint
                  * value][google.devicesandservices.health.v4.RollupDataPoint]
            @@ -966,7 +996,13 @@ public java.lang.String getParent() {
                  * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/distance`
            +     * - `users/1234567890/dataTypes/distance`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the [RollupDataPoint
                  * value][google.devicesandservices.health.v4.RollupDataPoint]
            @@ -1000,7 +1036,13 @@ public com.google.protobuf.ByteString getParentBytes() {
                  * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/distance`
            +     * - `users/1234567890/dataTypes/distance`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the [RollupDataPoint
                  * value][google.devicesandservices.health.v4.RollupDataPoint]
            @@ -1033,7 +1075,13 @@ public Builder setParent(java.lang.String value) {
                  * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/distance`
            +     * - `users/1234567890/dataTypes/distance`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the [RollupDataPoint
                  * value][google.devicesandservices.health.v4.RollupDataPoint]
            @@ -1062,7 +1110,13 @@ public Builder clearParent() {
                  * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                  *
                  * - `users/me/dataTypes/steps`
            +     * - `users/1234567890/dataTypes/steps`
                  * - `users/me/dataTypes/distance`
            +     * - `users/1234567890/dataTypes/distance`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID (retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                  *
                  * For a list of the supported data types see the [RollupDataPoint
                  * value][google.devicesandservices.health.v4.RollupDataPoint]
            @@ -1747,20 +1801,26 @@ public Builder setPageTokenBytes(com.google.protobuf.ByteString value) {
                  *
                  * If empty, data points from all available data sources will be rolled up.
                  *
            -     * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
                  *
                  * The supported values are:
                  *
            -     * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -     * from all available data sources.
            -     * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                  * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                  * Watch). Excludes manually logged data.
            -     * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                  * Google data, such as data from tracker devices, manually logged data, and
                  * Health Connect.
            -     * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -     * calling client wrote through this API, that is, data points whose data
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
                  * source was registered through this API with the same OAuth client ID as
                  * the caller.
                  *
            @@ -1797,20 +1857,26 @@ public java.lang.String getDataSourceFamily() {
                  *
                  * If empty, data points from all available data sources will be rolled up.
                  *
            -     * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
                  *
                  * The supported values are:
                  *
            -     * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -     * from all available data sources.
            -     * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                  * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                  * Watch). Excludes manually logged data.
            -     * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                  * Google data, such as data from tracker devices, manually logged data, and
                  * Health Connect.
            -     * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -     * calling client wrote through this API, that is, data points whose data
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
                  * source was registered through this API with the same OAuth client ID as
                  * the caller.
                  *
            @@ -1847,20 +1913,26 @@ public com.google.protobuf.ByteString getDataSourceFamilyBytes() {
                  *
                  * If empty, data points from all available data sources will be rolled up.
                  *
            -     * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
                  *
                  * The supported values are:
                  *
            -     * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -     * from all available data sources.
            -     * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                  * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                  * Watch). Excludes manually logged data.
            -     * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                  * Google data, such as data from tracker devices, manually logged data, and
                  * Health Connect.
            -     * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -     * calling client wrote through this API, that is, data points whose data
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
                  * source was registered through this API with the same OAuth client ID as
                  * the caller.
                  *
            @@ -1896,20 +1968,26 @@ public Builder setDataSourceFamily(java.lang.String value) {
                  *
                  * If empty, data points from all available data sources will be rolled up.
                  *
            -     * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
                  *
                  * The supported values are:
                  *
            -     * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -     * from all available data sources.
            -     * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                  * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                  * Watch). Excludes manually logged data.
            -     * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                  * Google data, such as data from tracker devices, manually logged data, and
                  * Health Connect.
            -     * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -     * calling client wrote through this API, that is, data points whose data
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
                  * source was registered through this API with the same OAuth client ID as
                  * the caller.
                  *
            @@ -1941,20 +2019,26 @@ public Builder clearDataSourceFamily() {
                  *
                  * If empty, data points from all available data sources will be rolled up.
                  *
            -     * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +     * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +     *
            +     * The `{user}` can be either the alias `me` or the authenticated user's
            +     * numeric Health User ID, retrieved via
            +     * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +     * (e.g. `users/me/dataSourceFamilies/...` or
            +     * `users/1234567890/dataSourceFamilies/...`).
                  *
                  * The supported values are:
                  *
            -     * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -     * from all available data sources.
            -     * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +     * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +     * data from all available data sources.
            +     * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                  * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                  * Watch). Excludes manually logged data.
            -     * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +     * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                  * Google data, such as data from tracker devices, manually logged data, and
                  * Health Connect.
            -     * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -     * calling client wrote through this API, that is, data points whose data
            +     * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +     * the calling client wrote through this API, that is, data points whose data
                  * source was registered through this API with the same OAuth client ID as
                  * the caller.
                  *
            diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/RollUpDataPointsRequestOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/RollUpDataPointsRequestOrBuilder.java
            index 69f5c672a4bb..bac339d47282 100644
            --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/RollUpDataPointsRequestOrBuilder.java
            +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/RollUpDataPointsRequestOrBuilder.java
            @@ -35,7 +35,13 @@ public interface RollUpDataPointsRequestOrBuilder
                * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/distance`
            +   * - `users/1234567890/dataTypes/distance`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the [RollupDataPoint
                * value][google.devicesandservices.health.v4.RollupDataPoint]
            @@ -59,7 +65,13 @@ public interface RollUpDataPointsRequestOrBuilder
                * Format: `users/{user}/dataTypes/{data_type}`, e.g.:
                *
                * - `users/me/dataTypes/steps`
            +   * - `users/1234567890/dataTypes/steps`
                * - `users/me/dataTypes/distance`
            +   * - `users/1234567890/dataTypes/distance`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID (retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]).
                *
                * For a list of the supported data types see the [RollupDataPoint
                * value][google.devicesandservices.health.v4.RollupDataPoint]
            @@ -229,20 +241,26 @@ public interface RollUpDataPointsRequestOrBuilder
                *
                * If empty, data points from all available data sources will be rolled up.
                *
            -   * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
                *
                * The supported values are:
                *
            -   * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -   * from all available data sources.
            -   * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                * Watch). Excludes manually logged data.
            -   * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                * Google data, such as data from tracker devices, manually logged data, and
                * Health Connect.
            -   * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -   * calling client wrote through this API, that is, data points whose data
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
                * source was registered through this API with the same OAuth client ID as
                * the caller.
                *
            @@ -269,20 +287,26 @@ public interface RollUpDataPointsRequestOrBuilder
                *
                * If empty, data points from all available data sources will be rolled up.
                *
            -   * Format: `users/me/dataSourceFamilies/{data_source_family}`
            +   * Format: `users/{user}/dataSourceFamilies/{data_source_family}`
            +   *
            +   * The `{user}` can be either the alias `me` or the authenticated user's
            +   * numeric Health User ID, retrieved via
            +   * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]
            +   * (e.g. `users/me/dataSourceFamilies/...` or
            +   * `users/1234567890/dataSourceFamilies/...`).
                *
                * The supported values are:
                *
            -   * - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data
            -   * from all available data sources.
            -   * - `users/me/dataSourceFamilies/google-wearables` - Includes data from
            +   * - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes
            +   * data from all available data sources.
            +   * - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from
                * Google and Fitbit tracker devices (such as Fitbit trackers and Pixel
                * Watch). Excludes manually logged data.
            -   * - `users/me/dataSourceFamilies/google-sources` - Includes first-party
            +   * - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party
                * Google data, such as data from tracker devices, manually logged data, and
                * Health Connect.
            -   * - `users/me/dataSourceFamilies/self-sources` - Includes only the data the
            -   * calling client wrote through this API, that is, data points whose data
            +   * - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data
            +   * the calling client wrote through this API, that is, data points whose data
                * source was registered through this API with the same OAuth client ID as
                * the caller.
                *
            diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/Symptoms.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/Symptoms.java
            index 0795f26354b8..d57d773a4cea 100644
            --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/Symptoms.java
            +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/Symptoms.java
            @@ -740,6 +740,36 @@ public enum SymptomValue implements com.google.protobuf.ProtocolMessageEnum {
                  * VOMITING = 65;
                  */
                 VOMITING(65),
            +    /**
            +     *
            +     *
            +     * 
            +     * Swelling of the arms or legs.
            +     * 
            + * + * LIMBS_SWELLING = 76; + */ + LIMBS_SWELLING(76), + /** + * + * + *
            +     * Swelling of the face.
            +     * 
            + * + * FACE_SWELLING = 77; + */ + FACE_SWELLING(77), + /** + * + * + *
            +     * Nasal congestion.
            +     * 
            + * + * NASAL_CONGESTION = 78; + */ + NASAL_CONGESTION(78), UNRECOGNIZED(-1), ; @@ -1479,6 +1509,39 @@ public enum SymptomValue implements com.google.protobuf.ProtocolMessageEnum { */ public static final int VOMITING_VALUE = 65; + /** + * + * + *
            +     * Swelling of the arms or legs.
            +     * 
            + * + * LIMBS_SWELLING = 76; + */ + public static final int LIMBS_SWELLING_VALUE = 76; + + /** + * + * + *
            +     * Swelling of the face.
            +     * 
            + * + * FACE_SWELLING = 77; + */ + public static final int FACE_SWELLING_VALUE = 77; + + /** + * + * + *
            +     * Nasal congestion.
            +     * 
            + * + * NASAL_CONGESTION = 78; + */ + public static final int NASAL_CONGESTION_VALUE = 78; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -1635,6 +1698,12 @@ public static SymptomValue forNumber(int value) { return VAGINAL_ITCHING; case 65: return VOMITING; + case 76: + return LIMBS_SWELLING; + case 77: + return FACE_SWELLING; + case 78: + return NASAL_CONGESTION; default: return null; } diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/UpdateDataPointRequest.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/UpdateDataPointRequest.java index d90b4222ee17..229b238f4944 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/UpdateDataPointRequest.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/UpdateDataPointRequest.java @@ -81,6 +81,17 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -103,6 +114,17 @@ public boolean hasDataPoint() { * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -127,6 +149,17 @@ public com.google.devicesandservices.health.v4.DataPoint getDataPoint() { * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -490,6 +523,17 @@ public Builder mergeFrom( * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -511,6 +555,17 @@ public boolean hasDataPoint() { * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -538,6 +593,17 @@ public com.google.devicesandservices.health.v4.DataPoint getDataPoint() { * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -567,6 +633,17 @@ public Builder setDataPoint(com.google.devicesandservices.health.v4.DataPoint va * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -594,6 +671,17 @@ public Builder setDataPoint( * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -629,6 +717,17 @@ public Builder mergeDataPoint(com.google.devicesandservices.health.v4.DataPoint * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -655,6 +754,17 @@ public Builder clearDataPoint() { * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -676,6 +786,17 @@ public com.google.devicesandservices.health.v4.DataPoint.Builder getDataPointBui * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -701,6 +822,17 @@ public com.google.devicesandservices.health.v4.DataPointOrBuilder getDataPointOr * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * diff --git a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/UpdateDataPointRequestOrBuilder.java b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/UpdateDataPointRequestOrBuilder.java index 6884df1412d6..8a123068ea48 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/UpdateDataPointRequestOrBuilder.java +++ b/java-health/proto-google-cloud-health-v4/src/main/java/com/google/devicesandservices/health/v4/UpdateDataPointRequestOrBuilder.java @@ -35,6 +35,17 @@ public interface UpdateDataPointRequestOrBuilder * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -54,6 +65,17 @@ public interface UpdateDataPointRequestOrBuilder * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * @@ -73,6 +95,17 @@ public interface UpdateDataPointRequestOrBuilder * The data point's `name` field is used to identify the data point to update. * * Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + * + * ## Examples: + * + * ## + * `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + * + * The `{user}` can be either the alias `me` or the authenticated user's + * numeric Health User ID (retrieved via + * [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). *
            * * diff --git a/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/data_model.proto b/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/data_model.proto index 29e63ccfd083..68300f8bf5dc 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/data_model.proto +++ b/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/data_model.proto @@ -318,6 +318,9 @@ enum OvulationTestResult { // Indeterminate result. INDETERMINATE = 5; + + // Ovulation day the user identified by their own method, not a test kit. + OWN_METHOD = 6; } // Record of active zone minutes in a given time interval. @@ -2920,12 +2923,30 @@ message MenstrualPeriod { // Ovulation test record. message OvulationTest { + // Ovulation test type. + enum TestType { + // Unspecified test type. + TEST_TYPE_UNSPECIFIED = 0; + + // Test strip. + STRIP = 1; + + // Digital test. + DIGITAL = 2; + + // The user's own method, not a test kit. + OWN_METHOD = 3; + } + // Required. The time at which ovulation test was measured. ObservationSampleTime sample_time = 2 [(google.api.field_behavior) = REQUIRED]; // Required. The result of the ovulation test. OvulationTestResult result = 3 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The type of ovulation test. + TestType test_type = 4 [(google.api.field_behavior) = OPTIONAL]; } // Symptoms logged by the user. @@ -3129,6 +3150,15 @@ message Symptoms { // Vomiting. VOMITING = 65; + + // Swelling of the arms or legs. + LIMBS_SWELLING = 76; + + // Swelling of the face. + FACE_SWELLING = 77; + + // Nasal congestion. + NASAL_CONGESTION = 78; } // Required. Time when the symptoms were logged. diff --git a/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/data_points.proto b/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/data_points.proto index 22aa949be4ea..65f1b2a0a806 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/data_points.proto +++ b/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/data_points.proto @@ -44,8 +44,10 @@ service DataPointsService { option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly," "https://www.googleapis.com/auth/googlehealth.activity_and_fitness.writeonly," + "https://www.googleapis.com/auth/googlehealth.ecg.readonly," "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.readonly," "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.writeonly," + "https://www.googleapis.com/auth/googlehealth.irn.readonly," "https://www.googleapis.com/auth/googlehealth.location.readonly," "https://www.googleapis.com/auth/googlehealth.logged_symptoms.readonly," "https://www.googleapis.com/auth/googlehealth.logged_symptoms.writeonly," @@ -146,9 +148,13 @@ service DataPointsService { // **IMPORTANT:** HTTP clients must append `?alt=media` to the // request URL to download the raw TCX file. // - // Example: + // ## Examples: + // + // ## // `https://health.googleapis.com/v4/users/me/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` // + // `https://health.googleapis.com/v4/users/1234567890/dataTypes/exercise/dataPoints/EXERCISE_ID:exportExerciseTcx?alt=media` + // // Without `alt=media`, the server returns a JSON response // (`ExportExerciseTcxResponse`) // which is intended primarily for gRPC clients. @@ -369,11 +375,18 @@ message DataPoint { // // Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` // - // Example: - // `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + // ## Examples: + // + // ## + // `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` // - // The `{user}` ID is a system-generated identifier, as described in - // [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]. + // `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID, which can be retrieved by calling + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + // (see + // [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]). // // The `{data_type}` ID corresponds to the kebab-case version of the field // names in the [DataPoint @@ -522,11 +535,18 @@ message ReconciledDataPoint { // // Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` // - // Example: - // `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + // ## Examples: + // + // ## + // `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` // - // The `{user}` ID is a system-generated identifier, as described in - // [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]. + // `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID, which can be retrieved by calling + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + // (see + // [Identity.health_user_id][google.devicesandservices.health.v4.Identity.health_user_id]). // // The `{data_type}` ID corresponds to the kebab-case version of the field // names in the [DataPoint @@ -827,6 +847,17 @@ message GetDataPointRequest { // // Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` // + // ## Examples: + // + // ## + // `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + // + // `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID (retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). + // // See // [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] // for examples and possible values. @@ -842,10 +873,16 @@ message GetDataPointRequest { message ListDataPointsRequest { // Required. Parent data type of the Data Point collection. // - // Format: `users/me/dataTypes/{data_type}`, e.g.: + // Format: `users/{user}/dataTypes/{data_type}`, e.g.: // // - `users/me/dataTypes/steps` + // - `users/1234567890/dataTypes/steps` // - `users/me/dataTypes/weight` + // - `users/1234567890/dataTypes/weight` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID (retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). // // For a list of the supported data types see the [DataPoint // data][google.devicesandservices.health.v4.DataPoint] union @@ -970,6 +1007,51 @@ message ListDataPointsRequest { // Data points in the response will be ordered by the interval start time in // descending order. string filter = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The data source family name to filter by. + // + // If empty, data points from all available data sources will be returned. + // + // Format: `users/{user}/dataSourceFamilies/{data_source_family}` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID, retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + // (e.g. `users/me/dataSourceFamilies/...` or + // `users/1234567890/dataSourceFamilies/...`). + // + // The supported values are: + // + // - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + // data from all available data sources. + // - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from + // Google and Fitbit tracker devices (such as Fitbit trackers and Pixel + // Watch). Excludes manually logged data. + // - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party + // Google data, such as data from tracker devices, manually logged data, and + // Health Connect. + // - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + // the calling client wrote through this API, that is, data points whose data + // source was registered through this API with the same OAuth client ID as + // the caller. + // + // Callers that were only granted write scopes for the requested data types + // may only read the data they wrote themselves: their requests are + // implicitly restricted to `self-sources`, and requesting any other data + // source family fails with `PERMISSION_DENIED`. + // + // If no data point matches the requested data source family, the response is + // an empty list rather than an error. + // + // Filtering by data source family is not supported for the `sleep`, `food` + // and `food-measurement-unit` data types, because the underlying listing + // implementation cannot restrict results by data source. Such requests fail + // with `INVALID_ARGUMENT` when the data source family is set explicitly, and + // with `PERMISSION_DENIED` when the restriction is only implied by the + // caller's scopes. For `sleep`, use + // [ReconcileDataPoints][google.devicesandservices.health.v4.DataPointsService.ReconcileDataPoints] + // instead. + string data_source_family = 5 [(google.api.field_behavior) = OPTIONAL]; } // Response containing raw data points matching the query @@ -984,7 +1066,15 @@ message ListDataPointsResponse { // Request to create an identifiable data point. message CreateDataPointRequest { // Required. The parent resource name where the data point will be created. - // Format: `users/{user}/dataTypes/{data_type}` + // + // Format: `users/{user}/dataTypes/{data_type}`, e.g.: + // + // - `users/me/dataTypes/steps` + // - `users/1234567890/dataTypes/steps` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID (retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -1006,6 +1096,17 @@ message UpdateDataPointRequest { // The data point's `name` field is used to identify the data point to update. // // Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` + // + // ## Examples: + // + // ## + // `users/me/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + // + // `users/1234567890/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID (retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). DataPoint data_point = 1 [(google.api.field_behavior) = REQUIRED]; } @@ -1015,10 +1116,17 @@ message UpdateDataPointOperationMetadata {} // Request to delete a batch of identifiable data points. message BatchDeleteDataPointsRequest { // Optional. Parent (data type) for the Data Point collection - // Format: `users/me/dataTypes/{data_type}`, e.g.: + // + // Format: `users/{user}/dataTypes/{data_type}`, e.g.: // // - `users/me/dataTypes/steps` + // - `users/1234567890/dataTypes/steps` // - `users/me/dataTypes/-` + // - `users/1234567890/dataTypes/-` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID (retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). // // For a list of the supported data types see the // [DataPoint @@ -1063,10 +1171,16 @@ message BatchDeleteDataPointsOperationMetadata { message ReconcileDataPointsRequest { // Required. Parent data type of the Data Point collection. // - // Format: `users/me/dataTypes/{data_type}`, e.g.: + // Format: `users/{user}/dataTypes/{data_type}`, e.g.: // // - `users/me/dataTypes/steps` + // - `users/1234567890/dataTypes/steps` // - `users/me/dataTypes/heart-rate` + // - `users/1234567890/dataTypes/heart-rate` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID (retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). // // For a list of the supported data types see the // [DataPoint @@ -1097,18 +1211,26 @@ message ReconcileDataPointsRequest { // // If empty, data points from all data sources will be reconciled. // - // Format: `users/me/dataSourceFamilies/{data_source_family}` + // Format: `users/{user}/dataSourceFamilies/{data_source_family}` // - // - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - // from all available data sources. - // - `users/me/dataSourceFamilies/google-wearables` - Includes data from + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID, retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + // (e.g. `users/me/dataSourceFamilies/...` or + // `users/1234567890/dataSourceFamilies/...`). + // + // The supported values are: + // + // - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + // data from all available data sources. + // - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from // Google and Fitbit tracker devices (such as Fitbit trackers and Pixel // Watch). Excludes manually logged data. - // - `users/me/dataSourceFamilies/google-sources` - Includes first-party + // - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party // Google data, such as data from tracker devices, manually logged data, and // Health Connect. - // - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - // calling client wrote through this API, that is, data points whose data + // - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + // the calling client wrote through this API, that is, data points whose data // source was registered through this API with the same OAuth client ID as // the caller. // @@ -1138,7 +1260,13 @@ message RollUpDataPointsRequest { // Format: `users/{user}/dataTypes/{data_type}`, e.g.: // // - `users/me/dataTypes/steps` + // - `users/1234567890/dataTypes/steps` // - `users/me/dataTypes/distance` + // - `users/1234567890/dataTypes/distance` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID (retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). // // For a list of the supported data types see the [RollupDataPoint // value][google.devicesandservices.health.v4.RollupDataPoint] @@ -1178,20 +1306,26 @@ message RollUpDataPointsRequest { // // If empty, data points from all available data sources will be rolled up. // - // Format: `users/me/dataSourceFamilies/{data_source_family}` + // Format: `users/{user}/dataSourceFamilies/{data_source_family}` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID, retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + // (e.g. `users/me/dataSourceFamilies/...` or + // `users/1234567890/dataSourceFamilies/...`). // // The supported values are: // - // - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - // from all available data sources. - // - `users/me/dataSourceFamilies/google-wearables` - Includes data from + // - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + // data from all available data sources. + // - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from // Google and Fitbit tracker devices (such as Fitbit trackers and Pixel // Watch). Excludes manually logged data. - // - `users/me/dataSourceFamilies/google-sources` - Includes first-party + // - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party // Google data, such as data from tracker devices, manually logged data, and // Health Connect. - // - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - // calling client wrote through this API, that is, data points whose data + // - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + // the calling client wrote through this API, that is, data points whose data // source was registered through this API with the same OAuth client ID as // the caller. // @@ -1222,7 +1356,13 @@ message DailyRollUpDataPointsRequest { // Format: `users/{user}/dataTypes/{data_type}`, e.g.: // // - `users/me/dataTypes/steps` + // - `users/1234567890/dataTypes/steps` // - `users/me/dataTypes/distance` + // - `users/1234567890/dataTypes/distance` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID (retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). // // For a list of the supported data types see the [DailyRollupDataPoint // value][google.devicesandservices.health.v4.DailyRollupDataPoint] @@ -1248,12 +1388,13 @@ message DailyRollUpDataPointsRequest { int32 window_size_days = 3 [(google.api.field_behavior) = OPTIONAL]; // Optional. The maximum number of data points to return. - // If unspecified, at most 1440 data points will be returned. - // The maximum page size is 10000; values above that will be truncated - // accordingly. + // If unspecified, at most `90` data points will be returned. + // The maximum page size is `90`. + // For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and + // `total-calories`, the default and maximum page size is `14`. int32 page_size = 4 [(google.api.field_behavior) = OPTIONAL]; - // Optional. The `next_page_token` from a previous request, if any. + // Optional. The next_page_token from a previous request, if any. // All other request fields need to be the same as in the initial request // when the page token is specified. string page_token = 5 [(google.api.field_behavior) = OPTIONAL]; @@ -1261,20 +1402,26 @@ message DailyRollUpDataPointsRequest { // Optional. The data source family name to roll up. // If empty, data points from all available data sources will be rolled up. // - // Format: `users/me/dataSourceFamilies/{data_source_family}` + // Format: `users/{user}/dataSourceFamilies/{data_source_family}` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID, retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity] + // (e.g. `users/me/dataSourceFamilies/...` or + // `users/1234567890/dataSourceFamilies/...`). // // The supported values are: // - // - `users/me/dataSourceFamilies/all-sources` - Default value. Includes data - // from all available data sources. - // - `users/me/dataSourceFamilies/google-wearables` - Includes data from + // - `users/{user}/dataSourceFamilies/all-sources` - Default value. Includes + // data from all available data sources. + // - `users/{user}/dataSourceFamilies/google-wearables` - Includes data from // Google and Fitbit tracker devices (such as Fitbit trackers and Pixel // Watch). Excludes manually logged data. - // - `users/me/dataSourceFamilies/google-sources` - Includes first-party + // - `users/{user}/dataSourceFamilies/google-sources` - Includes first-party // Google data, such as data from tracker devices, manually logged data, and // Health Connect. - // - `users/me/dataSourceFamilies/self-sources` - Includes only the data the - // calling client wrote through this API, that is, data points whose data + // - `users/{user}/dataSourceFamilies/self-sources` - Includes only the data + // the calling client wrote through this API, that is, data points whose data // source was registered through this API with the same OAuth client ID as // the caller. // @@ -1292,6 +1439,10 @@ message DailyRollUpDataPointsRequest { message DailyRollUpDataPointsResponse { // Values for each aggregation time window. repeated DailyRollupDataPoint rollup_data_points = 1; + + // A token, which can be sent as `page_token` to retrieve the next page. + // If this field is omitted, there are no subsequent pages. + string next_page_token = 2; } // Represents a type of health data a user can have data points recorded for. @@ -1309,7 +1460,14 @@ message DataType { // Identifier. The resource name of the data type. // - // Format: `users/{user}/dataTypes/{data_type}` + // Format: `users/{user}/dataTypes/{data_type}`, e.g.: + // + // - `users/me/dataTypes/steps` + // - `users/1234567890/dataTypes/steps` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID (retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). // // See // [DataPoint.name][google.devicesandservices.health.v4.DataPoint.name] @@ -1322,10 +1480,14 @@ message ExportExerciseTcxRequest { // Required. The resource name of the exercise data point to export. // // Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` - // Example: `users/me/dataTypes/exercise/dataPoints/2026443605080188808` // - // The `{user}` is the alias `"me"` currently. Future versions may support - // user IDs. + // Examples: + // - `users/me/dataTypes/exercise/dataPoints/2026443605080188808` + // - `users/1234567890/dataTypes/exercise/dataPoints/2026443605080188808` + // + // The `{user}` can be either the alias `me` or the authenticated user's + // numeric Health User ID (retrieved via + // [GetIdentity][google.devicesandservices.health.v4.HealthProfileService.GetIdentity]). // The `{data_point}` ID maps to the exercise ID, which is a long integer. string name = 1 [ (google.api.field_behavior) = REQUIRED, diff --git a/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/health_profile.proto b/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/health_profile.proto index f0ddc0dcf295..7db847ec140d 100644 --- a/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/health_profile.proto +++ b/java-health/proto-google-cloud-health-v4/src/main/proto/google/devicesandservices/health/v4/health_profile.proto @@ -38,17 +38,25 @@ service HealthProfileService { option (google.api.default_host) = "health.googleapis.com"; option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly," + "https://www.googleapis.com/auth/googlehealth.activity_and_fitness.writeonly," "https://www.googleapis.com/auth/googlehealth.ecg.readonly," "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.readonly," + "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.writeonly," "https://www.googleapis.com/auth/googlehealth.irn.readonly," + "https://www.googleapis.com/auth/googlehealth.location.readonly," "https://www.googleapis.com/auth/googlehealth.logged_symptoms.readonly," + "https://www.googleapis.com/auth/googlehealth.logged_symptoms.writeonly," "https://www.googleapis.com/auth/googlehealth.mindfulness.readonly," + "https://www.googleapis.com/auth/googlehealth.mindfulness.writeonly," + "https://www.googleapis.com/auth/googlehealth.nutrition.writeonly," "https://www.googleapis.com/auth/googlehealth.profile.readonly," "https://www.googleapis.com/auth/googlehealth.profile.writeonly," "https://www.googleapis.com/auth/googlehealth.reproductive_health.readonly," + "https://www.googleapis.com/auth/googlehealth.reproductive_health.writeonly," "https://www.googleapis.com/auth/googlehealth.settings.readonly," "https://www.googleapis.com/auth/googlehealth.settings.writeonly," - "https://www.googleapis.com/auth/googlehealth.sleep.readonly"; + "https://www.googleapis.com/auth/googlehealth.sleep.readonly," + "https://www.googleapis.com/auth/googlehealth.sleep.writeonly"; // Returns user Profile details. rpc GetProfile(GetProfileRequest) returns (Profile) { diff --git a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DailyRollUpDataPointsRequest.java b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DailyRollUpDataPointsRequest.java index e7385ff9363d..dcd7ad8eed13 100644 --- a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DailyRollUpDataPointsRequest.java +++ b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DailyRollUpDataPointsRequest.java @@ -264,9 +264,10 @@ public int getWindowSizeDays() { * *
                * Optional. The maximum number of data points to return.
            -   * If unspecified, at most 1440 data points will be returned.
            -   * The maximum page size is 10000; values above that will be truncated
            -   * accordingly.
            +   * If unspecified, at most `90` data points will be returned.
            +   * The maximum page size is `90`.
            +   * For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and
            +   * `total-calories`, the default and maximum page size is `14`.
                * 
            * * int32 page_size = 4 [(.google.api.field_behavior) = OPTIONAL]; @@ -1436,9 +1437,10 @@ public Builder clearWindowSizeDays() { * *
                  * Optional. The maximum number of data points to return.
            -     * If unspecified, at most 1440 data points will be returned.
            -     * The maximum page size is 10000; values above that will be truncated
            -     * accordingly.
            +     * If unspecified, at most `90` data points will be returned.
            +     * The maximum page size is `90`.
            +     * For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and
            +     * `total-calories`, the default and maximum page size is `14`.
                  * 
            * * int32 page_size = 4 [(.google.api.field_behavior) = OPTIONAL]; @@ -1455,9 +1457,10 @@ public int getPageSize() { * *
                  * Optional. The maximum number of data points to return.
            -     * If unspecified, at most 1440 data points will be returned.
            -     * The maximum page size is 10000; values above that will be truncated
            -     * accordingly.
            +     * If unspecified, at most `90` data points will be returned.
            +     * The maximum page size is `90`.
            +     * For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and
            +     * `total-calories`, the default and maximum page size is `14`.
                  * 
            * * int32 page_size = 4 [(.google.api.field_behavior) = OPTIONAL]; @@ -1478,9 +1481,10 @@ public Builder setPageSize(int value) { * *
                  * Optional. The maximum number of data points to return.
            -     * If unspecified, at most 1440 data points will be returned.
            -     * The maximum page size is 10000; values above that will be truncated
            -     * accordingly.
            +     * If unspecified, at most `90` data points will be returned.
            +     * The maximum page size is `90`.
            +     * For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and
            +     * `total-calories`, the default and maximum page size is `14`.
                  * 
            * * int32 page_size = 4 [(.google.api.field_behavior) = OPTIONAL]; diff --git a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DailyRollUpDataPointsRequestOrBuilder.java b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DailyRollUpDataPointsRequestOrBuilder.java index 9b03442875d1..ebdc576f663c 100644 --- a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DailyRollUpDataPointsRequestOrBuilder.java +++ b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DailyRollUpDataPointsRequestOrBuilder.java @@ -164,9 +164,10 @@ public interface DailyRollUpDataPointsRequestOrBuilder * *
                * Optional. The maximum number of data points to return.
            -   * If unspecified, at most 1440 data points will be returned.
            -   * The maximum page size is 10000; values above that will be truncated
            -   * accordingly.
            +   * If unspecified, at most `90` data points will be returned.
            +   * The maximum page size is `90`.
            +   * For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and
            +   * `total-calories`, the default and maximum page size is `14`.
                * 
            * * int32 page_size = 4 [(.google.api.field_behavior) = OPTIONAL]; diff --git a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DataModelProto.java b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DataModelProto.java index 03667bb692d1..53974d6e9646 100644 --- a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DataModelProto.java +++ b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/DataModelProto.java @@ -1533,17 +1533,25 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\017MenstrualPeriod\022X\n" + "\010interval\030\002 \001(\0132@.google.devic" + "esandservices.health.v4beta.ObservationTimeIntervalB\004\342A\001\002\022\023\n" - + "\005notes\030\004 \001(\tB\004\342A\001\001\"\276\001\n\r" + + "\005notes\030\004 \001(\tB\004\342A\001\001\"\347\002\n\r" + "OvulationTest\022Y\n" + "\013sample_time\030\002 \001(\0132>." + "google.devicesandservices.health.v4beta.ObservationSampleTimeB\004\342A\001\002\022R\n" + "\006result\030\003 " - + "\001(\0162<.google.devicesandservices.health.v4beta.OvulationTestResultB\004\342A\001\002\"\261\n\n" + + "\001(\0162<.google.devicesandservices.health.v4beta.OvulationTestResultB\004\342A\001\002\022X\n" + + "\ttest_type\030\004 \001(\0162?.google.devicesandservices.h", + "ealth.v4beta.OvulationTest.TestTypeB\004\342A\001\001\"M\n" + + "\010TestType\022\031\n" + + "\025TEST_TYPE_UNSPECIFIED\020\000\022\t\n" + + "\005STRIP\020\001\022\013\n" + + "\007DIGITAL\020\002\022\016\n\n" + + "OWN_METHOD\020\003\"\356\n\n" + "\010Symptoms\022Y\n" - + "\013sample_time\030\001 \001(\0132>.google.devic", - "esandservices.health.v4beta.ObservationSampleTimeB\004\342A\001\002\022V\n" - + "\010symptoms\030\002 \003(\0162>.goog" - + "le.devicesandservices.health.v4beta.Symptoms.SymptomValueB\004\342A\001\002\"\361\010\n" + + "\013sample_time\030\001 \001(\0132>.goo" + + "gle.devicesandservices.health.v4beta.ObservationSampleTimeB\004\342A\001\002\022V\n" + + "\010symptoms\030\002 \003" + + "(\0162>.google.devicesandservices.health.v4beta.Symptoms.SymptomValueB\004\342A\001\002\"\256" + + "\t\n" + "\014SymptomValue\022\035\n" + "\031SYMPTOM_VALUE_UNSPECIFIED\020\000\022\n\n" + "\006CRAMPS\020\001\022\014\n" @@ -1578,8 +1586,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tCONFUSION\020\034\022\r\n" + "\tDIZZINESS\020\035\022\022\n" + "\016ABDOMINAL_PAIN\020\036\022\021\n\r" - + "BLADDER_LEAKS\020\037\022\021\n" - + "\r" + + "BLADDER_LEAKS\020\037\022\021\n\r" + "BLEEDING_GUMS\020 \022\r\n" + "\tBRAIN_FOG\020!\022\021\n\r" + "BURNING_MOUTH\020\"\022\020\n" @@ -1613,14 +1620,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010SWELLING\020>\022\023\n" + "\017VAGINAL_DRYNESS\020?\022\023\n" + "\017VAGINAL_ITCHING\020@\022\014\n" - + "\010VOMITING\020A\"\237\n\n" + + "\010VOMITING\020A\022\022\n" + + "\016LIMBS_SWELLING\020L\022\021\n\r" + + "FACE_SWELLING\020M\022\024\n" + + "\020NASAL_CONGESTION\020N\"\237\n\n" + "\005Moods\022Y\n" - + "\013sample_time\030\002 \001(\0132>.goo" - + "gle.devicesandservices.health.v4beta.ObservationSampleTimeB\004\342A\001\002\022H\n" - + "\005moods\030\003 \003(\0162" - + "3.google.devicesandservices.health.v4beta.Moods.MoodB\004\342A\001\002\022N\n" - + "\010valences\030\005 \003(\01626.g" - + "oogle.devicesandservices.health.v4beta.Moods.ValenceB\004\342A\001\001\"\320\007\n" + + "\013sample_time\030\002 \001(\0132>.google.device" + + "sandservices.health.v4beta.ObservationSampleTimeB\004\342A\001\002\022H\n" + + "\005moods\030\003 \003(\01623.google.d" + + "evicesandservices.health.v4beta.Moods.MoodB\004\342A\001\002\022N\n" + + "\010valences\030\005 \003(\01626.google.devi" + + "cesandservices.health.v4beta.Moods.ValenceB\004\342A\001\001\"\320\007\n" + "\004Mood\022\024\n" + "\020MOOD_UNSPECIFIED\020\000\022\n\n" + "\006AMAZED\020\001\022\n\n" @@ -1650,12 +1660,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006GUILTY\020\027\022\013\n" + "\007HOPEFUL\020\030\022\014\n" + "\010HOPELESS\020\031\022\017\n" - + "\013INDIFFERENT\020\032\022\r" - + "\n" + + "\013INDIFFERENT\020\032\022\r\n" + "\tIRRITATED\020\033\022\013\n" + "\007JEALOUS\020\034\022\n\n" - + "\006JOYFUL\020\035\022\n" - + "\n" + + "\006JOYFUL\020\035\022\n\n" + "\006LONELY\020\036\022\017\n" + "\013OVERWHELMED\020\037\022\016\n\n" + "PASSIONATE\020 \022\014\n" @@ -1676,7 +1684,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006BITTER\020/\022\013\n" + "\007ENVIOUS\0200\022\014\n" + "\010CONFUSED\0201\022\013\n" - + "\007CURIOUS\0202\022\r\n" + + "\007CURIOUS\0202\022\r" + + "\n" + "\tAWESTRUCK\0203\022\014\n" + "\010INSPIRED\0204\022\013\n" + "\007LONGING\0205\022\020\n" @@ -1742,7 +1751,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "FOLIC_ACID\020\n" + "\022\n\n" + "\006IODINE\020\013\022\010\n" - + "\004IRON\020\014\022\r\n" + + "\004IRON\020\014\022\r" + + "\n" + "\tMAGNESIUM\020\r" + "\022\r\n" + "\tMANGANESE\020\016\022\016\n\n" @@ -1790,20 +1800,21 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005LITER\020\005\022\016\n\n" + "MILLILITER\020\006\022\021\n\r" + "PINT_IMPERIAL\020\007\022\013\n" - + "\007PINT_US\020\010*\236\001\n" + + "\007PINT_US\020\010*\256\001\n" + "\023OvulationTestResult\022%\n" + "!OVULATION_TEST_RESULT_UNSPECIFIED\020\000\022\014\n" + "\010NEGATIVE\020\001\022\035\n" + "\031LUTEINIZING_HORMONE_SURGE\020\002\022\022\n" + "\016ESTROGEN_SURGE\020\003\022\014\n" + "\010POSITIVE\020\004\022\021\n\r" - + "INDETERMINATE\020\005B\224\002\n" - + "+com.google.devicesandservices.health.v4betaB\016DataModelProtoP\001ZRgoogle.golang." - + "org/genproto/googleapis/devicesandservic" - + "es/health/apiv4beta;healthpb\252\002\'Google.De" - + "vicesAndServices.Health.V4Beta\312\002\'Google\\" - + "DevicesAndServices\\Health\\V4beta\352\002*Googl" - + "e::DevicesAndServices::Health::V4betab\006proto3" + + "INDETERMINATE\020\005\022\016\n\n" + + "OWN_METHOD\020\006B\224\002\n" + + "+com.google.devicesandservices.health.v4betaB\016DataModelProtoP\001ZRgoogle.g" + + "olang.org/genproto/googleapis/devicesand" + + "services/health/apiv4beta;healthpb\252\002\'Goo" + + "gle.DevicesAndServices.Health.V4Beta\312\002\'G" + + "oogle\\DevicesAndServices\\Health\\V4beta\352\002" + + "*Google::DevicesAndServices::Health::V4betab\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -2745,7 +2756,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_devicesandservices_health_v4beta_OvulationTest_descriptor, new java.lang.String[] { - "SampleTime", "Result", + "SampleTime", "Result", "TestType", }); internal_static_google_devicesandservices_health_v4beta_Symptoms_descriptor = getDescriptor().getMessageType(69); diff --git a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/HealthProfileProto.java b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/HealthProfileProto.java index c4c208ddbad9..084cc2924ab9 100644 --- a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/HealthProfileProto.java +++ b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/HealthProfileProto.java @@ -266,7 +266,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\031ListPairedDevicesResponse\022M\n" + "\016paired_devices\030\001 \003(\01325.google.devices" + "andservices.health.v4beta.PairedDevice\022\027\n" - + "\017next_page_token\030\002 \001(\t2\333\022\n" + + "\017next_page_token\030\002 \001(\t2\220\027\n" + "\024HealthProfileService\022\251\001\n\n" + "GetProfile\022:.google.devicesandservices.health.v4beta.GetProfileRequ" + "est\0320.google.devicesandservices.health.v4beta.Profile\"-\332A\004name\202\323\344\223\002" @@ -294,24 +294,32 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ice\"5\332A\004name\202\323\344\223\002(\022&/v4beta/{name=users/*/pairedDevices/*}\022\323\001\n" + "\021ListPairedDevices\022A.google.devicesandservices.health.v4be" + "ta.ListPairedDevicesRequest\032B.google.devicesandservices.health.v4beta.ListPaired" - + "DevicesResponse\"7\332A\006parent\202\323\344\223\002(\022&/v4bet" - + "a/{parent=users/*}/pairedDevices\032\272\006\312A\025he" - + "alth.googleapis.com\322A\236\006https://www.googl" - + "eapis.com/auth/googlehealth.activity_and_fitness.readonly,https://www.googleapis" - + ".com/auth/googlehealth.ecg.readonly,https://www.googleapis.com/auth/googlehealth" - + ".health_metrics_and_measurements.readonly,https://www.googleapis.com/auth/google" - + "health.irn.readonly,https://www.googleapis.com/auth/googlehealth.logged_symptoms" - + ".readonly,https://www.googleapis.com/auth/googlehealth.mindfulness.readonly,http" - + "s://www.googleapis.com/auth/googlehealth.profile.readonly,https://www.googleapis" - + ".com/auth/googlehealth.profile.writeonly,https://www.googleapis.com/auth/googleh" - + "ealth.reproductive_health.readonly,https://www.googleapis.com/auth/googlehealth." - + "settings.readonly,https://www.googleapis.com/auth/googlehealth.settings.writeonl" - + "y,https://www.googleapis.com/auth/googlehealth.sleep.readonlyB\230\002\n" - + "+com.google.devicesandservices.health.v4betaB\022HealthPro" - + "fileProtoP\001ZRgoogle.golang.org/genproto/googleapis/devicesandservices/health/api" - + "v4beta;healthpb\252\002\'Google.DevicesAndServi" - + "ces.Health.V4Beta\312\002\'Google\\DevicesAndSer" - + "vices\\Health\\V4beta\352\002*Google::DevicesAndServices::Health::V4betab\006proto3" + + "DevicesResponse\"7\332A\006parent\202\323\344\223\002(\022&/v4beta/{parent=users/*}/pairedDevices\032\357\n" + + "\312A\025health.googleapis.com\322A\323\n" + + "https://www.googleapis.com/auth/googlehealth.activity_and" + + "_fitness.readonly,https://www.googleapis.com/auth/googlehealth.activity_and_fitn" + + "ess.writeonly,https://www.googleapis.com/auth/googlehealth.ecg.readonly,https://" + + "www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.readonly,ht" + + "tps://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.write" + + "only,https://www.googleapis.com/auth/googlehealth.irn.readonly,https://www.googl" + + "eapis.com/auth/googlehealth.location.readonly,https://www.googleapis.com/auth/go" + + "oglehealth.logged_symptoms.readonly,https://www.googleapis.com/auth/googlehealth" + + ".logged_symptoms.writeonly,https://www.googleapis.com/auth/googlehealth.mindfuln" + + "ess.readonly,https://www.googleapis.com/auth/googlehealth.mindfulness.writeonly," + + "https://www.googleapis.com/auth/googlehealth.nutrition.writeonly,https://www.goo" + + "gleapis.com/auth/googlehealth.profile.readonly,https://www.googleapis.com/auth/g" + + "ooglehealth.profile.writeonly,https://www.googleapis.com/auth/googlehealth.repro" + + "ductive_health.readonly,https://www.googleapis.com/auth/googlehealth.reproductiv" + + "e_health.writeonly,https://www.googleapis.com/auth/googlehealth.settings.readonl" + + "y,https://www.googleapis.com/auth/googlehealth.settings.writeonly,https://www.go" + + "ogleapis.com/auth/googlehealth.sleep.rea" + + "donly,https://www.googleapis.com/auth/googlehealth.sleep.writeonlyB\230\002\n" + + "+com.google.devicesandservices.health.v4betaB\022Heal" + + "thProfileProtoP\001ZRgoogle.golang.org/genproto/googleapis/devicesandservices/healt" + + "h/apiv4beta;healthpb\252\002\'Google.DevicesAnd" + + "Services.Health.V4Beta\312\002\'Google\\DevicesA" + + "ndServices\\Health\\V4beta\352\002*Google::Devic" + + "esAndServices::Health::V4betab\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTest.java b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTest.java index 5563197bb7b9..fca925cb45b6 100644 --- a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTest.java +++ b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTest.java @@ -53,6 +53,7 @@ private OvulationTest(com.google.protobuf.GeneratedMessage.Builder builder) { private OvulationTest() { result_ = 0; + testType_ = 0; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -70,6 +71,200 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { com.google.devicesandservices.health.v4beta.OvulationTest.Builder.class); } + /** + * + * + *
            +   * Ovulation test type.
            +   * 
            + * + * Protobuf enum {@code google.devicesandservices.health.v4beta.OvulationTest.TestType} + */ + public enum TestType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
            +     * Unspecified test type.
            +     * 
            + * + * TEST_TYPE_UNSPECIFIED = 0; + */ + TEST_TYPE_UNSPECIFIED(0), + /** + * + * + *
            +     * Test strip.
            +     * 
            + * + * STRIP = 1; + */ + STRIP(1), + /** + * + * + *
            +     * Digital test.
            +     * 
            + * + * DIGITAL = 2; + */ + DIGITAL(2), + /** + * + * + *
            +     * The user's own method, not a test kit.
            +     * 
            + * + * OWN_METHOD = 3; + */ + OWN_METHOD(3), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "TestType"); + } + + /** + * + * + *
            +     * Unspecified test type.
            +     * 
            + * + * TEST_TYPE_UNSPECIFIED = 0; + */ + public static final int TEST_TYPE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
            +     * Test strip.
            +     * 
            + * + * STRIP = 1; + */ + public static final int STRIP_VALUE = 1; + + /** + * + * + *
            +     * Digital test.
            +     * 
            + * + * DIGITAL = 2; + */ + public static final int DIGITAL_VALUE = 2; + + /** + * + * + *
            +     * The user's own method, not a test kit.
            +     * 
            + * + * OWN_METHOD = 3; + */ + public static final int OWN_METHOD_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static TestType valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static TestType forNumber(int value) { + switch (value) { + case 0: + return TEST_TYPE_UNSPECIFIED; + case 1: + return STRIP; + case 2: + return DIGITAL; + case 3: + return OWN_METHOD; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public TestType findValueByNumber(int number) { + return TestType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.devicesandservices.health.v4beta.OvulationTest.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final TestType[] VALUES = values(); + + public static TestType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private TestType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.devicesandservices.health.v4beta.OvulationTest.TestType) + } + private int bitField0_; public static final int SAMPLE_TIME_FIELD_NUMBER = 2; private com.google.devicesandservices.health.v4beta.ObservationSampleTime sampleTime_; @@ -174,6 +369,49 @@ public com.google.devicesandservices.health.v4beta.OvulationTestResult getResult : result; } + public static final int TEST_TYPE_FIELD_NUMBER = 4; + private int testType_ = 0; + + /** + * + * + *
            +   * Optional. The type of ovulation test.
            +   * 
            + * + * + * .google.devicesandservices.health.v4beta.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for testType. + */ + @java.lang.Override + public int getTestTypeValue() { + return testType_; + } + + /** + * + * + *
            +   * Optional. The type of ovulation test.
            +   * 
            + * + * + * .google.devicesandservices.health.v4beta.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The testType. + */ + @java.lang.Override + public com.google.devicesandservices.health.v4beta.OvulationTest.TestType getTestType() { + com.google.devicesandservices.health.v4beta.OvulationTest.TestType result = + com.google.devicesandservices.health.v4beta.OvulationTest.TestType.forNumber(testType_); + return result == null + ? com.google.devicesandservices.health.v4beta.OvulationTest.TestType.UNRECOGNIZED + : result; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -197,6 +435,11 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io .getNumber()) { output.writeEnum(3, result_); } + if (testType_ + != com.google.devicesandservices.health.v4beta.OvulationTest.TestType.TEST_TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(4, testType_); + } getUnknownFields().writeTo(output); } @@ -215,6 +458,11 @@ public int getSerializedSize() { .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, result_); } + if (testType_ + != com.google.devicesandservices.health.v4beta.OvulationTest.TestType.TEST_TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, testType_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -236,6 +484,7 @@ public boolean equals(final java.lang.Object obj) { if (!getSampleTime().equals(other.getSampleTime())) return false; } if (result_ != other.result_) return false; + if (testType_ != other.testType_) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -253,6 +502,8 @@ public int hashCode() { } hash = (37 * hash) + RESULT_FIELD_NUMBER; hash = (53 * hash) + result_; + hash = (37 * hash) + TEST_TYPE_FIELD_NUMBER; + hash = (53 * hash) + testType_; hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -409,6 +660,7 @@ public Builder clear() { sampleTimeBuilder_ = null; } result_ = 0; + testType_ = 0; return this; } @@ -453,6 +705,9 @@ private void buildPartial0(com.google.devicesandservices.health.v4beta.Ovulation if (((from_bitField0_ & 0x00000002) != 0)) { result.result_ = result_; } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.testType_ = testType_; + } result.bitField0_ |= to_bitField0_; } @@ -475,6 +730,9 @@ public Builder mergeFrom(com.google.devicesandservices.health.v4beta.OvulationTe if (other.result_ != 0) { setResultValue(other.getResultValue()); } + if (other.testType_ != 0) { + setTestTypeValue(other.getTestTypeValue()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -514,6 +772,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000002; break; } // case 24 + case 32: + { + testType_ = input.readEnum(); + bitField0_ |= 0x00000004; + break; + } // case 32 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -860,6 +1124,114 @@ public Builder clearResult() { return this; } + private int testType_ = 0; + + /** + * + * + *
            +     * Optional. The type of ovulation test.
            +     * 
            + * + * + * .google.devicesandservices.health.v4beta.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for testType. + */ + @java.lang.Override + public int getTestTypeValue() { + return testType_; + } + + /** + * + * + *
            +     * Optional. The type of ovulation test.
            +     * 
            + * + * + * .google.devicesandservices.health.v4beta.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for testType to set. + * @return This builder for chaining. + */ + public Builder setTestTypeValue(int value) { + testType_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. The type of ovulation test.
            +     * 
            + * + * + * .google.devicesandservices.health.v4beta.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The testType. + */ + @java.lang.Override + public com.google.devicesandservices.health.v4beta.OvulationTest.TestType getTestType() { + com.google.devicesandservices.health.v4beta.OvulationTest.TestType result = + com.google.devicesandservices.health.v4beta.OvulationTest.TestType.forNumber(testType_); + return result == null + ? com.google.devicesandservices.health.v4beta.OvulationTest.TestType.UNRECOGNIZED + : result; + } + + /** + * + * + *
            +     * Optional. The type of ovulation test.
            +     * 
            + * + * + * .google.devicesandservices.health.v4beta.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The testType to set. + * @return This builder for chaining. + */ + public Builder setTestType( + com.google.devicesandservices.health.v4beta.OvulationTest.TestType value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000004; + testType_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. The type of ovulation test.
            +     * 
            + * + * + * .google.devicesandservices.health.v4beta.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearTestType() { + bitField0_ = (bitField0_ & ~0x00000004); + testType_ = 0; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.devicesandservices.health.v4beta.OvulationTest) } diff --git a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTestOrBuilder.java b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTestOrBuilder.java index 4ad30bb9ce3c..de8525b04be9 100644 --- a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTestOrBuilder.java +++ b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTestOrBuilder.java @@ -99,4 +99,34 @@ public interface OvulationTestOrBuilder * @return The result. */ com.google.devicesandservices.health.v4beta.OvulationTestResult getResult(); + + /** + * + * + *
            +   * Optional. The type of ovulation test.
            +   * 
            + * + * + * .google.devicesandservices.health.v4beta.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for testType. + */ + int getTestTypeValue(); + + /** + * + * + *
            +   * Optional. The type of ovulation test.
            +   * 
            + * + * + * .google.devicesandservices.health.v4beta.OvulationTest.TestType test_type = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The testType. + */ + com.google.devicesandservices.health.v4beta.OvulationTest.TestType getTestType(); } diff --git a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTestResult.java b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTestResult.java index 8fd6ffb86dcc..e3147bf91721 100644 --- a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTestResult.java +++ b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/OvulationTestResult.java @@ -91,6 +91,16 @@ public enum OvulationTestResult implements com.google.protobuf.ProtocolMessageEn * INDETERMINATE = 5; */ INDETERMINATE(5), + /** + * + * + *
            +   * Ovulation day the user identified by their own method, not a test kit.
            +   * 
            + * + * OWN_METHOD = 6; + */ + OWN_METHOD(6), UNRECOGNIZED(-1), ; @@ -170,6 +180,17 @@ public enum OvulationTestResult implements com.google.protobuf.ProtocolMessageEn */ public static final int INDETERMINATE_VALUE = 5; + /** + * + * + *
            +   * Ovulation day the user identified by their own method, not a test kit.
            +   * 
            + * + * OWN_METHOD = 6; + */ + public static final int OWN_METHOD_VALUE = 6; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -206,6 +227,8 @@ public static OvulationTestResult forNumber(int value) { return POSITIVE; case 5: return INDETERMINATE; + case 6: + return OWN_METHOD; default: return null; } diff --git a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/Symptoms.java b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/Symptoms.java index 8fde3f5e438c..ad48a7a245ce 100644 --- a/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/Symptoms.java +++ b/java-health/proto-google-cloud-health-v4beta/src/main/java/com/google/devicesandservices/health/v4beta/Symptoms.java @@ -740,6 +740,36 @@ public enum SymptomValue implements com.google.protobuf.ProtocolMessageEnum { * VOMITING = 65; */ VOMITING(65), + /** + * + * + *
            +     * Swelling of the arms or legs.
            +     * 
            + * + * LIMBS_SWELLING = 76; + */ + LIMBS_SWELLING(76), + /** + * + * + *
            +     * Swelling of the face.
            +     * 
            + * + * FACE_SWELLING = 77; + */ + FACE_SWELLING(77), + /** + * + * + *
            +     * Nasal congestion.
            +     * 
            + * + * NASAL_CONGESTION = 78; + */ + NASAL_CONGESTION(78), UNRECOGNIZED(-1), ; @@ -1479,6 +1509,39 @@ public enum SymptomValue implements com.google.protobuf.ProtocolMessageEnum { */ public static final int VOMITING_VALUE = 65; + /** + * + * + *
            +     * Swelling of the arms or legs.
            +     * 
            + * + * LIMBS_SWELLING = 76; + */ + public static final int LIMBS_SWELLING_VALUE = 76; + + /** + * + * + *
            +     * Swelling of the face.
            +     * 
            + * + * FACE_SWELLING = 77; + */ + public static final int FACE_SWELLING_VALUE = 77; + + /** + * + * + *
            +     * Nasal congestion.
            +     * 
            + * + * NASAL_CONGESTION = 78; + */ + public static final int NASAL_CONGESTION_VALUE = 78; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -1635,6 +1698,12 @@ public static SymptomValue forNumber(int value) { return VAGINAL_ITCHING; case 65: return VOMITING; + case 76: + return LIMBS_SWELLING; + case 77: + return FACE_SWELLING; + case 78: + return NASAL_CONGESTION; default: return null; } diff --git a/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/data_model.proto b/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/data_model.proto index cd3d97947476..683400f0487c 100644 --- a/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/data_model.proto +++ b/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/data_model.proto @@ -318,6 +318,9 @@ enum OvulationTestResult { // Indeterminate result. INDETERMINATE = 5; + + // Ovulation day the user identified by their own method, not a test kit. + OWN_METHOD = 6; } // Record of active zone minutes in a given time interval. @@ -2999,12 +3002,30 @@ message MenstrualPeriod { // Ovulation test record. message OvulationTest { + // Ovulation test type. + enum TestType { + // Unspecified test type. + TEST_TYPE_UNSPECIFIED = 0; + + // Test strip. + STRIP = 1; + + // Digital test. + DIGITAL = 2; + + // The user's own method, not a test kit. + OWN_METHOD = 3; + } + // Required. The time at which ovulation test was measured. ObservationSampleTime sample_time = 2 [(google.api.field_behavior) = REQUIRED]; // Required. The result of the ovulation test. OvulationTestResult result = 3 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The type of ovulation test. + TestType test_type = 4 [(google.api.field_behavior) = OPTIONAL]; } // Symptoms logged by the user. @@ -3208,6 +3229,15 @@ message Symptoms { // Vomiting. VOMITING = 65; + + // Swelling of the arms or legs. + LIMBS_SWELLING = 76; + + // Swelling of the face. + FACE_SWELLING = 77; + + // Nasal congestion. + NASAL_CONGESTION = 78; } // Required. Time when the symptoms were logged. diff --git a/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/data_points.proto b/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/data_points.proto index 9f37762d9da8..770bf9b4e2f5 100644 --- a/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/data_points.proto +++ b/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/data_points.proto @@ -1397,9 +1397,10 @@ message DailyRollUpDataPointsRequest { int32 window_size_days = 3 [(google.api.field_behavior) = OPTIONAL]; // Optional. The maximum number of data points to return. - // If unspecified, at most 1440 data points will be returned. - // The maximum page size is 10000; values above that will be truncated - // accordingly. + // If unspecified, at most `90` data points will be returned. + // The maximum page size is `90`. + // For `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes`, and + // `total-calories`, the default and maximum page size is `14`. int32 page_size = 4 [(google.api.field_behavior) = OPTIONAL]; // Optional. The next_page_token from a previous request, if any. diff --git a/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/health_profile.proto b/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/health_profile.proto index 655426232e1e..a93a95779080 100644 --- a/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/health_profile.proto +++ b/java-health/proto-google-cloud-health-v4beta/src/main/proto/google/devicesandservices/health/v4beta/health_profile.proto @@ -38,17 +38,25 @@ service HealthProfileService { option (google.api.default_host) = "health.googleapis.com"; option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly," + "https://www.googleapis.com/auth/googlehealth.activity_and_fitness.writeonly," "https://www.googleapis.com/auth/googlehealth.ecg.readonly," "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.readonly," + "https://www.googleapis.com/auth/googlehealth.health_metrics_and_measurements.writeonly," "https://www.googleapis.com/auth/googlehealth.irn.readonly," + "https://www.googleapis.com/auth/googlehealth.location.readonly," "https://www.googleapis.com/auth/googlehealth.logged_symptoms.readonly," + "https://www.googleapis.com/auth/googlehealth.logged_symptoms.writeonly," "https://www.googleapis.com/auth/googlehealth.mindfulness.readonly," + "https://www.googleapis.com/auth/googlehealth.mindfulness.writeonly," + "https://www.googleapis.com/auth/googlehealth.nutrition.writeonly," "https://www.googleapis.com/auth/googlehealth.profile.readonly," "https://www.googleapis.com/auth/googlehealth.profile.writeonly," "https://www.googleapis.com/auth/googlehealth.reproductive_health.readonly," + "https://www.googleapis.com/auth/googlehealth.reproductive_health.writeonly," "https://www.googleapis.com/auth/googlehealth.settings.readonly," "https://www.googleapis.com/auth/googlehealth.settings.writeonly," - "https://www.googleapis.com/auth/googlehealth.sleep.readonly"; + "https://www.googleapis.com/auth/googlehealth.sleep.readonly," + "https://www.googleapis.com/auth/googlehealth.sleep.writeonly"; // Returns user Profile details. rpc GetProfile(GetProfileRequest) returns (Profile) { diff --git a/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/dailyrollupdatapoints/AsyncDailyRollUpDataPoints.java b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/dailyrollupdatapoints/AsyncDailyRollUpDataPoints.java index e4bafb45d532..bcd0173ed48c 100644 --- a/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/dailyrollupdatapoints/AsyncDailyRollUpDataPoints.java +++ b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/dailyrollupdatapoints/AsyncDailyRollUpDataPoints.java @@ -20,7 +20,7 @@ import com.google.api.core.ApiFuture; import com.google.devicesandservices.health.v4.CivilTimeInterval; import com.google.devicesandservices.health.v4.DailyRollUpDataPointsRequest; -import com.google.devicesandservices.health.v4.DailyRollUpDataPointsResponse; +import com.google.devicesandservices.health.v4.DailyRollupDataPoint; import com.google.devicesandservices.health.v4.DataPointsServiceClient; import com.google.devicesandservices.health.v4.DataTypeName; @@ -46,10 +46,12 @@ public static void asyncDailyRollUpDataPoints() throws Exception { .setPageToken("pageToken873572522") .setDataSourceFamily("dataSourceFamily586548265") .build(); - ApiFuture future = - dataPointsServiceClient.dailyRollUpDataPointsCallable().futureCall(request); + ApiFuture future = + dataPointsServiceClient.dailyRollUpDataPointsPagedCallable().futureCall(request); // Do something. - DailyRollUpDataPointsResponse response = future.get(); + for (DailyRollupDataPoint element : future.get().iterateAll()) { + // doThingsWith(element); + } } } } diff --git a/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/dailyrollupdatapoints/AsyncDailyRollUpDataPointsPaged.java b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/dailyrollupdatapoints/AsyncDailyRollUpDataPointsPaged.java new file mode 100644 index 000000000000..46e1a5a0fff1 --- /dev/null +++ b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/dailyrollupdatapoints/AsyncDailyRollUpDataPointsPaged.java @@ -0,0 +1,66 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.devicesandservices.health.v4.samples; + +// [START health_v4_generated_DataPointsService_DailyRollUpDataPoints_Paged_async] +import com.google.common.base.Strings; +import com.google.devicesandservices.health.v4.CivilTimeInterval; +import com.google.devicesandservices.health.v4.DailyRollUpDataPointsRequest; +import com.google.devicesandservices.health.v4.DailyRollUpDataPointsResponse; +import com.google.devicesandservices.health.v4.DailyRollupDataPoint; +import com.google.devicesandservices.health.v4.DataPointsServiceClient; +import com.google.devicesandservices.health.v4.DataTypeName; + +public class AsyncDailyRollUpDataPointsPaged { + + public static void main(String[] args) throws Exception { + asyncDailyRollUpDataPointsPaged(); + } + + public static void asyncDailyRollUpDataPointsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (DataPointsServiceClient dataPointsServiceClient = DataPointsServiceClient.create()) { + DailyRollUpDataPointsRequest request = + DailyRollUpDataPointsRequest.newBuilder() + .setParent(DataTypeName.of("[USER]", "[DATA_TYPE]").toString()) + .setRange(CivilTimeInterval.newBuilder().build()) + .setWindowSizeDays(1064520774) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setDataSourceFamily("dataSourceFamily586548265") + .build(); + while (true) { + DailyRollUpDataPointsResponse response = + dataPointsServiceClient.dailyRollUpDataPointsCallable().call(request); + for (DailyRollupDataPoint element : response.getRollupDataPointsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END health_v4_generated_DataPointsService_DailyRollUpDataPoints_Paged_async] diff --git a/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/dailyrollupdatapoints/SyncDailyRollUpDataPoints.java b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/dailyrollupdatapoints/SyncDailyRollUpDataPoints.java index 25b46281eb7a..5f8e98403f31 100644 --- a/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/dailyrollupdatapoints/SyncDailyRollUpDataPoints.java +++ b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/dailyrollupdatapoints/SyncDailyRollUpDataPoints.java @@ -19,7 +19,7 @@ // [START health_v4_generated_DataPointsService_DailyRollUpDataPoints_sync] import com.google.devicesandservices.health.v4.CivilTimeInterval; import com.google.devicesandservices.health.v4.DailyRollUpDataPointsRequest; -import com.google.devicesandservices.health.v4.DailyRollUpDataPointsResponse; +import com.google.devicesandservices.health.v4.DailyRollupDataPoint; import com.google.devicesandservices.health.v4.DataPointsServiceClient; import com.google.devicesandservices.health.v4.DataTypeName; @@ -45,8 +45,10 @@ public static void syncDailyRollUpDataPoints() throws Exception { .setPageToken("pageToken873572522") .setDataSourceFamily("dataSourceFamily586548265") .build(); - DailyRollUpDataPointsResponse response = - dataPointsServiceClient.dailyRollUpDataPoints(request); + for (DailyRollupDataPoint element : + dataPointsServiceClient.dailyRollUpDataPoints(request).iterateAll()) { + // doThingsWith(element); + } } } } diff --git a/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/AsyncListDataPoints.java b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/AsyncListDataPoints.java index 7d580daacc08..2e6bceec693f 100644 --- a/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/AsyncListDataPoints.java +++ b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/AsyncListDataPoints.java @@ -42,6 +42,7 @@ public static void asyncListDataPoints() throws Exception { .setPageSize(883849137) .setPageToken("pageToken873572522") .setFilter("filter-1274492040") + .setDataSourceFamily("dataSourceFamily586548265") .build(); ApiFuture future = dataPointsServiceClient.listDataPointsPagedCallable().futureCall(request); diff --git a/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/AsyncListDataPointsPaged.java b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/AsyncListDataPointsPaged.java index 72199d038d7d..31961f46b853 100644 --- a/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/AsyncListDataPointsPaged.java +++ b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/AsyncListDataPointsPaged.java @@ -43,6 +43,7 @@ public static void asyncListDataPointsPaged() throws Exception { .setPageSize(883849137) .setPageToken("pageToken873572522") .setFilter("filter-1274492040") + .setDataSourceFamily("dataSourceFamily586548265") .build(); while (true) { ListDataPointsResponse response = diff --git a/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/SyncListDataPoints.java b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/SyncListDataPoints.java index 51ceed6f2cc4..bde0b732269f 100644 --- a/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/SyncListDataPoints.java +++ b/java-health/samples/snippets/generated/com/google/devicesandservices/health/v4/datapointsservice/listdatapoints/SyncListDataPoints.java @@ -41,6 +41,7 @@ public static void syncListDataPoints() throws Exception { .setPageSize(883849137) .setPageToken("pageToken873572522") .setFilter("filter-1274492040") + .setDataSourceFamily("dataSourceFamily586548265") .build(); for (DataPoint element : dataPointsServiceClient.listDataPoints(request).iterateAll()) { // doThingsWith(element); diff --git a/java-hypercomputecluster/README.md b/java-hypercomputecluster/README.md index cf6ab270ae27..b032167ab8a3 100644 --- a/java-hypercomputecluster/README.md +++ b/java-hypercomputecluster/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-hypercomputecluster - 0.22.0 + 0.23.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-hypercomputecluster' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-hypercomputecluster:0.22.0' +implementation 'com.google.cloud:google-cloud-hypercomputecluster:0.23.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-hypercomputecluster" % "0.22.0" +libraryDependencies += "com.google.cloud" % "google-cloud-hypercomputecluster" % "0.23.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-hypercomputecluster/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-hypercomputecluster.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-hypercomputecluster/0.22.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-hypercomputecluster/0.23.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-iam-admin/README.md b/java-iam-admin/README.md index 6f629945fbb5..71765b145055 100644 --- a/java-iam-admin/README.md +++ b/java-iam-admin/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-iam-admin - 3.97.0 + 3.98.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-iam-admin' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-iam-admin:3.97.0' +implementation 'com.google.cloud:google-iam-admin:3.98.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-iam-admin" % "3.97.0" +libraryDependencies += "com.google.cloud" % "google-iam-admin" % "3.98.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-iam-admin/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-iam-admin.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-iam-admin/3.97.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-iam-admin/3.98.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-iam-policy/README.md b/java-iam-policy/README.md index edea210fdfbd..a21166bf0fa5 100644 --- a/java-iam-policy/README.md +++ b/java-iam-policy/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-iam-policy - 1.99.0 + 1.100.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-iam-policy' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-iam-policy:1.99.0' +implementation 'com.google.cloud:google-iam-policy:1.100.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-iam-policy" % "1.99.0" +libraryDependencies += "com.google.cloud" % "google-iam-policy" % "1.100.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/proto-google-iam-v1/latest/history [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-iam-policy.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-iam-policy/1.99.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-iam-policy/1.100.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-iamcredentials/README.md b/java-iamcredentials/README.md index 70b0c07d81f7..c3a81e77c2d7 100644 --- a/java-iamcredentials/README.md +++ b/java-iamcredentials/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-iamcredentials - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-iamcredentials' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-iamcredentials:2.102.0' +implementation 'com.google.cloud:google-cloud-iamcredentials:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-iamcredentials" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-iamcredentials" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-iamcredentials/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-iamcredentials.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-iamcredentials/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-iamcredentials/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-iap/README.md b/java-iap/README.md index 020bdbff6a64..30f51d151f2a 100644 --- a/java-iap/README.md +++ b/java-iap/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-iap - 0.58.0 + 0.59.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-iap' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-iap:0.58.0' +implementation 'com.google.cloud:google-cloud-iap:0.59.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-iap" % "0.58.0" +libraryDependencies += "com.google.cloud" % "google-cloud-iap" % "0.59.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-iap/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-iap.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-iap/0.58.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-iap/0.59.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-ids/README.md b/java-ids/README.md index 4854cfb1cfa7..e5311b6adb56 100644 --- a/java-ids/README.md +++ b/java-ids/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-ids - 1.101.0 + 1.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-ids' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-ids:1.101.0' +implementation 'com.google.cloud:google-cloud-ids:1.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-ids" % "1.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-ids" % "1.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-ids/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-ids.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-ids/1.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-ids/1.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-infra-manager/README.md b/java-infra-manager/README.md index b85ad2a7d63c..0540f9e5491c 100644 --- a/java-infra-manager/README.md +++ b/java-infra-manager/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-infra-manager - 0.79.0 + 0.80.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-infra-manager' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-infra-manager:0.79.0' +implementation 'com.google.cloud:google-cloud-infra-manager:0.80.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-infra-manager" % "0.79.0" +libraryDependencies += "com.google.cloud" % "google-cloud-infra-manager" % "0.80.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-infra-manager/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-infra-manager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-infra-manager/0.79.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-infra-manager/0.80.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-iot/README.md b/java-iot/README.md index 01890d616d76..0daa5f41c418 100644 --- a/java-iot/README.md +++ b/java-iot/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-iot - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-iot' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-iot:2.102.0' +implementation 'com.google.cloud:google-cloud-iot:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-iot" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-iot" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-iot/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-iot.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-iot/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-iot/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-kms/README.md b/java-kms/README.md index aff761df8f27..5c22a33683a4 100644 --- a/java-kms/README.md +++ b/java-kms/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-kms - 2.105.0 + 2.106.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-kms' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-kms:2.105.0' +implementation 'com.google.cloud:google-cloud-kms:2.106.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-kms" % "2.105.0" +libraryDependencies += "com.google.cloud" % "google-cloud-kms" % "2.106.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-kms/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-kms.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-kms/2.105.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-kms/2.106.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-kmsinventory/README.md b/java-kmsinventory/README.md index 50ebe0bc4b46..5635ba56c7e6 100644 --- a/java-kmsinventory/README.md +++ b/java-kmsinventory/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-kmsinventory - 0.91.0 + 0.92.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-kmsinventory' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-kmsinventory:0.91.0' +implementation 'com.google.cloud:google-cloud-kmsinventory:0.92.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-kmsinventory" % "0.91.0" +libraryDependencies += "com.google.cloud" % "google-cloud-kmsinventory" % "0.92.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-kmsinventory/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-kmsinventory.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-kmsinventory/0.91.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-kmsinventory/0.92.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-language/README.md b/java-language/README.md index 2d8c35444cbb..d792cb360af1 100644 --- a/java-language/README.md +++ b/java-language/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-language - 2.103.0 + 2.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-language' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-language:2.103.0' +implementation 'com.google.cloud:google-cloud-language:2.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-language" % "2.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-language" % "2.104.0" ``` ## Authentication @@ -214,7 +214,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-language/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-language.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-language/2.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-language/2.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-licensemanager/README.md b/java-licensemanager/README.md index d64de9eda643..f0597c8df6e5 100644 --- a/java-licensemanager/README.md +++ b/java-licensemanager/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-licensemanager - 0.35.0 + 0.36.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-licensemanager' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-licensemanager:0.35.0' +implementation 'com.google.cloud:google-cloud-licensemanager:0.36.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-licensemanager" % "0.35.0" +libraryDependencies += "com.google.cloud" % "google-cloud-licensemanager" % "0.36.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-licensemanager/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-licensemanager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-licensemanager/0.35.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-licensemanager/0.36.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-life-sciences/README.md b/java-life-sciences/README.md index 790eae9078de..9e5d8b97b794 100644 --- a/java-life-sciences/README.md +++ b/java-life-sciences/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-life-sciences - 0.104.0 + 0.105.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-life-sciences' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-life-sciences:0.104.0' +implementation 'com.google.cloud:google-cloud-life-sciences:0.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-life-sciences" % "0.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-life-sciences" % "0.105.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-life-sciences/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-life-sciences.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-life-sciences/0.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-life-sciences/0.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-locationfinder/README.md b/java-locationfinder/README.md index 33c3e5d39216..06a4e6fb033c 100644 --- a/java-locationfinder/README.md +++ b/java-locationfinder/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-locationfinder - 0.27.0 + 0.28.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-locationfinder' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-locationfinder:0.27.0' +implementation 'com.google.cloud:google-cloud-locationfinder:0.28.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-locationfinder" % "0.27.0" +libraryDependencies += "com.google.cloud" % "google-cloud-locationfinder" % "0.28.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-locationfinder/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-locationfinder.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-locationfinder/0.27.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-locationfinder/0.28.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-logging/README.md b/java-logging/README.md index 0b63e6560186..9b9c1059767f 100644 --- a/java-logging/README.md +++ b/java-logging/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-logging - 3.43.0 + 3.44.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-logging' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-logging:3.43.0' +implementation 'com.google.cloud:google-cloud-logging:3.44.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-logging" % "3.43.0" +libraryDependencies += "com.google.cloud" % "google-cloud-logging" % "3.44.0" ``` ## Authentication @@ -440,7 +440,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-logging/latest/history [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-logging.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-logging/3.43.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-logging/3.44.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-lustre/README.md b/java-lustre/README.md index f77caac8d68a..f8e1d72cbaa4 100644 --- a/java-lustre/README.md +++ b/java-lustre/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-lustre - 0.42.0 + 0.43.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-lustre' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-lustre:0.42.0' +implementation 'com.google.cloud:google-cloud-lustre:0.43.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-lustre" % "0.42.0" +libraryDependencies += "com.google.cloud" % "google-cloud-lustre" % "0.43.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-lustre/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-lustre.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-lustre/0.42.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-lustre/0.43.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maintenance/README.md b/java-maintenance/README.md index 1bee6c2e3226..037901a63ff9 100644 --- a/java-maintenance/README.md +++ b/java-maintenance/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-maintenance - 0.36.0 + 0.37.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-maintenance' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-maintenance:0.36.0' +implementation 'com.google.cloud:google-cloud-maintenance:0.37.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-maintenance" % "0.36.0" +libraryDependencies += "com.google.cloud" % "google-cloud-maintenance" % "0.37.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-maintenance/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-maintenance.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-maintenance/0.36.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-maintenance/0.37.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-managed-identities/README.md b/java-managed-identities/README.md index d0c4f35ca1e4..4a488e7afd56 100644 --- a/java-managed-identities/README.md +++ b/java-managed-identities/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-managed-identities - 1.100.0 + 1.101.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-managed-identities' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-managed-identities:1.100.0' +implementation 'com.google.cloud:google-cloud-managed-identities:1.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-managed-identities" % "1.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-managed-identities" % "1.101.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-managed-identities/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-managed-identities.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-managed-identities/1.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-managed-identities/1.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-managedkafka/README.md b/java-managedkafka/README.md index 66e1fa17a28e..e07293c2437b 100644 --- a/java-managedkafka/README.md +++ b/java-managedkafka/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-managedkafka - 0.58.0 + 0.59.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-managedkafka' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-managedkafka:0.58.0' +implementation 'com.google.cloud:google-cloud-managedkafka:0.59.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-managedkafka" % "0.58.0" +libraryDependencies += "com.google.cloud" % "google-cloud-managedkafka" % "0.59.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-managedkafka/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-managedkafka.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-managedkafka/0.58.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-managedkafka/0.59.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-addressvalidation/README.md b/java-maps-addressvalidation/README.md index 48369f270a3d..208180d568a0 100644 --- a/java-maps-addressvalidation/README.md +++ b/java-maps-addressvalidation/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-addressvalidation - 0.96.0 + 0.97.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-addressvalidation:0.96.0' +implementation 'com.google.maps:google-maps-addressvalidation:0.97.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-addressvalidation" % "0.96.0" +libraryDependencies += "com.google.maps" % "google-maps-addressvalidation" % "0.97.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-addressvalidation/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-addressvalidation.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-addressvalidation/0.96.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-addressvalidation/0.97.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-area-insights/README.md b/java-maps-area-insights/README.md index 0ecf5edb81ef..08f36a3a4819 100644 --- a/java-maps-area-insights/README.md +++ b/java-maps-area-insights/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-area-insights - 0.53.0 + 0.54.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-area-insights:0.53.0' +implementation 'com.google.maps:google-maps-area-insights:0.54.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-area-insights" % "0.53.0" +libraryDependencies += "com.google.maps" % "google-maps-area-insights" % "0.54.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-area-insights/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-area-insights.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-area-insights/0.53.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-area-insights/0.54.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-fleetengine-delivery/README.md b/java-maps-fleetengine-delivery/README.md index 820ee8e3ed50..bc1db21f9b25 100644 --- a/java-maps-fleetengine-delivery/README.md +++ b/java-maps-fleetengine-delivery/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-fleetengine-delivery - 0.49.0 + 0.50.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-fleetengine-delivery:0.49.0' +implementation 'com.google.maps:google-maps-fleetengine-delivery:0.50.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-fleetengine-delivery" % "0.49.0" +libraryDependencies += "com.google.maps" % "google-maps-fleetengine-delivery" % "0.50.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-fleetengine-delivery/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-fleetengine-delivery.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-fleetengine-delivery/0.49.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-fleetengine-delivery/0.50.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-fleetengine/README.md b/java-maps-fleetengine/README.md index 659b991451df..ac88019b27f0 100644 --- a/java-maps-fleetengine/README.md +++ b/java-maps-fleetengine/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-fleetengine - 0.49.0 + 0.50.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-fleetengine:0.49.0' +implementation 'com.google.maps:google-maps-fleetengine:0.50.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-fleetengine" % "0.49.0" +libraryDependencies += "com.google.maps" % "google-maps-fleetengine" % "0.50.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-fleetengine/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-fleetengine.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-fleetengine/0.49.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-fleetengine/0.50.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-geocode/README.md b/java-maps-geocode/README.md index bc17ecdb7396..0ca4f25b15c7 100644 --- a/java-maps-geocode/README.md +++ b/java-maps-geocode/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-geocode - 0.14.0 + 0.15.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-geocode:0.14.0' +implementation 'com.google.maps:google-maps-geocode:0.15.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-geocode" % "0.14.0" +libraryDependencies += "com.google.maps" % "google-maps-geocode" % "0.15.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-geocode/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-geocode.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-geocode/0.14.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-geocode/0.15.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-isochrones/README.md b/java-maps-isochrones/README.md index 21fd28c13ca5..fac83d4a70dc 100644 --- a/java-maps-isochrones/README.md +++ b/java-maps-isochrones/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-isochrones - 0.8.0 + 0.9.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-isochrones:0.8.0' +implementation 'com.google.maps:google-maps-isochrones:0.9.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-isochrones" % "0.8.0" +libraryDependencies += "com.google.maps" % "google-maps-isochrones" % "0.9.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-isochrones/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-isochrones.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-isochrones/0.8.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-isochrones/0.9.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-mapmanagement/README.md b/java-maps-mapmanagement/README.md index b63a1a32e453..b2ffdc4c15c5 100644 --- a/java-maps-mapmanagement/README.md +++ b/java-maps-mapmanagement/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-mapmanagement - 0.11.0 + 0.12.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-mapmanagement:0.11.0' +implementation 'com.google.maps:google-maps-mapmanagement:0.12.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-mapmanagement" % "0.11.0" +libraryDependencies += "com.google.maps" % "google-maps-mapmanagement" % "0.12.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-mapmanagement/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-mapmanagement.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-mapmanagement/0.11.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-mapmanagement/0.12.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-mapsplatformdatasets/README.md b/java-maps-mapsplatformdatasets/README.md index c9e07eb072c5..d5fa447a929c 100644 --- a/java-maps-mapsplatformdatasets/README.md +++ b/java-maps-mapsplatformdatasets/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-mapsplatformdatasets - 0.91.0 + 0.92.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-mapsplatformdatasets:0.91.0' +implementation 'com.google.maps:google-maps-mapsplatformdatasets:0.92.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-mapsplatformdatasets" % "0.91.0" +libraryDependencies += "com.google.maps" % "google-maps-mapsplatformdatasets" % "0.92.0" ``` ## Authentication @@ -156,7 +156,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-mapsplatformdatasets/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-mapsplatformdatasets.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-mapsplatformdatasets/0.91.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-mapsplatformdatasets/0.92.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-navconnect/README.md b/java-maps-navconnect/README.md index d0dce0f450a1..d70847b094f2 100644 --- a/java-maps-navconnect/README.md +++ b/java-maps-navconnect/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-navconnect - 0.8.0 + 0.9.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-navconnect:0.8.0' +implementation 'com.google.maps:google-maps-navconnect:0.9.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-navconnect" % "0.8.0" +libraryDependencies += "com.google.maps" % "google-maps-navconnect" % "0.9.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-navconnect/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-navconnect.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-navconnect/0.8.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-navconnect/0.9.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-places/README.md b/java-maps-places/README.md index 1ed05fc1e8b0..7b96a7d65dec 100644 --- a/java-maps-places/README.md +++ b/java-maps-places/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-places - 0.73.0 + 0.74.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-places:0.73.0' +implementation 'com.google.maps:google-maps-places:0.74.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-places" % "0.73.0" +libraryDependencies += "com.google.maps" % "google-maps-places" % "0.74.0" ``` ## Authentication @@ -161,7 +161,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-places/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-places.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-places/0.73.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-places/0.74.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-routeoptimization/README.md b/java-maps-routeoptimization/README.md index 559fe75c514d..607ce6d5bca0 100644 --- a/java-maps-routeoptimization/README.md +++ b/java-maps-routeoptimization/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-routeoptimization - 0.60.0 + 0.61.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-routeoptimization:0.60.0' +implementation 'com.google.maps:google-maps-routeoptimization:0.61.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-routeoptimization" % "0.60.0" +libraryDependencies += "com.google.maps" % "google-maps-routeoptimization" % "0.61.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-routeoptimization/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-routeoptimization.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-routeoptimization/0.60.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-routeoptimization/0.61.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-routing/README.md b/java-maps-routing/README.md index 87c104ad55cd..791d0602396c 100644 --- a/java-maps-routing/README.md +++ b/java-maps-routing/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-routing - 1.87.0 + 1.88.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-routing:1.87.0' +implementation 'com.google.maps:google-maps-routing:1.88.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-routing" % "1.87.0" +libraryDependencies += "com.google.maps" % "google-maps-routing" % "1.88.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-routing/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-routing.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-routing/1.87.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-routing/1.88.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-maps-solar/README.md b/java-maps-solar/README.md index 547c07e90b93..a3c715ee50f1 100644 --- a/java-maps-solar/README.md +++ b/java-maps-solar/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.maps google-maps-solar - 0.61.0 + 0.62.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.maps:google-maps-solar:0.61.0' +implementation 'com.google.maps:google-maps-solar:0.62.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.maps" % "google-maps-solar" % "0.61.0" +libraryDependencies += "com.google.maps" % "google-maps-solar" % "0.62.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-maps-solar/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.maps/google-maps-solar.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-solar/0.61.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.maps/google-maps-solar/0.62.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-marketingplatformadminapi/README.md b/java-marketingplatformadminapi/README.md index cf9115d30afd..60d77f45b283 100644 --- a/java-marketingplatformadminapi/README.md +++ b/java-marketingplatformadminapi/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.ads-marketingplatform admin - 0.51.0 + 0.52.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.ads-marketingplatform:admin:0.51.0' +implementation 'com.google.ads-marketingplatform:admin:0.52.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.ads-marketingplatform" % "admin" % "0.51.0" +libraryDependencies += "com.google.ads-marketingplatform" % "admin" % "0.52.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/admin/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.ads-marketingplatform/admin.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.ads-marketingplatform/admin/0.51.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.ads-marketingplatform/admin/0.52.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-mediatranslation/README.md b/java-mediatranslation/README.md index 38a1e7d0981b..12970fab03c1 100644 --- a/java-mediatranslation/README.md +++ b/java-mediatranslation/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-mediatranslation - 0.108.0 + 0.109.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-mediatranslation' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-mediatranslation:0.108.0' +implementation 'com.google.cloud:google-cloud-mediatranslation:0.109.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-mediatranslation" % "0.108.0" +libraryDependencies += "com.google.cloud" % "google-cloud-mediatranslation" % "0.109.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-mediatranslation/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-mediatranslation.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-mediatranslation/0.108.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-mediatranslation/0.109.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-meet/README.md b/java-meet/README.md index 199ca1375000..b5ee336dd944 100644 --- a/java-meet/README.md +++ b/java-meet/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-meet - 0.69.0 + 0.70.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-meet' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-meet:0.69.0' +implementation 'com.google.cloud:google-cloud-meet:0.70.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-meet" % "0.69.0" +libraryDependencies += "com.google.cloud" % "google-cloud-meet" % "0.70.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-meet/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-meet.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-meet/0.69.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-meet/0.70.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-memcache/README.md b/java-memcache/README.md index db17ff570d20..08fd9047c459 100644 --- a/java-memcache/README.md +++ b/java-memcache/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-memcache - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-memcache' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-memcache:2.102.0' +implementation 'com.google.cloud:google-cloud-memcache:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-memcache" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-memcache" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-memcache/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-memcache.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-memcache/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-memcache/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-migrationcenter/README.md b/java-migrationcenter/README.md index 5e25d638cde7..4e8b832f965f 100644 --- a/java-migrationcenter/README.md +++ b/java-migrationcenter/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-migrationcenter - 0.84.0 + 0.85.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-migrationcenter' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-migrationcenter:0.84.0' +implementation 'com.google.cloud:google-cloud-migrationcenter:0.85.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-migrationcenter" % "0.84.0" +libraryDependencies += "com.google.cloud" % "google-cloud-migrationcenter" % "0.85.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-migrationcenter/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-migrationcenter.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-migrationcenter/0.84.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-migrationcenter/0.85.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-modelarmor/README.md b/java-modelarmor/README.md index eb798ed23508..25a9d34d0640 100644 --- a/java-modelarmor/README.md +++ b/java-modelarmor/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-modelarmor - 0.43.0 + 0.44.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-modelarmor' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-modelarmor:0.43.0' +implementation 'com.google.cloud:google-cloud-modelarmor:0.44.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-modelarmor" % "0.43.0" +libraryDependencies += "com.google.cloud" % "google-cloud-modelarmor" % "0.44.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-modelarmor/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-modelarmor.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-modelarmor/0.43.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-modelarmor/0.44.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-monitoring-dashboards/README.md b/java-monitoring-dashboards/README.md index ca28b7d0de97..eb99646a85d5 100644 --- a/java-monitoring-dashboards/README.md +++ b/java-monitoring-dashboards/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-monitoring-dashboard - 2.104.0 + 2.105.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-monitoring-dashboard' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-monitoring-dashboard:2.104.0' +implementation 'com.google.cloud:google-cloud-monitoring-dashboard:2.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-monitoring-dashboard" % "2.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-monitoring-dashboard" % "2.105.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-monitoring-dashboard/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-monitoring-dashboard.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-monitoring-dashboard/2.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-monitoring-dashboard/2.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-monitoring-metricsscope/README.md b/java-monitoring-metricsscope/README.md index 7cd3d1c6979b..8bd6fc6b2d20 100644 --- a/java-monitoring-metricsscope/README.md +++ b/java-monitoring-metricsscope/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-monitoring-metricsscope - 0.96.0 + 0.97.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-monitoring-metricsscope' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-monitoring-metricsscope:0.96.0' +implementation 'com.google.cloud:google-cloud-monitoring-metricsscope:0.97.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-monitoring-metricsscope" % "0.96.0" +libraryDependencies += "com.google.cloud" % "google-cloud-monitoring-metricsscope" % "0.97.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-monitoring-metricsscope/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-monitoring-metricsscope.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-monitoring-metricsscope/0.96.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-monitoring-metricsscope/0.97.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-monitoring/README.md b/java-monitoring/README.md index 7e5ce57b8151..390de4b52fe9 100644 --- a/java-monitoring/README.md +++ b/java-monitoring/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-monitoring - 3.103.0 + 3.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-monitoring' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-monitoring:3.103.0' +implementation 'com.google.cloud:google-cloud-monitoring:3.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-monitoring" % "3.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-monitoring" % "3.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-monitoring/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-monitoring.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-monitoring/3.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-monitoring/3.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-netapp/README.md b/java-netapp/README.md index 42aab28c641d..87c1ad1e815d 100644 --- a/java-netapp/README.md +++ b/java-netapp/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-netapp - 0.81.0 + 0.82.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-netapp' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-netapp:0.81.0' +implementation 'com.google.cloud:google-cloud-netapp:0.82.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-netapp" % "0.81.0" +libraryDependencies += "com.google.cloud" % "google-cloud-netapp" % "0.82.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-netapp/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-netapp.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-netapp/0.81.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-netapp/0.82.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-network-management/README.md b/java-network-management/README.md index 00a0d6225acf..f87aeb8a5cc3 100644 --- a/java-network-management/README.md +++ b/java-network-management/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-network-management - 1.103.0 + 1.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-network-management' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-network-management:1.103.0' +implementation 'com.google.cloud:google-cloud-network-management:1.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-network-management" % "1.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-network-management" % "1.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-network-management/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-network-management.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-network-management/1.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-network-management/1.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-network-security/README.md b/java-network-security/README.md index 54a5b754e453..d0999a5caf6c 100644 --- a/java-network-security/README.md +++ b/java-network-security/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-network-security - 0.105.0 + 0.106.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-network-security' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-network-security:0.105.0' +implementation 'com.google.cloud:google-cloud-network-security:0.106.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-network-security" % "0.105.0" +libraryDependencies += "com.google.cloud" % "google-cloud-network-security" % "0.106.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-network-security/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-network-security.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-network-security/0.105.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-network-security/0.106.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-networkconnectivity/README.md b/java-networkconnectivity/README.md index 522110cc7284..8489debaeb00 100644 --- a/java-networkconnectivity/README.md +++ b/java-networkconnectivity/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-networkconnectivity - 1.101.0 + 1.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-networkconnectivity' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-networkconnectivity:1.101.0' +implementation 'com.google.cloud:google-cloud-networkconnectivity:1.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-networkconnectivity" % "1.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-networkconnectivity" % "1.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-networkconnectivity/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-networkconnectivity.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-networkconnectivity/1.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-networkconnectivity/1.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceClient.java b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceClient.java index 9436644bba05..7853c5ff85c3 100644 --- a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceClient.java +++ b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceClient.java @@ -541,6 +541,104 @@ * * * + *

            CreateGatewayAdvertisedRoute + *

            Create a GatewayAdvertisedRoute + * + *

            Request object method variants only take one parameter, a request object, which must be constructed before the call.

            + *
              + *
            • createGatewayAdvertisedRouteAsync(CreateGatewayAdvertisedRouteRequest request) + *

            + *

            Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

            + *
              + *
            • createGatewayAdvertisedRouteAsync(SpokeName parent, GatewayAdvertisedRoute gatewayAdvertisedRoute, String gatewayAdvertisedRouteId) + *

            • createGatewayAdvertisedRouteAsync(String parent, GatewayAdvertisedRoute gatewayAdvertisedRoute, String gatewayAdvertisedRouteId) + *

            + *

            Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

            + *
              + *
            • createGatewayAdvertisedRouteOperationCallable() + *

            • createGatewayAdvertisedRouteCallable() + *

            + * + * + * + *

            GetGatewayAdvertisedRoute + *

            Get a GatewayAdvertisedRoute + * + *

            Request object method variants only take one parameter, a request object, which must be constructed before the call.

            + *
              + *
            • getGatewayAdvertisedRoute(GetGatewayAdvertisedRouteRequest request) + *

            + *

            "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

            + *
              + *
            • getGatewayAdvertisedRoute(GatewayAdvertisedRouteName name) + *

            • getGatewayAdvertisedRoute(String name) + *

            + *

            Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

            + *
              + *
            • getGatewayAdvertisedRouteCallable() + *

            + * + * + * + *

            ListGatewayAdvertisedRoutes + *

            List GatewayAdvertisedRoutes + * + *

            Request object method variants only take one parameter, a request object, which must be constructed before the call.

            + *
              + *
            • listGatewayAdvertisedRoutes(ListGatewayAdvertisedRoutesRequest request) + *

            + *

            "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

            + *
              + *
            • listGatewayAdvertisedRoutes(SpokeName parent) + *

            • listGatewayAdvertisedRoutes(String parent) + *

            + *

            Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

            + *
              + *
            • listGatewayAdvertisedRoutesPagedCallable() + *

            • listGatewayAdvertisedRoutesCallable() + *

            + * + * + * + *

            UpdateGatewayAdvertisedRoute + *

            Update a GatewayAdvertisedRoute + * + *

            Request object method variants only take one parameter, a request object, which must be constructed before the call.

            + *
              + *
            • updateGatewayAdvertisedRouteAsync(UpdateGatewayAdvertisedRouteRequest request) + *

            + *

            Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

            + *
              + *
            • updateGatewayAdvertisedRouteAsync(GatewayAdvertisedRoute gatewayAdvertisedRoute, FieldMask updateMask) + *

            + *

            Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

            + *
              + *
            • updateGatewayAdvertisedRouteOperationCallable() + *

            • updateGatewayAdvertisedRouteCallable() + *

            + * + * + * + *

            DeleteGatewayAdvertisedRoute + *

            Delete a GatewayAdvertisedRoute + * + *

            Request object method variants only take one parameter, a request object, which must be constructed before the call.

            + *
              + *
            • deleteGatewayAdvertisedRouteAsync(DeleteGatewayAdvertisedRouteRequest request) + *

            + *

            Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

            + *
              + *
            • deleteGatewayAdvertisedRouteAsync(GatewayAdvertisedRouteName name) + *

            • deleteGatewayAdvertisedRouteAsync(String name) + *

            + *

            Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

            + *
              + *
            • deleteGatewayAdvertisedRouteOperationCallable() + *

            • deleteGatewayAdvertisedRouteCallable() + *

            + * + * + * *

            ListLocations *

            Lists information about the supported locations for this service. * @@ -4353,7 +4451,7 @@ public final UnaryCallable updateGroupCallable() // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists information about the supported locations for this service. + * Create a GatewayAdvertisedRoute * *

            Sample code: * @@ -4364,29 +4462,39 @@ public final UnaryCallable updateGroupCallable() * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (HubServiceClient hubServiceClient = HubServiceClient.create()) { - * ListLocationsRequest request = - * ListLocationsRequest.newBuilder() - * .setName("name3373707") - * .setFilter("filter-1274492040") - * .setPageSize(883849137) - * .setPageToken("pageToken873572522") - * .build(); - * for (Location element : hubServiceClient.listLocations(request).iterateAll()) { - * // doThingsWith(element); - * } + * SpokeName parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); + * GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build(); + * String gatewayAdvertisedRouteId = "gatewayAdvertisedRouteId1531070339"; + * GatewayAdvertisedRoute response = + * hubServiceClient + * .createGatewayAdvertisedRouteAsync( + * parent, gatewayAdvertisedRoute, gatewayAdvertisedRouteId) + * .get(); * } * }

            * - * @param request The request object containing all of the parameters for the API call. + * @param parent Required. The parent resource. + * @param gatewayAdvertisedRoute Required. Initial values for the new gateway advertised route. + * @param gatewayAdvertisedRouteId Required. Unique id for the route to create. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final ListLocationsPagedResponse listLocations(ListLocationsRequest request) { - return listLocationsPagedCallable().call(request); + public final OperationFuture + createGatewayAdvertisedRouteAsync( + @Nullable SpokeName parent, + GatewayAdvertisedRoute gatewayAdvertisedRoute, + String gatewayAdvertisedRouteId) { + CreateGatewayAdvertisedRouteRequest request = + CreateGatewayAdvertisedRouteRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setGatewayAdvertisedRoute(gatewayAdvertisedRoute) + .setGatewayAdvertisedRouteId(gatewayAdvertisedRouteId) + .build(); + return createGatewayAdvertisedRouteAsync(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists information about the supported locations for this service. + * Create a GatewayAdvertisedRoute * *

            Sample code: * @@ -4397,30 +4505,39 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (HubServiceClient hubServiceClient = HubServiceClient.create()) { - * ListLocationsRequest request = - * ListLocationsRequest.newBuilder() - * .setName("name3373707") - * .setFilter("filter-1274492040") - * .setPageSize(883849137) - * .setPageToken("pageToken873572522") - * .build(); - * ApiFuture future = - * hubServiceClient.listLocationsPagedCallable().futureCall(request); - * // Do something. - * for (Location element : future.get().iterateAll()) { - * // doThingsWith(element); - * } + * String parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString(); + * GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build(); + * String gatewayAdvertisedRouteId = "gatewayAdvertisedRouteId1531070339"; + * GatewayAdvertisedRoute response = + * hubServiceClient + * .createGatewayAdvertisedRouteAsync( + * parent, gatewayAdvertisedRoute, gatewayAdvertisedRouteId) + * .get(); * } * }

            + * + * @param parent Required. The parent resource. + * @param gatewayAdvertisedRoute Required. Initial values for the new gateway advertised route. + * @param gatewayAdvertisedRouteId Required. Unique id for the route to create. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final UnaryCallable - listLocationsPagedCallable() { - return stub.listLocationsPagedCallable(); + public final OperationFuture + createGatewayAdvertisedRouteAsync( + String parent, + GatewayAdvertisedRoute gatewayAdvertisedRoute, + String gatewayAdvertisedRouteId) { + CreateGatewayAdvertisedRouteRequest request = + CreateGatewayAdvertisedRouteRequest.newBuilder() + .setParent(parent) + .setGatewayAdvertisedRoute(gatewayAdvertisedRoute) + .setGatewayAdvertisedRouteId(gatewayAdvertisedRouteId) + .build(); + return createGatewayAdvertisedRouteAsync(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Lists information about the supported locations for this service. + * Create a GatewayAdvertisedRoute * *

            Sample code: * @@ -4431,35 +4548,29 @@ public final ListLocationsPagedResponse listLocations(ListLocationsRequest reque * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (HubServiceClient hubServiceClient = HubServiceClient.create()) { - * ListLocationsRequest request = - * ListLocationsRequest.newBuilder() - * .setName("name3373707") - * .setFilter("filter-1274492040") - * .setPageSize(883849137) - * .setPageToken("pageToken873572522") + * CreateGatewayAdvertisedRouteRequest request = + * CreateGatewayAdvertisedRouteRequest.newBuilder() + * .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) + * .setGatewayAdvertisedRouteId("gatewayAdvertisedRouteId1531070339") + * .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build()) + * .setRequestId("requestId693933066") * .build(); - * while (true) { - * ListLocationsResponse response = hubServiceClient.listLocationsCallable().call(request); - * for (Location element : response.getLocationsList()) { - * // doThingsWith(element); - * } - * String nextPageToken = response.getNextPageToken(); - * if (!Strings.isNullOrEmpty(nextPageToken)) { - * request = request.toBuilder().setPageToken(nextPageToken).build(); - * } else { - * break; - * } - * } + * GatewayAdvertisedRoute response = + * hubServiceClient.createGatewayAdvertisedRouteAsync(request).get(); * } * }

            + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final UnaryCallable listLocationsCallable() { - return stub.listLocationsCallable(); + public final OperationFuture + createGatewayAdvertisedRouteAsync(CreateGatewayAdvertisedRouteRequest request) { + return createGatewayAdvertisedRouteOperationCallable().futureCall(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets information about a location. + * Create a GatewayAdvertisedRoute * *

            Sample code: * @@ -4470,21 +4581,29 @@ public final UnaryCallable listLoca * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (HubServiceClient hubServiceClient = HubServiceClient.create()) { - * GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); - * Location response = hubServiceClient.getLocation(request); + * CreateGatewayAdvertisedRouteRequest request = + * CreateGatewayAdvertisedRouteRequest.newBuilder() + * .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) + * .setGatewayAdvertisedRouteId("gatewayAdvertisedRouteId1531070339") + * .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build()) + * .setRequestId("requestId693933066") + * .build(); + * OperationFuture future = + * hubServiceClient.createGatewayAdvertisedRouteOperationCallable().futureCall(request); + * // Do something. + * GatewayAdvertisedRoute response = future.get(); * } * }

            - * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Location getLocation(GetLocationRequest request) { - return getLocationCallable().call(request); + public final OperationCallable< + CreateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + createGatewayAdvertisedRouteOperationCallable() { + return stub.createGatewayAdvertisedRouteOperationCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets information about a location. + * Create a GatewayAdvertisedRoute * *

            Sample code: * @@ -4495,22 +4614,28 @@ public final Location getLocation(GetLocationRequest request) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (HubServiceClient hubServiceClient = HubServiceClient.create()) { - * GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); - * ApiFuture future = hubServiceClient.getLocationCallable().futureCall(request); + * CreateGatewayAdvertisedRouteRequest request = + * CreateGatewayAdvertisedRouteRequest.newBuilder() + * .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) + * .setGatewayAdvertisedRouteId("gatewayAdvertisedRouteId1531070339") + * .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build()) + * .setRequestId("requestId693933066") + * .build(); + * ApiFuture future = + * hubServiceClient.createGatewayAdvertisedRouteCallable().futureCall(request); * // Do something. - * Location response = future.get(); + * Operation response = future.get(); * } * }

            */ - public final UnaryCallable getLocationCallable() { - return stub.getLocationCallable(); + public final UnaryCallable + createGatewayAdvertisedRouteCallable() { + return stub.createGatewayAdvertisedRouteCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Sets the access control policy on the specified resource. Replacesany existing policy. - * - *

            Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`errors. + * Get a GatewayAdvertisedRoute * *

            Sample code: * @@ -4521,28 +4646,28 @@ public final UnaryCallable getLocationCallable() { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (HubServiceClient hubServiceClient = HubServiceClient.create()) { - * SetIamPolicyRequest request = - * SetIamPolicyRequest.newBuilder() - * .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString()) - * .setPolicy(Policy.newBuilder().build()) - * .setUpdateMask(FieldMask.newBuilder().build()) - * .build(); - * Policy response = hubServiceClient.setIamPolicy(request); + * GatewayAdvertisedRouteName name = + * GatewayAdvertisedRouteName.of( + * "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]"); + * GatewayAdvertisedRoute response = hubServiceClient.getGatewayAdvertisedRoute(name); * } * }

            * - * @param request The request object containing all of the parameters for the API call. + * @param name Required. The name of the gateway advertised route to get. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Policy setIamPolicy(SetIamPolicyRequest request) { - return setIamPolicyCallable().call(request); + public final GatewayAdvertisedRoute getGatewayAdvertisedRoute( + @Nullable GatewayAdvertisedRouteName name) { + GetGatewayAdvertisedRouteRequest request = + GetGatewayAdvertisedRouteRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getGatewayAdvertisedRoute(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Sets the access control policy on the specified resource. Replacesany existing policy. - * - *

            Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`errors. + * Get a GatewayAdvertisedRoute * *

            Sample code: * @@ -4553,26 +4678,26 @@ public final Policy setIamPolicy(SetIamPolicyRequest request) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (HubServiceClient hubServiceClient = HubServiceClient.create()) { - * SetIamPolicyRequest request = - * SetIamPolicyRequest.newBuilder() - * .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString()) - * .setPolicy(Policy.newBuilder().build()) - * .setUpdateMask(FieldMask.newBuilder().build()) - * .build(); - * ApiFuture future = hubServiceClient.setIamPolicyCallable().futureCall(request); - * // Do something. - * Policy response = future.get(); + * String name = + * GatewayAdvertisedRouteName.of( + * "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + * .toString(); + * GatewayAdvertisedRoute response = hubServiceClient.getGatewayAdvertisedRoute(name); * } * }

            + * + * @param name Required. The name of the gateway advertised route to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final UnaryCallable setIamPolicyCallable() { - return stub.setIamPolicyCallable(); + public final GatewayAdvertisedRoute getGatewayAdvertisedRoute(String name) { + GetGatewayAdvertisedRouteRequest request = + GetGatewayAdvertisedRouteRequest.newBuilder().setName(name).build(); + return getGatewayAdvertisedRoute(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets the access control policy for a resource. Returns an empty policyif the resource exists - * and does not have a policy set. + * Get a GatewayAdvertisedRoute * *

            Sample code: * @@ -4583,26 +4708,28 @@ public final UnaryCallable setIamPolicyCallable() { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (HubServiceClient hubServiceClient = HubServiceClient.create()) { - * GetIamPolicyRequest request = - * GetIamPolicyRequest.newBuilder() - * .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString()) - * .setOptions(GetPolicyOptions.newBuilder().build()) + * GetGatewayAdvertisedRouteRequest request = + * GetGatewayAdvertisedRouteRequest.newBuilder() + * .setName( + * GatewayAdvertisedRouteName.of( + * "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + * .toString()) * .build(); - * Policy response = hubServiceClient.getIamPolicy(request); + * GatewayAdvertisedRoute response = hubServiceClient.getGatewayAdvertisedRoute(request); * } * }

            * * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final Policy getIamPolicy(GetIamPolicyRequest request) { - return getIamPolicyCallable().call(request); + public final GatewayAdvertisedRoute getGatewayAdvertisedRoute( + GetGatewayAdvertisedRouteRequest request) { + return getGatewayAdvertisedRouteCallable().call(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Gets the access control policy for a resource. Returns an empty policyif the resource exists - * and does not have a policy set. + * Get a GatewayAdvertisedRoute * *

            Sample code: * @@ -4613,29 +4740,28 @@ public final Policy getIamPolicy(GetIamPolicyRequest request) { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (HubServiceClient hubServiceClient = HubServiceClient.create()) { - * GetIamPolicyRequest request = - * GetIamPolicyRequest.newBuilder() - * .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString()) - * .setOptions(GetPolicyOptions.newBuilder().build()) + * GetGatewayAdvertisedRouteRequest request = + * GetGatewayAdvertisedRouteRequest.newBuilder() + * .setName( + * GatewayAdvertisedRouteName.of( + * "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + * .toString()) * .build(); - * ApiFuture future = hubServiceClient.getIamPolicyCallable().futureCall(request); + * ApiFuture future = + * hubServiceClient.getGatewayAdvertisedRouteCallable().futureCall(request); * // Do something. - * Policy response = future.get(); + * GatewayAdvertisedRoute response = future.get(); * } * }

            */ - public final UnaryCallable getIamPolicyCallable() { - return stub.getIamPolicyCallable(); + public final UnaryCallable + getGatewayAdvertisedRouteCallable() { + return stub.getGatewayAdvertisedRouteCallable(); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Returns permissions that a caller has on the specified resource. If theresource does not exist, - * this will return an empty set ofpermissions, not a `NOT_FOUND` error. - * - *

            Note: This operation is designed to be used for buildingpermission-aware UIs and - * command-line tools, not for authorizationchecking. This operation may "fail open" without - * warning. + * List GatewayAdvertisedRoutes * *

            Sample code: * @@ -4646,30 +4772,29 @@ public final UnaryCallable getIamPolicyCallable() { * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (HubServiceClient hubServiceClient = HubServiceClient.create()) { - * TestIamPermissionsRequest request = - * TestIamPermissionsRequest.newBuilder() - * .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString()) - * .addAllPermissions(new ArrayList()) - * .build(); - * TestIamPermissionsResponse response = hubServiceClient.testIamPermissions(request); + * SpokeName parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); + * for (GatewayAdvertisedRoute element : + * hubServiceClient.listGatewayAdvertisedRoutes(parent).iterateAll()) { + * // doThingsWith(element); + * } * } * }

            * - * @param request The request object containing all of the parameters for the API call. + * @param parent Required. The parent resource's name. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsRequest request) { - return testIamPermissionsCallable().call(request); + public final ListGatewayAdvertisedRoutesPagedResponse listGatewayAdvertisedRoutes( + @Nullable SpokeName parent) { + ListGatewayAdvertisedRoutesRequest request = + ListGatewayAdvertisedRoutesRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listGatewayAdvertisedRoutes(request); } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Returns permissions that a caller has on the specified resource. If theresource does not exist, - * this will return an empty set ofpermissions, not a `NOT_FOUND` error. - * - *

            Note: This operation is designed to be used for buildingpermission-aware UIs and - * command-line tools, not for authorizationchecking. This operation may "fail open" without - * warning. + * List GatewayAdvertisedRoutes * *

            Sample code: * @@ -4680,35 +4805,796 @@ public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsReq * // - It may require specifying regional endpoints when creating the service client as shown in * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library * try (HubServiceClient hubServiceClient = HubServiceClient.create()) { - * TestIamPermissionsRequest request = - * TestIamPermissionsRequest.newBuilder() - * .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString()) - * .addAllPermissions(new ArrayList()) - * .build(); - * ApiFuture future = - * hubServiceClient.testIamPermissionsCallable().futureCall(request); - * // Do something. - * TestIamPermissionsResponse response = future.get(); + * String parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString(); + * for (GatewayAdvertisedRoute element : + * hubServiceClient.listGatewayAdvertisedRoutes(parent).iterateAll()) { + * // doThingsWith(element); + * } * } * }

            + * + * @param parent Required. The parent resource's name. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ - public final UnaryCallable - testIamPermissionsCallable() { - return stub.testIamPermissionsCallable(); - } - - @Override - public final void close() { - stub.close(); - } - - @Override - public void shutdown() { - stub.shutdown(); + public final ListGatewayAdvertisedRoutesPagedResponse listGatewayAdvertisedRoutes(String parent) { + ListGatewayAdvertisedRoutesRequest request = + ListGatewayAdvertisedRoutesRequest.newBuilder().setParent(parent).build(); + return listGatewayAdvertisedRoutes(request); } - @Override - public boolean isShutdown() { + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List GatewayAdvertisedRoutes + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   ListGatewayAdvertisedRoutesRequest request =
            +   *       ListGatewayAdvertisedRoutesRequest.newBuilder()
            +   *           .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString())
            +   *           .setPageSize(883849137)
            +   *           .setPageToken("pageToken873572522")
            +   *           .setFilter("filter-1274492040")
            +   *           .setOrderBy("orderBy-1207110587")
            +   *           .build();
            +   *   for (GatewayAdvertisedRoute element :
            +   *       hubServiceClient.listGatewayAdvertisedRoutes(request).iterateAll()) {
            +   *     // doThingsWith(element);
            +   *   }
            +   * }
            +   * }
            + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListGatewayAdvertisedRoutesPagedResponse listGatewayAdvertisedRoutes( + ListGatewayAdvertisedRoutesRequest request) { + return listGatewayAdvertisedRoutesPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List GatewayAdvertisedRoutes + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   ListGatewayAdvertisedRoutesRequest request =
            +   *       ListGatewayAdvertisedRoutesRequest.newBuilder()
            +   *           .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString())
            +   *           .setPageSize(883849137)
            +   *           .setPageToken("pageToken873572522")
            +   *           .setFilter("filter-1274492040")
            +   *           .setOrderBy("orderBy-1207110587")
            +   *           .build();
            +   *   ApiFuture future =
            +   *       hubServiceClient.listGatewayAdvertisedRoutesPagedCallable().futureCall(request);
            +   *   // Do something.
            +   *   for (GatewayAdvertisedRoute element : future.get().iterateAll()) {
            +   *     // doThingsWith(element);
            +   *   }
            +   * }
            +   * }
            + */ + public final UnaryCallable< + ListGatewayAdvertisedRoutesRequest, ListGatewayAdvertisedRoutesPagedResponse> + listGatewayAdvertisedRoutesPagedCallable() { + return stub.listGatewayAdvertisedRoutesPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List GatewayAdvertisedRoutes + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   ListGatewayAdvertisedRoutesRequest request =
            +   *       ListGatewayAdvertisedRoutesRequest.newBuilder()
            +   *           .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString())
            +   *           .setPageSize(883849137)
            +   *           .setPageToken("pageToken873572522")
            +   *           .setFilter("filter-1274492040")
            +   *           .setOrderBy("orderBy-1207110587")
            +   *           .build();
            +   *   while (true) {
            +   *     ListGatewayAdvertisedRoutesResponse response =
            +   *         hubServiceClient.listGatewayAdvertisedRoutesCallable().call(request);
            +   *     for (GatewayAdvertisedRoute element : response.getGatewayAdvertisedRoutesList()) {
            +   *       // doThingsWith(element);
            +   *     }
            +   *     String nextPageToken = response.getNextPageToken();
            +   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
            +   *       request = request.toBuilder().setPageToken(nextPageToken).build();
            +   *     } else {
            +   *       break;
            +   *     }
            +   *   }
            +   * }
            +   * }
            + */ + public final UnaryCallable< + ListGatewayAdvertisedRoutesRequest, ListGatewayAdvertisedRoutesResponse> + listGatewayAdvertisedRoutesCallable() { + return stub.listGatewayAdvertisedRoutesCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a GatewayAdvertisedRoute + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build();
            +   *   FieldMask updateMask = FieldMask.newBuilder().build();
            +   *   GatewayAdvertisedRoute response =
            +   *       hubServiceClient
            +   *           .updateGatewayAdvertisedRouteAsync(gatewayAdvertisedRoute, updateMask)
            +   *           .get();
            +   * }
            +   * }
            + * + * @param gatewayAdvertisedRoute Required. The gateway advertised route to update. + *

            The gateway advertised route's `name` field is used to identify the gateway advertised + * route to update. Format: + * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}` + * @param updateMask Optional. In the case of an update to an existing group, field mask is used + * to specify the fields to be overwritten. The fields specified in the update_mask are + * relative to the resource, not the full request. A field is overwritten if it is in the + * mask. If the user does not provide a mask, then all fields are overwritten. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + updateGatewayAdvertisedRouteAsync( + GatewayAdvertisedRoute gatewayAdvertisedRoute, FieldMask updateMask) { + UpdateGatewayAdvertisedRouteRequest request = + UpdateGatewayAdvertisedRouteRequest.newBuilder() + .setGatewayAdvertisedRoute(gatewayAdvertisedRoute) + .setUpdateMask(updateMask) + .build(); + return updateGatewayAdvertisedRouteAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a GatewayAdvertisedRoute + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   UpdateGatewayAdvertisedRouteRequest request =
            +   *       UpdateGatewayAdvertisedRouteRequest.newBuilder()
            +   *           .setUpdateMask(FieldMask.newBuilder().build())
            +   *           .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build())
            +   *           .setRequestId("requestId693933066")
            +   *           .build();
            +   *   GatewayAdvertisedRoute response =
            +   *       hubServiceClient.updateGatewayAdvertisedRouteAsync(request).get();
            +   * }
            +   * }
            + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture + updateGatewayAdvertisedRouteAsync(UpdateGatewayAdvertisedRouteRequest request) { + return updateGatewayAdvertisedRouteOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a GatewayAdvertisedRoute + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   UpdateGatewayAdvertisedRouteRequest request =
            +   *       UpdateGatewayAdvertisedRouteRequest.newBuilder()
            +   *           .setUpdateMask(FieldMask.newBuilder().build())
            +   *           .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build())
            +   *           .setRequestId("requestId693933066")
            +   *           .build();
            +   *   OperationFuture future =
            +   *       hubServiceClient.updateGatewayAdvertisedRouteOperationCallable().futureCall(request);
            +   *   // Do something.
            +   *   GatewayAdvertisedRoute response = future.get();
            +   * }
            +   * }
            + */ + public final OperationCallable< + UpdateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + updateGatewayAdvertisedRouteOperationCallable() { + return stub.updateGatewayAdvertisedRouteOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a GatewayAdvertisedRoute + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   UpdateGatewayAdvertisedRouteRequest request =
            +   *       UpdateGatewayAdvertisedRouteRequest.newBuilder()
            +   *           .setUpdateMask(FieldMask.newBuilder().build())
            +   *           .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build())
            +   *           .setRequestId("requestId693933066")
            +   *           .build();
            +   *   ApiFuture future =
            +   *       hubServiceClient.updateGatewayAdvertisedRouteCallable().futureCall(request);
            +   *   // Do something.
            +   *   Operation response = future.get();
            +   * }
            +   * }
            + */ + public final UnaryCallable + updateGatewayAdvertisedRouteCallable() { + return stub.updateGatewayAdvertisedRouteCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a GatewayAdvertisedRoute + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   GatewayAdvertisedRouteName name =
            +   *       GatewayAdvertisedRouteName.of(
            +   *           "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]");
            +   *   hubServiceClient.deleteGatewayAdvertisedRouteAsync(name).get();
            +   * }
            +   * }
            + * + * @param name Required. The name of the gateway advertised route to delete. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteGatewayAdvertisedRouteAsync( + @Nullable GatewayAdvertisedRouteName name) { + DeleteGatewayAdvertisedRouteRequest request = + DeleteGatewayAdvertisedRouteRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return deleteGatewayAdvertisedRouteAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a GatewayAdvertisedRoute + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   String name =
            +   *       GatewayAdvertisedRouteName.of(
            +   *               "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]")
            +   *           .toString();
            +   *   hubServiceClient.deleteGatewayAdvertisedRouteAsync(name).get();
            +   * }
            +   * }
            + * + * @param name Required. The name of the gateway advertised route to delete. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteGatewayAdvertisedRouteAsync( + String name) { + DeleteGatewayAdvertisedRouteRequest request = + DeleteGatewayAdvertisedRouteRequest.newBuilder().setName(name).build(); + return deleteGatewayAdvertisedRouteAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a GatewayAdvertisedRoute + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   DeleteGatewayAdvertisedRouteRequest request =
            +   *       DeleteGatewayAdvertisedRouteRequest.newBuilder()
            +   *           .setName(
            +   *               GatewayAdvertisedRouteName.of(
            +   *                       "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]")
            +   *                   .toString())
            +   *           .setRequestId("requestId693933066")
            +   *           .build();
            +   *   hubServiceClient.deleteGatewayAdvertisedRouteAsync(request).get();
            +   * }
            +   * }
            + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteGatewayAdvertisedRouteAsync( + DeleteGatewayAdvertisedRouteRequest request) { + return deleteGatewayAdvertisedRouteOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a GatewayAdvertisedRoute + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   DeleteGatewayAdvertisedRouteRequest request =
            +   *       DeleteGatewayAdvertisedRouteRequest.newBuilder()
            +   *           .setName(
            +   *               GatewayAdvertisedRouteName.of(
            +   *                       "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]")
            +   *                   .toString())
            +   *           .setRequestId("requestId693933066")
            +   *           .build();
            +   *   OperationFuture future =
            +   *       hubServiceClient.deleteGatewayAdvertisedRouteOperationCallable().futureCall(request);
            +   *   // Do something.
            +   *   future.get();
            +   * }
            +   * }
            + */ + public final OperationCallable + deleteGatewayAdvertisedRouteOperationCallable() { + return stub.deleteGatewayAdvertisedRouteOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a GatewayAdvertisedRoute + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   DeleteGatewayAdvertisedRouteRequest request =
            +   *       DeleteGatewayAdvertisedRouteRequest.newBuilder()
            +   *           .setName(
            +   *               GatewayAdvertisedRouteName.of(
            +   *                       "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]")
            +   *                   .toString())
            +   *           .setRequestId("requestId693933066")
            +   *           .build();
            +   *   ApiFuture future =
            +   *       hubServiceClient.deleteGatewayAdvertisedRouteCallable().futureCall(request);
            +   *   // Do something.
            +   *   future.get();
            +   * }
            +   * }
            + */ + public final UnaryCallable + deleteGatewayAdvertisedRouteCallable() { + return stub.deleteGatewayAdvertisedRouteCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   ListLocationsRequest request =
            +   *       ListLocationsRequest.newBuilder()
            +   *           .setName("name3373707")
            +   *           .setFilter("filter-1274492040")
            +   *           .setPageSize(883849137)
            +   *           .setPageToken("pageToken873572522")
            +   *           .build();
            +   *   for (Location element : hubServiceClient.listLocations(request).iterateAll()) {
            +   *     // doThingsWith(element);
            +   *   }
            +   * }
            +   * }
            + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListLocationsPagedResponse listLocations(ListLocationsRequest request) { + return listLocationsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   ListLocationsRequest request =
            +   *       ListLocationsRequest.newBuilder()
            +   *           .setName("name3373707")
            +   *           .setFilter("filter-1274492040")
            +   *           .setPageSize(883849137)
            +   *           .setPageToken("pageToken873572522")
            +   *           .build();
            +   *   ApiFuture future =
            +   *       hubServiceClient.listLocationsPagedCallable().futureCall(request);
            +   *   // Do something.
            +   *   for (Location element : future.get().iterateAll()) {
            +   *     // doThingsWith(element);
            +   *   }
            +   * }
            +   * }
            + */ + public final UnaryCallable + listLocationsPagedCallable() { + return stub.listLocationsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   ListLocationsRequest request =
            +   *       ListLocationsRequest.newBuilder()
            +   *           .setName("name3373707")
            +   *           .setFilter("filter-1274492040")
            +   *           .setPageSize(883849137)
            +   *           .setPageToken("pageToken873572522")
            +   *           .build();
            +   *   while (true) {
            +   *     ListLocationsResponse response = hubServiceClient.listLocationsCallable().call(request);
            +   *     for (Location element : response.getLocationsList()) {
            +   *       // doThingsWith(element);
            +   *     }
            +   *     String nextPageToken = response.getNextPageToken();
            +   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
            +   *       request = request.toBuilder().setPageToken(nextPageToken).build();
            +   *     } else {
            +   *       break;
            +   *     }
            +   *   }
            +   * }
            +   * }
            + */ + public final UnaryCallable listLocationsCallable() { + return stub.listLocationsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets information about a location. + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
            +   *   Location response = hubServiceClient.getLocation(request);
            +   * }
            +   * }
            + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Location getLocation(GetLocationRequest request) { + return getLocationCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets information about a location. + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
            +   *   ApiFuture future = hubServiceClient.getLocationCallable().futureCall(request);
            +   *   // Do something.
            +   *   Location response = future.get();
            +   * }
            +   * }
            + */ + public final UnaryCallable getLocationCallable() { + return stub.getLocationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Sets the access control policy on the specified resource. Replacesany existing policy. + * + *

            Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`errors. + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   SetIamPolicyRequest request =
            +   *       SetIamPolicyRequest.newBuilder()
            +   *           .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString())
            +   *           .setPolicy(Policy.newBuilder().build())
            +   *           .setUpdateMask(FieldMask.newBuilder().build())
            +   *           .build();
            +   *   Policy response = hubServiceClient.setIamPolicy(request);
            +   * }
            +   * }
            + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Policy setIamPolicy(SetIamPolicyRequest request) { + return setIamPolicyCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Sets the access control policy on the specified resource. Replacesany existing policy. + * + *

            Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`errors. + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   SetIamPolicyRequest request =
            +   *       SetIamPolicyRequest.newBuilder()
            +   *           .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString())
            +   *           .setPolicy(Policy.newBuilder().build())
            +   *           .setUpdateMask(FieldMask.newBuilder().build())
            +   *           .build();
            +   *   ApiFuture future = hubServiceClient.setIamPolicyCallable().futureCall(request);
            +   *   // Do something.
            +   *   Policy response = future.get();
            +   * }
            +   * }
            + */ + public final UnaryCallable setIamPolicyCallable() { + return stub.setIamPolicyCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the access control policy for a resource. Returns an empty policyif the resource exists + * and does not have a policy set. + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   GetIamPolicyRequest request =
            +   *       GetIamPolicyRequest.newBuilder()
            +   *           .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString())
            +   *           .setOptions(GetPolicyOptions.newBuilder().build())
            +   *           .build();
            +   *   Policy response = hubServiceClient.getIamPolicy(request);
            +   * }
            +   * }
            + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Policy getIamPolicy(GetIamPolicyRequest request) { + return getIamPolicyCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the access control policy for a resource. Returns an empty policyif the resource exists + * and does not have a policy set. + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   GetIamPolicyRequest request =
            +   *       GetIamPolicyRequest.newBuilder()
            +   *           .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString())
            +   *           .setOptions(GetPolicyOptions.newBuilder().build())
            +   *           .build();
            +   *   ApiFuture future = hubServiceClient.getIamPolicyCallable().futureCall(request);
            +   *   // Do something.
            +   *   Policy response = future.get();
            +   * }
            +   * }
            + */ + public final UnaryCallable getIamPolicyCallable() { + return stub.getIamPolicyCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns permissions that a caller has on the specified resource. If theresource does not exist, + * this will return an empty set ofpermissions, not a `NOT_FOUND` error. + * + *

            Note: This operation is designed to be used for buildingpermission-aware UIs and + * command-line tools, not for authorizationchecking. This operation may "fail open" without + * warning. + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   TestIamPermissionsRequest request =
            +   *       TestIamPermissionsRequest.newBuilder()
            +   *           .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString())
            +   *           .addAllPermissions(new ArrayList())
            +   *           .build();
            +   *   TestIamPermissionsResponse response = hubServiceClient.testIamPermissions(request);
            +   * }
            +   * }
            + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsRequest request) { + return testIamPermissionsCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns permissions that a caller has on the specified resource. If theresource does not exist, + * this will return an empty set ofpermissions, not a `NOT_FOUND` error. + * + *

            Note: This operation is designed to be used for buildingpermission-aware UIs and + * command-line tools, not for authorizationchecking. This operation may "fail open" without + * warning. + * + *

            Sample code: + * + *

            {@code
            +   * // This snippet has been automatically generated and should be regarded as a code template only.
            +   * // It will require modifications to work:
            +   * // - It may require correct/in-range values for request initialization.
            +   * // - It may require specifying regional endpoints when creating the service client as shown in
            +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
            +   * try (HubServiceClient hubServiceClient = HubServiceClient.create()) {
            +   *   TestIamPermissionsRequest request =
            +   *       TestIamPermissionsRequest.newBuilder()
            +   *           .setResource(GroupName.of("[PROJECT]", "[HUB]", "[GROUP]").toString())
            +   *           .addAllPermissions(new ArrayList())
            +   *           .build();
            +   *   ApiFuture future =
            +   *       hubServiceClient.testIamPermissionsCallable().futureCall(request);
            +   *   // Do something.
            +   *   TestIamPermissionsResponse response = future.get();
            +   * }
            +   * }
            + */ + public final UnaryCallable + testIamPermissionsCallable() { + return stub.testIamPermissionsCallable(); + } + + @Override + public final void close() { + stub.close(); + } + + @Override + public void shutdown() { + stub.shutdown(); + } + + @Override + public boolean isShutdown() { return stub.isShutdown(); } @@ -5247,6 +6133,106 @@ protected ListGroupsFixedSizeCollection createCollection( } } + public static class ListGatewayAdvertisedRoutesPagedResponse + extends AbstractPagedListResponse< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + GatewayAdvertisedRoute, + ListGatewayAdvertisedRoutesPage, + ListGatewayAdvertisedRoutesFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + GatewayAdvertisedRoute> + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListGatewayAdvertisedRoutesPage.createEmptyPage() + .createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListGatewayAdvertisedRoutesPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListGatewayAdvertisedRoutesPagedResponse(ListGatewayAdvertisedRoutesPage page) { + super(page, ListGatewayAdvertisedRoutesFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListGatewayAdvertisedRoutesPage + extends AbstractPage< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + GatewayAdvertisedRoute, + ListGatewayAdvertisedRoutesPage> { + + private ListGatewayAdvertisedRoutesPage( + @Nullable + PageContext< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + GatewayAdvertisedRoute> + context, + @Nullable ListGatewayAdvertisedRoutesResponse response) { + super(context, response); + } + + private static ListGatewayAdvertisedRoutesPage createEmptyPage() { + return new ListGatewayAdvertisedRoutesPage(null, null); + } + + @Override + protected ListGatewayAdvertisedRoutesPage createPage( + @Nullable + PageContext< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + GatewayAdvertisedRoute> + context, + @Nullable ListGatewayAdvertisedRoutesResponse response) { + return new ListGatewayAdvertisedRoutesPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable + PageContext< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + GatewayAdvertisedRoute> + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListGatewayAdvertisedRoutesFixedSizeCollection + extends AbstractFixedSizeCollection< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + GatewayAdvertisedRoute, + ListGatewayAdvertisedRoutesPage, + ListGatewayAdvertisedRoutesFixedSizeCollection> { + + private ListGatewayAdvertisedRoutesFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListGatewayAdvertisedRoutesFixedSizeCollection createEmptyCollection() { + return new ListGatewayAdvertisedRoutesFixedSizeCollection(null, 0); + } + + @Override + protected ListGatewayAdvertisedRoutesFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListGatewayAdvertisedRoutesFixedSizeCollection(pages, collectionSize); + } + } + public static class ListLocationsPagedResponse extends AbstractPagedListResponse< ListLocationsRequest, diff --git a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceSettings.java b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceSettings.java index 889eecb6bb8b..92304e01ea04 100644 --- a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceSettings.java +++ b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceSettings.java @@ -16,6 +16,7 @@ package com.google.cloud.networkconnectivity.v1; +import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListGatewayAdvertisedRoutesPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListGroupsPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListHubSpokesPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListHubsPagedResponse; @@ -325,6 +326,62 @@ public UnaryCallSettings updateGroupSettings() { return ((HubServiceStubSettings) getStubSettings()).updateGroupOperationSettings(); } + /** Returns the object with the settings used for calls to createGatewayAdvertisedRoute. */ + public UnaryCallSettings + createGatewayAdvertisedRouteSettings() { + return ((HubServiceStubSettings) getStubSettings()).createGatewayAdvertisedRouteSettings(); + } + + /** Returns the object with the settings used for calls to createGatewayAdvertisedRoute. */ + public OperationCallSettings< + CreateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + createGatewayAdvertisedRouteOperationSettings() { + return ((HubServiceStubSettings) getStubSettings()) + .createGatewayAdvertisedRouteOperationSettings(); + } + + /** Returns the object with the settings used for calls to getGatewayAdvertisedRoute. */ + public UnaryCallSettings + getGatewayAdvertisedRouteSettings() { + return ((HubServiceStubSettings) getStubSettings()).getGatewayAdvertisedRouteSettings(); + } + + /** Returns the object with the settings used for calls to listGatewayAdvertisedRoutes. */ + public PagedCallSettings< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + ListGatewayAdvertisedRoutesPagedResponse> + listGatewayAdvertisedRoutesSettings() { + return ((HubServiceStubSettings) getStubSettings()).listGatewayAdvertisedRoutesSettings(); + } + + /** Returns the object with the settings used for calls to updateGatewayAdvertisedRoute. */ + public UnaryCallSettings + updateGatewayAdvertisedRouteSettings() { + return ((HubServiceStubSettings) getStubSettings()).updateGatewayAdvertisedRouteSettings(); + } + + /** Returns the object with the settings used for calls to updateGatewayAdvertisedRoute. */ + public OperationCallSettings< + UpdateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + updateGatewayAdvertisedRouteOperationSettings() { + return ((HubServiceStubSettings) getStubSettings()) + .updateGatewayAdvertisedRouteOperationSettings(); + } + + /** Returns the object with the settings used for calls to deleteGatewayAdvertisedRoute. */ + public UnaryCallSettings + deleteGatewayAdvertisedRouteSettings() { + return ((HubServiceStubSettings) getStubSettings()).deleteGatewayAdvertisedRouteSettings(); + } + + /** Returns the object with the settings used for calls to deleteGatewayAdvertisedRoute. */ + public OperationCallSettings + deleteGatewayAdvertisedRouteOperationSettings() { + return ((HubServiceStubSettings) getStubSettings()) + .deleteGatewayAdvertisedRouteOperationSettings(); + } + /** Returns the object with the settings used for calls to listLocations. */ public PagedCallSettings listLocationsSettings() { @@ -644,6 +701,60 @@ public UnaryCallSettings.Builder updateGroupSetti return getStubSettingsBuilder().updateGroupOperationSettings(); } + /** Returns the builder for the settings used for calls to createGatewayAdvertisedRoute. */ + public UnaryCallSettings.Builder + createGatewayAdvertisedRouteSettings() { + return getStubSettingsBuilder().createGatewayAdvertisedRouteSettings(); + } + + /** Returns the builder for the settings used for calls to createGatewayAdvertisedRoute. */ + public OperationCallSettings.Builder< + CreateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + createGatewayAdvertisedRouteOperationSettings() { + return getStubSettingsBuilder().createGatewayAdvertisedRouteOperationSettings(); + } + + /** Returns the builder for the settings used for calls to getGatewayAdvertisedRoute. */ + public UnaryCallSettings.Builder + getGatewayAdvertisedRouteSettings() { + return getStubSettingsBuilder().getGatewayAdvertisedRouteSettings(); + } + + /** Returns the builder for the settings used for calls to listGatewayAdvertisedRoutes. */ + public PagedCallSettings.Builder< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + ListGatewayAdvertisedRoutesPagedResponse> + listGatewayAdvertisedRoutesSettings() { + return getStubSettingsBuilder().listGatewayAdvertisedRoutesSettings(); + } + + /** Returns the builder for the settings used for calls to updateGatewayAdvertisedRoute. */ + public UnaryCallSettings.Builder + updateGatewayAdvertisedRouteSettings() { + return getStubSettingsBuilder().updateGatewayAdvertisedRouteSettings(); + } + + /** Returns the builder for the settings used for calls to updateGatewayAdvertisedRoute. */ + public OperationCallSettings.Builder< + UpdateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + updateGatewayAdvertisedRouteOperationSettings() { + return getStubSettingsBuilder().updateGatewayAdvertisedRouteOperationSettings(); + } + + /** Returns the builder for the settings used for calls to deleteGatewayAdvertisedRoute. */ + public UnaryCallSettings.Builder + deleteGatewayAdvertisedRouteSettings() { + return getStubSettingsBuilder().deleteGatewayAdvertisedRouteSettings(); + } + + /** Returns the builder for the settings used for calls to deleteGatewayAdvertisedRoute. */ + public OperationCallSettings.Builder< + DeleteGatewayAdvertisedRouteRequest, Empty, OperationMetadata> + deleteGatewayAdvertisedRouteOperationSettings() { + return getStubSettingsBuilder().deleteGatewayAdvertisedRouteOperationSettings(); + } + /** Returns the builder for the settings used for calls to listLocations. */ public PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> diff --git a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/gapic_metadata.json b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/gapic_metadata.json index c6ab18262922..d5207d193635 100644 --- a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/gapic_metadata.json +++ b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/gapic_metadata.json @@ -154,18 +154,27 @@ "AcceptSpokeUpdate": { "methods": ["acceptSpokeUpdateAsync", "acceptSpokeUpdateAsync", "acceptSpokeUpdateAsync", "acceptSpokeUpdateAsync", "acceptSpokeUpdateAsync", "acceptSpokeUpdateOperationCallable", "acceptSpokeUpdateCallable"] }, + "CreateGatewayAdvertisedRoute": { + "methods": ["createGatewayAdvertisedRouteAsync", "createGatewayAdvertisedRouteAsync", "createGatewayAdvertisedRouteAsync", "createGatewayAdvertisedRouteOperationCallable", "createGatewayAdvertisedRouteCallable"] + }, "CreateHub": { "methods": ["createHubAsync", "createHubAsync", "createHubAsync", "createHubOperationCallable", "createHubCallable"] }, "CreateSpoke": { "methods": ["createSpokeAsync", "createSpokeAsync", "createSpokeAsync", "createSpokeOperationCallable", "createSpokeCallable"] }, + "DeleteGatewayAdvertisedRoute": { + "methods": ["deleteGatewayAdvertisedRouteAsync", "deleteGatewayAdvertisedRouteAsync", "deleteGatewayAdvertisedRouteAsync", "deleteGatewayAdvertisedRouteOperationCallable", "deleteGatewayAdvertisedRouteCallable"] + }, "DeleteHub": { "methods": ["deleteHubAsync", "deleteHubAsync", "deleteHubAsync", "deleteHubOperationCallable", "deleteHubCallable"] }, "DeleteSpoke": { "methods": ["deleteSpokeAsync", "deleteSpokeAsync", "deleteSpokeAsync", "deleteSpokeOperationCallable", "deleteSpokeCallable"] }, + "GetGatewayAdvertisedRoute": { + "methods": ["getGatewayAdvertisedRoute", "getGatewayAdvertisedRoute", "getGatewayAdvertisedRoute", "getGatewayAdvertisedRouteCallable"] + }, "GetGroup": { "methods": ["getGroup", "getGroup", "getGroup", "getGroupCallable"] }, @@ -187,6 +196,9 @@ "GetSpoke": { "methods": ["getSpoke", "getSpoke", "getSpoke", "getSpokeCallable"] }, + "ListGatewayAdvertisedRoutes": { + "methods": ["listGatewayAdvertisedRoutes", "listGatewayAdvertisedRoutes", "listGatewayAdvertisedRoutes", "listGatewayAdvertisedRoutesPagedCallable", "listGatewayAdvertisedRoutesCallable"] + }, "ListGroups": { "methods": ["listGroups", "listGroups", "listGroups", "listGroupsPagedCallable", "listGroupsCallable"] }, @@ -223,6 +235,9 @@ "TestIamPermissions": { "methods": ["testIamPermissions", "testIamPermissionsCallable"] }, + "UpdateGatewayAdvertisedRoute": { + "methods": ["updateGatewayAdvertisedRouteAsync", "updateGatewayAdvertisedRouteAsync", "updateGatewayAdvertisedRouteOperationCallable", "updateGatewayAdvertisedRouteCallable"] + }, "UpdateGroup": { "methods": ["updateGroupAsync", "updateGroupAsync", "updateGroupOperationCallable", "updateGroupCallable"] }, diff --git a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/GrpcHubServiceStub.java b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/GrpcHubServiceStub.java index 8ab116327fe7..894b930906c8 100644 --- a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/GrpcHubServiceStub.java +++ b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/GrpcHubServiceStub.java @@ -16,6 +16,7 @@ package com.google.cloud.networkconnectivity.v1.stub; +import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListGatewayAdvertisedRoutesPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListGroupsPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListHubSpokesPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListHubsPagedResponse; @@ -41,10 +42,14 @@ import com.google.cloud.networkconnectivity.v1.AcceptHubSpokeResponse; import com.google.cloud.networkconnectivity.v1.AcceptSpokeUpdateRequest; import com.google.cloud.networkconnectivity.v1.AcceptSpokeUpdateResponse; +import com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.CreateHubRequest; import com.google.cloud.networkconnectivity.v1.CreateSpokeRequest; +import com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.DeleteHubRequest; import com.google.cloud.networkconnectivity.v1.DeleteSpokeRequest; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.GetGroupRequest; import com.google.cloud.networkconnectivity.v1.GetHubRequest; import com.google.cloud.networkconnectivity.v1.GetRouteRequest; @@ -52,6 +57,8 @@ import com.google.cloud.networkconnectivity.v1.GetSpokeRequest; import com.google.cloud.networkconnectivity.v1.Group; import com.google.cloud.networkconnectivity.v1.Hub; +import com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest; +import com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse; import com.google.cloud.networkconnectivity.v1.ListGroupsRequest; import com.google.cloud.networkconnectivity.v1.ListGroupsResponse; import com.google.cloud.networkconnectivity.v1.ListHubSpokesRequest; @@ -74,6 +81,7 @@ import com.google.cloud.networkconnectivity.v1.Route; import com.google.cloud.networkconnectivity.v1.RouteTable; import com.google.cloud.networkconnectivity.v1.Spoke; +import com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.UpdateGroupRequest; import com.google.cloud.networkconnectivity.v1.UpdateHubRequest; import com.google.cloud.networkconnectivity.v1.UpdateSpokeRequest; @@ -331,6 +339,70 @@ public class GrpcHubServiceStub extends HubServiceStub { .setSampledToLocalTracing(true) .build(); + private static final MethodDescriptor + createGatewayAdvertisedRouteMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.networkconnectivity.v1.HubService/CreateGatewayAdvertisedRoute") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateGatewayAdvertisedRouteRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getGatewayAdvertisedRouteMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.networkconnectivity.v1.HubService/GetGatewayAdvertisedRoute") + .setRequestMarshaller( + ProtoUtils.marshaller(GetGatewayAdvertisedRouteRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(GatewayAdvertisedRoute.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor< + ListGatewayAdvertisedRoutesRequest, ListGatewayAdvertisedRoutesResponse> + listGatewayAdvertisedRoutesMethodDescriptor = + MethodDescriptor + .newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.networkconnectivity.v1.HubService/ListGatewayAdvertisedRoutes") + .setRequestMarshaller( + ProtoUtils.marshaller(ListGatewayAdvertisedRoutesRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListGatewayAdvertisedRoutesResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + updateGatewayAdvertisedRouteMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.networkconnectivity.v1.HubService/UpdateGatewayAdvertisedRoute") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateGatewayAdvertisedRouteRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + deleteGatewayAdvertisedRouteMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.networkconnectivity.v1.HubService/DeleteGatewayAdvertisedRoute") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteGatewayAdvertisedRouteRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + private static final MethodDescriptor listLocationsMethodDescriptor = MethodDescriptor.newBuilder() @@ -440,6 +512,28 @@ public class GrpcHubServiceStub extends HubServiceStub { private final UnaryCallable updateGroupCallable; private final OperationCallable updateGroupOperationCallable; + private final UnaryCallable + createGatewayAdvertisedRouteCallable; + private final OperationCallable< + CreateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + createGatewayAdvertisedRouteOperationCallable; + private final UnaryCallable + getGatewayAdvertisedRouteCallable; + private final UnaryCallable< + ListGatewayAdvertisedRoutesRequest, ListGatewayAdvertisedRoutesResponse> + listGatewayAdvertisedRoutesCallable; + private final UnaryCallable< + ListGatewayAdvertisedRoutesRequest, ListGatewayAdvertisedRoutesPagedResponse> + listGatewayAdvertisedRoutesPagedCallable; + private final UnaryCallable + updateGatewayAdvertisedRouteCallable; + private final OperationCallable< + UpdateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + updateGatewayAdvertisedRouteOperationCallable; + private final UnaryCallable + deleteGatewayAdvertisedRouteCallable; + private final OperationCallable + deleteGatewayAdvertisedRouteOperationCallable; private final UnaryCallable listLocationsCallable; private final UnaryCallable listLocationsPagedCallable; @@ -743,6 +837,69 @@ protected GrpcHubServiceStub( return builder.build(); }) .build(); + GrpcCallSettings + createGatewayAdvertisedRouteTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createGatewayAdvertisedRouteMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings + getGatewayAdvertisedRouteTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getGatewayAdvertisedRouteMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings + listGatewayAdvertisedRoutesTransportSettings = + GrpcCallSettings + . + newBuilder() + .setMethodDescriptor(listGatewayAdvertisedRoutesMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings + updateGatewayAdvertisedRouteTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateGatewayAdvertisedRouteMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add( + "gateway_advertised_route.name", + String.valueOf(request.getGatewayAdvertisedRoute().getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings + deleteGatewayAdvertisedRouteTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteGatewayAdvertisedRouteMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); GrpcCallSettings listLocationsTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(listLocationsMethodDescriptor) @@ -958,6 +1115,54 @@ protected GrpcHubServiceStub( settings.updateGroupOperationSettings(), clientContext, operationsStub); + this.createGatewayAdvertisedRouteCallable = + callableFactory.createUnaryCallable( + createGatewayAdvertisedRouteTransportSettings, + settings.createGatewayAdvertisedRouteSettings(), + clientContext); + this.createGatewayAdvertisedRouteOperationCallable = + callableFactory.createOperationCallable( + createGatewayAdvertisedRouteTransportSettings, + settings.createGatewayAdvertisedRouteOperationSettings(), + clientContext, + operationsStub); + this.getGatewayAdvertisedRouteCallable = + callableFactory.createUnaryCallable( + getGatewayAdvertisedRouteTransportSettings, + settings.getGatewayAdvertisedRouteSettings(), + clientContext); + this.listGatewayAdvertisedRoutesCallable = + callableFactory.createUnaryCallable( + listGatewayAdvertisedRoutesTransportSettings, + settings.listGatewayAdvertisedRoutesSettings(), + clientContext); + this.listGatewayAdvertisedRoutesPagedCallable = + callableFactory.createPagedCallable( + listGatewayAdvertisedRoutesTransportSettings, + settings.listGatewayAdvertisedRoutesSettings(), + clientContext); + this.updateGatewayAdvertisedRouteCallable = + callableFactory.createUnaryCallable( + updateGatewayAdvertisedRouteTransportSettings, + settings.updateGatewayAdvertisedRouteSettings(), + clientContext); + this.updateGatewayAdvertisedRouteOperationCallable = + callableFactory.createOperationCallable( + updateGatewayAdvertisedRouteTransportSettings, + settings.updateGatewayAdvertisedRouteOperationSettings(), + clientContext, + operationsStub); + this.deleteGatewayAdvertisedRouteCallable = + callableFactory.createUnaryCallable( + deleteGatewayAdvertisedRouteTransportSettings, + settings.deleteGatewayAdvertisedRouteSettings(), + clientContext); + this.deleteGatewayAdvertisedRouteOperationCallable = + callableFactory.createOperationCallable( + deleteGatewayAdvertisedRouteTransportSettings, + settings.deleteGatewayAdvertisedRouteOperationSettings(), + clientContext, + operationsStub); this.listLocationsCallable = callableFactory.createUnaryCallable( listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); @@ -1204,6 +1409,62 @@ public UnaryCallable updateGroupCallable() { return updateGroupOperationCallable; } + @Override + public UnaryCallable + createGatewayAdvertisedRouteCallable() { + return createGatewayAdvertisedRouteCallable; + } + + @Override + public OperationCallable< + CreateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + createGatewayAdvertisedRouteOperationCallable() { + return createGatewayAdvertisedRouteOperationCallable; + } + + @Override + public UnaryCallable + getGatewayAdvertisedRouteCallable() { + return getGatewayAdvertisedRouteCallable; + } + + @Override + public UnaryCallable + listGatewayAdvertisedRoutesCallable() { + return listGatewayAdvertisedRoutesCallable; + } + + @Override + public UnaryCallable + listGatewayAdvertisedRoutesPagedCallable() { + return listGatewayAdvertisedRoutesPagedCallable; + } + + @Override + public UnaryCallable + updateGatewayAdvertisedRouteCallable() { + return updateGatewayAdvertisedRouteCallable; + } + + @Override + public OperationCallable< + UpdateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + updateGatewayAdvertisedRouteOperationCallable() { + return updateGatewayAdvertisedRouteOperationCallable; + } + + @Override + public UnaryCallable + deleteGatewayAdvertisedRouteCallable() { + return deleteGatewayAdvertisedRouteCallable; + } + + @Override + public OperationCallable + deleteGatewayAdvertisedRouteOperationCallable() { + return deleteGatewayAdvertisedRouteOperationCallable; + } + @Override public UnaryCallable listLocationsCallable() { return listLocationsCallable; diff --git a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStub.java b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStub.java index e4ea9a6cbd47..76bfdd6530b4 100644 --- a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStub.java +++ b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStub.java @@ -16,6 +16,7 @@ package com.google.cloud.networkconnectivity.v1.stub; +import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListGatewayAdvertisedRoutesPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListGroupsPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListHubSpokesPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListHubsPagedResponse; @@ -36,10 +37,14 @@ import com.google.cloud.networkconnectivity.v1.AcceptHubSpokeResponse; import com.google.cloud.networkconnectivity.v1.AcceptSpokeUpdateRequest; import com.google.cloud.networkconnectivity.v1.AcceptSpokeUpdateResponse; +import com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.CreateHubRequest; import com.google.cloud.networkconnectivity.v1.CreateSpokeRequest; +import com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.DeleteHubRequest; import com.google.cloud.networkconnectivity.v1.DeleteSpokeRequest; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.GetGroupRequest; import com.google.cloud.networkconnectivity.v1.GetHubRequest; import com.google.cloud.networkconnectivity.v1.GetRouteRequest; @@ -47,6 +52,8 @@ import com.google.cloud.networkconnectivity.v1.GetSpokeRequest; import com.google.cloud.networkconnectivity.v1.Group; import com.google.cloud.networkconnectivity.v1.Hub; +import com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest; +import com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse; import com.google.cloud.networkconnectivity.v1.ListGroupsRequest; import com.google.cloud.networkconnectivity.v1.ListGroupsResponse; import com.google.cloud.networkconnectivity.v1.ListHubSpokesRequest; @@ -69,6 +76,7 @@ import com.google.cloud.networkconnectivity.v1.Route; import com.google.cloud.networkconnectivity.v1.RouteTable; import com.google.cloud.networkconnectivity.v1.Spoke; +import com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.UpdateGroupRequest; import com.google.cloud.networkconnectivity.v1.UpdateHubRequest; import com.google.cloud.networkconnectivity.v1.UpdateSpokeRequest; @@ -276,6 +284,61 @@ public UnaryCallable updateGroupCallable() { throw new UnsupportedOperationException("Not implemented: updateGroupCallable()"); } + public OperationCallable< + CreateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + createGatewayAdvertisedRouteOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: createGatewayAdvertisedRouteOperationCallable()"); + } + + public UnaryCallable + createGatewayAdvertisedRouteCallable() { + throw new UnsupportedOperationException( + "Not implemented: createGatewayAdvertisedRouteCallable()"); + } + + public UnaryCallable + getGatewayAdvertisedRouteCallable() { + throw new UnsupportedOperationException("Not implemented: getGatewayAdvertisedRouteCallable()"); + } + + public UnaryCallable + listGatewayAdvertisedRoutesPagedCallable() { + throw new UnsupportedOperationException( + "Not implemented: listGatewayAdvertisedRoutesPagedCallable()"); + } + + public UnaryCallable + listGatewayAdvertisedRoutesCallable() { + throw new UnsupportedOperationException( + "Not implemented: listGatewayAdvertisedRoutesCallable()"); + } + + public OperationCallable< + UpdateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + updateGatewayAdvertisedRouteOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: updateGatewayAdvertisedRouteOperationCallable()"); + } + + public UnaryCallable + updateGatewayAdvertisedRouteCallable() { + throw new UnsupportedOperationException( + "Not implemented: updateGatewayAdvertisedRouteCallable()"); + } + + public OperationCallable + deleteGatewayAdvertisedRouteOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: deleteGatewayAdvertisedRouteOperationCallable()"); + } + + public UnaryCallable + deleteGatewayAdvertisedRouteCallable() { + throw new UnsupportedOperationException( + "Not implemented: deleteGatewayAdvertisedRouteCallable()"); + } + public UnaryCallable listLocationsPagedCallable() { throw new UnsupportedOperationException("Not implemented: listLocationsPagedCallable()"); diff --git a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStubSettings.java b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStubSettings.java index feca7e612575..c0247128d42e 100644 --- a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStubSettings.java +++ b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/java/com/google/cloud/networkconnectivity/v1/stub/HubServiceStubSettings.java @@ -16,6 +16,7 @@ package com.google.cloud.networkconnectivity.v1.stub; +import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListGatewayAdvertisedRoutesPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListGroupsPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListHubSpokesPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListHubsPagedResponse; @@ -60,10 +61,14 @@ import com.google.cloud.networkconnectivity.v1.AcceptHubSpokeResponse; import com.google.cloud.networkconnectivity.v1.AcceptSpokeUpdateRequest; import com.google.cloud.networkconnectivity.v1.AcceptSpokeUpdateResponse; +import com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.CreateHubRequest; import com.google.cloud.networkconnectivity.v1.CreateSpokeRequest; +import com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.DeleteHubRequest; import com.google.cloud.networkconnectivity.v1.DeleteSpokeRequest; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.GetGroupRequest; import com.google.cloud.networkconnectivity.v1.GetHubRequest; import com.google.cloud.networkconnectivity.v1.GetRouteRequest; @@ -72,6 +77,8 @@ import com.google.cloud.networkconnectivity.v1.Group; import com.google.cloud.networkconnectivity.v1.Hub; import com.google.cloud.networkconnectivity.v1.HubStatusEntry; +import com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest; +import com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse; import com.google.cloud.networkconnectivity.v1.ListGroupsRequest; import com.google.cloud.networkconnectivity.v1.ListGroupsResponse; import com.google.cloud.networkconnectivity.v1.ListHubSpokesRequest; @@ -94,6 +101,7 @@ import com.google.cloud.networkconnectivity.v1.Route; import com.google.cloud.networkconnectivity.v1.RouteTable; import com.google.cloud.networkconnectivity.v1.Spoke; +import com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest; import com.google.cloud.networkconnectivity.v1.UpdateGroupRequest; import com.google.cloud.networkconnectivity.v1.UpdateHubRequest; import com.google.cloud.networkconnectivity.v1.UpdateSpokeRequest; @@ -257,6 +265,27 @@ public class HubServiceStubSettings extends StubSettings private final UnaryCallSettings updateGroupSettings; private final OperationCallSettings updateGroupOperationSettings; + private final UnaryCallSettings + createGatewayAdvertisedRouteSettings; + private final OperationCallSettings< + CreateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + createGatewayAdvertisedRouteOperationSettings; + private final UnaryCallSettings + getGatewayAdvertisedRouteSettings; + private final PagedCallSettings< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + ListGatewayAdvertisedRoutesPagedResponse> + listGatewayAdvertisedRoutesSettings; + private final UnaryCallSettings + updateGatewayAdvertisedRouteSettings; + private final OperationCallSettings< + UpdateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + updateGatewayAdvertisedRouteOperationSettings; + private final UnaryCallSettings + deleteGatewayAdvertisedRouteSettings; + private final OperationCallSettings + deleteGatewayAdvertisedRouteOperationSettings; private final PagedCallSettings< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> listLocationsSettings; @@ -509,6 +538,53 @@ public Iterable extractResources(ListGroupsResponse payload) { } }; + private static final PagedListDescriptor< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + GatewayAdvertisedRoute> + LIST_GATEWAY_ADVERTISED_ROUTES_PAGE_STR_DESC = + new PagedListDescriptor< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + GatewayAdvertisedRoute>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListGatewayAdvertisedRoutesRequest injectToken( + ListGatewayAdvertisedRoutesRequest payload, String token) { + return ListGatewayAdvertisedRoutesRequest.newBuilder(payload) + .setPageToken(token) + .build(); + } + + @Override + public ListGatewayAdvertisedRoutesRequest injectPageSize( + ListGatewayAdvertisedRoutesRequest payload, int pageSize) { + return ListGatewayAdvertisedRoutesRequest.newBuilder(payload) + .setPageSize(pageSize) + .build(); + } + + @Override + public Integer extractPageSize(ListGatewayAdvertisedRoutesRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListGatewayAdvertisedRoutesResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources( + ListGatewayAdvertisedRoutesResponse payload) { + return payload.getGatewayAdvertisedRoutesList(); + } + }; + private static final PagedListDescriptor LIST_LOCATIONS_PAGE_STR_DESC = new PagedListDescriptor() { @@ -663,6 +739,35 @@ public ApiFuture getFuturePagedResponse( } }; + private static final PagedListResponseFactory< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + ListGatewayAdvertisedRoutesPagedResponse> + LIST_GATEWAY_ADVERTISED_ROUTES_PAGE_STR_FACT = + new PagedListResponseFactory< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + ListGatewayAdvertisedRoutesPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable< + ListGatewayAdvertisedRoutesRequest, ListGatewayAdvertisedRoutesResponse> + callable, + ListGatewayAdvertisedRoutesRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + GatewayAdvertisedRoute> + pageContext = + PageContext.create( + callable, LIST_GATEWAY_ADVERTISED_ROUTES_PAGE_STR_DESC, request, context); + return ListGatewayAdvertisedRoutesPagedResponse.createAsync( + pageContext, futureResponse); + } + }; + private static final PagedListResponseFactory< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> LIST_LOCATIONS_PAGE_STR_FACT = @@ -872,6 +977,59 @@ public UnaryCallSettings updateGroupSettings() { return updateGroupOperationSettings; } + /** Returns the object with the settings used for calls to createGatewayAdvertisedRoute. */ + public UnaryCallSettings + createGatewayAdvertisedRouteSettings() { + return createGatewayAdvertisedRouteSettings; + } + + /** Returns the object with the settings used for calls to createGatewayAdvertisedRoute. */ + public OperationCallSettings< + CreateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + createGatewayAdvertisedRouteOperationSettings() { + return createGatewayAdvertisedRouteOperationSettings; + } + + /** Returns the object with the settings used for calls to getGatewayAdvertisedRoute. */ + public UnaryCallSettings + getGatewayAdvertisedRouteSettings() { + return getGatewayAdvertisedRouteSettings; + } + + /** Returns the object with the settings used for calls to listGatewayAdvertisedRoutes. */ + public PagedCallSettings< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + ListGatewayAdvertisedRoutesPagedResponse> + listGatewayAdvertisedRoutesSettings() { + return listGatewayAdvertisedRoutesSettings; + } + + /** Returns the object with the settings used for calls to updateGatewayAdvertisedRoute. */ + public UnaryCallSettings + updateGatewayAdvertisedRouteSettings() { + return updateGatewayAdvertisedRouteSettings; + } + + /** Returns the object with the settings used for calls to updateGatewayAdvertisedRoute. */ + public OperationCallSettings< + UpdateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + updateGatewayAdvertisedRouteOperationSettings() { + return updateGatewayAdvertisedRouteOperationSettings; + } + + /** Returns the object with the settings used for calls to deleteGatewayAdvertisedRoute. */ + public UnaryCallSettings + deleteGatewayAdvertisedRouteSettings() { + return deleteGatewayAdvertisedRouteSettings; + } + + /** Returns the object with the settings used for calls to deleteGatewayAdvertisedRoute. */ + public OperationCallSettings + deleteGatewayAdvertisedRouteOperationSettings() { + return deleteGatewayAdvertisedRouteOperationSettings; + } + /** Returns the object with the settings used for calls to listLocations. */ public PagedCallSettings listLocationsSettings() { @@ -1016,6 +1174,21 @@ protected HubServiceStubSettings(Builder settingsBuilder) throws IOException { listGroupsSettings = settingsBuilder.listGroupsSettings().build(); updateGroupSettings = settingsBuilder.updateGroupSettings().build(); updateGroupOperationSettings = settingsBuilder.updateGroupOperationSettings().build(); + createGatewayAdvertisedRouteSettings = + settingsBuilder.createGatewayAdvertisedRouteSettings().build(); + createGatewayAdvertisedRouteOperationSettings = + settingsBuilder.createGatewayAdvertisedRouteOperationSettings().build(); + getGatewayAdvertisedRouteSettings = settingsBuilder.getGatewayAdvertisedRouteSettings().build(); + listGatewayAdvertisedRoutesSettings = + settingsBuilder.listGatewayAdvertisedRoutesSettings().build(); + updateGatewayAdvertisedRouteSettings = + settingsBuilder.updateGatewayAdvertisedRouteSettings().build(); + updateGatewayAdvertisedRouteOperationSettings = + settingsBuilder.updateGatewayAdvertisedRouteOperationSettings().build(); + deleteGatewayAdvertisedRouteSettings = + settingsBuilder.deleteGatewayAdvertisedRouteSettings().build(); + deleteGatewayAdvertisedRouteOperationSettings = + settingsBuilder.deleteGatewayAdvertisedRouteOperationSettings().build(); listLocationsSettings = settingsBuilder.listLocationsSettings().build(); getLocationSettings = settingsBuilder.getLocationSettings().build(); setIamPolicySettings = settingsBuilder.setIamPolicySettings().build(); @@ -1102,6 +1275,29 @@ public static class Builder extends StubSettings.Builder updateGroupSettings; private final OperationCallSettings.Builder updateGroupOperationSettings; + private final UnaryCallSettings.Builder + createGatewayAdvertisedRouteSettings; + private final OperationCallSettings.Builder< + CreateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + createGatewayAdvertisedRouteOperationSettings; + private final UnaryCallSettings.Builder< + GetGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute> + getGatewayAdvertisedRouteSettings; + private final PagedCallSettings.Builder< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + ListGatewayAdvertisedRoutesPagedResponse> + listGatewayAdvertisedRoutesSettings; + private final UnaryCallSettings.Builder + updateGatewayAdvertisedRouteSettings; + private final OperationCallSettings.Builder< + UpdateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + updateGatewayAdvertisedRouteOperationSettings; + private final UnaryCallSettings.Builder + deleteGatewayAdvertisedRouteSettings; + private final OperationCallSettings.Builder< + DeleteGatewayAdvertisedRouteRequest, Empty, OperationMetadata> + deleteGatewayAdvertisedRouteOperationSettings; private final PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> listLocationsSettings; @@ -1192,6 +1388,15 @@ protected Builder(@Nullable ClientContext clientContext) { listGroupsSettings = PagedCallSettings.newBuilder(LIST_GROUPS_PAGE_STR_FACT); updateGroupSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); updateGroupOperationSettings = OperationCallSettings.newBuilder(); + createGatewayAdvertisedRouteSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createGatewayAdvertisedRouteOperationSettings = OperationCallSettings.newBuilder(); + getGatewayAdvertisedRouteSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listGatewayAdvertisedRoutesSettings = + PagedCallSettings.newBuilder(LIST_GATEWAY_ADVERTISED_ROUTES_PAGE_STR_FACT); + updateGatewayAdvertisedRouteSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateGatewayAdvertisedRouteOperationSettings = OperationCallSettings.newBuilder(); + deleteGatewayAdvertisedRouteSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteGatewayAdvertisedRouteOperationSettings = OperationCallSettings.newBuilder(); listLocationsSettings = PagedCallSettings.newBuilder(LIST_LOCATIONS_PAGE_STR_FACT); getLocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); setIamPolicySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -1223,6 +1428,11 @@ protected Builder(@Nullable ClientContext clientContext) { getGroupSettings, listGroupsSettings, updateGroupSettings, + createGatewayAdvertisedRouteSettings, + getGatewayAdvertisedRouteSettings, + listGatewayAdvertisedRoutesSettings, + updateGatewayAdvertisedRouteSettings, + deleteGatewayAdvertisedRouteSettings, listLocationsSettings, getLocationSettings, setIamPolicySettings, @@ -1268,6 +1478,21 @@ protected Builder(HubServiceStubSettings settings) { listGroupsSettings = settings.listGroupsSettings.toBuilder(); updateGroupSettings = settings.updateGroupSettings.toBuilder(); updateGroupOperationSettings = settings.updateGroupOperationSettings.toBuilder(); + createGatewayAdvertisedRouteSettings = + settings.createGatewayAdvertisedRouteSettings.toBuilder(); + createGatewayAdvertisedRouteOperationSettings = + settings.createGatewayAdvertisedRouteOperationSettings.toBuilder(); + getGatewayAdvertisedRouteSettings = settings.getGatewayAdvertisedRouteSettings.toBuilder(); + listGatewayAdvertisedRoutesSettings = + settings.listGatewayAdvertisedRoutesSettings.toBuilder(); + updateGatewayAdvertisedRouteSettings = + settings.updateGatewayAdvertisedRouteSettings.toBuilder(); + updateGatewayAdvertisedRouteOperationSettings = + settings.updateGatewayAdvertisedRouteOperationSettings.toBuilder(); + deleteGatewayAdvertisedRouteSettings = + settings.deleteGatewayAdvertisedRouteSettings.toBuilder(); + deleteGatewayAdvertisedRouteOperationSettings = + settings.deleteGatewayAdvertisedRouteOperationSettings.toBuilder(); listLocationsSettings = settings.listLocationsSettings.toBuilder(); getLocationSettings = settings.getLocationSettings.toBuilder(); setIamPolicySettings = settings.setIamPolicySettings.toBuilder(); @@ -1299,6 +1524,11 @@ protected Builder(HubServiceStubSettings settings) { getGroupSettings, listGroupsSettings, updateGroupSettings, + createGatewayAdvertisedRouteSettings, + getGatewayAdvertisedRouteSettings, + listGatewayAdvertisedRoutesSettings, + updateGatewayAdvertisedRouteSettings, + deleteGatewayAdvertisedRouteSettings, listLocationsSettings, getLocationSettings, setIamPolicySettings, @@ -1434,6 +1664,31 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + builder + .createGatewayAdvertisedRouteSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .getGatewayAdvertisedRouteSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .listGatewayAdvertisedRoutesSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .updateGatewayAdvertisedRouteSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .deleteGatewayAdvertisedRouteSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + builder .listLocationsSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) @@ -1716,6 +1971,81 @@ private static Builder initDefaults(Builder builder) { .setTotalTimeoutDuration(Duration.ofMillis(300000L)) .build())); + builder + .createGatewayAdvertisedRouteOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + . + newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(GatewayAdvertisedRoute.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .updateGatewayAdvertisedRouteOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + . + newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(GatewayAdvertisedRoute.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .deleteGatewayAdvertisedRouteOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + . + newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Empty.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + return builder; } @@ -1931,6 +2261,60 @@ public UnaryCallSettings.Builder updateGroupSetti return updateGroupOperationSettings; } + /** Returns the builder for the settings used for calls to createGatewayAdvertisedRoute. */ + public UnaryCallSettings.Builder + createGatewayAdvertisedRouteSettings() { + return createGatewayAdvertisedRouteSettings; + } + + /** Returns the builder for the settings used for calls to createGatewayAdvertisedRoute. */ + public OperationCallSettings.Builder< + CreateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + createGatewayAdvertisedRouteOperationSettings() { + return createGatewayAdvertisedRouteOperationSettings; + } + + /** Returns the builder for the settings used for calls to getGatewayAdvertisedRoute. */ + public UnaryCallSettings.Builder + getGatewayAdvertisedRouteSettings() { + return getGatewayAdvertisedRouteSettings; + } + + /** Returns the builder for the settings used for calls to listGatewayAdvertisedRoutes. */ + public PagedCallSettings.Builder< + ListGatewayAdvertisedRoutesRequest, + ListGatewayAdvertisedRoutesResponse, + ListGatewayAdvertisedRoutesPagedResponse> + listGatewayAdvertisedRoutesSettings() { + return listGatewayAdvertisedRoutesSettings; + } + + /** Returns the builder for the settings used for calls to updateGatewayAdvertisedRoute. */ + public UnaryCallSettings.Builder + updateGatewayAdvertisedRouteSettings() { + return updateGatewayAdvertisedRouteSettings; + } + + /** Returns the builder for the settings used for calls to updateGatewayAdvertisedRoute. */ + public OperationCallSettings.Builder< + UpdateGatewayAdvertisedRouteRequest, GatewayAdvertisedRoute, OperationMetadata> + updateGatewayAdvertisedRouteOperationSettings() { + return updateGatewayAdvertisedRouteOperationSettings; + } + + /** Returns the builder for the settings used for calls to deleteGatewayAdvertisedRoute. */ + public UnaryCallSettings.Builder + deleteGatewayAdvertisedRouteSettings() { + return deleteGatewayAdvertisedRouteSettings; + } + + /** Returns the builder for the settings used for calls to deleteGatewayAdvertisedRoute. */ + public OperationCallSettings.Builder< + DeleteGatewayAdvertisedRouteRequest, Empty, OperationMetadata> + deleteGatewayAdvertisedRouteOperationSettings() { + return deleteGatewayAdvertisedRouteOperationSettings; + } + /** Returns the builder for the settings used for calls to listLocations. */ public PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> diff --git a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/resources/META-INF/native-image/com.google.cloud.networkconnectivity.v1/reflect-config.json b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/resources/META-INF/native-image/com.google.cloud.networkconnectivity.v1/reflect-config.json index a064a7d06df0..038cc3cf8335 100644 --- a/java-networkconnectivity/google-cloud-networkconnectivity/src/main/resources/META-INF/native-image/com.google.cloud.networkconnectivity.v1/reflect-config.json +++ b/java-networkconnectivity/google-cloud-networkconnectivity/src/main/resources/META-INF/native-image/com.google.cloud.networkconnectivity.v1/reflect-config.json @@ -710,6 +710,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.networkconnectivity.v1.CreateHubRequest", "queryAllDeclaredConstructors": true, @@ -872,6 +890,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.networkconnectivity.v1.DeleteHubRequest", "queryAllDeclaredConstructors": true, @@ -1079,6 +1115,78 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.networkconnectivity.v1.Gateway", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.Gateway$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.Gateway$GatewayCapacity", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.Gateway$IpRangeReservation", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.Gateway$IpRangeReservation$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute$Recipient", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.networkconnectivity.v1.GetDestinationRequest", "queryAllDeclaredConstructors": true, @@ -1097,6 +1205,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.networkconnectivity.v1.GetGroupRequest", "queryAllDeclaredConstructors": true, @@ -1367,6 +1493,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.networkconnectivity.v1.Hub$ExportPscConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.Hub$ExportPscConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.networkconnectivity.v1.HubStatusEntry", "queryAllDeclaredConstructors": true, @@ -1619,6 +1763,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.networkconnectivity.v1.ListGroupsRequest", "queryAllDeclaredConstructors": true, @@ -2231,6 +2411,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.networkconnectivity.v1.NextHopSpoke", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.NextHopSpoke$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.networkconnectivity.v1.NextHopVPNTunnel", "queryAllDeclaredConstructors": true, @@ -3059,6 +3257,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.networkconnectivity.v1.UpdateGroupRequest", "queryAllDeclaredConstructors": true, diff --git a/java-networkconnectivity/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/HubServiceClientTest.java b/java-networkconnectivity/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/HubServiceClientTest.java index 449fbb7349e2..6641fea360ad 100644 --- a/java-networkconnectivity/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/HubServiceClientTest.java +++ b/java-networkconnectivity/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/HubServiceClientTest.java @@ -16,6 +16,7 @@ package com.google.cloud.networkconnectivity.v1; +import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListGatewayAdvertisedRoutesPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListGroupsPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListHubSpokesPagedResponse; import static com.google.cloud.networkconnectivity.v1.HubServiceClient.ListHubsPagedResponse; @@ -217,6 +218,7 @@ public void getHubTest() throws Exception { .setPolicyMode(PolicyMode.forNumber(0)) .setPresetTopology(PresetTopology.forNumber(0)) .setExportPsc(true) + .setExportPscConfig(Hub.ExportPscConfig.newBuilder().build()) .build(); mockHubService.addResponse(expectedResponse); @@ -267,6 +269,7 @@ public void getHubTest2() throws Exception { .setPolicyMode(PolicyMode.forNumber(0)) .setPresetTopology(PresetTopology.forNumber(0)) .setExportPsc(true) + .setExportPscConfig(Hub.ExportPscConfig.newBuilder().build()) .build(); mockHubService.addResponse(expectedResponse); @@ -317,6 +320,7 @@ public void createHubTest() throws Exception { .setPolicyMode(PolicyMode.forNumber(0)) .setPresetTopology(PresetTopology.forNumber(0)) .setExportPsc(true) + .setExportPscConfig(Hub.ExportPscConfig.newBuilder().build()) .build(); Operation resultOperation = Operation.newBuilder() @@ -381,6 +385,7 @@ public void createHubTest2() throws Exception { .setPolicyMode(PolicyMode.forNumber(0)) .setPresetTopology(PresetTopology.forNumber(0)) .setExportPsc(true) + .setExportPscConfig(Hub.ExportPscConfig.newBuilder().build()) .build(); Operation resultOperation = Operation.newBuilder() @@ -445,6 +450,7 @@ public void updateHubTest() throws Exception { .setPolicyMode(PolicyMode.forNumber(0)) .setPresetTopology(PresetTopology.forNumber(0)) .setExportPsc(true) + .setExportPscConfig(Hub.ExportPscConfig.newBuilder().build()) .build(); Operation resultOperation = Operation.newBuilder() @@ -852,6 +858,7 @@ public void getSpokeTest() throws Exception { .setLinkedInterconnectAttachments(LinkedInterconnectAttachments.newBuilder().build()) .setLinkedRouterApplianceInstances(LinkedRouterApplianceInstances.newBuilder().build()) .setLinkedVpcNetwork(LinkedVpcNetwork.newBuilder().build()) + .setGateway(Gateway.newBuilder().build()) .setLinkedProducerVpcNetwork(LinkedProducerVpcNetwork.newBuilder().build()) .setUniqueId("uniqueId-294460212") .setState(State.forNumber(0)) @@ -907,6 +914,7 @@ public void getSpokeTest2() throws Exception { .setLinkedInterconnectAttachments(LinkedInterconnectAttachments.newBuilder().build()) .setLinkedRouterApplianceInstances(LinkedRouterApplianceInstances.newBuilder().build()) .setLinkedVpcNetwork(LinkedVpcNetwork.newBuilder().build()) + .setGateway(Gateway.newBuilder().build()) .setLinkedProducerVpcNetwork(LinkedProducerVpcNetwork.newBuilder().build()) .setUniqueId("uniqueId-294460212") .setState(State.forNumber(0)) @@ -962,6 +970,7 @@ public void createSpokeTest() throws Exception { .setLinkedInterconnectAttachments(LinkedInterconnectAttachments.newBuilder().build()) .setLinkedRouterApplianceInstances(LinkedRouterApplianceInstances.newBuilder().build()) .setLinkedVpcNetwork(LinkedVpcNetwork.newBuilder().build()) + .setGateway(Gateway.newBuilder().build()) .setLinkedProducerVpcNetwork(LinkedProducerVpcNetwork.newBuilder().build()) .setUniqueId("uniqueId-294460212") .setState(State.forNumber(0)) @@ -1031,6 +1040,7 @@ public void createSpokeTest2() throws Exception { .setLinkedInterconnectAttachments(LinkedInterconnectAttachments.newBuilder().build()) .setLinkedRouterApplianceInstances(LinkedRouterApplianceInstances.newBuilder().build()) .setLinkedVpcNetwork(LinkedVpcNetwork.newBuilder().build()) + .setGateway(Gateway.newBuilder().build()) .setLinkedProducerVpcNetwork(LinkedProducerVpcNetwork.newBuilder().build()) .setUniqueId("uniqueId-294460212") .setState(State.forNumber(0)) @@ -1100,6 +1110,7 @@ public void updateSpokeTest() throws Exception { .setLinkedInterconnectAttachments(LinkedInterconnectAttachments.newBuilder().build()) .setLinkedRouterApplianceInstances(LinkedRouterApplianceInstances.newBuilder().build()) .setLinkedVpcNetwork(LinkedVpcNetwork.newBuilder().build()) + .setGateway(Gateway.newBuilder().build()) .setLinkedProducerVpcNetwork(LinkedProducerVpcNetwork.newBuilder().build()) .setUniqueId("uniqueId-294460212") .setState(State.forNumber(0)) @@ -2127,6 +2138,7 @@ public void getRouteTest() throws Exception { .setNextHopVpnTunnel(NextHopVPNTunnel.newBuilder().build()) .setNextHopRouterApplianceInstance(NextHopRouterApplianceInstance.newBuilder().build()) .setNextHopInterconnectAttachment(NextHopInterconnectAttachment.newBuilder().build()) + .setNextHopSpoke(NextHopSpoke.newBuilder().build()) .build(); mockHubService.addResponse(expectedResponse); @@ -2180,6 +2192,7 @@ public void getRouteTest2() throws Exception { .setNextHopVpnTunnel(NextHopVPNTunnel.newBuilder().build()) .setNextHopRouterApplianceInstance(NextHopRouterApplianceInstance.newBuilder().build()) .setNextHopInterconnectAttachment(NextHopInterconnectAttachment.newBuilder().build()) + .setNextHopSpoke(NextHopSpoke.newBuilder().build()) .build(); mockHubService.addResponse(expectedResponse); @@ -2401,7 +2414,7 @@ public void getGroupTest() throws Exception { .setUid("uid115792") .setState(State.forNumber(0)) .setAutoAccept(AutoAccept.newBuilder().build()) - .setRouteTable("routeTable902012677") + .setRouteTable(RouteTableName.of("[PROJECT]", "[HUB]", "[ROUTE_TABLE]").toString()) .build(); mockHubService.addResponse(expectedResponse); @@ -2447,7 +2460,7 @@ public void getGroupTest2() throws Exception { .setUid("uid115792") .setState(State.forNumber(0)) .setAutoAccept(AutoAccept.newBuilder().build()) - .setRouteTable("routeTable902012677") + .setRouteTable(RouteTableName.of("[PROJECT]", "[HUB]", "[ROUTE_TABLE]").toString()) .build(); mockHubService.addResponse(expectedResponse); @@ -2581,7 +2594,7 @@ public void updateGroupTest() throws Exception { .setUid("uid115792") .setState(State.forNumber(0)) .setAutoAccept(AutoAccept.newBuilder().build()) - .setRouteTable("routeTable902012677") + .setRouteTable(RouteTableName.of("[PROJECT]", "[HUB]", "[ROUTE_TABLE]").toString()) .build(); Operation resultOperation = Operation.newBuilder() @@ -2626,6 +2639,496 @@ public void updateGroupExceptionTest() throws Exception { } } + @Test + public void createGatewayAdvertisedRouteTest() throws Exception { + GatewayAdvertisedRoute expectedResponse = + GatewayAdvertisedRoute.newBuilder() + .setName( + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setDescription("description-1724546052") + .setUniqueId("uniqueId-294460212") + .setState(State.forNumber(0)) + .setIpRange("ipRange1983798358") + .setPriority(-1165461084) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createGatewayAdvertisedRouteTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockHubService.addResponse(resultOperation); + + SpokeName parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); + GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build(); + String gatewayAdvertisedRouteId = "gatewayAdvertisedRouteId1531070339"; + + GatewayAdvertisedRoute actualResponse = + client + .createGatewayAdvertisedRouteAsync( + parent, gatewayAdvertisedRoute, gatewayAdvertisedRouteId) + .get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockHubService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateGatewayAdvertisedRouteRequest actualRequest = + ((CreateGatewayAdvertisedRouteRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(gatewayAdvertisedRoute, actualRequest.getGatewayAdvertisedRoute()); + Assert.assertEquals(gatewayAdvertisedRouteId, actualRequest.getGatewayAdvertisedRouteId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createGatewayAdvertisedRouteExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockHubService.addException(exception); + + try { + SpokeName parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); + GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build(); + String gatewayAdvertisedRouteId = "gatewayAdvertisedRouteId1531070339"; + client + .createGatewayAdvertisedRouteAsync( + parent, gatewayAdvertisedRoute, gatewayAdvertisedRouteId) + .get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void createGatewayAdvertisedRouteTest2() throws Exception { + GatewayAdvertisedRoute expectedResponse = + GatewayAdvertisedRoute.newBuilder() + .setName( + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setDescription("description-1724546052") + .setUniqueId("uniqueId-294460212") + .setState(State.forNumber(0)) + .setIpRange("ipRange1983798358") + .setPriority(-1165461084) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createGatewayAdvertisedRouteTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockHubService.addResponse(resultOperation); + + String parent = "parent-995424086"; + GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build(); + String gatewayAdvertisedRouteId = "gatewayAdvertisedRouteId1531070339"; + + GatewayAdvertisedRoute actualResponse = + client + .createGatewayAdvertisedRouteAsync( + parent, gatewayAdvertisedRoute, gatewayAdvertisedRouteId) + .get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockHubService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateGatewayAdvertisedRouteRequest actualRequest = + ((CreateGatewayAdvertisedRouteRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(gatewayAdvertisedRoute, actualRequest.getGatewayAdvertisedRoute()); + Assert.assertEquals(gatewayAdvertisedRouteId, actualRequest.getGatewayAdvertisedRouteId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createGatewayAdvertisedRouteExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockHubService.addException(exception); + + try { + String parent = "parent-995424086"; + GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build(); + String gatewayAdvertisedRouteId = "gatewayAdvertisedRouteId1531070339"; + client + .createGatewayAdvertisedRouteAsync( + parent, gatewayAdvertisedRoute, gatewayAdvertisedRouteId) + .get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void getGatewayAdvertisedRouteTest() throws Exception { + GatewayAdvertisedRoute expectedResponse = + GatewayAdvertisedRoute.newBuilder() + .setName( + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setDescription("description-1724546052") + .setUniqueId("uniqueId-294460212") + .setState(State.forNumber(0)) + .setIpRange("ipRange1983798358") + .setPriority(-1165461084) + .build(); + mockHubService.addResponse(expectedResponse); + + GatewayAdvertisedRouteName name = + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]"); + + GatewayAdvertisedRoute actualResponse = client.getGatewayAdvertisedRoute(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockHubService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetGatewayAdvertisedRouteRequest actualRequest = + ((GetGatewayAdvertisedRouteRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getGatewayAdvertisedRouteExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockHubService.addException(exception); + + try { + GatewayAdvertisedRouteName name = + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]"); + client.getGatewayAdvertisedRoute(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGatewayAdvertisedRouteTest2() throws Exception { + GatewayAdvertisedRoute expectedResponse = + GatewayAdvertisedRoute.newBuilder() + .setName( + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setDescription("description-1724546052") + .setUniqueId("uniqueId-294460212") + .setState(State.forNumber(0)) + .setIpRange("ipRange1983798358") + .setPriority(-1165461084) + .build(); + mockHubService.addResponse(expectedResponse); + + String name = "name3373707"; + + GatewayAdvertisedRoute actualResponse = client.getGatewayAdvertisedRoute(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockHubService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetGatewayAdvertisedRouteRequest actualRequest = + ((GetGatewayAdvertisedRouteRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getGatewayAdvertisedRouteExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockHubService.addException(exception); + + try { + String name = "name3373707"; + client.getGatewayAdvertisedRoute(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGatewayAdvertisedRoutesTest() throws Exception { + GatewayAdvertisedRoute responsesElement = GatewayAdvertisedRoute.newBuilder().build(); + ListGatewayAdvertisedRoutesResponse expectedResponse = + ListGatewayAdvertisedRoutesResponse.newBuilder() + .setNextPageToken("") + .addAllGatewayAdvertisedRoutes(Arrays.asList(responsesElement)) + .build(); + mockHubService.addResponse(expectedResponse); + + SpokeName parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); + + ListGatewayAdvertisedRoutesPagedResponse pagedListResponse = + client.listGatewayAdvertisedRoutes(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getGatewayAdvertisedRoutesList().get(0), resources.get(0)); + + List actualRequests = mockHubService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListGatewayAdvertisedRoutesRequest actualRequest = + ((ListGatewayAdvertisedRoutesRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listGatewayAdvertisedRoutesExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockHubService.addException(exception); + + try { + SpokeName parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); + client.listGatewayAdvertisedRoutes(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGatewayAdvertisedRoutesTest2() throws Exception { + GatewayAdvertisedRoute responsesElement = GatewayAdvertisedRoute.newBuilder().build(); + ListGatewayAdvertisedRoutesResponse expectedResponse = + ListGatewayAdvertisedRoutesResponse.newBuilder() + .setNextPageToken("") + .addAllGatewayAdvertisedRoutes(Arrays.asList(responsesElement)) + .build(); + mockHubService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListGatewayAdvertisedRoutesPagedResponse pagedListResponse = + client.listGatewayAdvertisedRoutes(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getGatewayAdvertisedRoutesList().get(0), resources.get(0)); + + List actualRequests = mockHubService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListGatewayAdvertisedRoutesRequest actualRequest = + ((ListGatewayAdvertisedRoutesRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listGatewayAdvertisedRoutesExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockHubService.addException(exception); + + try { + String parent = "parent-995424086"; + client.listGatewayAdvertisedRoutes(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateGatewayAdvertisedRouteTest() throws Exception { + GatewayAdvertisedRoute expectedResponse = + GatewayAdvertisedRoute.newBuilder() + .setName( + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setDescription("description-1724546052") + .setUniqueId("uniqueId-294460212") + .setState(State.forNumber(0)) + .setIpRange("ipRange1983798358") + .setPriority(-1165461084) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateGatewayAdvertisedRouteTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockHubService.addResponse(resultOperation); + + GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + GatewayAdvertisedRoute actualResponse = + client.updateGatewayAdvertisedRouteAsync(gatewayAdvertisedRoute, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockHubService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateGatewayAdvertisedRouteRequest actualRequest = + ((UpdateGatewayAdvertisedRouteRequest) actualRequests.get(0)); + + Assert.assertEquals(gatewayAdvertisedRoute, actualRequest.getGatewayAdvertisedRoute()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateGatewayAdvertisedRouteExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockHubService.addException(exception); + + try { + GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateGatewayAdvertisedRouteAsync(gatewayAdvertisedRoute, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteGatewayAdvertisedRouteTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteGatewayAdvertisedRouteTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockHubService.addResponse(resultOperation); + + GatewayAdvertisedRouteName name = + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]"); + + client.deleteGatewayAdvertisedRouteAsync(name).get(); + + List actualRequests = mockHubService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteGatewayAdvertisedRouteRequest actualRequest = + ((DeleteGatewayAdvertisedRouteRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteGatewayAdvertisedRouteExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockHubService.addException(exception); + + try { + GatewayAdvertisedRouteName name = + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]"); + client.deleteGatewayAdvertisedRouteAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteGatewayAdvertisedRouteTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteGatewayAdvertisedRouteTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockHubService.addResponse(resultOperation); + + String name = "name3373707"; + + client.deleteGatewayAdvertisedRouteAsync(name).get(); + + List actualRequests = mockHubService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteGatewayAdvertisedRouteRequest actualRequest = + ((DeleteGatewayAdvertisedRouteRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteGatewayAdvertisedRouteExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockHubService.addException(exception); + + try { + String name = "name3373707"; + client.deleteGatewayAdvertisedRouteAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + @Test public void listLocationsTest() throws Exception { Location responsesElement = Location.newBuilder().build(); diff --git a/java-networkconnectivity/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/MockHubServiceImpl.java b/java-networkconnectivity/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/MockHubServiceImpl.java index 7e4c730cdd9e..40128b06f9c8 100644 --- a/java-networkconnectivity/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/MockHubServiceImpl.java +++ b/java-networkconnectivity/google-cloud-networkconnectivity/src/test/java/com/google/cloud/networkconnectivity/v1/MockHubServiceImpl.java @@ -529,4 +529,116 @@ public void updateGroup(UpdateGroupRequest request, StreamObserver re Exception.class.getName()))); } } + + @Override + public void createGatewayAdvertisedRoute( + CreateGatewayAdvertisedRouteRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method CreateGatewayAdvertisedRoute, expected" + + " %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getGatewayAdvertisedRoute( + GetGatewayAdvertisedRouteRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof GatewayAdvertisedRoute) { + requests.add(request); + responseObserver.onNext(((GatewayAdvertisedRoute) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetGatewayAdvertisedRoute, expected %s" + + " or %s", + response == null ? "null" : response.getClass().getName(), + GatewayAdvertisedRoute.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listGatewayAdvertisedRoutes( + ListGatewayAdvertisedRoutesRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListGatewayAdvertisedRoutesResponse) { + requests.add(request); + responseObserver.onNext(((ListGatewayAdvertisedRoutesResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListGatewayAdvertisedRoutes, expected" + + " %s or %s", + response == null ? "null" : response.getClass().getName(), + ListGatewayAdvertisedRoutesResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void updateGatewayAdvertisedRoute( + UpdateGatewayAdvertisedRouteRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method UpdateGatewayAdvertisedRoute, expected" + + " %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteGatewayAdvertisedRoute( + DeleteGatewayAdvertisedRouteRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method DeleteGatewayAdvertisedRoute, expected" + + " %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } } diff --git a/java-networkconnectivity/grpc-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceGrpc.java b/java-networkconnectivity/grpc-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceGrpc.java index 12be90ef71e8..132080224923 100644 --- a/java-networkconnectivity/grpc-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceGrpc.java +++ b/java-networkconnectivity/grpc-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubServiceGrpc.java @@ -1081,6 +1081,266 @@ private HubServiceGrpc() {} return getUpdateGroupMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation> + getCreateGatewayAdvertisedRouteMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateGatewayAdvertisedRoute", + requestType = + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation> + getCreateGatewayAdvertisedRouteMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation> + getCreateGatewayAdvertisedRouteMethod; + if ((getCreateGatewayAdvertisedRouteMethod = + HubServiceGrpc.getCreateGatewayAdvertisedRouteMethod) + == null) { + synchronized (HubServiceGrpc.class) { + if ((getCreateGatewayAdvertisedRouteMethod = + HubServiceGrpc.getCreateGatewayAdvertisedRouteMethod) + == null) { + HubServiceGrpc.getCreateGatewayAdvertisedRouteMethod = + getCreateGatewayAdvertisedRouteMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "CreateGatewayAdvertisedRoute")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.networkconnectivity.v1 + .CreateGatewayAdvertisedRouteRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new HubServiceMethodDescriptorSupplier("CreateGatewayAdvertisedRoute")) + .build(); + } + } + } + return getCreateGatewayAdvertisedRouteMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute> + getGetGatewayAdvertisedRouteMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetGatewayAdvertisedRoute", + requestType = com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest.class, + responseType = com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute> + getGetGatewayAdvertisedRouteMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute> + getGetGatewayAdvertisedRouteMethod; + if ((getGetGatewayAdvertisedRouteMethod = HubServiceGrpc.getGetGatewayAdvertisedRouteMethod) + == null) { + synchronized (HubServiceGrpc.class) { + if ((getGetGatewayAdvertisedRouteMethod = HubServiceGrpc.getGetGatewayAdvertisedRouteMethod) + == null) { + HubServiceGrpc.getGetGatewayAdvertisedRouteMethod = + getGetGatewayAdvertisedRouteMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetGatewayAdvertisedRoute")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.networkconnectivity.v1 + .GetGatewayAdvertisedRouteRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + .getDefaultInstance())) + .setSchemaDescriptor( + new HubServiceMethodDescriptorSupplier("GetGatewayAdvertisedRoute")) + .build(); + } + } + } + return getGetGatewayAdvertisedRouteMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest, + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse> + getListGatewayAdvertisedRoutesMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListGatewayAdvertisedRoutes", + requestType = + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest.class, + responseType = + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest, + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse> + getListGatewayAdvertisedRoutesMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest, + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse> + getListGatewayAdvertisedRoutesMethod; + if ((getListGatewayAdvertisedRoutesMethod = HubServiceGrpc.getListGatewayAdvertisedRoutesMethod) + == null) { + synchronized (HubServiceGrpc.class) { + if ((getListGatewayAdvertisedRoutesMethod = + HubServiceGrpc.getListGatewayAdvertisedRoutesMethod) + == null) { + HubServiceGrpc.getListGatewayAdvertisedRoutesMethod = + getListGatewayAdvertisedRoutesMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListGatewayAdvertisedRoutes")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.networkconnectivity.v1 + .ListGatewayAdvertisedRoutesRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.networkconnectivity.v1 + .ListGatewayAdvertisedRoutesResponse.getDefaultInstance())) + .setSchemaDescriptor( + new HubServiceMethodDescriptorSupplier("ListGatewayAdvertisedRoutes")) + .build(); + } + } + } + return getListGatewayAdvertisedRoutesMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation> + getUpdateGatewayAdvertisedRouteMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateGatewayAdvertisedRoute", + requestType = + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation> + getUpdateGatewayAdvertisedRouteMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation> + getUpdateGatewayAdvertisedRouteMethod; + if ((getUpdateGatewayAdvertisedRouteMethod = + HubServiceGrpc.getUpdateGatewayAdvertisedRouteMethod) + == null) { + synchronized (HubServiceGrpc.class) { + if ((getUpdateGatewayAdvertisedRouteMethod = + HubServiceGrpc.getUpdateGatewayAdvertisedRouteMethod) + == null) { + HubServiceGrpc.getUpdateGatewayAdvertisedRouteMethod = + getUpdateGatewayAdvertisedRouteMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "UpdateGatewayAdvertisedRoute")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.networkconnectivity.v1 + .UpdateGatewayAdvertisedRouteRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new HubServiceMethodDescriptorSupplier("UpdateGatewayAdvertisedRoute")) + .build(); + } + } + } + return getUpdateGatewayAdvertisedRouteMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation> + getDeleteGatewayAdvertisedRouteMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteGatewayAdvertisedRoute", + requestType = + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation> + getDeleteGatewayAdvertisedRouteMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation> + getDeleteGatewayAdvertisedRouteMethod; + if ((getDeleteGatewayAdvertisedRouteMethod = + HubServiceGrpc.getDeleteGatewayAdvertisedRouteMethod) + == null) { + synchronized (HubServiceGrpc.class) { + if ((getDeleteGatewayAdvertisedRouteMethod = + HubServiceGrpc.getDeleteGatewayAdvertisedRouteMethod) + == null) { + HubServiceGrpc.getDeleteGatewayAdvertisedRouteMethod = + getDeleteGatewayAdvertisedRouteMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "DeleteGatewayAdvertisedRoute")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.networkconnectivity.v1 + .DeleteGatewayAdvertisedRouteRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new HubServiceMethodDescriptorSupplier("DeleteGatewayAdvertisedRoute")) + .build(); + } + } + } + return getDeleteGatewayAdvertisedRouteMethod; + } + /** Creates a new async stub that supports all call types for the service */ public static HubServiceStub newStub(io.grpc.Channel channel) { io.grpc.stub.AbstractStub.StubFactory factory = @@ -1475,6 +1735,79 @@ default void updateGroup( io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( getUpdateGroupMethod(), responseObserver); } + + /** + * + * + *
            +     * Create a GatewayAdvertisedRoute
            +     * 
            + */ + default void createGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateGatewayAdvertisedRouteMethod(), responseObserver); + } + + /** + * + * + *
            +     * Get a GatewayAdvertisedRoute
            +     * 
            + */ + default void getGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetGatewayAdvertisedRouteMethod(), responseObserver); + } + + /** + * + * + *
            +     * List GatewayAdvertisedRoutes
            +     * 
            + */ + default void listGatewayAdvertisedRoutes( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse> + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListGatewayAdvertisedRoutesMethod(), responseObserver); + } + + /** + * + * + *
            +     * Update a GatewayAdvertisedRoute
            +     * 
            + */ + default void updateGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateGatewayAdvertisedRouteMethod(), responseObserver); + } + + /** + * + * + *
            +     * Delete a GatewayAdvertisedRoute
            +     * 
            + */ + default void deleteGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteGatewayAdvertisedRouteMethod(), responseObserver); + } } /** @@ -1878,6 +2211,89 @@ public void updateGroup( request, responseObserver); } + + /** + * + * + *
            +     * Create a GatewayAdvertisedRoute
            +     * 
            + */ + public void createGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateGatewayAdvertisedRouteMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
            +     * Get a GatewayAdvertisedRoute
            +     * 
            + */ + public void getGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetGatewayAdvertisedRouteMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
            +     * List GatewayAdvertisedRoutes
            +     * 
            + */ + public void listGatewayAdvertisedRoutes( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse> + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListGatewayAdvertisedRoutesMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
            +     * Update a GatewayAdvertisedRoute
            +     * 
            + */ + public void updateGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateGatewayAdvertisedRouteMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
            +     * Delete a GatewayAdvertisedRoute
            +     * 
            + */ + public void deleteGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteGatewayAdvertisedRouteMethod(), getCallOptions()), + request, + responseObserver); + } } /** @@ -2231,6 +2647,77 @@ public com.google.longrunning.Operation updateGroup( return io.grpc.stub.ClientCalls.blockingV2UnaryCall( getChannel(), getUpdateGroupMethod(), getCallOptions(), request); } + + /** + * + * + *
            +     * Create a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.longrunning.Operation createGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getCreateGatewayAdvertisedRouteMethod(), getCallOptions(), request); + } + + /** + * + * + *
            +     * Get a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute getGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetGatewayAdvertisedRouteMethod(), getCallOptions(), request); + } + + /** + * + * + *
            +     * List GatewayAdvertisedRoutes
            +     * 
            + */ + public com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + listGatewayAdvertisedRoutes( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListGatewayAdvertisedRoutesMethod(), getCallOptions(), request); + } + + /** + * + * + *
            +     * Update a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.longrunning.Operation updateGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getUpdateGatewayAdvertisedRouteMethod(), getCallOptions(), request); + } + + /** + * + * + *
            +     * Delete a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.longrunning.Operation deleteGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getDeleteGatewayAdvertisedRouteMethod(), getCallOptions(), request); + } } /** @@ -2561,6 +3048,72 @@ public com.google.longrunning.Operation updateGroup( return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getUpdateGroupMethod(), getCallOptions(), request); } + + /** + * + * + *
            +     * Create a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.longrunning.Operation createGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateGatewayAdvertisedRouteMethod(), getCallOptions(), request); + } + + /** + * + * + *
            +     * Get a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute getGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetGatewayAdvertisedRouteMethod(), getCallOptions(), request); + } + + /** + * + * + *
            +     * List GatewayAdvertisedRoutes
            +     * 
            + */ + public com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + listGatewayAdvertisedRoutes( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListGatewayAdvertisedRoutesMethod(), getCallOptions(), request); + } + + /** + * + * + *
            +     * Update a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.longrunning.Operation updateGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateGatewayAdvertisedRouteMethod(), getCallOptions(), request); + } + + /** + * + * + *
            +     * Delete a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.longrunning.Operation deleteGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteGatewayAdvertisedRouteMethod(), getCallOptions(), request); + } } /** @@ -2904,6 +3457,78 @@ protected HubServiceFutureStub build(io.grpc.Channel channel, io.grpc.CallOption return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getUpdateGroupMethod(), getCallOptions()), request); } + + /** + * + * + *
            +     * Create a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.common.util.concurrent.ListenableFuture + createGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateGatewayAdvertisedRouteMethod(), getCallOptions()), request); + } + + /** + * + * + *
            +     * Get a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute> + getGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetGatewayAdvertisedRouteMethod(), getCallOptions()), request); + } + + /** + * + * + *
            +     * List GatewayAdvertisedRoutes
            +     * 
            + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse> + listGatewayAdvertisedRoutes( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListGatewayAdvertisedRoutesMethod(), getCallOptions()), request); + } + + /** + * + * + *
            +     * Update a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.common.util.concurrent.ListenableFuture + updateGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateGatewayAdvertisedRouteMethod(), getCallOptions()), request); + } + + /** + * + * + *
            +     * Delete a GatewayAdvertisedRoute
            +     * 
            + */ + public com.google.common.util.concurrent.ListenableFuture + deleteGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteGatewayAdvertisedRouteMethod(), getCallOptions()), request); + } } private static final int METHODID_LIST_HUBS = 0; @@ -2929,6 +3554,11 @@ protected HubServiceFutureStub build(io.grpc.Channel channel, io.grpc.CallOption private static final int METHODID_GET_GROUP = 20; private static final int METHODID_LIST_GROUPS = 21; private static final int METHODID_UPDATE_GROUP = 22; + private static final int METHODID_CREATE_GATEWAY_ADVERTISED_ROUTE = 23; + private static final int METHODID_GET_GATEWAY_ADVERTISED_ROUTE = 24; + private static final int METHODID_LIST_GATEWAY_ADVERTISED_ROUTES = 25; + private static final int METHODID_UPDATE_GATEWAY_ADVERTISED_ROUTE = 26; + private static final int METHODID_DELETE_GATEWAY_ADVERTISED_ROUTE = 27; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -3081,6 +3711,35 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (com.google.cloud.networkconnectivity.v1.UpdateGroupRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_CREATE_GATEWAY_ADVERTISED_ROUTE: + serviceImpl.createGatewayAdvertisedRoute( + (com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_GATEWAY_ADVERTISED_ROUTE: + serviceImpl.getGatewayAdvertisedRoute( + (com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute>) + responseObserver); + break; + case METHODID_LIST_GATEWAY_ADVERTISED_ROUTES: + serviceImpl.listGatewayAdvertisedRoutes( + (com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse>) + responseObserver); + break; + case METHODID_UPDATE_GATEWAY_ADVERTISED_ROUTE: + serviceImpl.updateGatewayAdvertisedRoute( + (com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DELETE_GATEWAY_ADVERTISED_ROUTE: + serviceImpl.deleteGatewayAdvertisedRoute( + (com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; default: throw new AssertionError(); } @@ -3245,6 +3904,41 @@ public static final io.grpc.ServerServiceDefinition bindService(AsyncService ser new MethodHandlers< com.google.cloud.networkconnectivity.v1.UpdateGroupRequest, com.google.longrunning.Operation>(service, METHODID_UPDATE_GROUP))) + .addMethod( + getCreateGatewayAdvertisedRouteMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation>( + service, METHODID_CREATE_GATEWAY_ADVERTISED_ROUTE))) + .addMethod( + getGetGatewayAdvertisedRouteMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute>( + service, METHODID_GET_GATEWAY_ADVERTISED_ROUTE))) + .addMethod( + getListGatewayAdvertisedRoutesMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest, + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse>( + service, METHODID_LIST_GATEWAY_ADVERTISED_ROUTES))) + .addMethod( + getUpdateGatewayAdvertisedRouteMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation>( + service, METHODID_UPDATE_GATEWAY_ADVERTISED_ROUTE))) + .addMethod( + getDeleteGatewayAdvertisedRouteMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest, + com.google.longrunning.Operation>( + service, METHODID_DELETE_GATEWAY_ADVERTISED_ROUTE))) .build(); } @@ -3319,6 +4013,11 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getGetGroupMethod()) .addMethod(getListGroupsMethod()) .addMethod(getUpdateGroupMethod()) + .addMethod(getCreateGatewayAdvertisedRouteMethod()) + .addMethod(getGetGatewayAdvertisedRouteMethod()) + .addMethod(getListGatewayAdvertisedRoutesMethod()) + .addMethod(getUpdateGatewayAdvertisedRouteMethod()) + .addMethod(getDeleteGatewayAdvertisedRouteMethod()) .build(); } } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/CreateGatewayAdvertisedRouteRequest.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/CreateGatewayAdvertisedRouteRequest.java new file mode 100644 index 000000000000..2bf1a2c8cfce --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/CreateGatewayAdvertisedRouteRequest.java @@ -0,0 +1,1456 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +/** + * + * + *
            + * The request for
            + * [HubService.CreateGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.CreateGatewayAdvertisedRoute].
            + * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest} + */ +@com.google.protobuf.Generated +public final class CreateGatewayAdvertisedRouteRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest) + CreateGatewayAdvertisedRouteRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "CreateGatewayAdvertisedRouteRequest"); + } + + // Use CreateGatewayAdvertisedRouteRequest.newBuilder() to construct. + private CreateGatewayAdvertisedRouteRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private CreateGatewayAdvertisedRouteRequest() { + parent_ = ""; + gatewayAdvertisedRouteId_ = ""; + requestId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_CreateGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_CreateGatewayAdvertisedRouteRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest.class, + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest.Builder + .class); + } + + private int bitField0_; + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
            +   * Required. The parent resource.
            +   * 
            + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
            +   * Required. The parent resource.
            +   * 
            + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int GATEWAY_ADVERTISED_ROUTE_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object gatewayAdvertisedRouteId_ = ""; + + /** + * + * + *
            +   * Required. Unique id for the route to create.
            +   * 
            + * + * string gateway_advertised_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The gatewayAdvertisedRouteId. + */ + @java.lang.Override + public java.lang.String getGatewayAdvertisedRouteId() { + java.lang.Object ref = gatewayAdvertisedRouteId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + gatewayAdvertisedRouteId_ = s; + return s; + } + } + + /** + * + * + *
            +   * Required. Unique id for the route to create.
            +   * 
            + * + * string gateway_advertised_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for gatewayAdvertisedRouteId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getGatewayAdvertisedRouteIdBytes() { + java.lang.Object ref = gatewayAdvertisedRouteId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + gatewayAdvertisedRouteId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int GATEWAY_ADVERTISED_ROUTE_FIELD_NUMBER = 3; + private com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gatewayAdvertisedRoute_; + + /** + * + * + *
            +   * Required. Initial values for the new gateway advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the gatewayAdvertisedRoute field is set. + */ + @java.lang.Override + public boolean hasGatewayAdvertisedRoute() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
            +   * Required. Initial values for the new gateway advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The gatewayAdvertisedRoute. + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + getGatewayAdvertisedRoute() { + return gatewayAdvertisedRoute_ == null + ? com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance() + : gatewayAdvertisedRoute_; + } + + /** + * + * + *
            +   * Required. Initial values for the new gateway advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder + getGatewayAdvertisedRouteOrBuilder() { + return gatewayAdvertisedRoute_ == null + ? com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance() + : gatewayAdvertisedRoute_; + } + + public static final int REQUEST_ID_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object requestId_ = ""; + + /** + * + * + *
            +   * Optional. A request ID to identify requests. Specify a unique request ID so
            +   * that if you must retry your request, the server knows to ignore the request
            +   * if it has already been completed. The server guarantees that a request
            +   * doesn't result in creation of duplicate commitments for at least 60
            +   * minutes.
            +   *
            +   * For example, consider a situation where you make an initial request and
            +   * the request times out. If you make the request again with the same request
            +   * ID, the server can check to see whether the original operation
            +   * was received. If it was, the server ignores the second request. This
            +   * behavior prevents clients from mistakenly creating duplicate commitments.
            +   *
            +   * The request ID must be a valid UUID, with the exception that zero UUID is
            +   * not supported (00000000-0000-0000-0000-000000000000).
            +   * 
            + * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + @java.lang.Override + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } + } + + /** + * + * + *
            +   * Optional. A request ID to identify requests. Specify a unique request ID so
            +   * that if you must retry your request, the server knows to ignore the request
            +   * if it has already been completed. The server guarantees that a request
            +   * doesn't result in creation of duplicate commitments for at least 60
            +   * minutes.
            +   *
            +   * For example, consider a situation where you make an initial request and
            +   * the request times out. If you make the request again with the same request
            +   * ID, the server can check to see whether the original operation
            +   * was received. If it was, the server ignores the second request. This
            +   * behavior prevents clients from mistakenly creating duplicate commitments.
            +   *
            +   * The request ID must be a valid UUID, with the exception that zero UUID is
            +   * not supported (00000000-0000-0000-0000-000000000000).
            +   * 
            + * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(gatewayAdvertisedRouteId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, gatewayAdvertisedRouteId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getGatewayAdvertisedRoute()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, requestId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(gatewayAdvertisedRouteId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, gatewayAdvertisedRouteId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(3, getGatewayAdvertisedRoute()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, requestId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest other = + (com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (!getGatewayAdvertisedRouteId().equals(other.getGatewayAdvertisedRouteId())) return false; + if (hasGatewayAdvertisedRoute() != other.hasGatewayAdvertisedRoute()) return false; + if (hasGatewayAdvertisedRoute()) { + if (!getGatewayAdvertisedRoute().equals(other.getGatewayAdvertisedRoute())) return false; + } + if (!getRequestId().equals(other.getRequestId())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + GATEWAY_ADVERTISED_ROUTE_ID_FIELD_NUMBER; + hash = (53 * hash) + getGatewayAdvertisedRouteId().hashCode(); + if (hasGatewayAdvertisedRoute()) { + hash = (37 * hash) + GATEWAY_ADVERTISED_ROUTE_FIELD_NUMBER; + hash = (53 * hash) + getGatewayAdvertisedRoute().hashCode(); + } + hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; + hash = (53 * hash) + getRequestId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
            +   * The request for
            +   * [HubService.CreateGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.CreateGatewayAdvertisedRoute].
            +   * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest) + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_CreateGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_CreateGatewayAdvertisedRouteRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest.class, + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest.Builder + .class); + } + + // Construct using + // com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetGatewayAdvertisedRouteFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + gatewayAdvertisedRouteId_ = ""; + gatewayAdvertisedRoute_ = null; + if (gatewayAdvertisedRouteBuilder_ != null) { + gatewayAdvertisedRouteBuilder_.dispose(); + gatewayAdvertisedRouteBuilder_ = null; + } + requestId_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_CreateGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest build() { + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + buildPartial() { + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest result = + new com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.gatewayAdvertisedRouteId_ = gatewayAdvertisedRouteId_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.gatewayAdvertisedRoute_ = + gatewayAdvertisedRouteBuilder_ == null + ? gatewayAdvertisedRoute_ + : gatewayAdvertisedRouteBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.requestId_ = requestId_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest) { + return mergeFrom( + (com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest other) { + if (other + == com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + .getDefaultInstance()) return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getGatewayAdvertisedRouteId().isEmpty()) { + gatewayAdvertisedRouteId_ = other.gatewayAdvertisedRouteId_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasGatewayAdvertisedRoute()) { + mergeGatewayAdvertisedRoute(other.getGatewayAdvertisedRoute()); + } + if (!other.getRequestId().isEmpty()) { + requestId_ = other.requestId_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + gatewayAdvertisedRouteId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetGatewayAdvertisedRouteFieldBuilder().getBuilder(), + extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + requestId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
            +     * Required. The parent resource.
            +     * 
            + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * Required. The parent resource.
            +     * 
            + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * Required. The parent resource.
            +     * 
            + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Required. The parent resource.
            +     * 
            + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Required. The parent resource.
            +     * 
            + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object gatewayAdvertisedRouteId_ = ""; + + /** + * + * + *
            +     * Required. Unique id for the route to create.
            +     * 
            + * + * string gateway_advertised_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The gatewayAdvertisedRouteId. + */ + public java.lang.String getGatewayAdvertisedRouteId() { + java.lang.Object ref = gatewayAdvertisedRouteId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + gatewayAdvertisedRouteId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * Required. Unique id for the route to create.
            +     * 
            + * + * string gateway_advertised_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The bytes for gatewayAdvertisedRouteId. + */ + public com.google.protobuf.ByteString getGatewayAdvertisedRouteIdBytes() { + java.lang.Object ref = gatewayAdvertisedRouteId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + gatewayAdvertisedRouteId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * Required. Unique id for the route to create.
            +     * 
            + * + * string gateway_advertised_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The gatewayAdvertisedRouteId to set. + * @return This builder for chaining. + */ + public Builder setGatewayAdvertisedRouteId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + gatewayAdvertisedRouteId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Required. Unique id for the route to create.
            +     * 
            + * + * string gateway_advertised_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return This builder for chaining. + */ + public Builder clearGatewayAdvertisedRouteId() { + gatewayAdvertisedRouteId_ = getDefaultInstance().getGatewayAdvertisedRouteId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Required. Unique id for the route to create.
            +     * 
            + * + * string gateway_advertised_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @param value The bytes for gatewayAdvertisedRouteId to set. + * @return This builder for chaining. + */ + public Builder setGatewayAdvertisedRouteIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + gatewayAdvertisedRouteId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gatewayAdvertisedRoute_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder> + gatewayAdvertisedRouteBuilder_; + + /** + * + * + *
            +     * Required. Initial values for the new gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the gatewayAdvertisedRoute field is set. + */ + public boolean hasGatewayAdvertisedRoute() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
            +     * Required. Initial values for the new gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The gatewayAdvertisedRoute. + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + getGatewayAdvertisedRoute() { + if (gatewayAdvertisedRouteBuilder_ == null) { + return gatewayAdvertisedRoute_ == null + ? com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance() + : gatewayAdvertisedRoute_; + } else { + return gatewayAdvertisedRouteBuilder_.getMessage(); + } + } + + /** + * + * + *
            +     * Required. Initial values for the new gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute value) { + if (gatewayAdvertisedRouteBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + gatewayAdvertisedRoute_ = value; + } else { + gatewayAdvertisedRouteBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Required. Initial values for the new gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder builderForValue) { + if (gatewayAdvertisedRouteBuilder_ == null) { + gatewayAdvertisedRoute_ = builderForValue.build(); + } else { + gatewayAdvertisedRouteBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Required. Initial values for the new gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute value) { + if (gatewayAdvertisedRouteBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && gatewayAdvertisedRoute_ != null + && gatewayAdvertisedRoute_ + != com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + .getDefaultInstance()) { + getGatewayAdvertisedRouteBuilder().mergeFrom(value); + } else { + gatewayAdvertisedRoute_ = value; + } + } else { + gatewayAdvertisedRouteBuilder_.mergeFrom(value); + } + if (gatewayAdvertisedRoute_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
            +     * Required. Initial values for the new gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearGatewayAdvertisedRoute() { + bitField0_ = (bitField0_ & ~0x00000004); + gatewayAdvertisedRoute_ = null; + if (gatewayAdvertisedRouteBuilder_ != null) { + gatewayAdvertisedRouteBuilder_.dispose(); + gatewayAdvertisedRouteBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
            +     * Required. Initial values for the new gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder + getGatewayAdvertisedRouteBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetGatewayAdvertisedRouteFieldBuilder().getBuilder(); + } + + /** + * + * + *
            +     * Required. Initial values for the new gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder + getGatewayAdvertisedRouteOrBuilder() { + if (gatewayAdvertisedRouteBuilder_ != null) { + return gatewayAdvertisedRouteBuilder_.getMessageOrBuilder(); + } else { + return gatewayAdvertisedRoute_ == null + ? com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance() + : gatewayAdvertisedRoute_; + } + } + + /** + * + * + *
            +     * Required. Initial values for the new gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder> + internalGetGatewayAdvertisedRouteFieldBuilder() { + if (gatewayAdvertisedRouteBuilder_ == null) { + gatewayAdvertisedRouteBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder>( + getGatewayAdvertisedRoute(), getParentForChildren(), isClean()); + gatewayAdvertisedRoute_ = null; + } + return gatewayAdvertisedRouteBuilder_; + } + + private java.lang.Object requestId_ = ""; + + /** + * + * + *
            +     * Optional. A request ID to identify requests. Specify a unique request ID so
            +     * that if you must retry your request, the server knows to ignore the request
            +     * if it has already been completed. The server guarantees that a request
            +     * doesn't result in creation of duplicate commitments for at least 60
            +     * minutes.
            +     *
            +     * For example, consider a situation where you make an initial request and
            +     * the request times out. If you make the request again with the same request
            +     * ID, the server can check to see whether the original operation
            +     * was received. If it was, the server ignores the second request. This
            +     * behavior prevents clients from mistakenly creating duplicate commitments.
            +     *
            +     * The request ID must be a valid UUID, with the exception that zero UUID is
            +     * not supported (00000000-0000-0000-0000-000000000000).
            +     * 
            + * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * Optional. A request ID to identify requests. Specify a unique request ID so
            +     * that if you must retry your request, the server knows to ignore the request
            +     * if it has already been completed. The server guarantees that a request
            +     * doesn't result in creation of duplicate commitments for at least 60
            +     * minutes.
            +     *
            +     * For example, consider a situation where you make an initial request and
            +     * the request times out. If you make the request again with the same request
            +     * ID, the server can check to see whether the original operation
            +     * was received. If it was, the server ignores the second request. This
            +     * behavior prevents clients from mistakenly creating duplicate commitments.
            +     *
            +     * The request ID must be a valid UUID, with the exception that zero UUID is
            +     * not supported (00000000-0000-0000-0000-000000000000).
            +     * 
            + * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * Optional. A request ID to identify requests. Specify a unique request ID so
            +     * that if you must retry your request, the server knows to ignore the request
            +     * if it has already been completed. The server guarantees that a request
            +     * doesn't result in creation of duplicate commitments for at least 60
            +     * minutes.
            +     *
            +     * For example, consider a situation where you make an initial request and
            +     * the request times out. If you make the request again with the same request
            +     * ID, the server can check to see whether the original operation
            +     * was received. If it was, the server ignores the second request. This
            +     * behavior prevents clients from mistakenly creating duplicate commitments.
            +     *
            +     * The request ID must be a valid UUID, with the exception that zero UUID is
            +     * not supported (00000000-0000-0000-0000-000000000000).
            +     * 
            + * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + requestId_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. A request ID to identify requests. Specify a unique request ID so
            +     * that if you must retry your request, the server knows to ignore the request
            +     * if it has already been completed. The server guarantees that a request
            +     * doesn't result in creation of duplicate commitments for at least 60
            +     * minutes.
            +     *
            +     * For example, consider a situation where you make an initial request and
            +     * the request times out. If you make the request again with the same request
            +     * ID, the server can check to see whether the original operation
            +     * was received. If it was, the server ignores the second request. This
            +     * behavior prevents clients from mistakenly creating duplicate commitments.
            +     *
            +     * The request ID must be a valid UUID, with the exception that zero UUID is
            +     * not supported (00000000-0000-0000-0000-000000000000).
            +     * 
            + * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearRequestId() { + requestId_ = getDefaultInstance().getRequestId(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. A request ID to identify requests. Specify a unique request ID so
            +     * that if you must retry your request, the server knows to ignore the request
            +     * if it has already been completed. The server guarantees that a request
            +     * doesn't result in creation of duplicate commitments for at least 60
            +     * minutes.
            +     *
            +     * For example, consider a situation where you make an initial request and
            +     * the request times out. If you make the request again with the same request
            +     * ID, the server can check to see whether the original operation
            +     * was received. If it was, the server ignores the second request. This
            +     * behavior prevents clients from mistakenly creating duplicate commitments.
            +     *
            +     * The request ID must be a valid UUID, with the exception that zero UUID is
            +     * not supported (00000000-0000-0000-0000-000000000000).
            +     * 
            + * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + requestId_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest) + private static final com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest(); + } + + public static com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateGatewayAdvertisedRouteRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/CreateGatewayAdvertisedRouteRequestOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/CreateGatewayAdvertisedRouteRequestOrBuilder.java new file mode 100644 index 000000000000..142cfd1709d1 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/CreateGatewayAdvertisedRouteRequestOrBuilder.java @@ -0,0 +1,184 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +@com.google.protobuf.Generated +public interface CreateGatewayAdvertisedRouteRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
            +   * Required. The parent resource.
            +   * 
            + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
            +   * Required. The parent resource.
            +   * 
            + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
            +   * Required. Unique id for the route to create.
            +   * 
            + * + * string gateway_advertised_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The gatewayAdvertisedRouteId. + */ + java.lang.String getGatewayAdvertisedRouteId(); + + /** + * + * + *
            +   * Required. Unique id for the route to create.
            +   * 
            + * + * string gateway_advertised_route_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for gatewayAdvertisedRouteId. + */ + com.google.protobuf.ByteString getGatewayAdvertisedRouteIdBytes(); + + /** + * + * + *
            +   * Required. Initial values for the new gateway advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the gatewayAdvertisedRoute field is set. + */ + boolean hasGatewayAdvertisedRoute(); + + /** + * + * + *
            +   * Required. Initial values for the new gateway advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The gatewayAdvertisedRoute. + */ + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute getGatewayAdvertisedRoute(); + + /** + * + * + *
            +   * Required. Initial values for the new gateway advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder + getGatewayAdvertisedRouteOrBuilder(); + + /** + * + * + *
            +   * Optional. A request ID to identify requests. Specify a unique request ID so
            +   * that if you must retry your request, the server knows to ignore the request
            +   * if it has already been completed. The server guarantees that a request
            +   * doesn't result in creation of duplicate commitments for at least 60
            +   * minutes.
            +   *
            +   * For example, consider a situation where you make an initial request and
            +   * the request times out. If you make the request again with the same request
            +   * ID, the server can check to see whether the original operation
            +   * was received. If it was, the server ignores the second request. This
            +   * behavior prevents clients from mistakenly creating duplicate commitments.
            +   *
            +   * The request ID must be a valid UUID, with the exception that zero UUID is
            +   * not supported (00000000-0000-0000-0000-000000000000).
            +   * 
            + * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + java.lang.String getRequestId(); + + /** + * + * + *
            +   * Optional. A request ID to identify requests. Specify a unique request ID so
            +   * that if you must retry your request, the server knows to ignore the request
            +   * if it has already been completed. The server guarantees that a request
            +   * doesn't result in creation of duplicate commitments for at least 60
            +   * minutes.
            +   *
            +   * For example, consider a situation where you make an initial request and
            +   * the request times out. If you make the request again with the same request
            +   * ID, the server can check to see whether the original operation
            +   * was received. If it was, the server ignores the second request. This
            +   * behavior prevents clients from mistakenly creating duplicate commitments.
            +   *
            +   * The request ID must be a valid UUID, with the exception that zero UUID is
            +   * not supported (00000000-0000-0000-0000-000000000000).
            +   * 
            + * + * + * string request_id = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + com.google.protobuf.ByteString getRequestIdBytes(); +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeleteGatewayAdvertisedRouteRequest.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeleteGatewayAdvertisedRouteRequest.java new file mode 100644 index 000000000000..73e2f1709fd9 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeleteGatewayAdvertisedRouteRequest.java @@ -0,0 +1,933 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +/** + * + * + *
            + * Request for
            + * [HubService.DeleteGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.DeleteGatewayAdvertisedRoute]
            + * method.
            + * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest} + */ +@com.google.protobuf.Generated +public final class DeleteGatewayAdvertisedRouteRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest) + DeleteGatewayAdvertisedRouteRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DeleteGatewayAdvertisedRouteRequest"); + } + + // Use DeleteGatewayAdvertisedRouteRequest.newBuilder() to construct. + private DeleteGatewayAdvertisedRouteRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DeleteGatewayAdvertisedRouteRequest() { + name_ = ""; + requestId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_DeleteGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_DeleteGatewayAdvertisedRouteRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest.class, + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest.Builder + .class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
            +   * Required. The name of the gateway advertised route to delete.
            +   * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
            +   * Required. The name of the gateway advertised route to delete.
            +   * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int REQUEST_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object requestId_ = ""; + + /** + * + * + *
            +   * Optional. A request ID to identify requests. Specify a unique request ID so
            +   * that if you must retry your request, the server knows to ignore the request
            +   * if it has already been completed. The server guarantees that a request
            +   * doesn't result in creation of duplicate commitments for at least 60
            +   * minutes.
            +   *
            +   * For example, consider a situation where you make an initial request and
            +   * the request times out. If you make the request again with the same request
            +   * ID, the server can check to see whether the original operation
            +   * was received. If it was, the server ignores the second request. This
            +   * behavior prevents clients from mistakenly creating duplicate commitments.
            +   *
            +   * The request ID must be a valid UUID, with the exception that zero UUID is
            +   * not supported (00000000-0000-0000-0000-000000000000).
            +   * 
            + * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + @java.lang.Override + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } + } + + /** + * + * + *
            +   * Optional. A request ID to identify requests. Specify a unique request ID so
            +   * that if you must retry your request, the server knows to ignore the request
            +   * if it has already been completed. The server guarantees that a request
            +   * doesn't result in creation of duplicate commitments for at least 60
            +   * minutes.
            +   *
            +   * For example, consider a situation where you make an initial request and
            +   * the request times out. If you make the request again with the same request
            +   * ID, the server can check to see whether the original operation
            +   * was received. If it was, the server ignores the second request. This
            +   * behavior prevents clients from mistakenly creating duplicate commitments.
            +   *
            +   * The request ID must be a valid UUID, with the exception that zero UUID is
            +   * not supported (00000000-0000-0000-0000-000000000000).
            +   * 
            + * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, requestId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, requestId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest other = + (com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getRequestId().equals(other.getRequestId())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; + hash = (53 * hash) + getRequestId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
            +   * Request for
            +   * [HubService.DeleteGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.DeleteGatewayAdvertisedRoute]
            +   * method.
            +   * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest) + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_DeleteGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_DeleteGatewayAdvertisedRouteRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest.class, + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest.Builder + .class); + } + + // Construct using + // com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + requestId_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_DeleteGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest build() { + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + buildPartial() { + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest result = + new com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.requestId_ = requestId_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest) { + return mergeFrom( + (com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest other) { + if (other + == com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + .getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getRequestId().isEmpty()) { + requestId_ = other.requestId_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + requestId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
            +     * Required. The name of the gateway advertised route to delete.
            +     * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * Required. The name of the gateway advertised route to delete.
            +     * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * Required. The name of the gateway advertised route to delete.
            +     * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Required. The name of the gateway advertised route to delete.
            +     * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Required. The name of the gateway advertised route to delete.
            +     * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object requestId_ = ""; + + /** + * + * + *
            +     * Optional. A request ID to identify requests. Specify a unique request ID so
            +     * that if you must retry your request, the server knows to ignore the request
            +     * if it has already been completed. The server guarantees that a request
            +     * doesn't result in creation of duplicate commitments for at least 60
            +     * minutes.
            +     *
            +     * For example, consider a situation where you make an initial request and
            +     * the request times out. If you make the request again with the same request
            +     * ID, the server can check to see whether the original operation
            +     * was received. If it was, the server ignores the second request. This
            +     * behavior prevents clients from mistakenly creating duplicate commitments.
            +     *
            +     * The request ID must be a valid UUID, with the exception that zero UUID is
            +     * not supported (00000000-0000-0000-0000-000000000000).
            +     * 
            + * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * Optional. A request ID to identify requests. Specify a unique request ID so
            +     * that if you must retry your request, the server knows to ignore the request
            +     * if it has already been completed. The server guarantees that a request
            +     * doesn't result in creation of duplicate commitments for at least 60
            +     * minutes.
            +     *
            +     * For example, consider a situation where you make an initial request and
            +     * the request times out. If you make the request again with the same request
            +     * ID, the server can check to see whether the original operation
            +     * was received. If it was, the server ignores the second request. This
            +     * behavior prevents clients from mistakenly creating duplicate commitments.
            +     *
            +     * The request ID must be a valid UUID, with the exception that zero UUID is
            +     * not supported (00000000-0000-0000-0000-000000000000).
            +     * 
            + * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * Optional. A request ID to identify requests. Specify a unique request ID so
            +     * that if you must retry your request, the server knows to ignore the request
            +     * if it has already been completed. The server guarantees that a request
            +     * doesn't result in creation of duplicate commitments for at least 60
            +     * minutes.
            +     *
            +     * For example, consider a situation where you make an initial request and
            +     * the request times out. If you make the request again with the same request
            +     * ID, the server can check to see whether the original operation
            +     * was received. If it was, the server ignores the second request. This
            +     * behavior prevents clients from mistakenly creating duplicate commitments.
            +     *
            +     * The request ID must be a valid UUID, with the exception that zero UUID is
            +     * not supported (00000000-0000-0000-0000-000000000000).
            +     * 
            + * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + requestId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. A request ID to identify requests. Specify a unique request ID so
            +     * that if you must retry your request, the server knows to ignore the request
            +     * if it has already been completed. The server guarantees that a request
            +     * doesn't result in creation of duplicate commitments for at least 60
            +     * minutes.
            +     *
            +     * For example, consider a situation where you make an initial request and
            +     * the request times out. If you make the request again with the same request
            +     * ID, the server can check to see whether the original operation
            +     * was received. If it was, the server ignores the second request. This
            +     * behavior prevents clients from mistakenly creating duplicate commitments.
            +     *
            +     * The request ID must be a valid UUID, with the exception that zero UUID is
            +     * not supported (00000000-0000-0000-0000-000000000000).
            +     * 
            + * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearRequestId() { + requestId_ = getDefaultInstance().getRequestId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. A request ID to identify requests. Specify a unique request ID so
            +     * that if you must retry your request, the server knows to ignore the request
            +     * if it has already been completed. The server guarantees that a request
            +     * doesn't result in creation of duplicate commitments for at least 60
            +     * minutes.
            +     *
            +     * For example, consider a situation where you make an initial request and
            +     * the request times out. If you make the request again with the same request
            +     * ID, the server can check to see whether the original operation
            +     * was received. If it was, the server ignores the second request. This
            +     * behavior prevents clients from mistakenly creating duplicate commitments.
            +     *
            +     * The request ID must be a valid UUID, with the exception that zero UUID is
            +     * not supported (00000000-0000-0000-0000-000000000000).
            +     * 
            + * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + requestId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest) + private static final com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest(); + } + + public static com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteGatewayAdvertisedRouteRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeleteGatewayAdvertisedRouteRequestOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeleteGatewayAdvertisedRouteRequestOrBuilder.java new file mode 100644 index 000000000000..6c6465582339 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/DeleteGatewayAdvertisedRouteRequestOrBuilder.java @@ -0,0 +1,114 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +@com.google.protobuf.Generated +public interface DeleteGatewayAdvertisedRouteRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
            +   * Required. The name of the gateway advertised route to delete.
            +   * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
            +   * Required. The name of the gateway advertised route to delete.
            +   * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
            +   * Optional. A request ID to identify requests. Specify a unique request ID so
            +   * that if you must retry your request, the server knows to ignore the request
            +   * if it has already been completed. The server guarantees that a request
            +   * doesn't result in creation of duplicate commitments for at least 60
            +   * minutes.
            +   *
            +   * For example, consider a situation where you make an initial request and
            +   * the request times out. If you make the request again with the same request
            +   * ID, the server can check to see whether the original operation
            +   * was received. If it was, the server ignores the second request. This
            +   * behavior prevents clients from mistakenly creating duplicate commitments.
            +   *
            +   * The request ID must be a valid UUID, with the exception that zero UUID is
            +   * not supported (00000000-0000-0000-0000-000000000000).
            +   * 
            + * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + java.lang.String getRequestId(); + + /** + * + * + *
            +   * Optional. A request ID to identify requests. Specify a unique request ID so
            +   * that if you must retry your request, the server knows to ignore the request
            +   * if it has already been completed. The server guarantees that a request
            +   * doesn't result in creation of duplicate commitments for at least 60
            +   * minutes.
            +   *
            +   * For example, consider a situation where you make an initial request and
            +   * the request times out. If you make the request again with the same request
            +   * ID, the server can check to see whether the original operation
            +   * was received. If it was, the server ignores the second request. This
            +   * behavior prevents clients from mistakenly creating duplicate commitments.
            +   *
            +   * The request ID must be a valid UUID, with the exception that zero UUID is
            +   * not supported (00000000-0000-0000-0000-000000000000).
            +   * 
            + * + * + * string request_id = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + com.google.protobuf.ByteString getRequestIdBytes(); +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Gateway.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Gateway.java new file mode 100644 index 000000000000..6420052f65e6 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Gateway.java @@ -0,0 +1,2560 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +/** + * + * + *
            + * A gateway that can apply specialized traffic processing.
            + * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.Gateway} + */ +@com.google.protobuf.Generated +public final class Gateway extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.Gateway) + GatewayOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Gateway"); + } + + // Use Gateway.newBuilder() to construct. + private Gateway(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Gateway() { + ipRangeReservations_ = java.util.Collections.emptyList(); + capacity_ = 0; + cloudRouters_ = com.google.protobuf.LazyStringArrayList.emptyList(); + sacAttachment_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Gateway_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Gateway_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.Gateway.class, + com.google.cloud.networkconnectivity.v1.Gateway.Builder.class); + } + + /** + * + * + *
            +   * The aggregate processing capacity of this gateway.
            +   * 
            + * + * Protobuf enum {@code google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity} + */ + public enum GatewayCapacity implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
            +     * The gateway capacity is unspecified.
            +     * 
            + * + * GATEWAY_CAPACITY_UNSPECIFIED = 0; + */ + GATEWAY_CAPACITY_UNSPECIFIED(0), + /** + * + * + *
            +     * The gateway has 1 Gbps of aggregate processing capacity
            +     * 
            + * + * CAPACITY_1_GBPS = 5; + */ + CAPACITY_1_GBPS(5), + /** + * + * + *
            +     * The gateway has 10 Gbps of aggregate processing capacity
            +     * 
            + * + * CAPACITY_10_GBPS = 1; + */ + CAPACITY_10_GBPS(1), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GatewayCapacity"); + } + + /** + * + * + *
            +     * The gateway capacity is unspecified.
            +     * 
            + * + * GATEWAY_CAPACITY_UNSPECIFIED = 0; + */ + public static final int GATEWAY_CAPACITY_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
            +     * The gateway has 1 Gbps of aggregate processing capacity
            +     * 
            + * + * CAPACITY_1_GBPS = 5; + */ + public static final int CAPACITY_1_GBPS_VALUE = 5; + + /** + * + * + *
            +     * The gateway has 10 Gbps of aggregate processing capacity
            +     * 
            + * + * CAPACITY_10_GBPS = 1; + */ + public static final int CAPACITY_10_GBPS_VALUE = 1; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static GatewayCapacity valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static GatewayCapacity forNumber(int value) { + switch (value) { + case 0: + return GATEWAY_CAPACITY_UNSPECIFIED; + case 5: + return CAPACITY_1_GBPS; + case 1: + return CAPACITY_10_GBPS; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public GatewayCapacity findValueByNumber(int number) { + return GatewayCapacity.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.Gateway.getDescriptor().getEnumTypes().get(0); + } + + private static final GatewayCapacity[] VALUES = values(); + + public static GatewayCapacity valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private GatewayCapacity(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity) + } + + public interface IpRangeReservationOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
            +     * Required. A block of IP addresses used to allocate supporting
            +     * infrastructure for this gateway. This block must not overlap with subnets
            +     * in any spokes or peer VPC networks that the gateway can communicate with.
            +     * Example: "10.1.2.0/24"
            +     * 
            + * + * string ip_range = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The ipRange. + */ + java.lang.String getIpRange(); + + /** + * + * + *
            +     * Required. A block of IP addresses used to allocate supporting
            +     * infrastructure for this gateway. This block must not overlap with subnets
            +     * in any spokes or peer VPC networks that the gateway can communicate with.
            +     * Example: "10.1.2.0/24"
            +     * 
            + * + * string ip_range = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for ipRange. + */ + com.google.protobuf.ByteString getIpRangeBytes(); + } + + /** + * + * + *
            +   * A list of IP ranges that are reserved for this gateway's internal
            +   * intfrastructure.
            +   * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation} + */ + public static final class IpRangeReservation extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation) + IpRangeReservationOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "IpRangeReservation"); + } + + // Use IpRangeReservation.newBuilder() to construct. + private IpRangeReservation(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private IpRangeReservation() { + ipRange_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Gateway_IpRangeReservation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Gateway_IpRangeReservation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.class, + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder.class); + } + + public static final int IP_RANGE_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object ipRange_ = ""; + + /** + * + * + *
            +     * Required. A block of IP addresses used to allocate supporting
            +     * infrastructure for this gateway. This block must not overlap with subnets
            +     * in any spokes or peer VPC networks that the gateway can communicate with.
            +     * Example: "10.1.2.0/24"
            +     * 
            + * + * string ip_range = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The ipRange. + */ + @java.lang.Override + public java.lang.String getIpRange() { + java.lang.Object ref = ipRange_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + ipRange_ = s; + return s; + } + } + + /** + * + * + *
            +     * Required. A block of IP addresses used to allocate supporting
            +     * infrastructure for this gateway. This block must not overlap with subnets
            +     * in any spokes or peer VPC networks that the gateway can communicate with.
            +     * Example: "10.1.2.0/24"
            +     * 
            + * + * string ip_range = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for ipRange. + */ + @java.lang.Override + public com.google.protobuf.ByteString getIpRangeBytes() { + java.lang.Object ref = ipRange_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + ipRange_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(ipRange_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, ipRange_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(ipRange_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, ipRange_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation other = + (com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation) obj; + + if (!getIpRange().equals(other.getIpRange())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + IP_RANGE_FIELD_NUMBER; + hash = (53 * hash) + getIpRange().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
            +     * A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation) + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservationOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Gateway_IpRangeReservation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Gateway_IpRangeReservation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.class, + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder.class); + } + + // Construct using + // com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + ipRange_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Gateway_IpRangeReservation_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation + getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation build() { + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation buildPartial() { + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation result = + new com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.ipRange_ = ipRange_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation) { + return mergeFrom( + (com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation other) { + if (other + == com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation + .getDefaultInstance()) return this; + if (!other.getIpRange().isEmpty()) { + ipRange_ = other.ipRange_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + ipRange_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object ipRange_ = ""; + + /** + * + * + *
            +       * Required. A block of IP addresses used to allocate supporting
            +       * infrastructure for this gateway. This block must not overlap with subnets
            +       * in any spokes or peer VPC networks that the gateway can communicate with.
            +       * Example: "10.1.2.0/24"
            +       * 
            + * + * string ip_range = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The ipRange. + */ + public java.lang.String getIpRange() { + java.lang.Object ref = ipRange_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + ipRange_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +       * Required. A block of IP addresses used to allocate supporting
            +       * infrastructure for this gateway. This block must not overlap with subnets
            +       * in any spokes or peer VPC networks that the gateway can communicate with.
            +       * Example: "10.1.2.0/24"
            +       * 
            + * + * string ip_range = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for ipRange. + */ + public com.google.protobuf.ByteString getIpRangeBytes() { + java.lang.Object ref = ipRange_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + ipRange_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +       * Required. A block of IP addresses used to allocate supporting
            +       * infrastructure for this gateway. This block must not overlap with subnets
            +       * in any spokes or peer VPC networks that the gateway can communicate with.
            +       * Example: "10.1.2.0/24"
            +       * 
            + * + * string ip_range = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The ipRange to set. + * @return This builder for chaining. + */ + public Builder setIpRange(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ipRange_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
            +       * Required. A block of IP addresses used to allocate supporting
            +       * infrastructure for this gateway. This block must not overlap with subnets
            +       * in any spokes or peer VPC networks that the gateway can communicate with.
            +       * Example: "10.1.2.0/24"
            +       * 
            + * + * string ip_range = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearIpRange() { + ipRange_ = getDefaultInstance().getIpRange(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
            +       * Required. A block of IP addresses used to allocate supporting
            +       * infrastructure for this gateway. This block must not overlap with subnets
            +       * in any spokes or peer VPC networks that the gateway can communicate with.
            +       * Example: "10.1.2.0/24"
            +       * 
            + * + * string ip_range = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for ipRange to set. + * @return This builder for chaining. + */ + public Builder setIpRangeBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ipRange_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation) + private static final com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation(); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public IpRangeReservation parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public static final int IP_RANGE_RESERVATIONS_FIELD_NUMBER = 7; + + @SuppressWarnings("serial") + private java.util.List + ipRangeReservations_; + + /** + * + * + *
            +   * Optional. A list of IP ranges that are reserved for this gateway's internal
            +   * intfrastructure.
            +   * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List + getIpRangeReservationsList() { + return ipRangeReservations_; + } + + /** + * + * + *
            +   * Optional. A list of IP ranges that are reserved for this gateway's internal
            +   * intfrastructure.
            +   * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservationOrBuilder> + getIpRangeReservationsOrBuilderList() { + return ipRangeReservations_; + } + + /** + * + * + *
            +   * Optional. A list of IP ranges that are reserved for this gateway's internal
            +   * intfrastructure.
            +   * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public int getIpRangeReservationsCount() { + return ipRangeReservations_.size(); + } + + /** + * + * + *
            +   * Optional. A list of IP ranges that are reserved for this gateway's internal
            +   * intfrastructure.
            +   * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation getIpRangeReservations( + int index) { + return ipRangeReservations_.get(index); + } + + /** + * + * + *
            +   * Optional. A list of IP ranges that are reserved for this gateway's internal
            +   * intfrastructure.
            +   * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservationOrBuilder + getIpRangeReservationsOrBuilder(int index) { + return ipRangeReservations_.get(index); + } + + public static final int CAPACITY_FIELD_NUMBER = 10; + private int capacity_ = 0; + + /** + * + * + *
            +   * Optional. The aggregate processing capacity of this gateway.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity capacity = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for capacity. + */ + @java.lang.Override + public int getCapacityValue() { + return capacity_; + } + + /** + * + * + *
            +   * Optional. The aggregate processing capacity of this gateway.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity capacity = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The capacity. + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity getCapacity() { + com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity result = + com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity.forNumber(capacity_); + return result == null + ? com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity.UNRECOGNIZED + : result; + } + + public static final int CLOUD_ROUTERS_FIELD_NUMBER = 13; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList cloudRouters_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
            +   * Output only. The list of Cloud Routers that are connected to this gateway.
            +   * Should be in the form:
            +   * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +   * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return A list containing the cloudRouters. + */ + public com.google.protobuf.ProtocolStringList getCloudRoutersList() { + return cloudRouters_; + } + + /** + * + * + *
            +   * Output only. The list of Cloud Routers that are connected to this gateway.
            +   * Should be in the form:
            +   * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +   * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The count of cloudRouters. + */ + public int getCloudRoutersCount() { + return cloudRouters_.size(); + } + + /** + * + * + *
            +   * Output only. The list of Cloud Routers that are connected to this gateway.
            +   * Should be in the form:
            +   * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +   * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param index The index of the element to return. + * @return The cloudRouters at the given index. + */ + public java.lang.String getCloudRouters(int index) { + return cloudRouters_.get(index); + } + + /** + * + * + *
            +   * Output only. The list of Cloud Routers that are connected to this gateway.
            +   * Should be in the form:
            +   * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +   * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param index The index of the value to return. + * @return The bytes of the cloudRouters at the given index. + */ + public com.google.protobuf.ByteString getCloudRoutersBytes(int index) { + return cloudRouters_.getByteString(index); + } + + public static final int SAC_ATTACHMENT_FIELD_NUMBER = 14; + + @SuppressWarnings("serial") + private volatile java.lang.Object sacAttachment_ = ""; + + /** + * + * + *
            +   * Output only. The URI of the connected SACAttachment.
            +   * Should be in the form:
            +   * projects/{project}/locations/{location}/sacAttachments/{sac_attachment}
            +   * 
            + * + * + * string sac_attachment = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The sacAttachment. + */ + @java.lang.Override + public java.lang.String getSacAttachment() { + java.lang.Object ref = sacAttachment_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sacAttachment_ = s; + return s; + } + } + + /** + * + * + *
            +   * Output only. The URI of the connected SACAttachment.
            +   * Should be in the form:
            +   * projects/{project}/locations/{location}/sacAttachments/{sac_attachment}
            +   * 
            + * + * + * string sac_attachment = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for sacAttachment. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSacAttachmentBytes() { + java.lang.Object ref = sacAttachment_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sacAttachment_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < ipRangeReservations_.size(); i++) { + output.writeMessage(7, ipRangeReservations_.get(i)); + } + if (capacity_ + != com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity + .GATEWAY_CAPACITY_UNSPECIFIED + .getNumber()) { + output.writeEnum(10, capacity_); + } + for (int i = 0; i < cloudRouters_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 13, cloudRouters_.getRaw(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sacAttachment_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 14, sacAttachment_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < ipRangeReservations_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(7, ipRangeReservations_.get(i)); + } + if (capacity_ + != com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity + .GATEWAY_CAPACITY_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(10, capacity_); + } + { + int dataSize = 0; + for (int i = 0; i < cloudRouters_.size(); i++) { + dataSize += computeStringSizeNoTag(cloudRouters_.getRaw(i)); + } + size += dataSize; + size += 1 * getCloudRoutersList().size(); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sacAttachment_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(14, sacAttachment_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.networkconnectivity.v1.Gateway)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.Gateway other = + (com.google.cloud.networkconnectivity.v1.Gateway) obj; + + if (!getIpRangeReservationsList().equals(other.getIpRangeReservationsList())) return false; + if (capacity_ != other.capacity_) return false; + if (!getCloudRoutersList().equals(other.getCloudRoutersList())) return false; + if (!getSacAttachment().equals(other.getSacAttachment())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getIpRangeReservationsCount() > 0) { + hash = (37 * hash) + IP_RANGE_RESERVATIONS_FIELD_NUMBER; + hash = (53 * hash) + getIpRangeReservationsList().hashCode(); + } + hash = (37 * hash) + CAPACITY_FIELD_NUMBER; + hash = (53 * hash) + capacity_; + if (getCloudRoutersCount() > 0) { + hash = (37 * hash) + CLOUD_ROUTERS_FIELD_NUMBER; + hash = (53 * hash) + getCloudRoutersList().hashCode(); + } + hash = (37 * hash) + SAC_ATTACHMENT_FIELD_NUMBER; + hash = (53 * hash) + getSacAttachment().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.networkconnectivity.v1.Gateway prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
            +   * A gateway that can apply specialized traffic processing.
            +   * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.Gateway} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.Gateway) + com.google.cloud.networkconnectivity.v1.GatewayOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Gateway_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Gateway_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.Gateway.class, + com.google.cloud.networkconnectivity.v1.Gateway.Builder.class); + } + + // Construct using com.google.cloud.networkconnectivity.v1.Gateway.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (ipRangeReservationsBuilder_ == null) { + ipRangeReservations_ = java.util.Collections.emptyList(); + } else { + ipRangeReservations_ = null; + ipRangeReservationsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + capacity_ = 0; + cloudRouters_ = com.google.protobuf.LazyStringArrayList.emptyList(); + sacAttachment_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Gateway_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.Gateway.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway build() { + com.google.cloud.networkconnectivity.v1.Gateway result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway buildPartial() { + com.google.cloud.networkconnectivity.v1.Gateway result = + new com.google.cloud.networkconnectivity.v1.Gateway(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.networkconnectivity.v1.Gateway result) { + if (ipRangeReservationsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + ipRangeReservations_ = java.util.Collections.unmodifiableList(ipRangeReservations_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.ipRangeReservations_ = ipRangeReservations_; + } else { + result.ipRangeReservations_ = ipRangeReservationsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.networkconnectivity.v1.Gateway result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.capacity_ = capacity_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + cloudRouters_.makeImmutable(); + result.cloudRouters_ = cloudRouters_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.sacAttachment_ = sacAttachment_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.networkconnectivity.v1.Gateway) { + return mergeFrom((com.google.cloud.networkconnectivity.v1.Gateway) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.Gateway other) { + if (other == com.google.cloud.networkconnectivity.v1.Gateway.getDefaultInstance()) + return this; + if (ipRangeReservationsBuilder_ == null) { + if (!other.ipRangeReservations_.isEmpty()) { + if (ipRangeReservations_.isEmpty()) { + ipRangeReservations_ = other.ipRangeReservations_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureIpRangeReservationsIsMutable(); + ipRangeReservations_.addAll(other.ipRangeReservations_); + } + onChanged(); + } + } else { + if (!other.ipRangeReservations_.isEmpty()) { + if (ipRangeReservationsBuilder_.isEmpty()) { + ipRangeReservationsBuilder_.dispose(); + ipRangeReservationsBuilder_ = null; + ipRangeReservations_ = other.ipRangeReservations_; + bitField0_ = (bitField0_ & ~0x00000001); + ipRangeReservationsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetIpRangeReservationsFieldBuilder() + : null; + } else { + ipRangeReservationsBuilder_.addAllMessages(other.ipRangeReservations_); + } + } + } + if (other.capacity_ != 0) { + setCapacityValue(other.getCapacityValue()); + } + if (!other.cloudRouters_.isEmpty()) { + if (cloudRouters_.isEmpty()) { + cloudRouters_ = other.cloudRouters_; + bitField0_ |= 0x00000004; + } else { + ensureCloudRoutersIsMutable(); + cloudRouters_.addAll(other.cloudRouters_); + } + onChanged(); + } + if (!other.getSacAttachment().isEmpty()) { + sacAttachment_ = other.sacAttachment_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 58: + { + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation m = + input.readMessage( + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.parser(), + extensionRegistry); + if (ipRangeReservationsBuilder_ == null) { + ensureIpRangeReservationsIsMutable(); + ipRangeReservations_.add(m); + } else { + ipRangeReservationsBuilder_.addMessage(m); + } + break; + } // case 58 + case 80: + { + capacity_ = input.readEnum(); + bitField0_ |= 0x00000002; + break; + } // case 80 + case 106: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureCloudRoutersIsMutable(); + cloudRouters_.add(s); + break; + } // case 106 + case 114: + { + sacAttachment_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 114 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List + ipRangeReservations_ = java.util.Collections.emptyList(); + + private void ensureIpRangeReservationsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + ipRangeReservations_ = + new java.util.ArrayList< + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation>( + ipRangeReservations_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation, + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder, + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservationOrBuilder> + ipRangeReservationsBuilder_; + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List + getIpRangeReservationsList() { + if (ipRangeReservationsBuilder_ == null) { + return java.util.Collections.unmodifiableList(ipRangeReservations_); + } else { + return ipRangeReservationsBuilder_.getMessageList(); + } + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public int getIpRangeReservationsCount() { + if (ipRangeReservationsBuilder_ == null) { + return ipRangeReservations_.size(); + } else { + return ipRangeReservationsBuilder_.getCount(); + } + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation + getIpRangeReservations(int index) { + if (ipRangeReservationsBuilder_ == null) { + return ipRangeReservations_.get(index); + } else { + return ipRangeReservationsBuilder_.getMessage(index); + } + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setIpRangeReservations( + int index, com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation value) { + if (ipRangeReservationsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureIpRangeReservationsIsMutable(); + ipRangeReservations_.set(index, value); + onChanged(); + } else { + ipRangeReservationsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setIpRangeReservations( + int index, + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder + builderForValue) { + if (ipRangeReservationsBuilder_ == null) { + ensureIpRangeReservationsIsMutable(); + ipRangeReservations_.set(index, builderForValue.build()); + onChanged(); + } else { + ipRangeReservationsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addIpRangeReservations( + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation value) { + if (ipRangeReservationsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureIpRangeReservationsIsMutable(); + ipRangeReservations_.add(value); + onChanged(); + } else { + ipRangeReservationsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addIpRangeReservations( + int index, com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation value) { + if (ipRangeReservationsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureIpRangeReservationsIsMutable(); + ipRangeReservations_.add(index, value); + onChanged(); + } else { + ipRangeReservationsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addIpRangeReservations( + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder + builderForValue) { + if (ipRangeReservationsBuilder_ == null) { + ensureIpRangeReservationsIsMutable(); + ipRangeReservations_.add(builderForValue.build()); + onChanged(); + } else { + ipRangeReservationsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addIpRangeReservations( + int index, + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder + builderForValue) { + if (ipRangeReservationsBuilder_ == null) { + ensureIpRangeReservationsIsMutable(); + ipRangeReservations_.add(index, builderForValue.build()); + onChanged(); + } else { + ipRangeReservationsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addAllIpRangeReservations( + java.lang.Iterable< + ? extends com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation> + values) { + if (ipRangeReservationsBuilder_ == null) { + ensureIpRangeReservationsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, ipRangeReservations_); + onChanged(); + } else { + ipRangeReservationsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearIpRangeReservations() { + if (ipRangeReservationsBuilder_ == null) { + ipRangeReservations_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + ipRangeReservationsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeIpRangeReservations(int index) { + if (ipRangeReservationsBuilder_ == null) { + ensureIpRangeReservationsIsMutable(); + ipRangeReservations_.remove(index); + onChanged(); + } else { + ipRangeReservationsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder + getIpRangeReservationsBuilder(int index) { + return internalGetIpRangeReservationsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservationOrBuilder + getIpRangeReservationsOrBuilder(int index) { + if (ipRangeReservationsBuilder_ == null) { + return ipRangeReservations_.get(index); + } else { + return ipRangeReservationsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List< + ? extends com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservationOrBuilder> + getIpRangeReservationsOrBuilderList() { + if (ipRangeReservationsBuilder_ != null) { + return ipRangeReservationsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(ipRangeReservations_); + } + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder + addIpRangeReservationsBuilder() { + return internalGetIpRangeReservationsFieldBuilder() + .addBuilder( + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation + .getDefaultInstance()); + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder + addIpRangeReservationsBuilder(int index) { + return internalGetIpRangeReservationsFieldBuilder() + .addBuilder( + index, + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation + .getDefaultInstance()); + } + + /** + * + * + *
            +     * Optional. A list of IP ranges that are reserved for this gateway's internal
            +     * intfrastructure.
            +     * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List< + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder> + getIpRangeReservationsBuilderList() { + return internalGetIpRangeReservationsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation, + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder, + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservationOrBuilder> + internalGetIpRangeReservationsFieldBuilder() { + if (ipRangeReservationsBuilder_ == null) { + ipRangeReservationsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation, + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation.Builder, + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservationOrBuilder>( + ipRangeReservations_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + ipRangeReservations_ = null; + } + return ipRangeReservationsBuilder_; + } + + private int capacity_ = 0; + + /** + * + * + *
            +     * Optional. The aggregate processing capacity of this gateway.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity capacity = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for capacity. + */ + @java.lang.Override + public int getCapacityValue() { + return capacity_; + } + + /** + * + * + *
            +     * Optional. The aggregate processing capacity of this gateway.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity capacity = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for capacity to set. + * @return This builder for chaining. + */ + public Builder setCapacityValue(int value) { + capacity_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. The aggregate processing capacity of this gateway.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity capacity = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The capacity. + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity getCapacity() { + com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity result = + com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity.forNumber(capacity_); + return result == null + ? com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity.UNRECOGNIZED + : result; + } + + /** + * + * + *
            +     * Optional. The aggregate processing capacity of this gateway.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity capacity = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The capacity to set. + * @return This builder for chaining. + */ + public Builder setCapacity( + com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000002; + capacity_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. The aggregate processing capacity of this gateway.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity capacity = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearCapacity() { + bitField0_ = (bitField0_ & ~0x00000002); + capacity_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList cloudRouters_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureCloudRoutersIsMutable() { + if (!cloudRouters_.isModifiable()) { + cloudRouters_ = new com.google.protobuf.LazyStringArrayList(cloudRouters_); + } + bitField0_ |= 0x00000004; + } + + /** + * + * + *
            +     * Output only. The list of Cloud Routers that are connected to this gateway.
            +     * Should be in the form:
            +     * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +     * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return A list containing the cloudRouters. + */ + public com.google.protobuf.ProtocolStringList getCloudRoutersList() { + cloudRouters_.makeImmutable(); + return cloudRouters_; + } + + /** + * + * + *
            +     * Output only. The list of Cloud Routers that are connected to this gateway.
            +     * Should be in the form:
            +     * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +     * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The count of cloudRouters. + */ + public int getCloudRoutersCount() { + return cloudRouters_.size(); + } + + /** + * + * + *
            +     * Output only. The list of Cloud Routers that are connected to this gateway.
            +     * Should be in the form:
            +     * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +     * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param index The index of the element to return. + * @return The cloudRouters at the given index. + */ + public java.lang.String getCloudRouters(int index) { + return cloudRouters_.get(index); + } + + /** + * + * + *
            +     * Output only. The list of Cloud Routers that are connected to this gateway.
            +     * Should be in the form:
            +     * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +     * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param index The index of the value to return. + * @return The bytes of the cloudRouters at the given index. + */ + public com.google.protobuf.ByteString getCloudRoutersBytes(int index) { + return cloudRouters_.getByteString(index); + } + + /** + * + * + *
            +     * Output only. The list of Cloud Routers that are connected to this gateway.
            +     * Should be in the form:
            +     * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +     * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param index The index to set the value at. + * @param value The cloudRouters to set. + * @return This builder for chaining. + */ + public Builder setCloudRouters(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureCloudRoutersIsMutable(); + cloudRouters_.set(index, value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The list of Cloud Routers that are connected to this gateway.
            +     * Should be in the form:
            +     * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +     * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The cloudRouters to add. + * @return This builder for chaining. + */ + public Builder addCloudRouters(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureCloudRoutersIsMutable(); + cloudRouters_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The list of Cloud Routers that are connected to this gateway.
            +     * Should be in the form:
            +     * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +     * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param values The cloudRouters to add. + * @return This builder for chaining. + */ + public Builder addAllCloudRouters(java.lang.Iterable values) { + ensureCloudRoutersIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, cloudRouters_); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The list of Cloud Routers that are connected to this gateway.
            +     * Should be in the form:
            +     * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +     * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearCloudRouters() { + cloudRouters_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + ; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The list of Cloud Routers that are connected to this gateway.
            +     * Should be in the form:
            +     * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +     * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes of the cloudRouters to add. + * @return This builder for chaining. + */ + public Builder addCloudRoutersBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureCloudRoutersIsMutable(); + cloudRouters_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object sacAttachment_ = ""; + + /** + * + * + *
            +     * Output only. The URI of the connected SACAttachment.
            +     * Should be in the form:
            +     * projects/{project}/locations/{location}/sacAttachments/{sac_attachment}
            +     * 
            + * + * + * string sac_attachment = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The sacAttachment. + */ + public java.lang.String getSacAttachment() { + java.lang.Object ref = sacAttachment_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sacAttachment_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * Output only. The URI of the connected SACAttachment.
            +     * Should be in the form:
            +     * projects/{project}/locations/{location}/sacAttachments/{sac_attachment}
            +     * 
            + * + * + * string sac_attachment = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for sacAttachment. + */ + public com.google.protobuf.ByteString getSacAttachmentBytes() { + java.lang.Object ref = sacAttachment_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sacAttachment_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * Output only. The URI of the connected SACAttachment.
            +     * Should be in the form:
            +     * projects/{project}/locations/{location}/sacAttachments/{sac_attachment}
            +     * 
            + * + * + * string sac_attachment = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The sacAttachment to set. + * @return This builder for chaining. + */ + public Builder setSacAttachment(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sacAttachment_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The URI of the connected SACAttachment.
            +     * Should be in the form:
            +     * projects/{project}/locations/{location}/sacAttachments/{sac_attachment}
            +     * 
            + * + * + * string sac_attachment = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearSacAttachment() { + sacAttachment_ = getDefaultInstance().getSacAttachment(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The URI of the connected SACAttachment.
            +     * Should be in the form:
            +     * projects/{project}/locations/{location}/sacAttachments/{sac_attachment}
            +     * 
            + * + * + * string sac_attachment = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for sacAttachment to set. + * @return This builder for chaining. + */ + public Builder setSacAttachmentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sacAttachment_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.Gateway) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.Gateway) + private static final com.google.cloud.networkconnectivity.v1.Gateway DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.networkconnectivity.v1.Gateway(); + } + + public static com.google.cloud.networkconnectivity.v1.Gateway getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Gateway parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayAdvertisedRoute.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayAdvertisedRoute.java new file mode 100644 index 000000000000..560e45e7fcf8 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayAdvertisedRoute.java @@ -0,0 +1,2861 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +/** + * + * + *
            + * A gateway advertised route is a route that a gateway spoke advertises
            + * somewhere.
            + * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute} + */ +@com.google.protobuf.Generated +public final class GatewayAdvertisedRoute extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute) + GatewayAdvertisedRouteOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GatewayAdvertisedRoute"); + } + + // Use GatewayAdvertisedRoute.newBuilder() to construct. + private GatewayAdvertisedRoute(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GatewayAdvertisedRoute() { + name_ = ""; + description_ = ""; + uniqueId_ = ""; + state_ = 0; + ipRange_ = ""; + recipient_ = 0; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_GatewayAdvertisedRoute_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 4: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_GatewayAdvertisedRoute_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.class, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder.class); + } + + /** + * + * + *
            +   * The recipient of an advertised route.
            +   * 
            + * + * Protobuf enum {@code google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient} + */ + public enum Recipient implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
            +     * No recipient specified. By default routes are advertised to the hub.
            +     * 
            + * + * RECIPIENT_UNSPECIFIED = 0; + */ + RECIPIENT_UNSPECIFIED(0), + /** + * + * + *
            +     * Advertises a route toward the hub. Other spokes reachable from this spoke
            +     * will receive the route.
            +     * 
            + * + * ADVERTISE_TO_HUB = 1; + */ + ADVERTISE_TO_HUB(1), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Recipient"); + } + + /** + * + * + *
            +     * No recipient specified. By default routes are advertised to the hub.
            +     * 
            + * + * RECIPIENT_UNSPECIFIED = 0; + */ + public static final int RECIPIENT_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
            +     * Advertises a route toward the hub. Other spokes reachable from this spoke
            +     * will receive the route.
            +     * 
            + * + * ADVERTISE_TO_HUB = 1; + */ + public static final int ADVERTISE_TO_HUB_VALUE = 1; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Recipient valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static Recipient forNumber(int value) { + switch (value) { + case 0: + return RECIPIENT_UNSPECIFIED; + case 1: + return ADVERTISE_TO_HUB; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Recipient findValueByNumber(int number) { + return Recipient.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Recipient[] VALUES = values(); + + public static Recipient valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Recipient(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient) + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
            +   * Identifier. The name of the gateway advertised route. Route names must be
            +   * unique and use the following form:
            +   * `projects/{project_number}/locations/{region}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route_id}`
            +   * 
            + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
            +   * Identifier. The name of the gateway advertised route. Route names must be
            +   * unique and use the following form:
            +   * `projects/{project_number}/locations/{region}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route_id}`
            +   * 
            + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was created.
            +   * 
            + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was created.
            +   * 
            + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was created.
            +   * 
            + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 3; + private com.google.protobuf.Timestamp updateTime_; + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was last updated.
            +   * 
            + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was last updated.
            +   * 
            + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was last updated.
            +   * 
            + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + public static final int LABELS_FIELD_NUMBER = 4; + + private static final class LabelsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_GatewayAdvertisedRoute_LabelsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + + @SuppressWarnings("serial") + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + + /** + * + * + *
            +   * Optional labels in key-value pair format. For more information about
            +   * labels, see [Requirements for
            +   * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +   * 
            + * + * map<string, string> labels = 4; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetLabels().getMap().containsKey(key); + } + + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + + /** + * + * + *
            +   * Optional labels in key-value pair format. For more information about
            +   * labels, see [Requirements for
            +   * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +   * 
            + * + * map<string, string> labels = 4; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
            +   * Optional labels in key-value pair format. For more information about
            +   * labels, see [Requirements for
            +   * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +   * 
            + * + * map<string, string> labels = 4; + */ + @java.lang.Override + public /* nullable */ java.lang.String getLabelsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
            +   * Optional labels in key-value pair format. For more information about
            +   * labels, see [Requirements for
            +   * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +   * 
            + * + * map<string, string> labels = 4; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public static final int DESCRIPTION_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object description_ = ""; + + /** + * + * + *
            +   * An optional description of the gateway advertised route.
            +   * 
            + * + * string description = 5; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + + /** + * + * + *
            +   * An optional description of the gateway advertised route.
            +   * 
            + * + * string description = 5; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UNIQUE_ID_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private volatile java.lang.Object uniqueId_ = ""; + + /** + * + * + *
            +   * Output only. The Google-generated UUID for the gateway advertised route.
            +   * This value is unique across all gateway advertised route resources. If a
            +   * gateway advertised route is deleted and another with the same name is
            +   * created, the new route is assigned a different `unique_id`.
            +   * 
            + * + * string unique_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uniqueId. + */ + @java.lang.Override + public java.lang.String getUniqueId() { + java.lang.Object ref = uniqueId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uniqueId_ = s; + return s; + } + } + + /** + * + * + *
            +   * Output only. The Google-generated UUID for the gateway advertised route.
            +   * This value is unique across all gateway advertised route resources. If a
            +   * gateway advertised route is deleted and another with the same name is
            +   * created, the new route is assigned a different `unique_id`.
            +   * 
            + * + * string unique_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uniqueId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUniqueIdBytes() { + java.lang.Object ref = uniqueId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uniqueId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STATE_FIELD_NUMBER = 7; + private int state_ = 0; + + /** + * + * + *
            +   * Output only. The current lifecycle state of this gateway advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
            +   * Output only. The current lifecycle state of this gateway advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.State getState() { + com.google.cloud.networkconnectivity.v1.State result = + com.google.cloud.networkconnectivity.v1.State.forNumber(state_); + return result == null ? com.google.cloud.networkconnectivity.v1.State.UNRECOGNIZED : result; + } + + public static final int IP_RANGE_FIELD_NUMBER = 8; + + @SuppressWarnings("serial") + private volatile java.lang.Object ipRange_ = ""; + + /** + * + * + *
            +   * Immutable. This route's advertised IP address range. Must be a valid
            +   * CIDR-formatted prefix. If an IP address is provided without a subnet mask,
            +   * it is interpreted as, for IPv4, a `/32` singular IP address range, and, for
            +   * IPv6,
            +   * `/128`.
            +   * 
            + * + * string ip_range = 8 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @return The ipRange. + */ + @java.lang.Override + public java.lang.String getIpRange() { + java.lang.Object ref = ipRange_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + ipRange_ = s; + return s; + } + } + + /** + * + * + *
            +   * Immutable. This route's advertised IP address range. Must be a valid
            +   * CIDR-formatted prefix. If an IP address is provided without a subnet mask,
            +   * it is interpreted as, for IPv4, a `/32` singular IP address range, and, for
            +   * IPv6,
            +   * `/128`.
            +   * 
            + * + * string ip_range = 8 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @return The bytes for ipRange. + */ + @java.lang.Override + public com.google.protobuf.ByteString getIpRangeBytes() { + java.lang.Object ref = ipRange_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + ipRange_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PRIORITY_FIELD_NUMBER = 9; + private int priority_ = 0; + + /** + * + * + *
            +   * Optional. The priority of this advertised route. You can choose a value
            +   * from `0` to `65335`. If you don't provide a value, Google Cloud assigns a
            +   * priority of `100` to the ranges.
            +   * 
            + * + * optional int32 priority = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the priority field is set. + */ + @java.lang.Override + public boolean hasPriority() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
            +   * Optional. The priority of this advertised route. You can choose a value
            +   * from `0` to `65335`. If you don't provide a value, Google Cloud assigns a
            +   * priority of `100` to the ranges.
            +   * 
            + * + * optional int32 priority = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The priority. + */ + @java.lang.Override + public int getPriority() { + return priority_; + } + + public static final int RECIPIENT_FIELD_NUMBER = 10; + private int recipient_ = 0; + + /** + * + * + *
            +   * Optional. The recipient of this advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient recipient = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for recipient. + */ + @java.lang.Override + public int getRecipientValue() { + return recipient_; + } + + /** + * + * + *
            +   * Optional. The recipient of this advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient recipient = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The recipient. + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient getRecipient() { + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient result = + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient.forNumber( + recipient_); + return result == null + ? com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(2, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(3, getUpdateTime()); + } + com.google.protobuf.GeneratedMessage.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 4); + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, description_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uniqueId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, uniqueId_); + } + if (state_ != com.google.cloud.networkconnectivity.v1.State.STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(7, state_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(ipRange_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 8, ipRange_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeInt32(9, priority_); + } + if (recipient_ + != com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient + .RECIPIENT_UNSPECIFIED + .getNumber()) { + output.writeEnum(10, recipient_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getUpdateTime()); + } + for (java.util.Map.Entry entry : + internalGetLabels().getMap().entrySet()) { + com.google.protobuf.MapEntry labels__ = + LabelsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, labels__); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, description_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uniqueId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(6, uniqueId_); + } + if (state_ != com.google.cloud.networkconnectivity.v1.State.STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, state_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(ipRange_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(8, ipRange_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(9, priority_); + } + if (recipient_ + != com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient + .RECIPIENT_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(10, recipient_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute other = + (com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute) obj; + + if (!getName().equals(other.getName())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!internalGetLabels().equals(other.internalGetLabels())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (!getUniqueId().equals(other.getUniqueId())) return false; + if (state_ != other.state_) return false; + if (!getIpRange().equals(other.getIpRange())) return false; + if (hasPriority() != other.hasPriority()) return false; + if (hasPriority()) { + if (getPriority() != other.getPriority()) return false; + } + if (recipient_ != other.recipient_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + if (!internalGetLabels().getMap().isEmpty()) { + hash = (37 * hash) + LABELS_FIELD_NUMBER; + hash = (53 * hash) + internalGetLabels().hashCode(); + } + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + hash = (37 * hash) + UNIQUE_ID_FIELD_NUMBER; + hash = (53 * hash) + getUniqueId().hashCode(); + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + hash = (37 * hash) + IP_RANGE_FIELD_NUMBER; + hash = (53 * hash) + getIpRange().hashCode(); + if (hasPriority()) { + hash = (37 * hash) + PRIORITY_FIELD_NUMBER; + hash = (53 * hash) + getPriority(); + } + hash = (37 * hash) + RECIPIENT_FIELD_NUMBER; + hash = (53 * hash) + recipient_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
            +   * A gateway advertised route is a route that a gateway spoke advertises
            +   * somewhere.
            +   * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute) + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_GatewayAdvertisedRoute_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 4: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( + int number) { + switch (number) { + case 4: + return internalGetMutableLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_GatewayAdvertisedRoute_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.class, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder.class); + } + + // Construct using com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetCreateTimeFieldBuilder(); + internalGetUpdateTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + internalGetMutableLabels().clear(); + description_ = ""; + uniqueId_ = ""; + state_ = 0; + ipRange_ = ""; + priority_ = 0; + recipient_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_GatewayAdvertisedRoute_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute build() { + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute buildPartial() { + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute result = + new com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.labels_ = internalGetLabels(); + result.labels_.makeImmutable(); + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.description_ = description_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.uniqueId_ = uniqueId_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.state_ = state_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.ipRange_ = ipRange_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.priority_ = priority_; + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.recipient_ = recipient_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute) { + return mergeFrom((com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute other) { + if (other + == com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); + bitField0_ |= 0x00000008; + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + bitField0_ |= 0x00000010; + onChanged(); + } + if (!other.getUniqueId().isEmpty()) { + uniqueId_ = other.uniqueId_; + bitField0_ |= 0x00000020; + onChanged(); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (!other.getIpRange().isEmpty()) { + ipRange_ = other.ipRange_; + bitField0_ |= 0x00000080; + onChanged(); + } + if (other.hasPriority()) { + setPriority(other.getPriority()); + } + if (other.recipient_ != 0) { + setRecipientValue(other.getRecipientValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + com.google.protobuf.MapEntry labels__ = + input.readMessage( + LabelsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableLabels() + .getMutableMap() + .put(labels__.getKey(), labels__.getValue()); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + uniqueId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000020; + break; + } // case 50 + case 56: + { + state_ = input.readEnum(); + bitField0_ |= 0x00000040; + break; + } // case 56 + case 66: + { + ipRange_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000080; + break; + } // case 66 + case 72: + { + priority_ = input.readInt32(); + bitField0_ |= 0x00000100; + break; + } // case 72 + case 80: + { + recipient_ = input.readEnum(); + bitField0_ |= 0x00000200; + break; + } // case 80 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
            +     * Identifier. The name of the gateway advertised route. Route names must be
            +     * unique and use the following form:
            +     * `projects/{project_number}/locations/{region}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route_id}`
            +     * 
            + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * Identifier. The name of the gateway advertised route. Route names must be
            +     * unique and use the following form:
            +     * `projects/{project_number}/locations/{region}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route_id}`
            +     * 
            + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * Identifier. The name of the gateway advertised route. Route names must be
            +     * unique and use the following form:
            +     * `projects/{project_number}/locations/{region}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route_id}`
            +     * 
            + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Identifier. The name of the gateway advertised route. Route names must be
            +     * unique and use the following form:
            +     * `projects/{project_number}/locations/{region}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route_id}`
            +     * 
            + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Identifier. The name of the gateway advertised route. Route names must be
            +     * unique and use the following form:
            +     * `projects/{project_number}/locations/{region}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route_id}`
            +     * 
            + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was created.
            +     * 
            + * + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was created.
            +     * 
            + * + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was created.
            +     * 
            + * + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was created.
            +     * 
            + * + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was created.
            +     * 
            + * + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was created.
            +     * 
            + * + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000002); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was created.
            +     * 
            + * + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was created.
            +     * 
            + * + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was created.
            +     * 
            + * + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was last updated.
            +     * 
            + * + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was last updated.
            +     * 
            + * + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was last updated.
            +     * 
            + * + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + } else { + updateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was last updated.
            +     * 
            + * + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was last updated.
            +     * 
            + * + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && updateTime_ != null + && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getUpdateTimeBuilder().mergeFrom(value); + } else { + updateTime_ = value; + } + } else { + updateTimeBuilder_.mergeFrom(value); + } + if (updateTime_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was last updated.
            +     * 
            + * + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000004); + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was last updated.
            +     * 
            + * + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was last updated.
            +     * 
            + * + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + + /** + * + * + *
            +     * Output only. The time the gateway advertised route was last updated.
            +     * 
            + * + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + private com.google.protobuf.MapField + internalGetMutableLabels() { + if (labels_ == null) { + labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); + } + if (!labels_.isMutable()) { + labels_ = labels_.copy(); + } + bitField0_ |= 0x00000008; + onChanged(); + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + + /** + * + * + *
            +     * Optional labels in key-value pair format. For more information about
            +     * labels, see [Requirements for
            +     * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +     * 
            + * + * map<string, string> labels = 4; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetLabels().getMap().containsKey(key); + } + + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + + /** + * + * + *
            +     * Optional labels in key-value pair format. For more information about
            +     * labels, see [Requirements for
            +     * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +     * 
            + * + * map<string, string> labels = 4; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
            +     * Optional labels in key-value pair format. For more information about
            +     * labels, see [Requirements for
            +     * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +     * 
            + * + * map<string, string> labels = 4; + */ + @java.lang.Override + public /* nullable */ java.lang.String getLabelsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
            +     * Optional labels in key-value pair format. For more information about
            +     * labels, see [Requirements for
            +     * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +     * 
            + * + * map<string, string> labels = 4; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearLabels() { + bitField0_ = (bitField0_ & ~0x00000008); + internalGetMutableLabels().getMutableMap().clear(); + return this; + } + + /** + * + * + *
            +     * Optional labels in key-value pair format. For more information about
            +     * labels, see [Requirements for
            +     * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +     * 
            + * + * map<string, string> labels = 4; + */ + public Builder removeLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableLabels().getMutableMap().remove(key); + return this; + } + + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableLabels() { + bitField0_ |= 0x00000008; + return internalGetMutableLabels().getMutableMap(); + } + + /** + * + * + *
            +     * Optional labels in key-value pair format. For more information about
            +     * labels, see [Requirements for
            +     * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +     * 
            + * + * map<string, string> labels = 4; + */ + public Builder putLabels(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + internalGetMutableLabels().getMutableMap().put(key, value); + bitField0_ |= 0x00000008; + return this; + } + + /** + * + * + *
            +     * Optional labels in key-value pair format. For more information about
            +     * labels, see [Requirements for
            +     * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +     * 
            + * + * map<string, string> labels = 4; + */ + public Builder putAllLabels(java.util.Map values) { + internalGetMutableLabels().getMutableMap().putAll(values); + bitField0_ |= 0x00000008; + return this; + } + + private java.lang.Object description_ = ""; + + /** + * + * + *
            +     * An optional description of the gateway advertised route.
            +     * 
            + * + * string description = 5; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * An optional description of the gateway advertised route.
            +     * 
            + * + * string description = 5; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * An optional description of the gateway advertised route.
            +     * 
            + * + * string description = 5; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + description_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
            +     * An optional description of the gateway advertised route.
            +     * 
            + * + * string description = 5; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + description_ = getDefaultInstance().getDescription(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
            +     * An optional description of the gateway advertised route.
            +     * 
            + * + * string description = 5; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private java.lang.Object uniqueId_ = ""; + + /** + * + * + *
            +     * Output only. The Google-generated UUID for the gateway advertised route.
            +     * This value is unique across all gateway advertised route resources. If a
            +     * gateway advertised route is deleted and another with the same name is
            +     * created, the new route is assigned a different `unique_id`.
            +     * 
            + * + * string unique_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uniqueId. + */ + public java.lang.String getUniqueId() { + java.lang.Object ref = uniqueId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uniqueId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * Output only. The Google-generated UUID for the gateway advertised route.
            +     * This value is unique across all gateway advertised route resources. If a
            +     * gateway advertised route is deleted and another with the same name is
            +     * created, the new route is assigned a different `unique_id`.
            +     * 
            + * + * string unique_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uniqueId. + */ + public com.google.protobuf.ByteString getUniqueIdBytes() { + java.lang.Object ref = uniqueId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uniqueId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * Output only. The Google-generated UUID for the gateway advertised route.
            +     * This value is unique across all gateway advertised route resources. If a
            +     * gateway advertised route is deleted and another with the same name is
            +     * created, the new route is assigned a different `unique_id`.
            +     * 
            + * + * string unique_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The uniqueId to set. + * @return This builder for chaining. + */ + public Builder setUniqueId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + uniqueId_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The Google-generated UUID for the gateway advertised route.
            +     * This value is unique across all gateway advertised route resources. If a
            +     * gateway advertised route is deleted and another with the same name is
            +     * created, the new route is assigned a different `unique_id`.
            +     * 
            + * + * string unique_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearUniqueId() { + uniqueId_ = getDefaultInstance().getUniqueId(); + bitField0_ = (bitField0_ & ~0x00000020); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The Google-generated UUID for the gateway advertised route.
            +     * This value is unique across all gateway advertised route resources. If a
            +     * gateway advertised route is deleted and another with the same name is
            +     * created, the new route is assigned a different `unique_id`.
            +     * 
            + * + * string unique_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for uniqueId to set. + * @return This builder for chaining. + */ + public Builder setUniqueIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + uniqueId_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + private int state_ = 0; + + /** + * + * + *
            +     * Output only. The current lifecycle state of this gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
            +     * Output only. The current lifecycle state of this gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The current lifecycle state of this gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.State getState() { + com.google.cloud.networkconnectivity.v1.State result = + com.google.cloud.networkconnectivity.v1.State.forNumber(state_); + return result == null ? com.google.cloud.networkconnectivity.v1.State.UNRECOGNIZED : result; + } + + /** + * + * + *
            +     * Output only. The current lifecycle state of this gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.networkconnectivity.v1.State value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000040; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Output only. The current lifecycle state of this gateway advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000040); + state_ = 0; + onChanged(); + return this; + } + + private java.lang.Object ipRange_ = ""; + + /** + * + * + *
            +     * Immutable. This route's advertised IP address range. Must be a valid
            +     * CIDR-formatted prefix. If an IP address is provided without a subnet mask,
            +     * it is interpreted as, for IPv4, a `/32` singular IP address range, and, for
            +     * IPv6,
            +     * `/128`.
            +     * 
            + * + * string ip_range = 8 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @return The ipRange. + */ + public java.lang.String getIpRange() { + java.lang.Object ref = ipRange_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + ipRange_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * Immutable. This route's advertised IP address range. Must be a valid
            +     * CIDR-formatted prefix. If an IP address is provided without a subnet mask,
            +     * it is interpreted as, for IPv4, a `/32` singular IP address range, and, for
            +     * IPv6,
            +     * `/128`.
            +     * 
            + * + * string ip_range = 8 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @return The bytes for ipRange. + */ + public com.google.protobuf.ByteString getIpRangeBytes() { + java.lang.Object ref = ipRange_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + ipRange_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * Immutable. This route's advertised IP address range. Must be a valid
            +     * CIDR-formatted prefix. If an IP address is provided without a subnet mask,
            +     * it is interpreted as, for IPv4, a `/32` singular IP address range, and, for
            +     * IPv6,
            +     * `/128`.
            +     * 
            + * + * string ip_range = 8 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @param value The ipRange to set. + * @return This builder for chaining. + */ + public Builder setIpRange(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ipRange_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Immutable. This route's advertised IP address range. Must be a valid
            +     * CIDR-formatted prefix. If an IP address is provided without a subnet mask,
            +     * it is interpreted as, for IPv4, a `/32` singular IP address range, and, for
            +     * IPv6,
            +     * `/128`.
            +     * 
            + * + * string ip_range = 8 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @return This builder for chaining. + */ + public Builder clearIpRange() { + ipRange_ = getDefaultInstance().getIpRange(); + bitField0_ = (bitField0_ & ~0x00000080); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Immutable. This route's advertised IP address range. Must be a valid
            +     * CIDR-formatted prefix. If an IP address is provided without a subnet mask,
            +     * it is interpreted as, for IPv4, a `/32` singular IP address range, and, for
            +     * IPv6,
            +     * `/128`.
            +     * 
            + * + * string ip_range = 8 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @param value The bytes for ipRange to set. + * @return This builder for chaining. + */ + public Builder setIpRangeBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ipRange_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + private int priority_; + + /** + * + * + *
            +     * Optional. The priority of this advertised route. You can choose a value
            +     * from `0` to `65335`. If you don't provide a value, Google Cloud assigns a
            +     * priority of `100` to the ranges.
            +     * 
            + * + * optional int32 priority = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the priority field is set. + */ + @java.lang.Override + public boolean hasPriority() { + return ((bitField0_ & 0x00000100) != 0); + } + + /** + * + * + *
            +     * Optional. The priority of this advertised route. You can choose a value
            +     * from `0` to `65335`. If you don't provide a value, Google Cloud assigns a
            +     * priority of `100` to the ranges.
            +     * 
            + * + * optional int32 priority = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The priority. + */ + @java.lang.Override + public int getPriority() { + return priority_; + } + + /** + * + * + *
            +     * Optional. The priority of this advertised route. You can choose a value
            +     * from `0` to `65335`. If you don't provide a value, Google Cloud assigns a
            +     * priority of `100` to the ranges.
            +     * 
            + * + * optional int32 priority = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The priority to set. + * @return This builder for chaining. + */ + public Builder setPriority(int value) { + + priority_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. The priority of this advertised route. You can choose a value
            +     * from `0` to `65335`. If you don't provide a value, Google Cloud assigns a
            +     * priority of `100` to the ranges.
            +     * 
            + * + * optional int32 priority = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPriority() { + bitField0_ = (bitField0_ & ~0x00000100); + priority_ = 0; + onChanged(); + return this; + } + + private int recipient_ = 0; + + /** + * + * + *
            +     * Optional. The recipient of this advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient recipient = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for recipient. + */ + @java.lang.Override + public int getRecipientValue() { + return recipient_; + } + + /** + * + * + *
            +     * Optional. The recipient of this advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient recipient = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for recipient to set. + * @return This builder for chaining. + */ + public Builder setRecipientValue(int value) { + recipient_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. The recipient of this advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient recipient = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The recipient. + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient getRecipient() { + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient result = + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient.forNumber( + recipient_); + return result == null + ? com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient.UNRECOGNIZED + : result; + } + + /** + * + * + *
            +     * Optional. The recipient of this advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient recipient = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The recipient to set. + * @return This builder for chaining. + */ + public Builder setRecipient( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000200; + recipient_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Optional. The recipient of this advertised route.
            +     * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient recipient = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearRecipient() { + bitField0_ = (bitField0_ & ~0x00000200); + recipient_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute) + private static final com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute(); + } + + public static com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GatewayAdvertisedRoute parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayAdvertisedRouteName.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayAdvertisedRouteName.java new file mode 100644 index 000000000000..f73f6c6a38d1 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayAdvertisedRouteName.java @@ -0,0 +1,273 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class GatewayAdvertisedRouteName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_SPOKE_GATEWAY_ADVERTISED_ROUTE = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String spoke; + private final String gatewayAdvertisedRoute; + + @Deprecated + protected GatewayAdvertisedRouteName() { + project = null; + location = null; + spoke = null; + gatewayAdvertisedRoute = null; + } + + private GatewayAdvertisedRouteName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + spoke = Preconditions.checkNotNull(builder.getSpoke()); + gatewayAdvertisedRoute = Preconditions.checkNotNull(builder.getGatewayAdvertisedRoute()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getSpoke() { + return spoke; + } + + public String getGatewayAdvertisedRoute() { + return gatewayAdvertisedRoute; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static GatewayAdvertisedRouteName of( + String project, String location, String spoke, String gatewayAdvertisedRoute) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setSpoke(spoke) + .setGatewayAdvertisedRoute(gatewayAdvertisedRoute) + .build(); + } + + public static String format( + String project, String location, String spoke, String gatewayAdvertisedRoute) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setSpoke(spoke) + .setGatewayAdvertisedRoute(gatewayAdvertisedRoute) + .build() + .toString(); + } + + public static @Nullable GatewayAdvertisedRouteName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_SPOKE_GATEWAY_ADVERTISED_ROUTE.validatedMatch( + formattedString, + "GatewayAdvertisedRouteName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("spoke"), + matchMap.get("gateway_advertised_route")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable GatewayAdvertisedRouteName> values) { + List list = new ArrayList<>(values.size()); + for (GatewayAdvertisedRouteName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_SPOKE_GATEWAY_ADVERTISED_ROUTE.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (spoke != null) { + fieldMapBuilder.put("spoke", spoke); + } + if (gatewayAdvertisedRoute != null) { + fieldMapBuilder.put("gateway_advertised_route", gatewayAdvertisedRoute); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_SPOKE_GATEWAY_ADVERTISED_ROUTE.instantiate( + "project", + project, + "location", + location, + "spoke", + spoke, + "gateway_advertised_route", + gatewayAdvertisedRoute); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + GatewayAdvertisedRouteName that = ((GatewayAdvertisedRouteName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.spoke, that.spoke) + && Objects.equals(this.gatewayAdvertisedRoute, that.gatewayAdvertisedRoute); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(spoke); + h *= 1000003; + h ^= Objects.hashCode(gatewayAdvertisedRoute); + return h; + } + + /** + * Builder for + * projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route}. + */ + public static class Builder { + private String project; + private String location; + private String spoke; + private String gatewayAdvertisedRoute; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getSpoke() { + return spoke; + } + + public String getGatewayAdvertisedRoute() { + return gatewayAdvertisedRoute; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setSpoke(String spoke) { + this.spoke = spoke; + return this; + } + + public Builder setGatewayAdvertisedRoute(String gatewayAdvertisedRoute) { + this.gatewayAdvertisedRoute = gatewayAdvertisedRoute; + return this; + } + + private Builder(GatewayAdvertisedRouteName gatewayAdvertisedRouteName) { + this.project = gatewayAdvertisedRouteName.project; + this.location = gatewayAdvertisedRouteName.location; + this.spoke = gatewayAdvertisedRouteName.spoke; + this.gatewayAdvertisedRoute = gatewayAdvertisedRouteName.gatewayAdvertisedRoute; + } + + public GatewayAdvertisedRouteName build() { + return new GatewayAdvertisedRouteName(this); + } + } +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayAdvertisedRouteOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayAdvertisedRouteOrBuilder.java new file mode 100644 index 000000000000..db3d9cbb8cab --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayAdvertisedRouteOrBuilder.java @@ -0,0 +1,393 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +@com.google.protobuf.Generated +public interface GatewayAdvertisedRouteOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
            +   * Identifier. The name of the gateway advertised route. Route names must be
            +   * unique and use the following form:
            +   * `projects/{project_number}/locations/{region}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route_id}`
            +   * 
            + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
            +   * Identifier. The name of the gateway advertised route. Route names must be
            +   * unique and use the following form:
            +   * `projects/{project_number}/locations/{region}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route_id}`
            +   * 
            + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was created.
            +   * 
            + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was created.
            +   * 
            + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was created.
            +   * 
            + * + * .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was last updated.
            +   * 
            + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was last updated.
            +   * 
            + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + + /** + * + * + *
            +   * Output only. The time the gateway advertised route was last updated.
            +   * 
            + * + * .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
            +   * Optional labels in key-value pair format. For more information about
            +   * labels, see [Requirements for
            +   * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +   * 
            + * + * map<string, string> labels = 4; + */ + int getLabelsCount(); + + /** + * + * + *
            +   * Optional labels in key-value pair format. For more information about
            +   * labels, see [Requirements for
            +   * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +   * 
            + * + * map<string, string> labels = 4; + */ + boolean containsLabels(java.lang.String key); + + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Deprecated + java.util.Map getLabels(); + + /** + * + * + *
            +   * Optional labels in key-value pair format. For more information about
            +   * labels, see [Requirements for
            +   * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +   * 
            + * + * map<string, string> labels = 4; + */ + java.util.Map getLabelsMap(); + + /** + * + * + *
            +   * Optional labels in key-value pair format. For more information about
            +   * labels, see [Requirements for
            +   * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +   * 
            + * + * map<string, string> labels = 4; + */ + /* nullable */ + java.lang.String getLabelsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue); + + /** + * + * + *
            +   * Optional labels in key-value pair format. For more information about
            +   * labels, see [Requirements for
            +   * labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements).
            +   * 
            + * + * map<string, string> labels = 4; + */ + java.lang.String getLabelsOrThrow(java.lang.String key); + + /** + * + * + *
            +   * An optional description of the gateway advertised route.
            +   * 
            + * + * string description = 5; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
            +   * An optional description of the gateway advertised route.
            +   * 
            + * + * string description = 5; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
            +   * Output only. The Google-generated UUID for the gateway advertised route.
            +   * This value is unique across all gateway advertised route resources. If a
            +   * gateway advertised route is deleted and another with the same name is
            +   * created, the new route is assigned a different `unique_id`.
            +   * 
            + * + * string unique_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uniqueId. + */ + java.lang.String getUniqueId(); + + /** + * + * + *
            +   * Output only. The Google-generated UUID for the gateway advertised route.
            +   * This value is unique across all gateway advertised route resources. If a
            +   * gateway advertised route is deleted and another with the same name is
            +   * created, the new route is assigned a different `unique_id`.
            +   * 
            + * + * string unique_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uniqueId. + */ + com.google.protobuf.ByteString getUniqueIdBytes(); + + /** + * + * + *
            +   * Output only. The current lifecycle state of this gateway advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
            +   * Output only. The current lifecycle state of this gateway advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.networkconnectivity.v1.State getState(); + + /** + * + * + *
            +   * Immutable. This route's advertised IP address range. Must be a valid
            +   * CIDR-formatted prefix. If an IP address is provided without a subnet mask,
            +   * it is interpreted as, for IPv4, a `/32` singular IP address range, and, for
            +   * IPv6,
            +   * `/128`.
            +   * 
            + * + * string ip_range = 8 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @return The ipRange. + */ + java.lang.String getIpRange(); + + /** + * + * + *
            +   * Immutable. This route's advertised IP address range. Must be a valid
            +   * CIDR-formatted prefix. If an IP address is provided without a subnet mask,
            +   * it is interpreted as, for IPv4, a `/32` singular IP address range, and, for
            +   * IPv6,
            +   * `/128`.
            +   * 
            + * + * string ip_range = 8 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @return The bytes for ipRange. + */ + com.google.protobuf.ByteString getIpRangeBytes(); + + /** + * + * + *
            +   * Optional. The priority of this advertised route. You can choose a value
            +   * from `0` to `65335`. If you don't provide a value, Google Cloud assigns a
            +   * priority of `100` to the ranges.
            +   * 
            + * + * optional int32 priority = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the priority field is set. + */ + boolean hasPriority(); + + /** + * + * + *
            +   * Optional. The priority of this advertised route. You can choose a value
            +   * from `0` to `65335`. If you don't provide a value, Google Cloud assigns a
            +   * priority of `100` to the ranges.
            +   * 
            + * + * optional int32 priority = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The priority. + */ + int getPriority(); + + /** + * + * + *
            +   * Optional. The recipient of this advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient recipient = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for recipient. + */ + int getRecipientValue(); + + /** + * + * + *
            +   * Optional. The recipient of this advertised route.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient recipient = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The recipient. + */ + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Recipient getRecipient(); +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayOrBuilder.java new file mode 100644 index 000000000000..4ac1cd781e15 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GatewayOrBuilder.java @@ -0,0 +1,229 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +@com.google.protobuf.Generated +public interface GatewayOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.Gateway) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
            +   * Optional. A list of IP ranges that are reserved for this gateway's internal
            +   * intfrastructure.
            +   * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List + getIpRangeReservationsList(); + + /** + * + * + *
            +   * Optional. A list of IP ranges that are reserved for this gateway's internal
            +   * intfrastructure.
            +   * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation getIpRangeReservations( + int index); + + /** + * + * + *
            +   * Optional. A list of IP ranges that are reserved for this gateway's internal
            +   * intfrastructure.
            +   * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + int getIpRangeReservationsCount(); + + /** + * + * + *
            +   * Optional. A list of IP ranges that are reserved for this gateway's internal
            +   * intfrastructure.
            +   * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List< + ? extends com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservationOrBuilder> + getIpRangeReservationsOrBuilderList(); + + /** + * + * + *
            +   * Optional. A list of IP ranges that are reserved for this gateway's internal
            +   * intfrastructure.
            +   * 
            + * + * + * repeated .google.cloud.networkconnectivity.v1.Gateway.IpRangeReservation ip_range_reservations = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservationOrBuilder + getIpRangeReservationsOrBuilder(int index); + + /** + * + * + *
            +   * Optional. The aggregate processing capacity of this gateway.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity capacity = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for capacity. + */ + int getCapacityValue(); + + /** + * + * + *
            +   * Optional. The aggregate processing capacity of this gateway.
            +   * 
            + * + * + * .google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity capacity = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The capacity. + */ + com.google.cloud.networkconnectivity.v1.Gateway.GatewayCapacity getCapacity(); + + /** + * + * + *
            +   * Output only. The list of Cloud Routers that are connected to this gateway.
            +   * Should be in the form:
            +   * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +   * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return A list containing the cloudRouters. + */ + java.util.List getCloudRoutersList(); + + /** + * + * + *
            +   * Output only. The list of Cloud Routers that are connected to this gateway.
            +   * Should be in the form:
            +   * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +   * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The count of cloudRouters. + */ + int getCloudRoutersCount(); + + /** + * + * + *
            +   * Output only. The list of Cloud Routers that are connected to this gateway.
            +   * Should be in the form:
            +   * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +   * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param index The index of the element to return. + * @return The cloudRouters at the given index. + */ + java.lang.String getCloudRouters(int index); + + /** + * + * + *
            +   * Output only. The list of Cloud Routers that are connected to this gateway.
            +   * Should be in the form:
            +   * https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router}
            +   * 
            + * + * repeated string cloud_routers = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param index The index of the value to return. + * @return The bytes of the cloudRouters at the given index. + */ + com.google.protobuf.ByteString getCloudRoutersBytes(int index); + + /** + * + * + *
            +   * Output only. The URI of the connected SACAttachment.
            +   * Should be in the form:
            +   * projects/{project}/locations/{location}/sacAttachments/{sac_attachment}
            +   * 
            + * + * + * string sac_attachment = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The sacAttachment. + */ + java.lang.String getSacAttachment(); + + /** + * + * + *
            +   * Output only. The URI of the connected SACAttachment.
            +   * Should be in the form:
            +   * projects/{project}/locations/{location}/sacAttachments/{sac_attachment}
            +   * 
            + * + * + * string sac_attachment = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for sacAttachment. + */ + com.google.protobuf.ByteString getSacAttachmentBytes(); +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GetGatewayAdvertisedRouteRequest.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GetGatewayAdvertisedRouteRequest.java new file mode 100644 index 000000000000..2c5ed3d27b47 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GetGatewayAdvertisedRouteRequest.java @@ -0,0 +1,630 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +/** + * + * + *
            + * The request for
            + * [HubService.GetGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.GetGatewayAdvertisedRoute].
            + * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest} + */ +@com.google.protobuf.Generated +public final class GetGatewayAdvertisedRouteRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest) + GetGatewayAdvertisedRouteRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetGatewayAdvertisedRouteRequest"); + } + + // Use GetGatewayAdvertisedRouteRequest.newBuilder() to construct. + private GetGatewayAdvertisedRouteRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetGatewayAdvertisedRouteRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_GetGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_GetGatewayAdvertisedRouteRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest.class, + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
            +   * Required. The name of the gateway advertised route to get.
            +   * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
            +   * Required. The name of the gateway advertised route to get.
            +   * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest other = + (com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
            +   * The request for
            +   * [HubService.GetGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.GetGatewayAdvertisedRoute].
            +   * 
            + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest) + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_GetGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_GetGatewayAdvertisedRouteRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest.class, + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest.Builder + .class); + } + + // Construct using + // com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_GetGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest + getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest build() { + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest buildPartial() { + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest result = + new com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest) { + return mergeFrom( + (com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest other) { + if (other + == com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest + .getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
            +     * Required. The name of the gateway advertised route to get.
            +     * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
            +     * Required. The name of the gateway advertised route to get.
            +     * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
            +     * Required. The name of the gateway advertised route to get.
            +     * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
            +     * Required. The name of the gateway advertised route to get.
            +     * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
            +     * Required. The name of the gateway advertised route to get.
            +     * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest) + private static final com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest(); + } + + public static com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetGatewayAdvertisedRouteRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GetGatewayAdvertisedRouteRequestOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GetGatewayAdvertisedRouteRequestOrBuilder.java new file mode 100644 index 000000000000..2f310f0c0729 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GetGatewayAdvertisedRouteRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +@com.google.protobuf.Generated +public interface GetGatewayAdvertisedRouteRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
            +   * Required. The name of the gateway advertised route to get.
            +   * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
            +   * Required. The name of the gateway advertised route to get.
            +   * 
            + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Group.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Group.java index dcd1efa1add4..f76e972e335f 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Group.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Group.java @@ -589,7 +589,9 @@ public com.google.cloud.networkconnectivity.v1.AutoAcceptOrBuilder getAutoAccept * `projects/{project_number}/locations/global/hubs/{hub_id}/routeTables/{route_table_id}` *
            * - * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * * * @return The routeTable. */ @@ -615,7 +617,9 @@ public java.lang.String getRouteTable() { * `projects/{project_number}/locations/global/hubs/{hub_id}/routeTables/{route_table_id}` *
            * - * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * * * @return The bytes for routeTable. */ @@ -2503,7 +2507,9 @@ public com.google.cloud.networkconnectivity.v1.AutoAcceptOrBuilder getAutoAccept * `projects/{project_number}/locations/global/hubs/{hub_id}/routeTables/{route_table_id}` *
          * - * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * * * @return The routeTable. */ @@ -2528,7 +2534,9 @@ public java.lang.String getRouteTable() { * `projects/{project_number}/locations/global/hubs/{hub_id}/routeTables/{route_table_id}` *
          * - * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * * * @return The bytes for routeTable. */ @@ -2553,7 +2561,9 @@ public com.google.protobuf.ByteString getRouteTableBytes() { * `projects/{project_number}/locations/global/hubs/{hub_id}/routeTables/{route_table_id}` *
          * - * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * * * @param value The routeTable to set. * @return This builder for chaining. @@ -2577,7 +2587,9 @@ public Builder setRouteTable(java.lang.String value) { * `projects/{project_number}/locations/global/hubs/{hub_id}/routeTables/{route_table_id}` *
        * - * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * * * @return This builder for chaining. */ @@ -2597,7 +2609,9 @@ public Builder clearRouteTable() { * `projects/{project_number}/locations/global/hubs/{hub_id}/routeTables/{route_table_id}` *
        * - * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * * * @param value The bytes for routeTable to set. * @return This builder for chaining. diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GroupOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GroupOrBuilder.java index 0f84af37ad4f..2ff69e248bec 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GroupOrBuilder.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/GroupOrBuilder.java @@ -349,7 +349,9 @@ java.lang.String getLabelsOrDefault( * `projects/{project_number}/locations/global/hubs/{hub_id}/routeTables/{route_table_id}` *
        * - * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * * * @return The routeTable. */ @@ -364,7 +366,9 @@ java.lang.String getLabelsOrDefault( * `projects/{project_number}/locations/global/hubs/{hub_id}/routeTables/{route_table_id}` *
      * - * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * string route_table = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * * * @return The bytes for routeTable. */ diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Hub.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Hub.java index a31f0693d707..c560b6d3b698 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Hub.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Hub.java @@ -94,6 +94,785 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldRefl com.google.cloud.networkconnectivity.v1.Hub.Builder.class); } + public interface ExportPscConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.Hub.ExportPscConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
      +     * Optional. Controls whether Private Service Connect endpoints for regional
      +     * ILBs and regional Google APIs should be propagated. Default value is true
      +     * if export_psc is true. Otherwise, the default value is false.
      +     * 
      + * + * + * optional bool published_services_and_regional_google_apis = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the publishedServicesAndRegionalGoogleApis field is set. + */ + boolean hasPublishedServicesAndRegionalGoogleApis(); + + /** + * + * + *
      +     * Optional. Controls whether Private Service Connect endpoints for regional
      +     * ILBs and regional Google APIs should be propagated. Default value is true
      +     * if export_psc is true. Otherwise, the default value is false.
      +     * 
      + * + * + * optional bool published_services_and_regional_google_apis = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The publishedServicesAndRegionalGoogleApis. + */ + boolean getPublishedServicesAndRegionalGoogleApis(); + + /** + * + * + *
      +     * Optional. Controls whether Private Service Connect endpoints for global
      +     * Google APIs should be propagated. The default value is false.
      +     * 
      + * + * optional bool global_google_apis = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the globalGoogleApis field is set. + */ + boolean hasGlobalGoogleApis(); + + /** + * + * + *
      +     * Optional. Controls whether Private Service Connect endpoints for global
      +     * Google APIs should be propagated. The default value is false.
      +     * 
      + * + * optional bool global_google_apis = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The globalGoogleApis. + */ + boolean getGlobalGoogleApis(); + } + + /** + * + * + *
      +   * Configuration for more granular control of Private Service Connect
      +   * connection propagation.
      +   * This allows enabling or disabling connection propagation for specific types
      +   * of Private Service Connect endpoints.
      +   * 
      + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.Hub.ExportPscConfig} + */ + public static final class ExportPscConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.Hub.ExportPscConfig) + ExportPscConfigOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ExportPscConfig"); + } + + // Use ExportPscConfig.newBuilder() to construct. + private ExportPscConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ExportPscConfig() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Hub_ExportPscConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Hub_ExportPscConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.class, + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.Builder.class); + } + + private int bitField0_; + public static final int PUBLISHED_SERVICES_AND_REGIONAL_GOOGLE_APIS_FIELD_NUMBER = 1; + private boolean publishedServicesAndRegionalGoogleApis_ = false; + + /** + * + * + *
      +     * Optional. Controls whether Private Service Connect endpoints for regional
      +     * ILBs and regional Google APIs should be propagated. Default value is true
      +     * if export_psc is true. Otherwise, the default value is false.
      +     * 
      + * + * + * optional bool published_services_and_regional_google_apis = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the publishedServicesAndRegionalGoogleApis field is set. + */ + @java.lang.Override + public boolean hasPublishedServicesAndRegionalGoogleApis() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
      +     * Optional. Controls whether Private Service Connect endpoints for regional
      +     * ILBs and regional Google APIs should be propagated. Default value is true
      +     * if export_psc is true. Otherwise, the default value is false.
      +     * 
      + * + * + * optional bool published_services_and_regional_google_apis = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The publishedServicesAndRegionalGoogleApis. + */ + @java.lang.Override + public boolean getPublishedServicesAndRegionalGoogleApis() { + return publishedServicesAndRegionalGoogleApis_; + } + + public static final int GLOBAL_GOOGLE_APIS_FIELD_NUMBER = 2; + private boolean globalGoogleApis_ = false; + + /** + * + * + *
      +     * Optional. Controls whether Private Service Connect endpoints for global
      +     * Google APIs should be propagated. The default value is false.
      +     * 
      + * + * optional bool global_google_apis = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the globalGoogleApis field is set. + */ + @java.lang.Override + public boolean hasGlobalGoogleApis() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
      +     * Optional. Controls whether Private Service Connect endpoints for global
      +     * Google APIs should be propagated. The default value is false.
      +     * 
      + * + * optional bool global_google_apis = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The globalGoogleApis. + */ + @java.lang.Override + public boolean getGlobalGoogleApis() { + return globalGoogleApis_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeBool(1, publishedServicesAndRegionalGoogleApis_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeBool(2, globalGoogleApis_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeBoolSize( + 1, publishedServicesAndRegionalGoogleApis_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, globalGoogleApis_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig other = + (com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig) obj; + + if (hasPublishedServicesAndRegionalGoogleApis() + != other.hasPublishedServicesAndRegionalGoogleApis()) return false; + if (hasPublishedServicesAndRegionalGoogleApis()) { + if (getPublishedServicesAndRegionalGoogleApis() + != other.getPublishedServicesAndRegionalGoogleApis()) return false; + } + if (hasGlobalGoogleApis() != other.hasGlobalGoogleApis()) return false; + if (hasGlobalGoogleApis()) { + if (getGlobalGoogleApis() != other.getGlobalGoogleApis()) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasPublishedServicesAndRegionalGoogleApis()) { + hash = (37 * hash) + PUBLISHED_SERVICES_AND_REGIONAL_GOOGLE_APIS_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashBoolean( + getPublishedServicesAndRegionalGoogleApis()); + } + if (hasGlobalGoogleApis()) { + hash = (37 * hash) + GLOBAL_GOOGLE_APIS_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getGlobalGoogleApis()); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
      +     * Configuration for more granular control of Private Service Connect
      +     * connection propagation.
      +     * This allows enabling or disabling connection propagation for specific types
      +     * of Private Service Connect endpoints.
      +     * 
      + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.Hub.ExportPscConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.Hub.ExportPscConfig) + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Hub_ExportPscConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Hub_ExportPscConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.class, + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.Builder.class); + } + + // Construct using com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + publishedServicesAndRegionalGoogleApis_ = false; + globalGoogleApis_ = false; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_Hub_ExportPscConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig + getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig build() { + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig buildPartial() { + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig result = + new com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.publishedServicesAndRegionalGoogleApis_ = publishedServicesAndRegionalGoogleApis_; + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.globalGoogleApis_ = globalGoogleApis_; + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig) { + return mergeFrom((com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig other) { + if (other + == com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.getDefaultInstance()) + return this; + if (other.hasPublishedServicesAndRegionalGoogleApis()) { + setPublishedServicesAndRegionalGoogleApis( + other.getPublishedServicesAndRegionalGoogleApis()); + } + if (other.hasGlobalGoogleApis()) { + setGlobalGoogleApis(other.getGlobalGoogleApis()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + publishedServicesAndRegionalGoogleApis_ = input.readBool(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 16: + { + globalGoogleApis_ = input.readBool(); + bitField0_ |= 0x00000002; + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private boolean publishedServicesAndRegionalGoogleApis_; + + /** + * + * + *
      +       * Optional. Controls whether Private Service Connect endpoints for regional
      +       * ILBs and regional Google APIs should be propagated. Default value is true
      +       * if export_psc is true. Otherwise, the default value is false.
      +       * 
      + * + * + * optional bool published_services_and_regional_google_apis = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the publishedServicesAndRegionalGoogleApis field is set. + */ + @java.lang.Override + public boolean hasPublishedServicesAndRegionalGoogleApis() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
      +       * Optional. Controls whether Private Service Connect endpoints for regional
      +       * ILBs and regional Google APIs should be propagated. Default value is true
      +       * if export_psc is true. Otherwise, the default value is false.
      +       * 
      + * + * + * optional bool published_services_and_regional_google_apis = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The publishedServicesAndRegionalGoogleApis. + */ + @java.lang.Override + public boolean getPublishedServicesAndRegionalGoogleApis() { + return publishedServicesAndRegionalGoogleApis_; + } + + /** + * + * + *
      +       * Optional. Controls whether Private Service Connect endpoints for regional
      +       * ILBs and regional Google APIs should be propagated. Default value is true
      +       * if export_psc is true. Otherwise, the default value is false.
      +       * 
      + * + * + * optional bool published_services_and_regional_google_apis = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The publishedServicesAndRegionalGoogleApis to set. + * @return This builder for chaining. + */ + public Builder setPublishedServicesAndRegionalGoogleApis(boolean value) { + + publishedServicesAndRegionalGoogleApis_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
      +       * Optional. Controls whether Private Service Connect endpoints for regional
      +       * ILBs and regional Google APIs should be propagated. Default value is true
      +       * if export_psc is true. Otherwise, the default value is false.
      +       * 
      + * + * + * optional bool published_services_and_regional_google_apis = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearPublishedServicesAndRegionalGoogleApis() { + bitField0_ = (bitField0_ & ~0x00000001); + publishedServicesAndRegionalGoogleApis_ = false; + onChanged(); + return this; + } + + private boolean globalGoogleApis_; + + /** + * + * + *
      +       * Optional. Controls whether Private Service Connect endpoints for global
      +       * Google APIs should be propagated. The default value is false.
      +       * 
      + * + * optional bool global_google_apis = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the globalGoogleApis field is set. + */ + @java.lang.Override + public boolean hasGlobalGoogleApis() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
      +       * Optional. Controls whether Private Service Connect endpoints for global
      +       * Google APIs should be propagated. The default value is false.
      +       * 
      + * + * optional bool global_google_apis = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The globalGoogleApis. + */ + @java.lang.Override + public boolean getGlobalGoogleApis() { + return globalGoogleApis_; + } + + /** + * + * + *
      +       * Optional. Controls whether Private Service Connect endpoints for global
      +       * Google APIs should be propagated. The default value is false.
      +       * 
      + * + * optional bool global_google_apis = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The globalGoogleApis to set. + * @return This builder for chaining. + */ + public Builder setGlobalGoogleApis(boolean value) { + + globalGoogleApis_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
      +       * Optional. Controls whether Private Service Connect endpoints for global
      +       * Google APIs should be propagated. The default value is false.
      +       * 
      + * + * optional bool global_google_apis = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearGlobalGoogleApis() { + bitField0_ = (bitField0_ & ~0x00000002); + globalGoogleApis_ = false; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.Hub.ExportPscConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.Hub.ExportPscConfig) + private static final com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig(); + } + + public static com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ExportPscConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + private int bitField0_; public static final int NAME_FIELD_NUMBER = 1; @@ -531,13 +1310,15 @@ public com.google.cloud.networkconnectivity.v1.State getState() { * * *
      -   * The VPC networks associated with this hub's spokes.
      +   * Output only. The VPC networks associated with this hub's spokes.
          *
          * This field is read-only. Network Connectivity Center automatically
          * populates it based on the set of spokes attached to the hub.
          * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public java.util.List getRoutingVpcsList() { @@ -548,13 +1329,15 @@ public java.util.List getRou * * *
      -   * The VPC networks associated with this hub's spokes.
      +   * Output only. The VPC networks associated with this hub's spokes.
          *
          * This field is read-only. Network Connectivity Center automatically
          * populates it based on the set of spokes attached to the hub.
          * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public java.util.List @@ -566,13 +1349,15 @@ public java.util.List getRou * * *
      -   * The VPC networks associated with this hub's spokes.
      +   * Output only. The VPC networks associated with this hub's spokes.
          *
          * This field is read-only. Network Connectivity Center automatically
          * populates it based on the set of spokes attached to the hub.
          * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public int getRoutingVpcsCount() { @@ -583,13 +1368,15 @@ public int getRoutingVpcsCount() { * * *
      -   * The VPC networks associated with this hub's spokes.
      +   * Output only. The VPC networks associated with this hub's spokes.
          *
          * This field is read-only. Network Connectivity Center automatically
          * populates it based on the set of spokes attached to the hub.
          * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.cloud.networkconnectivity.v1.RoutingVPC getRoutingVpcs(int index) { @@ -600,13 +1387,15 @@ public com.google.cloud.networkconnectivity.v1.RoutingVPC getRoutingVpcs(int ind * * *
      -   * The VPC networks associated with this hub's spokes.
      +   * Output only. The VPC networks associated with this hub's spokes.
          *
          * This field is read-only. Network Connectivity Center automatically
          * populates it based on the set of spokes attached to the hub.
          * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder getRoutingVpcsOrBuilder( @@ -912,6 +1701,69 @@ public boolean getExportPsc() { return exportPsc_; } + public static final int EXPORT_PSC_CONFIG_FIELD_NUMBER = 17; + private com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig exportPscConfig_; + + /** + * + * + *
      +   * Optional. Config for more granular control of Private Service Connect
      +   * transitivity.
      +   * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the exportPscConfig field is set. + */ + @java.lang.Override + public boolean hasExportPscConfig() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
      +   * Optional. Config for more granular control of Private Service Connect
      +   * transitivity.
      +   * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The exportPscConfig. + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig getExportPscConfig() { + return exportPscConfig_ == null + ? com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.getDefaultInstance() + : exportPscConfig_; + } + + /** + * + * + *
      +   * Optional. Config for more granular control of Private Service Connect
      +   * transitivity.
      +   * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfigOrBuilder + getExportPscConfigOrBuilder() { + return exportPscConfig_ == null + ? com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.getDefaultInstance() + : exportPscConfig_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -967,6 +1819,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000008) != 0)) { output.writeBool(15, exportPsc_); } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeMessage(17, getExportPscConfig()); + } getUnknownFields().writeTo(output); } @@ -1030,6 +1885,9 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000008) != 0)) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(15, exportPsc_); } + if (((bitField0_ & 0x00000010) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(17, getExportPscConfig()); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1071,6 +1929,10 @@ public boolean equals(final java.lang.Object obj) { if (hasExportPsc()) { if (getExportPsc() != other.getExportPsc()) return false; } + if (hasExportPscConfig() != other.hasExportPscConfig()) return false; + if (hasExportPscConfig()) { + if (!getExportPscConfig().equals(other.getExportPscConfig())) return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1122,6 +1984,10 @@ public int hashCode() { hash = (37 * hash) + EXPORT_PSC_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getExportPsc()); } + if (hasExportPscConfig()) { + hash = (37 * hash) + EXPORT_PSC_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getExportPscConfig().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1294,6 +2160,7 @@ private void maybeForceBuilderInitialization() { internalGetUpdateTimeFieldBuilder(); internalGetRoutingVpcsFieldBuilder(); internalGetSpokeSummaryFieldBuilder(); + internalGetExportPscConfigFieldBuilder(); } } @@ -1332,6 +2199,11 @@ public Builder clear() { policyMode_ = 0; presetTopology_ = 0; exportPsc_ = false; + exportPscConfig_ = null; + if (exportPscConfigBuilder_ != null) { + exportPscConfigBuilder_.dispose(); + exportPscConfigBuilder_ = null; + } return this; } @@ -1425,6 +2297,11 @@ private void buildPartial0(com.google.cloud.networkconnectivity.v1.Hub result) { result.exportPsc_ = exportPsc_; to_bitField0_ |= 0x00000008; } + if (((from_bitField0_ & 0x00002000) != 0)) { + result.exportPscConfig_ = + exportPscConfigBuilder_ == null ? exportPscConfig_ : exportPscConfigBuilder_.build(); + to_bitField0_ |= 0x00000010; + } result.bitField0_ |= to_bitField0_; } @@ -1515,6 +2392,9 @@ public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.Hub other) { if (other.hasExportPsc()) { setExportPsc(other.getExportPsc()); } + if (other.hasExportPscConfig()) { + mergeExportPscConfig(other.getExportPscConfig()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1637,6 +2517,13 @@ public Builder mergeFrom( bitField0_ |= 0x00001000; break; } // case 120 + case 138: + { + input.readMessage( + internalGetExportPscConfigFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00002000; + break; + } // case 138 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -2746,13 +3633,15 @@ private void ensureRoutingVpcsIsMutable() { * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public java.util.List getRoutingVpcsList() { if (routingVpcsBuilder_ == null) { @@ -2766,13 +3655,15 @@ public java.util.List getRou * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public int getRoutingVpcsCount() { if (routingVpcsBuilder_ == null) { @@ -2786,13 +3677,15 @@ public int getRoutingVpcsCount() { * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.networkconnectivity.v1.RoutingVPC getRoutingVpcs(int index) { if (routingVpcsBuilder_ == null) { @@ -2806,13 +3699,15 @@ public com.google.cloud.networkconnectivity.v1.RoutingVPC getRoutingVpcs(int ind * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setRoutingVpcs( int index, com.google.cloud.networkconnectivity.v1.RoutingVPC value) { @@ -2833,13 +3728,15 @@ public Builder setRoutingVpcs( * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setRoutingVpcs( int index, com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder builderForValue) { @@ -2857,13 +3754,15 @@ public Builder setRoutingVpcs( * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addRoutingVpcs(com.google.cloud.networkconnectivity.v1.RoutingVPC value) { if (routingVpcsBuilder_ == null) { @@ -2883,13 +3782,15 @@ public Builder addRoutingVpcs(com.google.cloud.networkconnectivity.v1.RoutingVPC * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addRoutingVpcs( int index, com.google.cloud.networkconnectivity.v1.RoutingVPC value) { @@ -2910,13 +3811,15 @@ public Builder addRoutingVpcs( * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addRoutingVpcs( com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder builderForValue) { @@ -2934,13 +3837,15 @@ public Builder addRoutingVpcs( * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addRoutingVpcs( int index, com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder builderForValue) { @@ -2958,13 +3863,15 @@ public Builder addRoutingVpcs( * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addAllRoutingVpcs( java.lang.Iterable values) { @@ -2982,13 +3889,15 @@ public Builder addAllRoutingVpcs( * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearRoutingVpcs() { if (routingVpcsBuilder_ == null) { @@ -3005,13 +3914,15 @@ public Builder clearRoutingVpcs() { * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder removeRoutingVpcs(int index) { if (routingVpcsBuilder_ == null) { @@ -3028,13 +3939,15 @@ public Builder removeRoutingVpcs(int index) { * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder getRoutingVpcsBuilder( int index) { @@ -3045,13 +3958,15 @@ public com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder getRoutingVpcs * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder getRoutingVpcsOrBuilder( int index) { @@ -3066,13 +3981,15 @@ public com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder getRoutingVpc * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public java.util.List getRoutingVpcsOrBuilderList() { @@ -3087,13 +4004,15 @@ public com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder getRoutingVpc * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder addRoutingVpcsBuilder() { return internalGetRoutingVpcsFieldBuilder() @@ -3104,13 +4023,15 @@ public com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder addRoutingVpcs * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder addRoutingVpcsBuilder( int index) { @@ -3123,13 +4044,15 @@ public com.google.cloud.networkconnectivity.v1.RoutingVPC.Builder addRoutingVpcs * * *
      -     * The VPC networks associated with this hub's spokes.
      +     * Output only. The VPC networks associated with this hub's spokes.
            *
            * This field is read-only. Network Connectivity Center automatically
            * populates it based on the set of spokes attached to the hub.
            * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public java.util.List getRoutingVpcsBuilderList() { @@ -3960,6 +4883,234 @@ public Builder clearExportPsc() { return this; } + private com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig exportPscConfig_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig, + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.Builder, + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfigOrBuilder> + exportPscConfigBuilder_; + + /** + * + * + *
      +     * Optional. Config for more granular control of Private Service Connect
      +     * transitivity.
      +     * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the exportPscConfig field is set. + */ + public boolean hasExportPscConfig() { + return ((bitField0_ & 0x00002000) != 0); + } + + /** + * + * + *
      +     * Optional. Config for more granular control of Private Service Connect
      +     * transitivity.
      +     * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The exportPscConfig. + */ + public com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig getExportPscConfig() { + if (exportPscConfigBuilder_ == null) { + return exportPscConfig_ == null + ? com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.getDefaultInstance() + : exportPscConfig_; + } else { + return exportPscConfigBuilder_.getMessage(); + } + } + + /** + * + * + *
      +     * Optional. Config for more granular control of Private Service Connect
      +     * transitivity.
      +     * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setExportPscConfig( + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig value) { + if (exportPscConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + exportPscConfig_ = value; + } else { + exportPscConfigBuilder_.setMessage(value); + } + bitField0_ |= 0x00002000; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Config for more granular control of Private Service Connect
      +     * transitivity.
      +     * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setExportPscConfig( + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.Builder builderForValue) { + if (exportPscConfigBuilder_ == null) { + exportPscConfig_ = builderForValue.build(); + } else { + exportPscConfigBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00002000; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Config for more granular control of Private Service Connect
      +     * transitivity.
      +     * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeExportPscConfig( + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig value) { + if (exportPscConfigBuilder_ == null) { + if (((bitField0_ & 0x00002000) != 0) + && exportPscConfig_ != null + && exportPscConfig_ + != com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig + .getDefaultInstance()) { + getExportPscConfigBuilder().mergeFrom(value); + } else { + exportPscConfig_ = value; + } + } else { + exportPscConfigBuilder_.mergeFrom(value); + } + if (exportPscConfig_ != null) { + bitField0_ |= 0x00002000; + onChanged(); + } + return this; + } + + /** + * + * + *
      +     * Optional. Config for more granular control of Private Service Connect
      +     * transitivity.
      +     * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearExportPscConfig() { + bitField0_ = (bitField0_ & ~0x00002000); + exportPscConfig_ = null; + if (exportPscConfigBuilder_ != null) { + exportPscConfigBuilder_.dispose(); + exportPscConfigBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Config for more granular control of Private Service Connect
      +     * transitivity.
      +     * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.Builder + getExportPscConfigBuilder() { + bitField0_ |= 0x00002000; + onChanged(); + return internalGetExportPscConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
      +     * Optional. Config for more granular control of Private Service Connect
      +     * transitivity.
      +     * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfigOrBuilder + getExportPscConfigOrBuilder() { + if (exportPscConfigBuilder_ != null) { + return exportPscConfigBuilder_.getMessageOrBuilder(); + } else { + return exportPscConfig_ == null + ? com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.getDefaultInstance() + : exportPscConfig_; + } + } + + /** + * + * + *
      +     * Optional. Config for more granular control of Private Service Connect
      +     * transitivity.
      +     * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig, + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.Builder, + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfigOrBuilder> + internalGetExportPscConfigFieldBuilder() { + if (exportPscConfigBuilder_ == null) { + exportPscConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig, + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig.Builder, + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfigOrBuilder>( + getExportPscConfig(), getParentForChildren(), isClean()); + exportPscConfig_ = null; + } + return exportPscConfigBuilder_; + } + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.Hub) } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubOrBuilder.java index 4309f44f94d7..2e5d7c619452 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubOrBuilder.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubOrBuilder.java @@ -299,13 +299,15 @@ java.lang.String getLabelsOrDefault( * * *
      -   * The VPC networks associated with this hub's spokes.
      +   * Output only. The VPC networks associated with this hub's spokes.
          *
          * This field is read-only. Network Connectivity Center automatically
          * populates it based on the set of spokes attached to the hub.
          * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ java.util.List getRoutingVpcsList(); @@ -313,13 +315,15 @@ java.lang.String getLabelsOrDefault( * * *
      -   * The VPC networks associated with this hub's spokes.
      +   * Output only. The VPC networks associated with this hub's spokes.
          *
          * This field is read-only. Network Connectivity Center automatically
          * populates it based on the set of spokes attached to the hub.
          * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.cloud.networkconnectivity.v1.RoutingVPC getRoutingVpcs(int index); @@ -327,13 +331,15 @@ java.lang.String getLabelsOrDefault( * * *
      -   * The VPC networks associated with this hub's spokes.
      +   * Output only. The VPC networks associated with this hub's spokes.
          *
          * This field is read-only. Network Connectivity Center automatically
          * populates it based on the set of spokes attached to the hub.
          * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ int getRoutingVpcsCount(); @@ -341,13 +347,15 @@ java.lang.String getLabelsOrDefault( * * *
      -   * The VPC networks associated with this hub's spokes.
      +   * Output only. The VPC networks associated with this hub's spokes.
          *
          * This field is read-only. Network Connectivity Center automatically
          * populates it based on the set of spokes attached to the hub.
          * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ java.util.List getRoutingVpcsOrBuilderList(); @@ -356,13 +364,15 @@ java.lang.String getLabelsOrDefault( * * *
      -   * The VPC networks associated with this hub's spokes.
      +   * Output only. The VPC networks associated with this hub's spokes.
          *
          * This field is read-only. Network Connectivity Center automatically
          * populates it based on the set of spokes attached to the hub.
          * 
      * - * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10; + * + * repeated .google.cloud.networkconnectivity.v1.RoutingVPC routing_vpcs = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.cloud.networkconnectivity.v1.RoutingVPCOrBuilder getRoutingVpcsOrBuilder(int index); @@ -598,4 +608,51 @@ java.lang.String getLabelsOrDefault( * @return The exportPsc. */ boolean getExportPsc(); + + /** + * + * + *
      +   * Optional. Config for more granular control of Private Service Connect
      +   * transitivity.
      +   * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the exportPscConfig field is set. + */ + boolean hasExportPscConfig(); + + /** + * + * + *
      +   * Optional. Config for more granular control of Private Service Connect
      +   * transitivity.
      +   * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The exportPscConfig. + */ + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfig getExportPscConfig(); + + /** + * + * + *
      +   * Optional. Config for more granular control of Private Service Connect
      +   * transitivity.
      +   * 
      + * + * + * .google.cloud.networkconnectivity.v1.Hub.ExportPscConfig export_psc_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.networkconnectivity.v1.Hub.ExportPscConfigOrBuilder + getExportPscConfigOrBuilder(); } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubProto.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubProto.java index 74fb7d11b482..74a308be3448 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubProto.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/HubProto.java @@ -44,6 +44,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_networkconnectivity_v1_Hub_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_networkconnectivity_v1_Hub_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_Hub_ExportPscConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_Hub_ExportPscConfig_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_networkconnectivity_v1_Hub_LabelsEntry_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -244,6 +248,46 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_networkconnectivity_v1_LinkedVpcNetwork_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_networkconnectivity_v1_LinkedVpcNetwork_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_Gateway_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_Gateway_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_Gateway_IpRangeReservation_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_Gateway_IpRangeReservation_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_GatewayAdvertisedRoute_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_GatewayAdvertisedRoute_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_GatewayAdvertisedRoute_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_GatewayAdvertisedRoute_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_CreateGatewayAdvertisedRouteRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_CreateGatewayAdvertisedRouteRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_GetGatewayAdvertisedRouteRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_GetGatewayAdvertisedRouteRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_UpdateGatewayAdvertisedRouteRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_UpdateGatewayAdvertisedRouteRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_DeleteGatewayAdvertisedRouteRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_DeleteGatewayAdvertisedRouteRequest_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_networkconnectivity_v1_LinkedProducerVpcNetwork_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -272,6 +316,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_networkconnectivity_v1_NextHopInterconnectAttachment_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_networkconnectivity_v1_NextHopInterconnectAttachment_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_networkconnectivity_v1_NextHopSpoke_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_networkconnectivity_v1_NextHopSpoke_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_networkconnectivity_v1_SpokeSummary_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -313,7 +361,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "o\032\031google/api/resource.proto\0320google/clo" + "ud/networkconnectivity/v1/common.proto\032#" + "google/longrunning/operations.proto\032\033google/protobuf/empty.proto\032" - + " google/protobuf/field_mask.proto\032\037google/protobuf/timestamp.proto\"\317\006\n" + + " google/protobuf/field_mask.proto\032\037google/protobuf/timestamp.proto\"\362\010\n" + "\003Hub\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\005\0225\n" + "\013create_time\030\002" @@ -325,49 +373,60 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013description\030\005 \001(\tB\004\342A\001\001\022\027\n" + "\tunique_id\030\010 \001(\tB\004\342A\001\003\022?\n" + "\005state\030\t" - + " \001(\0162*.google.cloud.networkconnectivity.v1.StateB\004\342A\001\003\022E\n" + + " \001(\0162*.google.cloud.networkconnectivity.v1.StateB\004\342A\001\003\022K\n" + "\014routing_vpcs\030\n" - + " \003(\0132/.google.cloud.networkconnectivity.v1.RoutingVPC\022\032\n" + + " \003(\0132/" + + ".google.cloud.networkconnectivity.v1.RoutingVPCB\004\342A\001\003\022\032\n" + "\014route_tables\030\013 \003(\tB\004\342A\001\003\022N\n\r" - + "spoke_summary\030\014" - + " \001(\01321.google.cloud.networkconnectivity.v1.SpokeSummaryB\004\342A\001\003\022J\n" + + "spoke_summary\030\014 \001(\01321.google.cloud." + + "networkconnectivity.v1.SpokeSummaryB\004\342A\001\003\022J\n" + "\013policy_mode\030\r" + " \001(\0162/.google.cloud.networkconnectivity.v1.PolicyModeB\004\342A\001\001\022R\n" - + "\017preset_topology\030\016" - + " \001(\01623.google.cloud.networkconnectivity.v1.PresetTopologyB\004\342A\001\001\022\035\n\n" - + "export_psc\030\017 \001(\010B\004\342A\001\001H\000\210\001\001\032-\n" + + "\017preset_topology\030\016 \001(\01623.google.cloud.ne" + + "tworkconnectivity.v1.PresetTopologyB\004\342A\001\001\022\035\n\n" + + "export_psc\030\017 \001(\010B\004\342A\001\001H\000\210\001\001\022Y\n" + + "\021export_psc_config\030\021 \001(\01328.google.cloud.netwo" + + "rkconnectivity.v1.Hub.ExportPscConfigB\004\342A\001\001\032\277\001\n" + + "\017ExportPscConfig\022>\n" + + "+published_services_and_regional_google_apis\030\001" + + " \001(\010B\004\342A\001\001H\000\210\001\001\022%\n" + + "\022global_google_apis\030\002 \001(\010B\004\342A\001\001H\001\210\001\001B.\n" + + ",_published_services_and_regional_google_apisB\025\n" + + "\023_global_google_apis\032-\n" + "\013LabelsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001:[\352AX\n" - + "&networkconnectivity.googleapis.com/Hub\022." - + "projects/{project}/locations/global/hubs/{hub}B\r\n" + + "&networkconnectivity.googleapi" + + "s.com/Hub\022.projects/{project}/locations/global/hubs/{hub}B\r\n" + "\013_export_psc\"\200\001\n\n" + "RoutingVPC\0220\n" + "\003uri\030\001 \001(\tB#\372A \n" + "\036compute.googleapis.com/Network\022@\n" + "2required_for_new_site_to_site_data_transfer_spokes\030\002" - + " \001(\010B\004\342A\001\003\"\326\014\n" + + " \001(\010B\004\342A\001\003\"\233\r\n" + "\005Spoke\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\005\0225\n" + "\013create_time\030\002" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\003" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022F\n" - + "\006labels\030\004 \003(\01326.google.cl" - + "oud.networkconnectivity.v1.Spoke.LabelsEntry\022\031\n" + + "\006labels\030\004 \003(\0132" + + "6.google.cloud.networkconnectivity.v1.Spoke.LabelsEntry\022\031\n" + "\013description\030\005 \001(\tB\004\342A\001\001\022<\n" + "\003hub\030\006 \001(\tB/\342A\001\005\372A(\n" + "&networkconnectivity.googleapis.com/Hub\022@\n" + "\005group\030\027 \001(\tB1\342A\001\001\372A*\n" + "(networkconnectivity.googleapis.com/Group\022W\n" - + "\022linked_vpn_tunnels\030\021 \001(\01325.google.clo" - + "ud.networkconnectivity.v1.LinkedVpnTunnelsB\004\342A\001\001\022q\n" - + "\037linked_interconnect_attachments\030\022 \001(\0132B.google.cloud.networkconnecti" - + "vity.v1.LinkedInterconnectAttachmentsB\004\342A\001\001\022t\n" - + "!linked_router_appliance_instances\030\023 \001(\0132C.google.cloud.networkconnectivit" - + "y.v1.LinkedRouterApplianceInstancesB\004\342A\001\001\022W\n" - + "\022linked_vpc_network\030\024 \001(\01325.google.c" - + "loud.networkconnectivity.v1.LinkedVpcNetworkB\004\342A\001\001\022h\n" + + "\022linked_vpn_tunnels\030\021 \001(\01325" + + ".google.cloud.networkconnectivity.v1.LinkedVpnTunnelsB\004\342A\001\001\022q\n" + + "\037linked_interconnect_attachments\030\022 \001(\0132B.google.cloud.netw" + + "orkconnectivity.v1.LinkedInterconnectAttachmentsB\004\342A\001\001\022t\n" + + "!linked_router_appliance_instances\030\023 \001(\0132C.google.cloud.network" + + "connectivity.v1.LinkedRouterApplianceInstancesB\004\342A\001\001\022W\n" + + "\022linked_vpc_network\030\024 \001(\013" + + "25.google.cloud.networkconnectivity.v1.LinkedVpcNetworkB\004\342A\001\001\022C\n" + + "\007gateway\030\030 \001(\0132," + + ".google.cloud.networkconnectivity.v1.GatewayB\004\342A\001\001\022h\n" + "\033linked_producer_vpc_network\030\032" + " \001(\0132=.google.cloud.networkconnectivity.v1.LinkedProducerVpcNetworkB\004\342A\001\001\022\027\n" + "\tunique_id\030\013 \001(\tB\004\342A\001\003\022?\n" @@ -378,7 +437,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "spoke_type\030\026 \001(\0162..google.cloud" + ".networkconnectivity.v1.SpokeTypeB\004\342A\001\003\022\022\n" + "\004etag\030\033 \001(\tB\004\342A\001\001\022(\n" - + "\032field_paths_pending_update\030\034 \003(\tB\004\342A\001\001\032\233\002\n" + + "\032field_paths_pending_update\030\034 \003(\tB\004\342A\001\003\032\233\002\n" + "\013StateReason\022I\n" + "\004code\030\001" + " \001(\0162;.google.cloud.networkconnectivity.v1.Spoke.StateReason.Code\022\017\n" @@ -413,8 +472,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013LabelsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001:|\352Ay\n" - + "-networkconnectivity.googleapis.com/RouteTable\022Hprojects/{project}/locations/global" - + "/hubs/{hub}/routeTables/{route_table}\"\344\010\n" + + "-networkconnectivity.googleapis.com/RouteTa" + + "ble\022Hprojects/{project}/locations/global/hubs/{hub}/routeTables/{route_table}\"\265" + + "\t\n" + "\005Route\022\022\n" + "\004name\030\003 \001(\tB\004\342A\001\005\0225\n" + "\013create_time\030\004" @@ -442,33 +502,36 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\"next_hop_router_appliance_instance\030\017 \001(\0132C.google.cloud" + ".networkconnectivity.v1.NextHopRouterApplianceInstanceB\004\342A\001\005\022r\n" + " next_hop_interconnect_attachment\030\020 \001(\0132B.google.cloud.ne" - + "tworkconnectivity.v1.NextHopInterconnectAttachmentB\004\342A\001\005\032-\n" + + "tworkconnectivity.v1.NextHopInterconnectAttachmentB\004\342A\001\005\022O\n" + + "\016next_hop_spoke\030\022 \001(\013" + + "21.google.cloud.networkconnectivity.v1.NextHopSpokeB\004\342A\001\005\032-\n" + "\013LabelsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001:\212\001\352A\206\001\n" - + "+networkconnectivity.googleapis.com/HubRoute\022Wpro" - + "jects/{project}/locations/global/hubs/{h" - + "ub}/routeTables/{route_table}/routes/{route}\"\312\004\n" + + "+networkconnectivity.googleapis.com/HubRoute\022Wpr" + + "ojects/{project}/locations/global/hubs/{" + + "hub}/routeTables/{route_table}/routes/{route}\"\374\004\n" + "\005Group\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\005\0225\n" + "\013create_time\030\002" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + "\013update_time\030\003" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022L\n" - + "\006labels\030\004 \003(\013" - + "26.google.cloud.networkconnectivity.v1.Group.LabelsEntryB\004\342A\001\001\022\031\n" + + "\006labels\030\004 \003(" + + "\01326.google.cloud.networkconnectivity.v1.Group.LabelsEntryB\004\342A\001\001\022\031\n" + "\013description\030\005 \001(\tB\004\342A\001\001\022\021\n" + "\003uid\030\006 \001(\tB\004\342A\001\003\022?\n" - + "\005state\030\007 " - + "\001(\0162*.google.cloud.networkconnectivity.v1.StateB\004\342A\001\003\022J\n" - + "\013auto_accept\030\010 \001(\0132/.goo" - + "gle.cloud.networkconnectivity.v1.AutoAcceptB\004\342A\001\001\022\031\n" - + "\013route_table\030\t \001(\tB\004\342A\001\003\032-\n" + + "\005state\030\007" + + " \001(\0162*.google.cloud.networkconnectivity.v1.StateB\004\342A\001\003\022J\n" + + "\013auto_accept\030\010 \001(\0132/.go" + + "ogle.cloud.networkconnectivity.v1.AutoAcceptB\004\342A\001\001\022K\n" + + "\013route_table\030\t \001(\tB6\342A\001\003\372A/\n" + + "-networkconnectivity.googleapis.com/RouteTable\032-\n" + "\013LabelsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001:l\352Ai\n" - + "(networkconnectivity.googleapis" - + ".com/Group\022=projects/{project}/locations/global/hubs/{hub}/groups/{group}\"0\n\n" + + "(networkconnectivity.googleapis.com/Group\022=projects/{project" + + "}/locations/global/hubs/{hub}/groups/{group}\"0\n\n" + "AutoAccept\022\"\n" + "\024auto_accept_projects\030\001 \003(\tB\004\342A\001\001\"\226\001\n" + "\017ListHubsRequest\022:\n" @@ -489,14 +552,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006parent\030\001 \001(\tB*\342A\001\002\372A#\n" + "!locations.googleapis.com/Location\022\024\n" + "\006hub_id\030\002 \001(\tB\004\342A\001\002\022;\n" - + "\003hub\030\003 \001(\0132(.goo" - + "gle.cloud.networkconnectivity.v1.HubB\004\342A\001\002\022\030\n\n" + + "\003hub\030\003" + + " \001(\0132(.google.cloud.networkconnectivity.v1.HubB\004\342A\001\002\022\030\n\n" + "request_id\030\004 \001(\tB\004\342A\001\001\"\240\001\n" + "\020UpdateHubRequest\0225\n" + "\013update_mask\030\001" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022;\n" - + "\003hub\030\002 \001(\0132(." - + "google.cloud.networkconnectivity.v1.HubB\004\342A\001\002\022\030\n\n" + + "\003hub\030\002" + + " \001(\0132(.google.cloud.networkconnectivity.v1.HubB\004\342A\001\002\022\030\n\n" + "request_id\030\003 \001(\tB\004\342A\001\001\"k\n" + "\020DeleteHubRequest\022=\n" + "\004name\030\001 \001(\tB/\342A\001\002\372A(\n" @@ -510,8 +573,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "page_token\030\004 \001(\t\022\016\n" + "\006filter\030\005 \001(\t\022\020\n" + "\010order_by\030\006 \001(\t\022Q\n" - + "\004view\030\007 \001(\0162C.google.cloud.netw" - + "orkconnectivity.v1.ListHubSpokesRequest.SpokeView\"@\n" + + "\004view\030\007 \001(\0162C.google" + + ".cloud.networkconnectivity.v1.ListHubSpokesRequest.SpokeView\"@\n" + "\tSpokeView\022\032\n" + "\026SPOKE_VIEW_UNSPECIFIED\020\000\022\t\n" + "\005BASIC\020\001\022\014\n" @@ -529,22 +592,22 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010order_by\030\005 \001(\tB\004\342A\001\001\022\026\n" + "\010group_by\030\006 \001(\tB\004\342A\001\001\"\202\001\n" + "\026QueryHubStatusResponse\022O\n" - + "\022hub_status_entries\030\001 \003(\01323.googl" - + "e.cloud.networkconnectivity.v1.HubStatusEntry\022\027\n" + + "\022hub_status_entries\030\001 " + + "\003(\01323.google.cloud.networkconnectivity.v1.HubStatusEntry\022\027\n" + "\017next_page_token\030\002 \001(\t\"\214\001\n" + "\016HubStatusEntry\022\r\n" + "\005count\030\001 \001(\005\022\020\n" + "\010group_by\030\002 \001(\t\022Y\n" - + "\026psc_propagation_status\030\003 \001(\01329.goo" - + "gle.cloud.networkconnectivity.v1.PscPropagationStatus\"\322\003\n" + + "\026psc_propagation_status\030\003" + + " \001(\01329.google.cloud.networkconnectivity.v1.PscPropagationStatus\"\322\003\n" + "\024PscPropagationStatus\022\024\n" + "\014source_spoke\030\001 \001(\t\022\024\n" + "\014source_group\030\002 \001(\t\022\036\n" + "\026source_forwarding_rule\030\003 \001(\t\022\024\n" + "\014target_spoke\030\004 \001(\t\022\024\n" + "\014target_group\030\005 \001(\t\022L\n" - + "\004code\030\006" - + " \001(\0162>.google.cloud.networkconnectivity.v1.PscPropagationStatus.Code\022\017\n" + + "\004code\030\006 \001(\0162>.google.cloud.n" + + "etworkconnectivity.v1.PscPropagationStatus.Code\022\017\n" + "\007message\030\007 \001(\t\"\342\001\n" + "\004Code\022\024\n" + "\020CODE_UNSPECIFIED\020\000\022\t\n" @@ -578,8 +641,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\022UpdateSpokeRequest\0225\n" + "\013update_mask\030\001" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022?\n" - + "\005spoke\030\002" - + " \001(\0132*.google.cloud.networkconnectivity.v1.SpokeB\004\342A\001\002\022\030\n\n" + + "\005spoke\030\002 \001(\0132*.google" + + ".cloud.networkconnectivity.v1.SpokeB\004\342A\001\002\022\030\n\n" + "request_id\030\003 \001(\tB\004\342A\001\001\"o\n" + "\022DeleteSpokeRequest\022?\n" + "\004name\030\001 \001(\tB1\342A\001\002\372A*\n" @@ -646,8 +709,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006filter\030\004 \001(\t\022\020\n" + "\010order_by\030\005 \001(\t\"\216\001\n" + "\027ListRouteTablesResponse\022E\n" - + "\014route_tables\030\001" - + " \003(\0132/.google.cloud.networkconnectivity.v1.RouteTable\022\027\n" + + "\014route_tables\030\001 \003(\0132/." + + "google.cloud.networkconnectivity.v1.RouteTable\022\027\n" + "\017next_page_token\030\002 \001(\t\022\023\n" + "\013unreachable\030\003 \003(\t\"\235\001\n" + "\021ListGroupsRequest\022?\n" @@ -660,37 +723,141 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\022ListGroupsResponse\022:\n" + "\006groups\030\001 \003(\0132*.google.cloud.networkconnectivity.v1.Group\022\027\n" + "\017next_page_token\030\002 \001(\t\022\023\n" - + "\013unreachable\030\003 \003(\t\"\316\001\n" + + "\013unreachable\030\003 \003(\t\"\365\003\n" + "\020LinkedVpnTunnels\0223\n" + "\004uris\030\001 \003(\tB%\372A\"\n" + " compute.googleapis.com/VpnTunnel\022\"\n" + "\032site_to_site_data_transfer\030\002 \001(\010\022<\n" + "\013vpc_network\030\003 \001(\tB\'\342A\001\003\372A \n" + "\036compute.googleapis.com/Network\022#\n" - + "\025include_import_ranges\030\005 \003(\tB\004\342A\001\001\"\350\001\n" + + "\025include_import_ranges\030\005 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_include_import_ranges\030\013 \003(\tB\004\342A\001\003\022#\n" + + "\025exclude_import_ranges\030\006 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_exclude_import_ranges\030\014 \003(\tB\004\342A\001\003\022#\n" + + "\025include_export_ranges\030\007 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_include_export_ranges\030\t \003(\tB\004\342A\001\003\022#\n" + + "\025exclude_export_ranges\030\010 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_exclude_export_ranges\030\n" + + " \003(\tB\004\342A\001\003\"\217\004\n" + "\035LinkedInterconnectAttachments\022@\n" + "\004uris\030\001 \003(\tB2\372A/\n" + "-compute.googleapis.com/InterconnectAttachment\022\"\n" + "\032site_to_site_data_transfer\030\002 \001(\010\022<\n" + "\013vpc_network\030\003 \001(\tB\'\342A\001\003\372A \n" + "\036compute.googleapis.com/Network\022#\n" - + "\025include_import_ranges\030\005 \003(\tB\004\342A\001\001\"\370\001\n" + + "\025include_import_ranges\030\005 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_include_import_ranges\030\013 \003(\tB\004\342A\001\003\022#\n" + + "\025exclude_import_ranges\030\006 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_exclude_import_ranges\030\014 \003(\tB\004\342A\001\003\022#\n" + + "\025include_export_ranges\030\007 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_include_export_ranges\030\t \003(\tB\004\342A\001\003\022#\n" + + "\025exclude_export_ranges\030\010 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_exclude_export_ranges\030\n" + + " \003(\tB\004\342A\001\003\"\237\004\n" + "\036LinkedRouterApplianceInstances\022O\n" - + "\tinstances\030\001 \003(\0132<.google.clo" - + "ud.networkconnectivity.v1.RouterApplianceInstance\022\"\n" + + "\tinstances\030\001 \003(\0132<.google.cl" + + "oud.networkconnectivity.v1.RouterApplianceInstance\022\"\n" + "\032site_to_site_data_transfer\030\002 \001(\010\022<\n" + "\013vpc_network\030\003 \001(\tB\'\342A\001\003\372A \n" + "\036compute.googleapis.com/Network\022#\n" - + "\025include_import_ranges\030\005 \003(\tB\004\342A\001\001\"\276\002\n" + + "\025include_import_ranges\030\005 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_include_import_ranges\030\013 \003(\tB\004\342A\001\003\022#\n" + + "\025exclude_import_ranges\030\006 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_exclude_import_ranges\030\014 \003(\tB\004\342A\001\003\022#\n" + + "\025include_export_ranges\030\007 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_include_export_ranges\030\t \003(\tB\004\342A\001\003\022#\n" + + "\025exclude_export_ranges\030\010 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_exclude_export_ranges\030\n" + + " \003(\tB\004\342A\001\003\"\276\002\n" + "\020LinkedVpcNetwork\0224\n" + "\003uri\030\001 \001(\tB\'\342A\001\002\372A \n" + "\036compute.googleapis.com/Network\022#\n" + "\025exclude_export_ranges\030\002 \003(\tB\004\342A\001\001\022#\n" + "\025include_export_ranges\030\003 \003(\tB\004\342A\001\001\022,\n" - + "\036proposed_include_export_ranges\030\005 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_include_export_ranges\030\005 \003(\tB\004\342A\001\003\022,\n" + "\036proposed_exclude_export_ranges\030\006 \003(\tB\004\342A\001\003\022N\n" + "\023producer_vpc_spokes\030\004 \003(\tB1\342A\001\003\372A*\n" - + "(networkconnectivity.googleapis.com/Spoke\"\253\003\n" + + "(networkconnectivity.googleapis.com/Spoke\"\277\003\n" + + "\007Gateway\022d\n" + + "\025ip_range_reservations\030\007" + + " \003(\0132?.google.cloud.networkconnectivity.v1.Gateway.IpRangeReservationB\004\342A\001\001\022T\n" + + "\010capacity\030\n" + + " \001(\0162<.google.cloud.networkconn" + + "ectivity.v1.Gateway.GatewayCapacityB\004\342A\001\001\022\033\n\r" + + "cloud_routers\030\r" + + " \003(\tB\004\342A\001\003\022M\n" + + "\016sac_attachment\030\016 \001(\tB5\342A\001\003\372A.\n" + + ",networksecurity.googleapis.com/SACAttachment\032,\n" + + "\022IpRangeReservation\022\026\n" + + "\010ip_range\030\001 \001(\tB\004\342A\001\002\"^\n" + + "\017GatewayCapacity\022 \n" + + "\034GATEWAY_CAPACITY_UNSPECIFIED\020\000\022\023\n" + + "\017CAPACITY_1_GBPS\020\005\022\024\n" + + "\020CAPACITY_10_GBPS\020\001\"\317\006\n" + + "\026GatewayAdvertisedRoute\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\0225\n" + + "\013create_time\030\002" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + + "\013update_time\030\003" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022W\n" + + "\006labels\030\004 \003(\0132G.google.cloud." + + "networkconnectivity.v1.GatewayAdvertisedRoute.LabelsEntry\022\023\n" + + "\013description\030\005 \001(\t\022\027\n" + + "\tunique_id\030\006 \001(\tB\004\342A\001\003\022?\n" + + "\005state\030\007 \001(\0162*" + + ".google.cloud.networkconnectivity.v1.StateB\004\342A\001\003\022\026\n" + + "\010ip_range\030\010 \001(\tB\004\342A\001\005\022\033\n" + + "\010priority\030\t \001(\005B\004\342A\001\001H\000\210\001\001\022^\n" + + "\trecipient\030\n" + + " \001(\016" + + "2E.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.RecipientB\004\342A\001\001\032-\n" + + "\013LabelsEntry\022\013\n" + + "\003key\030\001 \001(\t\022\r\n" + + "\005value\030\002 \001(\t:\0028\001\"<\n" + + "\tRecipient\022\031\n" + + "\025RECIPIENT_UNSPECIFIED\020\000\022\024\n" + + "\020ADVERTISE_TO_HUB\020\001:\333\001\352A\327\001\n" + + "9networkconnectivity.googleapis.com/GatewayAdv" + + "ertisedRoute\022iprojects/{project}/locations/{location}/spokes/{spoke}/gatewayAdve" + + "rtisedRoutes/{gateway_advertised_route}*" + + "\027gatewayAdvertisedRoutes2\026gatewayAdvertisedRouteB\013\n" + + "\t_priority\"\232\002\n" + + "#CreateGatewayAdvertisedRouteRequest\022A\n" + + "\006parent\030\001 \001(\tB1\342A\001\002\372A*\n" + + "(networkconnectivity.googleapis.com/Spoke\022)\n" + + "\033gateway_advertised_route_id\030\002 \001(\tB\004\342A\001\002\022c\n" + + "\030gateway_advertised_route\030\003" + + " \001(\0132;.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteB\004\342A\001\002\022" + + " \n\n" + + "request_id\030\004 \001(\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"t\n" + + " GetGatewayAdvertisedRouteRequest\022P\n" + + "\004name\030\001 \001(\tBB\342A\001\002\372A;\n" + + "9networkconnectivity.googleapis.com/GatewayAdvertisedRoute\"\274\001\n" + + "\"ListGatewayAdvertisedRoutesRequest\022A\n" + + "\006parent\030\001 \001(\tB1\342A\001\002\372A*\n" + + "(networkconnectivity.googleapis.com/Spoke\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\022\016\n" + + "\006filter\030\004 \001(\t\022\020\n" + + "\010order_by\030\005 \001(\t\"\263\001\n" + + "#ListGatewayAdvertisedRoutesResponse\022^\n" + + "\031gateway_advertised_routes\030\001" + + " \003(\0132;.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute\022\027\n" + + "\017next_page_token\030\002 \001(\t\022\023\n" + + "\013unreachable\030\003 \003(\t\"\343\001\n" + + "#UpdateGatewayAdvertisedRouteRequest\0225\n" + + "\013update_mask\030\001" + + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022c\n" + + "\030gateway_advertised_route\030\002" + + " \001(\0132;.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteB\004\342A\001\002\022" + + " \n\n" + + "request_id\030\003 \001(" + + "\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"\231\001\n" + + "#DeleteGatewayAdvertisedRouteRequest\022P\n" + + "\004name\030\001 \001(\tBB\342A\001\002\372A;\n" + + "9networkconnectivity.googleapis.com/GatewayAdvertisedRoute\022 \n\n" + + "request_id\030\002 \001(" + + "\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"\253\003\n" + "\030LinkedProducerVpcNetwork\0228\n" + "\007network\030\001 \001(\tB\'\342A\001\005\372A \n" + "\036compute.googleapis.com/Network\022U\n" @@ -701,11 +868,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\036compute.googleapis.com/Network\022#\n" + "\025exclude_export_ranges\030\003 \003(\tB\004\342A\001\001\022#\n" + "\025include_export_ranges\030\004 \003(\tB\004\342A\001\001\022,\n" - + "\036proposed_include_export_ranges\030\007 \003(\tB\004\342A\001\001\022,\n" + + "\036proposed_include_export_ranges\030\007 \003(\tB\004\342A\001\003\022,\n" + "\036proposed_exclude_export_ranges\030\010 \003(\tB\004\342A\001\003\"l\n" + "\027RouterApplianceInstance\022=\n" + "\017virtual_machine\030\001 \001(\tB$\372A!\n" - + "\037compute.googleapis.com/Instance\022\022\n\n" + + "\037compute.", + "googleapis.com/Instance\022\022\n\n" + "ip_address\030\003 \001(\t\"c\n" + "\020LocationMetadata\022O\n" + "\021location_features\030\001" @@ -730,25 +898,30 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "-compute.googleapis.com/InterconnectAttachment\0228\n" + "\013vpc_network\030\002 \001(\tB#\372A \n" + "\036compute.googleapis.com/Network\022\"\n" - + "\032site_to_site_data_transfer\030\003 \001(\010\"\257\005\n" + + "\032site_to_site_data_transfer\030\003 \001(\010\"n\n" + + "\014NextHopSpoke\022:\n" + + "\003uri\030\001 \001(\tB-\372A*\n" + + "(networkconnectivity.googleapis.com/Spoke\022\"\n" + + "\032site_to_site_data_transfer\030\002 \001(\010\"\257\005\n" + "\014SpokeSummary\022a\n" - + "\021spoke_type_counts\030\001 \003(" - + "\0132@.google.cloud.networkconnectivity.v1.SpokeSummary.SpokeTypeCountB\004\342A\001\003\022c\n" - + "\022spoke_state_counts\030\002 \003(\0132A.google.cloud.net" - + "workconnectivity.v1.SpokeSummary.SpokeStateCountB\004\342A\001\003\022p\n" - + "\031spoke_state_reason_counts\030\003 \003(\0132G.google.cloud.networkconnecti" - + "vity.v1.SpokeSummary.SpokeStateReasonCountB\004\342A\001\003\032o\n" + + "\021spoke_type_counts\030\001 \003(\0132@.google" + + ".cloud.networkconnectivity.v1.SpokeSummary.SpokeTypeCountB\004\342A\001\003\022c\n" + + "\022spoke_state_counts\030\002 \003(\0132A.google.cloud.networkconnec" + + "tivity.v1.SpokeSummary.SpokeStateCountB\004\342A\001\003\022p\n" + + "\031spoke_state_reason_counts\030\003 \003(\0132" + + "G.google.cloud.networkconnectivity.v1.Sp" + + "okeSummary.SpokeStateReasonCountB\004\342A\001\003\032o\n" + "\016SpokeTypeCount\022H\n\n" - + "spoke_type\030\001" - + " \001(\0162..google.cloud.networkconnectivity.v1.SpokeTypeB\004\342A\001\003\022\023\n" + + "spoke_type\030\001 \001(\0162..g" + + "oogle.cloud.networkconnectivity.v1.SpokeTypeB\004\342A\001\003\022\023\n" + "\005count\030\002 \001(\003B\004\342A\001\003\032g\n" + "\017SpokeStateCount\022?\n" - + "\005state\030\001 \001(\0162*.go" - + "ogle.cloud.networkconnectivity.v1.StateB\004\342A\001\003\022\023\n" + + "\005state\030\001" + + " \001(\0162*.google.cloud.networkconnectivity.v1.StateB\004\342A\001\003\022\023\n" + "\005count\030\002 \001(\003B\004\342A\001\003\032\212\001\n" + "\025SpokeStateReasonCount\022\\\n" - + "\021state_reason_code\030\001 \001(\0162" - + ";.google.cloud.networkconnectivity.v1.Spoke.StateReason.CodeB\004\342A\001\003\022\023\n" + + "\021state_reason_code\030\001 \001(\0162;.google.c" + + "loud.networkconnectivity.v1.Spoke.StateReason.CodeB\004\342A\001\003\022\023\n" + "\005count\030\002 \001(\003B\004\342A\001\003\"R\n" + "\017GetGroupRequest\022?\n" + "\004name\030\001 \001(\tB1\342A\001\002\372A*\n" @@ -758,16 +931,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022?\n" + "\005group\030\002" + " \001(\0132*.google.cloud.networkconnectivity.v1.GroupB\004\342A\001\002\022\030\n\n" - + "request_id\030\003 \001(\tB\004\342A\001\001*f\n" - + "\017LocationFeature\022 \n" - + "\034LOCATION_FEATURE_UNSPECIFIED\020\000\022\030\n" - + "\024SITE_TO_CLOUD_SPOKES\020\001\022\027\n" - + "\023SITE_TO_SITE_SPOKES\020\002*l\n" + + "request_id\030\003 \001(\tB\004\342A\001\001*\201\001\n" + "\tRouteType\022\032\n" + "\026ROUTE_TYPE_UNSPECIFIED\020\000\022\026\n" + "\022VPC_PRIMARY_SUBNET\020\001\022\030\n" + "\024VPC_SECONDARY_SUBNET\020\002\022\021\n\r" - + "DYNAMIC_ROUTE\020\003*\232\001\n" + + "DYNAMIC_ROUTE\020\003\022\023\n" + + "\017PSC_GLOBAL_GAPI\020\004*\232\001\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\014\n" + "\010CREATING\020\001\022\n\n" @@ -779,150 +949,168 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010INACTIVE\020\007\022\014\n" + "\010OBSOLETE\020\n" + "\022\n\n" - + "\006FAILED\020\013*\225\001\n" + + "\006FAILED\020\013*\242\001\n" + "\tSpokeType\022\032\n" + "\026SPOKE_TYPE_UNSPECIFIED\020\000\022\016\n\n" + "VPN_TUNNEL\020\001\022\033\n" + "\027INTERCONNECT_ATTACHMENT\020\002\022\024\n" + "\020ROUTER_APPLIANCE\020\003\022\017\n" - + "\013VPC_NETWORK\020\004\022\030\n" + + "\013VPC_NETWORK\020\004\022\013\n" + + "\007GATEWAY\020\005\022\030\n" + "\024PRODUCER_VPC_NETWORK\020\007*5\n\n" + "PolicyMode\022\033\n" + "\027POLICY_MODE_UNSPECIFIED\020\000\022\n\n" - + "\006PRESET\020\001*E\n" + + "\006PRESET\020\001*\\\n" + "\016PresetTopology\022\037\n" + "\033PRESET_TOPOLOGY_UNSPECIFIED\020\000\022\010\n" + "\004MESH\020\002\022\010\n" - + "\004STAR\020\0032\360&\n\n" + + "\004STAR\020\003\022\025\n" + + "\021HYBRID_INSPECTION\020\004*\212\001\n" + + "\017LocationFeature\022 \n" + + "\034LOCATION_FEATURE_UNSPECIFIED\020\000\022\030\n" + + "\024SITE_TO_CLOUD_SPOKES\020\001\022\027\n" + + "\023SITE_TO_SITE_SPOKES\020\002\022\022\n" + + "\016GATEWAY_SPOKES\020\003\022\016\n\n" + + "TRANSPORTS\020\0042\2762\n\n" + "HubService\022\267\001\n" - + "\010ListHubs\0224.google.cloud.networkconnectivity.v1.ListHubsRequest\0325.google" - + ".cloud.networkconnectivity.v1.ListHubsRe" - + "sponse\">\332A\006parent\202\323\344\223\002/\022-/v1/{parent=projects/*/locations/global}/hubs\022\244\001\n" - + "\006GetHub\0222.google.cloud.networkconnectivity.v1." - + "GetHubRequest\032(.google.cloud.networkconn" - + "ectivity.v1.Hub\"<\332A\004name\202\323\344\223\002/\022-/v1/{nam" - + "e=projects/*/locations/global/hubs/*}\022\314\001\n" - + "\tCreateHub\0225.google.cloud.networkconnec" - + "tivity.v1.CreateHubRequest\032\035.google.longrunning.Operation\"i\312A\030\n" - + "\003Hub\022\021OperationMe" - + "tadata\332A\021parent,hub,hub_id\202\323\344\223\0024\"-/v1/{p" - + "arent=projects/*/locations/global}/hubs:\003hub\022\316\001\n" - + "\tUpdateHub\0225.google.cloud.networ" - + "kconnectivity.v1.UpdateHubRequest\032\035.google.longrunning.Operation\"k\312A\030\n" - + "\003Hub\022\021OperationMetadata\332A\017hub,update_mask\202\323\344\223\002821/" - + "v1/{hub.name=projects/*/locations/global/hubs/*}:\003hub\022\314\001\n" - + "\tDeleteHub\0225.google.clo" - + "ud.networkconnectivity.v1.DeleteHubRequest\032\035.google.longrunning.Operation\"i\312A*\n" - + "\025google.protobuf.Empty\022\021OperationMetadata" - + "\332A\004name\202\323\344\223\002/*-/v1/{name=projects/*/locations/global/hubs/*}\022\317\001\n\r" - + "ListHubSpokes\0229.google.cloud.networkconnectivity.v1.Lis" - + "tHubSpokesRequest\032:.google.cloud.network" - + "connectivity.v1.ListHubSpokesResponse\"G\332" - + "A\004name\202\323\344\223\002:\0228/v1/{name=projects/*/locations/global/hubs/*}:listSpokes\022\323\001\n" - + "\016QueryHubStatus\022:.google.cloud.networkconnecti" - + "vity.v1.QueryHubStatusRequest\032;.google.cloud.networkconnectivity.v1.QueryHubStat" - + "usResponse\"H\332A\004name\202\323\344\223\002;\0229/v1/{name=pro" - + "jects/*/locations/global/hubs/*}:queryStatus\022\272\001\n\n" - + "ListSpokes\0226.google.cloud.networkconnectivity.v1.ListSpokesRequest\0327.go", - "ogle.cloud.networkconnectivity.v1.ListSp" - + "okesResponse\";\332A\006parent\202\323\344\223\002,\022*/v1/{pare" - + "nt=projects/*/locations/*}/spokes\022\247\001\n\010Ge" - + "tSpoke\0224.google.cloud.networkconnectivit" - + "y.v1.GetSpokeRequest\032*.google.cloud.netw" - + "orkconnectivity.v1.Spoke\"9\332A\004name\202\323\344\223\002,\022" - + "*/v1/{name=projects/*/locations/*/spokes" - + "/*}\022\325\001\n\013CreateSpoke\0227.google.cloud.netwo" - + "rkconnectivity.v1.CreateSpokeRequest\032\035.g" - + "oogle.longrunning.Operation\"n\312A\032\n\005Spoke\022" - + "\021OperationMetadata\332A\025parent,spoke,spoke_" - + "id\202\323\344\223\0023\"*/v1/{parent=projects/*/locatio" - + "ns/*}/spokes:\005spoke\022\327\001\n\013UpdateSpoke\0227.go" - + "ogle.cloud.networkconnectivity.v1.Update" - + "SpokeRequest\032\035.google.longrunning.Operat" - + "ion\"p\312A\032\n\005Spoke\022\021OperationMetadata\332A\021spo" - + "ke,update_mask\202\323\344\223\002920/v1/{spoke.name=pr" - + "ojects/*/locations/*/spokes/*}:\005spoke\022\361\001" - + "\n\016RejectHubSpoke\022:.google.cloud.networkc" - + "onnectivity.v1.RejectHubSpokeRequest\032\035.g" - + "oogle.longrunning.Operation\"\203\001\312A+\n\026Rejec" - + "tHubSpokeResponse\022\021OperationMetadata\332A\016n" - + "ame,spoke_uri\202\323\344\223\002>\"9/v1/{name=projects/" - + "*/locations/global/hubs/*}:rejectSpoke:\001" - + "*\022\361\001\n\016AcceptHubSpoke\022:.google.cloud.netw" - + "orkconnectivity.v1.AcceptHubSpokeRequest" - + "\032\035.google.longrunning.Operation\"\203\001\312A+\n\026A" - + "cceptHubSpokeResponse\022\021OperationMetadata" - + "\332A\016name,spoke_uri\202\323\344\223\002>\"9/v1/{name=proje" - + "cts/*/locations/global/hubs/*}:acceptSpo" - + "ke:\001*\022\213\002\n\021AcceptSpokeUpdate\022=.google.clo" - + "ud.networkconnectivity.v1.AcceptSpokeUpd" - + "ateRequest\032\035.google.longrunning.Operatio" - + "n\"\227\001\312A.\n\031AcceptSpokeUpdateResponse\022\021Oper" - + "ationMetadata\332A\031name,spoke_uri,spoke_eta" - + "g\202\323\344\223\002D\"?/v1/{name=projects/*/locations/" - + "global/hubs/*}:acceptSpokeUpdate:\001*\022\213\002\n\021" - + "RejectSpokeUpdate\022=.google.cloud.network" - + "connectivity.v1.RejectSpokeUpdateRequest" - + "\032\035.google.longrunning.Operation\"\227\001\312A.\n\031R" - + "ejectSpokeUpdateResponse\022\021OperationMetad" - + "ata\332A\031name,spoke_uri,spoke_etag\202\323\344\223\002D\"?/" - + "v1/{name=projects/*/locations/global/hub" - + "s/*}:rejectSpokeUpdate:\001*\022\315\001\n\013DeleteSpok" - + "e\0227.google.cloud.networkconnectivity.v1." - + "DeleteSpokeRequest\032\035.google.longrunning." - + "Operation\"f\312A*\n\025google.protobuf.Empty\022\021O" - + "perationMetadata\332A\004name\202\323\344\223\002,**/v1/{name" - + "=projects/*/locations/*/spokes/*}\022\307\001\n\rGe" - + "tRouteTable\0229.google.cloud.networkconnec" - + "tivity.v1.GetRouteTableRequest\032/.google." - + "cloud.networkconnectivity.v1.RouteTable\"" - + "J\332A\004name\202\323\344\223\002=\022;/v1/{name=projects/*/loc" - + "ations/global/hubs/*/routeTables/*}\022\301\001\n\010" - + "GetRoute\0224.google.cloud.networkconnectiv" - + "ity.v1.GetRouteRequest\032*.google.cloud.ne" - + "tworkconnectivity.v1.Route\"S\332A\004name\202\323\344\223\002" - + "F\022D/v1/{name=projects/*/locations/global" - + "/hubs/*/routeTables/*/routes/*}\022\324\001\n\nList" - + "Routes\0226.google.cloud.networkconnectivit" - + "y.v1.ListRoutesRequest\0327.google.cloud.ne" - + "tworkconnectivity.v1.ListRoutesResponse\"" - + "U\332A\006parent\202\323\344\223\002F\022D/v1/{parent=projects/*" - + "/locations/global/hubs/*/routeTables/*}/" - + "routes\022\332\001\n\017ListRouteTables\022;.google.clou" - + "d.networkconnectivity.v1.ListRouteTables" - + "Request\032<.google.cloud.networkconnectivi" - + "ty.v1.ListRouteTablesResponse\"L\332A\006parent" - + "\202\323\344\223\002=\022;/v1/{parent=projects/*/locations" - + "/global/hubs/*}/routeTables\022\263\001\n\010GetGroup" - + "\0224.google.cloud.networkconnectivity.v1.G" - + "etGroupRequest\032*.google.cloud.networkcon" - + "nectivity.v1.Group\"E\332A\004name\202\323\344\223\0028\0226/v1/{" - + "name=projects/*/locations/global/hubs/*/" - + "groups/*}\022\306\001\n\nListGroups\0226.google.cloud." - + "networkconnectivity.v1.ListGroupsRequest" + + "\010ListHubs\0224.google.cloud.networkconnectivity.v1.ListHubsRequest\0325.g" + + "oogle.cloud.networkconnectivity.v1.ListH" + + "ubsResponse\">\332A\006parent\202\323\344\223\002/\022-/v1/{parent=projects/*/locations/global}/hubs\022\244\001\n" + + "\006GetHub\0222.google.cloud.networkconnectivit" + + "y.v1.GetHubRequest\032(.google.cloud.networ" + + "kconnectivity.v1.Hub\"<\332A\004name\202\323\344\223\002/\022-/v1" + + "/{name=projects/*/locations/global/hubs/*}\022\314\001\n" + + "\tCreateHub\0225.google.cloud.networkc" + + "onnectivity.v1.CreateHubRequest\032\035.google.longrunning.Operation\"i\312A\030\n" + + "\003Hub\022\021OperationMetadata\332A\021parent,hub,hub_id\202\323\344\223\0024\"-/" + + "v1/{parent=projects/*/locations/global}/hubs:\003hub\022\316\001\n" + + "\tUpdateHub\0225.google.cloud.n" + + "etworkconnectivity.v1.UpdateHubRequest\032\035.google.longrunning.Operation\"k\312A\030\n" + + "\003Hub\022\021OperationMetadata\332A\017hub,update_mask\202\323\344\223" + + "\002821/v1/{hub.name=projects/*/locations/global/hubs/*}:\003hub\022\314\001\n" + + "\tDeleteHub\0225.google.cloud.networkconnectivity.v1.DeleteHub" + + "Request\032\035.google.longrunning.Operation\"i\312A*\n" + + "\025google.protobuf.Empty\022\021OperationMet" + + "adata\332A\004name\202\323\344\223\002/*-/v1/{name=projects/*/locations/global/hubs/*}\022\317\001\n\r" + + "ListHubSpokes\0229.google.cloud.networkconnectivity.v" + + "1.ListHubSpokesRequest\032:.google.cloud.networkconnectivity.v1.ListHubSpokesRespon" + + "se\"G\332A\004name\202\323\344\223\002:\0228/v1/{name=projects/*/locations/global/hubs/*}:listSpokes\022\323\001\n" + + "\016QueryHubStatus\022:.google.cloud.networkcon" + + "nectivity.v1.QueryHubStatusRequest\032;.google.cloud.networkconnectivity.v1.QueryHu" + + "bStatusResponse\"H\332A\004name\202\323\344\223\002;\0229/v1/{nam" + + "e=projects/*/locations/global/hubs/*}:queryStatus\022\272\001\n\n" + + "ListSpokes\0226.google.cloud.networkconnectivity.v1.ListSpokesRequest" + "\0327.google.cloud.networkconnectivity.v1.L" - + "istGroupsResponse\"G\332A\006parent\202\323\344\223\0028\0226/v1/" - + "{parent=projects/*/locations/global/hubs" - + "/*}/groups\022\343\001\n\013UpdateGroup\0227.google.clou" - + "d.networkconnectivity.v1.UpdateGroupRequ" - + "est\032\035.google.longrunning.Operation\"|\312A\032\n" - + "\005Group\022\021OperationMetadata\332A\021group,update" - + "_mask\202\323\344\223\002E2\"9/v1/{name=proj" + + "ects/*/locations/global/hubs/*}:rejectSpoke:\001*\022\361\001\n" + + "\016AcceptHubSpoke\022:.google.cloud.networkconnectivity.v1.AcceptHubSpokeRe" + + "quest\032\035.google.longrunning.Operation\"\203\001\312A+\n" + + "\026AcceptHubSpokeResponse\022\021OperationMet" + + "adata\332A\016name,spoke_uri\202\323\344\223\002>\"9/v1/{name=" + + "projects/*/locations/global/hubs/*}:acceptSpoke:\001*\022\213\002\n" + + "\021AcceptSpokeUpdate\022=.google.cloud.networkconnectivity.v1.AcceptSpo" + + "keUpdateRequest\032\035.google.longrunning.Operation\"\227\001\312A.\n" + + "\031AcceptSpokeUpdateResponse\022\021OperationMetadata\332A\031name,spoke_uri,spok" + + "e_etag\202\323\344\223\002D\"?/v1/{name=projects/*/locat" + + "ions/global/hubs/*}:acceptSpokeUpdate:\001*\022\213\002\n" + + "\021RejectSpokeUpdate\022=.google.cloud.networkconnectivity.v1.RejectSpokeUpdateRe" + + "quest\032\035.google.longrunning.Operation\"\227\001\312A.\n" + + "\031RejectSpokeUpdateResponse\022\021Operation" + + "Metadata\332A\031name,spoke_uri,spoke_etag\202\323\344\223" + + "\002D\"?/v1/{name=projects/*/locations/global/hubs/*}:rejectSpokeUpdate:\001*\022\315\001\n" + + "\013DeleteSpoke\0227.google.cloud.networkconnectivit" + + "y.v1.DeleteSpokeRequest\032\035.google.longrunning.Operation\"f\312A*\n" + + "\025google.protobuf.Emp" + + "ty\022\021OperationMetadata\332A\004name\202\323\344\223\002,**/v1/" + + "{name=projects/*/locations/*/spokes/*}\022\307\001\n\r" + + "GetRouteTable\0229.google.cloud.networkconnectivity.v1.GetRouteTableRequest\032/.go" + + "ogle.cloud.networkconnectivity.v1.RouteT" + + "able\"J\332A\004name\202\323\344\223\002=\022;/v1/{name=projects/" + + "*/locations/global/hubs/*/routeTables/*}\022\301\001\n" + + "\010GetRoute\0224.google.cloud.networkconnectivity.v1.GetRouteRequest\032*.google.clo" + + "ud.networkconnectivity.v1.Route\"S\332A\004name" + + "\202\323\344\223\002F\022D/v1/{name=projects/*/locations/global/hubs/*/routeTables/*/routes/*}\022\324\001\n" + + "\n" + + "ListRoutes\0226.google.cloud.networkconnectivity.v1.ListRoutesRequest\0327.google.clo" + + "ud.networkconnectivity.v1.ListRoutesResp" + + "onse\"U\332A\006parent\202\323\344\223\002F\022D/v1/{parent=proje" + + "cts/*/locations/global/hubs/*/routeTables/*}/routes\022\332\001\n" + + "\017ListRouteTables\022;.google.cloud.networkconnectivity.v1.ListRouteT" + + "ablesRequest\032<.google.cloud.networkconne" + + "ctivity.v1.ListRouteTablesResponse\"L\332A\006p" + + "arent\202\323\344\223\002=\022;/v1/{parent=projects/*/locations/global/hubs/*}/routeTables\022\263\001\n" + + "\010GetGroup\0224.google.cloud.networkconnectivity" + + ".v1.GetGroupRequest\032*.google.cloud.netwo" + + "rkconnectivity.v1.Group\"E\332A\004name\202\323\344\223\0028\0226" + + "/v1/{name=projects/*/locations/global/hubs/*/groups/*}\022\306\001\n\n" + + "ListGroups\0226.google.cloud.networkconnectivity.v1.ListGroupsRe" + + "quest\0327.google.cloud.networkconnectivity" + + ".v1.ListGroupsResponse\"G\332A\006parent\202\323\344\223\0028\022" + + "6/v1/{parent=projects/*/locations/global/hubs/*}/groups\022\343\001\n" + + "\013UpdateGroup\0227.google.cloud.networkconnectivity.v1.UpdateGrou" + + "pRequest\032\035.google.longrunning.Operation\"|\312A\032\n" + + "\005Group\022\021OperationMetadata\332A\021group,u" + + "pdate_mask\202\323\344\223\002E2 - * Optional. IP ranges allowed to be included during import from hub (does not - * control transit connectivity). The only allowed value for now is - * "ALL_IPV4_RANGES". + * Optional. Hub routes fully encompassed by include import ranges are + * included during import from hub. *
      * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -249,9 +255,8 @@ public com.google.protobuf.ProtocolStringList getIncludeImportRangesList() { * * *
      -   * Optional. IP ranges allowed to be included during import from hub (does not
      -   * control transit connectivity). The only allowed value for now is
      -   * "ALL_IPV4_RANGES".
      +   * Optional. Hub routes fully encompassed by include import ranges are
      +   * included during import from hub.
          * 
      * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -267,9 +272,8 @@ public int getIncludeImportRangesCount() { * * *
      -   * Optional. IP ranges allowed to be included during import from hub (does not
      -   * control transit connectivity). The only allowed value for now is
      -   * "ALL_IPV4_RANGES".
      +   * Optional. Hub routes fully encompassed by include import ranges are
      +   * included during import from hub.
          * 
      * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -286,9 +290,8 @@ public java.lang.String getIncludeImportRanges(int index) { * * *
      -   * Optional. IP ranges allowed to be included during import from hub (does not
      -   * control transit connectivity). The only allowed value for now is
      -   * "ALL_IPV4_RANGES".
      +   * Optional. Hub routes fully encompassed by include import ranges are
      +   * included during import from hub.
          * 
      * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -301,519 +304,2748 @@ public com.google.protobuf.ByteString getIncludeImportRangesBytes(int index) { return includeImportRanges_.getByteString(index); } - private byte memoizedIsInitialized = -1; + public static final int PROPOSED_INCLUDE_IMPORT_RANGES_FIELD_NUMBER = 11; - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedIncludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - memoizedIsInitialized = 1; - return true; + /** + * + * + *
      +   * Output only. The proposed include import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedIncludeImportRangesList() { + return proposedIncludeImportRanges_; } - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < uris_.size(); i++) { - com.google.protobuf.GeneratedMessage.writeString(output, 1, uris_.getRaw(i)); - } - if (siteToSiteDataTransfer_ != false) { - output.writeBool(2, siteToSiteDataTransfer_); - } - if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { - com.google.protobuf.GeneratedMessage.writeString(output, 3, vpcNetwork_); - } - for (int i = 0; i < includeImportRanges_.size(); i++) { - com.google.protobuf.GeneratedMessage.writeString(output, 5, includeImportRanges_.getRaw(i)); - } - getUnknownFields().writeTo(output); + /** + * + * + *
      +   * Output only. The proposed include import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeImportRanges. + */ + public int getProposedIncludeImportRangesCount() { + return proposedIncludeImportRanges_.size(); } - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - for (int i = 0; i < uris_.size(); i++) { - dataSize += computeStringSizeNoTag(uris_.getRaw(i)); - } - size += dataSize; - size += 1 * getUrisList().size(); - } - if (siteToSiteDataTransfer_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, siteToSiteDataTransfer_); - } - if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { - size += com.google.protobuf.GeneratedMessage.computeStringSize(3, vpcNetwork_); - } - { - int dataSize = 0; - for (int i = 0; i < includeImportRanges_.size(); i++) { - dataSize += computeStringSizeNoTag(includeImportRanges_.getRaw(i)); - } - size += dataSize; - size += 1 * getIncludeImportRangesList().size(); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; + /** + * + * + *
      +   * Output only. The proposed include import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeImportRanges at the given index. + */ + public java.lang.String getProposedIncludeImportRanges(int index) { + return proposedIncludeImportRanges_.get(index); } - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments)) { - return super.equals(obj); - } - com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments other = - (com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments) obj; - - if (!getUrisList().equals(other.getUrisList())) return false; - if (getSiteToSiteDataTransfer() != other.getSiteToSiteDataTransfer()) return false; - if (!getVpcNetwork().equals(other.getVpcNetwork())) return false; - if (!getIncludeImportRangesList().equals(other.getIncludeImportRangesList())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; + /** + * + * + *
      +   * Output only. The proposed include import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedIncludeImportRangesBytes(int index) { + return proposedIncludeImportRanges_.getByteString(index); } - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getUrisCount() > 0) { - hash = (37 * hash) + URIS_FIELD_NUMBER; - hash = (53 * hash) + getUrisList().hashCode(); - } - hash = (37 * hash) + SITE_TO_SITE_DATA_TRANSFER_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSiteToSiteDataTransfer()); - hash = (37 * hash) + VPC_NETWORK_FIELD_NUMBER; - hash = (53 * hash) + getVpcNetwork().hashCode(); - if (getIncludeImportRangesCount() > 0) { - hash = (37 * hash) + INCLUDE_IMPORT_RANGES_FIELD_NUMBER; - hash = (53 * hash) + getIncludeImportRangesList().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } + public static final int EXCLUDE_IMPORT_RANGES_FIELD_NUMBER = 6; - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList excludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); + /** + * + * + *
      +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +   * excluded during import from hub.
      +   * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getExcludeImportRangesList() { + return excludeImportRanges_; } - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); + /** + * + * + *
      +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +   * excluded during import from hub.
      +   * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeImportRanges. + */ + public int getExcludeImportRangesCount() { + return excludeImportRanges_.size(); } - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); + /** + * + * + *
      +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +   * excluded during import from hub.
      +   * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeImportRanges at the given index. + */ + public java.lang.String getExcludeImportRanges(int index) { + return excludeImportRanges_.get(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); + /** + * + * + *
      +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +   * excluded during import from hub.
      +   * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getExcludeImportRangesBytes(int index) { + return excludeImportRanges_.getByteString(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } + public static final int PROPOSED_EXCLUDE_IMPORT_RANGES_FIELD_NUMBER = 12; - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); - } + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedExcludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException( - PARSER, input, extensionRegistry); + /** + * + * + *
      +   * Output only. The proposed exclude import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedExcludeImportRangesList() { + return proposedExcludeImportRanges_; } - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + /** + * + * + *
      +   * Output only. The proposed exclude import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeImportRanges. + */ + public int getProposedExcludeImportRangesCount() { + return proposedExcludeImportRanges_.size(); } - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments - parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); + /** + * + * + *
      +   * Output only. The proposed exclude import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeImportRanges at the given index. + */ + public java.lang.String getProposedExcludeImportRanges(int index) { + return proposedExcludeImportRanges_.get(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + /** + * + * + *
      +   * Output only. The proposed exclude import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedExcludeImportRangesBytes(int index) { + return proposedExcludeImportRanges_.getByteString(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException( - PARSER, input, extensionRegistry); + public static final int INCLUDE_EXPORT_RANGES_FIELD_NUMBER = 7; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList includeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
      +   * Optional. Dynamic routes fully encompassed by include export ranges are
      +   * included during export to hub.
      +   * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getIncludeExportRangesList() { + return includeExportRanges_; } - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); + /** + * + * + *
      +   * Optional. Dynamic routes fully encompassed by include export ranges are
      +   * included during export to hub.
      +   * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of includeExportRanges. + */ + public int getIncludeExportRangesCount() { + return includeExportRanges_.size(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); + /** + * + * + *
      +   * Optional. Dynamic routes fully encompassed by include export ranges are
      +   * included during export to hub.
      +   * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The includeExportRanges at the given index. + */ + public java.lang.String getIncludeExportRanges(int index) { + return includeExportRanges_.get(index); } - public static Builder newBuilder( - com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + /** + * + * + *
      +   * Optional. Dynamic routes fully encompassed by include export ranges are
      +   * included during export to hub.
      +   * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the includeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getIncludeExportRangesBytes(int index) { + return includeExportRanges_.getByteString(index); } - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + public static final int PROPOSED_INCLUDE_EXPORT_RANGES_FIELD_NUMBER = 9; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedIncludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedIncludeExportRangesList() { + return proposedIncludeExportRanges_; } - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; + /** + * + * + *
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeExportRanges. + */ + public int getProposedIncludeExportRangesCount() { + return proposedIncludeExportRanges_.size(); } /** * * *
      -   * A collection of VLAN attachment resources. These resources should
      -   * be redundant attachments that all advertise the same prefixes to Google
      -   * Cloud. Alternatively, in active/passive configurations, all attachments
      -   * should be capable of advertising the same prefixes.
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
          * 
      * - * Protobuf type {@code google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments} + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeExportRanges at the given index. */ - public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments) - com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachmentsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_LinkedInterconnectAttachments_descriptor; - } + public java.lang.String getProposedIncludeExportRanges(int index) { + return proposedIncludeExportRanges_.get(index); + } - @java.lang.Override - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_LinkedInterconnectAttachments_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments.class, - com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments.Builder.class); - } + /** + * + * + *
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int index) { + return proposedIncludeExportRanges_.getByteString(index); + } - // Construct using - // com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments.newBuilder() - private Builder() {} + public static final int EXCLUDE_EXPORT_RANGES_FIELD_NUMBER = 8; - private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - } + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList excludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - @java.lang.Override - public Builder clear() { - super.clear(); - bitField0_ = 0; - uris_ = com.google.protobuf.LazyStringArrayList.emptyList(); - siteToSiteDataTransfer_ = false; - vpcNetwork_ = ""; - includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); - return this; - } + /** + * + * + *
      +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +   * are excluded during export to hub.
      +   * 
      + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getExcludeExportRangesList() { + return excludeExportRanges_; + } - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_LinkedInterconnectAttachments_descriptor; - } + /** + * + * + *
      +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +   * are excluded during export to hub.
      +   * 
      + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeExportRanges. + */ + public int getExcludeExportRangesCount() { + return excludeExportRanges_.size(); + } - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments - getDefaultInstanceForType() { - return com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments - .getDefaultInstance(); - } + /** + * + * + *
      +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +   * are excluded during export to hub.
      +   * 
      + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeExportRanges at the given index. + */ + public java.lang.String getExcludeExportRanges(int index) { + return excludeExportRanges_.get(index); + } - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments build() { - com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } + /** + * + * + *
      +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +   * are excluded during export to hub.
      +   * 
      + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getExcludeExportRangesBytes(int index) { + return excludeExportRanges_.getByteString(index); + } - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments buildPartial() { - com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments result = - new com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments(this); - if (bitField0_ != 0) { - buildPartial0(result); - } - onBuilt(); - return result; - } + public static final int PROPOSED_EXCLUDE_EXPORT_RANGES_FIELD_NUMBER = 10; - private void buildPartial0( - com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments result) { - int from_bitField0_ = bitField0_; - if (((from_bitField0_ & 0x00000001) != 0)) { - uris_.makeImmutable(); - result.uris_ = uris_; - } - if (((from_bitField0_ & 0x00000002) != 0)) { - result.siteToSiteDataTransfer_ = siteToSiteDataTransfer_; - } - if (((from_bitField0_ & 0x00000004) != 0)) { - result.vpcNetwork_ = vpcNetwork_; - } - if (((from_bitField0_ & 0x00000008) != 0)) { - includeImportRanges_.makeImmutable(); - result.includeImportRanges_ = includeImportRanges_; - } - } + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedExcludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments) { - return mergeFrom( - (com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments) other); - } else { - super.mergeFrom(other); - return this; - } + /** + * + * + *
      +   * Output only. The proposed exclude export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedExcludeExportRangesList() { + return proposedExcludeExportRanges_; + } + + /** + * + * + *
      +   * Output only. The proposed exclude export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeExportRanges. + */ + public int getProposedExcludeExportRangesCount() { + return proposedExcludeExportRanges_.size(); + } + + /** + * + * + *
      +   * Output only. The proposed exclude export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeExportRanges at the given index. + */ + public java.lang.String getProposedExcludeExportRanges(int index) { + return proposedExcludeExportRanges_.get(index); + } + + /** + * + * + *
      +   * Output only. The proposed exclude export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int index) { + return proposedExcludeExportRanges_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < uris_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, uris_.getRaw(i)); + } + if (siteToSiteDataTransfer_ != false) { + output.writeBool(2, siteToSiteDataTransfer_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, vpcNetwork_); + } + for (int i = 0; i < includeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, includeImportRanges_.getRaw(i)); + } + for (int i = 0; i < excludeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, excludeImportRanges_.getRaw(i)); + } + for (int i = 0; i < includeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 7, includeExportRanges_.getRaw(i)); + } + for (int i = 0; i < excludeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 8, excludeExportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedIncludeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 9, proposedIncludeExportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedExcludeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 10, proposedExcludeExportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedIncludeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 11, proposedIncludeImportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedExcludeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 12, proposedExcludeImportRanges_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + for (int i = 0; i < uris_.size(); i++) { + dataSize += computeStringSizeNoTag(uris_.getRaw(i)); + } + size += dataSize; + size += 1 * getUrisList().size(); + } + if (siteToSiteDataTransfer_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, siteToSiteDataTransfer_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, vpcNetwork_); + } + { + int dataSize = 0; + for (int i = 0; i < includeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(includeImportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getIncludeImportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < excludeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(excludeImportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getExcludeImportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < includeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(includeExportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getIncludeExportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < excludeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(excludeExportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getExcludeExportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proposedIncludeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedIncludeExportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getProposedIncludeExportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proposedExcludeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedExcludeExportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getProposedExcludeExportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proposedIncludeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedIncludeImportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getProposedIncludeImportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proposedExcludeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedExcludeImportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getProposedExcludeImportRangesList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments other = + (com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments) obj; + + if (!getUrisList().equals(other.getUrisList())) return false; + if (getSiteToSiteDataTransfer() != other.getSiteToSiteDataTransfer()) return false; + if (!getVpcNetwork().equals(other.getVpcNetwork())) return false; + if (!getIncludeImportRangesList().equals(other.getIncludeImportRangesList())) return false; + if (!getProposedIncludeImportRangesList().equals(other.getProposedIncludeImportRangesList())) + return false; + if (!getExcludeImportRangesList().equals(other.getExcludeImportRangesList())) return false; + if (!getProposedExcludeImportRangesList().equals(other.getProposedExcludeImportRangesList())) + return false; + if (!getIncludeExportRangesList().equals(other.getIncludeExportRangesList())) return false; + if (!getProposedIncludeExportRangesList().equals(other.getProposedIncludeExportRangesList())) + return false; + if (!getExcludeExportRangesList().equals(other.getExcludeExportRangesList())) return false; + if (!getProposedExcludeExportRangesList().equals(other.getProposedExcludeExportRangesList())) + return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getUrisCount() > 0) { + hash = (37 * hash) + URIS_FIELD_NUMBER; + hash = (53 * hash) + getUrisList().hashCode(); + } + hash = (37 * hash) + SITE_TO_SITE_DATA_TRANSFER_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSiteToSiteDataTransfer()); + hash = (37 * hash) + VPC_NETWORK_FIELD_NUMBER; + hash = (53 * hash) + getVpcNetwork().hashCode(); + if (getIncludeImportRangesCount() > 0) { + hash = (37 * hash) + INCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getIncludeImportRangesList().hashCode(); + } + if (getProposedIncludeImportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_INCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedIncludeImportRangesList().hashCode(); + } + if (getExcludeImportRangesCount() > 0) { + hash = (37 * hash) + EXCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getExcludeImportRangesList().hashCode(); + } + if (getProposedExcludeImportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_EXCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedExcludeImportRangesList().hashCode(); + } + if (getIncludeExportRangesCount() > 0) { + hash = (37 * hash) + INCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getIncludeExportRangesList().hashCode(); + } + if (getProposedIncludeExportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_INCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedIncludeExportRangesList().hashCode(); + } + if (getExcludeExportRangesCount() > 0) { + hash = (37 * hash) + EXCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getExcludeExportRangesList().hashCode(); + } + if (getProposedExcludeExportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_EXCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedExcludeExportRangesList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
      +   * A collection of VLAN attachment resources. These resources should
      +   * be redundant attachments that all advertise the same prefixes to Google
      +   * Cloud. Alternatively, in active/passive configurations, all attachments
      +   * should be capable of advertising the same prefixes.
      +   * 
      + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments) + com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachmentsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_LinkedInterconnectAttachments_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_LinkedInterconnectAttachments_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments.class, + com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments.Builder.class); + } + + // Construct using + // com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + uris_ = com.google.protobuf.LazyStringArrayList.emptyList(); + siteToSiteDataTransfer_ = false; + vpcNetwork_ = ""; + includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedIncludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + excludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedExcludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + includeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedIncludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + excludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedExcludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_LinkedInterconnectAttachments_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments + getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments build() { + com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments buildPartial() { + com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments result = + new com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + uris_.makeImmutable(); + result.uris_ = uris_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.siteToSiteDataTransfer_ = siteToSiteDataTransfer_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.vpcNetwork_ = vpcNetwork_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + includeImportRanges_.makeImmutable(); + result.includeImportRanges_ = includeImportRanges_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + proposedIncludeImportRanges_.makeImmutable(); + result.proposedIncludeImportRanges_ = proposedIncludeImportRanges_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + excludeImportRanges_.makeImmutable(); + result.excludeImportRanges_ = excludeImportRanges_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + proposedExcludeImportRanges_.makeImmutable(); + result.proposedExcludeImportRanges_ = proposedExcludeImportRanges_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + includeExportRanges_.makeImmutable(); + result.includeExportRanges_ = includeExportRanges_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + proposedIncludeExportRanges_.makeImmutable(); + result.proposedIncludeExportRanges_ = proposedIncludeExportRanges_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + excludeExportRanges_.makeImmutable(); + result.excludeExportRanges_ = excludeExportRanges_; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + proposedExcludeExportRanges_.makeImmutable(); + result.proposedExcludeExportRanges_ = proposedExcludeExportRanges_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments) { + return mergeFrom( + (com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments other) { + if (other + == com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments + .getDefaultInstance()) return this; + if (!other.uris_.isEmpty()) { + if (uris_.isEmpty()) { + uris_ = other.uris_; + bitField0_ |= 0x00000001; + } else { + ensureUrisIsMutable(); + uris_.addAll(other.uris_); + } + onChanged(); + } + if (other.getSiteToSiteDataTransfer() != false) { + setSiteToSiteDataTransfer(other.getSiteToSiteDataTransfer()); + } + if (!other.getVpcNetwork().isEmpty()) { + vpcNetwork_ = other.vpcNetwork_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.includeImportRanges_.isEmpty()) { + if (includeImportRanges_.isEmpty()) { + includeImportRanges_ = other.includeImportRanges_; + bitField0_ |= 0x00000008; + } else { + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.addAll(other.includeImportRanges_); + } + onChanged(); + } + if (!other.proposedIncludeImportRanges_.isEmpty()) { + if (proposedIncludeImportRanges_.isEmpty()) { + proposedIncludeImportRanges_ = other.proposedIncludeImportRanges_; + bitField0_ |= 0x00000010; + } else { + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.addAll(other.proposedIncludeImportRanges_); + } + onChanged(); + } + if (!other.excludeImportRanges_.isEmpty()) { + if (excludeImportRanges_.isEmpty()) { + excludeImportRanges_ = other.excludeImportRanges_; + bitField0_ |= 0x00000020; + } else { + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.addAll(other.excludeImportRanges_); + } + onChanged(); + } + if (!other.proposedExcludeImportRanges_.isEmpty()) { + if (proposedExcludeImportRanges_.isEmpty()) { + proposedExcludeImportRanges_ = other.proposedExcludeImportRanges_; + bitField0_ |= 0x00000040; + } else { + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.addAll(other.proposedExcludeImportRanges_); + } + onChanged(); + } + if (!other.includeExportRanges_.isEmpty()) { + if (includeExportRanges_.isEmpty()) { + includeExportRanges_ = other.includeExportRanges_; + bitField0_ |= 0x00000080; + } else { + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.addAll(other.includeExportRanges_); + } + onChanged(); + } + if (!other.proposedIncludeExportRanges_.isEmpty()) { + if (proposedIncludeExportRanges_.isEmpty()) { + proposedIncludeExportRanges_ = other.proposedIncludeExportRanges_; + bitField0_ |= 0x00000100; + } else { + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.addAll(other.proposedIncludeExportRanges_); + } + onChanged(); + } + if (!other.excludeExportRanges_.isEmpty()) { + if (excludeExportRanges_.isEmpty()) { + excludeExportRanges_ = other.excludeExportRanges_; + bitField0_ |= 0x00000200; + } else { + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.addAll(other.excludeExportRanges_); + } + onChanged(); + } + if (!other.proposedExcludeExportRanges_.isEmpty()) { + if (proposedExcludeExportRanges_.isEmpty()) { + proposedExcludeExportRanges_ = other.proposedExcludeExportRanges_; + bitField0_ |= 0x00000400; + } else { + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.addAll(other.proposedExcludeExportRanges_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUrisIsMutable(); + uris_.add(s); + break; + } // case 10 + case 16: + { + siteToSiteDataTransfer_ = input.readBool(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + vpcNetwork_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.add(s); + break; + } // case 42 + case 50: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.add(s); + break; + } // case 50 + case 58: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.add(s); + break; + } // case 58 + case 66: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.add(s); + break; + } // case 66 + case 74: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.add(s); + break; + } // case 74 + case 82: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.add(s); + break; + } // case 82 + case 90: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.add(s); + break; + } // case 90 + case 98: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.add(s); + break; + } // case 98 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringArrayList uris_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureUrisIsMutable() { + if (!uris_.isModifiable()) { + uris_ = new com.google.protobuf.LazyStringArrayList(uris_); + } + bitField0_ |= 0x00000001; + } + + /** + * + * + *
      +     * The URIs of linked interconnect attachment resources
      +     * 
      + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @return A list containing the uris. + */ + public com.google.protobuf.ProtocolStringList getUrisList() { + uris_.makeImmutable(); + return uris_; + } + + /** + * + * + *
      +     * The URIs of linked interconnect attachment resources
      +     * 
      + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @return The count of uris. + */ + public int getUrisCount() { + return uris_.size(); + } + + /** + * + * + *
      +     * The URIs of linked interconnect attachment resources
      +     * 
      + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param index The index of the element to return. + * @return The uris at the given index. + */ + public java.lang.String getUris(int index) { + return uris_.get(index); + } + + /** + * + * + *
      +     * The URIs of linked interconnect attachment resources
      +     * 
      + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param index The index of the value to return. + * @return The bytes of the uris at the given index. + */ + public com.google.protobuf.ByteString getUrisBytes(int index) { + return uris_.getByteString(index); + } + + /** + * + * + *
      +     * The URIs of linked interconnect attachment resources
      +     * 
      + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param index The index to set the value at. + * @param value The uris to set. + * @return This builder for chaining. + */ + public Builder setUris(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUrisIsMutable(); + uris_.set(index, value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
      +     * The URIs of linked interconnect attachment resources
      +     * 
      + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The uris to add. + * @return This builder for chaining. + */ + public Builder addUris(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUrisIsMutable(); + uris_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
      +     * The URIs of linked interconnect attachment resources
      +     * 
      + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param values The uris to add. + * @return This builder for chaining. + */ + public Builder addAllUris(java.lang.Iterable values) { + ensureUrisIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, uris_); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
      +     * The URIs of linked interconnect attachment resources
      +     * 
      + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @return This builder for chaining. + */ + public Builder clearUris() { + uris_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + ; + onChanged(); + return this; + } + + /** + * + * + *
      +     * The URIs of linked interconnect attachment resources
      +     * 
      + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The bytes of the uris to add. + * @return This builder for chaining. + */ + public Builder addUrisBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUrisIsMutable(); + uris_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private boolean siteToSiteDataTransfer_; + + /** + * + * + *
      +     * A value that controls whether site-to-site data transfer is enabled for
      +     * these resources. Data transfer is available only in [supported
      +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
      +     * 
      + * + * bool site_to_site_data_transfer = 2; + * + * @return The siteToSiteDataTransfer. + */ + @java.lang.Override + public boolean getSiteToSiteDataTransfer() { + return siteToSiteDataTransfer_; + } + + /** + * + * + *
      +     * A value that controls whether site-to-site data transfer is enabled for
      +     * these resources. Data transfer is available only in [supported
      +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
      +     * 
      + * + * bool site_to_site_data_transfer = 2; + * + * @param value The siteToSiteDataTransfer to set. + * @return This builder for chaining. + */ + public Builder setSiteToSiteDataTransfer(boolean value) { + + siteToSiteDataTransfer_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
      +     * A value that controls whether site-to-site data transfer is enabled for
      +     * these resources. Data transfer is available only in [supported
      +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
      +     * 
      + * + * bool site_to_site_data_transfer = 2; + * + * @return This builder for chaining. + */ + public Builder clearSiteToSiteDataTransfer() { + bitField0_ = (bitField0_ & ~0x00000002); + siteToSiteDataTransfer_ = false; + onChanged(); + return this; + } + + private java.lang.Object vpcNetwork_ = ""; + + /** + * + * + *
      +     * Output only. The VPC network where these VLAN attachments are located.
      +     * 
      + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The vpcNetwork. + */ + public java.lang.String getVpcNetwork() { + java.lang.Object ref = vpcNetwork_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + vpcNetwork_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
      +     * Output only. The VPC network where these VLAN attachments are located.
      +     * 
      + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for vpcNetwork. + */ + public com.google.protobuf.ByteString getVpcNetworkBytes() { + java.lang.Object ref = vpcNetwork_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + vpcNetwork_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
      +     * Output only. The VPC network where these VLAN attachments are located.
      +     * 
      + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The vpcNetwork to set. + * @return This builder for chaining. + */ + public Builder setVpcNetwork(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + vpcNetwork_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Output only. The VPC network where these VLAN attachments are located.
      +     * 
      + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearVpcNetwork() { + vpcNetwork_ = getDefaultInstance().getVpcNetwork(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
      +     * Output only. The VPC network where these VLAN attachments are located.
      +     * 
      + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for vpcNetwork to set. + * @return This builder for chaining. + */ + public Builder setVpcNetworkBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + vpcNetwork_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList includeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureIncludeImportRangesIsMutable() { + if (!includeImportRanges_.isModifiable()) { + includeImportRanges_ = new com.google.protobuf.LazyStringArrayList(includeImportRanges_); + } + bitField0_ |= 0x00000008; + } + + /** + * + * + *
      +     * Optional. Hub routes fully encompassed by include import ranges are
      +     * included during import from hub.
      +     * 
      + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getIncludeImportRangesList() { + includeImportRanges_.makeImmutable(); + return includeImportRanges_; + } + + /** + * + * + *
      +     * Optional. Hub routes fully encompassed by include import ranges are
      +     * included during import from hub.
      +     * 
      + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of includeImportRanges. + */ + public int getIncludeImportRangesCount() { + return includeImportRanges_.size(); + } + + /** + * + * + *
      +     * Optional. Hub routes fully encompassed by include import ranges are
      +     * included during import from hub.
      +     * 
      + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The includeImportRanges at the given index. + */ + public java.lang.String getIncludeImportRanges(int index) { + return includeImportRanges_.get(index); + } + + /** + * + * + *
      +     * Optional. Hub routes fully encompassed by include import ranges are
      +     * included during import from hub.
      +     * 
      + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the includeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getIncludeImportRangesBytes(int index) { + return includeImportRanges_.getByteString(index); + } + + /** + * + * + *
      +     * Optional. Hub routes fully encompassed by include import ranges are
      +     * included during import from hub.
      +     * 
      + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The includeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setIncludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.set(index, value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Hub routes fully encompassed by include import ranges are
      +     * included during import from hub.
      +     * 
      + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The includeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addIncludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Hub routes fully encompassed by include import ranges are
      +     * included during import from hub.
      +     * 
      + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The includeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllIncludeImportRanges(java.lang.Iterable values) { + ensureIncludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, includeImportRanges_); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Hub routes fully encompassed by include import ranges are
      +     * included during import from hub.
      +     * 
      + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIncludeImportRanges() { + includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + ; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Hub routes fully encompassed by include import ranges are
      +     * included during import from hub.
      +     * 
      + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the includeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addIncludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList proposedIncludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureProposedIncludeImportRangesIsMutable() { + if (!proposedIncludeImportRanges_.isModifiable()) { + proposedIncludeImportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedIncludeImportRanges_); + } + bitField0_ |= 0x00000010; + } + + /** + * + * + *
      +     * Output only. The proposed include import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedIncludeImportRangesList() { + proposedIncludeImportRanges_.makeImmutable(); + return proposedIncludeImportRanges_; + } + + /** + * + * + *
      +     * Output only. The proposed include import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeImportRanges. + */ + public int getProposedIncludeImportRangesCount() { + return proposedIncludeImportRanges_.size(); + } + + /** + * + * + *
      +     * Output only. The proposed include import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeImportRanges at the given index. + */ + public java.lang.String getProposedIncludeImportRanges(int index) { + return proposedIncludeImportRanges_.get(index); + } + + /** + * + * + *
      +     * Output only. The proposed include import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedIncludeImportRangesBytes(int index) { + return proposedIncludeImportRanges_.getByteString(index); + } + + /** + * + * + *
      +     * Output only. The proposed include import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index to set the value at. + * @param value The proposedIncludeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setProposedIncludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.set(index, value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Output only. The proposed include import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The proposedIncludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedIncludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Output only. The proposed include import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param values The proposedIncludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllProposedIncludeImportRanges(java.lang.Iterable values) { + ensureProposedIncludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedIncludeImportRanges_); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Output only. The proposed include import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearProposedIncludeImportRanges() { + proposedIncludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000010); + ; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Output only. The proposed include import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The bytes of the proposedIncludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedIncludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList excludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureExcludeImportRangesIsMutable() { + if (!excludeImportRanges_.isModifiable()) { + excludeImportRanges_ = new com.google.protobuf.LazyStringArrayList(excludeImportRanges_); + } + bitField0_ |= 0x00000020; + } + + /** + * + * + *
      +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +     * excluded during import from hub.
      +     * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getExcludeImportRangesList() { + excludeImportRanges_.makeImmutable(); + return excludeImportRanges_; + } + + /** + * + * + *
      +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +     * excluded during import from hub.
      +     * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeImportRanges. + */ + public int getExcludeImportRangesCount() { + return excludeImportRanges_.size(); + } + + /** + * + * + *
      +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +     * excluded during import from hub.
      +     * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeImportRanges at the given index. + */ + public java.lang.String getExcludeImportRanges(int index) { + return excludeImportRanges_.get(index); + } + + /** + * + * + *
      +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +     * excluded during import from hub.
      +     * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getExcludeImportRangesBytes(int index) { + return excludeImportRanges_.getByteString(index); + } + + /** + * + * + *
      +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +     * excluded during import from hub.
      +     * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The excludeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setExcludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.set(index, value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +     * excluded during import from hub.
      +     * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The excludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addExcludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +     * excluded during import from hub.
      +     * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The excludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllExcludeImportRanges(java.lang.Iterable values) { + ensureExcludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, excludeImportRanges_); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +     * excluded during import from hub.
      +     * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearExcludeImportRanges() { + excludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000020); + ; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +     * excluded during import from hub.
      +     * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the excludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addExcludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList proposedExcludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureProposedExcludeImportRangesIsMutable() { + if (!proposedExcludeImportRanges_.isModifiable()) { + proposedExcludeImportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedExcludeImportRanges_); + } + bitField0_ |= 0x00000040; + } + + /** + * + * + *
      +     * Output only. The proposed exclude import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedExcludeImportRangesList() { + proposedExcludeImportRanges_.makeImmutable(); + return proposedExcludeImportRanges_; + } + + /** + * + * + *
      +     * Output only. The proposed exclude import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeImportRanges. + */ + public int getProposedExcludeImportRangesCount() { + return proposedExcludeImportRanges_.size(); + } + + /** + * + * + *
      +     * Output only. The proposed exclude import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeImportRanges at the given index. + */ + public java.lang.String getProposedExcludeImportRanges(int index) { + return proposedExcludeImportRanges_.get(index); + } + + /** + * + * + *
      +     * Output only. The proposed exclude import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedExcludeImportRangesBytes(int index) { + return proposedExcludeImportRanges_.getByteString(index); + } + + /** + * + * + *
      +     * Output only. The proposed exclude import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index to set the value at. + * @param value The proposedExcludeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setProposedExcludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.set(index, value); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Output only. The proposed exclude import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The proposedExcludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedExcludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.add(value); + bitField0_ |= 0x00000040; + onChanged(); + return this; } - public Builder mergeFrom( - com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments other) { - if (other - == com.google.cloud.networkconnectivity.v1.LinkedInterconnectAttachments - .getDefaultInstance()) return this; - if (!other.uris_.isEmpty()) { - if (uris_.isEmpty()) { - uris_ = other.uris_; - bitField0_ |= 0x00000001; - } else { - ensureUrisIsMutable(); - uris_.addAll(other.uris_); - } - onChanged(); + /** + * + * + *
      +     * Output only. The proposed exclude import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param values The proposedExcludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllProposedExcludeImportRanges(java.lang.Iterable values) { + ensureProposedExcludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedExcludeImportRanges_); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Output only. The proposed exclude import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearProposedExcludeImportRanges() { + proposedExcludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000040); + ; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Output only. The proposed exclude import IP ranges waiting for hub
      +     * administrator's approval.
      +     * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The bytes of the proposedExcludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedExcludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); } - if (other.getSiteToSiteDataTransfer() != false) { - setSiteToSiteDataTransfer(other.getSiteToSiteDataTransfer()); + checkByteStringIsUtf8(value); + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.add(value); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList includeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureIncludeExportRangesIsMutable() { + if (!includeExportRanges_.isModifiable()) { + includeExportRanges_ = new com.google.protobuf.LazyStringArrayList(includeExportRanges_); } - if (!other.getVpcNetwork().isEmpty()) { - vpcNetwork_ = other.vpcNetwork_; - bitField0_ |= 0x00000004; - onChanged(); + bitField0_ |= 0x00000080; + } + + /** + * + * + *
      +     * Optional. Dynamic routes fully encompassed by include export ranges are
      +     * included during export to hub.
      +     * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getIncludeExportRangesList() { + includeExportRanges_.makeImmutable(); + return includeExportRanges_; + } + + /** + * + * + *
      +     * Optional. Dynamic routes fully encompassed by include export ranges are
      +     * included during export to hub.
      +     * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of includeExportRanges. + */ + public int getIncludeExportRangesCount() { + return includeExportRanges_.size(); + } + + /** + * + * + *
      +     * Optional. Dynamic routes fully encompassed by include export ranges are
      +     * included during export to hub.
      +     * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The includeExportRanges at the given index. + */ + public java.lang.String getIncludeExportRanges(int index) { + return includeExportRanges_.get(index); + } + + /** + * + * + *
      +     * Optional. Dynamic routes fully encompassed by include export ranges are
      +     * included during export to hub.
      +     * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the includeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getIncludeExportRangesBytes(int index) { + return includeExportRanges_.getByteString(index); + } + + /** + * + * + *
      +     * Optional. Dynamic routes fully encompassed by include export ranges are
      +     * included during export to hub.
      +     * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The includeExportRanges to set. + * @return This builder for chaining. + */ + public Builder setIncludeExportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); } - if (!other.includeImportRanges_.isEmpty()) { - if (includeImportRanges_.isEmpty()) { - includeImportRanges_ = other.includeImportRanges_; - bitField0_ |= 0x00000008; - } else { - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.addAll(other.includeImportRanges_); - } - onChanged(); + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.set(index, value); + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Dynamic routes fully encompassed by include export ranges are
      +     * included during export to hub.
      +     * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The includeExportRanges to add. + * @return This builder for chaining. + */ + public Builder addIncludeExportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); } - this.mergeUnknownFields(other.getUnknownFields()); + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.add(value); + bitField0_ |= 0x00000080; onChanged(); return this; } - @java.lang.Override - public final boolean isInitialized() { - return true; + /** + * + * + *
      +     * Optional. Dynamic routes fully encompassed by include export ranges are
      +     * included during export to hub.
      +     * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The includeExportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllIncludeExportRanges(java.lang.Iterable values) { + ensureIncludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, includeExportRanges_); + bitField0_ |= 0x00000080; + onChanged(); + return this; } - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureUrisIsMutable(); - uris_.add(s); - break; - } // case 10 - case 16: - { - siteToSiteDataTransfer_ = input.readBool(); - bitField0_ |= 0x00000002; - break; - } // case 16 - case 26: - { - vpcNetwork_ = input.readStringRequireUtf8(); - bitField0_ |= 0x00000004; - break; - } // case 26 - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.add(s); - break; - } // case 42 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally + /** + * + * + *
      +     * Optional. Dynamic routes fully encompassed by include export ranges are
      +     * included during export to hub.
      +     * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIncludeExportRanges() { + includeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000080); + ; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Dynamic routes fully encompassed by include export ranges are
      +     * included during export to hub.
      +     * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the includeExportRanges to add. + * @return This builder for chaining. + */ + public Builder addIncludeExportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.add(value); + bitField0_ |= 0x00000080; + onChanged(); return this; } - private int bitField0_; - - private com.google.protobuf.LazyStringArrayList uris_ = + private com.google.protobuf.LazyStringArrayList proposedIncludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); - private void ensureUrisIsMutable() { - if (!uris_.isModifiable()) { - uris_ = new com.google.protobuf.LazyStringArrayList(uris_); + private void ensureProposedIncludeExportRangesIsMutable() { + if (!proposedIncludeExportRanges_.isModifiable()) { + proposedIncludeExportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedIncludeExportRanges_); } - bitField0_ |= 0x00000001; + bitField0_ |= 0x00000100; } /** * * *
      -     * The URIs of linked interconnect attachment resources
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * - * @return A list containing the uris. + * @return A list containing the proposedIncludeExportRanges. */ - public com.google.protobuf.ProtocolStringList getUrisList() { - uris_.makeImmutable(); - return uris_; + public com.google.protobuf.ProtocolStringList getProposedIncludeExportRangesList() { + proposedIncludeExportRanges_.makeImmutable(); + return proposedIncludeExportRanges_; } /** * * *
      -     * The URIs of linked interconnect attachment resources
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * - * @return The count of uris. + * @return The count of proposedIncludeExportRanges. */ - public int getUrisCount() { - return uris_.size(); + public int getProposedIncludeExportRangesCount() { + return proposedIncludeExportRanges_.size(); } /** * * *
      -     * The URIs of linked interconnect attachment resources
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index of the element to return. - * @return The uris at the given index. + * @return The proposedIncludeExportRanges at the given index. */ - public java.lang.String getUris(int index) { - return uris_.get(index); + public java.lang.String getProposedIncludeExportRanges(int index) { + return proposedIncludeExportRanges_.get(index); } /** * * *
      -     * The URIs of linked interconnect attachment resources
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index of the value to return. - * @return The bytes of the uris at the given index. + * @return The bytes of the proposedIncludeExportRanges at the given index. */ - public com.google.protobuf.ByteString getUrisBytes(int index) { - return uris_.getByteString(index); + public com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int index) { + return proposedIncludeExportRanges_.getByteString(index); } /** * * *
      -     * The URIs of linked interconnect attachment resources
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index to set the value at. - * @param value The uris to set. + * @param value The proposedIncludeExportRanges to set. * @return This builder for chaining. */ - public Builder setUris(int index, java.lang.String value) { + public Builder setProposedIncludeExportRanges(int index, java.lang.String value) { if (value == null) { throw new NullPointerException(); } - ensureUrisIsMutable(); - uris_.set(index, value); - bitField0_ |= 0x00000001; + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.set(index, value); + bitField0_ |= 0x00000100; onChanged(); return this; } @@ -822,21 +3054,24 @@ public Builder setUris(int index, java.lang.String value) { * * *
      -     * The URIs of linked interconnect attachment resources
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * - * @param value The uris to add. + * @param value The proposedIncludeExportRanges to add. * @return This builder for chaining. */ - public Builder addUris(java.lang.String value) { + public Builder addProposedIncludeExportRanges(java.lang.String value) { if (value == null) { throw new NullPointerException(); } - ensureUrisIsMutable(); - uris_.add(value); - bitField0_ |= 0x00000001; + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.add(value); + bitField0_ |= 0x00000100; onChanged(); return this; } @@ -845,18 +3080,21 @@ public Builder addUris(java.lang.String value) { * * *
      -     * The URIs of linked interconnect attachment resources
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * - * @param values The uris to add. + * @param values The proposedIncludeExportRanges to add. * @return This builder for chaining. */ - public Builder addAllUris(java.lang.Iterable values) { - ensureUrisIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, uris_); - bitField0_ |= 0x00000001; + public Builder addAllProposedIncludeExportRanges(java.lang.Iterable values) { + ensureProposedIncludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedIncludeExportRanges_); + bitField0_ |= 0x00000100; onChanged(); return this; } @@ -865,16 +3103,19 @@ public Builder addAllUris(java.lang.Iterable values) { * * *
      -     * The URIs of linked interconnect attachment resources
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return This builder for chaining. */ - public Builder clearUris() { - uris_ = com.google.protobuf.LazyStringArrayList.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); + public Builder clearProposedIncludeExportRanges() { + proposedIncludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000100); ; onChanged(); return this; @@ -884,160 +3125,157 @@ public Builder clearUris() { * * *
      -     * The URIs of linked interconnect attachment resources
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * - * @param value The bytes of the uris to add. + * @param value The bytes of the proposedIncludeExportRanges to add. * @return This builder for chaining. */ - public Builder addUrisBytes(com.google.protobuf.ByteString value) { + public Builder addProposedIncludeExportRangesBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - ensureUrisIsMutable(); - uris_.add(value); - bitField0_ |= 0x00000001; + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.add(value); + bitField0_ |= 0x00000100; onChanged(); return this; } - private boolean siteToSiteDataTransfer_; + private com.google.protobuf.LazyStringArrayList excludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureExcludeExportRangesIsMutable() { + if (!excludeExportRanges_.isModifiable()) { + excludeExportRanges_ = new com.google.protobuf.LazyStringArrayList(excludeExportRanges_); + } + bitField0_ |= 0x00000200; + } /** * * *
      -     * A value that controls whether site-to-site data transfer is enabled for
      -     * these resources. Data transfer is available only in [supported
      -     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
      +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +     * are excluded during export to hub.
            * 
      * - * bool site_to_site_data_transfer = 2; + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * * - * @return The siteToSiteDataTransfer. + * @return A list containing the excludeExportRanges. */ - @java.lang.Override - public boolean getSiteToSiteDataTransfer() { - return siteToSiteDataTransfer_; + public com.google.protobuf.ProtocolStringList getExcludeExportRangesList() { + excludeExportRanges_.makeImmutable(); + return excludeExportRanges_; } /** * * *
      -     * A value that controls whether site-to-site data transfer is enabled for
      -     * these resources. Data transfer is available only in [supported
      -     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
      +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +     * are excluded during export to hub.
            * 
      * - * bool site_to_site_data_transfer = 2; + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * * - * @param value The siteToSiteDataTransfer to set. - * @return This builder for chaining. + * @return The count of excludeExportRanges. */ - public Builder setSiteToSiteDataTransfer(boolean value) { - - siteToSiteDataTransfer_ = value; - bitField0_ |= 0x00000002; - onChanged(); - return this; + public int getExcludeExportRangesCount() { + return excludeExportRanges_.size(); } /** * * *
      -     * A value that controls whether site-to-site data transfer is enabled for
      -     * these resources. Data transfer is available only in [supported
      -     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
      +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +     * are excluded during export to hub.
            * 
      * - * bool site_to_site_data_transfer = 2; + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * * - * @return This builder for chaining. + * @param index The index of the element to return. + * @return The excludeExportRanges at the given index. */ - public Builder clearSiteToSiteDataTransfer() { - bitField0_ = (bitField0_ & ~0x00000002); - siteToSiteDataTransfer_ = false; - onChanged(); - return this; + public java.lang.String getExcludeExportRanges(int index) { + return excludeExportRanges_.get(index); } - private java.lang.Object vpcNetwork_ = ""; - /** * * *
      -     * Output only. The VPC network where these VLAN attachments are located.
      +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +     * are excluded during export to hub.
            * 
      * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @return The vpcNetwork. + * @param index The index of the value to return. + * @return The bytes of the excludeExportRanges at the given index. */ - public java.lang.String getVpcNetwork() { - java.lang.Object ref = vpcNetwork_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - vpcNetwork_ = s; - return s; - } else { - return (java.lang.String) ref; - } + public com.google.protobuf.ByteString getExcludeExportRangesBytes(int index) { + return excludeExportRanges_.getByteString(index); } /** * * *
      -     * Output only. The VPC network where these VLAN attachments are located.
      +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +     * are excluded during export to hub.
            * 
      * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @return The bytes for vpcNetwork. + * @param index The index to set the value at. + * @param value The excludeExportRanges to set. + * @return This builder for chaining. */ - public com.google.protobuf.ByteString getVpcNetworkBytes() { - java.lang.Object ref = vpcNetwork_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - vpcNetwork_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; + public Builder setExcludeExportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); } + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.set(index, value); + bitField0_ |= 0x00000200; + onChanged(); + return this; } /** * * *
      -     * Output only. The VPC network where these VLAN attachments are located.
      +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +     * are excluded during export to hub.
            * 
      * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @param value The vpcNetwork to set. + * @param value The excludeExportRanges to add. * @return This builder for chaining. */ - public Builder setVpcNetwork(java.lang.String value) { + public Builder addExcludeExportRanges(java.lang.String value) { if (value == null) { throw new NullPointerException(); } - vpcNetwork_ = value; - bitField0_ |= 0x00000004; + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.add(value); + bitField0_ |= 0x00000200; onChanged(); return this; } @@ -1046,18 +3284,20 @@ public Builder setVpcNetwork(java.lang.String value) { * * *
      -     * Output only. The VPC network where these VLAN attachments are located.
      +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +     * are excluded during export to hub.
            * 
      * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * + * @param values The excludeExportRanges to add. * @return This builder for chaining. */ - public Builder clearVpcNetwork() { - vpcNetwork_ = getDefaultInstance().getVpcNetwork(); - bitField0_ = (bitField0_ & ~0x00000004); + public Builder addAllExcludeExportRanges(java.lang.Iterable values) { + ensureExcludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, excludeExportRanges_); + bitField0_ |= 0x00000200; onChanged(); return this; } @@ -1066,135 +3306,158 @@ public Builder clearVpcNetwork() { * * *
      -     * Output only. The VPC network where these VLAN attachments are located.
      +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +     * are excluded during export to hub.
            * 
      * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @param value The bytes for vpcNetwork to set. * @return This builder for chaining. */ - public Builder setVpcNetworkBytes(com.google.protobuf.ByteString value) { + public Builder clearExcludeExportRanges() { + excludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000200); + ; + onChanged(); + return this; + } + + /** + * + * + *
      +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +     * are excluded during export to hub.
      +     * 
      + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the excludeExportRanges to add. + * @return This builder for chaining. + */ + public Builder addExcludeExportRangesBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - vpcNetwork_ = value; - bitField0_ |= 0x00000004; + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.add(value); + bitField0_ |= 0x00000200; onChanged(); return this; } - private com.google.protobuf.LazyStringArrayList includeImportRanges_ = + private com.google.protobuf.LazyStringArrayList proposedExcludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); - private void ensureIncludeImportRangesIsMutable() { - if (!includeImportRanges_.isModifiable()) { - includeImportRanges_ = new com.google.protobuf.LazyStringArrayList(includeImportRanges_); + private void ensureProposedExcludeExportRangesIsMutable() { + if (!proposedExcludeExportRanges_.isModifiable()) { + proposedExcludeExportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedExcludeExportRanges_); } - bitField0_ |= 0x00000008; + bitField0_ |= 0x00000400; } /** * * *
      -     * Optional. IP ranges allowed to be included during import from hub (does not
      -     * control transit connectivity). The only allowed value for now is
      -     * "ALL_IPV4_RANGES".
      +     * Output only. The proposed exclude export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @return A list containing the includeImportRanges. + * @return A list containing the proposedExcludeExportRanges. */ - public com.google.protobuf.ProtocolStringList getIncludeImportRangesList() { - includeImportRanges_.makeImmutable(); - return includeImportRanges_; + public com.google.protobuf.ProtocolStringList getProposedExcludeExportRangesList() { + proposedExcludeExportRanges_.makeImmutable(); + return proposedExcludeExportRanges_; } /** * * *
      -     * Optional. IP ranges allowed to be included during import from hub (does not
      -     * control transit connectivity). The only allowed value for now is
      -     * "ALL_IPV4_RANGES".
      +     * Output only. The proposed exclude export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @return The count of includeImportRanges. + * @return The count of proposedExcludeExportRanges. */ - public int getIncludeImportRangesCount() { - return includeImportRanges_.size(); + public int getProposedExcludeExportRangesCount() { + return proposedExcludeExportRanges_.size(); } /** * * *
      -     * Optional. IP ranges allowed to be included during import from hub (does not
      -     * control transit connectivity). The only allowed value for now is
      -     * "ALL_IPV4_RANGES".
      +     * Output only. The proposed exclude export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. - * @return The includeImportRanges at the given index. + * @return The proposedExcludeExportRanges at the given index. */ - public java.lang.String getIncludeImportRanges(int index) { - return includeImportRanges_.get(index); + public java.lang.String getProposedExcludeExportRanges(int index) { + return proposedExcludeExportRanges_.get(index); } /** * * *
      -     * Optional. IP ranges allowed to be included during import from hub (does not
      -     * control transit connectivity). The only allowed value for now is
      -     * "ALL_IPV4_RANGES".
      +     * Output only. The proposed exclude export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. - * @return The bytes of the includeImportRanges at the given index. + * @return The bytes of the proposedExcludeExportRanges at the given index. */ - public com.google.protobuf.ByteString getIncludeImportRangesBytes(int index) { - return includeImportRanges_.getByteString(index); + public com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int index) { + return proposedExcludeExportRanges_.getByteString(index); } /** * * *
      -     * Optional. IP ranges allowed to be included during import from hub (does not
      -     * control transit connectivity). The only allowed value for now is
      -     * "ALL_IPV4_RANGES".
      +     * Output only. The proposed exclude export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index to set the value at. - * @param value The includeImportRanges to set. + * @param value The proposedExcludeExportRanges to set. * @return This builder for chaining. */ - public Builder setIncludeImportRanges(int index, java.lang.String value) { + public Builder setProposedExcludeExportRanges(int index, java.lang.String value) { if (value == null) { throw new NullPointerException(); } - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.set(index, value); - bitField0_ |= 0x00000008; + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.set(index, value); + bitField0_ |= 0x00000400; onChanged(); return this; } @@ -1203,24 +3466,24 @@ public Builder setIncludeImportRanges(int index, java.lang.String value) { * * *
      -     * Optional. IP ranges allowed to be included during import from hub (does not
      -     * control transit connectivity). The only allowed value for now is
      -     * "ALL_IPV4_RANGES".
      +     * Output only. The proposed exclude export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @param value The includeImportRanges to add. + * @param value The proposedExcludeExportRanges to add. * @return This builder for chaining. */ - public Builder addIncludeImportRanges(java.lang.String value) { + public Builder addProposedExcludeExportRanges(java.lang.String value) { if (value == null) { throw new NullPointerException(); } - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.add(value); - bitField0_ |= 0x00000008; + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.add(value); + bitField0_ |= 0x00000400; onChanged(); return this; } @@ -1229,21 +3492,21 @@ public Builder addIncludeImportRanges(java.lang.String value) { * * *
      -     * Optional. IP ranges allowed to be included during import from hub (does not
      -     * control transit connectivity). The only allowed value for now is
      -     * "ALL_IPV4_RANGES".
      +     * Output only. The proposed exclude export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @param values The includeImportRanges to add. + * @param values The proposedExcludeExportRanges to add. * @return This builder for chaining. */ - public Builder addAllIncludeImportRanges(java.lang.Iterable values) { - ensureIncludeImportRangesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, includeImportRanges_); - bitField0_ |= 0x00000008; + public Builder addAllProposedExcludeExportRanges(java.lang.Iterable values) { + ensureProposedExcludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedExcludeExportRanges_); + bitField0_ |= 0x00000400; onChanged(); return this; } @@ -1252,19 +3515,19 @@ public Builder addAllIncludeImportRanges(java.lang.Iterable va * * *
      -     * Optional. IP ranges allowed to be included during import from hub (does not
      -     * control transit connectivity). The only allowed value for now is
      -     * "ALL_IPV4_RANGES".
      +     * Output only. The proposed exclude export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return This builder for chaining. */ - public Builder clearIncludeImportRanges() { - includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); + public Builder clearProposedExcludeExportRanges() { + proposedExcludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000400); ; onChanged(); return this; @@ -1274,25 +3537,25 @@ public Builder clearIncludeImportRanges() { * * *
      -     * Optional. IP ranges allowed to be included during import from hub (does not
      -     * control transit connectivity). The only allowed value for now is
      -     * "ALL_IPV4_RANGES".
      +     * Output only. The proposed exclude export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @param value The bytes of the includeImportRanges to add. + * @param value The bytes of the proposedExcludeExportRanges to add. * @return This builder for chaining. */ - public Builder addIncludeImportRangesBytes(com.google.protobuf.ByteString value) { + public Builder addProposedExcludeExportRangesBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.add(value); - bitField0_ |= 0x00000008; + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.add(value); + bitField0_ |= 0x00000400; onChanged(); return this; } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedInterconnectAttachmentsOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedInterconnectAttachmentsOrBuilder.java index 655318c3c7e6..49f7d1230d65 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedInterconnectAttachmentsOrBuilder.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedInterconnectAttachmentsOrBuilder.java @@ -129,9 +129,8 @@ public interface LinkedInterconnectAttachmentsOrBuilder * * *
      -   * Optional. IP ranges allowed to be included during import from hub (does not
      -   * control transit connectivity). The only allowed value for now is
      -   * "ALL_IPV4_RANGES".
      +   * Optional. Hub routes fully encompassed by include import ranges are
      +   * included during import from hub.
          * 
      * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -145,9 +144,8 @@ public interface LinkedInterconnectAttachmentsOrBuilder * * *
      -   * Optional. IP ranges allowed to be included during import from hub (does not
      -   * control transit connectivity). The only allowed value for now is
      -   * "ALL_IPV4_RANGES".
      +   * Optional. Hub routes fully encompassed by include import ranges are
      +   * included during import from hub.
          * 
      * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -161,9 +159,8 @@ public interface LinkedInterconnectAttachmentsOrBuilder * * *
      -   * Optional. IP ranges allowed to be included during import from hub (does not
      -   * control transit connectivity). The only allowed value for now is
      -   * "ALL_IPV4_RANGES".
      +   * Optional. Hub routes fully encompassed by include import ranges are
      +   * included during import from hub.
          * 
      * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -178,9 +175,8 @@ public interface LinkedInterconnectAttachmentsOrBuilder * * *
      -   * Optional. IP ranges allowed to be included during import from hub (does not
      -   * control transit connectivity). The only allowed value for now is
      -   * "ALL_IPV4_RANGES".
      +   * Optional. Hub routes fully encompassed by include import ranges are
      +   * included during import from hub.
          * 
      * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -190,4 +186,454 @@ public interface LinkedInterconnectAttachmentsOrBuilder * @return The bytes of the includeImportRanges at the given index. */ com.google.protobuf.ByteString getIncludeImportRangesBytes(int index); + + /** + * + * + *
      +   * Output only. The proposed include import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeImportRanges. + */ + java.util.List getProposedIncludeImportRangesList(); + + /** + * + * + *
      +   * Output only. The proposed include import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeImportRanges. + */ + int getProposedIncludeImportRangesCount(); + + /** + * + * + *
      +   * Output only. The proposed include import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeImportRanges at the given index. + */ + java.lang.String getProposedIncludeImportRanges(int index); + + /** + * + * + *
      +   * Output only. The proposed include import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeImportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedIncludeImportRangesBytes(int index); + + /** + * + * + *
      +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +   * excluded during import from hub.
      +   * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeImportRanges. + */ + java.util.List getExcludeImportRangesList(); + + /** + * + * + *
      +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +   * excluded during import from hub.
      +   * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeImportRanges. + */ + int getExcludeImportRangesCount(); + + /** + * + * + *
      +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +   * excluded during import from hub.
      +   * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeImportRanges at the given index. + */ + java.lang.String getExcludeImportRanges(int index); + + /** + * + * + *
      +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
      +   * excluded during import from hub.
      +   * 
      + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeImportRanges at the given index. + */ + com.google.protobuf.ByteString getExcludeImportRangesBytes(int index); + + /** + * + * + *
      +   * Output only. The proposed exclude import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeImportRanges. + */ + java.util.List getProposedExcludeImportRangesList(); + + /** + * + * + *
      +   * Output only. The proposed exclude import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeImportRanges. + */ + int getProposedExcludeImportRangesCount(); + + /** + * + * + *
      +   * Output only. The proposed exclude import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeImportRanges at the given index. + */ + java.lang.String getProposedExcludeImportRanges(int index); + + /** + * + * + *
      +   * Output only. The proposed exclude import IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeImportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedExcludeImportRangesBytes(int index); + + /** + * + * + *
      +   * Optional. Dynamic routes fully encompassed by include export ranges are
      +   * included during export to hub.
      +   * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeExportRanges. + */ + java.util.List getIncludeExportRangesList(); + + /** + * + * + *
      +   * Optional. Dynamic routes fully encompassed by include export ranges are
      +   * included during export to hub.
      +   * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of includeExportRanges. + */ + int getIncludeExportRangesCount(); + + /** + * + * + *
      +   * Optional. Dynamic routes fully encompassed by include export ranges are
      +   * included during export to hub.
      +   * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The includeExportRanges at the given index. + */ + java.lang.String getIncludeExportRanges(int index); + + /** + * + * + *
      +   * Optional. Dynamic routes fully encompassed by include export ranges are
      +   * included during export to hub.
      +   * 
      + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the includeExportRanges at the given index. + */ + com.google.protobuf.ByteString getIncludeExportRangesBytes(int index); + + /** + * + * + *
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeExportRanges. + */ + java.util.List getProposedIncludeExportRangesList(); + + /** + * + * + *
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeExportRanges. + */ + int getProposedIncludeExportRangesCount(); + + /** + * + * + *
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeExportRanges at the given index. + */ + java.lang.String getProposedIncludeExportRanges(int index); + + /** + * + * + *
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeExportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int index); + + /** + * + * + *
      +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +   * are excluded during export to hub.
      +   * 
      + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeExportRanges. + */ + java.util.List getExcludeExportRangesList(); + + /** + * + * + *
      +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +   * are excluded during export to hub.
      +   * 
      + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeExportRanges. + */ + int getExcludeExportRangesCount(); + + /** + * + * + *
      +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +   * are excluded during export to hub.
      +   * 
      + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeExportRanges at the given index. + */ + java.lang.String getExcludeExportRanges(int index); + + /** + * + * + *
      +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
      +   * are excluded during export to hub.
      +   * 
      + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeExportRanges at the given index. + */ + com.google.protobuf.ByteString getExcludeExportRangesBytes(int index); + + /** + * + * + *
      +   * Output only. The proposed exclude export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeExportRanges. + */ + java.util.List getProposedExcludeExportRangesList(); + + /** + * + * + *
      +   * Output only. The proposed exclude export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeExportRanges. + */ + int getProposedExcludeExportRangesCount(); + + /** + * + * + *
      +   * Output only. The proposed exclude export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeExportRanges at the given index. + */ + java.lang.String getProposedExcludeExportRanges(int index); + + /** + * + * + *
      +   * Output only. The proposed exclude export IP ranges waiting for hub
      +   * administrator's approval.
      +   * 
      + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeExportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int index); } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedProducerVpcNetwork.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedProducerVpcNetwork.java index efdbe5d78bfd..96f77627e330 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedProducerVpcNetwork.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedProducerVpcNetwork.java @@ -453,12 +453,12 @@ public com.google.protobuf.ByteString getIncludeExportRangesBytes(int index) { * * *
      -   * Optional. The proposed include export IP ranges waiting for hub
      -   * administration's approval.
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
          * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return A list containing the proposedIncludeExportRanges. @@ -471,12 +471,12 @@ public com.google.protobuf.ProtocolStringList getProposedIncludeExportRangesList * * *
      -   * Optional. The proposed include export IP ranges waiting for hub
      -   * administration's approval.
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
          * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The count of proposedIncludeExportRanges. @@ -489,12 +489,12 @@ public int getProposedIncludeExportRangesCount() { * * *
      -   * Optional. The proposed include export IP ranges waiting for hub
      -   * administration's approval.
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
          * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. @@ -508,12 +508,12 @@ public java.lang.String getProposedIncludeExportRanges(int index) { * * *
      -   * Optional. The proposed include export IP ranges waiting for hub
      -   * administration's approval.
      +   * Output only. The proposed include export IP ranges waiting for hub
      +   * administrator's approval.
          * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. @@ -534,7 +534,7 @@ public com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int in * *
          * Output only. The proposed exclude export IP ranges waiting for hub
      -   * administration's approval.
      +   * administrator's approval.
          * 
      * * @@ -552,7 +552,7 @@ public com.google.protobuf.ProtocolStringList getProposedExcludeExportRangesList * *
          * Output only. The proposed exclude export IP ranges waiting for hub
      -   * administration's approval.
      +   * administrator's approval.
          * 
      * * @@ -570,7 +570,7 @@ public int getProposedExcludeExportRangesCount() { * *
          * Output only. The proposed exclude export IP ranges waiting for hub
      -   * administration's approval.
      +   * administrator's approval.
          * 
      * * @@ -589,7 +589,7 @@ public java.lang.String getProposedExcludeExportRanges(int index) { * *
          * Output only. The proposed exclude export IP ranges waiting for hub
      -   * administration's approval.
      +   * administrator's approval.
          * 
      * * @@ -2026,12 +2026,12 @@ private void ensureProposedIncludeExportRangesIsMutable() { * * *
      -     * Optional. The proposed include export IP ranges waiting for hub
      -     * administration's approval.
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return A list containing the proposedIncludeExportRanges. @@ -2045,12 +2045,12 @@ public com.google.protobuf.ProtocolStringList getProposedIncludeExportRangesList * * *
      -     * Optional. The proposed include export IP ranges waiting for hub
      -     * administration's approval.
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The count of proposedIncludeExportRanges. @@ -2063,12 +2063,12 @@ public int getProposedIncludeExportRangesCount() { * * *
      -     * Optional. The proposed include export IP ranges waiting for hub
      -     * administration's approval.
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. @@ -2082,12 +2082,12 @@ public java.lang.String getProposedIncludeExportRanges(int index) { * * *
      -     * Optional. The proposed include export IP ranges waiting for hub
      -     * administration's approval.
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. @@ -2101,12 +2101,12 @@ public com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int in * * *
      -     * Optional. The proposed include export IP ranges waiting for hub
      -     * administration's approval.
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index to set the value at. @@ -2128,12 +2128,12 @@ public Builder setProposedIncludeExportRanges(int index, java.lang.String value) * * *
      -     * Optional. The proposed include export IP ranges waiting for hub
      -     * administration's approval.
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The proposedIncludeExportRanges to add. @@ -2154,12 +2154,12 @@ public Builder addProposedIncludeExportRanges(java.lang.String value) { * * *
      -     * Optional. The proposed include export IP ranges waiting for hub
      -     * administration's approval.
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param values The proposedIncludeExportRanges to add. @@ -2177,12 +2177,12 @@ public Builder addAllProposedIncludeExportRanges(java.lang.Iterable - * Optional. The proposed include export IP ranges waiting for hub - * administration's approval. + * Output only. The proposed include export IP ranges waiting for hub + * administrator's approval. *
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return This builder for chaining. @@ -2199,12 +2199,12 @@ public Builder clearProposedIncludeExportRanges() { * * *
      -     * Optional. The proposed include export IP ranges waiting for hub
      -     * administration's approval.
      +     * Output only. The proposed include export IP ranges waiting for hub
      +     * administrator's approval.
            * 
      * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The bytes of the proposedIncludeExportRanges to add. @@ -2238,7 +2238,7 @@ private void ensureProposedExcludeExportRangesIsMutable() { * *
            * Output only. The proposed exclude export IP ranges waiting for hub
      -     * administration's approval.
      +     * administrator's approval.
            * 
      * * @@ -2257,7 +2257,7 @@ public com.google.protobuf.ProtocolStringList getProposedExcludeExportRangesList * *
            * Output only. The proposed exclude export IP ranges waiting for hub
      -     * administration's approval.
      +     * administrator's approval.
            * 
      * * @@ -2275,7 +2275,7 @@ public int getProposedExcludeExportRangesCount() { * *
            * Output only. The proposed exclude export IP ranges waiting for hub
      -     * administration's approval.
      +     * administrator's approval.
            * 
      * * @@ -2294,7 +2294,7 @@ public java.lang.String getProposedExcludeExportRanges(int index) { * *
            * Output only. The proposed exclude export IP ranges waiting for hub
      -     * administration's approval.
      +     * administrator's approval.
            * 
      * * @@ -2313,7 +2313,7 @@ public com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int in * *
            * Output only. The proposed exclude export IP ranges waiting for hub
      -     * administration's approval.
      +     * administrator's approval.
            * 
      * * @@ -2340,7 +2340,7 @@ public Builder setProposedExcludeExportRanges(int index, java.lang.String value) * *
            * Output only. The proposed exclude export IP ranges waiting for hub
      -     * administration's approval.
      +     * administrator's approval.
            * 
      * * @@ -2366,7 +2366,7 @@ public Builder addProposedExcludeExportRanges(java.lang.String value) { * *
            * Output only. The proposed exclude export IP ranges waiting for hub
      -     * administration's approval.
      +     * administrator's approval.
            * 
      * * @@ -2389,7 +2389,7 @@ public Builder addAllProposedExcludeExportRanges(java.lang.Iterable * Output only. The proposed exclude export IP ranges waiting for hub - * administration's approval. + * administrator's approval. *
    * * @@ -2411,7 +2411,7 @@ public Builder clearProposedExcludeExportRanges() { * *
          * Output only. The proposed exclude export IP ranges waiting for hub
    -     * administration's approval.
    +     * administrator's approval.
          * 
    * * diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedProducerVpcNetworkOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedProducerVpcNetworkOrBuilder.java index 53e006bb9173..e97f1330a3e0 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedProducerVpcNetworkOrBuilder.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedProducerVpcNetworkOrBuilder.java @@ -268,12 +268,12 @@ public interface LinkedProducerVpcNetworkOrBuilder * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return A list containing the proposedIncludeExportRanges. @@ -284,12 +284,12 @@ public interface LinkedProducerVpcNetworkOrBuilder * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The count of proposedIncludeExportRanges. @@ -300,12 +300,12 @@ public interface LinkedProducerVpcNetworkOrBuilder * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. @@ -317,12 +317,12 @@ public interface LinkedProducerVpcNetworkOrBuilder * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. @@ -335,7 +335,7 @@ public interface LinkedProducerVpcNetworkOrBuilder * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * @@ -351,7 +351,7 @@ public interface LinkedProducerVpcNetworkOrBuilder * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * @@ -367,7 +367,7 @@ public interface LinkedProducerVpcNetworkOrBuilder * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * @@ -384,7 +384,7 @@ public interface LinkedProducerVpcNetworkOrBuilder * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstances.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstances.java index 942672b381c3..45685c89dd14 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstances.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstances.java @@ -58,6 +58,13 @@ private LinkedRouterApplianceInstances() { instances_ = java.util.Collections.emptyList(); vpcNetwork_ = ""; includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedIncludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + excludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedExcludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + includeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedIncludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + excludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedExcludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -250,9 +257,8 @@ public com.google.protobuf.ByteString getVpcNetworkBytes() { * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -268,9 +274,8 @@ public com.google.protobuf.ProtocolStringList getIncludeImportRangesList() { * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -286,9 +291,8 @@ public int getIncludeImportRangesCount() { * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -305,9 +309,8 @@ public java.lang.String getIncludeImportRanges(int index) { * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -320,557 +323,2803 @@ public com.google.protobuf.ByteString getIncludeImportRangesBytes(int index) { return includeImportRanges_.getByteString(index); } - private byte memoizedIsInitialized = -1; + public static final int PROPOSED_INCLUDE_IMPORT_RANGES_FIELD_NUMBER = 11; - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedIncludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - memoizedIsInitialized = 1; - return true; + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedIncludeImportRangesList() { + return proposedIncludeImportRanges_; } - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < instances_.size(); i++) { - output.writeMessage(1, instances_.get(i)); - } - if (siteToSiteDataTransfer_ != false) { - output.writeBool(2, siteToSiteDataTransfer_); - } - if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { - com.google.protobuf.GeneratedMessage.writeString(output, 3, vpcNetwork_); - } - for (int i = 0; i < includeImportRanges_.size(); i++) { - com.google.protobuf.GeneratedMessage.writeString(output, 5, includeImportRanges_.getRaw(i)); - } - getUnknownFields().writeTo(output); + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeImportRanges. + */ + public int getProposedIncludeImportRangesCount() { + return proposedIncludeImportRanges_.size(); } - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeImportRanges at the given index. + */ + public java.lang.String getProposedIncludeImportRanges(int index) { + return proposedIncludeImportRanges_.get(index); + } - size = 0; - for (int i = 0; i < instances_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, instances_.get(i)); - } - if (siteToSiteDataTransfer_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, siteToSiteDataTransfer_); - } - if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { - size += com.google.protobuf.GeneratedMessage.computeStringSize(3, vpcNetwork_); - } - { - int dataSize = 0; - for (int i = 0; i < includeImportRanges_.size(); i++) { - dataSize += computeStringSizeNoTag(includeImportRanges_.getRaw(i)); - } - size += dataSize; - size += 1 * getIncludeImportRangesList().size(); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedIncludeImportRangesBytes(int index) { + return proposedIncludeImportRanges_.getByteString(index); } - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances)) { - return super.equals(obj); - } - com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances other = - (com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances) obj; + public static final int EXCLUDE_IMPORT_RANGES_FIELD_NUMBER = 6; - if (!getInstancesList().equals(other.getInstancesList())) return false; - if (getSiteToSiteDataTransfer() != other.getSiteToSiteDataTransfer()) return false; - if (!getVpcNetwork().equals(other.getVpcNetwork())) return false; - if (!getIncludeImportRangesList().equals(other.getIncludeImportRangesList())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList excludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getInstancesCount() > 0) { - hash = (37 * hash) + INSTANCES_FIELD_NUMBER; - hash = (53 * hash) + getInstancesList().hashCode(); - } - hash = (37 * hash) + SITE_TO_SITE_DATA_TRANSFER_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSiteToSiteDataTransfer()); - hash = (37 * hash) + VPC_NETWORK_FIELD_NUMBER; - hash = (53 * hash) + getVpcNetwork().hashCode(); - if (getIncludeImportRangesCount() > 0) { - hash = (37 * hash) + INCLUDE_IMPORT_RANGES_FIELD_NUMBER; - hash = (53 * hash) + getIncludeImportRangesList().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getExcludeImportRangesList() { + return excludeImportRanges_; } - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeImportRanges. + */ + public int getExcludeImportRangesCount() { + return excludeImportRanges_.size(); } - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeImportRanges at the given index. + */ + public java.lang.String getExcludeImportRanges(int index) { + return excludeImportRanges_.get(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getExcludeImportRangesBytes(int index) { + return excludeImportRanges_.getByteString(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } + public static final int PROPOSED_EXCLUDE_IMPORT_RANGES_FIELD_NUMBER = 12; - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedExcludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedExcludeImportRangesList() { + return proposedExcludeImportRanges_; } - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeImportRanges. + */ + public int getProposedExcludeImportRangesCount() { + return proposedExcludeImportRanges_.size(); } - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException( - PARSER, input, extensionRegistry); + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeImportRanges at the given index. + */ + public java.lang.String getProposedExcludeImportRanges(int index) { + return proposedExcludeImportRanges_.get(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedExcludeImportRangesBytes(int index) { + return proposedExcludeImportRanges_.getByteString(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances - parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } + public static final int INCLUDE_EXPORT_RANGES_FIELD_NUMBER = 7; - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList includeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getIncludeExportRangesList() { + return includeExportRanges_; } - public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException( - PARSER, input, extensionRegistry); + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of includeExportRanges. + */ + public int getIncludeExportRangesCount() { + return includeExportRanges_.size(); } - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The includeExportRanges at the given index. + */ + public java.lang.String getIncludeExportRanges(int index) { + return includeExportRanges_.get(index); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the includeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getIncludeExportRangesBytes(int index) { + return includeExportRanges_.getByteString(index); } - public static Builder newBuilder( - com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + public static final int PROPOSED_INCLUDE_EXPORT_RANGES_FIELD_NUMBER = 9; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedIncludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedIncludeExportRangesList() { + return proposedIncludeExportRanges_; } - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeExportRanges. + */ + public int getProposedIncludeExportRangesCount() { + return proposedIncludeExportRanges_.size(); } - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeExportRanges at the given index. + */ + public java.lang.String getProposedIncludeExportRanges(int index) { + return proposedIncludeExportRanges_.get(index); } /** * * *
    -   * A collection of router appliance instances. If you configure multiple router
    -   * appliance instances to receive data from the same set of sites outside of
    -   * Google Cloud, we recommend that you associate those instances with the same
    -   * spoke.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * - * Protobuf type {@code google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances} + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeExportRanges at the given index. */ - public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances) - com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstancesOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_LinkedRouterApplianceInstances_descriptor; - } + public com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int index) { + return proposedIncludeExportRanges_.getByteString(index); + } - @java.lang.Override - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_LinkedRouterApplianceInstances_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances.class, - com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances.Builder.class); - } + public static final int EXCLUDE_EXPORT_RANGES_FIELD_NUMBER = 8; - // Construct using - // com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances.newBuilder() - private Builder() {} + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList excludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - } + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getExcludeExportRangesList() { + return excludeExportRanges_; + } - @java.lang.Override - public Builder clear() { - super.clear(); - bitField0_ = 0; - if (instancesBuilder_ == null) { - instances_ = java.util.Collections.emptyList(); - } else { - instances_ = null; - instancesBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - siteToSiteDataTransfer_ = false; - vpcNetwork_ = ""; - includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); - return this; - } + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeExportRanges. + */ + public int getExcludeExportRangesCount() { + return excludeExportRanges_.size(); + } - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_LinkedRouterApplianceInstances_descriptor; - } + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeExportRanges at the given index. + */ + public java.lang.String getExcludeExportRanges(int index) { + return excludeExportRanges_.get(index); + } - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances - getDefaultInstanceForType() { - return com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances - .getDefaultInstance(); - } + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getExcludeExportRangesBytes(int index) { + return excludeExportRanges_.getByteString(index); + } - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances build() { - com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances result = - buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } + public static final int PROPOSED_EXCLUDE_EXPORT_RANGES_FIELD_NUMBER = 10; - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances buildPartial() { - com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances result = - new com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances(this); - buildPartialRepeatedFields(result); - if (bitField0_ != 0) { - buildPartial0(result); - } - onBuilt(); - return result; - } + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedExcludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - private void buildPartialRepeatedFields( - com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances result) { - if (instancesBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - instances_ = java.util.Collections.unmodifiableList(instances_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.instances_ = instances_; - } else { - result.instances_ = instancesBuilder_.build(); - } - } + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedExcludeExportRangesList() { + return proposedExcludeExportRanges_; + } - private void buildPartial0( - com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances result) { - int from_bitField0_ = bitField0_; - if (((from_bitField0_ & 0x00000002) != 0)) { - result.siteToSiteDataTransfer_ = siteToSiteDataTransfer_; + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeExportRanges. + */ + public int getProposedExcludeExportRangesCount() { + return proposedExcludeExportRanges_.size(); + } + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeExportRanges at the given index. + */ + public java.lang.String getProposedExcludeExportRanges(int index) { + return proposedExcludeExportRanges_.get(index); + } + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int index) { + return proposedExcludeExportRanges_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < instances_.size(); i++) { + output.writeMessage(1, instances_.get(i)); + } + if (siteToSiteDataTransfer_ != false) { + output.writeBool(2, siteToSiteDataTransfer_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, vpcNetwork_); + } + for (int i = 0; i < includeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, includeImportRanges_.getRaw(i)); + } + for (int i = 0; i < excludeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, excludeImportRanges_.getRaw(i)); + } + for (int i = 0; i < includeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 7, includeExportRanges_.getRaw(i)); + } + for (int i = 0; i < excludeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 8, excludeExportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedIncludeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 9, proposedIncludeExportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedExcludeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 10, proposedExcludeExportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedIncludeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 11, proposedIncludeImportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedExcludeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 12, proposedExcludeImportRanges_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < instances_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, instances_.get(i)); + } + if (siteToSiteDataTransfer_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, siteToSiteDataTransfer_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, vpcNetwork_); + } + { + int dataSize = 0; + for (int i = 0; i < includeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(includeImportRanges_.getRaw(i)); } - if (((from_bitField0_ & 0x00000004) != 0)) { - result.vpcNetwork_ = vpcNetwork_; + size += dataSize; + size += 1 * getIncludeImportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < excludeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(excludeImportRanges_.getRaw(i)); } - if (((from_bitField0_ & 0x00000008) != 0)) { - includeImportRanges_.makeImmutable(); - result.includeImportRanges_ = includeImportRanges_; + size += dataSize; + size += 1 * getExcludeImportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < includeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(includeExportRanges_.getRaw(i)); } + size += dataSize; + size += 1 * getIncludeExportRangesList().size(); } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances) { - return mergeFrom( - (com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances) other); - } else { - super.mergeFrom(other); - return this; + { + int dataSize = 0; + for (int i = 0; i < excludeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(excludeExportRanges_.getRaw(i)); } + size += dataSize; + size += 1 * getExcludeExportRangesList().size(); } - - public Builder mergeFrom( - com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances other) { - if (other - == com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances - .getDefaultInstance()) return this; - if (instancesBuilder_ == null) { - if (!other.instances_.isEmpty()) { - if (instances_.isEmpty()) { - instances_ = other.instances_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureInstancesIsMutable(); - instances_.addAll(other.instances_); - } - onChanged(); - } - } else { - if (!other.instances_.isEmpty()) { - if (instancesBuilder_.isEmpty()) { - instancesBuilder_.dispose(); - instancesBuilder_ = null; - instances_ = other.instances_; - bitField0_ = (bitField0_ & ~0x00000001); - instancesBuilder_ = - com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders - ? internalGetInstancesFieldBuilder() - : null; - } else { - instancesBuilder_.addAllMessages(other.instances_); - } - } + { + int dataSize = 0; + for (int i = 0; i < proposedIncludeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedIncludeExportRanges_.getRaw(i)); } - if (other.getSiteToSiteDataTransfer() != false) { - setSiteToSiteDataTransfer(other.getSiteToSiteDataTransfer()); + size += dataSize; + size += 1 * getProposedIncludeExportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proposedExcludeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedExcludeExportRanges_.getRaw(i)); } - if (!other.getVpcNetwork().isEmpty()) { - vpcNetwork_ = other.vpcNetwork_; - bitField0_ |= 0x00000004; - onChanged(); + size += dataSize; + size += 1 * getProposedExcludeExportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proposedIncludeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedIncludeImportRanges_.getRaw(i)); } - if (!other.includeImportRanges_.isEmpty()) { - if (includeImportRanges_.isEmpty()) { - includeImportRanges_ = other.includeImportRanges_; - bitField0_ |= 0x00000008; - } else { - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.addAll(other.includeImportRanges_); - } - onChanged(); + size += dataSize; + size += 1 * getProposedIncludeImportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proposedExcludeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedExcludeImportRanges_.getRaw(i)); } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; + size += dataSize; + size += 1 * getProposedExcludeImportRangesList().size(); } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } - @java.lang.Override - public final boolean isInitialized() { + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { return true; } + if (!(obj instanceof com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances other = + (com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances) obj; - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance m = - input.readMessage( - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.parser(), - extensionRegistry); - if (instancesBuilder_ == null) { - ensureInstancesIsMutable(); - instances_.add(m); - } else { - instancesBuilder_.addMessage(m); - } - break; - } // case 10 - case 16: - { - siteToSiteDataTransfer_ = input.readBool(); - bitField0_ |= 0x00000002; - break; - } // case 16 - case 26: - { - vpcNetwork_ = input.readStringRequireUtf8(); - bitField0_ |= 0x00000004; - break; - } // case 26 - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.add(s); - break; - } // case 42 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + if (!getInstancesList().equals(other.getInstancesList())) return false; + if (getSiteToSiteDataTransfer() != other.getSiteToSiteDataTransfer()) return false; + if (!getVpcNetwork().equals(other.getVpcNetwork())) return false; + if (!getIncludeImportRangesList().equals(other.getIncludeImportRangesList())) return false; + if (!getProposedIncludeImportRangesList().equals(other.getProposedIncludeImportRangesList())) + return false; + if (!getExcludeImportRangesList().equals(other.getExcludeImportRangesList())) return false; + if (!getProposedExcludeImportRangesList().equals(other.getProposedExcludeImportRangesList())) + return false; + if (!getIncludeExportRangesList().equals(other.getIncludeExportRangesList())) return false; + if (!getProposedIncludeExportRangesList().equals(other.getProposedIncludeExportRangesList())) + return false; + if (!getExcludeExportRangesList().equals(other.getExcludeExportRangesList())) return false; + if (!getProposedExcludeExportRangesList().equals(other.getProposedExcludeExportRangesList())) + return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getInstancesCount() > 0) { + hash = (37 * hash) + INSTANCES_FIELD_NUMBER; + hash = (53 * hash) + getInstancesList().hashCode(); + } + hash = (37 * hash) + SITE_TO_SITE_DATA_TRANSFER_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSiteToSiteDataTransfer()); + hash = (37 * hash) + VPC_NETWORK_FIELD_NUMBER; + hash = (53 * hash) + getVpcNetwork().hashCode(); + if (getIncludeImportRangesCount() > 0) { + hash = (37 * hash) + INCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getIncludeImportRangesList().hashCode(); + } + if (getProposedIncludeImportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_INCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedIncludeImportRangesList().hashCode(); + } + if (getExcludeImportRangesCount() > 0) { + hash = (37 * hash) + EXCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getExcludeImportRangesList().hashCode(); + } + if (getProposedExcludeImportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_EXCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedExcludeImportRangesList().hashCode(); + } + if (getIncludeExportRangesCount() > 0) { + hash = (37 * hash) + INCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getIncludeExportRangesList().hashCode(); + } + if (getProposedIncludeExportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_INCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedIncludeExportRangesList().hashCode(); + } + if (getExcludeExportRangesCount() > 0) { + hash = (37 * hash) + EXCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getExcludeExportRangesList().hashCode(); + } + if (getProposedExcludeExportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_EXCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedExcludeExportRangesList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * A collection of router appliance instances. If you configure multiple router
    +   * appliance instances to receive data from the same set of sites outside of
    +   * Google Cloud, we recommend that you associate those instances with the same
    +   * spoke.
    +   * 
    + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances) + com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstancesOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_LinkedRouterApplianceInstances_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_LinkedRouterApplianceInstances_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances.class, + com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances.Builder.class); + } + + // Construct using + // com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (instancesBuilder_ == null) { + instances_ = java.util.Collections.emptyList(); + } else { + instances_ = null; + instancesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + siteToSiteDataTransfer_ = false; + vpcNetwork_ = ""; + includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedIncludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + excludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedExcludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + includeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedIncludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + excludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedExcludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_LinkedRouterApplianceInstances_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances + getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances build() { + com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances buildPartial() { + com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances result = + new com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances result) { + if (instancesBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + instances_ = java.util.Collections.unmodifiableList(instances_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.instances_ = instances_; + } else { + result.instances_ = instancesBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.siteToSiteDataTransfer_ = siteToSiteDataTransfer_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.vpcNetwork_ = vpcNetwork_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + includeImportRanges_.makeImmutable(); + result.includeImportRanges_ = includeImportRanges_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + proposedIncludeImportRanges_.makeImmutable(); + result.proposedIncludeImportRanges_ = proposedIncludeImportRanges_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + excludeImportRanges_.makeImmutable(); + result.excludeImportRanges_ = excludeImportRanges_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + proposedExcludeImportRanges_.makeImmutable(); + result.proposedExcludeImportRanges_ = proposedExcludeImportRanges_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + includeExportRanges_.makeImmutable(); + result.includeExportRanges_ = includeExportRanges_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + proposedIncludeExportRanges_.makeImmutable(); + result.proposedIncludeExportRanges_ = proposedIncludeExportRanges_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + excludeExportRanges_.makeImmutable(); + result.excludeExportRanges_ = excludeExportRanges_; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + proposedExcludeExportRanges_.makeImmutable(); + result.proposedExcludeExportRanges_ = proposedExcludeExportRanges_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances) { + return mergeFrom( + (com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances other) { + if (other + == com.google.cloud.networkconnectivity.v1.LinkedRouterApplianceInstances + .getDefaultInstance()) return this; + if (instancesBuilder_ == null) { + if (!other.instances_.isEmpty()) { + if (instances_.isEmpty()) { + instances_ = other.instances_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureInstancesIsMutable(); + instances_.addAll(other.instances_); + } + onChanged(); + } + } else { + if (!other.instances_.isEmpty()) { + if (instancesBuilder_.isEmpty()) { + instancesBuilder_.dispose(); + instancesBuilder_ = null; + instances_ = other.instances_; + bitField0_ = (bitField0_ & ~0x00000001); + instancesBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetInstancesFieldBuilder() + : null; + } else { + instancesBuilder_.addAllMessages(other.instances_); + } + } + } + if (other.getSiteToSiteDataTransfer() != false) { + setSiteToSiteDataTransfer(other.getSiteToSiteDataTransfer()); + } + if (!other.getVpcNetwork().isEmpty()) { + vpcNetwork_ = other.vpcNetwork_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.includeImportRanges_.isEmpty()) { + if (includeImportRanges_.isEmpty()) { + includeImportRanges_ = other.includeImportRanges_; + bitField0_ |= 0x00000008; + } else { + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.addAll(other.includeImportRanges_); + } + onChanged(); + } + if (!other.proposedIncludeImportRanges_.isEmpty()) { + if (proposedIncludeImportRanges_.isEmpty()) { + proposedIncludeImportRanges_ = other.proposedIncludeImportRanges_; + bitField0_ |= 0x00000010; + } else { + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.addAll(other.proposedIncludeImportRanges_); + } + onChanged(); + } + if (!other.excludeImportRanges_.isEmpty()) { + if (excludeImportRanges_.isEmpty()) { + excludeImportRanges_ = other.excludeImportRanges_; + bitField0_ |= 0x00000020; + } else { + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.addAll(other.excludeImportRanges_); + } + onChanged(); + } + if (!other.proposedExcludeImportRanges_.isEmpty()) { + if (proposedExcludeImportRanges_.isEmpty()) { + proposedExcludeImportRanges_ = other.proposedExcludeImportRanges_; + bitField0_ |= 0x00000040; + } else { + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.addAll(other.proposedExcludeImportRanges_); + } + onChanged(); + } + if (!other.includeExportRanges_.isEmpty()) { + if (includeExportRanges_.isEmpty()) { + includeExportRanges_ = other.includeExportRanges_; + bitField0_ |= 0x00000080; + } else { + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.addAll(other.includeExportRanges_); + } + onChanged(); + } + if (!other.proposedIncludeExportRanges_.isEmpty()) { + if (proposedIncludeExportRanges_.isEmpty()) { + proposedIncludeExportRanges_ = other.proposedIncludeExportRanges_; + bitField0_ |= 0x00000100; + } else { + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.addAll(other.proposedIncludeExportRanges_); + } + onChanged(); + } + if (!other.excludeExportRanges_.isEmpty()) { + if (excludeExportRanges_.isEmpty()) { + excludeExportRanges_ = other.excludeExportRanges_; + bitField0_ |= 0x00000200; + } else { + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.addAll(other.excludeExportRanges_); + } + onChanged(); + } + if (!other.proposedExcludeExportRanges_.isEmpty()) { + if (proposedExcludeExportRanges_.isEmpty()) { + proposedExcludeExportRanges_ = other.proposedExcludeExportRanges_; + bitField0_ |= 0x00000400; + } else { + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.addAll(other.proposedExcludeExportRanges_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance m = + input.readMessage( + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.parser(), + extensionRegistry); + if (instancesBuilder_ == null) { + ensureInstancesIsMutable(); + instances_.add(m); + } else { + instancesBuilder_.addMessage(m); + } + break; + } // case 10 + case 16: + { + siteToSiteDataTransfer_ = input.readBool(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + vpcNetwork_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.add(s); + break; + } // case 42 + case 50: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.add(s); + break; + } // case 50 + case 58: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.add(s); + break; + } // case 58 + case 66: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.add(s); + break; + } // case 66 + case 74: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.add(s); + break; + } // case 74 + case 82: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.add(s); + break; + } // case 82 + case 90: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.add(s); + break; + } // case 90 + case 98: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.add(s); + break; + } // case 98 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); - } // finally + } // finally + return this; + } + + private int bitField0_; + + private java.util.List + instances_ = java.util.Collections.emptyList(); + + private void ensureInstancesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + instances_ = + new java.util.ArrayList< + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance>(instances_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance, + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder, + com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder> + instancesBuilder_; + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public java.util.List + getInstancesList() { + if (instancesBuilder_ == null) { + return java.util.Collections.unmodifiableList(instances_); + } else { + return instancesBuilder_.getMessageList(); + } + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public int getInstancesCount() { + if (instancesBuilder_ == null) { + return instances_.size(); + } else { + return instancesBuilder_.getCount(); + } + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public com.google.cloud.networkconnectivity.v1.RouterApplianceInstance getInstances(int index) { + if (instancesBuilder_ == null) { + return instances_.get(index); + } else { + return instancesBuilder_.getMessage(index); + } + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public Builder setInstances( + int index, com.google.cloud.networkconnectivity.v1.RouterApplianceInstance value) { + if (instancesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureInstancesIsMutable(); + instances_.set(index, value); + onChanged(); + } else { + instancesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public Builder setInstances( + int index, + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder builderForValue) { + if (instancesBuilder_ == null) { + ensureInstancesIsMutable(); + instances_.set(index, builderForValue.build()); + onChanged(); + } else { + instancesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public Builder addInstances( + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance value) { + if (instancesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureInstancesIsMutable(); + instances_.add(value); + onChanged(); + } else { + instancesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public Builder addInstances( + int index, com.google.cloud.networkconnectivity.v1.RouterApplianceInstance value) { + if (instancesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureInstancesIsMutable(); + instances_.add(index, value); + onChanged(); + } else { + instancesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public Builder addInstances( + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder builderForValue) { + if (instancesBuilder_ == null) { + ensureInstancesIsMutable(); + instances_.add(builderForValue.build()); + onChanged(); + } else { + instancesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public Builder addInstances( + int index, + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder builderForValue) { + if (instancesBuilder_ == null) { + ensureInstancesIsMutable(); + instances_.add(index, builderForValue.build()); + onChanged(); + } else { + instancesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public Builder addAllInstances( + java.lang.Iterable< + ? extends com.google.cloud.networkconnectivity.v1.RouterApplianceInstance> + values) { + if (instancesBuilder_ == null) { + ensureInstancesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, instances_); + onChanged(); + } else { + instancesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public Builder clearInstances() { + if (instancesBuilder_ == null) { + instances_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + instancesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public Builder removeInstances(int index) { + if (instancesBuilder_ == null) { + ensureInstancesIsMutable(); + instances_.remove(index); + onChanged(); + } else { + instancesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder + getInstancesBuilder(int index) { + return internalGetInstancesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder + getInstancesOrBuilder(int index) { + if (instancesBuilder_ == null) { + return instances_.get(index); + } else { + return instancesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public java.util.List< + ? extends com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder> + getInstancesOrBuilderList() { + if (instancesBuilder_ != null) { + return instancesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(instances_); + } + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder + addInstancesBuilder() { + return internalGetInstancesFieldBuilder() + .addBuilder( + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.getDefaultInstance()); + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder + addInstancesBuilder(int index) { + return internalGetInstancesFieldBuilder() + .addBuilder( + index, + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.getDefaultInstance()); + } + + /** + * + * + *
    +     * The list of router appliance instances.
    +     * 
    + * + * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + */ + public java.util.List + getInstancesBuilderList() { + return internalGetInstancesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance, + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder, + com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder> + internalGetInstancesFieldBuilder() { + if (instancesBuilder_ == null) { + instancesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance, + com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder, + com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder>( + instances_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + instances_ = null; + } + return instancesBuilder_; + } + + private boolean siteToSiteDataTransfer_; + + /** + * + * + *
    +     * A value that controls whether site-to-site data transfer is enabled for
    +     * these resources. Data transfer is available only in [supported
    +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * 
    + * + * bool site_to_site_data_transfer = 2; + * + * @return The siteToSiteDataTransfer. + */ + @java.lang.Override + public boolean getSiteToSiteDataTransfer() { + return siteToSiteDataTransfer_; + } + + /** + * + * + *
    +     * A value that controls whether site-to-site data transfer is enabled for
    +     * these resources. Data transfer is available only in [supported
    +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * 
    + * + * bool site_to_site_data_transfer = 2; + * + * @param value The siteToSiteDataTransfer to set. + * @return This builder for chaining. + */ + public Builder setSiteToSiteDataTransfer(boolean value) { + + siteToSiteDataTransfer_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * A value that controls whether site-to-site data transfer is enabled for
    +     * these resources. Data transfer is available only in [supported
    +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * 
    + * + * bool site_to_site_data_transfer = 2; + * + * @return This builder for chaining. + */ + public Builder clearSiteToSiteDataTransfer() { + bitField0_ = (bitField0_ & ~0x00000002); + siteToSiteDataTransfer_ = false; + onChanged(); + return this; + } + + private java.lang.Object vpcNetwork_ = ""; + + /** + * + * + *
    +     * Output only. The VPC network where these router appliance instances are
    +     * located.
    +     * 
    + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The vpcNetwork. + */ + public java.lang.String getVpcNetwork() { + java.lang.Object ref = vpcNetwork_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + vpcNetwork_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Output only. The VPC network where these router appliance instances are
    +     * located.
    +     * 
    + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for vpcNetwork. + */ + public com.google.protobuf.ByteString getVpcNetworkBytes() { + java.lang.Object ref = vpcNetwork_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + vpcNetwork_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Output only. The VPC network where these router appliance instances are
    +     * located.
    +     * 
    + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The vpcNetwork to set. + * @return This builder for chaining. + */ + public Builder setVpcNetwork(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + vpcNetwork_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The VPC network where these router appliance instances are
    +     * located.
    +     * 
    + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearVpcNetwork() { + vpcNetwork_ = getDefaultInstance().getVpcNetwork(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The VPC network where these router appliance instances are
    +     * located.
    +     * 
    + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for vpcNetwork to set. + * @return This builder for chaining. + */ + public Builder setVpcNetworkBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + vpcNetwork_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList includeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureIncludeImportRangesIsMutable() { + if (!includeImportRanges_.isModifiable()) { + includeImportRanges_ = new com.google.protobuf.LazyStringArrayList(includeImportRanges_); + } + bitField0_ |= 0x00000008; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getIncludeImportRangesList() { + includeImportRanges_.makeImmutable(); + return includeImportRanges_; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of includeImportRanges. + */ + public int getIncludeImportRangesCount() { + return includeImportRanges_.size(); + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The includeImportRanges at the given index. + */ + public java.lang.String getIncludeImportRanges(int index) { + return includeImportRanges_.get(index); + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the includeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getIncludeImportRangesBytes(int index) { + return includeImportRanges_.getByteString(index); + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The includeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setIncludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.set(index, value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The includeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addIncludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The includeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllIncludeImportRanges(java.lang.Iterable values) { + ensureIncludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, includeImportRanges_); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIncludeImportRanges() { + includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the includeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addIncludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList proposedIncludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureProposedIncludeImportRangesIsMutable() { + if (!proposedIncludeImportRanges_.isModifiable()) { + proposedIncludeImportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedIncludeImportRanges_); + } + bitField0_ |= 0x00000010; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedIncludeImportRangesList() { + proposedIncludeImportRanges_.makeImmutable(); + return proposedIncludeImportRanges_; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeImportRanges. + */ + public int getProposedIncludeImportRangesCount() { + return proposedIncludeImportRanges_.size(); + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeImportRanges at the given index. + */ + public java.lang.String getProposedIncludeImportRanges(int index) { + return proposedIncludeImportRanges_.get(index); + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedIncludeImportRangesBytes(int index) { + return proposedIncludeImportRanges_.getByteString(index); + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index to set the value at. + * @param value The proposedIncludeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setProposedIncludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.set(index, value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The proposedIncludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedIncludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param values The proposedIncludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllProposedIncludeImportRanges(java.lang.Iterable values) { + ensureProposedIncludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedIncludeImportRanges_); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearProposedIncludeImportRanges() { + proposedIncludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000010); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The bytes of the proposedIncludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedIncludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList excludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureExcludeImportRangesIsMutable() { + if (!excludeImportRanges_.isModifiable()) { + excludeImportRanges_ = new com.google.protobuf.LazyStringArrayList(excludeImportRanges_); + } + bitField0_ |= 0x00000020; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getExcludeImportRangesList() { + excludeImportRanges_.makeImmutable(); + return excludeImportRanges_; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeImportRanges. + */ + public int getExcludeImportRangesCount() { + return excludeImportRanges_.size(); + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeImportRanges at the given index. + */ + public java.lang.String getExcludeImportRanges(int index) { + return excludeImportRanges_.get(index); + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getExcludeImportRangesBytes(int index) { + return excludeImportRanges_.getByteString(index); + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The excludeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setExcludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.set(index, value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The excludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addExcludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The excludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllExcludeImportRanges(java.lang.Iterable values) { + ensureExcludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, excludeImportRanges_); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearExcludeImportRanges() { + excludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000020); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the excludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addExcludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList proposedExcludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureProposedExcludeImportRangesIsMutable() { + if (!proposedExcludeImportRanges_.isModifiable()) { + proposedExcludeImportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedExcludeImportRanges_); + } + bitField0_ |= 0x00000040; + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedExcludeImportRangesList() { + proposedExcludeImportRanges_.makeImmutable(); + return proposedExcludeImportRanges_; + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeImportRanges. + */ + public int getProposedExcludeImportRangesCount() { + return proposedExcludeImportRanges_.size(); + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeImportRanges at the given index. + */ + public java.lang.String getProposedExcludeImportRanges(int index) { + return proposedExcludeImportRanges_.get(index); + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedExcludeImportRangesBytes(int index) { + return proposedExcludeImportRanges_.getByteString(index); + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index to set the value at. + * @param value The proposedExcludeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setProposedExcludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.set(index, value); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The proposedExcludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedExcludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.add(value); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param values The proposedExcludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllProposedExcludeImportRanges(java.lang.Iterable values) { + ensureProposedExcludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedExcludeImportRanges_); + bitField0_ |= 0x00000040; + onChanged(); return this; } - private int bitField0_; + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearProposedExcludeImportRanges() { + proposedExcludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000040); + ; + onChanged(); + return this; + } - private java.util.List - instances_ = java.util.Collections.emptyList(); + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The bytes of the proposedExcludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedExcludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.add(value); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } - private void ensureInstancesIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - instances_ = - new java.util.ArrayList< - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance>(instances_); - bitField0_ |= 0x00000001; + private com.google.protobuf.LazyStringArrayList includeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureIncludeExportRangesIsMutable() { + if (!includeExportRanges_.isModifiable()) { + includeExportRanges_ = new com.google.protobuf.LazyStringArrayList(includeExportRanges_); } + bitField0_ |= 0x00000080; } - private com.google.protobuf.RepeatedFieldBuilder< - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance, - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder, - com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder> - instancesBuilder_; + /** + * + * + *
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
    +     * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getIncludeExportRangesList() { + includeExportRanges_.makeImmutable(); + return includeExportRanges_; + } /** * * *
    -     * The list of router appliance instances.
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; * + * + * @return The count of includeExportRanges. */ - public java.util.List - getInstancesList() { - if (instancesBuilder_ == null) { - return java.util.Collections.unmodifiableList(instances_); - } else { - return instancesBuilder_.getMessageList(); - } + public int getIncludeExportRangesCount() { + return includeExportRanges_.size(); } /** * * *
    -     * The list of router appliance instances.
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; * + * + * @param index The index of the element to return. + * @return The includeExportRanges at the given index. */ - public int getInstancesCount() { - if (instancesBuilder_ == null) { - return instances_.size(); - } else { - return instancesBuilder_.getCount(); - } + public java.lang.String getIncludeExportRanges(int index) { + return includeExportRanges_.get(index); } /** * * *
    -     * The list of router appliance instances.
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; * + * + * @param index The index of the value to return. + * @return The bytes of the includeExportRanges at the given index. */ - public com.google.cloud.networkconnectivity.v1.RouterApplianceInstance getInstances(int index) { - if (instancesBuilder_ == null) { - return instances_.get(index); - } else { - return instancesBuilder_.getMessage(index); - } + public com.google.protobuf.ByteString getIncludeExportRangesBytes(int index) { + return includeExportRanges_.getByteString(index); } /** * * *
    -     * The list of router appliance instances.
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; * + * + * @param index The index to set the value at. + * @param value The includeExportRanges to set. + * @return This builder for chaining. */ - public Builder setInstances( - int index, com.google.cloud.networkconnectivity.v1.RouterApplianceInstance value) { - if (instancesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInstancesIsMutable(); - instances_.set(index, value); - onChanged(); - } else { - instancesBuilder_.setMessage(index, value); + public Builder setIncludeExportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); } + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.set(index, value); + bitField0_ |= 0x00000080; + onChanged(); return this; } @@ -878,22 +3127,24 @@ public Builder setInstances( * * *
    -     * The list of router appliance instances.
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; * + * + * @param value The includeExportRanges to add. + * @return This builder for chaining. */ - public Builder setInstances( - int index, - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder builderForValue) { - if (instancesBuilder_ == null) { - ensureInstancesIsMutable(); - instances_.set(index, builderForValue.build()); - onChanged(); - } else { - instancesBuilder_.setMessage(index, builderForValue.build()); + public Builder addIncludeExportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); } + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.add(value); + bitField0_ |= 0x00000080; + onChanged(); return this; } @@ -901,24 +3152,21 @@ public Builder setInstances( * * *
    -     * The list of router appliance instances.
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; * + * + * @param values The includeExportRanges to add. + * @return This builder for chaining. */ - public Builder addInstances( - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance value) { - if (instancesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInstancesIsMutable(); - instances_.add(value); - onChanged(); - } else { - instancesBuilder_.addMessage(value); - } + public Builder addAllIncludeExportRanges(java.lang.Iterable values) { + ensureIncludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, includeExportRanges_); + bitField0_ |= 0x00000080; + onChanged(); return this; } @@ -926,24 +3174,20 @@ public Builder addInstances( * * *
    -     * The list of router appliance instances.
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; * + * + * @return This builder for chaining. */ - public Builder addInstances( - int index, com.google.cloud.networkconnectivity.v1.RouterApplianceInstance value) { - if (instancesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInstancesIsMutable(); - instances_.add(index, value); - onChanged(); - } else { - instancesBuilder_.addMessage(index, value); - } + public Builder clearIncludeExportRanges() { + includeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000080); + ; + onChanged(); return this; } @@ -951,371 +3195,389 @@ public Builder addInstances( * * *
    -     * The list of router appliance instances.
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; * + * + * @param value The bytes of the includeExportRanges to add. + * @return This builder for chaining. */ - public Builder addInstances( - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder builderForValue) { - if (instancesBuilder_ == null) { - ensureInstancesIsMutable(); - instances_.add(builderForValue.build()); - onChanged(); - } else { - instancesBuilder_.addMessage(builderForValue.build()); + public Builder addIncludeExportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); } + checkByteStringIsUtf8(value); + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.add(value); + bitField0_ |= 0x00000080; + onChanged(); return this; } + private com.google.protobuf.LazyStringArrayList proposedIncludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureProposedIncludeExportRangesIsMutable() { + if (!proposedIncludeExportRanges_.isModifiable()) { + proposedIncludeExportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedIncludeExportRanges_); + } + bitField0_ |= 0x00000100; + } + /** * * *
    -     * The list of router appliance instances.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @return A list containing the proposedIncludeExportRanges. */ - public Builder addInstances( - int index, - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder builderForValue) { - if (instancesBuilder_ == null) { - ensureInstancesIsMutable(); - instances_.add(index, builderForValue.build()); - onChanged(); - } else { - instancesBuilder_.addMessage(index, builderForValue.build()); - } - return this; + public com.google.protobuf.ProtocolStringList getProposedIncludeExportRangesList() { + proposedIncludeExportRanges_.makeImmutable(); + return proposedIncludeExportRanges_; } /** * * *
    -     * The list of router appliance instances.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @return The count of proposedIncludeExportRanges. */ - public Builder addAllInstances( - java.lang.Iterable< - ? extends com.google.cloud.networkconnectivity.v1.RouterApplianceInstance> - values) { - if (instancesBuilder_ == null) { - ensureInstancesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, instances_); - onChanged(); - } else { - instancesBuilder_.addAllMessages(values); - } - return this; + public int getProposedIncludeExportRangesCount() { + return proposedIncludeExportRanges_.size(); } /** * * *
    -     * The list of router appliance instances.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @param index The index of the element to return. + * @return The proposedIncludeExportRanges at the given index. */ - public Builder clearInstances() { - if (instancesBuilder_ == null) { - instances_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - instancesBuilder_.clear(); - } - return this; + public java.lang.String getProposedIncludeExportRanges(int index) { + return proposedIncludeExportRanges_.get(index); } /** * * *
    -     * The list of router appliance instances.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeExportRanges at the given index. */ - public Builder removeInstances(int index) { - if (instancesBuilder_ == null) { - ensureInstancesIsMutable(); - instances_.remove(index); - onChanged(); - } else { - instancesBuilder_.remove(index); - } - return this; + public com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int index) { + return proposedIncludeExportRanges_.getByteString(index); } /** * * *
    -     * The list of router appliance instances.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @param index The index to set the value at. + * @param value The proposedIncludeExportRanges to set. + * @return This builder for chaining. */ - public com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder - getInstancesBuilder(int index) { - return internalGetInstancesFieldBuilder().getBuilder(index); + public Builder setProposedIncludeExportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.set(index, value); + bitField0_ |= 0x00000100; + onChanged(); + return this; } /** * * *
    -     * The list of router appliance instances.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @param value The proposedIncludeExportRanges to add. + * @return This builder for chaining. */ - public com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder - getInstancesOrBuilder(int index) { - if (instancesBuilder_ == null) { - return instances_.get(index); - } else { - return instancesBuilder_.getMessageOrBuilder(index); + public Builder addProposedIncludeExportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); } + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.add(value); + bitField0_ |= 0x00000100; + onChanged(); + return this; } /** * * *
    -     * The list of router appliance instances.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @param values The proposedIncludeExportRanges to add. + * @return This builder for chaining. */ - public java.util.List< - ? extends com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder> - getInstancesOrBuilderList() { - if (instancesBuilder_ != null) { - return instancesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(instances_); - } + public Builder addAllProposedIncludeExportRanges(java.lang.Iterable values) { + ensureProposedIncludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedIncludeExportRanges_); + bitField0_ |= 0x00000100; + onChanged(); + return this; } /** * * *
    -     * The list of router appliance instances.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @return This builder for chaining. */ - public com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder - addInstancesBuilder() { - return internalGetInstancesFieldBuilder() - .addBuilder( - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.getDefaultInstance()); + public Builder clearProposedIncludeExportRanges() { + proposedIncludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000100); + ; + onChanged(); + return this; } /** * * *
    -     * The list of router appliance instances.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @param value The bytes of the proposedIncludeExportRanges to add. + * @return This builder for chaining. */ - public com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder - addInstancesBuilder(int index) { - return internalGetInstancesFieldBuilder() - .addBuilder( - index, - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.getDefaultInstance()); + public Builder addProposedIncludeExportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.add(value); + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList excludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureExcludeExportRangesIsMutable() { + if (!excludeExportRanges_.isModifiable()) { + excludeExportRanges_ = new com.google.protobuf.LazyStringArrayList(excludeExportRanges_); + } + bitField0_ |= 0x00000200; } /** * * *
    -     * The list of router appliance instances.
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * repeated .google.cloud.networkconnectivity.v1.RouterApplianceInstance instances = 1; + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * + * + * @return A list containing the excludeExportRanges. */ - public java.util.List - getInstancesBuilderList() { - return internalGetInstancesFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilder< - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance, - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder, - com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder> - internalGetInstancesFieldBuilder() { - if (instancesBuilder_ == null) { - instancesBuilder_ = - new com.google.protobuf.RepeatedFieldBuilder< - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance, - com.google.cloud.networkconnectivity.v1.RouterApplianceInstance.Builder, - com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder>( - instances_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - instances_ = null; - } - return instancesBuilder_; + public com.google.protobuf.ProtocolStringList getExcludeExportRangesList() { + excludeExportRanges_.makeImmutable(); + return excludeExportRanges_; } - private boolean siteToSiteDataTransfer_; - /** * * *
    -     * A value that controls whether site-to-site data transfer is enabled for
    -     * these resources. Data transfer is available only in [supported
    -     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * bool site_to_site_data_transfer = 2; + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * * - * @return The siteToSiteDataTransfer. + * @return The count of excludeExportRanges. */ - @java.lang.Override - public boolean getSiteToSiteDataTransfer() { - return siteToSiteDataTransfer_; + public int getExcludeExportRangesCount() { + return excludeExportRanges_.size(); } /** * * *
    -     * A value that controls whether site-to-site data transfer is enabled for
    -     * these resources. Data transfer is available only in [supported
    -     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * bool site_to_site_data_transfer = 2; + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * * - * @param value The siteToSiteDataTransfer to set. - * @return This builder for chaining. + * @param index The index of the element to return. + * @return The excludeExportRanges at the given index. */ - public Builder setSiteToSiteDataTransfer(boolean value) { - - siteToSiteDataTransfer_ = value; - bitField0_ |= 0x00000002; - onChanged(); - return this; + public java.lang.String getExcludeExportRanges(int index) { + return excludeExportRanges_.get(index); } /** * * *
    -     * A value that controls whether site-to-site data transfer is enabled for
    -     * these resources. Data transfer is available only in [supported
    -     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * bool site_to_site_data_transfer = 2; + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * * - * @return This builder for chaining. + * @param index The index of the value to return. + * @return The bytes of the excludeExportRanges at the given index. */ - public Builder clearSiteToSiteDataTransfer() { - bitField0_ = (bitField0_ & ~0x00000002); - siteToSiteDataTransfer_ = false; - onChanged(); - return this; + public com.google.protobuf.ByteString getExcludeExportRangesBytes(int index) { + return excludeExportRanges_.getByteString(index); } - private java.lang.Object vpcNetwork_ = ""; - /** * * *
    -     * Output only. The VPC network where these router appliance instances are
    -     * located.
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @return The vpcNetwork. + * @param index The index to set the value at. + * @param value The excludeExportRanges to set. + * @return This builder for chaining. */ - public java.lang.String getVpcNetwork() { - java.lang.Object ref = vpcNetwork_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - vpcNetwork_ = s; - return s; - } else { - return (java.lang.String) ref; + public Builder setExcludeExportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); } + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.set(index, value); + bitField0_ |= 0x00000200; + onChanged(); + return this; } /** * * *
    -     * Output only. The VPC network where these router appliance instances are
    -     * located.
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @return The bytes for vpcNetwork. + * @param value The excludeExportRanges to add. + * @return This builder for chaining. */ - public com.google.protobuf.ByteString getVpcNetworkBytes() { - java.lang.Object ref = vpcNetwork_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - vpcNetwork_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; + public Builder addExcludeExportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); } + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.add(value); + bitField0_ |= 0x00000200; + onChanged(); + return this; } /** * * *
    -     * Output only. The VPC network where these router appliance instances are
    -     * located.
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @param value The vpcNetwork to set. + * @param values The excludeExportRanges to add. * @return This builder for chaining. */ - public Builder setVpcNetwork(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - vpcNetwork_ = value; - bitField0_ |= 0x00000004; + public Builder addAllExcludeExportRanges(java.lang.Iterable values) { + ensureExcludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, excludeExportRanges_); + bitField0_ |= 0x00000200; onChanged(); return this; } @@ -1324,19 +3586,19 @@ public Builder setVpcNetwork(java.lang.String value) { * * *
    -     * Output only. The VPC network where these router appliance instances are
    -     * located.
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * * @return This builder for chaining. */ - public Builder clearVpcNetwork() { - vpcNetwork_ = getDefaultInstance().getVpcNetwork(); - bitField0_ = (bitField0_ & ~0x00000004); + public Builder clearExcludeExportRanges() { + excludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000200); + ; onChanged(); return this; } @@ -1345,136 +3607,137 @@ public Builder clearVpcNetwork() { * * *
    -     * Output only. The VPC network where these router appliance instances are
    -     * located.
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @param value The bytes for vpcNetwork to set. + * @param value The bytes of the excludeExportRanges to add. * @return This builder for chaining. */ - public Builder setVpcNetworkBytes(com.google.protobuf.ByteString value) { + public Builder addExcludeExportRangesBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - vpcNetwork_ = value; - bitField0_ |= 0x00000004; + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.add(value); + bitField0_ |= 0x00000200; onChanged(); return this; } - private com.google.protobuf.LazyStringArrayList includeImportRanges_ = + private com.google.protobuf.LazyStringArrayList proposedExcludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); - private void ensureIncludeImportRangesIsMutable() { - if (!includeImportRanges_.isModifiable()) { - includeImportRanges_ = new com.google.protobuf.LazyStringArrayList(includeImportRanges_); + private void ensureProposedExcludeExportRangesIsMutable() { + if (!proposedExcludeExportRanges_.isModifiable()) { + proposedExcludeExportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedExcludeExportRanges_); } - bitField0_ |= 0x00000008; + bitField0_ |= 0x00000400; } /** * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @return A list containing the includeImportRanges. + * @return A list containing the proposedExcludeExportRanges. */ - public com.google.protobuf.ProtocolStringList getIncludeImportRangesList() { - includeImportRanges_.makeImmutable(); - return includeImportRanges_; + public com.google.protobuf.ProtocolStringList getProposedExcludeExportRangesList() { + proposedExcludeExportRanges_.makeImmutable(); + return proposedExcludeExportRanges_; } /** * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @return The count of includeImportRanges. + * @return The count of proposedExcludeExportRanges. */ - public int getIncludeImportRangesCount() { - return includeImportRanges_.size(); + public int getProposedExcludeExportRangesCount() { + return proposedExcludeExportRanges_.size(); } /** * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. - * @return The includeImportRanges at the given index. + * @return The proposedExcludeExportRanges at the given index. */ - public java.lang.String getIncludeImportRanges(int index) { - return includeImportRanges_.get(index); + public java.lang.String getProposedExcludeExportRanges(int index) { + return proposedExcludeExportRanges_.get(index); } /** * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. - * @return The bytes of the includeImportRanges at the given index. + * @return The bytes of the proposedExcludeExportRanges at the given index. */ - public com.google.protobuf.ByteString getIncludeImportRangesBytes(int index) { - return includeImportRanges_.getByteString(index); + public com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int index) { + return proposedExcludeExportRanges_.getByteString(index); } /** * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index to set the value at. - * @param value The includeImportRanges to set. + * @param value The proposedExcludeExportRanges to set. * @return This builder for chaining. */ - public Builder setIncludeImportRanges(int index, java.lang.String value) { + public Builder setProposedExcludeExportRanges(int index, java.lang.String value) { if (value == null) { throw new NullPointerException(); } - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.set(index, value); - bitField0_ |= 0x00000008; + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.set(index, value); + bitField0_ |= 0x00000400; onChanged(); return this; } @@ -1483,24 +3746,24 @@ public Builder setIncludeImportRanges(int index, java.lang.String value) { * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @param value The includeImportRanges to add. + * @param value The proposedExcludeExportRanges to add. * @return This builder for chaining. */ - public Builder addIncludeImportRanges(java.lang.String value) { + public Builder addProposedExcludeExportRanges(java.lang.String value) { if (value == null) { throw new NullPointerException(); } - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.add(value); - bitField0_ |= 0x00000008; + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.add(value); + bitField0_ |= 0x00000400; onChanged(); return this; } @@ -1509,21 +3772,21 @@ public Builder addIncludeImportRanges(java.lang.String value) { * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @param values The includeImportRanges to add. + * @param values The proposedExcludeExportRanges to add. * @return This builder for chaining. */ - public Builder addAllIncludeImportRanges(java.lang.Iterable values) { - ensureIncludeImportRangesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, includeImportRanges_); - bitField0_ |= 0x00000008; + public Builder addAllProposedExcludeExportRanges(java.lang.Iterable values) { + ensureProposedExcludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedExcludeExportRanges_); + bitField0_ |= 0x00000400; onChanged(); return this; } @@ -1532,19 +3795,19 @@ public Builder addAllIncludeImportRanges(java.lang.Iterable va * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return This builder for chaining. */ - public Builder clearIncludeImportRanges() { - includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); + public Builder clearProposedExcludeExportRanges() { + proposedExcludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000400); ; onChanged(); return this; @@ -1554,25 +3817,25 @@ public Builder clearIncludeImportRanges() { * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @param value The bytes of the includeImportRanges to add. + * @param value The bytes of the proposedExcludeExportRanges to add. * @return This builder for chaining. */ - public Builder addIncludeImportRangesBytes(com.google.protobuf.ByteString value) { + public Builder addProposedExcludeExportRangesBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.add(value); - bitField0_ |= 0x00000008; + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.add(value); + bitField0_ |= 0x00000400; onChanged(); return this; } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstancesOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstancesOrBuilder.java index 67ea46c3fa5b..0866d417bcdb 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstancesOrBuilder.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedRouterApplianceInstancesOrBuilder.java @@ -140,9 +140,8 @@ com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder getInst * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -156,9 +155,8 @@ com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder getInst * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -172,9 +170,8 @@ com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder getInst * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -189,9 +186,8 @@ com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder getInst * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -201,4 +197,454 @@ com.google.cloud.networkconnectivity.v1.RouterApplianceInstanceOrBuilder getInst * @return The bytes of the includeImportRanges at the given index. */ com.google.protobuf.ByteString getIncludeImportRangesBytes(int index); + + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeImportRanges. + */ + java.util.List getProposedIncludeImportRangesList(); + + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeImportRanges. + */ + int getProposedIncludeImportRangesCount(); + + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeImportRanges at the given index. + */ + java.lang.String getProposedIncludeImportRanges(int index); + + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeImportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedIncludeImportRangesBytes(int index); + + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeImportRanges. + */ + java.util.List getExcludeImportRangesList(); + + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeImportRanges. + */ + int getExcludeImportRangesCount(); + + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeImportRanges at the given index. + */ + java.lang.String getExcludeImportRanges(int index); + + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeImportRanges at the given index. + */ + com.google.protobuf.ByteString getExcludeImportRangesBytes(int index); + + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeImportRanges. + */ + java.util.List getProposedExcludeImportRangesList(); + + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeImportRanges. + */ + int getProposedExcludeImportRangesCount(); + + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeImportRanges at the given index. + */ + java.lang.String getProposedExcludeImportRanges(int index); + + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeImportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedExcludeImportRangesBytes(int index); + + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeExportRanges. + */ + java.util.List getIncludeExportRangesList(); + + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of includeExportRanges. + */ + int getIncludeExportRangesCount(); + + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The includeExportRanges at the given index. + */ + java.lang.String getIncludeExportRanges(int index); + + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the includeExportRanges at the given index. + */ + com.google.protobuf.ByteString getIncludeExportRangesBytes(int index); + + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeExportRanges. + */ + java.util.List getProposedIncludeExportRangesList(); + + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeExportRanges. + */ + int getProposedIncludeExportRangesCount(); + + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeExportRanges at the given index. + */ + java.lang.String getProposedIncludeExportRanges(int index); + + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeExportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int index); + + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeExportRanges. + */ + java.util.List getExcludeExportRangesList(); + + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeExportRanges. + */ + int getExcludeExportRangesCount(); + + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeExportRanges at the given index. + */ + java.lang.String getExcludeExportRanges(int index); + + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeExportRanges at the given index. + */ + com.google.protobuf.ByteString getExcludeExportRangesBytes(int index); + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeExportRanges. + */ + java.util.List getProposedExcludeExportRangesList(); + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeExportRanges. + */ + int getProposedExcludeExportRangesCount(); + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeExportRanges at the given index. + */ + java.lang.String getProposedExcludeExportRanges(int index); + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeExportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int index); } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpcNetwork.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpcNetwork.java index 7086919eb0f7..5116beec3c6f 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpcNetwork.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpcNetwork.java @@ -286,12 +286,12 @@ public com.google.protobuf.ByteString getIncludeExportRangesBytes(int index) { * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return A list containing the proposedIncludeExportRanges. @@ -304,12 +304,12 @@ public com.google.protobuf.ProtocolStringList getProposedIncludeExportRangesList * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The count of proposedIncludeExportRanges. @@ -322,12 +322,12 @@ public int getProposedIncludeExportRangesCount() { * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. @@ -341,12 +341,12 @@ public java.lang.String getProposedIncludeExportRanges(int index) { * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. @@ -367,7 +367,7 @@ public com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int in * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * @@ -385,7 +385,7 @@ public com.google.protobuf.ProtocolStringList getProposedExcludeExportRangesList * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * @@ -403,7 +403,7 @@ public int getProposedExcludeExportRangesCount() { * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * @@ -422,7 +422,7 @@ public java.lang.String getProposedExcludeExportRanges(int index) { * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * @@ -449,7 +449,7 @@ public com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int in * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -472,7 +472,7 @@ public com.google.protobuf.ProtocolStringList getProducerVpcSpokesList() { * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -495,7 +495,7 @@ public int getProducerVpcSpokesCount() { * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -519,7 +519,7 @@ public java.lang.String getProducerVpcSpokes(int index) { * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -1561,12 +1561,12 @@ private void ensureProposedIncludeExportRangesIsMutable() { * * *
    -     * Optional. The proposed include export IP ranges waiting for hub
    -     * administration's approval.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return A list containing the proposedIncludeExportRanges. @@ -1580,12 +1580,12 @@ public com.google.protobuf.ProtocolStringList getProposedIncludeExportRangesList * * *
    -     * Optional. The proposed include export IP ranges waiting for hub
    -     * administration's approval.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The count of proposedIncludeExportRanges. @@ -1598,12 +1598,12 @@ public int getProposedIncludeExportRangesCount() { * * *
    -     * Optional. The proposed include export IP ranges waiting for hub
    -     * administration's approval.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. @@ -1617,12 +1617,12 @@ public java.lang.String getProposedIncludeExportRanges(int index) { * * *
    -     * Optional. The proposed include export IP ranges waiting for hub
    -     * administration's approval.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. @@ -1636,12 +1636,12 @@ public com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int in * * *
    -     * Optional. The proposed include export IP ranges waiting for hub
    -     * administration's approval.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index to set the value at. @@ -1663,12 +1663,12 @@ public Builder setProposedIncludeExportRanges(int index, java.lang.String value) * * *
    -     * Optional. The proposed include export IP ranges waiting for hub
    -     * administration's approval.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The proposedIncludeExportRanges to add. @@ -1689,12 +1689,12 @@ public Builder addProposedIncludeExportRanges(java.lang.String value) { * * *
    -     * Optional. The proposed include export IP ranges waiting for hub
    -     * administration's approval.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param values The proposedIncludeExportRanges to add. @@ -1712,12 +1712,12 @@ public Builder addAllProposedIncludeExportRanges(java.lang.Iterable - * Optional. The proposed include export IP ranges waiting for hub - * administration's approval. + * Output only. The proposed include export IP ranges waiting for hub + * administrator's approval. *
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return This builder for chaining. @@ -1734,12 +1734,12 @@ public Builder clearProposedIncludeExportRanges() { * * *
    -     * Optional. The proposed include export IP ranges waiting for hub
    -     * administration's approval.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The bytes of the proposedIncludeExportRanges to add. @@ -1773,7 +1773,7 @@ private void ensureProposedExcludeExportRangesIsMutable() { * *
          * Output only. The proposed exclude export IP ranges waiting for hub
    -     * administration's approval.
    +     * administrator's approval.
          * 
    * * @@ -1792,7 +1792,7 @@ public com.google.protobuf.ProtocolStringList getProposedExcludeExportRangesList * *
          * Output only. The proposed exclude export IP ranges waiting for hub
    -     * administration's approval.
    +     * administrator's approval.
          * 
    * * @@ -1810,7 +1810,7 @@ public int getProposedExcludeExportRangesCount() { * *
          * Output only. The proposed exclude export IP ranges waiting for hub
    -     * administration's approval.
    +     * administrator's approval.
          * 
    * * @@ -1829,7 +1829,7 @@ public java.lang.String getProposedExcludeExportRanges(int index) { * *
          * Output only. The proposed exclude export IP ranges waiting for hub
    -     * administration's approval.
    +     * administrator's approval.
          * 
    * * @@ -1848,7 +1848,7 @@ public com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int in * *
          * Output only. The proposed exclude export IP ranges waiting for hub
    -     * administration's approval.
    +     * administrator's approval.
          * 
    * * @@ -1875,7 +1875,7 @@ public Builder setProposedExcludeExportRanges(int index, java.lang.String value) * *
          * Output only. The proposed exclude export IP ranges waiting for hub
    -     * administration's approval.
    +     * administrator's approval.
          * 
    * * @@ -1901,7 +1901,7 @@ public Builder addProposedExcludeExportRanges(java.lang.String value) { * *
          * Output only. The proposed exclude export IP ranges waiting for hub
    -     * administration's approval.
    +     * administrator's approval.
          * 
    * * @@ -1924,7 +1924,7 @@ public Builder addAllProposedExcludeExportRanges(java.lang.Iterable * Output only. The proposed exclude export IP ranges waiting for hub - * administration's approval. + * administrator's approval. *
    * * @@ -1946,7 +1946,7 @@ public Builder clearProposedExcludeExportRanges() { * *
          * Output only. The proposed exclude export IP ranges waiting for hub
    -     * administration's approval.
    +     * administrator's approval.
          * 
    * * @@ -1985,7 +1985,7 @@ private void ensureProducerVpcSpokesIsMutable() { * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -2009,7 +2009,7 @@ public com.google.protobuf.ProtocolStringList getProducerVpcSpokesList() { * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -2032,7 +2032,7 @@ public int getProducerVpcSpokesCount() { * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -2056,7 +2056,7 @@ public java.lang.String getProducerVpcSpokes(int index) { * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -2080,7 +2080,7 @@ public com.google.protobuf.ByteString getProducerVpcSpokesBytes(int index) { * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -2112,7 +2112,7 @@ public Builder setProducerVpcSpokes(int index, java.lang.String value) { * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -2143,7 +2143,7 @@ public Builder addProducerVpcSpokes(java.lang.String value) { * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -2171,7 +2171,7 @@ public Builder addAllProducerVpcSpokes(java.lang.Iterable valu * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -2198,7 +2198,7 @@ public Builder clearProducerVpcSpokes() { * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpcNetworkOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpcNetworkOrBuilder.java index 74c761d2ccb8..3467931efa4d 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpcNetworkOrBuilder.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpcNetworkOrBuilder.java @@ -176,12 +176,12 @@ public interface LinkedVpcNetworkOrBuilder * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return A list containing the proposedIncludeExportRanges. @@ -192,12 +192,12 @@ public interface LinkedVpcNetworkOrBuilder * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The count of proposedIncludeExportRanges. @@ -208,12 +208,12 @@ public interface LinkedVpcNetworkOrBuilder * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. @@ -225,12 +225,12 @@ public interface LinkedVpcNetworkOrBuilder * * *
    -   * Optional. The proposed include export IP ranges waiting for hub
    -   * administration's approval.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * * - * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string proposed_include_export_ranges = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. @@ -243,7 +243,7 @@ public interface LinkedVpcNetworkOrBuilder * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * @@ -259,7 +259,7 @@ public interface LinkedVpcNetworkOrBuilder * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * @@ -275,7 +275,7 @@ public interface LinkedVpcNetworkOrBuilder * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * @@ -292,7 +292,7 @@ public interface LinkedVpcNetworkOrBuilder * *
        * Output only. The proposed exclude export IP ranges waiting for hub
    -   * administration's approval.
    +   * administrator's approval.
        * 
    * * @@ -311,7 +311,7 @@ public interface LinkedVpcNetworkOrBuilder * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -332,7 +332,7 @@ public interface LinkedVpcNetworkOrBuilder * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -353,7 +353,7 @@ public interface LinkedVpcNetworkOrBuilder * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. @@ -375,7 +375,7 @@ public interface LinkedVpcNetworkOrBuilder * Output only. The list of Producer VPC spokes that this VPC spoke is a * service consumer VPC spoke for. These producer VPCs are connected through * VPC peering to this spoke's backing VPC network. Because they are directly - * connected throuh VPC peering, NCC export filters do not apply between the + * connected through VPC peering, NCC export filters do not apply between the * service consumer VPC spoke and any of its producer VPC spokes. This VPC * spoke cannot be deleted as long as any of these producer VPC spokes are * connected to the NCC Hub. diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnels.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnels.java index a6585dbd1033..833ebbc71a54 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnels.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnels.java @@ -58,6 +58,13 @@ private LinkedVpnTunnels() { uris_ = com.google.protobuf.LazyStringArrayList.emptyList(); vpcNetwork_ = ""; includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedIncludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + excludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedExcludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + includeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedIncludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + excludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedExcludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -231,9 +238,8 @@ public com.google.protobuf.ByteString getVpcNetworkBytes() { * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -249,9 +255,8 @@ public com.google.protobuf.ProtocolStringList getIncludeImportRangesList() { * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -267,9 +272,8 @@ public int getIncludeImportRangesCount() { * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -286,9 +290,8 @@ public java.lang.String getIncludeImportRanges(int index) { * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -301,511 +304,2740 @@ public com.google.protobuf.ByteString getIncludeImportRangesBytes(int index) { return includeImportRanges_.getByteString(index); } - private byte memoizedIsInitialized = -1; + public static final int PROPOSED_INCLUDE_IMPORT_RANGES_FIELD_NUMBER = 11; - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedIncludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - memoizedIsInitialized = 1; - return true; + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedIncludeImportRangesList() { + return proposedIncludeImportRanges_; } - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < uris_.size(); i++) { - com.google.protobuf.GeneratedMessage.writeString(output, 1, uris_.getRaw(i)); - } - if (siteToSiteDataTransfer_ != false) { - output.writeBool(2, siteToSiteDataTransfer_); - } - if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { - com.google.protobuf.GeneratedMessage.writeString(output, 3, vpcNetwork_); - } - for (int i = 0; i < includeImportRanges_.size(); i++) { - com.google.protobuf.GeneratedMessage.writeString(output, 5, includeImportRanges_.getRaw(i)); - } - getUnknownFields().writeTo(output); + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeImportRanges. + */ + public int getProposedIncludeImportRangesCount() { + return proposedIncludeImportRanges_.size(); } - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - for (int i = 0; i < uris_.size(); i++) { - dataSize += computeStringSizeNoTag(uris_.getRaw(i)); - } - size += dataSize; - size += 1 * getUrisList().size(); - } - if (siteToSiteDataTransfer_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, siteToSiteDataTransfer_); - } - if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { - size += com.google.protobuf.GeneratedMessage.computeStringSize(3, vpcNetwork_); - } - { - int dataSize = 0; - for (int i = 0; i < includeImportRanges_.size(); i++) { - dataSize += computeStringSizeNoTag(includeImportRanges_.getRaw(i)); - } - size += dataSize; - size += 1 * getIncludeImportRangesList().size(); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeImportRanges at the given index. + */ + public java.lang.String getProposedIncludeImportRanges(int index) { + return proposedIncludeImportRanges_.get(index); } - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels)) { - return super.equals(obj); - } - com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels other = - (com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels) obj; - - if (!getUrisList().equals(other.getUrisList())) return false; - if (getSiteToSiteDataTransfer() != other.getSiteToSiteDataTransfer()) return false; - if (!getVpcNetwork().equals(other.getVpcNetwork())) return false; - if (!getIncludeImportRangesList().equals(other.getIncludeImportRangesList())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedIncludeImportRangesBytes(int index) { + return proposedIncludeImportRanges_.getByteString(index); } - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getUrisCount() > 0) { - hash = (37 * hash) + URIS_FIELD_NUMBER; - hash = (53 * hash) + getUrisList().hashCode(); - } - hash = (37 * hash) + SITE_TO_SITE_DATA_TRANSFER_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSiteToSiteDataTransfer()); - hash = (37 * hash) + VPC_NETWORK_FIELD_NUMBER; - hash = (53 * hash) + getVpcNetwork().hashCode(); - if (getIncludeImportRangesCount() > 0) { - hash = (37 * hash) + INCLUDE_IMPORT_RANGES_FIELD_NUMBER; - hash = (53 * hash) + getIncludeImportRangesList().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } + public static final int EXCLUDE_IMPORT_RANGES_FIELD_NUMBER = 6; - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList excludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getExcludeImportRangesList() { + return excludeImportRanges_; } - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeImportRanges. + */ + public int getExcludeImportRangesCount() { + return excludeImportRanges_.size(); } - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeImportRanges at the given index. + */ + public java.lang.String getExcludeImportRanges(int index) { + return excludeImportRanges_.get(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getExcludeImportRangesBytes(int index) { + return excludeImportRanges_.getByteString(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } + public static final int PROPOSED_EXCLUDE_IMPORT_RANGES_FIELD_NUMBER = 12; - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); - } + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedExcludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException( - PARSER, input, extensionRegistry); + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedExcludeImportRangesList() { + return proposedExcludeImportRanges_; } - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeImportRanges. + */ + public int getProposedExcludeImportRangesCount() { + return proposedExcludeImportRanges_.size(); } - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeImportRanges at the given index. + */ + public java.lang.String getProposedExcludeImportRanges(int index) { + return proposedExcludeImportRanges_.get(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedExcludeImportRangesBytes(int index) { + return proposedExcludeImportRanges_.getByteString(index); } - public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessage.parseWithIOException( - PARSER, input, extensionRegistry); - } + public static final int INCLUDE_EXPORT_RANGES_FIELD_NUMBER = 7; - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList includeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getIncludeExportRangesList() { + return includeExportRanges_; } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of includeExportRanges. + */ + public int getIncludeExportRangesCount() { + return includeExportRanges_.size(); } - public static Builder newBuilder( - com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The includeExportRanges at the given index. + */ + public java.lang.String getIncludeExportRanges(int index) { + return includeExportRanges_.get(index); } - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the includeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getIncludeExportRangesBytes(int index) { + return includeExportRanges_.getByteString(index); } - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; + public static final int PROPOSED_INCLUDE_EXPORT_RANGES_FIELD_NUMBER = 9; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedIncludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedIncludeExportRangesList() { + return proposedIncludeExportRanges_; } /** * * *
    -   * A collection of Cloud VPN tunnel resources. These resources should be
    -   * redundant HA VPN tunnels that all advertise the same prefixes to Google
    -   * Cloud. Alternatively, in a passive/active configuration, all tunnels
    -   * should be capable of advertising the same prefixes.
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
        * 
    * - * Protobuf type {@code google.cloud.networkconnectivity.v1.LinkedVpnTunnels} + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeExportRanges. */ - public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.LinkedVpnTunnels) - com.google.cloud.networkconnectivity.v1.LinkedVpnTunnelsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_LinkedVpnTunnels_descriptor; - } + public int getProposedIncludeExportRangesCount() { + return proposedIncludeExportRanges_.size(); + } - @java.lang.Override - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_LinkedVpnTunnels_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels.class, - com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels.Builder.class); - } + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeExportRanges at the given index. + */ + public java.lang.String getProposedIncludeExportRanges(int index) { + return proposedIncludeExportRanges_.get(index); + } - // Construct using com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels.newBuilder() - private Builder() {} + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int index) { + return proposedIncludeExportRanges_.getByteString(index); + } - private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - } + public static final int EXCLUDE_EXPORT_RANGES_FIELD_NUMBER = 8; - @java.lang.Override - public Builder clear() { - super.clear(); - bitField0_ = 0; - uris_ = com.google.protobuf.LazyStringArrayList.emptyList(); - siteToSiteDataTransfer_ = false; - vpcNetwork_ = ""; - includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); - return this; - } + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList excludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.networkconnectivity.v1.HubProto - .internal_static_google_cloud_networkconnectivity_v1_LinkedVpnTunnels_descriptor; - } + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getExcludeExportRangesList() { + return excludeExportRanges_; + } - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels getDefaultInstanceForType() { - return com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels.getDefaultInstance(); - } + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeExportRanges. + */ + public int getExcludeExportRangesCount() { + return excludeExportRanges_.size(); + } - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels build() { - com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeExportRanges at the given index. + */ + public java.lang.String getExcludeExportRanges(int index) { + return excludeExportRanges_.get(index); + } - @java.lang.Override - public com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels buildPartial() { - com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels result = - new com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels(this); - if (bitField0_ != 0) { - buildPartial0(result); - } - onBuilt(); - return result; - } + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getExcludeExportRangesBytes(int index) { + return excludeExportRanges_.getByteString(index); + } - private void buildPartial0(com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels result) { - int from_bitField0_ = bitField0_; - if (((from_bitField0_ & 0x00000001) != 0)) { - uris_.makeImmutable(); - result.uris_ = uris_; - } - if (((from_bitField0_ & 0x00000002) != 0)) { - result.siteToSiteDataTransfer_ = siteToSiteDataTransfer_; - } - if (((from_bitField0_ & 0x00000004) != 0)) { - result.vpcNetwork_ = vpcNetwork_; - } - if (((from_bitField0_ & 0x00000008) != 0)) { - includeImportRanges_.makeImmutable(); - result.includeImportRanges_ = includeImportRanges_; - } - } + public static final int PROPOSED_EXCLUDE_EXPORT_RANGES_FIELD_NUMBER = 10; - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels) { - return mergeFrom((com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels) other); - } else { - super.mergeFrom(other); - return this; - } - } + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList proposedExcludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); - public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels other) { - if (other == com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels.getDefaultInstance()) - return this; - if (!other.uris_.isEmpty()) { + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedExcludeExportRangesList() { + return proposedExcludeExportRanges_; + } + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeExportRanges. + */ + public int getProposedExcludeExportRangesCount() { + return proposedExcludeExportRanges_.size(); + } + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeExportRanges at the given index. + */ + public java.lang.String getProposedExcludeExportRanges(int index) { + return proposedExcludeExportRanges_.get(index); + } + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int index) { + return proposedExcludeExportRanges_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < uris_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, uris_.getRaw(i)); + } + if (siteToSiteDataTransfer_ != false) { + output.writeBool(2, siteToSiteDataTransfer_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, vpcNetwork_); + } + for (int i = 0; i < includeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, includeImportRanges_.getRaw(i)); + } + for (int i = 0; i < excludeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 6, excludeImportRanges_.getRaw(i)); + } + for (int i = 0; i < includeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 7, includeExportRanges_.getRaw(i)); + } + for (int i = 0; i < excludeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 8, excludeExportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedIncludeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 9, proposedIncludeExportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedExcludeExportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 10, proposedExcludeExportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedIncludeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 11, proposedIncludeImportRanges_.getRaw(i)); + } + for (int i = 0; i < proposedExcludeImportRanges_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString( + output, 12, proposedExcludeImportRanges_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + for (int i = 0; i < uris_.size(); i++) { + dataSize += computeStringSizeNoTag(uris_.getRaw(i)); + } + size += dataSize; + size += 1 * getUrisList().size(); + } + if (siteToSiteDataTransfer_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, siteToSiteDataTransfer_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(vpcNetwork_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, vpcNetwork_); + } + { + int dataSize = 0; + for (int i = 0; i < includeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(includeImportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getIncludeImportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < excludeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(excludeImportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getExcludeImportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < includeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(includeExportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getIncludeExportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < excludeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(excludeExportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getExcludeExportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proposedIncludeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedIncludeExportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getProposedIncludeExportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proposedExcludeExportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedExcludeExportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getProposedExcludeExportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proposedIncludeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedIncludeImportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getProposedIncludeImportRangesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < proposedExcludeImportRanges_.size(); i++) { + dataSize += computeStringSizeNoTag(proposedExcludeImportRanges_.getRaw(i)); + } + size += dataSize; + size += 1 * getProposedExcludeImportRangesList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels other = + (com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels) obj; + + if (!getUrisList().equals(other.getUrisList())) return false; + if (getSiteToSiteDataTransfer() != other.getSiteToSiteDataTransfer()) return false; + if (!getVpcNetwork().equals(other.getVpcNetwork())) return false; + if (!getIncludeImportRangesList().equals(other.getIncludeImportRangesList())) return false; + if (!getProposedIncludeImportRangesList().equals(other.getProposedIncludeImportRangesList())) + return false; + if (!getExcludeImportRangesList().equals(other.getExcludeImportRangesList())) return false; + if (!getProposedExcludeImportRangesList().equals(other.getProposedExcludeImportRangesList())) + return false; + if (!getIncludeExportRangesList().equals(other.getIncludeExportRangesList())) return false; + if (!getProposedIncludeExportRangesList().equals(other.getProposedIncludeExportRangesList())) + return false; + if (!getExcludeExportRangesList().equals(other.getExcludeExportRangesList())) return false; + if (!getProposedExcludeExportRangesList().equals(other.getProposedExcludeExportRangesList())) + return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getUrisCount() > 0) { + hash = (37 * hash) + URIS_FIELD_NUMBER; + hash = (53 * hash) + getUrisList().hashCode(); + } + hash = (37 * hash) + SITE_TO_SITE_DATA_TRANSFER_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSiteToSiteDataTransfer()); + hash = (37 * hash) + VPC_NETWORK_FIELD_NUMBER; + hash = (53 * hash) + getVpcNetwork().hashCode(); + if (getIncludeImportRangesCount() > 0) { + hash = (37 * hash) + INCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getIncludeImportRangesList().hashCode(); + } + if (getProposedIncludeImportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_INCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedIncludeImportRangesList().hashCode(); + } + if (getExcludeImportRangesCount() > 0) { + hash = (37 * hash) + EXCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getExcludeImportRangesList().hashCode(); + } + if (getProposedExcludeImportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_EXCLUDE_IMPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedExcludeImportRangesList().hashCode(); + } + if (getIncludeExportRangesCount() > 0) { + hash = (37 * hash) + INCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getIncludeExportRangesList().hashCode(); + } + if (getProposedIncludeExportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_INCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedIncludeExportRangesList().hashCode(); + } + if (getExcludeExportRangesCount() > 0) { + hash = (37 * hash) + EXCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getExcludeExportRangesList().hashCode(); + } + if (getProposedExcludeExportRangesCount() > 0) { + hash = (37 * hash) + PROPOSED_EXCLUDE_EXPORT_RANGES_FIELD_NUMBER; + hash = (53 * hash) + getProposedExcludeExportRangesList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * A collection of Cloud VPN tunnel resources. These resources should be
    +   * redundant HA VPN tunnels that all advertise the same prefixes to Google
    +   * Cloud. Alternatively, in a passive/active configuration, all tunnels
    +   * should be capable of advertising the same prefixes.
    +   * 
    + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.LinkedVpnTunnels} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.LinkedVpnTunnels) + com.google.cloud.networkconnectivity.v1.LinkedVpnTunnelsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_LinkedVpnTunnels_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_LinkedVpnTunnels_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels.class, + com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels.Builder.class); + } + + // Construct using com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + uris_ = com.google.protobuf.LazyStringArrayList.emptyList(); + siteToSiteDataTransfer_ = false; + vpcNetwork_ = ""; + includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedIncludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + excludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedExcludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + includeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedIncludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + excludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + proposedExcludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_LinkedVpnTunnels_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels build() { + com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels buildPartial() { + com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels result = + new com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + uris_.makeImmutable(); + result.uris_ = uris_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.siteToSiteDataTransfer_ = siteToSiteDataTransfer_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.vpcNetwork_ = vpcNetwork_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + includeImportRanges_.makeImmutable(); + result.includeImportRanges_ = includeImportRanges_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + proposedIncludeImportRanges_.makeImmutable(); + result.proposedIncludeImportRanges_ = proposedIncludeImportRanges_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + excludeImportRanges_.makeImmutable(); + result.excludeImportRanges_ = excludeImportRanges_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + proposedExcludeImportRanges_.makeImmutable(); + result.proposedExcludeImportRanges_ = proposedExcludeImportRanges_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + includeExportRanges_.makeImmutable(); + result.includeExportRanges_ = includeExportRanges_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + proposedIncludeExportRanges_.makeImmutable(); + result.proposedIncludeExportRanges_ = proposedIncludeExportRanges_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + excludeExportRanges_.makeImmutable(); + result.excludeExportRanges_ = excludeExportRanges_; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + proposedExcludeExportRanges_.makeImmutable(); + result.proposedExcludeExportRanges_ = proposedExcludeExportRanges_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels) { + return mergeFrom((com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels other) { + if (other == com.google.cloud.networkconnectivity.v1.LinkedVpnTunnels.getDefaultInstance()) + return this; + if (!other.uris_.isEmpty()) { if (uris_.isEmpty()) { uris_ = other.uris_; bitField0_ |= 0x00000001; } else { - ensureUrisIsMutable(); - uris_.addAll(other.uris_); + ensureUrisIsMutable(); + uris_.addAll(other.uris_); + } + onChanged(); + } + if (other.getSiteToSiteDataTransfer() != false) { + setSiteToSiteDataTransfer(other.getSiteToSiteDataTransfer()); + } + if (!other.getVpcNetwork().isEmpty()) { + vpcNetwork_ = other.vpcNetwork_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.includeImportRanges_.isEmpty()) { + if (includeImportRanges_.isEmpty()) { + includeImportRanges_ = other.includeImportRanges_; + bitField0_ |= 0x00000008; + } else { + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.addAll(other.includeImportRanges_); + } + onChanged(); + } + if (!other.proposedIncludeImportRanges_.isEmpty()) { + if (proposedIncludeImportRanges_.isEmpty()) { + proposedIncludeImportRanges_ = other.proposedIncludeImportRanges_; + bitField0_ |= 0x00000010; + } else { + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.addAll(other.proposedIncludeImportRanges_); + } + onChanged(); + } + if (!other.excludeImportRanges_.isEmpty()) { + if (excludeImportRanges_.isEmpty()) { + excludeImportRanges_ = other.excludeImportRanges_; + bitField0_ |= 0x00000020; + } else { + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.addAll(other.excludeImportRanges_); + } + onChanged(); + } + if (!other.proposedExcludeImportRanges_.isEmpty()) { + if (proposedExcludeImportRanges_.isEmpty()) { + proposedExcludeImportRanges_ = other.proposedExcludeImportRanges_; + bitField0_ |= 0x00000040; + } else { + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.addAll(other.proposedExcludeImportRanges_); + } + onChanged(); + } + if (!other.includeExportRanges_.isEmpty()) { + if (includeExportRanges_.isEmpty()) { + includeExportRanges_ = other.includeExportRanges_; + bitField0_ |= 0x00000080; + } else { + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.addAll(other.includeExportRanges_); + } + onChanged(); + } + if (!other.proposedIncludeExportRanges_.isEmpty()) { + if (proposedIncludeExportRanges_.isEmpty()) { + proposedIncludeExportRanges_ = other.proposedIncludeExportRanges_; + bitField0_ |= 0x00000100; + } else { + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.addAll(other.proposedIncludeExportRanges_); + } + onChanged(); + } + if (!other.excludeExportRanges_.isEmpty()) { + if (excludeExportRanges_.isEmpty()) { + excludeExportRanges_ = other.excludeExportRanges_; + bitField0_ |= 0x00000200; + } else { + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.addAll(other.excludeExportRanges_); + } + onChanged(); + } + if (!other.proposedExcludeExportRanges_.isEmpty()) { + if (proposedExcludeExportRanges_.isEmpty()) { + proposedExcludeExportRanges_ = other.proposedExcludeExportRanges_; + bitField0_ |= 0x00000400; + } else { + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.addAll(other.proposedExcludeExportRanges_); } onChanged(); } - if (other.getSiteToSiteDataTransfer() != false) { - setSiteToSiteDataTransfer(other.getSiteToSiteDataTransfer()); + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUrisIsMutable(); + uris_.add(s); + break; + } // case 10 + case 16: + { + siteToSiteDataTransfer_ = input.readBool(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + vpcNetwork_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.add(s); + break; + } // case 42 + case 50: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.add(s); + break; + } // case 50 + case 58: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.add(s); + break; + } // case 58 + case 66: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.add(s); + break; + } // case 66 + case 74: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.add(s); + break; + } // case 74 + case 82: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.add(s); + break; + } // case 82 + case 90: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.add(s); + break; + } // case 90 + case 98: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.add(s); + break; + } // case 98 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringArrayList uris_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureUrisIsMutable() { + if (!uris_.isModifiable()) { + uris_ = new com.google.protobuf.LazyStringArrayList(uris_); + } + bitField0_ |= 0x00000001; + } + + /** + * + * + *
    +     * The URIs of linked VPN tunnel resources.
    +     * 
    + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @return A list containing the uris. + */ + public com.google.protobuf.ProtocolStringList getUrisList() { + uris_.makeImmutable(); + return uris_; + } + + /** + * + * + *
    +     * The URIs of linked VPN tunnel resources.
    +     * 
    + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @return The count of uris. + */ + public int getUrisCount() { + return uris_.size(); + } + + /** + * + * + *
    +     * The URIs of linked VPN tunnel resources.
    +     * 
    + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param index The index of the element to return. + * @return The uris at the given index. + */ + public java.lang.String getUris(int index) { + return uris_.get(index); + } + + /** + * + * + *
    +     * The URIs of linked VPN tunnel resources.
    +     * 
    + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param index The index of the value to return. + * @return The bytes of the uris at the given index. + */ + public com.google.protobuf.ByteString getUrisBytes(int index) { + return uris_.getByteString(index); + } + + /** + * + * + *
    +     * The URIs of linked VPN tunnel resources.
    +     * 
    + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param index The index to set the value at. + * @param value The uris to set. + * @return This builder for chaining. + */ + public Builder setUris(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUrisIsMutable(); + uris_.set(index, value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * The URIs of linked VPN tunnel resources.
    +     * 
    + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The uris to add. + * @return This builder for chaining. + */ + public Builder addUris(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUrisIsMutable(); + uris_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * The URIs of linked VPN tunnel resources.
    +     * 
    + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param values The uris to add. + * @return This builder for chaining. + */ + public Builder addAllUris(java.lang.Iterable values) { + ensureUrisIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, uris_); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * The URIs of linked VPN tunnel resources.
    +     * 
    + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @return This builder for chaining. + */ + public Builder clearUris() { + uris_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * The URIs of linked VPN tunnel resources.
    +     * 
    + * + * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The bytes of the uris to add. + * @return This builder for chaining. + */ + public Builder addUrisBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUrisIsMutable(); + uris_.add(value); + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private boolean siteToSiteDataTransfer_; + + /** + * + * + *
    +     * A value that controls whether site-to-site data transfer is enabled for
    +     * these resources. Data transfer is available only in [supported
    +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * 
    + * + * bool site_to_site_data_transfer = 2; + * + * @return The siteToSiteDataTransfer. + */ + @java.lang.Override + public boolean getSiteToSiteDataTransfer() { + return siteToSiteDataTransfer_; + } + + /** + * + * + *
    +     * A value that controls whether site-to-site data transfer is enabled for
    +     * these resources. Data transfer is available only in [supported
    +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * 
    + * + * bool site_to_site_data_transfer = 2; + * + * @param value The siteToSiteDataTransfer to set. + * @return This builder for chaining. + */ + public Builder setSiteToSiteDataTransfer(boolean value) { + + siteToSiteDataTransfer_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * A value that controls whether site-to-site data transfer is enabled for
    +     * these resources. Data transfer is available only in [supported
    +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * 
    + * + * bool site_to_site_data_transfer = 2; + * + * @return This builder for chaining. + */ + public Builder clearSiteToSiteDataTransfer() { + bitField0_ = (bitField0_ & ~0x00000002); + siteToSiteDataTransfer_ = false; + onChanged(); + return this; + } + + private java.lang.Object vpcNetwork_ = ""; + + /** + * + * + *
    +     * Output only. The VPC network where these VPN tunnels are located.
    +     * 
    + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The vpcNetwork. + */ + public java.lang.String getVpcNetwork() { + java.lang.Object ref = vpcNetwork_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + vpcNetwork_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Output only. The VPC network where these VPN tunnels are located.
    +     * 
    + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for vpcNetwork. + */ + public com.google.protobuf.ByteString getVpcNetworkBytes() { + java.lang.Object ref = vpcNetwork_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + vpcNetwork_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Output only. The VPC network where these VPN tunnels are located.
    +     * 
    + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The vpcNetwork to set. + * @return This builder for chaining. + */ + public Builder setVpcNetwork(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + vpcNetwork_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The VPC network where these VPN tunnels are located.
    +     * 
    + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearVpcNetwork() { + vpcNetwork_ = getDefaultInstance().getVpcNetwork(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The VPC network where these VPN tunnels are located.
    +     * 
    + * + * + * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for vpcNetwork to set. + * @return This builder for chaining. + */ + public Builder setVpcNetworkBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + vpcNetwork_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList includeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureIncludeImportRangesIsMutable() { + if (!includeImportRanges_.isModifiable()) { + includeImportRanges_ = new com.google.protobuf.LazyStringArrayList(includeImportRanges_); + } + bitField0_ |= 0x00000008; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getIncludeImportRangesList() { + includeImportRanges_.makeImmutable(); + return includeImportRanges_; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of includeImportRanges. + */ + public int getIncludeImportRangesCount() { + return includeImportRanges_.size(); + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The includeImportRanges at the given index. + */ + public java.lang.String getIncludeImportRanges(int index) { + return includeImportRanges_.get(index); + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the includeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getIncludeImportRangesBytes(int index) { + return includeImportRanges_.getByteString(index); + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The includeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setIncludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.set(index, value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The includeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addIncludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The includeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllIncludeImportRanges(java.lang.Iterable values) { + ensureIncludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, includeImportRanges_); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIncludeImportRanges() { + includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes fully encompassed by include import ranges are
    +     * included during import from hub.
    +     * 
    + * + * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the includeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addIncludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureIncludeImportRangesIsMutable(); + includeImportRanges_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList proposedIncludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureProposedIncludeImportRangesIsMutable() { + if (!proposedIncludeImportRanges_.isModifiable()) { + proposedIncludeImportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedIncludeImportRanges_); + } + bitField0_ |= 0x00000010; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedIncludeImportRangesList() { + proposedIncludeImportRanges_.makeImmutable(); + return proposedIncludeImportRanges_; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeImportRanges. + */ + public int getProposedIncludeImportRangesCount() { + return proposedIncludeImportRanges_.size(); + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeImportRanges at the given index. + */ + public java.lang.String getProposedIncludeImportRanges(int index) { + return proposedIncludeImportRanges_.get(index); + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedIncludeImportRangesBytes(int index) { + return proposedIncludeImportRanges_.getByteString(index); + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index to set the value at. + * @param value The proposedIncludeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setProposedIncludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.set(index, value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The proposedIncludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedIncludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param values The proposedIncludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllProposedIncludeImportRanges(java.lang.Iterable values) { + ensureProposedIncludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedIncludeImportRanges_); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearProposedIncludeImportRanges() { + proposedIncludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000010); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed include import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The bytes of the proposedIncludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedIncludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureProposedIncludeImportRangesIsMutable(); + proposedIncludeImportRanges_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList excludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureExcludeImportRangesIsMutable() { + if (!excludeImportRanges_.isModifiable()) { + excludeImportRanges_ = new com.google.protobuf.LazyStringArrayList(excludeImportRanges_); + } + bitField0_ |= 0x00000020; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getExcludeImportRangesList() { + excludeImportRanges_.makeImmutable(); + return excludeImportRanges_; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeImportRanges. + */ + public int getExcludeImportRangesCount() { + return excludeImportRanges_.size(); + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeImportRanges at the given index. + */ + public java.lang.String getExcludeImportRanges(int index) { + return excludeImportRanges_.get(index); + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getExcludeImportRangesBytes(int index) { + return excludeImportRanges_.getByteString(index); + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The excludeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setExcludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.set(index, value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The excludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addExcludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The excludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllExcludeImportRanges(java.lang.Iterable values) { + ensureExcludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, excludeImportRanges_); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearExcludeImportRanges() { + excludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000020); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +     * excluded during import from hub.
    +     * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the excludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addExcludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureExcludeImportRangesIsMutable(); + excludeImportRanges_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList proposedExcludeImportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureProposedExcludeImportRangesIsMutable() { + if (!proposedExcludeImportRanges_.isModifiable()) { + proposedExcludeImportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedExcludeImportRanges_); + } + bitField0_ |= 0x00000040; + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeImportRanges. + */ + public com.google.protobuf.ProtocolStringList getProposedExcludeImportRangesList() { + proposedExcludeImportRanges_.makeImmutable(); + return proposedExcludeImportRanges_; + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeImportRanges. + */ + public int getProposedExcludeImportRangesCount() { + return proposedExcludeImportRanges_.size(); + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeImportRanges at the given index. + */ + public java.lang.String getProposedExcludeImportRanges(int index) { + return proposedExcludeImportRanges_.get(index); + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeImportRanges at the given index. + */ + public com.google.protobuf.ByteString getProposedExcludeImportRangesBytes(int index) { + return proposedExcludeImportRanges_.getByteString(index); + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index to set the value at. + * @param value The proposedExcludeImportRanges to set. + * @return This builder for chaining. + */ + public Builder setProposedExcludeImportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.set(index, value); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The proposedExcludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedExcludeImportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.add(value); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param values The proposedExcludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllProposedExcludeImportRanges(java.lang.Iterable values) { + ensureProposedExcludeImportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedExcludeImportRanges_); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearProposedExcludeImportRanges() { + proposedExcludeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000040); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The proposed exclude import IP ranges waiting for hub
    +     * administrator's approval.
    +     * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The bytes of the proposedExcludeImportRanges to add. + * @return This builder for chaining. + */ + public Builder addProposedExcludeImportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); } - if (!other.getVpcNetwork().isEmpty()) { - vpcNetwork_ = other.vpcNetwork_; - bitField0_ |= 0x00000004; - onChanged(); + checkByteStringIsUtf8(value); + ensureProposedExcludeImportRangesIsMutable(); + proposedExcludeImportRanges_.add(value); + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList includeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureIncludeExportRangesIsMutable() { + if (!includeExportRanges_.isModifiable()) { + includeExportRanges_ = new com.google.protobuf.LazyStringArrayList(includeExportRanges_); } - if (!other.includeImportRanges_.isEmpty()) { - if (includeImportRanges_.isEmpty()) { - includeImportRanges_ = other.includeImportRanges_; - bitField0_ |= 0x00000008; - } else { - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.addAll(other.includeImportRanges_); - } - onChanged(); + bitField0_ |= 0x00000080; + } + + /** + * + * + *
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
    +     * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeExportRanges. + */ + public com.google.protobuf.ProtocolStringList getIncludeExportRangesList() { + includeExportRanges_.makeImmutable(); + return includeExportRanges_; + } + + /** + * + * + *
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
    +     * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of includeExportRanges. + */ + public int getIncludeExportRangesCount() { + return includeExportRanges_.size(); + } + + /** + * + * + *
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
    +     * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The includeExportRanges at the given index. + */ + public java.lang.String getIncludeExportRanges(int index) { + return includeExportRanges_.get(index); + } + + /** + * + * + *
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
    +     * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the includeExportRanges at the given index. + */ + public com.google.protobuf.ByteString getIncludeExportRangesBytes(int index) { + return includeExportRanges_.getByteString(index); + } + + /** + * + * + *
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
    +     * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The includeExportRanges to set. + * @return This builder for chaining. + */ + public Builder setIncludeExportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); } - this.mergeUnknownFields(other.getUnknownFields()); + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.set(index, value); + bitField0_ |= 0x00000080; onChanged(); return this; } - @java.lang.Override - public final boolean isInitialized() { - return true; + /** + * + * + *
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
    +     * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The includeExportRanges to add. + * @return This builder for chaining. + */ + public Builder addIncludeExportRanges(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.add(value); + bitField0_ |= 0x00000080; + onChanged(); + return this; } - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureUrisIsMutable(); - uris_.add(s); - break; - } // case 10 - case 16: - { - siteToSiteDataTransfer_ = input.readBool(); - bitField0_ |= 0x00000002; - break; - } // case 16 - case 26: - { - vpcNetwork_ = input.readStringRequireUtf8(); - bitField0_ |= 0x00000004; - break; - } // case 26 - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.add(s); - break; - } // case 42 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally + /** + * + * + *
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
    +     * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The includeExportRanges to add. + * @return This builder for chaining. + */ + public Builder addAllIncludeExportRanges(java.lang.Iterable values) { + ensureIncludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, includeExportRanges_); + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
    +     * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIncludeExportRanges() { + includeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000080); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Dynamic routes fully encompassed by include export ranges are
    +     * included during export to hub.
    +     * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the includeExportRanges to add. + * @return This builder for chaining. + */ + public Builder addIncludeExportRangesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureIncludeExportRangesIsMutable(); + includeExportRanges_.add(value); + bitField0_ |= 0x00000080; + onChanged(); return this; } - private int bitField0_; - - private com.google.protobuf.LazyStringArrayList uris_ = + private com.google.protobuf.LazyStringArrayList proposedIncludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); - private void ensureUrisIsMutable() { - if (!uris_.isModifiable()) { - uris_ = new com.google.protobuf.LazyStringArrayList(uris_); + private void ensureProposedIncludeExportRangesIsMutable() { + if (!proposedIncludeExportRanges_.isModifiable()) { + proposedIncludeExportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedIncludeExportRanges_); } - bitField0_ |= 0x00000001; + bitField0_ |= 0x00000100; } /** * * *
    -     * The URIs of linked VPN tunnel resources.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * - * @return A list containing the uris. + * @return A list containing the proposedIncludeExportRanges. */ - public com.google.protobuf.ProtocolStringList getUrisList() { - uris_.makeImmutable(); - return uris_; + public com.google.protobuf.ProtocolStringList getProposedIncludeExportRangesList() { + proposedIncludeExportRanges_.makeImmutable(); + return proposedIncludeExportRanges_; } /** * * *
    -     * The URIs of linked VPN tunnel resources.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * - * @return The count of uris. + * @return The count of proposedIncludeExportRanges. */ - public int getUrisCount() { - return uris_.size(); + public int getProposedIncludeExportRangesCount() { + return proposedIncludeExportRanges_.size(); } /** * * *
    -     * The URIs of linked VPN tunnel resources.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index of the element to return. - * @return The uris at the given index. + * @return The proposedIncludeExportRanges at the given index. */ - public java.lang.String getUris(int index) { - return uris_.get(index); + public java.lang.String getProposedIncludeExportRanges(int index) { + return proposedIncludeExportRanges_.get(index); } /** * * *
    -     * The URIs of linked VPN tunnel resources.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index of the value to return. - * @return The bytes of the uris at the given index. + * @return The bytes of the proposedIncludeExportRanges at the given index. */ - public com.google.protobuf.ByteString getUrisBytes(int index) { - return uris_.getByteString(index); + public com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int index) { + return proposedIncludeExportRanges_.getByteString(index); } /** * * *
    -     * The URIs of linked VPN tunnel resources.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index to set the value at. - * @param value The uris to set. + * @param value The proposedIncludeExportRanges to set. * @return This builder for chaining. */ - public Builder setUris(int index, java.lang.String value) { + public Builder setProposedIncludeExportRanges(int index, java.lang.String value) { if (value == null) { throw new NullPointerException(); } - ensureUrisIsMutable(); - uris_.set(index, value); - bitField0_ |= 0x00000001; + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.set(index, value); + bitField0_ |= 0x00000100; onChanged(); return this; } @@ -814,21 +3046,24 @@ public Builder setUris(int index, java.lang.String value) { * * *
    -     * The URIs of linked VPN tunnel resources.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * - * @param value The uris to add. + * @param value The proposedIncludeExportRanges to add. * @return This builder for chaining. */ - public Builder addUris(java.lang.String value) { + public Builder addProposedIncludeExportRanges(java.lang.String value) { if (value == null) { throw new NullPointerException(); } - ensureUrisIsMutable(); - uris_.add(value); - bitField0_ |= 0x00000001; + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.add(value); + bitField0_ |= 0x00000100; onChanged(); return this; } @@ -837,18 +3072,21 @@ public Builder addUris(java.lang.String value) { * * *
    -     * The URIs of linked VPN tunnel resources.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * - * @param values The uris to add. + * @param values The proposedIncludeExportRanges to add. * @return This builder for chaining. */ - public Builder addAllUris(java.lang.Iterable values) { - ensureUrisIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, uris_); - bitField0_ |= 0x00000001; + public Builder addAllProposedIncludeExportRanges(java.lang.Iterable values) { + ensureProposedIncludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedIncludeExportRanges_); + bitField0_ |= 0x00000100; onChanged(); return this; } @@ -857,16 +3095,19 @@ public Builder addAllUris(java.lang.Iterable values) { * * *
    -     * The URIs of linked VPN tunnel resources.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return This builder for chaining. */ - public Builder clearUris() { - uris_ = com.google.protobuf.LazyStringArrayList.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); + public Builder clearProposedIncludeExportRanges() { + proposedIncludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000100); ; onChanged(); return this; @@ -876,160 +3117,157 @@ public Builder clearUris() { * * *
    -     * The URIs of linked VPN tunnel resources.
    +     * Output only. The proposed include export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string uris = 1 [(.google.api.resource_reference) = { ... } + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * - * @param value The bytes of the uris to add. + * @param value The bytes of the proposedIncludeExportRanges to add. * @return This builder for chaining. */ - public Builder addUrisBytes(com.google.protobuf.ByteString value) { + public Builder addProposedIncludeExportRangesBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - ensureUrisIsMutable(); - uris_.add(value); - bitField0_ |= 0x00000001; + ensureProposedIncludeExportRangesIsMutable(); + proposedIncludeExportRanges_.add(value); + bitField0_ |= 0x00000100; onChanged(); return this; } - private boolean siteToSiteDataTransfer_; + private com.google.protobuf.LazyStringArrayList excludeExportRanges_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureExcludeExportRangesIsMutable() { + if (!excludeExportRanges_.isModifiable()) { + excludeExportRanges_ = new com.google.protobuf.LazyStringArrayList(excludeExportRanges_); + } + bitField0_ |= 0x00000200; + } /** * * *
    -     * A value that controls whether site-to-site data transfer is enabled for
    -     * these resources. Data transfer is available only in [supported
    -     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * bool site_to_site_data_transfer = 2; + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * * - * @return The siteToSiteDataTransfer. + * @return A list containing the excludeExportRanges. */ - @java.lang.Override - public boolean getSiteToSiteDataTransfer() { - return siteToSiteDataTransfer_; + public com.google.protobuf.ProtocolStringList getExcludeExportRangesList() { + excludeExportRanges_.makeImmutable(); + return excludeExportRanges_; } /** * * *
    -     * A value that controls whether site-to-site data transfer is enabled for
    -     * these resources. Data transfer is available only in [supported
    -     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * bool site_to_site_data_transfer = 2; + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * * - * @param value The siteToSiteDataTransfer to set. - * @return This builder for chaining. + * @return The count of excludeExportRanges. */ - public Builder setSiteToSiteDataTransfer(boolean value) { - - siteToSiteDataTransfer_ = value; - bitField0_ |= 0x00000002; - onChanged(); - return this; + public int getExcludeExportRangesCount() { + return excludeExportRanges_.size(); } /** * * *
    -     * A value that controls whether site-to-site data transfer is enabled for
    -     * these resources. Data transfer is available only in [supported
    -     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * bool site_to_site_data_transfer = 2; + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * * - * @return This builder for chaining. + * @param index The index of the element to return. + * @return The excludeExportRanges at the given index. */ - public Builder clearSiteToSiteDataTransfer() { - bitField0_ = (bitField0_ & ~0x00000002); - siteToSiteDataTransfer_ = false; - onChanged(); - return this; + public java.lang.String getExcludeExportRanges(int index) { + return excludeExportRanges_.get(index); } - private java.lang.Object vpcNetwork_ = ""; - /** * * *
    -     * Output only. The VPC network where these VPN tunnels are located.
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @return The vpcNetwork. + * @param index The index of the value to return. + * @return The bytes of the excludeExportRanges at the given index. */ - public java.lang.String getVpcNetwork() { - java.lang.Object ref = vpcNetwork_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - vpcNetwork_ = s; - return s; - } else { - return (java.lang.String) ref; - } + public com.google.protobuf.ByteString getExcludeExportRangesBytes(int index) { + return excludeExportRanges_.getByteString(index); } /** * * *
    -     * Output only. The VPC network where these VPN tunnels are located.
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @return The bytes for vpcNetwork. + * @param index The index to set the value at. + * @param value The excludeExportRanges to set. + * @return This builder for chaining. */ - public com.google.protobuf.ByteString getVpcNetworkBytes() { - java.lang.Object ref = vpcNetwork_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - vpcNetwork_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; + public Builder setExcludeExportRanges(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); } + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.set(index, value); + bitField0_ |= 0x00000200; + onChanged(); + return this; } /** * * *
    -     * Output only. The VPC network where these VPN tunnels are located.
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @param value The vpcNetwork to set. + * @param value The excludeExportRanges to add. * @return This builder for chaining. */ - public Builder setVpcNetwork(java.lang.String value) { + public Builder addExcludeExportRanges(java.lang.String value) { if (value == null) { throw new NullPointerException(); } - vpcNetwork_ = value; - bitField0_ |= 0x00000004; + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.add(value); + bitField0_ |= 0x00000200; onChanged(); return this; } @@ -1038,18 +3276,20 @@ public Builder setVpcNetwork(java.lang.String value) { * * *
    -     * Output only. The VPC network where these VPN tunnels are located.
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * + * @param values The excludeExportRanges to add. * @return This builder for chaining. */ - public Builder clearVpcNetwork() { - vpcNetwork_ = getDefaultInstance().getVpcNetwork(); - bitField0_ = (bitField0_ & ~0x00000004); + public Builder addAllExcludeExportRanges(java.lang.Iterable values) { + ensureExcludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, excludeExportRanges_); + bitField0_ |= 0x00000200; onChanged(); return this; } @@ -1058,135 +3298,158 @@ public Builder clearVpcNetwork() { * * *
    -     * Output only. The VPC network where these VPN tunnels are located.
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
          * 
    * - * - * string vpc_network = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; * * - * @param value The bytes for vpcNetwork to set. * @return This builder for chaining. */ - public Builder setVpcNetworkBytes(com.google.protobuf.ByteString value) { + public Builder clearExcludeExportRanges() { + excludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000200); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +     * are excluded during export to hub.
    +     * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the excludeExportRanges to add. + * @return This builder for chaining. + */ + public Builder addExcludeExportRangesBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - vpcNetwork_ = value; - bitField0_ |= 0x00000004; + ensureExcludeExportRangesIsMutable(); + excludeExportRanges_.add(value); + bitField0_ |= 0x00000200; onChanged(); return this; } - private com.google.protobuf.LazyStringArrayList includeImportRanges_ = + private com.google.protobuf.LazyStringArrayList proposedExcludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); - private void ensureIncludeImportRangesIsMutable() { - if (!includeImportRanges_.isModifiable()) { - includeImportRanges_ = new com.google.protobuf.LazyStringArrayList(includeImportRanges_); + private void ensureProposedExcludeExportRangesIsMutable() { + if (!proposedExcludeExportRanges_.isModifiable()) { + proposedExcludeExportRanges_ = + new com.google.protobuf.LazyStringArrayList(proposedExcludeExportRanges_); } - bitField0_ |= 0x00000008; + bitField0_ |= 0x00000400; } /** * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @return A list containing the includeImportRanges. + * @return A list containing the proposedExcludeExportRanges. */ - public com.google.protobuf.ProtocolStringList getIncludeImportRangesList() { - includeImportRanges_.makeImmutable(); - return includeImportRanges_; + public com.google.protobuf.ProtocolStringList getProposedExcludeExportRangesList() { + proposedExcludeExportRanges_.makeImmutable(); + return proposedExcludeExportRanges_; } /** * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @return The count of includeImportRanges. + * @return The count of proposedExcludeExportRanges. */ - public int getIncludeImportRangesCount() { - return includeImportRanges_.size(); + public int getProposedExcludeExportRangesCount() { + return proposedExcludeExportRanges_.size(); } /** * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. - * @return The includeImportRanges at the given index. + * @return The proposedExcludeExportRanges at the given index. */ - public java.lang.String getIncludeImportRanges(int index) { - return includeImportRanges_.get(index); + public java.lang.String getProposedExcludeExportRanges(int index) { + return proposedExcludeExportRanges_.get(index); } /** * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. - * @return The bytes of the includeImportRanges at the given index. + * @return The bytes of the proposedExcludeExportRanges at the given index. */ - public com.google.protobuf.ByteString getIncludeImportRangesBytes(int index) { - return includeImportRanges_.getByteString(index); + public com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int index) { + return proposedExcludeExportRanges_.getByteString(index); } /** * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index to set the value at. - * @param value The includeImportRanges to set. + * @param value The proposedExcludeExportRanges to set. * @return This builder for chaining. */ - public Builder setIncludeImportRanges(int index, java.lang.String value) { + public Builder setProposedExcludeExportRanges(int index, java.lang.String value) { if (value == null) { throw new NullPointerException(); } - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.set(index, value); - bitField0_ |= 0x00000008; + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.set(index, value); + bitField0_ |= 0x00000400; onChanged(); return this; } @@ -1195,24 +3458,24 @@ public Builder setIncludeImportRanges(int index, java.lang.String value) { * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @param value The includeImportRanges to add. + * @param value The proposedExcludeExportRanges to add. * @return This builder for chaining. */ - public Builder addIncludeImportRanges(java.lang.String value) { + public Builder addProposedExcludeExportRanges(java.lang.String value) { if (value == null) { throw new NullPointerException(); } - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.add(value); - bitField0_ |= 0x00000008; + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.add(value); + bitField0_ |= 0x00000400; onChanged(); return this; } @@ -1221,21 +3484,21 @@ public Builder addIncludeImportRanges(java.lang.String value) { * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @param values The includeImportRanges to add. + * @param values The proposedExcludeExportRanges to add. * @return This builder for chaining. */ - public Builder addAllIncludeImportRanges(java.lang.Iterable values) { - ensureIncludeImportRangesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, includeImportRanges_); - bitField0_ |= 0x00000008; + public Builder addAllProposedExcludeExportRanges(java.lang.Iterable values) { + ensureProposedExcludeExportRangesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, proposedExcludeExportRanges_); + bitField0_ |= 0x00000400; onChanged(); return this; } @@ -1244,19 +3507,19 @@ public Builder addAllIncludeImportRanges(java.lang.Iterable va * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return This builder for chaining. */ - public Builder clearIncludeImportRanges() { - includeImportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); + public Builder clearProposedExcludeExportRanges() { + proposedExcludeExportRanges_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000400); ; onChanged(); return this; @@ -1266,25 +3529,25 @@ public Builder clearIncludeImportRanges() { * * *
    -     * Optional. IP ranges allowed to be included during import from hub (does not
    -     * control transit connectivity). The only allowed value for now is
    -     * "ALL_IPV4_RANGES".
    +     * Output only. The proposed exclude export IP ranges waiting for hub
    +     * administrator's approval.
          * 
    * - * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * - * @param value The bytes of the includeImportRanges to add. + * @param value The bytes of the proposedExcludeExportRanges to add. * @return This builder for chaining. */ - public Builder addIncludeImportRangesBytes(com.google.protobuf.ByteString value) { + public Builder addProposedExcludeExportRangesBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - ensureIncludeImportRangesIsMutable(); - includeImportRanges_.add(value); - bitField0_ |= 0x00000008; + ensureProposedExcludeExportRangesIsMutable(); + proposedExcludeExportRanges_.add(value); + bitField0_ |= 0x00000400; onChanged(); return this; } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnelsOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnelsOrBuilder.java index eb88767066ea..64905bad9a33 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnelsOrBuilder.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LinkedVpnTunnelsOrBuilder.java @@ -129,9 +129,8 @@ public interface LinkedVpnTunnelsOrBuilder * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -145,9 +144,8 @@ public interface LinkedVpnTunnelsOrBuilder * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -161,9 +159,8 @@ public interface LinkedVpnTunnelsOrBuilder * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -178,9 +175,8 @@ public interface LinkedVpnTunnelsOrBuilder * * *
    -   * Optional. IP ranges allowed to be included during import from hub (does not
    -   * control transit connectivity). The only allowed value for now is
    -   * "ALL_IPV4_RANGES".
    +   * Optional. Hub routes fully encompassed by include import ranges are
    +   * included during import from hub.
        * 
    * * repeated string include_import_ranges = 5 [(.google.api.field_behavior) = OPTIONAL]; @@ -190,4 +186,454 @@ public interface LinkedVpnTunnelsOrBuilder * @return The bytes of the includeImportRanges at the given index. */ com.google.protobuf.ByteString getIncludeImportRangesBytes(int index); + + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeImportRanges. + */ + java.util.List getProposedIncludeImportRangesList(); + + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeImportRanges. + */ + int getProposedIncludeImportRangesCount(); + + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeImportRanges at the given index. + */ + java.lang.String getProposedIncludeImportRanges(int index); + + /** + * + * + *
    +   * Output only. The proposed include import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_import_ranges = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeImportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedIncludeImportRangesBytes(int index); + + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeImportRanges. + */ + java.util.List getExcludeImportRangesList(); + + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeImportRanges. + */ + int getExcludeImportRangesCount(); + + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeImportRanges at the given index. + */ + java.lang.String getExcludeImportRanges(int index); + + /** + * + * + *
    +   * Optional. Hub routes overlapped/encompassed by exclude import ranges are
    +   * excluded during import from hub.
    +   * 
    + * + * repeated string exclude_import_ranges = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeImportRanges at the given index. + */ + com.google.protobuf.ByteString getExcludeImportRangesBytes(int index); + + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeImportRanges. + */ + java.util.List getProposedExcludeImportRangesList(); + + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeImportRanges. + */ + int getProposedExcludeImportRangesCount(); + + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeImportRanges at the given index. + */ + java.lang.String getProposedExcludeImportRanges(int index); + + /** + * + * + *
    +   * Output only. The proposed exclude import IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_import_ranges = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeImportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedExcludeImportRangesBytes(int index); + + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the includeExportRanges. + */ + java.util.List getIncludeExportRangesList(); + + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of includeExportRanges. + */ + int getIncludeExportRangesCount(); + + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The includeExportRanges at the given index. + */ + java.lang.String getIncludeExportRanges(int index); + + /** + * + * + *
    +   * Optional. Dynamic routes fully encompassed by include export ranges are
    +   * included during export to hub.
    +   * 
    + * + * repeated string include_export_ranges = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the includeExportRanges at the given index. + */ + com.google.protobuf.ByteString getIncludeExportRangesBytes(int index); + + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedIncludeExportRanges. + */ + java.util.List getProposedIncludeExportRangesList(); + + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedIncludeExportRanges. + */ + int getProposedIncludeExportRangesCount(); + + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedIncludeExportRanges at the given index. + */ + java.lang.String getProposedIncludeExportRanges(int index); + + /** + * + * + *
    +   * Output only. The proposed include export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_include_export_ranges = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedIncludeExportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedIncludeExportRangesBytes(int index); + + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the excludeExportRanges. + */ + java.util.List getExcludeExportRangesList(); + + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of excludeExportRanges. + */ + int getExcludeExportRangesCount(); + + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The excludeExportRanges at the given index. + */ + java.lang.String getExcludeExportRanges(int index); + + /** + * + * + *
    +   * Optional. Dynamic routes overlapped/encompassed by exclude export ranges
    +   * are excluded during export to hub.
    +   * 
    + * + * repeated string exclude_export_ranges = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the excludeExportRanges at the given index. + */ + com.google.protobuf.ByteString getExcludeExportRangesBytes(int index); + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return A list containing the proposedExcludeExportRanges. + */ + java.util.List getProposedExcludeExportRangesList(); + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The count of proposedExcludeExportRanges. + */ + int getProposedExcludeExportRangesCount(); + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the element to return. + * @return The proposedExcludeExportRanges at the given index. + */ + java.lang.String getProposedExcludeExportRanges(int index); + + /** + * + * + *
    +   * Output only. The proposed exclude export IP ranges waiting for hub
    +   * administrator's approval.
    +   * 
    + * + * + * repeated string proposed_exclude_export_ranges = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param index The index of the value to return. + * @return The bytes of the proposedExcludeExportRanges at the given index. + */ + com.google.protobuf.ByteString getProposedExcludeExportRangesBytes(int index); } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesRequest.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesRequest.java new file mode 100644 index 000000000000..4124c51ffae7 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesRequest.java @@ -0,0 +1,1343 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +/** + * + * + *
    + * The request for
    + * [HubService.ListGatewayAdvertisedRoutes][google.cloud.networkconnectivity.v1.HubService.ListGatewayAdvertisedRoutes].
    + * 
    + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest} + */ +@com.google.protobuf.Generated +public final class ListGatewayAdvertisedRoutesRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest) + ListGatewayAdvertisedRoutesRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListGatewayAdvertisedRoutesRequest"); + } + + // Use ListGatewayAdvertisedRoutesRequest.newBuilder() to construct. + private ListGatewayAdvertisedRoutesRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListGatewayAdvertisedRoutesRequest() { + parent_ = ""; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest.class, + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest.Builder + .class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
    +   * Required. The parent resource's name.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
    +   * Required. The parent resource's name.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
    +   * Optional. The maximum number of results per page that should be returned.
    +   * 
    + * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
    +   * Optional. A page token, received from a previous
    +   * `ListGatewayAdvertisedRoutes` call. Provide this to retrieve the subsequent
    +   * page.
    +   *
    +   * When paginating, all other parameters provided to
    +   * `ListGatewayAdvertisedRoutes` must match the call that provided the page
    +   * token.
    +   * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
    +   * Optional. A page token, received from a previous
    +   * `ListGatewayAdvertisedRoutes` call. Provide this to retrieve the subsequent
    +   * page.
    +   *
    +   * When paginating, all other parameters provided to
    +   * `ListGatewayAdvertisedRoutes` must match the call that provided the page
    +   * token.
    +   * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object filter_ = ""; + + /** + * + * + *
    +   * An expression that filters the list of results.
    +   * 
    + * + * string filter = 4; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + + /** + * + * + *
    +   * An expression that filters the list of results.
    +   * 
    + * + * string filter = 4; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ORDER_BY_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object orderBy_ = ""; + + /** + * + * + *
    +   * Sort the results by a certain order.
    +   * 
    + * + * string order_by = 5; + * + * @return The orderBy. + */ + @java.lang.Override + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } + } + + /** + * + * + *
    +   * Sort the results by a certain order.
    +   * 
    + * + * string order_by = 5; + * + * @return The bytes for orderBy. + */ + @java.lang.Override + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, filter_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, orderBy_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, filter_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, orderBy_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest other = + (com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (37 * hash) + ORDER_BY_FIELD_NUMBER; + hash = (53 * hash) + getOrderBy().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * The request for
    +   * [HubService.ListGatewayAdvertisedRoutes][google.cloud.networkconnectivity.v1.HubService.ListGatewayAdvertisedRoutes].
    +   * 
    + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest) + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest.class, + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest.Builder + .class); + } + + // Construct using + // com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest build() { + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + buildPartial() { + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest result = + new com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.filter_ = filter_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.orderBy_ = orderBy_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest) { + return mergeFrom( + (com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest other) { + if (other + == com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + .getDefaultInstance()) return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (!other.getOrderBy().isEmpty()) { + orderBy_ = other.orderBy_; + bitField0_ |= 0x00000010; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + filter_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + orderBy_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
    +     * Required. The parent resource's name.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Required. The parent resource's name.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Required. The parent resource's name.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The parent resource's name.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The parent resource's name.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
    +     * Optional. The maximum number of results per page that should be returned.
    +     * 
    + * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
    +     * Optional. The maximum number of results per page that should be returned.
    +     * 
    + * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. The maximum number of results per page that should be returned.
    +     * 
    + * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
    +     * Optional. A page token, received from a previous
    +     * `ListGatewayAdvertisedRoutes` call. Provide this to retrieve the subsequent
    +     * page.
    +     *
    +     * When paginating, all other parameters provided to
    +     * `ListGatewayAdvertisedRoutes` must match the call that provided the page
    +     * token.
    +     * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Optional. A page token, received from a previous
    +     * `ListGatewayAdvertisedRoutes` call. Provide this to retrieve the subsequent
    +     * page.
    +     *
    +     * When paginating, all other parameters provided to
    +     * `ListGatewayAdvertisedRoutes` must match the call that provided the page
    +     * token.
    +     * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Optional. A page token, received from a previous
    +     * `ListGatewayAdvertisedRoutes` call. Provide this to retrieve the subsequent
    +     * page.
    +     *
    +     * When paginating, all other parameters provided to
    +     * `ListGatewayAdvertisedRoutes` must match the call that provided the page
    +     * token.
    +     * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. A page token, received from a previous
    +     * `ListGatewayAdvertisedRoutes` call. Provide this to retrieve the subsequent
    +     * page.
    +     *
    +     * When paginating, all other parameters provided to
    +     * `ListGatewayAdvertisedRoutes` must match the call that provided the page
    +     * token.
    +     * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. A page token, received from a previous
    +     * `ListGatewayAdvertisedRoutes` call. Provide this to retrieve the subsequent
    +     * page.
    +     *
    +     * When paginating, all other parameters provided to
    +     * `ListGatewayAdvertisedRoutes` must match the call that provided the page
    +     * token.
    +     * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + + /** + * + * + *
    +     * An expression that filters the list of results.
    +     * 
    + * + * string filter = 4; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * An expression that filters the list of results.
    +     * 
    + * + * string filter = 4; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * An expression that filters the list of results.
    +     * 
    + * + * string filter = 4; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * An expression that filters the list of results.
    +     * 
    + * + * string filter = 4; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + filter_ = getDefaultInstance().getFilter(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
    +     * An expression that filters the list of results.
    +     * 
    + * + * string filter = 4; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private java.lang.Object orderBy_ = ""; + + /** + * + * + *
    +     * Sort the results by a certain order.
    +     * 
    + * + * string order_by = 5; + * + * @return The orderBy. + */ + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Sort the results by a certain order.
    +     * 
    + * + * string order_by = 5; + * + * @return The bytes for orderBy. + */ + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Sort the results by a certain order.
    +     * 
    + * + * string order_by = 5; + * + * @param value The orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderBy(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + orderBy_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Sort the results by a certain order.
    +     * 
    + * + * string order_by = 5; + * + * @return This builder for chaining. + */ + public Builder clearOrderBy() { + orderBy_ = getDefaultInstance().getOrderBy(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Sort the results by a certain order.
    +     * 
    + * + * string order_by = 5; + * + * @param value The bytes for orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + orderBy_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest) + private static final com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest(); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListGatewayAdvertisedRoutesRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesRequestOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesRequestOrBuilder.java new file mode 100644 index 000000000000..8eb6fe8bd6ee --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesRequestOrBuilder.java @@ -0,0 +1,161 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +@com.google.protobuf.Generated +public interface ListGatewayAdvertisedRoutesRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * Required. The parent resource's name.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
    +   * Required. The parent resource's name.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
    +   * Optional. The maximum number of results per page that should be returned.
    +   * 
    + * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
    +   * Optional. A page token, received from a previous
    +   * `ListGatewayAdvertisedRoutes` call. Provide this to retrieve the subsequent
    +   * page.
    +   *
    +   * When paginating, all other parameters provided to
    +   * `ListGatewayAdvertisedRoutes` must match the call that provided the page
    +   * token.
    +   * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
    +   * Optional. A page token, received from a previous
    +   * `ListGatewayAdvertisedRoutes` call. Provide this to retrieve the subsequent
    +   * page.
    +   *
    +   * When paginating, all other parameters provided to
    +   * `ListGatewayAdvertisedRoutes` must match the call that provided the page
    +   * token.
    +   * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
    +   * An expression that filters the list of results.
    +   * 
    + * + * string filter = 4; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
    +   * An expression that filters the list of results.
    +   * 
    + * + * string filter = 4; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
    +   * Sort the results by a certain order.
    +   * 
    + * + * string order_by = 5; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + + /** + * + * + *
    +   * Sort the results by a certain order.
    +   * 
    + * + * string order_by = 5; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesResponse.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesResponse.java new file mode 100644 index 000000000000..c664a1ef136c --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesResponse.java @@ -0,0 +1,1522 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +/** + * + * + *
    + * Response for
    + * [HubService.ListGatewayAdvertisedRoutes][google.cloud.networkconnectivity.v1.HubService.ListGatewayAdvertisedRoutes]
    + * method.
    + * 
    + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse} + */ +@com.google.protobuf.Generated +public final class ListGatewayAdvertisedRoutesResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse) + ListGatewayAdvertisedRoutesResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListGatewayAdvertisedRoutesResponse"); + } + + // Use ListGatewayAdvertisedRoutesResponse.newBuilder() to construct. + private ListGatewayAdvertisedRoutesResponse( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListGatewayAdvertisedRoutesResponse() { + gatewayAdvertisedRoutes_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse.class, + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse.Builder + .class); + } + + public static final int GATEWAY_ADVERTISED_ROUTES_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List + gatewayAdvertisedRoutes_; + + /** + * + * + *
    +   * The requested gateway advertised routes.
    +   * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + @java.lang.Override + public java.util.List + getGatewayAdvertisedRoutesList() { + return gatewayAdvertisedRoutes_; + } + + /** + * + * + *
    +   * The requested gateway advertised routes.
    +   * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder> + getGatewayAdvertisedRoutesOrBuilderList() { + return gatewayAdvertisedRoutes_; + } + + /** + * + * + *
    +   * The requested gateway advertised routes.
    +   * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + @java.lang.Override + public int getGatewayAdvertisedRoutesCount() { + return gatewayAdvertisedRoutes_.size(); + } + + /** + * + * + *
    +   * The requested gateway advertised routes.
    +   * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute getGatewayAdvertisedRoutes( + int index) { + return gatewayAdvertisedRoutes_.get(index); + } + + /** + * + * + *
    +   * The requested gateway advertised routes.
    +   * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder + getGatewayAdvertisedRoutesOrBuilder(int index) { + return gatewayAdvertisedRoutes_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
    +   * The token for the next page of the response. To see more results,
    +   * use this value as the page_token for your next request. If this value
    +   * is empty, there are no more results.
    +   * 
    + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
    +   * The token for the next page of the response. To see more results,
    +   * use this value as the page_token for your next request. If this value
    +   * is empty, there are no more results.
    +   * 
    + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UNREACHABLE_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList unreachable_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
    +   * Hubs that could not be reached.
    +   * 
    + * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_; + } + + /** + * + * + *
    +   * Hubs that could not be reached.
    +   * 
    + * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + + /** + * + * + *
    +   * Hubs that could not be reached.
    +   * 
    + * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + + /** + * + * + *
    +   * Hubs that could not be reached.
    +   * 
    + * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < gatewayAdvertisedRoutes_.size(); i++) { + output.writeMessage(1, gatewayAdvertisedRoutes_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + for (int i = 0; i < unreachable_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, unreachable_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < gatewayAdvertisedRoutes_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, gatewayAdvertisedRoutes_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + { + int dataSize = 0; + for (int i = 0; i < unreachable_.size(); i++) { + dataSize += computeStringSizeNoTag(unreachable_.getRaw(i)); + } + size += dataSize; + size += 1 * getUnreachableList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse other = + (com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse) obj; + + if (!getGatewayAdvertisedRoutesList().equals(other.getGatewayAdvertisedRoutesList())) + return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getGatewayAdvertisedRoutesCount() > 0) { + hash = (37 * hash) + GATEWAY_ADVERTISED_ROUTES_FIELD_NUMBER; + hash = (53 * hash) + getGatewayAdvertisedRoutesList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (getUnreachableCount() > 0) { + hash = (37 * hash) + UNREACHABLE_FIELD_NUMBER; + hash = (53 * hash) + getUnreachableList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * Response for
    +   * [HubService.ListGatewayAdvertisedRoutes][google.cloud.networkconnectivity.v1.HubService.ListGatewayAdvertisedRoutes]
    +   * method.
    +   * 
    + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse) + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse.class, + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse.Builder + .class); + } + + // Construct using + // com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (gatewayAdvertisedRoutesBuilder_ == null) { + gatewayAdvertisedRoutes_ = java.util.Collections.emptyList(); + } else { + gatewayAdvertisedRoutes_ = null; + gatewayAdvertisedRoutesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_ListGatewayAdvertisedRoutesResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse build() { + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + buildPartial() { + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse result = + new com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse result) { + if (gatewayAdvertisedRoutesBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + gatewayAdvertisedRoutes_ = + java.util.Collections.unmodifiableList(gatewayAdvertisedRoutes_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.gatewayAdvertisedRoutes_ = gatewayAdvertisedRoutes_; + } else { + result.gatewayAdvertisedRoutes_ = gatewayAdvertisedRoutesBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + unreachable_.makeImmutable(); + result.unreachable_ = unreachable_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse) { + return mergeFrom( + (com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse other) { + if (other + == com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + .getDefaultInstance()) return this; + if (gatewayAdvertisedRoutesBuilder_ == null) { + if (!other.gatewayAdvertisedRoutes_.isEmpty()) { + if (gatewayAdvertisedRoutes_.isEmpty()) { + gatewayAdvertisedRoutes_ = other.gatewayAdvertisedRoutes_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureGatewayAdvertisedRoutesIsMutable(); + gatewayAdvertisedRoutes_.addAll(other.gatewayAdvertisedRoutes_); + } + onChanged(); + } + } else { + if (!other.gatewayAdvertisedRoutes_.isEmpty()) { + if (gatewayAdvertisedRoutesBuilder_.isEmpty()) { + gatewayAdvertisedRoutesBuilder_.dispose(); + gatewayAdvertisedRoutesBuilder_ = null; + gatewayAdvertisedRoutes_ = other.gatewayAdvertisedRoutes_; + bitField0_ = (bitField0_ & ~0x00000001); + gatewayAdvertisedRoutesBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetGatewayAdvertisedRoutesFieldBuilder() + : null; + } else { + gatewayAdvertisedRoutesBuilder_.addAllMessages(other.gatewayAdvertisedRoutes_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.unreachable_.isEmpty()) { + if (unreachable_.isEmpty()) { + unreachable_ = other.unreachable_; + bitField0_ |= 0x00000004; + } else { + ensureUnreachableIsMutable(); + unreachable_.addAll(other.unreachable_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute m = + input.readMessage( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.parser(), + extensionRegistry); + if (gatewayAdvertisedRoutesBuilder_ == null) { + ensureGatewayAdvertisedRoutesIsMutable(); + gatewayAdvertisedRoutes_.add(m); + } else { + gatewayAdvertisedRoutesBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List + gatewayAdvertisedRoutes_ = java.util.Collections.emptyList(); + + private void ensureGatewayAdvertisedRoutesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + gatewayAdvertisedRoutes_ = + new java.util.ArrayList( + gatewayAdvertisedRoutes_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder> + gatewayAdvertisedRoutesBuilder_; + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public java.util.List + getGatewayAdvertisedRoutesList() { + if (gatewayAdvertisedRoutesBuilder_ == null) { + return java.util.Collections.unmodifiableList(gatewayAdvertisedRoutes_); + } else { + return gatewayAdvertisedRoutesBuilder_.getMessageList(); + } + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public int getGatewayAdvertisedRoutesCount() { + if (gatewayAdvertisedRoutesBuilder_ == null) { + return gatewayAdvertisedRoutes_.size(); + } else { + return gatewayAdvertisedRoutesBuilder_.getCount(); + } + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + getGatewayAdvertisedRoutes(int index) { + if (gatewayAdvertisedRoutesBuilder_ == null) { + return gatewayAdvertisedRoutes_.get(index); + } else { + return gatewayAdvertisedRoutesBuilder_.getMessage(index); + } + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public Builder setGatewayAdvertisedRoutes( + int index, com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute value) { + if (gatewayAdvertisedRoutesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureGatewayAdvertisedRoutesIsMutable(); + gatewayAdvertisedRoutes_.set(index, value); + onChanged(); + } else { + gatewayAdvertisedRoutesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public Builder setGatewayAdvertisedRoutes( + int index, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder builderForValue) { + if (gatewayAdvertisedRoutesBuilder_ == null) { + ensureGatewayAdvertisedRoutesIsMutable(); + gatewayAdvertisedRoutes_.set(index, builderForValue.build()); + onChanged(); + } else { + gatewayAdvertisedRoutesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public Builder addGatewayAdvertisedRoutes( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute value) { + if (gatewayAdvertisedRoutesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureGatewayAdvertisedRoutesIsMutable(); + gatewayAdvertisedRoutes_.add(value); + onChanged(); + } else { + gatewayAdvertisedRoutesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public Builder addGatewayAdvertisedRoutes( + int index, com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute value) { + if (gatewayAdvertisedRoutesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureGatewayAdvertisedRoutesIsMutable(); + gatewayAdvertisedRoutes_.add(index, value); + onChanged(); + } else { + gatewayAdvertisedRoutesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public Builder addGatewayAdvertisedRoutes( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder builderForValue) { + if (gatewayAdvertisedRoutesBuilder_ == null) { + ensureGatewayAdvertisedRoutesIsMutable(); + gatewayAdvertisedRoutes_.add(builderForValue.build()); + onChanged(); + } else { + gatewayAdvertisedRoutesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public Builder addGatewayAdvertisedRoutes( + int index, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder builderForValue) { + if (gatewayAdvertisedRoutesBuilder_ == null) { + ensureGatewayAdvertisedRoutesIsMutable(); + gatewayAdvertisedRoutes_.add(index, builderForValue.build()); + onChanged(); + } else { + gatewayAdvertisedRoutesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public Builder addAllGatewayAdvertisedRoutes( + java.lang.Iterable + values) { + if (gatewayAdvertisedRoutesBuilder_ == null) { + ensureGatewayAdvertisedRoutesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, gatewayAdvertisedRoutes_); + onChanged(); + } else { + gatewayAdvertisedRoutesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public Builder clearGatewayAdvertisedRoutes() { + if (gatewayAdvertisedRoutesBuilder_ == null) { + gatewayAdvertisedRoutes_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + gatewayAdvertisedRoutesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public Builder removeGatewayAdvertisedRoutes(int index) { + if (gatewayAdvertisedRoutesBuilder_ == null) { + ensureGatewayAdvertisedRoutesIsMutable(); + gatewayAdvertisedRoutes_.remove(index); + onChanged(); + } else { + gatewayAdvertisedRoutesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder + getGatewayAdvertisedRoutesBuilder(int index) { + return internalGetGatewayAdvertisedRoutesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder + getGatewayAdvertisedRoutesOrBuilder(int index) { + if (gatewayAdvertisedRoutesBuilder_ == null) { + return gatewayAdvertisedRoutes_.get(index); + } else { + return gatewayAdvertisedRoutesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public java.util.List< + ? extends com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder> + getGatewayAdvertisedRoutesOrBuilderList() { + if (gatewayAdvertisedRoutesBuilder_ != null) { + return gatewayAdvertisedRoutesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(gatewayAdvertisedRoutes_); + } + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder + addGatewayAdvertisedRoutesBuilder() { + return internalGetGatewayAdvertisedRoutesFieldBuilder() + .addBuilder( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance()); + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder + addGatewayAdvertisedRoutesBuilder(int index) { + return internalGetGatewayAdvertisedRoutesFieldBuilder() + .addBuilder( + index, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance()); + } + + /** + * + * + *
    +     * The requested gateway advertised routes.
    +     * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + public java.util.List + getGatewayAdvertisedRoutesBuilderList() { + return internalGetGatewayAdvertisedRoutesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder> + internalGetGatewayAdvertisedRoutesFieldBuilder() { + if (gatewayAdvertisedRoutesBuilder_ == null) { + gatewayAdvertisedRoutesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder>( + gatewayAdvertisedRoutes_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + gatewayAdvertisedRoutes_ = null; + } + return gatewayAdvertisedRoutesBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
    +     * The token for the next page of the response. To see more results,
    +     * use this value as the page_token for your next request. If this value
    +     * is empty, there are no more results.
    +     * 
    + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * The token for the next page of the response. To see more results,
    +     * use this value as the page_token for your next request. If this value
    +     * is empty, there are no more results.
    +     * 
    + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * The token for the next page of the response. To see more results,
    +     * use this value as the page_token for your next request. If this value
    +     * is empty, there are no more results.
    +     * 
    + * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * The token for the next page of the response. To see more results,
    +     * use this value as the page_token for your next request. If this value
    +     * is empty, there are no more results.
    +     * 
    + * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
    +     * The token for the next page of the response. To see more results,
    +     * use this value as the page_token for your next request. If this value
    +     * is empty, there are no more results.
    +     * 
    + * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList unreachable_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureUnreachableIsMutable() { + if (!unreachable_.isModifiable()) { + unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); + } + bitField0_ |= 0x00000004; + } + + /** + * + * + *
    +     * Hubs that could not be reached.
    +     * 
    + * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + unreachable_.makeImmutable(); + return unreachable_; + } + + /** + * + * + *
    +     * Hubs that could not be reached.
    +     * 
    + * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + + /** + * + * + *
    +     * Hubs that could not be reached.
    +     * 
    + * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + + /** + * + * + *
    +     * Hubs that could not be reached.
    +     * 
    + * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + /** + * + * + *
    +     * Hubs that could not be reached.
    +     * 
    + * + * repeated string unreachable = 3; + * + * @param index The index to set the value at. + * @param value The unreachable to set. + * @return This builder for chaining. + */ + public Builder setUnreachable(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.set(index, value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Hubs that could not be reached.
    +     * 
    + * + * repeated string unreachable = 3; + * + * @param value The unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Hubs that could not be reached.
    +     * 
    + * + * repeated string unreachable = 3; + * + * @param values The unreachable to add. + * @return This builder for chaining. + */ + public Builder addAllUnreachable(java.lang.Iterable values) { + ensureUnreachableIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Hubs that could not be reached.
    +     * 
    + * + * repeated string unreachable = 3; + * + * @return This builder for chaining. + */ + public Builder clearUnreachable() { + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Hubs that could not be reached.
    +     * 
    + * + * repeated string unreachable = 3; + * + * @param value The bytes of the unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUnreachableIsMutable(); + unreachable_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse) + private static final com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse(); + } + + public static com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListGatewayAdvertisedRoutesResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesResponseOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesResponseOrBuilder.java new file mode 100644 index 000000000000..3d5c684c6c7b --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/ListGatewayAdvertisedRoutesResponseOrBuilder.java @@ -0,0 +1,181 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +@com.google.protobuf.Generated +public interface ListGatewayAdvertisedRoutesResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * The requested gateway advertised routes.
    +   * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + java.util.List + getGatewayAdvertisedRoutesList(); + + /** + * + * + *
    +   * The requested gateway advertised routes.
    +   * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute getGatewayAdvertisedRoutes( + int index); + + /** + * + * + *
    +   * The requested gateway advertised routes.
    +   * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + int getGatewayAdvertisedRoutesCount(); + + /** + * + * + *
    +   * The requested gateway advertised routes.
    +   * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + java.util.List + getGatewayAdvertisedRoutesOrBuilderList(); + + /** + * + * + *
    +   * The requested gateway advertised routes.
    +   * 
    + * + * + * repeated .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_routes = 1; + * + */ + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder + getGatewayAdvertisedRoutesOrBuilder(int index); + + /** + * + * + *
    +   * The token for the next page of the response. To see more results,
    +   * use this value as the page_token for your next request. If this value
    +   * is empty, there are no more results.
    +   * 
    + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
    +   * The token for the next page of the response. To see more results,
    +   * use this value as the page_token for your next request. If this value
    +   * is empty, there are no more results.
    +   * 
    + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); + + /** + * + * + *
    +   * Hubs that could not be reached.
    +   * 
    + * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + java.util.List getUnreachableList(); + + /** + * + * + *
    +   * Hubs that could not be reached.
    +   * 
    + * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + int getUnreachableCount(); + + /** + * + * + *
    +   * Hubs that could not be reached.
    +   * 
    + * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + java.lang.String getUnreachable(int index); + + /** + * + * + *
    +   * Hubs that could not be reached.
    +   * 
    + * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + com.google.protobuf.ByteString getUnreachableBytes(int index); +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LocationFeature.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LocationFeature.java index bf1269b31d15..1678bd053503 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LocationFeature.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/LocationFeature.java @@ -61,6 +61,26 @@ public enum LocationFeature implements com.google.protobuf.ProtocolMessageEnum { * SITE_TO_SITE_SPOKES = 2; */ SITE_TO_SITE_SPOKES(2), + /** + * + * + *
    +   * Gateway spokes are supported in this location.
    +   * 
    + * + * GATEWAY_SPOKES = 3; + */ + GATEWAY_SPOKES(3), + /** + * + * + *
    +   * Supports transports in this location.
    +   * 
    + * + * TRANSPORTS = 4; + */ + TRANSPORTS(4), UNRECOGNIZED(-1), ; @@ -107,6 +127,28 @@ public enum LocationFeature implements com.google.protobuf.ProtocolMessageEnum { */ public static final int SITE_TO_SITE_SPOKES_VALUE = 2; + /** + * + * + *
    +   * Gateway spokes are supported in this location.
    +   * 
    + * + * GATEWAY_SPOKES = 3; + */ + public static final int GATEWAY_SPOKES_VALUE = 3; + + /** + * + * + *
    +   * Supports transports in this location.
    +   * 
    + * + * TRANSPORTS = 4; + */ + public static final int TRANSPORTS_VALUE = 4; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -137,6 +179,10 @@ public static LocationFeature forNumber(int value) { return SITE_TO_CLOUD_SPOKES; case 2: return SITE_TO_SITE_SPOKES; + case 3: + return GATEWAY_SPOKES; + case 4: + return TRANSPORTS; default: return null; } @@ -166,7 +212,7 @@ public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType } public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(0); + return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(5); } private static final LocationFeature[] VALUES = values(); diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/NextHopSpoke.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/NextHopSpoke.java new file mode 100644 index 000000000000..247c34aa69d9 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/NextHopSpoke.java @@ -0,0 +1,717 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +/** + * + * + *
    + * A route next hop that leads to a spoke resource.
    + * 
    + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.NextHopSpoke} + */ +@com.google.protobuf.Generated +public final class NextHopSpoke extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.NextHopSpoke) + NextHopSpokeOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "NextHopSpoke"); + } + + // Use NextHopSpoke.newBuilder() to construct. + private NextHopSpoke(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private NextHopSpoke() { + uri_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_NextHopSpoke_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_NextHopSpoke_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.NextHopSpoke.class, + com.google.cloud.networkconnectivity.v1.NextHopSpoke.Builder.class); + } + + public static final int URI_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object uri_ = ""; + + /** + * + * + *
    +   * The URI of the spoke resource.
    +   * 
    + * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The uri. + */ + @java.lang.Override + public java.lang.String getUri() { + java.lang.Object ref = uri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uri_ = s; + return s; + } + } + + /** + * + * + *
    +   * The URI of the spoke resource.
    +   * 
    + * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for uri. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUriBytes() { + java.lang.Object ref = uri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SITE_TO_SITE_DATA_TRANSFER_FIELD_NUMBER = 2; + private boolean siteToSiteDataTransfer_ = false; + + /** + * + * + *
    +   * Indicates whether site-to-site data transfer is allowed for this
    +   * spoke resource. Data transfer is available only in
    +   * [supported
    +   * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +   * Whether this route is accessible to other hybrid spokes with site-to-site
    +   * data transfer enabled. If this is false, the route is only accessible to
    +   * VPC spokes of the connected Hub.
    +   * 
    + * + * bool site_to_site_data_transfer = 2; + * + * @return The siteToSiteDataTransfer. + */ + @java.lang.Override + public boolean getSiteToSiteDataTransfer() { + return siteToSiteDataTransfer_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uri_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, uri_); + } + if (siteToSiteDataTransfer_ != false) { + output.writeBool(2, siteToSiteDataTransfer_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(uri_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, uri_); + } + if (siteToSiteDataTransfer_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, siteToSiteDataTransfer_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.networkconnectivity.v1.NextHopSpoke)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.NextHopSpoke other = + (com.google.cloud.networkconnectivity.v1.NextHopSpoke) obj; + + if (!getUri().equals(other.getUri())) return false; + if (getSiteToSiteDataTransfer() != other.getSiteToSiteDataTransfer()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + URI_FIELD_NUMBER; + hash = (53 * hash) + getUri().hashCode(); + hash = (37 * hash) + SITE_TO_SITE_DATA_TRANSFER_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSiteToSiteDataTransfer()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.networkconnectivity.v1.NextHopSpoke prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * A route next hop that leads to a spoke resource.
    +   * 
    + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.NextHopSpoke} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.NextHopSpoke) + com.google.cloud.networkconnectivity.v1.NextHopSpokeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_NextHopSpoke_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_NextHopSpoke_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.NextHopSpoke.class, + com.google.cloud.networkconnectivity.v1.NextHopSpoke.Builder.class); + } + + // Construct using com.google.cloud.networkconnectivity.v1.NextHopSpoke.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + uri_ = ""; + siteToSiteDataTransfer_ = false; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_NextHopSpoke_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.NextHopSpoke getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.NextHopSpoke.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.NextHopSpoke build() { + com.google.cloud.networkconnectivity.v1.NextHopSpoke result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.NextHopSpoke buildPartial() { + com.google.cloud.networkconnectivity.v1.NextHopSpoke result = + new com.google.cloud.networkconnectivity.v1.NextHopSpoke(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.networkconnectivity.v1.NextHopSpoke result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.uri_ = uri_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.siteToSiteDataTransfer_ = siteToSiteDataTransfer_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.networkconnectivity.v1.NextHopSpoke) { + return mergeFrom((com.google.cloud.networkconnectivity.v1.NextHopSpoke) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.NextHopSpoke other) { + if (other == com.google.cloud.networkconnectivity.v1.NextHopSpoke.getDefaultInstance()) + return this; + if (!other.getUri().isEmpty()) { + uri_ = other.uri_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getSiteToSiteDataTransfer() != false) { + setSiteToSiteDataTransfer(other.getSiteToSiteDataTransfer()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + uri_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + siteToSiteDataTransfer_ = input.readBool(); + bitField0_ |= 0x00000002; + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object uri_ = ""; + + /** + * + * + *
    +     * The URI of the spoke resource.
    +     * 
    + * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The uri. + */ + public java.lang.String getUri() { + java.lang.Object ref = uri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * The URI of the spoke resource.
    +     * 
    + * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for uri. + */ + public com.google.protobuf.ByteString getUriBytes() { + java.lang.Object ref = uri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * The URI of the spoke resource.
    +     * 
    + * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The uri to set. + * @return This builder for chaining. + */ + public Builder setUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + uri_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * The URI of the spoke resource.
    +     * 
    + * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return This builder for chaining. + */ + public Builder clearUri() { + uri_ = getDefaultInstance().getUri(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
    +     * The URI of the spoke resource.
    +     * 
    + * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The bytes for uri to set. + * @return This builder for chaining. + */ + public Builder setUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + uri_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private boolean siteToSiteDataTransfer_; + + /** + * + * + *
    +     * Indicates whether site-to-site data transfer is allowed for this
    +     * spoke resource. Data transfer is available only in
    +     * [supported
    +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * Whether this route is accessible to other hybrid spokes with site-to-site
    +     * data transfer enabled. If this is false, the route is only accessible to
    +     * VPC spokes of the connected Hub.
    +     * 
    + * + * bool site_to_site_data_transfer = 2; + * + * @return The siteToSiteDataTransfer. + */ + @java.lang.Override + public boolean getSiteToSiteDataTransfer() { + return siteToSiteDataTransfer_; + } + + /** + * + * + *
    +     * Indicates whether site-to-site data transfer is allowed for this
    +     * spoke resource. Data transfer is available only in
    +     * [supported
    +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * Whether this route is accessible to other hybrid spokes with site-to-site
    +     * data transfer enabled. If this is false, the route is only accessible to
    +     * VPC spokes of the connected Hub.
    +     * 
    + * + * bool site_to_site_data_transfer = 2; + * + * @param value The siteToSiteDataTransfer to set. + * @return This builder for chaining. + */ + public Builder setSiteToSiteDataTransfer(boolean value) { + + siteToSiteDataTransfer_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Indicates whether site-to-site data transfer is allowed for this
    +     * spoke resource. Data transfer is available only in
    +     * [supported
    +     * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +     * Whether this route is accessible to other hybrid spokes with site-to-site
    +     * data transfer enabled. If this is false, the route is only accessible to
    +     * VPC spokes of the connected Hub.
    +     * 
    + * + * bool site_to_site_data_transfer = 2; + * + * @return This builder for chaining. + */ + public Builder clearSiteToSiteDataTransfer() { + bitField0_ = (bitField0_ & ~0x00000002); + siteToSiteDataTransfer_ = false; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.NextHopSpoke) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.NextHopSpoke) + private static final com.google.cloud.networkconnectivity.v1.NextHopSpoke DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.networkconnectivity.v1.NextHopSpoke(); + } + + public static com.google.cloud.networkconnectivity.v1.NextHopSpoke getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public NextHopSpoke parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.NextHopSpoke getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/NextHopSpokeOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/NextHopSpokeOrBuilder.java new file mode 100644 index 000000000000..64741cba9d8c --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/NextHopSpokeOrBuilder.java @@ -0,0 +1,73 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +@com.google.protobuf.Generated +public interface NextHopSpokeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.NextHopSpoke) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * The URI of the spoke resource.
    +   * 
    + * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The uri. + */ + java.lang.String getUri(); + + /** + * + * + *
    +   * The URI of the spoke resource.
    +   * 
    + * + * string uri = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for uri. + */ + com.google.protobuf.ByteString getUriBytes(); + + /** + * + * + *
    +   * Indicates whether site-to-site data transfer is allowed for this
    +   * spoke resource. Data transfer is available only in
    +   * [supported
    +   * locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations).
    +   * Whether this route is accessible to other hybrid spokes with site-to-site
    +   * data transfer enabled. If this is false, the route is only accessible to
    +   * VPC spokes of the connected Hub.
    +   * 
    + * + * bool site_to_site_data_transfer = 2; + * + * @return The siteToSiteDataTransfer. + */ + boolean getSiteToSiteDataTransfer(); +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/PolicyMode.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/PolicyMode.java index c24cc9613d1a..dbf5a6031748 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/PolicyMode.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/PolicyMode.java @@ -145,7 +145,7 @@ public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType } public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(4); + return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(3); } private static final PolicyMode[] VALUES = values(); diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/PresetTopology.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/PresetTopology.java index 7a5cc5d4097f..c21b9627184a 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/PresetTopology.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/PresetTopology.java @@ -65,6 +65,17 @@ public enum PresetTopology implements com.google.protobuf.ProtocolMessageEnum { * STAR = 3; */ STAR(3), + /** + * + * + *
    +   * Hybrid inspection has 4 groups ('non-prod', 'prod', 'services', and
    +   * 'untrusted') that are automatically created along with hub creation.
    +   * 
    + * + * HYBRID_INSPECTION = 4; + */ + HYBRID_INSPECTION(4), UNRECOGNIZED(-1), ; @@ -115,6 +126,18 @@ public enum PresetTopology implements com.google.protobuf.ProtocolMessageEnum { */ public static final int STAR_VALUE = 3; + /** + * + * + *
    +   * Hybrid inspection has 4 groups ('non-prod', 'prod', 'services', and
    +   * 'untrusted') that are automatically created along with hub creation.
    +   * 
    + * + * HYBRID_INSPECTION = 4; + */ + public static final int HYBRID_INSPECTION_VALUE = 4; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -145,6 +168,8 @@ public static PresetTopology forNumber(int value) { return MESH; case 3: return STAR; + case 4: + return HYBRID_INSPECTION; default: return null; } @@ -174,7 +199,7 @@ public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType } public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(5); + return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(4); } private static final PresetTopology[] VALUES = values(); diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Route.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Route.java index 967bbd350924..7c8fd1cbe7f9 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Route.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Route.java @@ -1002,6 +1002,65 @@ public boolean hasNextHopInterconnectAttachment() { : nextHopInterconnectAttachment_; } + public static final int NEXT_HOP_SPOKE_FIELD_NUMBER = 18; + private com.google.cloud.networkconnectivity.v1.NextHopSpoke nextHopSpoke_; + + /** + * + * + *
    +   * Immutable. The next-hop spoke for packets on this route.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return Whether the nextHopSpoke field is set. + */ + @java.lang.Override + public boolean hasNextHopSpoke() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
    +   * Immutable. The next-hop spoke for packets on this route.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The nextHopSpoke. + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.NextHopSpoke getNextHopSpoke() { + return nextHopSpoke_ == null + ? com.google.cloud.networkconnectivity.v1.NextHopSpoke.getDefaultInstance() + : nextHopSpoke_; + } + + /** + * + * + *
    +   * Immutable. The next-hop spoke for packets on this route.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.NextHopSpokeOrBuilder getNextHopSpokeOrBuilder() { + return nextHopSpoke_ == null + ? com.google.cloud.networkconnectivity.v1.NextHopSpoke.getDefaultInstance() + : nextHopSpoke_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -1064,6 +1123,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000020) != 0)) { output.writeMessage(16, getNextHopInterconnectAttachment()); } + if (((bitField0_ & 0x00000040) != 0)) { + output.writeMessage(18, getNextHopSpoke()); + } getUnknownFields().writeTo(output); } @@ -1133,6 +1195,9 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 16, getNextHopInterconnectAttachment()); } + if (((bitField0_ & 0x00000040) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(18, getNextHopSpoke()); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1187,6 +1252,10 @@ public boolean equals(final java.lang.Object obj) { if (!getNextHopInterconnectAttachment().equals(other.getNextHopInterconnectAttachment())) return false; } + if (hasNextHopSpoke() != other.hasNextHopSpoke()) return false; + if (hasNextHopSpoke()) { + if (!getNextHopSpoke().equals(other.getNextHopSpoke())) return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1244,6 +1313,10 @@ public int hashCode() { hash = (37 * hash) + NEXT_HOP_INTERCONNECT_ATTACHMENT_FIELD_NUMBER; hash = (53 * hash) + getNextHopInterconnectAttachment().hashCode(); } + if (hasNextHopSpoke()) { + hash = (37 * hash) + NEXT_HOP_SPOKE_FIELD_NUMBER; + hash = (53 * hash) + getNextHopSpoke().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1414,6 +1487,7 @@ private void maybeForceBuilderInitialization() { internalGetNextHopVpnTunnelFieldBuilder(); internalGetNextHopRouterApplianceInstanceFieldBuilder(); internalGetNextHopInterconnectAttachmentFieldBuilder(); + internalGetNextHopSpokeFieldBuilder(); } } @@ -1461,6 +1535,11 @@ public Builder clear() { nextHopInterconnectAttachmentBuilder_.dispose(); nextHopInterconnectAttachmentBuilder_ = null; } + nextHopSpoke_ = null; + if (nextHopSpokeBuilder_ != null) { + nextHopSpokeBuilder_.dispose(); + nextHopSpokeBuilder_ = null; + } return this; } @@ -1563,6 +1642,11 @@ private void buildPartial0(com.google.cloud.networkconnectivity.v1.Route result) : nextHopInterconnectAttachmentBuilder_.build(); to_bitField0_ |= 0x00000020; } + if (((from_bitField0_ & 0x00010000) != 0)) { + result.nextHopSpoke_ = + nextHopSpokeBuilder_ == null ? nextHopSpoke_ : nextHopSpokeBuilder_.build(); + to_bitField0_ |= 0x00000040; + } result.bitField0_ |= to_bitField0_; } @@ -1637,6 +1721,9 @@ public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.Route other) { if (other.hasNextHopInterconnectAttachment()) { mergeNextHopInterconnectAttachment(other.getNextHopInterconnectAttachment()); } + if (other.hasNextHopSpoke()) { + mergeNextHopSpoke(other.getNextHopSpoke()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1773,6 +1860,13 @@ public Builder mergeFrom( bitField0_ |= 0x00008000; break; } // case 130 + case 146: + { + input.readMessage( + internalGetNextHopSpokeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00010000; + break; + } // case 146 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -4290,6 +4384,221 @@ public Builder clearNextHopInterconnectAttachment() { return nextHopInterconnectAttachmentBuilder_; } + private com.google.cloud.networkconnectivity.v1.NextHopSpoke nextHopSpoke_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.NextHopSpoke, + com.google.cloud.networkconnectivity.v1.NextHopSpoke.Builder, + com.google.cloud.networkconnectivity.v1.NextHopSpokeOrBuilder> + nextHopSpokeBuilder_; + + /** + * + * + *
    +     * Immutable. The next-hop spoke for packets on this route.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return Whether the nextHopSpoke field is set. + */ + public boolean hasNextHopSpoke() { + return ((bitField0_ & 0x00010000) != 0); + } + + /** + * + * + *
    +     * Immutable. The next-hop spoke for packets on this route.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The nextHopSpoke. + */ + public com.google.cloud.networkconnectivity.v1.NextHopSpoke getNextHopSpoke() { + if (nextHopSpokeBuilder_ == null) { + return nextHopSpoke_ == null + ? com.google.cloud.networkconnectivity.v1.NextHopSpoke.getDefaultInstance() + : nextHopSpoke_; + } else { + return nextHopSpokeBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Immutable. The next-hop spoke for packets on this route.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + */ + public Builder setNextHopSpoke(com.google.cloud.networkconnectivity.v1.NextHopSpoke value) { + if (nextHopSpokeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + nextHopSpoke_ = value; + } else { + nextHopSpokeBuilder_.setMessage(value); + } + bitField0_ |= 0x00010000; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Immutable. The next-hop spoke for packets on this route.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + */ + public Builder setNextHopSpoke( + com.google.cloud.networkconnectivity.v1.NextHopSpoke.Builder builderForValue) { + if (nextHopSpokeBuilder_ == null) { + nextHopSpoke_ = builderForValue.build(); + } else { + nextHopSpokeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00010000; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Immutable. The next-hop spoke for packets on this route.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + */ + public Builder mergeNextHopSpoke(com.google.cloud.networkconnectivity.v1.NextHopSpoke value) { + if (nextHopSpokeBuilder_ == null) { + if (((bitField0_ & 0x00010000) != 0) + && nextHopSpoke_ != null + && nextHopSpoke_ + != com.google.cloud.networkconnectivity.v1.NextHopSpoke.getDefaultInstance()) { + getNextHopSpokeBuilder().mergeFrom(value); + } else { + nextHopSpoke_ = value; + } + } else { + nextHopSpokeBuilder_.mergeFrom(value); + } + if (nextHopSpoke_ != null) { + bitField0_ |= 0x00010000; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Immutable. The next-hop spoke for packets on this route.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + */ + public Builder clearNextHopSpoke() { + bitField0_ = (bitField0_ & ~0x00010000); + nextHopSpoke_ = null; + if (nextHopSpokeBuilder_ != null) { + nextHopSpokeBuilder_.dispose(); + nextHopSpokeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Immutable. The next-hop spoke for packets on this route.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + */ + public com.google.cloud.networkconnectivity.v1.NextHopSpoke.Builder getNextHopSpokeBuilder() { + bitField0_ |= 0x00010000; + onChanged(); + return internalGetNextHopSpokeFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Immutable. The next-hop spoke for packets on this route.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + */ + public com.google.cloud.networkconnectivity.v1.NextHopSpokeOrBuilder + getNextHopSpokeOrBuilder() { + if (nextHopSpokeBuilder_ != null) { + return nextHopSpokeBuilder_.getMessageOrBuilder(); + } else { + return nextHopSpoke_ == null + ? com.google.cloud.networkconnectivity.v1.NextHopSpoke.getDefaultInstance() + : nextHopSpoke_; + } + } + + /** + * + * + *
    +     * Immutable. The next-hop spoke for packets on this route.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.NextHopSpoke, + com.google.cloud.networkconnectivity.v1.NextHopSpoke.Builder, + com.google.cloud.networkconnectivity.v1.NextHopSpokeOrBuilder> + internalGetNextHopSpokeFieldBuilder() { + if (nextHopSpokeBuilder_ == null) { + nextHopSpokeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.NextHopSpoke, + com.google.cloud.networkconnectivity.v1.NextHopSpoke.Builder, + com.google.cloud.networkconnectivity.v1.NextHopSpokeOrBuilder>( + getNextHopSpoke(), getParentForChildren(), isClean()); + nextHopSpoke_ = null; + } + return nextHopSpokeBuilder_; + } + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.Route) } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RouteOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RouteOrBuilder.java index 975d0c372800..f84a57e5f7fe 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RouteOrBuilder.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RouteOrBuilder.java @@ -611,4 +611,47 @@ java.lang.String getLabelsOrDefault( */ com.google.cloud.networkconnectivity.v1.NextHopInterconnectAttachmentOrBuilder getNextHopInterconnectAttachmentOrBuilder(); + + /** + * + * + *
    +   * Immutable. The next-hop spoke for packets on this route.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return Whether the nextHopSpoke field is set. + */ + boolean hasNextHopSpoke(); + + /** + * + * + *
    +   * Immutable. The next-hop spoke for packets on this route.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The nextHopSpoke. + */ + com.google.cloud.networkconnectivity.v1.NextHopSpoke getNextHopSpoke(); + + /** + * + * + *
    +   * Immutable. The next-hop spoke for packets on this route.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.NextHopSpoke next_hop_spoke = 18 [(.google.api.field_behavior) = IMMUTABLE]; + * + */ + com.google.cloud.networkconnectivity.v1.NextHopSpokeOrBuilder getNextHopSpokeOrBuilder(); } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RouteType.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RouteType.java index e4a258d53eaf..fd2768b996d9 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RouteType.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/RouteType.java @@ -75,6 +75,17 @@ public enum RouteType implements com.google.protobuf.ProtocolMessageEnum { * DYNAMIC_ROUTE = 3; */ DYNAMIC_ROUTE(3), + /** + * + * + *
    +   * The route leads to a destination within the Private Service Connect
    +   * Global Google API range of the VPC network.
    +   * 
    + * + * PSC_GLOBAL_GAPI = 4; + */ + PSC_GLOBAL_GAPI(4), UNRECOGNIZED(-1), ; @@ -136,6 +147,18 @@ public enum RouteType implements com.google.protobuf.ProtocolMessageEnum { */ public static final int DYNAMIC_ROUTE_VALUE = 3; + /** + * + * + *
    +   * The route leads to a destination within the Private Service Connect
    +   * Global Google API range of the VPC network.
    +   * 
    + * + * PSC_GLOBAL_GAPI = 4; + */ + public static final int PSC_GLOBAL_GAPI_VALUE = 4; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -168,6 +191,8 @@ public static RouteType forNumber(int value) { return VPC_SECONDARY_SUBNET; case 3: return DYNAMIC_ROUTE; + case 4: + return PSC_GLOBAL_GAPI; default: return null; } @@ -197,7 +222,7 @@ public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType } public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(1); + return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(0); } private static final RouteType[] VALUES = values(); diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Spoke.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Spoke.java index c06caadd577e..df4da6df9dab 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Spoke.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/Spoke.java @@ -188,7 +188,7 @@ public interface StateReasonOrBuilder * * *
    -   * The reason a spoke is inactive.
    +   * The reason for the current state of the spoke.
        * 
    * * Protobuf type {@code google.cloud.networkconnectivity.v1.Spoke.StateReason} @@ -239,7 +239,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
    -     * The Code enum represents the various reasons a state can be `INACTIVE`.
    +     * The Code enum represents the various reasons for the state of the spoke.
          * 
    * * Protobuf enum {@code google.cloud.networkconnectivity.v1.Spoke.StateReason.Code} @@ -857,7 +857,7 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.Builder * * *
    -     * The reason a spoke is inactive.
    +     * The reason for the current state of the spoke.
          * 
    * * Protobuf type {@code google.cloud.networkconnectivity.v1.Spoke.StateReason} @@ -2092,6 +2092,68 @@ public com.google.cloud.networkconnectivity.v1.LinkedVpcNetwork getLinkedVpcNetw : linkedVpcNetwork_; } + public static final int GATEWAY_FIELD_NUMBER = 24; + private com.google.cloud.networkconnectivity.v1.Gateway gateway_; + + /** + * + * + *
    +   * Optional. This is a gateway that can apply specialized processing to
    +   * traffic going through it.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the gateway field is set. + */ + @java.lang.Override + public boolean hasGateway() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
    +   * Optional. This is a gateway that can apply specialized processing to
    +   * traffic going through it.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The gateway. + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.Gateway getGateway() { + return gateway_ == null + ? com.google.cloud.networkconnectivity.v1.Gateway.getDefaultInstance() + : gateway_; + } + + /** + * + * + *
    +   * Optional. This is a gateway that can apply specialized processing to
    +   * traffic going through it.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayOrBuilder getGatewayOrBuilder() { + return gateway_ == null + ? com.google.cloud.networkconnectivity.v1.Gateway.getDefaultInstance() + : gateway_; + } + public static final int LINKED_PRODUCER_VPC_NETWORK_FIELD_NUMBER = 26; private com.google.cloud.networkconnectivity.v1.LinkedProducerVpcNetwork linkedProducerVpcNetwork_; @@ -2111,7 +2173,7 @@ public com.google.cloud.networkconnectivity.v1.LinkedVpcNetwork getLinkedVpcNetw */ @java.lang.Override public boolean hasLinkedProducerVpcNetwork() { - return ((bitField0_ & 0x00000040) != 0); + return ((bitField0_ & 0x00000080) != 0); } /** @@ -2449,11 +2511,11 @@ public com.google.protobuf.ByteString getEtagBytes() { * * *
    -   * Optional. The list of fields waiting for hub administration's approval.
    +   * Output only. The list of fields waiting for hub administrator's approval.
        * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return A list containing the fieldPathsPendingUpdate. @@ -2466,11 +2528,11 @@ public com.google.protobuf.ProtocolStringList getFieldPathsPendingUpdateList() { * * *
    -   * Optional. The list of fields waiting for hub administration's approval.
    +   * Output only. The list of fields waiting for hub administrator's approval.
        * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The count of fieldPathsPendingUpdate. @@ -2483,11 +2545,11 @@ public int getFieldPathsPendingUpdateCount() { * * *
    -   * Optional. The list of fields waiting for hub administration's approval.
    +   * Output only. The list of fields waiting for hub administrator's approval.
        * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. @@ -2501,11 +2563,11 @@ public java.lang.String getFieldPathsPendingUpdate(int index) { * * *
    -   * Optional. The list of fields waiting for hub administration's approval.
    +   * Output only. The list of fields waiting for hub administrator's approval.
        * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. @@ -2575,6 +2637,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io com.google.protobuf.GeneratedMessage.writeString(output, 23, group_); } if (((bitField0_ & 0x00000040) != 0)) { + output.writeMessage(24, getGateway()); + } + if (((bitField0_ & 0x00000080) != 0)) { output.writeMessage(26, getLinkedProducerVpcNetwork()); } if (!com.google.protobuf.GeneratedMessage.isStringEmpty(etag_)) { @@ -2651,6 +2716,9 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessage.computeStringSize(23, group_); } if (((bitField0_ & 0x00000040) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(24, getGateway()); + } + if (((bitField0_ & 0x00000080) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize( 26, getLinkedProducerVpcNetwork()); @@ -2715,6 +2783,10 @@ public boolean equals(final java.lang.Object obj) { if (hasLinkedVpcNetwork()) { if (!getLinkedVpcNetwork().equals(other.getLinkedVpcNetwork())) return false; } + if (hasGateway() != other.hasGateway()) return false; + if (hasGateway()) { + if (!getGateway().equals(other.getGateway())) return false; + } if (hasLinkedProducerVpcNetwork() != other.hasLinkedProducerVpcNetwork()) return false; if (hasLinkedProducerVpcNetwork()) { if (!getLinkedProducerVpcNetwork().equals(other.getLinkedProducerVpcNetwork())) return false; @@ -2773,6 +2845,10 @@ public int hashCode() { hash = (37 * hash) + LINKED_VPC_NETWORK_FIELD_NUMBER; hash = (53 * hash) + getLinkedVpcNetwork().hashCode(); } + if (hasGateway()) { + hash = (37 * hash) + GATEWAY_FIELD_NUMBER; + hash = (53 * hash) + getGateway().hashCode(); + } if (hasLinkedProducerVpcNetwork()) { hash = (37 * hash) + LINKED_PRODUCER_VPC_NETWORK_FIELD_NUMBER; hash = (53 * hash) + getLinkedProducerVpcNetwork().hashCode(); @@ -2971,6 +3047,7 @@ private void maybeForceBuilderInitialization() { internalGetLinkedInterconnectAttachmentsFieldBuilder(); internalGetLinkedRouterApplianceInstancesFieldBuilder(); internalGetLinkedVpcNetworkFieldBuilder(); + internalGetGatewayFieldBuilder(); internalGetLinkedProducerVpcNetworkFieldBuilder(); internalGetReasonsFieldBuilder(); } @@ -3015,6 +3092,11 @@ public Builder clear() { linkedVpcNetworkBuilder_.dispose(); linkedVpcNetworkBuilder_ = null; } + gateway_ = null; + if (gatewayBuilder_ != null) { + gatewayBuilder_.dispose(); + gatewayBuilder_ = null; + } linkedProducerVpcNetwork_ = null; if (linkedProducerVpcNetworkBuilder_ != null) { linkedProducerVpcNetworkBuilder_.dispose(); @@ -3028,7 +3110,7 @@ public Builder clear() { reasons_ = null; reasonsBuilder_.clear(); } - bitField0_ = (bitField0_ & ~0x00004000); + bitField0_ = (bitField0_ & ~0x00008000); spokeType_ = 0; etag_ = ""; fieldPathsPendingUpdate_ = com.google.protobuf.LazyStringArrayList.emptyList(); @@ -3069,9 +3151,9 @@ public com.google.cloud.networkconnectivity.v1.Spoke buildPartial() { private void buildPartialRepeatedFields(com.google.cloud.networkconnectivity.v1.Spoke result) { if (reasonsBuilder_ == null) { - if (((bitField0_ & 0x00004000) != 0)) { + if (((bitField0_ & 0x00008000) != 0)) { reasons_ = java.util.Collections.unmodifiableList(reasons_); - bitField0_ = (bitField0_ & ~0x00004000); + bitField0_ = (bitField0_ & ~0x00008000); } result.reasons_ = reasons_; } else { @@ -3131,25 +3213,29 @@ private void buildPartial0(com.google.cloud.networkconnectivity.v1.Spoke result) to_bitField0_ |= 0x00000020; } if (((from_bitField0_ & 0x00000800) != 0)) { + result.gateway_ = gatewayBuilder_ == null ? gateway_ : gatewayBuilder_.build(); + to_bitField0_ |= 0x00000040; + } + if (((from_bitField0_ & 0x00001000) != 0)) { result.linkedProducerVpcNetwork_ = linkedProducerVpcNetworkBuilder_ == null ? linkedProducerVpcNetwork_ : linkedProducerVpcNetworkBuilder_.build(); - to_bitField0_ |= 0x00000040; + to_bitField0_ |= 0x00000080; } - if (((from_bitField0_ & 0x00001000) != 0)) { + if (((from_bitField0_ & 0x00002000) != 0)) { result.uniqueId_ = uniqueId_; } - if (((from_bitField0_ & 0x00002000) != 0)) { + if (((from_bitField0_ & 0x00004000) != 0)) { result.state_ = state_; } - if (((from_bitField0_ & 0x00008000) != 0)) { + if (((from_bitField0_ & 0x00010000) != 0)) { result.spokeType_ = spokeType_; } - if (((from_bitField0_ & 0x00010000) != 0)) { + if (((from_bitField0_ & 0x00020000) != 0)) { result.etag_ = etag_; } - if (((from_bitField0_ & 0x00020000) != 0)) { + if (((from_bitField0_ & 0x00040000) != 0)) { fieldPathsPendingUpdate_.makeImmutable(); result.fieldPathsPendingUpdate_ = fieldPathsPendingUpdate_; } @@ -3208,12 +3294,15 @@ public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.Spoke other) { if (other.hasLinkedVpcNetwork()) { mergeLinkedVpcNetwork(other.getLinkedVpcNetwork()); } + if (other.hasGateway()) { + mergeGateway(other.getGateway()); + } if (other.hasLinkedProducerVpcNetwork()) { mergeLinkedProducerVpcNetwork(other.getLinkedProducerVpcNetwork()); } if (!other.getUniqueId().isEmpty()) { uniqueId_ = other.uniqueId_; - bitField0_ |= 0x00001000; + bitField0_ |= 0x00002000; onChanged(); } if (other.state_ != 0) { @@ -3223,7 +3312,7 @@ public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.Spoke other) { if (!other.reasons_.isEmpty()) { if (reasons_.isEmpty()) { reasons_ = other.reasons_; - bitField0_ = (bitField0_ & ~0x00004000); + bitField0_ = (bitField0_ & ~0x00008000); } else { ensureReasonsIsMutable(); reasons_.addAll(other.reasons_); @@ -3236,7 +3325,7 @@ public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.Spoke other) { reasonsBuilder_.dispose(); reasonsBuilder_ = null; reasons_ = other.reasons_; - bitField0_ = (bitField0_ & ~0x00004000); + bitField0_ = (bitField0_ & ~0x00008000); reasonsBuilder_ = com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? internalGetReasonsFieldBuilder() @@ -3251,13 +3340,13 @@ public Builder mergeFrom(com.google.cloud.networkconnectivity.v1.Spoke other) { } if (!other.getEtag().isEmpty()) { etag_ = other.etag_; - bitField0_ |= 0x00010000; + bitField0_ |= 0x00020000; onChanged(); } if (!other.fieldPathsPendingUpdate_.isEmpty()) { if (fieldPathsPendingUpdate_.isEmpty()) { fieldPathsPendingUpdate_ = other.fieldPathsPendingUpdate_; - bitField0_ |= 0x00020000; + bitField0_ |= 0x00040000; } else { ensureFieldPathsPendingUpdateIsMutable(); fieldPathsPendingUpdate_.addAll(other.fieldPathsPendingUpdate_); @@ -3337,13 +3426,13 @@ public Builder mergeFrom( case 90: { uniqueId_ = input.readStringRequireUtf8(); - bitField0_ |= 0x00001000; + bitField0_ |= 0x00002000; break; } // case 90 case 120: { state_ = input.readEnum(); - bitField0_ |= 0x00002000; + bitField0_ |= 0x00004000; break; } // case 120 case 138: @@ -3393,7 +3482,7 @@ public Builder mergeFrom( case 176: { spokeType_ = input.readEnum(); - bitField0_ |= 0x00008000; + bitField0_ |= 0x00010000; break; } // case 176 case 186: @@ -3402,18 +3491,24 @@ public Builder mergeFrom( bitField0_ |= 0x00000040; break; } // case 186 + case 194: + { + input.readMessage(internalGetGatewayFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000800; + break; + } // case 194 case 210: { input.readMessage( internalGetLinkedProducerVpcNetworkFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x00000800; + bitField0_ |= 0x00001000; break; } // case 210 case 218: { etag_ = input.readStringRequireUtf8(); - bitField0_ |= 0x00010000; + bitField0_ |= 0x00020000; break; } // case 218 case 226: @@ -5410,6 +5505,228 @@ public Builder clearLinkedVpcNetwork() { return linkedVpcNetworkBuilder_; } + private com.google.cloud.networkconnectivity.v1.Gateway gateway_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.Gateway, + com.google.cloud.networkconnectivity.v1.Gateway.Builder, + com.google.cloud.networkconnectivity.v1.GatewayOrBuilder> + gatewayBuilder_; + + /** + * + * + *
    +     * Optional. This is a gateway that can apply specialized processing to
    +     * traffic going through it.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the gateway field is set. + */ + public boolean hasGateway() { + return ((bitField0_ & 0x00000800) != 0); + } + + /** + * + * + *
    +     * Optional. This is a gateway that can apply specialized processing to
    +     * traffic going through it.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The gateway. + */ + public com.google.cloud.networkconnectivity.v1.Gateway getGateway() { + if (gatewayBuilder_ == null) { + return gateway_ == null + ? com.google.cloud.networkconnectivity.v1.Gateway.getDefaultInstance() + : gateway_; + } else { + return gatewayBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Optional. This is a gateway that can apply specialized processing to
    +     * traffic going through it.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setGateway(com.google.cloud.networkconnectivity.v1.Gateway value) { + if (gatewayBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + gateway_ = value; + } else { + gatewayBuilder_.setMessage(value); + } + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. This is a gateway that can apply specialized processing to
    +     * traffic going through it.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setGateway( + com.google.cloud.networkconnectivity.v1.Gateway.Builder builderForValue) { + if (gatewayBuilder_ == null) { + gateway_ = builderForValue.build(); + } else { + gatewayBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000800; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. This is a gateway that can apply specialized processing to
    +     * traffic going through it.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeGateway(com.google.cloud.networkconnectivity.v1.Gateway value) { + if (gatewayBuilder_ == null) { + if (((bitField0_ & 0x00000800) != 0) + && gateway_ != null + && gateway_ != com.google.cloud.networkconnectivity.v1.Gateway.getDefaultInstance()) { + getGatewayBuilder().mergeFrom(value); + } else { + gateway_ = value; + } + } else { + gatewayBuilder_.mergeFrom(value); + } + if (gateway_ != null) { + bitField0_ |= 0x00000800; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Optional. This is a gateway that can apply specialized processing to
    +     * traffic going through it.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearGateway() { + bitField0_ = (bitField0_ & ~0x00000800); + gateway_ = null; + if (gatewayBuilder_ != null) { + gatewayBuilder_.dispose(); + gatewayBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. This is a gateway that can apply specialized processing to
    +     * traffic going through it.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.networkconnectivity.v1.Gateway.Builder getGatewayBuilder() { + bitField0_ |= 0x00000800; + onChanged(); + return internalGetGatewayFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Optional. This is a gateway that can apply specialized processing to
    +     * traffic going through it.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.networkconnectivity.v1.GatewayOrBuilder getGatewayOrBuilder() { + if (gatewayBuilder_ != null) { + return gatewayBuilder_.getMessageOrBuilder(); + } else { + return gateway_ == null + ? com.google.cloud.networkconnectivity.v1.Gateway.getDefaultInstance() + : gateway_; + } + } + + /** + * + * + *
    +     * Optional. This is a gateway that can apply specialized processing to
    +     * traffic going through it.
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.Gateway, + com.google.cloud.networkconnectivity.v1.Gateway.Builder, + com.google.cloud.networkconnectivity.v1.GatewayOrBuilder> + internalGetGatewayFieldBuilder() { + if (gatewayBuilder_ == null) { + gatewayBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.Gateway, + com.google.cloud.networkconnectivity.v1.Gateway.Builder, + com.google.cloud.networkconnectivity.v1.GatewayOrBuilder>( + getGateway(), getParentForChildren(), isClean()); + gateway_ = null; + } + return gatewayBuilder_; + } + private com.google.cloud.networkconnectivity.v1.LinkedProducerVpcNetwork linkedProducerVpcNetwork_; private com.google.protobuf.SingleFieldBuilder< @@ -5432,7 +5749,7 @@ public Builder clearLinkedVpcNetwork() { * @return Whether the linkedProducerVpcNetwork field is set. */ public boolean hasLinkedProducerVpcNetwork() { - return ((bitField0_ & 0x00000800) != 0); + return ((bitField0_ & 0x00001000) != 0); } /** @@ -5480,7 +5797,7 @@ public Builder setLinkedProducerVpcNetwork( } else { linkedProducerVpcNetworkBuilder_.setMessage(value); } - bitField0_ |= 0x00000800; + bitField0_ |= 0x00001000; onChanged(); return this; } @@ -5503,7 +5820,7 @@ public Builder setLinkedProducerVpcNetwork( } else { linkedProducerVpcNetworkBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x00000800; + bitField0_ |= 0x00001000; onChanged(); return this; } @@ -5522,7 +5839,7 @@ public Builder setLinkedProducerVpcNetwork( public Builder mergeLinkedProducerVpcNetwork( com.google.cloud.networkconnectivity.v1.LinkedProducerVpcNetwork value) { if (linkedProducerVpcNetworkBuilder_ == null) { - if (((bitField0_ & 0x00000800) != 0) + if (((bitField0_ & 0x00001000) != 0) && linkedProducerVpcNetwork_ != null && linkedProducerVpcNetwork_ != com.google.cloud.networkconnectivity.v1.LinkedProducerVpcNetwork @@ -5535,7 +5852,7 @@ public Builder mergeLinkedProducerVpcNetwork( linkedProducerVpcNetworkBuilder_.mergeFrom(value); } if (linkedProducerVpcNetwork_ != null) { - bitField0_ |= 0x00000800; + bitField0_ |= 0x00001000; onChanged(); } return this; @@ -5553,7 +5870,7 @@ public Builder mergeLinkedProducerVpcNetwork( *
    */ public Builder clearLinkedProducerVpcNetwork() { - bitField0_ = (bitField0_ & ~0x00000800); + bitField0_ = (bitField0_ & ~0x00001000); linkedProducerVpcNetwork_ = null; if (linkedProducerVpcNetworkBuilder_ != null) { linkedProducerVpcNetworkBuilder_.dispose(); @@ -5576,7 +5893,7 @@ public Builder clearLinkedProducerVpcNetwork() { */ public com.google.cloud.networkconnectivity.v1.LinkedProducerVpcNetwork.Builder getLinkedProducerVpcNetworkBuilder() { - bitField0_ |= 0x00000800; + bitField0_ |= 0x00001000; onChanged(); return internalGetLinkedProducerVpcNetworkFieldBuilder().getBuilder(); } @@ -5702,7 +6019,7 @@ public Builder setUniqueId(java.lang.String value) { throw new NullPointerException(); } uniqueId_ = value; - bitField0_ |= 0x00001000; + bitField0_ |= 0x00002000; onChanged(); return this; } @@ -5722,7 +6039,7 @@ public Builder setUniqueId(java.lang.String value) { */ public Builder clearUniqueId() { uniqueId_ = getDefaultInstance().getUniqueId(); - bitField0_ = (bitField0_ & ~0x00001000); + bitField0_ = (bitField0_ & ~0x00002000); onChanged(); return this; } @@ -5747,7 +6064,7 @@ public Builder setUniqueIdBytes(com.google.protobuf.ByteString value) { } checkByteStringIsUtf8(value); uniqueId_ = value; - bitField0_ |= 0x00001000; + bitField0_ |= 0x00002000; onChanged(); return this; } @@ -5788,7 +6105,7 @@ public int getStateValue() { */ public Builder setStateValue(int value) { state_ = value; - bitField0_ |= 0x00002000; + bitField0_ |= 0x00004000; onChanged(); return this; } @@ -5831,7 +6148,7 @@ public Builder setState(com.google.cloud.networkconnectivity.v1.State value) { if (value == null) { throw new NullPointerException(); } - bitField0_ |= 0x00002000; + bitField0_ |= 0x00004000; state_ = value.getNumber(); onChanged(); return this; @@ -5851,7 +6168,7 @@ public Builder setState(com.google.cloud.networkconnectivity.v1.State value) { * @return This builder for chaining. */ public Builder clearState() { - bitField0_ = (bitField0_ & ~0x00002000); + bitField0_ = (bitField0_ & ~0x00004000); state_ = 0; onChanged(); return this; @@ -5861,11 +6178,11 @@ public Builder clearState() { java.util.Collections.emptyList(); private void ensureReasonsIsMutable() { - if (!((bitField0_ & 0x00004000) != 0)) { + if (!((bitField0_ & 0x00008000) != 0)) { reasons_ = new java.util.ArrayList( reasons_); - bitField0_ |= 0x00004000; + bitField0_ |= 0x00008000; } } @@ -6119,7 +6436,7 @@ public Builder addAllReasons( public Builder clearReasons() { if (reasonsBuilder_ == null) { reasons_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00004000); + bitField0_ = (bitField0_ & ~0x00008000); onChanged(); } else { reasonsBuilder_.clear(); @@ -6269,7 +6586,7 @@ public com.google.cloud.networkconnectivity.v1.Spoke.StateReason.Builder addReas com.google.cloud.networkconnectivity.v1.Spoke.StateReason, com.google.cloud.networkconnectivity.v1.Spoke.StateReason.Builder, com.google.cloud.networkconnectivity.v1.Spoke.StateReasonOrBuilder>( - reasons_, ((bitField0_ & 0x00004000) != 0), getParentForChildren(), isClean()); + reasons_, ((bitField0_ & 0x00008000) != 0), getParentForChildren(), isClean()); reasons_ = null; } return reasonsBuilder_; @@ -6311,7 +6628,7 @@ public int getSpokeTypeValue() { */ public Builder setSpokeTypeValue(int value) { spokeType_ = value; - bitField0_ |= 0x00008000; + bitField0_ |= 0x00010000; onChanged(); return this; } @@ -6356,7 +6673,7 @@ public Builder setSpokeType(com.google.cloud.networkconnectivity.v1.SpokeType va if (value == null) { throw new NullPointerException(); } - bitField0_ |= 0x00008000; + bitField0_ |= 0x00010000; spokeType_ = value.getNumber(); onChanged(); return this; @@ -6376,7 +6693,7 @@ public Builder setSpokeType(com.google.cloud.networkconnectivity.v1.SpokeType va * @return This builder for chaining. */ public Builder clearSpokeType() { - bitField0_ = (bitField0_ & ~0x00008000); + bitField0_ = (bitField0_ & ~0x00010000); spokeType_ = 0; onChanged(); return this; @@ -6453,7 +6770,7 @@ public Builder setEtag(java.lang.String value) { throw new NullPointerException(); } etag_ = value; - bitField0_ |= 0x00010000; + bitField0_ |= 0x00020000; onChanged(); return this; } @@ -6473,7 +6790,7 @@ public Builder setEtag(java.lang.String value) { */ public Builder clearEtag() { etag_ = getDefaultInstance().getEtag(); - bitField0_ = (bitField0_ & ~0x00010000); + bitField0_ = (bitField0_ & ~0x00020000); onChanged(); return this; } @@ -6498,7 +6815,7 @@ public Builder setEtagBytes(com.google.protobuf.ByteString value) { } checkByteStringIsUtf8(value); etag_ = value; - bitField0_ |= 0x00010000; + bitField0_ |= 0x00020000; onChanged(); return this; } @@ -6511,18 +6828,18 @@ private void ensureFieldPathsPendingUpdateIsMutable() { fieldPathsPendingUpdate_ = new com.google.protobuf.LazyStringArrayList(fieldPathsPendingUpdate_); } - bitField0_ |= 0x00020000; + bitField0_ |= 0x00040000; } /** * * *
    -     * Optional. The list of fields waiting for hub administration's approval.
    +     * Output only. The list of fields waiting for hub administrator's approval.
          * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return A list containing the fieldPathsPendingUpdate. @@ -6536,11 +6853,11 @@ public com.google.protobuf.ProtocolStringList getFieldPathsPendingUpdateList() { * * *
    -     * Optional. The list of fields waiting for hub administration's approval.
    +     * Output only. The list of fields waiting for hub administrator's approval.
          * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The count of fieldPathsPendingUpdate. @@ -6553,11 +6870,11 @@ public int getFieldPathsPendingUpdateCount() { * * *
    -     * Optional. The list of fields waiting for hub administration's approval.
    +     * Output only. The list of fields waiting for hub administrator's approval.
          * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. @@ -6571,11 +6888,11 @@ public java.lang.String getFieldPathsPendingUpdate(int index) { * * *
    -     * Optional. The list of fields waiting for hub administration's approval.
    +     * Output only. The list of fields waiting for hub administrator's approval.
          * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. @@ -6589,11 +6906,11 @@ public com.google.protobuf.ByteString getFieldPathsPendingUpdateBytes(int index) * * *
    -     * Optional. The list of fields waiting for hub administration's approval.
    +     * Output only. The list of fields waiting for hub administrator's approval.
          * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index to set the value at. @@ -6606,7 +6923,7 @@ public Builder setFieldPathsPendingUpdate(int index, java.lang.String value) { } ensureFieldPathsPendingUpdateIsMutable(); fieldPathsPendingUpdate_.set(index, value); - bitField0_ |= 0x00020000; + bitField0_ |= 0x00040000; onChanged(); return this; } @@ -6615,11 +6932,11 @@ public Builder setFieldPathsPendingUpdate(int index, java.lang.String value) { * * *
    -     * Optional. The list of fields waiting for hub administration's approval.
    +     * Output only. The list of fields waiting for hub administrator's approval.
          * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The fieldPathsPendingUpdate to add. @@ -6631,7 +6948,7 @@ public Builder addFieldPathsPendingUpdate(java.lang.String value) { } ensureFieldPathsPendingUpdateIsMutable(); fieldPathsPendingUpdate_.add(value); - bitField0_ |= 0x00020000; + bitField0_ |= 0x00040000; onChanged(); return this; } @@ -6640,11 +6957,11 @@ public Builder addFieldPathsPendingUpdate(java.lang.String value) { * * *
    -     * Optional. The list of fields waiting for hub administration's approval.
    +     * Output only. The list of fields waiting for hub administrator's approval.
          * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param values The fieldPathsPendingUpdate to add. @@ -6653,7 +6970,7 @@ public Builder addFieldPathsPendingUpdate(java.lang.String value) { public Builder addAllFieldPathsPendingUpdate(java.lang.Iterable values) { ensureFieldPathsPendingUpdateIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, fieldPathsPendingUpdate_); - bitField0_ |= 0x00020000; + bitField0_ |= 0x00040000; onChanged(); return this; } @@ -6662,18 +6979,18 @@ public Builder addAllFieldPathsPendingUpdate(java.lang.Iterable - * Optional. The list of fields waiting for hub administration's approval. + * Output only. The list of fields waiting for hub administrator's approval. * * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return This builder for chaining. */ public Builder clearFieldPathsPendingUpdate() { fieldPathsPendingUpdate_ = com.google.protobuf.LazyStringArrayList.emptyList(); - bitField0_ = (bitField0_ & ~0x00020000); + bitField0_ = (bitField0_ & ~0x00040000); ; onChanged(); return this; @@ -6683,11 +7000,11 @@ public Builder clearFieldPathsPendingUpdate() { * * *
    -     * Optional. The list of fields waiting for hub administration's approval.
    +     * Output only. The list of fields waiting for hub administrator's approval.
          * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param value The bytes of the fieldPathsPendingUpdate to add. @@ -6700,7 +7017,7 @@ public Builder addFieldPathsPendingUpdateBytes(com.google.protobuf.ByteString va checkByteStringIsUtf8(value); ensureFieldPathsPendingUpdateIsMutable(); fieldPathsPendingUpdate_.add(value); - bitField0_ |= 0x00020000; + bitField0_ |= 0x00040000; onChanged(); return this; } diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/SpokeOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/SpokeOrBuilder.java index 1277c6a49c42..6efd6833da0d 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/SpokeOrBuilder.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/SpokeOrBuilder.java @@ -471,6 +471,52 @@ java.lang.String getLabelsOrDefault( */ com.google.cloud.networkconnectivity.v1.LinkedVpcNetworkOrBuilder getLinkedVpcNetworkOrBuilder(); + /** + * + * + *
    +   * Optional. This is a gateway that can apply specialized processing to
    +   * traffic going through it.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the gateway field is set. + */ + boolean hasGateway(); + + /** + * + * + *
    +   * Optional. This is a gateway that can apply specialized processing to
    +   * traffic going through it.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The gateway. + */ + com.google.cloud.networkconnectivity.v1.Gateway getGateway(); + + /** + * + * + *
    +   * Optional. This is a gateway that can apply specialized processing to
    +   * traffic going through it.
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.Gateway gateway = 24 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.networkconnectivity.v1.GatewayOrBuilder getGatewayOrBuilder(); + /** * * @@ -705,11 +751,11 @@ java.lang.String getLabelsOrDefault( * * *
    -   * Optional. The list of fields waiting for hub administration's approval.
    +   * Output only. The list of fields waiting for hub administrator's approval.
        * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return A list containing the fieldPathsPendingUpdate. @@ -720,11 +766,11 @@ java.lang.String getLabelsOrDefault( * * *
    -   * Optional. The list of fields waiting for hub administration's approval.
    +   * Output only. The list of fields waiting for hub administrator's approval.
        * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The count of fieldPathsPendingUpdate. @@ -735,11 +781,11 @@ java.lang.String getLabelsOrDefault( * * *
    -   * Optional. The list of fields waiting for hub administration's approval.
    +   * Output only. The list of fields waiting for hub administrator's approval.
        * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the element to return. @@ -751,11 +797,11 @@ java.lang.String getLabelsOrDefault( * * *
    -   * Optional. The list of fields waiting for hub administration's approval.
    +   * Output only. The list of fields waiting for hub administrator's approval.
        * 
    * * - * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OPTIONAL]; + * repeated string field_paths_pending_update = 28 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @param index The index of the value to return. diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/SpokeType.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/SpokeType.java index 964cd8a330f4..a86c2a8c71fe 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/SpokeType.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/SpokeType.java @@ -82,6 +82,16 @@ public enum SpokeType implements com.google.protobuf.ProtocolMessageEnum { * VPC_NETWORK = 4; */ VPC_NETWORK(4), + /** + * + * + *
    +   * Spokes that are NCC gateways.
    +   * 
    + * + * GATEWAY = 5; + */ + GATEWAY(5), /** * * @@ -160,6 +170,17 @@ public enum SpokeType implements com.google.protobuf.ProtocolMessageEnum { */ public static final int VPC_NETWORK_VALUE = 4; + /** + * + * + *
    +   * Spokes that are NCC gateways.
    +   * 
    + * + * GATEWAY = 5; + */ + public static final int GATEWAY_VALUE = 5; + /** * * @@ -205,6 +226,8 @@ public static SpokeType forNumber(int value) { return ROUTER_APPLIANCE; case 4: return VPC_NETWORK; + case 5: + return GATEWAY; case 7: return PRODUCER_VPC_NETWORK; default: @@ -236,7 +259,7 @@ public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType } public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(3); + return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(2); } private static final SpokeType[] VALUES = values(); diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/State.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/State.java index d625f6bfccb8..d900cf0eda3f 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/State.java +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/State.java @@ -334,7 +334,7 @@ public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType } public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(2); + return com.google.cloud.networkconnectivity.v1.HubProto.getDescriptor().getEnumTypes().get(1); } private static final State[] VALUES = values(); diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/UpdateGatewayAdvertisedRouteRequest.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/UpdateGatewayAdvertisedRouteRequest.java new file mode 100644 index 000000000000..83ad827bb262 --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/UpdateGatewayAdvertisedRouteRequest.java @@ -0,0 +1,1444 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +/** + * + * + *
    + * The request for
    + * [HubService.UpdateGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.UpdateGatewayAdvertisedRoute].
    + * 
    + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest} + */ +@com.google.protobuf.Generated +public final class UpdateGatewayAdvertisedRouteRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest) + UpdateGatewayAdvertisedRouteRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "UpdateGatewayAdvertisedRouteRequest"); + } + + // Use UpdateGatewayAdvertisedRouteRequest.newBuilder() to construct. + private UpdateGatewayAdvertisedRouteRequest( + com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private UpdateGatewayAdvertisedRouteRequest() { + requestId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_UpdateGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_UpdateGatewayAdvertisedRouteRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest.class, + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest.Builder + .class); + } + + private int bitField0_; + public static final int UPDATE_MASK_FIELD_NUMBER = 1; + private com.google.protobuf.FieldMask updateMask_; + + /** + * + * + *
    +   * Optional. In the case of an update to an existing group, field mask is used
    +   * to specify the fields to be overwritten. The fields specified in the
    +   * update_mask are relative to the resource, not the full request. A field is
    +   * overwritten if it is in the mask. If the user does not provide a mask, then
    +   * all fields are overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +   * Optional. In the case of an update to an existing group, field mask is used
    +   * to specify the fields to be overwritten. The fields specified in the
    +   * update_mask are relative to the resource, not the full request. A field is
    +   * overwritten if it is in the mask. If the user does not provide a mask, then
    +   * all fields are overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + /** + * + * + *
    +   * Optional. In the case of an update to an existing group, field mask is used
    +   * to specify the fields to be overwritten. The fields specified in the
    +   * update_mask are relative to the resource, not the full request. A field is
    +   * overwritten if it is in the mask. If the user does not provide a mask, then
    +   * all fields are overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + public static final int GATEWAY_ADVERTISED_ROUTE_FIELD_NUMBER = 2; + private com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gatewayAdvertisedRoute_; + + /** + * + * + *
    +   * Required. The gateway advertised route to update.
    +   *
    +   * The gateway advertised route's `name` field is used to identify the gateway
    +   * advertised route to update. Format:
    +   * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the gatewayAdvertisedRoute field is set. + */ + @java.lang.Override + public boolean hasGatewayAdvertisedRoute() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
    +   * Required. The gateway advertised route to update.
    +   *
    +   * The gateway advertised route's `name` field is used to identify the gateway
    +   * advertised route to update. Format:
    +   * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The gatewayAdvertisedRoute. + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + getGatewayAdvertisedRoute() { + return gatewayAdvertisedRoute_ == null + ? com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance() + : gatewayAdvertisedRoute_; + } + + /** + * + * + *
    +   * Required. The gateway advertised route to update.
    +   *
    +   * The gateway advertised route's `name` field is used to identify the gateway
    +   * advertised route to update. Format:
    +   * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder + getGatewayAdvertisedRouteOrBuilder() { + return gatewayAdvertisedRoute_ == null + ? com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance() + : gatewayAdvertisedRoute_; + } + + public static final int REQUEST_ID_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object requestId_ = ""; + + /** + * + * + *
    +   * Optional. A request ID to identify requests. Specify a unique request ID so
    +   * that if you must retry your request, the server knows to ignore the request
    +   * if it has already been completed. The server guarantees that a request
    +   * doesn't result in creation of duplicate commitments for at least 60
    +   * minutes.
    +   *
    +   * For example, consider a situation where you make an initial request and
    +   * the request times out. If you make the request again with the same request
    +   * ID, the server can check to see whether the original operation
    +   * was received. If it was, the server ignores the second request. This
    +   * behavior prevents clients from mistakenly creating duplicate commitments.
    +   *
    +   * The request ID must be a valid UUID, with the exception that zero UUID is
    +   * not supported (00000000-0000-0000-0000-000000000000).
    +   * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + @java.lang.Override + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } + } + + /** + * + * + *
    +   * Optional. A request ID to identify requests. Specify a unique request ID so
    +   * that if you must retry your request, the server knows to ignore the request
    +   * if it has already been completed. The server guarantees that a request
    +   * doesn't result in creation of duplicate commitments for at least 60
    +   * minutes.
    +   *
    +   * For example, consider a situation where you make an initial request and
    +   * the request times out. If you make the request again with the same request
    +   * ID, the server can check to see whether the original operation
    +   * was received. If it was, the server ignores the second request. This
    +   * behavior prevents clients from mistakenly creating duplicate commitments.
    +   *
    +   * The request ID must be a valid UUID, with the exception that zero UUID is
    +   * not supported (00000000-0000-0000-0000-000000000000).
    +   * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getUpdateMask()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getGatewayAdvertisedRoute()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, requestId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getUpdateMask()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(2, getGatewayAdvertisedRoute()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, requestId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest)) { + return super.equals(obj); + } + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest other = + (com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest) obj; + + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (hasGatewayAdvertisedRoute() != other.hasGatewayAdvertisedRoute()) return false; + if (hasGatewayAdvertisedRoute()) { + if (!getGatewayAdvertisedRoute().equals(other.getGatewayAdvertisedRoute())) return false; + } + if (!getRequestId().equals(other.getRequestId())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + if (hasGatewayAdvertisedRoute()) { + hash = (37 * hash) + GATEWAY_ADVERTISED_ROUTE_FIELD_NUMBER; + hash = (53 * hash) + getGatewayAdvertisedRoute().hashCode(); + } + hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; + hash = (53 * hash) + getRequestId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * The request for
    +   * [HubService.UpdateGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.UpdateGatewayAdvertisedRoute].
    +   * 
    + * + * Protobuf type {@code google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest) + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_UpdateGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_UpdateGatewayAdvertisedRouteRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest.class, + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest.Builder + .class); + } + + // Construct using + // com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetUpdateMaskFieldBuilder(); + internalGetGatewayAdvertisedRouteFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + gatewayAdvertisedRoute_ = null; + if (gatewayAdvertisedRouteBuilder_ != null) { + gatewayAdvertisedRouteBuilder_.dispose(); + gatewayAdvertisedRouteBuilder_ = null; + } + requestId_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.networkconnectivity.v1.HubProto + .internal_static_google_cloud_networkconnectivity_v1_UpdateGatewayAdvertisedRouteRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + getDefaultInstanceForType() { + return com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest build() { + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + buildPartial() { + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest result = + new com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.updateMask_ = updateMaskBuilder_ == null ? updateMask_ : updateMaskBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.gatewayAdvertisedRoute_ = + gatewayAdvertisedRouteBuilder_ == null + ? gatewayAdvertisedRoute_ + : gatewayAdvertisedRouteBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.requestId_ = requestId_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest) { + return mergeFrom( + (com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest other) { + if (other + == com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + .getDefaultInstance()) return this; + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + if (other.hasGatewayAdvertisedRoute()) { + mergeGatewayAdvertisedRoute(other.getGatewayAdvertisedRoute()); + } + if (!other.getRequestId().isEmpty()) { + requestId_ = other.requestId_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetGatewayAdvertisedRouteFieldBuilder().getBuilder(), + extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + requestId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + + /** + * + * + *
    +     * Optional. In the case of an update to an existing group, field mask is used
    +     * to specify the fields to be overwritten. The fields specified in the
    +     * update_mask are relative to the resource, not the full request. A field is
    +     * overwritten if it is in the mask. If the user does not provide a mask, then
    +     * all fields are overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +     * Optional. In the case of an update to an existing group, field mask is used
    +     * to specify the fields to be overwritten. The fields specified in the
    +     * update_mask are relative to the resource, not the full request. A field is
    +     * overwritten if it is in the mask. If the user does not provide a mask, then
    +     * all fields are overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Optional. In the case of an update to an existing group, field mask is used
    +     * to specify the fields to be overwritten. The fields specified in the
    +     * update_mask are relative to the resource, not the full request. A field is
    +     * overwritten if it is in the mask. If the user does not provide a mask, then
    +     * all fields are overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + } else { + updateMaskBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. In the case of an update to an existing group, field mask is used
    +     * to specify the fields to be overwritten. The fields specified in the
    +     * update_mask are relative to the resource, not the full request. A field is
    +     * overwritten if it is in the mask. If the user does not provide a mask, then
    +     * all fields are overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. In the case of an update to an existing group, field mask is used
    +     * to specify the fields to be overwritten. The fields specified in the
    +     * update_mask are relative to the resource, not the full request. A field is
    +     * overwritten if it is in the mask. If the user does not provide a mask, then
    +     * all fields are overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && updateMask_ != null + && updateMask_ != com.google.protobuf.FieldMask.getDefaultInstance()) { + getUpdateMaskBuilder().mergeFrom(value); + } else { + updateMask_ = value; + } + } else { + updateMaskBuilder_.mergeFrom(value); + } + if (updateMask_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Optional. In the case of an update to an existing group, field mask is used
    +     * to specify the fields to be overwritten. The fields specified in the
    +     * update_mask are relative to the resource, not the full request. A field is
    +     * overwritten if it is in the mask. If the user does not provide a mask, then
    +     * all fields are overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearUpdateMask() { + bitField0_ = (bitField0_ & ~0x00000001); + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. In the case of an update to an existing group, field mask is used
    +     * to specify the fields to be overwritten. The fields specified in the
    +     * update_mask are relative to the resource, not the full request. A field is
    +     * overwritten if it is in the mask. If the user does not provide a mask, then
    +     * all fields are overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetUpdateMaskFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Optional. In the case of an update to an existing group, field mask is used
    +     * to specify the fields to be overwritten. The fields specified in the
    +     * update_mask are relative to the resource, not the full request. A field is
    +     * overwritten if it is in the mask. If the user does not provide a mask, then
    +     * all fields are overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + + /** + * + * + *
    +     * Optional. In the case of an update to an existing group, field mask is used
    +     * to specify the fields to be overwritten. The fields specified in the
    +     * update_mask are relative to the resource, not the full request. A field is
    +     * overwritten if it is in the mask. If the user does not provide a mask, then
    +     * all fields are overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + internalGetUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + private com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gatewayAdvertisedRoute_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder> + gatewayAdvertisedRouteBuilder_; + + /** + * + * + *
    +     * Required. The gateway advertised route to update.
    +     *
    +     * The gateway advertised route's `name` field is used to identify the gateway
    +     * advertised route to update. Format:
    +     * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the gatewayAdvertisedRoute field is set. + */ + public boolean hasGatewayAdvertisedRoute() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
    +     * Required. The gateway advertised route to update.
    +     *
    +     * The gateway advertised route's `name` field is used to identify the gateway
    +     * advertised route to update. Format:
    +     * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The gatewayAdvertisedRoute. + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + getGatewayAdvertisedRoute() { + if (gatewayAdvertisedRouteBuilder_ == null) { + return gatewayAdvertisedRoute_ == null + ? com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance() + : gatewayAdvertisedRoute_; + } else { + return gatewayAdvertisedRouteBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Required. The gateway advertised route to update.
    +     *
    +     * The gateway advertised route's `name` field is used to identify the gateway
    +     * advertised route to update. Format:
    +     * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute value) { + if (gatewayAdvertisedRouteBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + gatewayAdvertisedRoute_ = value; + } else { + gatewayAdvertisedRouteBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The gateway advertised route to update.
    +     *
    +     * The gateway advertised route's `name` field is used to identify the gateway
    +     * advertised route to update. Format:
    +     * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder builderForValue) { + if (gatewayAdvertisedRouteBuilder_ == null) { + gatewayAdvertisedRoute_ = builderForValue.build(); + } else { + gatewayAdvertisedRouteBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The gateway advertised route to update.
    +     *
    +     * The gateway advertised route's `name` field is used to identify the gateway
    +     * advertised route to update. Format:
    +     * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeGatewayAdvertisedRoute( + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute value) { + if (gatewayAdvertisedRouteBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && gatewayAdvertisedRoute_ != null + && gatewayAdvertisedRoute_ + != com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute + .getDefaultInstance()) { + getGatewayAdvertisedRouteBuilder().mergeFrom(value); + } else { + gatewayAdvertisedRoute_ = value; + } + } else { + gatewayAdvertisedRouteBuilder_.mergeFrom(value); + } + if (gatewayAdvertisedRoute_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Required. The gateway advertised route to update.
    +     *
    +     * The gateway advertised route's `name` field is used to identify the gateway
    +     * advertised route to update. Format:
    +     * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearGatewayAdvertisedRoute() { + bitField0_ = (bitField0_ & ~0x00000002); + gatewayAdvertisedRoute_ = null; + if (gatewayAdvertisedRouteBuilder_ != null) { + gatewayAdvertisedRouteBuilder_.dispose(); + gatewayAdvertisedRouteBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The gateway advertised route to update.
    +     *
    +     * The gateway advertised route's `name` field is used to identify the gateway
    +     * advertised route to update. Format:
    +     * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder + getGatewayAdvertisedRouteBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetGatewayAdvertisedRouteFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Required. The gateway advertised route to update.
    +     *
    +     * The gateway advertised route's `name` field is used to identify the gateway
    +     * advertised route to update. Format:
    +     * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder + getGatewayAdvertisedRouteOrBuilder() { + if (gatewayAdvertisedRouteBuilder_ != null) { + return gatewayAdvertisedRouteBuilder_.getMessageOrBuilder(); + } else { + return gatewayAdvertisedRoute_ == null + ? com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.getDefaultInstance() + : gatewayAdvertisedRoute_; + } + } + + /** + * + * + *
    +     * Required. The gateway advertised route to update.
    +     *
    +     * The gateway advertised route's `name` field is used to identify the gateway
    +     * advertised route to update. Format:
    +     * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +     * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder> + internalGetGatewayAdvertisedRouteFieldBuilder() { + if (gatewayAdvertisedRouteBuilder_ == null) { + gatewayAdvertisedRouteBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute.Builder, + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder>( + getGatewayAdvertisedRoute(), getParentForChildren(), isClean()); + gatewayAdvertisedRoute_ = null; + } + return gatewayAdvertisedRouteBuilder_; + } + + private java.lang.Object requestId_ = ""; + + /** + * + * + *
    +     * Optional. A request ID to identify requests. Specify a unique request ID so
    +     * that if you must retry your request, the server knows to ignore the request
    +     * if it has already been completed. The server guarantees that a request
    +     * doesn't result in creation of duplicate commitments for at least 60
    +     * minutes.
    +     *
    +     * For example, consider a situation where you make an initial request and
    +     * the request times out. If you make the request again with the same request
    +     * ID, the server can check to see whether the original operation
    +     * was received. If it was, the server ignores the second request. This
    +     * behavior prevents clients from mistakenly creating duplicate commitments.
    +     *
    +     * The request ID must be a valid UUID, with the exception that zero UUID is
    +     * not supported (00000000-0000-0000-0000-000000000000).
    +     * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Optional. A request ID to identify requests. Specify a unique request ID so
    +     * that if you must retry your request, the server knows to ignore the request
    +     * if it has already been completed. The server guarantees that a request
    +     * doesn't result in creation of duplicate commitments for at least 60
    +     * minutes.
    +     *
    +     * For example, consider a situation where you make an initial request and
    +     * the request times out. If you make the request again with the same request
    +     * ID, the server can check to see whether the original operation
    +     * was received. If it was, the server ignores the second request. This
    +     * behavior prevents clients from mistakenly creating duplicate commitments.
    +     *
    +     * The request ID must be a valid UUID, with the exception that zero UUID is
    +     * not supported (00000000-0000-0000-0000-000000000000).
    +     * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Optional. A request ID to identify requests. Specify a unique request ID so
    +     * that if you must retry your request, the server knows to ignore the request
    +     * if it has already been completed. The server guarantees that a request
    +     * doesn't result in creation of duplicate commitments for at least 60
    +     * minutes.
    +     *
    +     * For example, consider a situation where you make an initial request and
    +     * the request times out. If you make the request again with the same request
    +     * ID, the server can check to see whether the original operation
    +     * was received. If it was, the server ignores the second request. This
    +     * behavior prevents clients from mistakenly creating duplicate commitments.
    +     *
    +     * The request ID must be a valid UUID, with the exception that zero UUID is
    +     * not supported (00000000-0000-0000-0000-000000000000).
    +     * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + requestId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. A request ID to identify requests. Specify a unique request ID so
    +     * that if you must retry your request, the server knows to ignore the request
    +     * if it has already been completed. The server guarantees that a request
    +     * doesn't result in creation of duplicate commitments for at least 60
    +     * minutes.
    +     *
    +     * For example, consider a situation where you make an initial request and
    +     * the request times out. If you make the request again with the same request
    +     * ID, the server can check to see whether the original operation
    +     * was received. If it was, the server ignores the second request. This
    +     * behavior prevents clients from mistakenly creating duplicate commitments.
    +     *
    +     * The request ID must be a valid UUID, with the exception that zero UUID is
    +     * not supported (00000000-0000-0000-0000-000000000000).
    +     * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearRequestId() { + requestId_ = getDefaultInstance().getRequestId(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. A request ID to identify requests. Specify a unique request ID so
    +     * that if you must retry your request, the server knows to ignore the request
    +     * if it has already been completed. The server guarantees that a request
    +     * doesn't result in creation of duplicate commitments for at least 60
    +     * minutes.
    +     *
    +     * For example, consider a situation where you make an initial request and
    +     * the request times out. If you make the request again with the same request
    +     * ID, the server can check to see whether the original operation
    +     * was received. If it was, the server ignores the second request. This
    +     * behavior prevents clients from mistakenly creating duplicate commitments.
    +     *
    +     * The request ID must be a valid UUID, with the exception that zero UUID is
    +     * not supported (00000000-0000-0000-0000-000000000000).
    +     * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + requestId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest) + private static final com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest(); + } + + public static com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateGatewayAdvertisedRouteRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/UpdateGatewayAdvertisedRouteRequestOrBuilder.java b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/UpdateGatewayAdvertisedRouteRequestOrBuilder.java new file mode 100644 index 000000000000..bb7dc47d762f --- /dev/null +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/java/com/google/cloud/networkconnectivity/v1/UpdateGatewayAdvertisedRouteRequestOrBuilder.java @@ -0,0 +1,192 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/networkconnectivity/v1/hub.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.networkconnectivity.v1; + +@com.google.protobuf.Generated +public interface UpdateGatewayAdvertisedRouteRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * Optional. In the case of an update to an existing group, field mask is used
    +   * to specify the fields to be overwritten. The fields specified in the
    +   * update_mask are relative to the resource, not the full request. A field is
    +   * overwritten if it is in the mask. If the user does not provide a mask, then
    +   * all fields are overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + + /** + * + * + *
    +   * Optional. In the case of an update to an existing group, field mask is used
    +   * to specify the fields to be overwritten. The fields specified in the
    +   * update_mask are relative to the resource, not the full request. A field is
    +   * overwritten if it is in the mask. If the user does not provide a mask, then
    +   * all fields are overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + + /** + * + * + *
    +   * Optional. In the case of an update to an existing group, field mask is used
    +   * to specify the fields to be overwritten. The fields specified in the
    +   * update_mask are relative to the resource, not the full request. A field is
    +   * overwritten if it is in the mask. If the user does not provide a mask, then
    +   * all fields are overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); + + /** + * + * + *
    +   * Required. The gateway advertised route to update.
    +   *
    +   * The gateway advertised route's `name` field is used to identify the gateway
    +   * advertised route to update. Format:
    +   * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the gatewayAdvertisedRoute field is set. + */ + boolean hasGatewayAdvertisedRoute(); + + /** + * + * + *
    +   * Required. The gateway advertised route to update.
    +   *
    +   * The gateway advertised route's `name` field is used to identify the gateway
    +   * advertised route to update. Format:
    +   * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The gatewayAdvertisedRoute. + */ + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute getGatewayAdvertisedRoute(); + + /** + * + * + *
    +   * Required. The gateway advertised route to update.
    +   *
    +   * The gateway advertised route's `name` field is used to identify the gateway
    +   * advertised route to update. Format:
    +   * `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}`
    +   * 
    + * + * + * .google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute gateway_advertised_route = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteOrBuilder + getGatewayAdvertisedRouteOrBuilder(); + + /** + * + * + *
    +   * Optional. A request ID to identify requests. Specify a unique request ID so
    +   * that if you must retry your request, the server knows to ignore the request
    +   * if it has already been completed. The server guarantees that a request
    +   * doesn't result in creation of duplicate commitments for at least 60
    +   * minutes.
    +   *
    +   * For example, consider a situation where you make an initial request and
    +   * the request times out. If you make the request again with the same request
    +   * ID, the server can check to see whether the original operation
    +   * was received. If it was, the server ignores the second request. This
    +   * behavior prevents clients from mistakenly creating duplicate commitments.
    +   *
    +   * The request ID must be a valid UUID, with the exception that zero UUID is
    +   * not supported (00000000-0000-0000-0000-000000000000).
    +   * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + java.lang.String getRequestId(); + + /** + * + * + *
    +   * Optional. A request ID to identify requests. Specify a unique request ID so
    +   * that if you must retry your request, the server knows to ignore the request
    +   * if it has already been completed. The server guarantees that a request
    +   * doesn't result in creation of duplicate commitments for at least 60
    +   * minutes.
    +   *
    +   * For example, consider a situation where you make an initial request and
    +   * the request times out. If you make the request again with the same request
    +   * ID, the server can check to see whether the original operation
    +   * was received. If it was, the server ignores the second request. This
    +   * behavior prevents clients from mistakenly creating duplicate commitments.
    +   *
    +   * The request ID must be a valid UUID, with the exception that zero UUID is
    +   * not supported (00000000-0000-0000-0000-000000000000).
    +   * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + com.google.protobuf.ByteString getRequestIdBytes(); +} diff --git a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/hub.proto b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/hub.proto index c12320483ebf..0cc309dae644 100644 --- a/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/hub.proto +++ b/java-networkconnectivity/proto-google-cloud-networkconnectivity-v1/src/main/proto/google/cloud/networkconnectivity/v1/hub.proto @@ -1,4 +1,4 @@ -// Copyright 2025 Google LLC +// Copyright 2026 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -42,6 +42,10 @@ option (google.api.resource_definition) = { type: "compute.googleapis.com/Instance" pattern: "projects/{project}/zones/{zone}/instances/{instance}" }; +option (google.api.resource_definition) = { + type: "networksecurity.googleapis.com/SACAttachment" + pattern: "projects/{project}/locations/{location}/sacAttachments/{sac_attachment}" +}; // Network Connectivity Center is a hub-and-spoke abstraction for network // connectivity management in Google Cloud. It reduces operational complexity @@ -301,18 +305,67 @@ service HubService { metadata_type: "OperationMetadata" }; } -} -// Supported features for a location -enum LocationFeature { - // No publicly supported feature in this location - LOCATION_FEATURE_UNSPECIFIED = 0; + // Create a GatewayAdvertisedRoute + rpc CreateGatewayAdvertisedRoute(CreateGatewayAdvertisedRouteRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*/spokes/*}/gatewayAdvertisedRoutes" + body: "gateway_advertised_route" + }; + option (google.api.method_signature) = + "parent,gateway_advertised_route,gateway_advertised_route_id"; + option (google.longrunning.operation_info) = { + response_type: "GatewayAdvertisedRoute" + metadata_type: "OperationMetadata" + }; + } - // Site-to-cloud spokes are supported in this location - SITE_TO_CLOUD_SPOKES = 1; + // Get a GatewayAdvertisedRoute + rpc GetGatewayAdvertisedRoute(GetGatewayAdvertisedRouteRequest) + returns (GatewayAdvertisedRoute) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/spokes/*/gatewayAdvertisedRoutes/*}" + }; + option (google.api.method_signature) = "name"; + } - // Site-to-site spokes are supported in this location - SITE_TO_SITE_SPOKES = 2; + // List GatewayAdvertisedRoutes + rpc ListGatewayAdvertisedRoutes(ListGatewayAdvertisedRoutesRequest) + returns (ListGatewayAdvertisedRoutesResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*/spokes/*}/gatewayAdvertisedRoutes" + }; + option (google.api.method_signature) = "parent"; + } + + // Update a GatewayAdvertisedRoute + rpc UpdateGatewayAdvertisedRoute(UpdateGatewayAdvertisedRouteRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + patch: "/v1/{gateway_advertised_route.name=projects/*/locations/*/spokes/*/gatewayAdvertisedRoutes/*}" + body: "gateway_advertised_route" + }; + option (google.api.method_signature) = + "gateway_advertised_route,update_mask"; + option (google.longrunning.operation_info) = { + response_type: "GatewayAdvertisedRoute" + metadata_type: "OperationMetadata" + }; + } + + // Delete a GatewayAdvertisedRoute + rpc DeleteGatewayAdvertisedRoute(DeleteGatewayAdvertisedRouteRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/spokes/*/gatewayAdvertisedRoutes/*}" + }; + option (google.api.method_signature) = "name"; + option (google.longrunning.operation_info) = { + response_type: "google.protobuf.Empty" + metadata_type: "OperationMetadata" + }; + } } // The route's type @@ -332,6 +385,10 @@ enum RouteType { // derived from Border Gateway Protocol (BGP) advertisements received from an // NCC hybrid spoke. DYNAMIC_ROUTE = 3; + + // The route leads to a destination within the Private Service Connect + // Global Google API range of the VPC network. + PSC_GLOBAL_GAPI = 4; } // The State enum represents the lifecycle stage of a Network Connectivity @@ -389,6 +446,9 @@ enum SpokeType { // Spokes associated with VPC networks. VPC_NETWORK = 4; + // Spokes that are NCC gateways. + GATEWAY = 5; + // Spokes that are backed by a producer VPC network. PRODUCER_VPC_NETWORK = 7; } @@ -417,6 +477,28 @@ enum PresetTopology { // automatically created along with hub creation. Spokes have to join one of // the groups during creation. STAR = 3; + + // Hybrid inspection has 4 groups ('non-prod', 'prod', 'services', and + // 'untrusted') that are automatically created along with hub creation. + HYBRID_INSPECTION = 4; +} + +// Supported features for a location +enum LocationFeature { + // No publicly supported feature in this location + LOCATION_FEATURE_UNSPECIFIED = 0; + + // Site-to-cloud spokes are supported in this location + SITE_TO_CLOUD_SPOKES = 1; + + // Site-to-site spokes are supported in this location + SITE_TO_SITE_SPOKES = 2; + + // Gateway spokes are supported in this location. + GATEWAY_SPOKES = 3; + + // Supports transports in this location. + TRANSPORTS = 4; } // A Network Connectivity Center hub is a global management resource to which @@ -431,6 +513,23 @@ message Hub { pattern: "projects/{project}/locations/global/hubs/{hub}" }; + // Configuration for more granular control of Private Service Connect + // connection propagation. + // This allows enabling or disabling connection propagation for specific types + // of Private Service Connect endpoints. + message ExportPscConfig { + // Optional. Controls whether Private Service Connect endpoints for regional + // ILBs and regional Google APIs should be propagated. Default value is true + // if export_psc is true. Otherwise, the default value is false. + optional bool published_services_and_regional_google_apis = 1 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Controls whether Private Service Connect endpoints for global + // Google APIs should be propagated. The default value is false. + optional bool global_google_apis = 2 + [(google.api.field_behavior) = OPTIONAL]; + } + // Immutable. The name of the hub. Hub names must be unique. They use the // following form: // `projects/{project_number}/locations/global/hubs/{hub_id}` @@ -460,11 +559,12 @@ message Hub { // Output only. The current lifecycle state of this hub. State state = 9 [(google.api.field_behavior) = OUTPUT_ONLY]; - // The VPC networks associated with this hub's spokes. + // Output only. The VPC networks associated with this hub's spokes. // // This field is read-only. Network Connectivity Center automatically // populates it based on the set of spokes attached to the hub. - repeated RoutingVPC routing_vpcs = 10; + repeated RoutingVPC routing_vpcs = 10 + [(google.api.field_behavior) = OUTPUT_ONLY]; // Output only. The route tables that belong to this hub. They use the // following form: @@ -498,6 +598,11 @@ message Hub { // attached to the hub are made accessible to other VPC spokes attached to the // hub. The default value is false. optional bool export_psc = 15 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Config for more granular control of Private Service Connect + // transitivity. + ExportPscConfig export_psc_config = 17 + [(google.api.field_behavior) = OPTIONAL]; } // RoutingVPC contains information about the VPC networks associated @@ -533,9 +638,9 @@ message Spoke { pattern: "projects/{project}/locations/{location}/spokes/{spoke}" }; - // The reason a spoke is inactive. + // The reason for the current state of the spoke. message StateReason { - // The Code enum represents the various reasons a state can be `INACTIVE`. + // The Code enum represents the various reasons for the state of the spoke. enum Code { // No information available. CODE_UNSPECIFIED = 0; @@ -627,6 +732,10 @@ message Spoke { LinkedVpcNetwork linked_vpc_network = 20 [(google.api.field_behavior) = OPTIONAL]; + // Optional. This is a gateway that can apply specialized processing to + // traffic going through it. + Gateway gateway = 24 [(google.api.field_behavior) = OPTIONAL]; + // Optional. The linked producer VPC that is associated with the spoke. LinkedProducerVpcNetwork linked_producer_vpc_network = 26 [(google.api.field_behavior) = OPTIONAL]; @@ -650,9 +759,9 @@ message Spoke { // client has an up-to-date value before proceeding. string etag = 27 [(google.api.field_behavior) = OPTIONAL]; - // Optional. The list of fields waiting for hub administration's approval. + // Output only. The list of fields waiting for hub administrator's approval. repeated string field_paths_pending_update = 28 - [(google.api.field_behavior) = OPTIONAL]; + [(google.api.field_behavior) = OUTPUT_ONLY]; } message RouteTable { @@ -772,6 +881,9 @@ message Route { // Immutable. The next-hop VLAN attachment for packets on this route. NextHopInterconnectAttachment next_hop_interconnect_attachment = 16 [(google.api.field_behavior) = IMMUTABLE]; + + // Immutable. The next-hop spoke for packets on this route. + NextHopSpoke next_hop_spoke = 18 [(google.api.field_behavior) = IMMUTABLE]; } // A group represents a subset of spokes attached to a hub. @@ -817,7 +929,12 @@ message Group { // Output only. The name of the route table that corresponds to this group. // They use the following form: // `projects/{project_number}/locations/global/hubs/{hub_id}/routeTables/{route_table_id}` - string route_table = 9 [(google.api.field_behavior) = OUTPUT_ONLY]; + string route_table = 9 [ + (google.api.field_behavior) = OUTPUT_ONLY, + (google.api.resource_reference) = { + type: "networkconnectivity.googleapis.com/RouteTable" + } + ]; } // The auto-accept setting for a group controls whether @@ -1700,11 +1817,45 @@ message LinkedVpnTunnels { (google.api.resource_reference) = { type: "compute.googleapis.com/Network" } ]; - // Optional. IP ranges allowed to be included during import from hub (does not - // control transit connectivity). The only allowed value for now is - // "ALL_IPV4_RANGES". + // Optional. Hub routes fully encompassed by include import ranges are + // included during import from hub. repeated string include_import_ranges = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed include import IP ranges waiting for hub + // administrator's approval. + repeated string proposed_include_import_ranges = 11 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Hub routes overlapped/encompassed by exclude import ranges are + // excluded during import from hub. + repeated string exclude_import_ranges = 6 + [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed exclude import IP ranges waiting for hub + // administrator's approval. + repeated string proposed_exclude_import_ranges = 12 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Dynamic routes fully encompassed by include export ranges are + // included during export to hub. + repeated string include_export_ranges = 7 + [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed include export IP ranges waiting for hub + // administrator's approval. + repeated string proposed_include_export_ranges = 9 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Dynamic routes overlapped/encompassed by exclude export ranges + // are excluded during export to hub. + repeated string exclude_export_ranges = 8 + [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed exclude export IP ranges waiting for hub + // administrator's approval. + repeated string proposed_exclude_export_ranges = 10 + [(google.api.field_behavior) = OUTPUT_ONLY]; } // A collection of VLAN attachment resources. These resources should @@ -1728,11 +1879,45 @@ message LinkedInterconnectAttachments { (google.api.resource_reference) = { type: "compute.googleapis.com/Network" } ]; - // Optional. IP ranges allowed to be included during import from hub (does not - // control transit connectivity). The only allowed value for now is - // "ALL_IPV4_RANGES". + // Optional. Hub routes fully encompassed by include import ranges are + // included during import from hub. repeated string include_import_ranges = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed include import IP ranges waiting for hub + // administrator's approval. + repeated string proposed_include_import_ranges = 11 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Hub routes overlapped/encompassed by exclude import ranges are + // excluded during import from hub. + repeated string exclude_import_ranges = 6 + [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed exclude import IP ranges waiting for hub + // administrator's approval. + repeated string proposed_exclude_import_ranges = 12 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Dynamic routes fully encompassed by include export ranges are + // included during export to hub. + repeated string include_export_ranges = 7 + [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed include export IP ranges waiting for hub + // administrator's approval. + repeated string proposed_include_export_ranges = 9 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Dynamic routes overlapped/encompassed by exclude export ranges + // are excluded during export to hub. + repeated string exclude_export_ranges = 8 + [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed exclude export IP ranges waiting for hub + // administrator's approval. + repeated string proposed_exclude_export_ranges = 10 + [(google.api.field_behavior) = OUTPUT_ONLY]; } // A collection of router appliance instances. If you configure multiple router @@ -1755,11 +1940,45 @@ message LinkedRouterApplianceInstances { (google.api.resource_reference) = { type: "compute.googleapis.com/Network" } ]; - // Optional. IP ranges allowed to be included during import from hub (does not - // control transit connectivity). The only allowed value for now is - // "ALL_IPV4_RANGES". + // Optional. Hub routes fully encompassed by include import ranges are + // included during import from hub. repeated string include_import_ranges = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed include import IP ranges waiting for hub + // administrator's approval. + repeated string proposed_include_import_ranges = 11 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Hub routes overlapped/encompassed by exclude import ranges are + // excluded during import from hub. + repeated string exclude_import_ranges = 6 + [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed exclude import IP ranges waiting for hub + // administrator's approval. + repeated string proposed_exclude_import_ranges = 12 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Dynamic routes fully encompassed by include export ranges are + // included during export to hub. + repeated string include_export_ranges = 7 + [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed include export IP ranges waiting for hub + // administrator's approval. + repeated string proposed_include_export_ranges = 9 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Dynamic routes overlapped/encompassed by exclude export ranges + // are excluded during export to hub. + repeated string exclude_export_ranges = 8 + [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The proposed exclude export IP ranges waiting for hub + // administrator's approval. + repeated string proposed_exclude_export_ranges = 10 + [(google.api.field_behavior) = OUTPUT_ONLY]; } // An existing VPC network. @@ -1778,20 +1997,20 @@ message LinkedVpcNetwork { repeated string include_export_ranges = 3 [(google.api.field_behavior) = OPTIONAL]; - // Optional. The proposed include export IP ranges waiting for hub - // administration's approval. + // Output only. The proposed include export IP ranges waiting for hub + // administrator's approval. repeated string proposed_include_export_ranges = 5 - [(google.api.field_behavior) = OPTIONAL]; + [(google.api.field_behavior) = OUTPUT_ONLY]; // Output only. The proposed exclude export IP ranges waiting for hub - // administration's approval. + // administrator's approval. repeated string proposed_exclude_export_ranges = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; // Output only. The list of Producer VPC spokes that this VPC spoke is a // service consumer VPC spoke for. These producer VPCs are connected through // VPC peering to this spoke's backing VPC network. Because they are directly - // connected throuh VPC peering, NCC export filters do not apply between the + // connected through VPC peering, NCC export filters do not apply between the // service consumer VPC spoke and any of its producer VPC spokes. This VPC // spoke cannot be deleted as long as any of these producer VPC spokes are // connected to the NCC Hub. @@ -1803,6 +2022,289 @@ message LinkedVpcNetwork { ]; } +// A gateway that can apply specialized traffic processing. +message Gateway { + // A list of IP ranges that are reserved for this gateway's internal + // intfrastructure. + message IpRangeReservation { + // Required. A block of IP addresses used to allocate supporting + // infrastructure for this gateway. This block must not overlap with subnets + // in any spokes or peer VPC networks that the gateway can communicate with. + // Example: "10.1.2.0/24" + string ip_range = 1 [(google.api.field_behavior) = REQUIRED]; + } + + // The aggregate processing capacity of this gateway. + enum GatewayCapacity { + // The gateway capacity is unspecified. + GATEWAY_CAPACITY_UNSPECIFIED = 0; + + // The gateway has 1 Gbps of aggregate processing capacity + CAPACITY_1_GBPS = 5; + + // The gateway has 10 Gbps of aggregate processing capacity + CAPACITY_10_GBPS = 1; + } + + // Optional. A list of IP ranges that are reserved for this gateway's internal + // intfrastructure. + repeated IpRangeReservation ip_range_reservations = 7 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The aggregate processing capacity of this gateway. + GatewayCapacity capacity = 10 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The list of Cloud Routers that are connected to this gateway. + // Should be in the form: + // https://www.googleapis.com/compute/v1/projects/{project}/regions/{region}/routers/{router} + repeated string cloud_routers = 13 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The URI of the connected SACAttachment. + // Should be in the form: + // projects/{project}/locations/{location}/sacAttachments/{sac_attachment} + string sac_attachment = 14 [ + (google.api.field_behavior) = OUTPUT_ONLY, + (google.api.resource_reference) = { + type: "networksecurity.googleapis.com/SACAttachment" + } + ]; +} + +// A gateway advertised route is a route that a gateway spoke advertises +// somewhere. +message GatewayAdvertisedRoute { + option (google.api.resource) = { + type: "networkconnectivity.googleapis.com/GatewayAdvertisedRoute" + pattern: "projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route}" + plural: "gatewayAdvertisedRoutes" + singular: "gatewayAdvertisedRoute" + }; + + // The recipient of an advertised route. + enum Recipient { + // No recipient specified. By default routes are advertised to the hub. + RECIPIENT_UNSPECIFIED = 0; + + // Advertises a route toward the hub. Other spokes reachable from this spoke + // will receive the route. + ADVERTISE_TO_HUB = 1; + } + + // Identifier. The name of the gateway advertised route. Route names must be + // unique and use the following form: + // `projects/{project_number}/locations/{region}/spokes/{spoke}/gatewayAdvertisedRoutes/{gateway_advertised_route_id}` + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Output only. The time the gateway advertised route was created. + google.protobuf.Timestamp create_time = 2 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The time the gateway advertised route was last updated. + google.protobuf.Timestamp update_time = 3 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional labels in key-value pair format. For more information about + // labels, see [Requirements for + // labels](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements). + map labels = 4; + + // An optional description of the gateway advertised route. + string description = 5; + + // Output only. The Google-generated UUID for the gateway advertised route. + // This value is unique across all gateway advertised route resources. If a + // gateway advertised route is deleted and another with the same name is + // created, the new route is assigned a different `unique_id`. + string unique_id = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The current lifecycle state of this gateway advertised route. + State state = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Immutable. This route's advertised IP address range. Must be a valid + // CIDR-formatted prefix. If an IP address is provided without a subnet mask, + // it is interpreted as, for IPv4, a `/32` singular IP address range, and, for + // IPv6, + // `/128`. + string ip_range = 8 [(google.api.field_behavior) = IMMUTABLE]; + + // Optional. The priority of this advertised route. You can choose a value + // from `0` to `65335`. If you don't provide a value, Google Cloud assigns a + // priority of `100` to the ranges. + optional int32 priority = 9 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The recipient of this advertised route. + Recipient recipient = 10 [(google.api.field_behavior) = OPTIONAL]; +} + +// The request for +// [HubService.CreateGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.CreateGatewayAdvertisedRoute]. +message CreateGatewayAdvertisedRouteRequest { + // Required. The parent resource. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "networkconnectivity.googleapis.com/Spoke" + } + ]; + + // Required. Unique id for the route to create. + string gateway_advertised_route_id = 2 + [(google.api.field_behavior) = REQUIRED]; + + // Required. Initial values for the new gateway advertised route. + GatewayAdvertisedRoute gateway_advertised_route = 3 + [(google.api.field_behavior) = REQUIRED]; + + // Optional. A request ID to identify requests. Specify a unique request ID so + // that if you must retry your request, the server knows to ignore the request + // if it has already been completed. The server guarantees that a request + // doesn't result in creation of duplicate commitments for at least 60 + // minutes. + // + // For example, consider a situation where you make an initial request and + // the request times out. If you make the request again with the same request + // ID, the server can check to see whether the original operation + // was received. If it was, the server ignores the second request. This + // behavior prevents clients from mistakenly creating duplicate commitments. + // + // The request ID must be a valid UUID, with the exception that zero UUID is + // not supported (00000000-0000-0000-0000-000000000000). + string request_id = 4 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OPTIONAL + ]; +} + +// The request for +// [HubService.GetGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.GetGatewayAdvertisedRoute]. +message GetGatewayAdvertisedRouteRequest { + // Required. The name of the gateway advertised route to get. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "networkconnectivity.googleapis.com/GatewayAdvertisedRoute" + } + ]; +} + +// The request for +// [HubService.ListGatewayAdvertisedRoutes][google.cloud.networkconnectivity.v1.HubService.ListGatewayAdvertisedRoutes]. +message ListGatewayAdvertisedRoutesRequest { + // Required. The parent resource's name. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "networkconnectivity.googleapis.com/Spoke" + } + ]; + + // Optional. The maximum number of results per page that should be returned. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A page token, received from a previous + // `ListGatewayAdvertisedRoutes` call. Provide this to retrieve the subsequent + // page. + // + // When paginating, all other parameters provided to + // `ListGatewayAdvertisedRoutes` must match the call that provided the page + // token. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; + + // An expression that filters the list of results. + string filter = 4; + + // Sort the results by a certain order. + string order_by = 5; +} + +// Response for +// [HubService.ListGatewayAdvertisedRoutes][google.cloud.networkconnectivity.v1.HubService.ListGatewayAdvertisedRoutes] +// method. +message ListGatewayAdvertisedRoutesResponse { + // The requested gateway advertised routes. + repeated GatewayAdvertisedRoute gateway_advertised_routes = 1; + + // The token for the next page of the response. To see more results, + // use this value as the page_token for your next request. If this value + // is empty, there are no more results. + string next_page_token = 2; + + // Hubs that could not be reached. + repeated string unreachable = 3; +} + +// The request for +// [HubService.UpdateGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.UpdateGatewayAdvertisedRoute]. +message UpdateGatewayAdvertisedRouteRequest { + // Optional. In the case of an update to an existing group, field mask is used + // to specify the fields to be overwritten. The fields specified in the + // update_mask are relative to the resource, not the full request. A field is + // overwritten if it is in the mask. If the user does not provide a mask, then + // all fields are overwritten. + google.protobuf.FieldMask update_mask = 1 + [(google.api.field_behavior) = OPTIONAL]; + + // Required. The gateway advertised route to update. + // + // The gateway advertised route's `name` field is used to identify the gateway + // advertised route to update. Format: + // `projects/{project}/locations/{location}/spokes/{spoke}/gatewayAdvertisedRoutes/{gatewayAdvertisedRoute}` + GatewayAdvertisedRoute gateway_advertised_route = 2 + [(google.api.field_behavior) = REQUIRED]; + + // Optional. A request ID to identify requests. Specify a unique request ID so + // that if you must retry your request, the server knows to ignore the request + // if it has already been completed. The server guarantees that a request + // doesn't result in creation of duplicate commitments for at least 60 + // minutes. + // + // For example, consider a situation where you make an initial request and + // the request times out. If you make the request again with the same request + // ID, the server can check to see whether the original operation + // was received. If it was, the server ignores the second request. This + // behavior prevents clients from mistakenly creating duplicate commitments. + // + // The request ID must be a valid UUID, with the exception that zero UUID is + // not supported (00000000-0000-0000-0000-000000000000). + string request_id = 3 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OPTIONAL + ]; +} + +// Request for +// [HubService.DeleteGatewayAdvertisedRoute][google.cloud.networkconnectivity.v1.HubService.DeleteGatewayAdvertisedRoute] +// method. +message DeleteGatewayAdvertisedRouteRequest { + // Required. The name of the gateway advertised route to delete. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "networkconnectivity.googleapis.com/GatewayAdvertisedRoute" + } + ]; + + // Optional. A request ID to identify requests. Specify a unique request ID so + // that if you must retry your request, the server knows to ignore the request + // if it has already been completed. The server guarantees that a request + // doesn't result in creation of duplicate commitments for at least 60 + // minutes. + // + // For example, consider a situation where you make an initial request and + // the request times out. If you make the request again with the same request + // ID, the server can check to see whether the original operation + // was received. If it was, the server ignores the second request. This + // behavior prevents clients from mistakenly creating duplicate commitments. + // + // The request ID must be a valid UUID, with the exception that zero UUID is + // not supported (00000000-0000-0000-0000-000000000000). + string request_id = 2 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OPTIONAL + ]; +} + message LinkedProducerVpcNetwork { // Immutable. The URI of the Service Consumer VPC that the Producer VPC is // peered with. @@ -1838,13 +2340,13 @@ message LinkedProducerVpcNetwork { repeated string include_export_ranges = 4 [(google.api.field_behavior) = OPTIONAL]; - // Optional. The proposed include export IP ranges waiting for hub - // administration's approval. + // Output only. The proposed include export IP ranges waiting for hub + // administrator's approval. repeated string proposed_include_export_ranges = 7 - [(google.api.field_behavior) = OPTIONAL]; + [(google.api.field_behavior) = OUTPUT_ONLY]; // Output only. The proposed exclude export IP ranges waiting for hub - // administration's approval. + // administrator's approval. repeated string proposed_exclude_export_ranges = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; } @@ -1931,6 +2433,23 @@ message NextHopInterconnectAttachment { bool site_to_site_data_transfer = 3; } +// A route next hop that leads to a spoke resource. +message NextHopSpoke { + // The URI of the spoke resource. + string uri = 1 [(google.api.resource_reference) = { + type: "networkconnectivity.googleapis.com/Spoke" + }]; + + // Indicates whether site-to-site data transfer is allowed for this + // spoke resource. Data transfer is available only in + // [supported + // locations](https://cloud.google.com/network-connectivity/docs/network-connectivity-center/concepts/locations). + // Whether this route is accessible to other hybrid spokes with site-to-site + // data transfer enabled. If this is false, the route is only accessible to + // VPC spokes of the connected Hub. + bool site_to_site_data_transfer = 2; +} + // Summarizes information about the spokes associated with a hub. // The summary includes a count of spokes according to type // and according to state. If any spokes are inactive, diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/AsyncCreateGatewayAdvertisedRoute.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/AsyncCreateGatewayAdvertisedRoute.java new file mode 100644 index 000000000000..6c1b7221c9c3 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/AsyncCreateGatewayAdvertisedRoute.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_CreateGatewayAdvertisedRoute_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.SpokeName; +import com.google.longrunning.Operation; + +public class AsyncCreateGatewayAdvertisedRoute { + + public static void main(String[] args) throws Exception { + asyncCreateGatewayAdvertisedRoute(); + } + + public static void asyncCreateGatewayAdvertisedRoute() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + CreateGatewayAdvertisedRouteRequest request = + CreateGatewayAdvertisedRouteRequest.newBuilder() + .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) + .setGatewayAdvertisedRouteId("gatewayAdvertisedRouteId1531070339") + .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + ApiFuture future = + hubServiceClient.createGatewayAdvertisedRouteCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_CreateGatewayAdvertisedRoute_async] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/AsyncCreateGatewayAdvertisedRouteLRO.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/AsyncCreateGatewayAdvertisedRouteLRO.java new file mode 100644 index 000000000000..2c97d9103f7d --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/AsyncCreateGatewayAdvertisedRouteLRO.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_CreateGatewayAdvertisedRoute_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.OperationMetadata; +import com.google.cloud.networkconnectivity.v1.SpokeName; + +public class AsyncCreateGatewayAdvertisedRouteLRO { + + public static void main(String[] args) throws Exception { + asyncCreateGatewayAdvertisedRouteLRO(); + } + + public static void asyncCreateGatewayAdvertisedRouteLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + CreateGatewayAdvertisedRouteRequest request = + CreateGatewayAdvertisedRouteRequest.newBuilder() + .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) + .setGatewayAdvertisedRouteId("gatewayAdvertisedRouteId1531070339") + .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + OperationFuture future = + hubServiceClient.createGatewayAdvertisedRouteOperationCallable().futureCall(request); + // Do something. + GatewayAdvertisedRoute response = future.get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_CreateGatewayAdvertisedRoute_LRO_async] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/SyncCreateGatewayAdvertisedRoute.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/SyncCreateGatewayAdvertisedRoute.java new file mode 100644 index 000000000000..3076f6de9d0c --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/SyncCreateGatewayAdvertisedRoute.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_CreateGatewayAdvertisedRoute_sync] +import com.google.cloud.networkconnectivity.v1.CreateGatewayAdvertisedRouteRequest; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.SpokeName; + +public class SyncCreateGatewayAdvertisedRoute { + + public static void main(String[] args) throws Exception { + syncCreateGatewayAdvertisedRoute(); + } + + public static void syncCreateGatewayAdvertisedRoute() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + CreateGatewayAdvertisedRouteRequest request = + CreateGatewayAdvertisedRouteRequest.newBuilder() + .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) + .setGatewayAdvertisedRouteId("gatewayAdvertisedRouteId1531070339") + .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + GatewayAdvertisedRoute response = + hubServiceClient.createGatewayAdvertisedRouteAsync(request).get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_CreateGatewayAdvertisedRoute_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/SyncCreateGatewayAdvertisedRouteSpokenameGatewayadvertisedrouteString.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/SyncCreateGatewayAdvertisedRouteSpokenameGatewayadvertisedrouteString.java new file mode 100644 index 000000000000..aef1c87b750c --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/SyncCreateGatewayAdvertisedRouteSpokenameGatewayadvertisedrouteString.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_CreateGatewayAdvertisedRoute_SpokenameGatewayadvertisedrouteString_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.SpokeName; + +public class SyncCreateGatewayAdvertisedRouteSpokenameGatewayadvertisedrouteString { + + public static void main(String[] args) throws Exception { + syncCreateGatewayAdvertisedRouteSpokenameGatewayadvertisedrouteString(); + } + + public static void syncCreateGatewayAdvertisedRouteSpokenameGatewayadvertisedrouteString() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + SpokeName parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); + GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build(); + String gatewayAdvertisedRouteId = "gatewayAdvertisedRouteId1531070339"; + GatewayAdvertisedRoute response = + hubServiceClient + .createGatewayAdvertisedRouteAsync( + parent, gatewayAdvertisedRoute, gatewayAdvertisedRouteId) + .get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_CreateGatewayAdvertisedRoute_SpokenameGatewayadvertisedrouteString_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/SyncCreateGatewayAdvertisedRouteStringGatewayadvertisedrouteString.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/SyncCreateGatewayAdvertisedRouteStringGatewayadvertisedrouteString.java new file mode 100644 index 000000000000..cfd75cf499a9 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/creategatewayadvertisedroute/SyncCreateGatewayAdvertisedRouteStringGatewayadvertisedrouteString.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_CreateGatewayAdvertisedRoute_StringGatewayadvertisedrouteString_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.SpokeName; + +public class SyncCreateGatewayAdvertisedRouteStringGatewayadvertisedrouteString { + + public static void main(String[] args) throws Exception { + syncCreateGatewayAdvertisedRouteStringGatewayadvertisedrouteString(); + } + + public static void syncCreateGatewayAdvertisedRouteStringGatewayadvertisedrouteString() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + String parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString(); + GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build(); + String gatewayAdvertisedRouteId = "gatewayAdvertisedRouteId1531070339"; + GatewayAdvertisedRoute response = + hubServiceClient + .createGatewayAdvertisedRouteAsync( + parent, gatewayAdvertisedRoute, gatewayAdvertisedRouteId) + .get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_CreateGatewayAdvertisedRoute_StringGatewayadvertisedrouteString_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/AsyncDeleteGatewayAdvertisedRoute.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/AsyncDeleteGatewayAdvertisedRoute.java new file mode 100644 index 000000000000..2698d227363d --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/AsyncDeleteGatewayAdvertisedRoute.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_DeleteGatewayAdvertisedRoute_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteName; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.longrunning.Operation; + +public class AsyncDeleteGatewayAdvertisedRoute { + + public static void main(String[] args) throws Exception { + asyncDeleteGatewayAdvertisedRoute(); + } + + public static void asyncDeleteGatewayAdvertisedRoute() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + DeleteGatewayAdvertisedRouteRequest request = + DeleteGatewayAdvertisedRouteRequest.newBuilder() + .setName( + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString()) + .setRequestId("requestId693933066") + .build(); + ApiFuture future = + hubServiceClient.deleteGatewayAdvertisedRouteCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_DeleteGatewayAdvertisedRoute_async] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/AsyncDeleteGatewayAdvertisedRouteLRO.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/AsyncDeleteGatewayAdvertisedRouteLRO.java new file mode 100644 index 000000000000..bfd3a523d967 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/AsyncDeleteGatewayAdvertisedRouteLRO.java @@ -0,0 +1,55 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_DeleteGatewayAdvertisedRoute_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteName; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.OperationMetadata; +import com.google.protobuf.Empty; + +public class AsyncDeleteGatewayAdvertisedRouteLRO { + + public static void main(String[] args) throws Exception { + asyncDeleteGatewayAdvertisedRouteLRO(); + } + + public static void asyncDeleteGatewayAdvertisedRouteLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + DeleteGatewayAdvertisedRouteRequest request = + DeleteGatewayAdvertisedRouteRequest.newBuilder() + .setName( + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString()) + .setRequestId("requestId693933066") + .build(); + OperationFuture future = + hubServiceClient.deleteGatewayAdvertisedRouteOperationCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_DeleteGatewayAdvertisedRoute_LRO_async] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/SyncDeleteGatewayAdvertisedRoute.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/SyncDeleteGatewayAdvertisedRoute.java new file mode 100644 index 000000000000..8519c19518d2 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/SyncDeleteGatewayAdvertisedRoute.java @@ -0,0 +1,50 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_DeleteGatewayAdvertisedRoute_sync] +import com.google.cloud.networkconnectivity.v1.DeleteGatewayAdvertisedRouteRequest; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteName; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.protobuf.Empty; + +public class SyncDeleteGatewayAdvertisedRoute { + + public static void main(String[] args) throws Exception { + syncDeleteGatewayAdvertisedRoute(); + } + + public static void syncDeleteGatewayAdvertisedRoute() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + DeleteGatewayAdvertisedRouteRequest request = + DeleteGatewayAdvertisedRouteRequest.newBuilder() + .setName( + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString()) + .setRequestId("requestId693933066") + .build(); + hubServiceClient.deleteGatewayAdvertisedRouteAsync(request).get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_DeleteGatewayAdvertisedRoute_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/SyncDeleteGatewayAdvertisedRouteGatewayadvertisedroutename.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/SyncDeleteGatewayAdvertisedRouteGatewayadvertisedroutename.java new file mode 100644 index 000000000000..30ec4575dce3 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/SyncDeleteGatewayAdvertisedRouteGatewayadvertisedroutename.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_DeleteGatewayAdvertisedRoute_Gatewayadvertisedroutename_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteName; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.protobuf.Empty; + +public class SyncDeleteGatewayAdvertisedRouteGatewayadvertisedroutename { + + public static void main(String[] args) throws Exception { + syncDeleteGatewayAdvertisedRouteGatewayadvertisedroutename(); + } + + public static void syncDeleteGatewayAdvertisedRouteGatewayadvertisedroutename() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + GatewayAdvertisedRouteName name = + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]"); + hubServiceClient.deleteGatewayAdvertisedRouteAsync(name).get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_DeleteGatewayAdvertisedRoute_Gatewayadvertisedroutename_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/SyncDeleteGatewayAdvertisedRouteString.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/SyncDeleteGatewayAdvertisedRouteString.java new file mode 100644 index 000000000000..5c19c4fe9b0d --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/deletegatewayadvertisedroute/SyncDeleteGatewayAdvertisedRouteString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_DeleteGatewayAdvertisedRoute_String_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteName; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.protobuf.Empty; + +public class SyncDeleteGatewayAdvertisedRouteString { + + public static void main(String[] args) throws Exception { + syncDeleteGatewayAdvertisedRouteString(); + } + + public static void syncDeleteGatewayAdvertisedRouteString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + String name = + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString(); + hubServiceClient.deleteGatewayAdvertisedRouteAsync(name).get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_DeleteGatewayAdvertisedRoute_String_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/AsyncGetGatewayAdvertisedRoute.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/AsyncGetGatewayAdvertisedRoute.java new file mode 100644 index 000000000000..680b1b135d2e --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/AsyncGetGatewayAdvertisedRoute.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_GetGatewayAdvertisedRoute_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteName; +import com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; + +public class AsyncGetGatewayAdvertisedRoute { + + public static void main(String[] args) throws Exception { + asyncGetGatewayAdvertisedRoute(); + } + + public static void asyncGetGatewayAdvertisedRoute() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + GetGatewayAdvertisedRouteRequest request = + GetGatewayAdvertisedRouteRequest.newBuilder() + .setName( + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString()) + .build(); + ApiFuture future = + hubServiceClient.getGatewayAdvertisedRouteCallable().futureCall(request); + // Do something. + GatewayAdvertisedRoute response = future.get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_GetGatewayAdvertisedRoute_async] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/SyncGetGatewayAdvertisedRoute.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/SyncGetGatewayAdvertisedRoute.java new file mode 100644 index 000000000000..439a83408502 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/SyncGetGatewayAdvertisedRoute.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_GetGatewayAdvertisedRoute_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteName; +import com.google.cloud.networkconnectivity.v1.GetGatewayAdvertisedRouteRequest; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; + +public class SyncGetGatewayAdvertisedRoute { + + public static void main(String[] args) throws Exception { + syncGetGatewayAdvertisedRoute(); + } + + public static void syncGetGatewayAdvertisedRoute() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + GetGatewayAdvertisedRouteRequest request = + GetGatewayAdvertisedRouteRequest.newBuilder() + .setName( + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString()) + .build(); + GatewayAdvertisedRoute response = hubServiceClient.getGatewayAdvertisedRoute(request); + } + } +} +// [END networkconnectivity_v1_generated_HubService_GetGatewayAdvertisedRoute_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/SyncGetGatewayAdvertisedRouteGatewayadvertisedroutename.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/SyncGetGatewayAdvertisedRouteGatewayadvertisedroutename.java new file mode 100644 index 000000000000..1ad35857a3ba --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/SyncGetGatewayAdvertisedRouteGatewayadvertisedroutename.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_GetGatewayAdvertisedRoute_Gatewayadvertisedroutename_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteName; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; + +public class SyncGetGatewayAdvertisedRouteGatewayadvertisedroutename { + + public static void main(String[] args) throws Exception { + syncGetGatewayAdvertisedRouteGatewayadvertisedroutename(); + } + + public static void syncGetGatewayAdvertisedRouteGatewayadvertisedroutename() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + GatewayAdvertisedRouteName name = + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]"); + GatewayAdvertisedRoute response = hubServiceClient.getGatewayAdvertisedRoute(name); + } + } +} +// [END networkconnectivity_v1_generated_HubService_GetGatewayAdvertisedRoute_Gatewayadvertisedroutename_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/SyncGetGatewayAdvertisedRouteString.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/SyncGetGatewayAdvertisedRouteString.java new file mode 100644 index 000000000000..71b19ee66ab1 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/getgatewayadvertisedroute/SyncGetGatewayAdvertisedRouteString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_GetGatewayAdvertisedRoute_String_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRouteName; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; + +public class SyncGetGatewayAdvertisedRouteString { + + public static void main(String[] args) throws Exception { + syncGetGatewayAdvertisedRouteString(); + } + + public static void syncGetGatewayAdvertisedRouteString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + String name = + GatewayAdvertisedRouteName.of( + "[PROJECT]", "[LOCATION]", "[SPOKE]", "[GATEWAY_ADVERTISED_ROUTE]") + .toString(); + GatewayAdvertisedRoute response = hubServiceClient.getGatewayAdvertisedRoute(name); + } + } +} +// [END networkconnectivity_v1_generated_HubService_GetGatewayAdvertisedRoute_String_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/AsyncListGatewayAdvertisedRoutes.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/AsyncListGatewayAdvertisedRoutes.java new file mode 100644 index 000000000000..2f029f02ae5e --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/AsyncListGatewayAdvertisedRoutes.java @@ -0,0 +1,56 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_ListGatewayAdvertisedRoutes_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest; +import com.google.cloud.networkconnectivity.v1.SpokeName; + +public class AsyncListGatewayAdvertisedRoutes { + + public static void main(String[] args) throws Exception { + asyncListGatewayAdvertisedRoutes(); + } + + public static void asyncListGatewayAdvertisedRoutes() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + ListGatewayAdvertisedRoutesRequest request = + ListGatewayAdvertisedRoutesRequest.newBuilder() + .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + ApiFuture future = + hubServiceClient.listGatewayAdvertisedRoutesPagedCallable().futureCall(request); + // Do something. + for (GatewayAdvertisedRoute element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END networkconnectivity_v1_generated_HubService_ListGatewayAdvertisedRoutes_async] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/AsyncListGatewayAdvertisedRoutesPaged.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/AsyncListGatewayAdvertisedRoutesPaged.java new file mode 100644 index 000000000000..ac3784148852 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/AsyncListGatewayAdvertisedRoutesPaged.java @@ -0,0 +1,64 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_ListGatewayAdvertisedRoutes_Paged_async] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest; +import com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesResponse; +import com.google.cloud.networkconnectivity.v1.SpokeName; +import com.google.common.base.Strings; + +public class AsyncListGatewayAdvertisedRoutesPaged { + + public static void main(String[] args) throws Exception { + asyncListGatewayAdvertisedRoutesPaged(); + } + + public static void asyncListGatewayAdvertisedRoutesPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + ListGatewayAdvertisedRoutesRequest request = + ListGatewayAdvertisedRoutesRequest.newBuilder() + .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + while (true) { + ListGatewayAdvertisedRoutesResponse response = + hubServiceClient.listGatewayAdvertisedRoutesCallable().call(request); + for (GatewayAdvertisedRoute element : response.getGatewayAdvertisedRoutesList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END networkconnectivity_v1_generated_HubService_ListGatewayAdvertisedRoutes_Paged_async] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/SyncListGatewayAdvertisedRoutes.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/SyncListGatewayAdvertisedRoutes.java new file mode 100644 index 000000000000..85c1a90b1a54 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/SyncListGatewayAdvertisedRoutes.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_ListGatewayAdvertisedRoutes_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.ListGatewayAdvertisedRoutesRequest; +import com.google.cloud.networkconnectivity.v1.SpokeName; + +public class SyncListGatewayAdvertisedRoutes { + + public static void main(String[] args) throws Exception { + syncListGatewayAdvertisedRoutes(); + } + + public static void syncListGatewayAdvertisedRoutes() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + ListGatewayAdvertisedRoutesRequest request = + ListGatewayAdvertisedRoutesRequest.newBuilder() + .setParent(SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + for (GatewayAdvertisedRoute element : + hubServiceClient.listGatewayAdvertisedRoutes(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END networkconnectivity_v1_generated_HubService_ListGatewayAdvertisedRoutes_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/SyncListGatewayAdvertisedRoutesSpokename.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/SyncListGatewayAdvertisedRoutesSpokename.java new file mode 100644 index 000000000000..94d84e0e9fd7 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/SyncListGatewayAdvertisedRoutesSpokename.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_ListGatewayAdvertisedRoutes_Spokename_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.SpokeName; + +public class SyncListGatewayAdvertisedRoutesSpokename { + + public static void main(String[] args) throws Exception { + syncListGatewayAdvertisedRoutesSpokename(); + } + + public static void syncListGatewayAdvertisedRoutesSpokename() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + SpokeName parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]"); + for (GatewayAdvertisedRoute element : + hubServiceClient.listGatewayAdvertisedRoutes(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END networkconnectivity_v1_generated_HubService_ListGatewayAdvertisedRoutes_Spokename_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/SyncListGatewayAdvertisedRoutesString.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/SyncListGatewayAdvertisedRoutesString.java new file mode 100644 index 000000000000..cfa6a5fa0da9 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/listgatewayadvertisedroutes/SyncListGatewayAdvertisedRoutesString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_ListGatewayAdvertisedRoutes_String_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.SpokeName; + +public class SyncListGatewayAdvertisedRoutesString { + + public static void main(String[] args) throws Exception { + syncListGatewayAdvertisedRoutesString(); + } + + public static void syncListGatewayAdvertisedRoutesString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + String parent = SpokeName.of("[PROJECT]", "[LOCATION]", "[SPOKE]").toString(); + for (GatewayAdvertisedRoute element : + hubServiceClient.listGatewayAdvertisedRoutes(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END networkconnectivity_v1_generated_HubService_ListGatewayAdvertisedRoutes_String_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/AsyncUpdateGatewayAdvertisedRoute.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/AsyncUpdateGatewayAdvertisedRoute.java new file mode 100644 index 000000000000..04b5c6036758 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/AsyncUpdateGatewayAdvertisedRoute.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_UpdateGatewayAdvertisedRoute_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest; +import com.google.longrunning.Operation; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateGatewayAdvertisedRoute { + + public static void main(String[] args) throws Exception { + asyncUpdateGatewayAdvertisedRoute(); + } + + public static void asyncUpdateGatewayAdvertisedRoute() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + UpdateGatewayAdvertisedRouteRequest request = + UpdateGatewayAdvertisedRouteRequest.newBuilder() + .setUpdateMask(FieldMask.newBuilder().build()) + .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + ApiFuture future = + hubServiceClient.updateGatewayAdvertisedRouteCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_UpdateGatewayAdvertisedRoute_async] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/AsyncUpdateGatewayAdvertisedRouteLRO.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/AsyncUpdateGatewayAdvertisedRouteLRO.java new file mode 100644 index 000000000000..03282d78cdf5 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/AsyncUpdateGatewayAdvertisedRouteLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_UpdateGatewayAdvertisedRoute_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.OperationMetadata; +import com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateGatewayAdvertisedRouteLRO { + + public static void main(String[] args) throws Exception { + asyncUpdateGatewayAdvertisedRouteLRO(); + } + + public static void asyncUpdateGatewayAdvertisedRouteLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + UpdateGatewayAdvertisedRouteRequest request = + UpdateGatewayAdvertisedRouteRequest.newBuilder() + .setUpdateMask(FieldMask.newBuilder().build()) + .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + OperationFuture future = + hubServiceClient.updateGatewayAdvertisedRouteOperationCallable().futureCall(request); + // Do something. + GatewayAdvertisedRoute response = future.get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_UpdateGatewayAdvertisedRoute_LRO_async] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/SyncUpdateGatewayAdvertisedRoute.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/SyncUpdateGatewayAdvertisedRoute.java new file mode 100644 index 000000000000..bd0b10acda77 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/SyncUpdateGatewayAdvertisedRoute.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_UpdateGatewayAdvertisedRoute_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.cloud.networkconnectivity.v1.UpdateGatewayAdvertisedRouteRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateGatewayAdvertisedRoute { + + public static void main(String[] args) throws Exception { + syncUpdateGatewayAdvertisedRoute(); + } + + public static void syncUpdateGatewayAdvertisedRoute() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + UpdateGatewayAdvertisedRouteRequest request = + UpdateGatewayAdvertisedRouteRequest.newBuilder() + .setUpdateMask(FieldMask.newBuilder().build()) + .setGatewayAdvertisedRoute(GatewayAdvertisedRoute.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + GatewayAdvertisedRoute response = + hubServiceClient.updateGatewayAdvertisedRouteAsync(request).get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_UpdateGatewayAdvertisedRoute_sync] diff --git a/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/SyncUpdateGatewayAdvertisedRouteGatewayadvertisedrouteFieldmask.java b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/SyncUpdateGatewayAdvertisedRouteGatewayadvertisedrouteFieldmask.java new file mode 100644 index 000000000000..8e05d9bb5eb0 --- /dev/null +++ b/java-networkconnectivity/samples/snippets/generated/com/google/cloud/networkconnectivity/v1/hubservice/updategatewayadvertisedroute/SyncUpdateGatewayAdvertisedRouteGatewayadvertisedrouteFieldmask.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.networkconnectivity.v1.samples; + +// [START networkconnectivity_v1_generated_HubService_UpdateGatewayAdvertisedRoute_GatewayadvertisedrouteFieldmask_sync] +import com.google.cloud.networkconnectivity.v1.GatewayAdvertisedRoute; +import com.google.cloud.networkconnectivity.v1.HubServiceClient; +import com.google.protobuf.FieldMask; + +public class SyncUpdateGatewayAdvertisedRouteGatewayadvertisedrouteFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateGatewayAdvertisedRouteGatewayadvertisedrouteFieldmask(); + } + + public static void syncUpdateGatewayAdvertisedRouteGatewayadvertisedrouteFieldmask() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (HubServiceClient hubServiceClient = HubServiceClient.create()) { + GatewayAdvertisedRoute gatewayAdvertisedRoute = GatewayAdvertisedRoute.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + GatewayAdvertisedRoute response = + hubServiceClient + .updateGatewayAdvertisedRouteAsync(gatewayAdvertisedRoute, updateMask) + .get(); + } + } +} +// [END networkconnectivity_v1_generated_HubService_UpdateGatewayAdvertisedRoute_GatewayadvertisedrouteFieldmask_sync] diff --git a/java-networkservices/README.md b/java-networkservices/README.md index 8f2e3cbd1ba3..8e56194862b1 100644 --- a/java-networkservices/README.md +++ b/java-networkservices/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-networkservices - 0.58.0 + 0.59.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-networkservices' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-networkservices:0.58.0' +implementation 'com.google.cloud:google-cloud-networkservices:0.59.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-networkservices" % "0.58.0" +libraryDependencies += "com.google.cloud" % "google-cloud-networkservices" % "0.59.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-networkservices/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-networkservices.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-networkservices/0.58.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-networkservices/0.59.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-notebooks/README.md b/java-notebooks/README.md index a0ea7b81f94a..fea8fdfb22ab 100644 --- a/java-notebooks/README.md +++ b/java-notebooks/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-notebooks - 1.100.0 + 1.101.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-notebooks' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-notebooks:1.100.0' +implementation 'com.google.cloud:google-cloud-notebooks:1.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-notebooks" % "1.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-notebooks" % "1.101.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-notebooks/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-notebooks.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-notebooks/1.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-notebooks/1.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-observability/README.md b/java-observability/README.md index 47c0abb8a611..4fc704ab7cd0 100644 --- a/java-observability/README.md +++ b/java-observability/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-observability - 0.2.0 + 0.3.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-observability' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-observability:0.2.0' +implementation 'com.google.cloud:google-cloud-observability:0.3.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-observability" % "0.2.0" +libraryDependencies += "com.google.cloud" % "google-cloud-observability" % "0.3.0" ``` ## Authentication @@ -187,7 +187,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-observability/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-observability.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-observability/0.2.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-observability/0.3.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-optimization/README.md b/java-optimization/README.md index 357c94cec70c..397875f36dab 100644 --- a/java-optimization/README.md +++ b/java-optimization/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-optimization - 1.100.0 + 1.101.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-optimization' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-optimization:1.100.0' +implementation 'com.google.cloud:google-cloud-optimization:1.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-optimization" % "1.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-optimization" % "1.101.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-optimization/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-optimization.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-optimization/1.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-optimization/1.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-oracledatabase/README.md b/java-oracledatabase/README.md index 0a300866f3fd..56fd436ee3c9 100644 --- a/java-oracledatabase/README.md +++ b/java-oracledatabase/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-oracledatabase - 0.51.0 + 0.52.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-oracledatabase' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-oracledatabase:0.51.0' +implementation 'com.google.cloud:google-cloud-oracledatabase:0.52.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-oracledatabase" % "0.51.0" +libraryDependencies += "com.google.cloud" % "google-cloud-oracledatabase" % "0.52.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-oracledatabase/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-oracledatabase.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-oracledatabase/0.51.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-oracledatabase/0.52.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClient.java b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClient.java index 7a3c5b7323ee..ff5281805141 100644 --- a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClient.java +++ b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClient.java @@ -1111,6 +1111,25 @@ * * * + *

    UpdateOdbDnsZone + *

    Updates the `labels` of a single ODB DNS Zone. + * + *

    Request object method variants only take one parameter, a request object, which must be constructed before the call.

    + *
      + *
    • updateOdbDnsZoneAsync(UpdateOdbDnsZoneRequest request) + *

    + *

    Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

    + *
      + *
    • updateOdbDnsZoneAsync(OdbDnsZone odbDnsZone, FieldMask updateMask) + *

    + *

    Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

    + *
      + *
    • updateOdbDnsZoneOperationCallable() + *

    • updateOdbDnsZoneCallable() + *

    + * + * + * *

    DeleteOdbDnsZone *

    Deletes a single ODB DNS Zone. * @@ -10887,6 +10906,140 @@ public final UnaryCallable createOdbDnsZoneC return stub.createOdbDnsZoneCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the `labels` of a single ODB DNS Zone. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (OracleDatabaseClient oracleDatabaseClient = OracleDatabaseClient.create()) {
    +   *   OdbDnsZone odbDnsZone = OdbDnsZone.newBuilder().build();
    +   *   FieldMask updateMask = FieldMask.newBuilder().build();
    +   *   OdbDnsZone response =
    +   *       oracleDatabaseClient.updateOdbDnsZoneAsync(odbDnsZone, updateMask).get();
    +   * }
    +   * }
    + * + * @param odbDnsZone Required. The resource being updated. Note only labels can be updated. The + * provided labels will completely replace the existing labels. Any existing label keys that + * are not included in the update request will be deleted. Not providing labels and + * update_mask will not update the labels. To clear all labels, specify `labels` in the + * `update_mask` and omit or leave the `labels` field empty in the update request. + * @param updateMask Optional. A mask specifying which fields in the OdbDnsZone should be updated. + * A field specified in the mask is updated. If a mask isn't provided, the service treats this + * as an implied field mask equivalent to all fields that are populated (have a non-empty + * value). To clear or unset a field, the field must be explicitly specified in the + * `update_mask`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateOdbDnsZoneAsync( + OdbDnsZone odbDnsZone, FieldMask updateMask) { + UpdateOdbDnsZoneRequest request = + UpdateOdbDnsZoneRequest.newBuilder() + .setOdbDnsZone(odbDnsZone) + .setUpdateMask(updateMask) + .build(); + return updateOdbDnsZoneAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the `labels` of a single ODB DNS Zone. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (OracleDatabaseClient oracleDatabaseClient = OracleDatabaseClient.create()) {
    +   *   UpdateOdbDnsZoneRequest request =
    +   *       UpdateOdbDnsZoneRequest.newBuilder()
    +   *           .setUpdateMask(FieldMask.newBuilder().build())
    +   *           .setOdbDnsZone(OdbDnsZone.newBuilder().build())
    +   *           .setRequestId("requestId693933066")
    +   *           .build();
    +   *   OdbDnsZone response = oracleDatabaseClient.updateOdbDnsZoneAsync(request).get();
    +   * }
    +   * }
    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateOdbDnsZoneAsync( + UpdateOdbDnsZoneRequest request) { + return updateOdbDnsZoneOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the `labels` of a single ODB DNS Zone. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (OracleDatabaseClient oracleDatabaseClient = OracleDatabaseClient.create()) {
    +   *   UpdateOdbDnsZoneRequest request =
    +   *       UpdateOdbDnsZoneRequest.newBuilder()
    +   *           .setUpdateMask(FieldMask.newBuilder().build())
    +   *           .setOdbDnsZone(OdbDnsZone.newBuilder().build())
    +   *           .setRequestId("requestId693933066")
    +   *           .build();
    +   *   OperationFuture future =
    +   *       oracleDatabaseClient.updateOdbDnsZoneOperationCallable().futureCall(request);
    +   *   // Do something.
    +   *   OdbDnsZone response = future.get();
    +   * }
    +   * }
    + */ + public final OperationCallable + updateOdbDnsZoneOperationCallable() { + return stub.updateOdbDnsZoneOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the `labels` of a single ODB DNS Zone. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (OracleDatabaseClient oracleDatabaseClient = OracleDatabaseClient.create()) {
    +   *   UpdateOdbDnsZoneRequest request =
    +   *       UpdateOdbDnsZoneRequest.newBuilder()
    +   *           .setUpdateMask(FieldMask.newBuilder().build())
    +   *           .setOdbDnsZone(OdbDnsZone.newBuilder().build())
    +   *           .setRequestId("requestId693933066")
    +   *           .build();
    +   *   ApiFuture future =
    +   *       oracleDatabaseClient.updateOdbDnsZoneCallable().futureCall(request);
    +   *   // Do something.
    +   *   Operation response = future.get();
    +   * }
    +   * }
    + */ + public final UnaryCallable updateOdbDnsZoneCallable() { + return stub.updateOdbDnsZoneCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Deletes a single ODB DNS Zone. diff --git a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseSettings.java b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseSettings.java index 4c31d750c595..a06d919cfe07 100644 --- a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseSettings.java +++ b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseSettings.java @@ -721,6 +721,17 @@ public UnaryCallSettings createOdbDnsZoneSet return ((OracleDatabaseStubSettings) getStubSettings()).createOdbDnsZoneOperationSettings(); } + /** Returns the object with the settings used for calls to updateOdbDnsZone. */ + public UnaryCallSettings updateOdbDnsZoneSettings() { + return ((OracleDatabaseStubSettings) getStubSettings()).updateOdbDnsZoneSettings(); + } + + /** Returns the object with the settings used for calls to updateOdbDnsZone. */ + public OperationCallSettings + updateOdbDnsZoneOperationSettings() { + return ((OracleDatabaseStubSettings) getStubSettings()).updateOdbDnsZoneOperationSettings(); + } + /** Returns the object with the settings used for calls to deleteOdbDnsZone. */ public UnaryCallSettings deleteOdbDnsZoneSettings() { return ((OracleDatabaseStubSettings) getStubSettings()).deleteOdbDnsZoneSettings(); @@ -1968,6 +1979,18 @@ public UnaryCallSettings.Builder getOdbDnsZone return getStubSettingsBuilder().createOdbDnsZoneOperationSettings(); } + /** Returns the builder for the settings used for calls to updateOdbDnsZone. */ + public UnaryCallSettings.Builder + updateOdbDnsZoneSettings() { + return getStubSettingsBuilder().updateOdbDnsZoneSettings(); + } + + /** Returns the builder for the settings used for calls to updateOdbDnsZone. */ + public OperationCallSettings.Builder + updateOdbDnsZoneOperationSettings() { + return getStubSettingsBuilder().updateOdbDnsZoneOperationSettings(); + } + /** Returns the builder for the settings used for calls to deleteOdbDnsZone. */ public UnaryCallSettings.Builder deleteOdbDnsZoneSettings() { diff --git a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/gapic_metadata.json b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/gapic_metadata.json index 39df87c80e55..deae04ef3b48 100644 --- a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/gapic_metadata.json +++ b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/gapic_metadata.json @@ -328,6 +328,9 @@ "UpdateGoldengateDeployment": { "methods": ["updateGoldengateDeploymentAsync", "updateGoldengateDeploymentAsync", "updateGoldengateDeploymentOperationCallable", "updateGoldengateDeploymentCallable"] }, + "UpdateOdbDnsZone": { + "methods": ["updateOdbDnsZoneAsync", "updateOdbDnsZoneAsync", "updateOdbDnsZoneOperationCallable", "updateOdbDnsZoneCallable"] + }, "UpdateOdbNetwork": { "methods": ["updateOdbNetworkAsync", "updateOdbNetworkAsync", "updateOdbNetworkOperationCallable", "updateOdbNetworkCallable"] }, diff --git a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/GrpcOracleDatabaseStub.java b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/GrpcOracleDatabaseStub.java index 62afafb99ad6..89fc60a98fe7 100644 --- a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/GrpcOracleDatabaseStub.java +++ b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/GrpcOracleDatabaseStub.java @@ -221,6 +221,7 @@ import com.google.cloud.oracledatabase.v1.UpdateGoldengateConnectionAssignmentRequest; import com.google.cloud.oracledatabase.v1.UpdateGoldengateConnectionRequest; import com.google.cloud.oracledatabase.v1.UpdateGoldengateDeploymentRequest; +import com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest; import com.google.cloud.oracledatabase.v1.UpdateOdbNetworkRequest; import com.google.cloud.oracledatabase.v1.UpdateOdbSubnetRequest; import com.google.longrunning.Operation; @@ -901,6 +902,17 @@ public class GrpcOracleDatabaseStub extends OracleDatabaseStub { .setSampledToLocalTracing(true) .build(); + private static final MethodDescriptor + updateOdbDnsZoneMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.oracledatabase.v1.OracleDatabase/UpdateOdbDnsZone") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateOdbDnsZoneRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + private static final MethodDescriptor deleteOdbDnsZoneMethodDescriptor = MethodDescriptor.newBuilder() @@ -1840,6 +1852,9 @@ public class GrpcOracleDatabaseStub extends OracleDatabaseStub { private final UnaryCallable createOdbDnsZoneCallable; private final OperationCallable createOdbDnsZoneOperationCallable; + private final UnaryCallable updateOdbDnsZoneCallable; + private final OperationCallable + updateOdbDnsZoneOperationCallable; private final UnaryCallable deleteOdbDnsZoneCallable; private final OperationCallable deleteOdbDnsZoneOperationCallable; @@ -2738,6 +2753,17 @@ protected GrpcOracleDatabaseStub( }) .setResourceNameExtractor(request -> request.getParent()) .build(); + GrpcCallSettings updateOdbDnsZoneTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateOdbDnsZoneMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add( + "odb_dns_zone.name", String.valueOf(request.getOdbDnsZone().getName())); + return builder.build(); + }) + .build(); GrpcCallSettings deleteOdbDnsZoneTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(deleteOdbDnsZoneMethodDescriptor) @@ -3895,6 +3921,15 @@ protected GrpcOracleDatabaseStub( settings.createOdbDnsZoneOperationSettings(), clientContext, operationsStub); + this.updateOdbDnsZoneCallable = + callableFactory.createUnaryCallable( + updateOdbDnsZoneTransportSettings, settings.updateOdbDnsZoneSettings(), clientContext); + this.updateOdbDnsZoneOperationCallable = + callableFactory.createOperationCallable( + updateOdbDnsZoneTransportSettings, + settings.updateOdbDnsZoneOperationSettings(), + clientContext, + operationsStub); this.deleteOdbDnsZoneCallable = callableFactory.createUnaryCallable( deleteOdbDnsZoneTransportSettings, settings.deleteOdbDnsZoneSettings(), clientContext); @@ -4964,6 +4999,17 @@ public UnaryCallable createOdbDnsZoneCallabl return createOdbDnsZoneOperationCallable; } + @Override + public UnaryCallable updateOdbDnsZoneCallable() { + return updateOdbDnsZoneCallable; + } + + @Override + public OperationCallable + updateOdbDnsZoneOperationCallable() { + return updateOdbDnsZoneOperationCallable; + } + @Override public UnaryCallable deleteOdbDnsZoneCallable() { return deleteOdbDnsZoneCallable; diff --git a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/HttpJsonOracleDatabaseStub.java b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/HttpJsonOracleDatabaseStub.java index b7cb9bebd348..c479ae85577a 100644 --- a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/HttpJsonOracleDatabaseStub.java +++ b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/HttpJsonOracleDatabaseStub.java @@ -229,6 +229,7 @@ import com.google.cloud.oracledatabase.v1.UpdateGoldengateConnectionAssignmentRequest; import com.google.cloud.oracledatabase.v1.UpdateGoldengateConnectionRequest; import com.google.cloud.oracledatabase.v1.UpdateGoldengateDeploymentRequest; +import com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest; import com.google.cloud.oracledatabase.v1.UpdateOdbNetworkRequest; import com.google.cloud.oracledatabase.v1.UpdateOdbSubnetRequest; import com.google.common.collect.ImmutableMap; @@ -2370,6 +2371,49 @@ public class HttpJsonOracleDatabaseStub extends OracleDatabaseStub { HttpJsonOperationSnapshot.create(response)) .build(); + private static final ApiMethodDescriptor + updateOdbDnsZoneMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.oracledatabase.v1.OracleDatabase/UpdateOdbDnsZone") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{odbDnsZone.name=projects/*/locations/*/odbNetworks/*/odbDnsZones/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, "odbDnsZone.name", request.getOdbDnsZone().getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "requestId", request.getRequestId()); + serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("odbDnsZone", request.getOdbDnsZone(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (UpdateOdbDnsZoneRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + private static final ApiMethodDescriptor deleteOdbDnsZoneMethodDescriptor = ApiMethodDescriptor.newBuilder() @@ -4869,6 +4913,9 @@ public class HttpJsonOracleDatabaseStub extends OracleDatabaseStub { private final UnaryCallable createOdbDnsZoneCallable; private final OperationCallable createOdbDnsZoneOperationCallable; + private final UnaryCallable updateOdbDnsZoneCallable; + private final OperationCallable + updateOdbDnsZoneOperationCallable; private final UnaryCallable deleteOdbDnsZoneCallable; private final OperationCallable deleteOdbDnsZoneOperationCallable; @@ -5856,6 +5903,18 @@ protected HttpJsonOracleDatabaseStub( }) .setResourceNameExtractor(request -> request.getParent()) .build(); + HttpJsonCallSettings updateOdbDnsZoneTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateOdbDnsZoneMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add( + "odb_dns_zone.name", String.valueOf(request.getOdbDnsZone().getName())); + return builder.build(); + }) + .build(); HttpJsonCallSettings deleteOdbDnsZoneTransportSettings = HttpJsonCallSettings.newBuilder() .setMethodDescriptor(deleteOdbDnsZoneMethodDescriptor) @@ -7083,6 +7142,15 @@ protected HttpJsonOracleDatabaseStub( settings.createOdbDnsZoneOperationSettings(), clientContext, httpJsonOperationsStub); + this.updateOdbDnsZoneCallable = + callableFactory.createUnaryCallable( + updateOdbDnsZoneTransportSettings, settings.updateOdbDnsZoneSettings(), clientContext); + this.updateOdbDnsZoneOperationCallable = + callableFactory.createOperationCallable( + updateOdbDnsZoneTransportSettings, + settings.updateOdbDnsZoneOperationSettings(), + clientContext, + httpJsonOperationsStub); this.deleteOdbDnsZoneCallable = callableFactory.createUnaryCallable( deleteOdbDnsZoneTransportSettings, settings.deleteOdbDnsZoneSettings(), clientContext); @@ -7631,6 +7699,7 @@ public static List getMethodDescriptors() { methodDescriptors.add(listOdbDnsZonesMethodDescriptor); methodDescriptors.add(getOdbDnsZoneMethodDescriptor); methodDescriptors.add(createOdbDnsZoneMethodDescriptor); + methodDescriptors.add(updateOdbDnsZoneMethodDescriptor); methodDescriptors.add(deleteOdbDnsZoneMethodDescriptor); methodDescriptors.add(listExadbVmClustersMethodDescriptor); methodDescriptors.add(getExadbVmClusterMethodDescriptor); @@ -8266,6 +8335,17 @@ public UnaryCallable createOdbDnsZoneCallabl return createOdbDnsZoneOperationCallable; } + @Override + public UnaryCallable updateOdbDnsZoneCallable() { + return updateOdbDnsZoneCallable; + } + + @Override + public OperationCallable + updateOdbDnsZoneOperationCallable() { + return updateOdbDnsZoneOperationCallable; + } + @Override public UnaryCallable deleteOdbDnsZoneCallable() { return deleteOdbDnsZoneCallable; diff --git a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/OracleDatabaseStub.java b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/OracleDatabaseStub.java index 11ce154b1d64..698d96352496 100644 --- a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/OracleDatabaseStub.java +++ b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/OracleDatabaseStub.java @@ -216,6 +216,7 @@ import com.google.cloud.oracledatabase.v1.UpdateGoldengateConnectionAssignmentRequest; import com.google.cloud.oracledatabase.v1.UpdateGoldengateConnectionRequest; import com.google.cloud.oracledatabase.v1.UpdateGoldengateDeploymentRequest; +import com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest; import com.google.cloud.oracledatabase.v1.UpdateOdbNetworkRequest; import com.google.cloud.oracledatabase.v1.UpdateOdbSubnetRequest; import com.google.longrunning.Operation; @@ -762,6 +763,15 @@ public UnaryCallable createOdbDnsZoneCallabl throw new UnsupportedOperationException("Not implemented: createOdbDnsZoneCallable()"); } + public OperationCallable + updateOdbDnsZoneOperationCallable() { + throw new UnsupportedOperationException("Not implemented: updateOdbDnsZoneOperationCallable()"); + } + + public UnaryCallable updateOdbDnsZoneCallable() { + throw new UnsupportedOperationException("Not implemented: updateOdbDnsZoneCallable()"); + } + public OperationCallable deleteOdbDnsZoneOperationCallable() { throw new UnsupportedOperationException("Not implemented: deleteOdbDnsZoneOperationCallable()"); diff --git a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/OracleDatabaseStubSettings.java b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/OracleDatabaseStubSettings.java index a8ebc87829a0..f18a84c21bb3 100644 --- a/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/OracleDatabaseStubSettings.java +++ b/java-oracledatabase/google-cloud-oracledatabase/src/main/java/com/google/cloud/oracledatabase/v1/stub/OracleDatabaseStubSettings.java @@ -262,6 +262,7 @@ import com.google.cloud.oracledatabase.v1.UpdateGoldengateConnectionAssignmentRequest; import com.google.cloud.oracledatabase.v1.UpdateGoldengateConnectionRequest; import com.google.cloud.oracledatabase.v1.UpdateGoldengateDeploymentRequest; +import com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest; import com.google.cloud.oracledatabase.v1.UpdateOdbNetworkRequest; import com.google.cloud.oracledatabase.v1.UpdateOdbSubnetRequest; import com.google.common.collect.ImmutableList; @@ -560,6 +561,9 @@ public class OracleDatabaseStubSettings extends StubSettings createOdbDnsZoneSettings; private final OperationCallSettings createOdbDnsZoneOperationSettings; + private final UnaryCallSettings updateOdbDnsZoneSettings; + private final OperationCallSettings + updateOdbDnsZoneOperationSettings; private final UnaryCallSettings deleteOdbDnsZoneSettings; private final OperationCallSettings deleteOdbDnsZoneOperationSettings; @@ -3563,6 +3567,17 @@ public UnaryCallSettings createOdbDnsZoneSet return createOdbDnsZoneOperationSettings; } + /** Returns the object with the settings used for calls to updateOdbDnsZone. */ + public UnaryCallSettings updateOdbDnsZoneSettings() { + return updateOdbDnsZoneSettings; + } + + /** Returns the object with the settings used for calls to updateOdbDnsZone. */ + public OperationCallSettings + updateOdbDnsZoneOperationSettings() { + return updateOdbDnsZoneOperationSettings; + } + /** Returns the object with the settings used for calls to deleteOdbDnsZone. */ public UnaryCallSettings deleteOdbDnsZoneSettings() { return deleteOdbDnsZoneSettings; @@ -4339,6 +4354,8 @@ protected OracleDatabaseStubSettings(Builder settingsBuilder) throws IOException getOdbDnsZoneSettings = settingsBuilder.getOdbDnsZoneSettings().build(); createOdbDnsZoneSettings = settingsBuilder.createOdbDnsZoneSettings().build(); createOdbDnsZoneOperationSettings = settingsBuilder.createOdbDnsZoneOperationSettings().build(); + updateOdbDnsZoneSettings = settingsBuilder.updateOdbDnsZoneSettings().build(); + updateOdbDnsZoneOperationSettings = settingsBuilder.updateOdbDnsZoneOperationSettings().build(); deleteOdbDnsZoneSettings = settingsBuilder.deleteOdbDnsZoneSettings().build(); deleteOdbDnsZoneOperationSettings = settingsBuilder.deleteOdbDnsZoneOperationSettings().build(); listExadbVmClustersSettings = settingsBuilder.listExadbVmClustersSettings().build(); @@ -4697,6 +4714,11 @@ public static class Builder extends StubSettings.Builder createOdbDnsZoneOperationSettings; + private final UnaryCallSettings.Builder + updateOdbDnsZoneSettings; + private final OperationCallSettings.Builder< + UpdateOdbDnsZoneRequest, OdbDnsZone, OperationMetadata> + updateOdbDnsZoneOperationSettings; private final UnaryCallSettings.Builder deleteOdbDnsZoneSettings; private final OperationCallSettings.Builder @@ -5075,6 +5097,8 @@ protected Builder(@Nullable ClientContext clientContext) { getOdbDnsZoneSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); createOdbDnsZoneSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); createOdbDnsZoneOperationSettings = OperationCallSettings.newBuilder(); + updateOdbDnsZoneSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateOdbDnsZoneOperationSettings = OperationCallSettings.newBuilder(); deleteOdbDnsZoneSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); deleteOdbDnsZoneOperationSettings = OperationCallSettings.newBuilder(); listExadbVmClustersSettings = @@ -5228,6 +5252,7 @@ protected Builder(@Nullable ClientContext clientContext) { listOdbDnsZonesSettings, getOdbDnsZoneSettings, createOdbDnsZoneSettings, + updateOdbDnsZoneSettings, deleteOdbDnsZoneSettings, listExadbVmClustersSettings, getExadbVmClusterSettings, @@ -5406,6 +5431,8 @@ protected Builder(OracleDatabaseStubSettings settings) { getOdbDnsZoneSettings = settings.getOdbDnsZoneSettings.toBuilder(); createOdbDnsZoneSettings = settings.createOdbDnsZoneSettings.toBuilder(); createOdbDnsZoneOperationSettings = settings.createOdbDnsZoneOperationSettings.toBuilder(); + updateOdbDnsZoneSettings = settings.updateOdbDnsZoneSettings.toBuilder(); + updateOdbDnsZoneOperationSettings = settings.updateOdbDnsZoneOperationSettings.toBuilder(); deleteOdbDnsZoneSettings = settings.deleteOdbDnsZoneSettings.toBuilder(); deleteOdbDnsZoneOperationSettings = settings.deleteOdbDnsZoneOperationSettings.toBuilder(); listExadbVmClustersSettings = settings.listExadbVmClustersSettings.toBuilder(); @@ -5580,6 +5607,7 @@ protected Builder(OracleDatabaseStubSettings settings) { listOdbDnsZonesSettings, getOdbDnsZoneSettings, createOdbDnsZoneSettings, + updateOdbDnsZoneSettings, deleteOdbDnsZoneSettings, listExadbVmClustersSettings, getExadbVmClusterSettings, @@ -5923,6 +5951,11 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + builder + .updateOdbDnsZoneSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); + builder .deleteOdbDnsZoneSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) @@ -6891,6 +6924,30 @@ private static Builder initDefaults(Builder builder) { .setTotalTimeoutDuration(Duration.ofMillis(300000L)) .build())); + builder + .updateOdbDnsZoneOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(OdbDnsZone.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + builder .deleteOdbDnsZoneOperationSettings() .setInitialCallSettings( @@ -8082,6 +8139,18 @@ public UnaryCallSettings.Builder getOdbDnsZone return createOdbDnsZoneOperationSettings; } + /** Returns the builder for the settings used for calls to updateOdbDnsZone. */ + public UnaryCallSettings.Builder + updateOdbDnsZoneSettings() { + return updateOdbDnsZoneSettings; + } + + /** Returns the builder for the settings used for calls to updateOdbDnsZone. */ + public OperationCallSettings.Builder + updateOdbDnsZoneOperationSettings() { + return updateOdbDnsZoneOperationSettings; + } + /** Returns the builder for the settings used for calls to deleteOdbDnsZone. */ public UnaryCallSettings.Builder deleteOdbDnsZoneSettings() { diff --git a/java-oracledatabase/google-cloud-oracledatabase/src/main/resources/META-INF/native-image/com.google.cloud.oracledatabase.v1/reflect-config.json b/java-oracledatabase/google-cloud-oracledatabase/src/main/resources/META-INF/native-image/com.google.cloud.oracledatabase.v1/reflect-config.json index 1c5b86cb0e06..54cee89f6e01 100644 --- a/java-oracledatabase/google-cloud-oracledatabase/src/main/resources/META-INF/native-image/com.google.cloud.oracledatabase.v1/reflect-config.json +++ b/java-oracledatabase/google-cloud-oracledatabase/src/main/resources/META-INF/native-image/com.google.cloud.oracledatabase.v1/reflect-config.json @@ -6767,6 +6767,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.oracledatabase.v1.UpdateOdbNetworkRequest", "queryAllDeclaredConstructors": true, diff --git a/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/MockOracleDatabaseImpl.java b/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/MockOracleDatabaseImpl.java index 915f6823edde..8d651bc6fb4a 100644 --- a/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/MockOracleDatabaseImpl.java +++ b/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/MockOracleDatabaseImpl.java @@ -1198,6 +1198,27 @@ public void createOdbDnsZone( } } + @Override + public void updateOdbDnsZone( + UpdateOdbDnsZoneRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method UpdateOdbDnsZone, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + @Override public void deleteOdbDnsZone( DeleteOdbDnsZoneRequest request, StreamObserver responseObserver) { diff --git a/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClientHttpJsonTest.java b/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClientHttpJsonTest.java index a6e88cff23c5..fa48fccd527c 100644 --- a/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClientHttpJsonTest.java +++ b/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClientHttpJsonTest.java @@ -6500,6 +6500,78 @@ public void createOdbDnsZoneExceptionTest2() throws Exception { } } + @Test + public void updateOdbDnsZoneTest() throws Exception { + OdbDnsZone expectedResponse = + OdbDnsZone.newBuilder() + .setName( + OdbDnsZoneName.of("[PROJECT]", "[LOCATION]", "[ODB_NETWORK]", "[ODB_DNS_ZONE]") + .toString()) + .setDomain("domain-1326197564") + .putAllLabels(new HashMap()) + .setCreateTime(Timestamp.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateOdbDnsZoneTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + OdbDnsZone odbDnsZone = + OdbDnsZone.newBuilder() + .setName( + OdbDnsZoneName.of("[PROJECT]", "[LOCATION]", "[ODB_NETWORK]", "[ODB_DNS_ZONE]") + .toString()) + .setDomain("domain-1326197564") + .putAllLabels(new HashMap()) + .setCreateTime(Timestamp.newBuilder().build()) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + OdbDnsZone actualResponse = client.updateOdbDnsZoneAsync(odbDnsZone, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void updateOdbDnsZoneExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + OdbDnsZone odbDnsZone = + OdbDnsZone.newBuilder() + .setName( + OdbDnsZoneName.of("[PROJECT]", "[LOCATION]", "[ODB_NETWORK]", "[ODB_DNS_ZONE]") + .toString()) + .setDomain("domain-1326197564") + .putAllLabels(new HashMap()) + .setCreateTime(Timestamp.newBuilder().build()) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateOdbDnsZoneAsync(odbDnsZone, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + @Test public void deleteOdbDnsZoneTest() throws Exception { Empty expectedResponse = Empty.newBuilder().build(); diff --git a/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClientTest.java b/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClientTest.java index 000cecdee4e9..5dc3348ff184 100644 --- a/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClientTest.java +++ b/java-oracledatabase/google-cloud-oracledatabase/src/test/java/com/google/cloud/oracledatabase/v1/OracleDatabaseClientTest.java @@ -5942,6 +5942,60 @@ public void createOdbDnsZoneExceptionTest2() throws Exception { } } + @Test + public void updateOdbDnsZoneTest() throws Exception { + OdbDnsZone expectedResponse = + OdbDnsZone.newBuilder() + .setName( + OdbDnsZoneName.of("[PROJECT]", "[LOCATION]", "[ODB_NETWORK]", "[ODB_DNS_ZONE]") + .toString()) + .setDomain("domain-1326197564") + .putAllLabels(new HashMap()) + .setCreateTime(Timestamp.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateOdbDnsZoneTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockOracleDatabase.addResponse(resultOperation); + + OdbDnsZone odbDnsZone = OdbDnsZone.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + OdbDnsZone actualResponse = client.updateOdbDnsZoneAsync(odbDnsZone, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockOracleDatabase.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateOdbDnsZoneRequest actualRequest = ((UpdateOdbDnsZoneRequest) actualRequests.get(0)); + + Assert.assertEquals(odbDnsZone, actualRequest.getOdbDnsZone()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateOdbDnsZoneExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockOracleDatabase.addException(exception); + + try { + OdbDnsZone odbDnsZone = OdbDnsZone.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateOdbDnsZoneAsync(odbDnsZone, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + @Test public void deleteOdbDnsZoneTest() throws Exception { Empty expectedResponse = Empty.newBuilder().build(); diff --git a/java-oracledatabase/grpc-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseGrpc.java b/java-oracledatabase/grpc-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseGrpc.java index 39c5052d3158..cccce1c42b16 100644 --- a/java-oracledatabase/grpc-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseGrpc.java +++ b/java-oracledatabase/grpc-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/OracleDatabaseGrpc.java @@ -2633,6 +2633,52 @@ private OracleDatabaseGrpc() {} return getCreateOdbDnsZoneMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest, + com.google.longrunning.Operation> + getUpdateOdbDnsZoneMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateOdbDnsZone", + requestType = com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest, + com.google.longrunning.Operation> + getUpdateOdbDnsZoneMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest, + com.google.longrunning.Operation> + getUpdateOdbDnsZoneMethod; + if ((getUpdateOdbDnsZoneMethod = OracleDatabaseGrpc.getUpdateOdbDnsZoneMethod) == null) { + synchronized (OracleDatabaseGrpc.class) { + if ((getUpdateOdbDnsZoneMethod = OracleDatabaseGrpc.getUpdateOdbDnsZoneMethod) == null) { + OracleDatabaseGrpc.getUpdateOdbDnsZoneMethod = + getUpdateOdbDnsZoneMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateOdbDnsZone")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new OracleDatabaseMethodDescriptorSupplier("UpdateOdbDnsZone")) + .build(); + } + } + } + return getUpdateOdbDnsZoneMethod; + } + private static volatile io.grpc.MethodDescriptor< com.google.cloud.oracledatabase.v1.DeleteOdbDnsZoneRequest, com.google.longrunning.Operation> @@ -6212,6 +6258,20 @@ default void createOdbDnsZone( getCreateOdbDnsZoneMethod(), responseObserver); } + /** + * + * + *
    +     * Updates the `labels` of a single ODB DNS Zone.
    +     * 
    + */ + default void updateOdbDnsZone( + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateOdbDnsZoneMethod(), responseObserver); + } + /** * * @@ -7923,6 +7983,22 @@ public void createOdbDnsZone( responseObserver); } + /** + * + * + *
    +     * Updates the `labels` of a single ODB DNS Zone.
    +     * 
    + */ + public void updateOdbDnsZone( + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateOdbDnsZoneMethod(), getCallOptions()), + request, + responseObserver); + } + /** * * @@ -9617,6 +9693,20 @@ public com.google.longrunning.Operation createOdbDnsZone( getChannel(), getCreateOdbDnsZoneMethod(), getCallOptions(), request); } + /** + * + * + *
    +     * Updates the `labels` of a single ODB DNS Zone.
    +     * 
    + */ + public com.google.longrunning.Operation updateOdbDnsZone( + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getUpdateOdbDnsZoneMethod(), getCallOptions(), request); + } + /** * * @@ -11124,6 +11214,19 @@ public com.google.longrunning.Operation createOdbDnsZone( getChannel(), getCreateOdbDnsZoneMethod(), getCallOptions(), request); } + /** + * + * + *
    +     * Updates the `labels` of a single ODB DNS Zone.
    +     * 
    + */ + public com.google.longrunning.Operation updateOdbDnsZone( + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateOdbDnsZoneMethod(), getCallOptions(), request); + } + /** * * @@ -12625,6 +12728,19 @@ protected OracleDatabaseFutureStub build( getChannel().newCall(getCreateOdbDnsZoneMethod(), getCallOptions()), request); } + /** + * + * + *
    +     * Updates the `labels` of a single ODB DNS Zone.
    +     * 
    + */ + public com.google.common.util.concurrent.ListenableFuture + updateOdbDnsZone(com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateOdbDnsZoneMethod(), getCallOptions()), request); + } + /** * * @@ -13475,60 +13591,61 @@ protected OracleDatabaseFutureStub build( private static final int METHODID_LIST_ODB_DNS_ZONES = 49; private static final int METHODID_GET_ODB_DNS_ZONE = 50; private static final int METHODID_CREATE_ODB_DNS_ZONE = 51; - private static final int METHODID_DELETE_ODB_DNS_ZONE = 52; - private static final int METHODID_LIST_EXADB_VM_CLUSTERS = 53; - private static final int METHODID_GET_EXADB_VM_CLUSTER = 54; - private static final int METHODID_CREATE_EXADB_VM_CLUSTER = 55; - private static final int METHODID_DELETE_EXADB_VM_CLUSTER = 56; - private static final int METHODID_UPDATE_EXADB_VM_CLUSTER = 57; - private static final int METHODID_REMOVE_VIRTUAL_MACHINE_EXADB_VM_CLUSTER = 58; - private static final int METHODID_LIST_EXASCALE_DB_STORAGE_VAULTS = 59; - private static final int METHODID_GET_EXASCALE_DB_STORAGE_VAULT = 60; - private static final int METHODID_CREATE_EXASCALE_DB_STORAGE_VAULT = 61; - private static final int METHODID_UPDATE_EXASCALE_DB_STORAGE_VAULT = 62; - private static final int METHODID_DELETE_EXASCALE_DB_STORAGE_VAULT = 63; - private static final int METHODID_LIST_DB_SYSTEM_INITIAL_STORAGE_SIZES = 64; - private static final int METHODID_LIST_DB_SYSTEM_COMPUTE_PERFORMANCES = 65; - private static final int METHODID_LIST_DATABASES = 66; - private static final int METHODID_GET_DATABASE = 67; - private static final int METHODID_LIST_PLUGGABLE_DATABASES = 68; - private static final int METHODID_GET_PLUGGABLE_DATABASE = 69; - private static final int METHODID_LIST_DB_SYSTEMS = 70; - private static final int METHODID_GET_DB_SYSTEM = 71; - private static final int METHODID_CREATE_DB_SYSTEM = 72; - private static final int METHODID_UPDATE_DB_SYSTEM = 73; - private static final int METHODID_DELETE_DB_SYSTEM = 74; - private static final int METHODID_LIST_GOLDENGATE_DEPLOYMENTS = 75; - private static final int METHODID_GET_GOLDENGATE_DEPLOYMENT = 76; - private static final int METHODID_CREATE_GOLDENGATE_DEPLOYMENT = 77; - private static final int METHODID_UPDATE_GOLDENGATE_DEPLOYMENT = 78; - private static final int METHODID_DELETE_GOLDENGATE_DEPLOYMENT = 79; - private static final int METHODID_STOP_GOLDENGATE_DEPLOYMENT = 80; - private static final int METHODID_START_GOLDENGATE_DEPLOYMENT = 81; - private static final int METHODID_LIST_GOLDENGATE_CONNECTIONS = 82; - private static final int METHODID_GET_GOLDENGATE_CONNECTION = 83; - private static final int METHODID_CREATE_GOLDENGATE_CONNECTION = 84; - private static final int METHODID_UPDATE_GOLDENGATE_CONNECTION = 85; - private static final int METHODID_DELETE_GOLDENGATE_CONNECTION = 86; - private static final int METHODID_LIST_GOLDENGATE_DEPLOYMENT_VERSIONS = 87; - private static final int METHODID_LIST_GOLDENGATE_DEPLOYMENT_TYPES = 88; - private static final int METHODID_LIST_GOLDENGATE_DEPLOYMENT_ENVIRONMENTS = 89; - private static final int METHODID_LIST_GOLDENGATE_CONNECTION_TYPES = 90; - private static final int METHODID_LIST_DB_VERSIONS = 91; - private static final int METHODID_LIST_DATABASE_CHARACTER_SETS = 92; - private static final int METHODID_LIST_GOLDENGATE_CONNECTION_ASSIGNMENTS = 93; - private static final int METHODID_GET_GOLDENGATE_CONNECTION_ASSIGNMENT = 94; - private static final int METHODID_CREATE_GOLDENGATE_CONNECTION_ASSIGNMENT = 95; - private static final int METHODID_UPDATE_GOLDENGATE_CONNECTION_ASSIGNMENT = 96; - private static final int METHODID_DELETE_GOLDENGATE_CONNECTION_ASSIGNMENT = 97; - private static final int METHODID_TEST_GOLDENGATE_CONNECTION_ASSIGNMENT = 98; - private static final int METHODID_LIST_DATABASE_CONNECTIONS = 99; - private static final int METHODID_GET_DATABASE_CONNECTION = 100; - private static final int METHODID_CREATE_DATABASE_CONNECTION = 101; - private static final int METHODID_UPDATE_DATABASE_CONNECTION = 102; - private static final int METHODID_DELETE_DATABASE_CONNECTION = 103; - private static final int METHODID_TEST_DATABASE_CONNECTION = 104; - private static final int METHODID_EXECUTE_SQL = 105; + private static final int METHODID_UPDATE_ODB_DNS_ZONE = 52; + private static final int METHODID_DELETE_ODB_DNS_ZONE = 53; + private static final int METHODID_LIST_EXADB_VM_CLUSTERS = 54; + private static final int METHODID_GET_EXADB_VM_CLUSTER = 55; + private static final int METHODID_CREATE_EXADB_VM_CLUSTER = 56; + private static final int METHODID_DELETE_EXADB_VM_CLUSTER = 57; + private static final int METHODID_UPDATE_EXADB_VM_CLUSTER = 58; + private static final int METHODID_REMOVE_VIRTUAL_MACHINE_EXADB_VM_CLUSTER = 59; + private static final int METHODID_LIST_EXASCALE_DB_STORAGE_VAULTS = 60; + private static final int METHODID_GET_EXASCALE_DB_STORAGE_VAULT = 61; + private static final int METHODID_CREATE_EXASCALE_DB_STORAGE_VAULT = 62; + private static final int METHODID_UPDATE_EXASCALE_DB_STORAGE_VAULT = 63; + private static final int METHODID_DELETE_EXASCALE_DB_STORAGE_VAULT = 64; + private static final int METHODID_LIST_DB_SYSTEM_INITIAL_STORAGE_SIZES = 65; + private static final int METHODID_LIST_DB_SYSTEM_COMPUTE_PERFORMANCES = 66; + private static final int METHODID_LIST_DATABASES = 67; + private static final int METHODID_GET_DATABASE = 68; + private static final int METHODID_LIST_PLUGGABLE_DATABASES = 69; + private static final int METHODID_GET_PLUGGABLE_DATABASE = 70; + private static final int METHODID_LIST_DB_SYSTEMS = 71; + private static final int METHODID_GET_DB_SYSTEM = 72; + private static final int METHODID_CREATE_DB_SYSTEM = 73; + private static final int METHODID_UPDATE_DB_SYSTEM = 74; + private static final int METHODID_DELETE_DB_SYSTEM = 75; + private static final int METHODID_LIST_GOLDENGATE_DEPLOYMENTS = 76; + private static final int METHODID_GET_GOLDENGATE_DEPLOYMENT = 77; + private static final int METHODID_CREATE_GOLDENGATE_DEPLOYMENT = 78; + private static final int METHODID_UPDATE_GOLDENGATE_DEPLOYMENT = 79; + private static final int METHODID_DELETE_GOLDENGATE_DEPLOYMENT = 80; + private static final int METHODID_STOP_GOLDENGATE_DEPLOYMENT = 81; + private static final int METHODID_START_GOLDENGATE_DEPLOYMENT = 82; + private static final int METHODID_LIST_GOLDENGATE_CONNECTIONS = 83; + private static final int METHODID_GET_GOLDENGATE_CONNECTION = 84; + private static final int METHODID_CREATE_GOLDENGATE_CONNECTION = 85; + private static final int METHODID_UPDATE_GOLDENGATE_CONNECTION = 86; + private static final int METHODID_DELETE_GOLDENGATE_CONNECTION = 87; + private static final int METHODID_LIST_GOLDENGATE_DEPLOYMENT_VERSIONS = 88; + private static final int METHODID_LIST_GOLDENGATE_DEPLOYMENT_TYPES = 89; + private static final int METHODID_LIST_GOLDENGATE_DEPLOYMENT_ENVIRONMENTS = 90; + private static final int METHODID_LIST_GOLDENGATE_CONNECTION_TYPES = 91; + private static final int METHODID_LIST_DB_VERSIONS = 92; + private static final int METHODID_LIST_DATABASE_CHARACTER_SETS = 93; + private static final int METHODID_LIST_GOLDENGATE_CONNECTION_ASSIGNMENTS = 94; + private static final int METHODID_GET_GOLDENGATE_CONNECTION_ASSIGNMENT = 95; + private static final int METHODID_CREATE_GOLDENGATE_CONNECTION_ASSIGNMENT = 96; + private static final int METHODID_UPDATE_GOLDENGATE_CONNECTION_ASSIGNMENT = 97; + private static final int METHODID_DELETE_GOLDENGATE_CONNECTION_ASSIGNMENT = 98; + private static final int METHODID_TEST_GOLDENGATE_CONNECTION_ASSIGNMENT = 99; + private static final int METHODID_LIST_DATABASE_CONNECTIONS = 100; + private static final int METHODID_GET_DATABASE_CONNECTION = 101; + private static final int METHODID_CREATE_DATABASE_CONNECTION = 102; + private static final int METHODID_UPDATE_DATABASE_CONNECTION = 103; + private static final int METHODID_DELETE_DATABASE_CONNECTION = 104; + private static final int METHODID_TEST_DATABASE_CONNECTION = 105; + private static final int METHODID_EXECUTE_SQL = 106; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -13858,6 +13975,11 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (com.google.cloud.oracledatabase.v1.CreateOdbDnsZoneRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_UPDATE_ODB_DNS_ZONE: + serviceImpl.updateOdbDnsZone( + (com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; case METHODID_DELETE_ODB_DNS_ZONE: serviceImpl.deleteOdbDnsZone( (com.google.cloud.oracledatabase.v1.DeleteOdbDnsZoneRequest) request, @@ -14562,6 +14684,12 @@ public static final io.grpc.ServerServiceDefinition bindService(AsyncService ser new MethodHandlers< com.google.cloud.oracledatabase.v1.CreateOdbDnsZoneRequest, com.google.longrunning.Operation>(service, METHODID_CREATE_ODB_DNS_ZONE))) + .addMethod( + getUpdateOdbDnsZoneMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest, + com.google.longrunning.Operation>(service, METHODID_UPDATE_ODB_DNS_ZONE))) .addMethod( getDeleteOdbDnsZoneMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( @@ -15035,6 +15163,7 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getListOdbDnsZonesMethod()) .addMethod(getGetOdbDnsZoneMethod()) .addMethod(getCreateOdbDnsZoneMethod()) + .addMethod(getUpdateOdbDnsZoneMethod()) .addMethod(getDeleteOdbDnsZoneMethod()) .addMethod(getListExadbVmClustersMethod()) .addMethod(getGetExadbVmClusterMethod()) diff --git a/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/OdbDnsZoneProto.java b/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/OdbDnsZoneProto.java index 8417a076dd16..f8223e5836e2 100644 --- a/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/OdbDnsZoneProto.java +++ b/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/OdbDnsZoneProto.java @@ -68,6 +68,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_oracledatabase_v1_GetOdbDnsZoneRequest_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_oracledatabase_v1_GetOdbDnsZoneRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_oracledatabase_v1_UpdateOdbDnsZoneRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_oracledatabase_v1_UpdateOdbDnsZoneRequest_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -80,15 +84,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "\n" + "1google/cloud/oracledatabase/v1/odb_dns_zone.proto\022\036google.cloud.oracledatabase" + ".v1\032\037google/api/field_behavior.proto\032\033go" - + "ogle/api/field_info.proto\032\031google/api/re" - + "source.proto\032\037google/protobuf/timestamp.proto\"\306\004\n\n" + + "ogle/api/field_info.proto\032\031google/api/resource.proto\032" + + " google/protobuf/field_mask.proto\032\037google/protobuf/timestamp.proto\"\306\004\n\n" + "OdbDnsZone\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\025\n" + "\006domain\030\002 \001(\tB\005\342A\002\002\005\022L\n" - + "\006labels\030\003 \003(\0132" - + "6.google.cloud.oracledatabase.v1.OdbDnsZone.LabelsEntryB\004\342A\001\001\022E\n" - + "\005state\030\004 \001(\01620.g" - + "oogle.cloud.oracledatabase.v1.OdbDnsZone.StateB\004\342A\001\003\0225\n" + + "\006labels\030\003 \003(\01326.goog" + + "le.cloud.oracledatabase.v1.OdbDnsZone.LabelsEntryB\004\342A\001\001\022E\n" + + "\005state\030\004 \001(\01620.google." + + "cloud.oracledatabase.v1.OdbDnsZone.StateB\004\342A\001\003\0225\n" + "\013create_time\030\005" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\032-\n" + "\013LabelsEntry\022\013\n" @@ -96,18 +100,19 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005value\030\002 \001(\t:\0028\001\"j\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\020\n" - + "\014PROVISIONING\020\001\022\r\n" + + "\014PROVISIONING\020\001\022\r" + + "\n" + "\tAVAILABLE\020\002\022\014\n" + "\010INACTIVE\020\003\022\017\n" + "\013TERMINATING\020\004\022\n\n" + "\006FAILED\020\005:\245\001\352A\241\001\n" - + "(oracledatabase.googleapis.com/OdbDnsZone\022\\project" - + "s/{project}/locations/{location}/odbNetw" - + "orks/{odb_network}/odbDnsZones/{odb_dns_zone}*\013odbDnsZones2\n" + + "(oracledatabase.googleapis.com/OdbDnsZone\022\\projects/{pro" + + "ject}/locations/{location}/odbNetworks/{" + + "odb_network}/odbDnsZones/{odb_dns_zone}*\013odbDnsZones2\n" + "odbDnsZone\"\345\001\n" + "\027CreateOdbDnsZoneRequest\022A\n" - + "\006parent\030\001 \001(\tB1\342A\001\002" - + "\372A*\022(oracledatabase.googleapis.com/OdbDnsZone\022\035\n" + + "\006parent\030\001 \001(\tB1\342A\001\002\372A*\022(o" + + "racledatabase.googleapis.com/OdbDnsZone\022\035\n" + "\017odb_dns_zone_id\030\002 \001(\tB\004\342A\001\002\022F\n" + "\014odb_dns_zone\030\003" + " \001(\0132*.google.cloud.oracledatabase.v1.OdbDnsZoneB\004\342A\001\002\022 \n\n" @@ -118,8 +123,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "request_id\030\002 \001(" + "\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"\274\001\n" + "\026ListOdbDnsZonesRequest\022A\n" - + "\006parent\030\001 \001(\tB1\342A\001\002\372A*" - + "\022(oracledatabase.googleapis.com/OdbDnsZone\022\027\n" + + "\006parent\030\001 \001(" + + "\tB1\342A\001\002\372A*\022(oracledatabase.googleapis.com/OdbDnsZone\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\022\026\n" @@ -130,12 +135,19 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013unreachable\030\003 \003(\t\"W\n" + "\024GetOdbDnsZoneRequest\022?\n" + "\004name\030\001 \001(\tB1\342A\001\002\372A*\n" - + "(oracledatabase.googleapis.com/OdbDnsZoneB\351\001\n" - + "\"com.google.cloud.oracledatabase.v1B\017OdbDnsZoneProtoP\001ZJcloud.googl" - + "e.com/go/oracledatabase/apiv1/oracledata" - + "basepb;oracledatabasepb\252\002\036Google.Cloud.O" - + "racleDatabase.V1\312\002\036Google\\Cloud\\OracleDa" - + "tabase\\V1\352\002!Google::Cloud::OracleDatabase::V1b\006proto3" + + "(oracledatabase.googleapis.com/OdbDnsZone\"\272\001\n" + + "\027UpdateOdbDnsZoneRequest\0225\n" + + "\013update_mask\030\001" + + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022F\n" + + "\014odb_dns_zone\030\002" + + " \001(\0132*.google.cloud.oracledatabase.v1.OdbDnsZoneB\004\342A\001\002\022 \n\n" + + "request_id\030\003 \001(" + + "\tB\014\342A\001\001\342\214\317\327\010\002\010\001B\351\001\n" + + "\"com.google.cloud.oracledatabase.v1B\017OdbDnsZ" + + "oneProtoP\001ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledata" + + "basepb\252\002\036Google.Cloud.OracleDatabase.V1\312" + + "\002\036Google\\Cloud\\OracleDatabase\\V1\352\002!Googl" + + "e::Cloud::OracleDatabase::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -144,6 +156,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.FieldBehaviorProto.getDescriptor(), com.google.api.FieldInfoProto.getDescriptor(), com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.FieldMaskProto.getDescriptor(), com.google.protobuf.TimestampProto.getDescriptor(), }); internal_static_google_cloud_oracledatabase_v1_OdbDnsZone_descriptor = @@ -202,10 +215,19 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Name", }); + internal_static_google_cloud_oracledatabase_v1_UpdateOdbDnsZoneRequest_descriptor = + getDescriptor().getMessageType(6); + internal_static_google_cloud_oracledatabase_v1_UpdateOdbDnsZoneRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_oracledatabase_v1_UpdateOdbDnsZoneRequest_descriptor, + new java.lang.String[] { + "UpdateMask", "OdbDnsZone", "RequestId", + }); descriptor.resolveAllFeaturesImmutable(); com.google.api.FieldBehaviorProto.getDescriptor(); com.google.api.FieldInfoProto.getDescriptor(); com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.FieldMaskProto.getDescriptor(); com.google.protobuf.TimestampProto.getDescriptor(); com.google.protobuf.ExtensionRegistry registry = com.google.protobuf.ExtensionRegistry.newInstance(); diff --git a/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/UpdateOdbDnsZoneRequest.java b/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/UpdateOdbDnsZoneRequest.java new file mode 100644 index 000000000000..28693b4af65e --- /dev/null +++ b/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/UpdateOdbDnsZoneRequest.java @@ -0,0 +1,1374 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/oracledatabase/v1/odb_dns_zone.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.oracledatabase.v1; + +/** + * + * + *
    + * The request for `OdbDnsZone.Update`.
    + * 
    + * + * Protobuf type {@code google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest} + */ +@com.google.protobuf.Generated +public final class UpdateOdbDnsZoneRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest) + UpdateOdbDnsZoneRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "UpdateOdbDnsZoneRequest"); + } + + // Use UpdateOdbDnsZoneRequest.newBuilder() to construct. + private UpdateOdbDnsZoneRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private UpdateOdbDnsZoneRequest() { + requestId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.oracledatabase.v1.OdbDnsZoneProto + .internal_static_google_cloud_oracledatabase_v1_UpdateOdbDnsZoneRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.oracledatabase.v1.OdbDnsZoneProto + .internal_static_google_cloud_oracledatabase_v1_UpdateOdbDnsZoneRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest.class, + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest.Builder.class); + } + + private int bitField0_; + public static final int UPDATE_MASK_FIELD_NUMBER = 1; + private com.google.protobuf.FieldMask updateMask_; + + /** + * + * + *
    +   * Optional. A mask specifying which fields in the OdbDnsZone should be
    +   * updated. A field specified in the mask is updated. If a mask isn't
    +   * provided, the service treats this as an implied field mask equivalent to
    +   * all fields that are populated (have a non-empty value). To clear or unset a
    +   * field, the field must be explicitly specified in the `update_mask`.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +   * Optional. A mask specifying which fields in the OdbDnsZone should be
    +   * updated. A field specified in the mask is updated. If a mask isn't
    +   * provided, the service treats this as an implied field mask equivalent to
    +   * all fields that are populated (have a non-empty value). To clear or unset a
    +   * field, the field must be explicitly specified in the `update_mask`.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + /** + * + * + *
    +   * Optional. A mask specifying which fields in the OdbDnsZone should be
    +   * updated. A field specified in the mask is updated. If a mask isn't
    +   * provided, the service treats this as an implied field mask equivalent to
    +   * all fields that are populated (have a non-empty value). To clear or unset a
    +   * field, the field must be explicitly specified in the `update_mask`.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + public static final int ODB_DNS_ZONE_FIELD_NUMBER = 2; + private com.google.cloud.oracledatabase.v1.OdbDnsZone odbDnsZone_; + + /** + * + * + *
    +   * Required. The resource being updated. Note only labels can be updated.
    +   * The provided labels will completely replace the existing labels.
    +   * Any existing label keys that are not included in the update request will be
    +   * deleted. Not providing labels and update_mask will not update the labels.
    +   * To clear all labels, specify `labels` in the `update_mask` and omit or
    +   * leave the `labels` field empty in the update request.
    +   * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the odbDnsZone field is set. + */ + @java.lang.Override + public boolean hasOdbDnsZone() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
    +   * Required. The resource being updated. Note only labels can be updated.
    +   * The provided labels will completely replace the existing labels.
    +   * Any existing label keys that are not included in the update request will be
    +   * deleted. Not providing labels and update_mask will not update the labels.
    +   * To clear all labels, specify `labels` in the `update_mask` and omit or
    +   * leave the `labels` field empty in the update request.
    +   * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The odbDnsZone. + */ + @java.lang.Override + public com.google.cloud.oracledatabase.v1.OdbDnsZone getOdbDnsZone() { + return odbDnsZone_ == null + ? com.google.cloud.oracledatabase.v1.OdbDnsZone.getDefaultInstance() + : odbDnsZone_; + } + + /** + * + * + *
    +   * Required. The resource being updated. Note only labels can be updated.
    +   * The provided labels will completely replace the existing labels.
    +   * Any existing label keys that are not included in the update request will be
    +   * deleted. Not providing labels and update_mask will not update the labels.
    +   * To clear all labels, specify `labels` in the `update_mask` and omit or
    +   * leave the `labels` field empty in the update request.
    +   * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.oracledatabase.v1.OdbDnsZoneOrBuilder getOdbDnsZoneOrBuilder() { + return odbDnsZone_ == null + ? com.google.cloud.oracledatabase.v1.OdbDnsZone.getDefaultInstance() + : odbDnsZone_; + } + + public static final int REQUEST_ID_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object requestId_ = ""; + + /** + * + * + *
    +   * Optional. An optional ID to identify the request. This value is used to
    +   * identify duplicate requests. If you make a request with the same request ID
    +   * and the original request is still in progress or completed, the server
    +   * ignores the second request. This prevents clients from
    +   * accidentally creating duplicate commitments.
    +   *
    +   * The request ID must be a valid UUID with the exception that zero UUID is
    +   * not supported (00000000-0000-0000-0000-000000000000).
    +   * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + @java.lang.Override + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } + } + + /** + * + * + *
    +   * Optional. An optional ID to identify the request. This value is used to
    +   * identify duplicate requests. If you make a request with the same request ID
    +   * and the original request is still in progress or completed, the server
    +   * ignores the second request. This prevents clients from
    +   * accidentally creating duplicate commitments.
    +   *
    +   * The request ID must be a valid UUID with the exception that zero UUID is
    +   * not supported (00000000-0000-0000-0000-000000000000).
    +   * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getUpdateMask()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getOdbDnsZone()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, requestId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getUpdateMask()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getOdbDnsZone()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(requestId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, requestId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest)) { + return super.equals(obj); + } + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest other = + (com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest) obj; + + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (hasOdbDnsZone() != other.hasOdbDnsZone()) return false; + if (hasOdbDnsZone()) { + if (!getOdbDnsZone().equals(other.getOdbDnsZone())) return false; + } + if (!getRequestId().equals(other.getRequestId())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + if (hasOdbDnsZone()) { + hash = (37 * hash) + ODB_DNS_ZONE_FIELD_NUMBER; + hash = (53 * hash) + getOdbDnsZone().hashCode(); + } + hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER; + hash = (53 * hash) + getRequestId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * The request for `OdbDnsZone.Update`.
    +   * 
    + * + * Protobuf type {@code google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest) + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.oracledatabase.v1.OdbDnsZoneProto + .internal_static_google_cloud_oracledatabase_v1_UpdateOdbDnsZoneRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.oracledatabase.v1.OdbDnsZoneProto + .internal_static_google_cloud_oracledatabase_v1_UpdateOdbDnsZoneRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest.class, + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest.Builder.class); + } + + // Construct using com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetUpdateMaskFieldBuilder(); + internalGetOdbDnsZoneFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + odbDnsZone_ = null; + if (odbDnsZoneBuilder_ != null) { + odbDnsZoneBuilder_.dispose(); + odbDnsZoneBuilder_ = null; + } + requestId_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.oracledatabase.v1.OdbDnsZoneProto + .internal_static_google_cloud_oracledatabase_v1_UpdateOdbDnsZoneRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest getDefaultInstanceForType() { + return com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest build() { + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest buildPartial() { + com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest result = + new com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.updateMask_ = updateMaskBuilder_ == null ? updateMask_ : updateMaskBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.odbDnsZone_ = odbDnsZoneBuilder_ == null ? odbDnsZone_ : odbDnsZoneBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.requestId_ = requestId_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest) { + return mergeFrom((com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest other) { + if (other == com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest.getDefaultInstance()) + return this; + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + if (other.hasOdbDnsZone()) { + mergeOdbDnsZone(other.getOdbDnsZone()); + } + if (!other.getRequestId().isEmpty()) { + requestId_ = other.requestId_; + bitField0_ |= 0x00000004; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage( + internalGetOdbDnsZoneFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + requestId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + + /** + * + * + *
    +     * Optional. A mask specifying which fields in the OdbDnsZone should be
    +     * updated. A field specified in the mask is updated. If a mask isn't
    +     * provided, the service treats this as an implied field mask equivalent to
    +     * all fields that are populated (have a non-empty value). To clear or unset a
    +     * field, the field must be explicitly specified in the `update_mask`.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +     * Optional. A mask specifying which fields in the OdbDnsZone should be
    +     * updated. A field specified in the mask is updated. If a mask isn't
    +     * provided, the service treats this as an implied field mask equivalent to
    +     * all fields that are populated (have a non-empty value). To clear or unset a
    +     * field, the field must be explicitly specified in the `update_mask`.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Optional. A mask specifying which fields in the OdbDnsZone should be
    +     * updated. A field specified in the mask is updated. If a mask isn't
    +     * provided, the service treats this as an implied field mask equivalent to
    +     * all fields that are populated (have a non-empty value). To clear or unset a
    +     * field, the field must be explicitly specified in the `update_mask`.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + } else { + updateMaskBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. A mask specifying which fields in the OdbDnsZone should be
    +     * updated. A field specified in the mask is updated. If a mask isn't
    +     * provided, the service treats this as an implied field mask equivalent to
    +     * all fields that are populated (have a non-empty value). To clear or unset a
    +     * field, the field must be explicitly specified in the `update_mask`.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. A mask specifying which fields in the OdbDnsZone should be
    +     * updated. A field specified in the mask is updated. If a mask isn't
    +     * provided, the service treats this as an implied field mask equivalent to
    +     * all fields that are populated (have a non-empty value). To clear or unset a
    +     * field, the field must be explicitly specified in the `update_mask`.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && updateMask_ != null + && updateMask_ != com.google.protobuf.FieldMask.getDefaultInstance()) { + getUpdateMaskBuilder().mergeFrom(value); + } else { + updateMask_ = value; + } + } else { + updateMaskBuilder_.mergeFrom(value); + } + if (updateMask_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Optional. A mask specifying which fields in the OdbDnsZone should be
    +     * updated. A field specified in the mask is updated. If a mask isn't
    +     * provided, the service treats this as an implied field mask equivalent to
    +     * all fields that are populated (have a non-empty value). To clear or unset a
    +     * field, the field must be explicitly specified in the `update_mask`.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearUpdateMask() { + bitField0_ = (bitField0_ & ~0x00000001); + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. A mask specifying which fields in the OdbDnsZone should be
    +     * updated. A field specified in the mask is updated. If a mask isn't
    +     * provided, the service treats this as an implied field mask equivalent to
    +     * all fields that are populated (have a non-empty value). To clear or unset a
    +     * field, the field must be explicitly specified in the `update_mask`.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetUpdateMaskFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Optional. A mask specifying which fields in the OdbDnsZone should be
    +     * updated. A field specified in the mask is updated. If a mask isn't
    +     * provided, the service treats this as an implied field mask equivalent to
    +     * all fields that are populated (have a non-empty value). To clear or unset a
    +     * field, the field must be explicitly specified in the `update_mask`.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + + /** + * + * + *
    +     * Optional. A mask specifying which fields in the OdbDnsZone should be
    +     * updated. A field specified in the mask is updated. If a mask isn't
    +     * provided, the service treats this as an implied field mask equivalent to
    +     * all fields that are populated (have a non-empty value). To clear or unset a
    +     * field, the field must be explicitly specified in the `update_mask`.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + internalGetUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + private com.google.cloud.oracledatabase.v1.OdbDnsZone odbDnsZone_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.oracledatabase.v1.OdbDnsZone, + com.google.cloud.oracledatabase.v1.OdbDnsZone.Builder, + com.google.cloud.oracledatabase.v1.OdbDnsZoneOrBuilder> + odbDnsZoneBuilder_; + + /** + * + * + *
    +     * Required. The resource being updated. Note only labels can be updated.
    +     * The provided labels will completely replace the existing labels.
    +     * Any existing label keys that are not included in the update request will be
    +     * deleted. Not providing labels and update_mask will not update the labels.
    +     * To clear all labels, specify `labels` in the `update_mask` and omit or
    +     * leave the `labels` field empty in the update request.
    +     * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the odbDnsZone field is set. + */ + public boolean hasOdbDnsZone() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
    +     * Required. The resource being updated. Note only labels can be updated.
    +     * The provided labels will completely replace the existing labels.
    +     * Any existing label keys that are not included in the update request will be
    +     * deleted. Not providing labels and update_mask will not update the labels.
    +     * To clear all labels, specify `labels` in the `update_mask` and omit or
    +     * leave the `labels` field empty in the update request.
    +     * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The odbDnsZone. + */ + public com.google.cloud.oracledatabase.v1.OdbDnsZone getOdbDnsZone() { + if (odbDnsZoneBuilder_ == null) { + return odbDnsZone_ == null + ? com.google.cloud.oracledatabase.v1.OdbDnsZone.getDefaultInstance() + : odbDnsZone_; + } else { + return odbDnsZoneBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Required. The resource being updated. Note only labels can be updated.
    +     * The provided labels will completely replace the existing labels.
    +     * Any existing label keys that are not included in the update request will be
    +     * deleted. Not providing labels and update_mask will not update the labels.
    +     * To clear all labels, specify `labels` in the `update_mask` and omit or
    +     * leave the `labels` field empty in the update request.
    +     * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setOdbDnsZone(com.google.cloud.oracledatabase.v1.OdbDnsZone value) { + if (odbDnsZoneBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + odbDnsZone_ = value; + } else { + odbDnsZoneBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource being updated. Note only labels can be updated.
    +     * The provided labels will completely replace the existing labels.
    +     * Any existing label keys that are not included in the update request will be
    +     * deleted. Not providing labels and update_mask will not update the labels.
    +     * To clear all labels, specify `labels` in the `update_mask` and omit or
    +     * leave the `labels` field empty in the update request.
    +     * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setOdbDnsZone( + com.google.cloud.oracledatabase.v1.OdbDnsZone.Builder builderForValue) { + if (odbDnsZoneBuilder_ == null) { + odbDnsZone_ = builderForValue.build(); + } else { + odbDnsZoneBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource being updated. Note only labels can be updated.
    +     * The provided labels will completely replace the existing labels.
    +     * Any existing label keys that are not included in the update request will be
    +     * deleted. Not providing labels and update_mask will not update the labels.
    +     * To clear all labels, specify `labels` in the `update_mask` and omit or
    +     * leave the `labels` field empty in the update request.
    +     * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeOdbDnsZone(com.google.cloud.oracledatabase.v1.OdbDnsZone value) { + if (odbDnsZoneBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && odbDnsZone_ != null + && odbDnsZone_ != com.google.cloud.oracledatabase.v1.OdbDnsZone.getDefaultInstance()) { + getOdbDnsZoneBuilder().mergeFrom(value); + } else { + odbDnsZone_ = value; + } + } else { + odbDnsZoneBuilder_.mergeFrom(value); + } + if (odbDnsZone_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Required. The resource being updated. Note only labels can be updated.
    +     * The provided labels will completely replace the existing labels.
    +     * Any existing label keys that are not included in the update request will be
    +     * deleted. Not providing labels and update_mask will not update the labels.
    +     * To clear all labels, specify `labels` in the `update_mask` and omit or
    +     * leave the `labels` field empty in the update request.
    +     * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearOdbDnsZone() { + bitField0_ = (bitField0_ & ~0x00000002); + odbDnsZone_ = null; + if (odbDnsZoneBuilder_ != null) { + odbDnsZoneBuilder_.dispose(); + odbDnsZoneBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource being updated. Note only labels can be updated.
    +     * The provided labels will completely replace the existing labels.
    +     * Any existing label keys that are not included in the update request will be
    +     * deleted. Not providing labels and update_mask will not update the labels.
    +     * To clear all labels, specify `labels` in the `update_mask` and omit or
    +     * leave the `labels` field empty in the update request.
    +     * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.oracledatabase.v1.OdbDnsZone.Builder getOdbDnsZoneBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetOdbDnsZoneFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Required. The resource being updated. Note only labels can be updated.
    +     * The provided labels will completely replace the existing labels.
    +     * Any existing label keys that are not included in the update request will be
    +     * deleted. Not providing labels and update_mask will not update the labels.
    +     * To clear all labels, specify `labels` in the `update_mask` and omit or
    +     * leave the `labels` field empty in the update request.
    +     * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.oracledatabase.v1.OdbDnsZoneOrBuilder getOdbDnsZoneOrBuilder() { + if (odbDnsZoneBuilder_ != null) { + return odbDnsZoneBuilder_.getMessageOrBuilder(); + } else { + return odbDnsZone_ == null + ? com.google.cloud.oracledatabase.v1.OdbDnsZone.getDefaultInstance() + : odbDnsZone_; + } + } + + /** + * + * + *
    +     * Required. The resource being updated. Note only labels can be updated.
    +     * The provided labels will completely replace the existing labels.
    +     * Any existing label keys that are not included in the update request will be
    +     * deleted. Not providing labels and update_mask will not update the labels.
    +     * To clear all labels, specify `labels` in the `update_mask` and omit or
    +     * leave the `labels` field empty in the update request.
    +     * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.oracledatabase.v1.OdbDnsZone, + com.google.cloud.oracledatabase.v1.OdbDnsZone.Builder, + com.google.cloud.oracledatabase.v1.OdbDnsZoneOrBuilder> + internalGetOdbDnsZoneFieldBuilder() { + if (odbDnsZoneBuilder_ == null) { + odbDnsZoneBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.oracledatabase.v1.OdbDnsZone, + com.google.cloud.oracledatabase.v1.OdbDnsZone.Builder, + com.google.cloud.oracledatabase.v1.OdbDnsZoneOrBuilder>( + getOdbDnsZone(), getParentForChildren(), isClean()); + odbDnsZone_ = null; + } + return odbDnsZoneBuilder_; + } + + private java.lang.Object requestId_ = ""; + + /** + * + * + *
    +     * Optional. An optional ID to identify the request. This value is used to
    +     * identify duplicate requests. If you make a request with the same request ID
    +     * and the original request is still in progress or completed, the server
    +     * ignores the second request. This prevents clients from
    +     * accidentally creating duplicate commitments.
    +     *
    +     * The request ID must be a valid UUID with the exception that zero UUID is
    +     * not supported (00000000-0000-0000-0000-000000000000).
    +     * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + public java.lang.String getRequestId() { + java.lang.Object ref = requestId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + requestId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Optional. An optional ID to identify the request. This value is used to
    +     * identify duplicate requests. If you make a request with the same request ID
    +     * and the original request is still in progress or completed, the server
    +     * ignores the second request. This prevents clients from
    +     * accidentally creating duplicate commitments.
    +     *
    +     * The request ID must be a valid UUID with the exception that zero UUID is
    +     * not supported (00000000-0000-0000-0000-000000000000).
    +     * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + public com.google.protobuf.ByteString getRequestIdBytes() { + java.lang.Object ref = requestId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + requestId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Optional. An optional ID to identify the request. This value is used to
    +     * identify duplicate requests. If you make a request with the same request ID
    +     * and the original request is still in progress or completed, the server
    +     * ignores the second request. This prevents clients from
    +     * accidentally creating duplicate commitments.
    +     *
    +     * The request ID must be a valid UUID with the exception that zero UUID is
    +     * not supported (00000000-0000-0000-0000-000000000000).
    +     * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + requestId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. An optional ID to identify the request. This value is used to
    +     * identify duplicate requests. If you make a request with the same request ID
    +     * and the original request is still in progress or completed, the server
    +     * ignores the second request. This prevents clients from
    +     * accidentally creating duplicate commitments.
    +     *
    +     * The request ID must be a valid UUID with the exception that zero UUID is
    +     * not supported (00000000-0000-0000-0000-000000000000).
    +     * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearRequestId() { + requestId_ = getDefaultInstance().getRequestId(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. An optional ID to identify the request. This value is used to
    +     * identify duplicate requests. If you make a request with the same request ID
    +     * and the original request is still in progress or completed, the server
    +     * ignores the second request. This prevents clients from
    +     * accidentally creating duplicate commitments.
    +     *
    +     * The request ID must be a valid UUID with the exception that zero UUID is
    +     * not supported (00000000-0000-0000-0000-000000000000).
    +     * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @param value The bytes for requestId to set. + * @return This builder for chaining. + */ + public Builder setRequestIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + requestId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest) + private static final com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest(); + } + + public static com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateOdbDnsZoneRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/UpdateOdbDnsZoneRequestOrBuilder.java b/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/UpdateOdbDnsZoneRequestOrBuilder.java new file mode 100644 index 000000000000..c61ef23cb421 --- /dev/null +++ b/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/UpdateOdbDnsZoneRequestOrBuilder.java @@ -0,0 +1,182 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/oracledatabase/v1/odb_dns_zone.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.oracledatabase.v1; + +@com.google.protobuf.Generated +public interface UpdateOdbDnsZoneRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * Optional. A mask specifying which fields in the OdbDnsZone should be
    +   * updated. A field specified in the mask is updated. If a mask isn't
    +   * provided, the service treats this as an implied field mask equivalent to
    +   * all fields that are populated (have a non-empty value). To clear or unset a
    +   * field, the field must be explicitly specified in the `update_mask`.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + + /** + * + * + *
    +   * Optional. A mask specifying which fields in the OdbDnsZone should be
    +   * updated. A field specified in the mask is updated. If a mask isn't
    +   * provided, the service treats this as an implied field mask equivalent to
    +   * all fields that are populated (have a non-empty value). To clear or unset a
    +   * field, the field must be explicitly specified in the `update_mask`.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + + /** + * + * + *
    +   * Optional. A mask specifying which fields in the OdbDnsZone should be
    +   * updated. A field specified in the mask is updated. If a mask isn't
    +   * provided, the service treats this as an implied field mask equivalent to
    +   * all fields that are populated (have a non-empty value). To clear or unset a
    +   * field, the field must be explicitly specified in the `update_mask`.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); + + /** + * + * + *
    +   * Required. The resource being updated. Note only labels can be updated.
    +   * The provided labels will completely replace the existing labels.
    +   * Any existing label keys that are not included in the update request will be
    +   * deleted. Not providing labels and update_mask will not update the labels.
    +   * To clear all labels, specify `labels` in the `update_mask` and omit or
    +   * leave the `labels` field empty in the update request.
    +   * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the odbDnsZone field is set. + */ + boolean hasOdbDnsZone(); + + /** + * + * + *
    +   * Required. The resource being updated. Note only labels can be updated.
    +   * The provided labels will completely replace the existing labels.
    +   * Any existing label keys that are not included in the update request will be
    +   * deleted. Not providing labels and update_mask will not update the labels.
    +   * To clear all labels, specify `labels` in the `update_mask` and omit or
    +   * leave the `labels` field empty in the update request.
    +   * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The odbDnsZone. + */ + com.google.cloud.oracledatabase.v1.OdbDnsZone getOdbDnsZone(); + + /** + * + * + *
    +   * Required. The resource being updated. Note only labels can be updated.
    +   * The provided labels will completely replace the existing labels.
    +   * Any existing label keys that are not included in the update request will be
    +   * deleted. Not providing labels and update_mask will not update the labels.
    +   * To clear all labels, specify `labels` in the `update_mask` and omit or
    +   * leave the `labels` field empty in the update request.
    +   * 
    + * + * + * .google.cloud.oracledatabase.v1.OdbDnsZone odb_dns_zone = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.oracledatabase.v1.OdbDnsZoneOrBuilder getOdbDnsZoneOrBuilder(); + + /** + * + * + *
    +   * Optional. An optional ID to identify the request. This value is used to
    +   * identify duplicate requests. If you make a request with the same request ID
    +   * and the original request is still in progress or completed, the server
    +   * ignores the second request. This prevents clients from
    +   * accidentally creating duplicate commitments.
    +   *
    +   * The request ID must be a valid UUID with the exception that zero UUID is
    +   * not supported (00000000-0000-0000-0000-000000000000).
    +   * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The requestId. + */ + java.lang.String getRequestId(); + + /** + * + * + *
    +   * Optional. An optional ID to identify the request. This value is used to
    +   * identify duplicate requests. If you make a request with the same request ID
    +   * and the original request is still in progress or completed, the server
    +   * ignores the second request. This prevents clients from
    +   * accidentally creating duplicate commitments.
    +   *
    +   * The request ID must be a valid UUID with the exception that zero UUID is
    +   * not supported (00000000-0000-0000-0000-000000000000).
    +   * 
    + * + * + * string request_id = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { ... } + * + * + * @return The bytes for requestId. + */ + com.google.protobuf.ByteString getRequestIdBytes(); +} diff --git a/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/V1mainProto.java b/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/V1mainProto.java index 46a5ec6f1340..e4dbb77743a9 100644 --- a/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/V1mainProto.java +++ b/java-oracledatabase/proto-google-cloud-oracledatabase-v1/src/main/java/com/google/cloud/oracledatabase/v1/V1mainProto.java @@ -595,7 +595,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + ",oracledatabase.googleapis.com/CloudVmCluster\"t\n" + "-DisableExadbVmClusterIdentityConnectorRequest\022C\n" + "\004name\030\001 \001(\tB5\342A\001\002\372A.\n" - + ",oracledatabase.googleapis.com/ExadbVmCluster2\311\323\001\n" + + ",oracledatabase.googleapis.com/ExadbVmCluster2\326\325\001\n" + "\016OracleDatabase\022\204\002\n" + "\037ListCloudExadataInfrastructures\022F.google." + "cloud.oracledatabase.v1.ListCloudExadataInfrastructuresRequest\032G.google.cloud.or" @@ -901,375 +901,382 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "tionMetadata\332A#parent,odb_dns_zone,odb_d" + "ns_zone_id\202\323\344\223\002M\"=/v1/{parent=projects/*" + "/locations/*/odbNetworks/*}/odbDnsZones:" - + "\014odb_dns_zone\022\345\001\n\020DeleteOdbDnsZone\0227.goo" - + "gle.cloud.oracledatabase.v1.DeleteOdbDns" + + "\014odb_dns_zone\022\212\002\n\020UpdateOdbDnsZone\0227.goo" + + "gle.cloud.oracledatabase.v1.UpdateOdbDns" + "ZoneRequest\032\035.google.longrunning.Operati" - + "on\"y\312A*\n\025google.protobuf.Empty\022\021Operatio" - + "nMetadata\332A\004name\202\323\344\223\002?*=/v1/{name=projec" - + "ts/*/locations/*/odbNetworks/*/odbDnsZon" - + "es/*}\022\324\001\n\023ListExadbVmClusters\022:.google.c" - + "loud.oracledatabase.v1.ListExadbVmCluste" - + "rsRequest\032;.google.cloud.oracledatabase." - + "v1.ListExadbVmClustersResponse\"D\332A\006paren" - + "t\202\323\344\223\0025\0223/v1/{parent=projects/*/location" - + "s/*}/exadbVmClusters\022\301\001\n\021GetExadbVmClust" - + "er\0228.google.cloud.oracledatabase.v1.GetE" - + "xadbVmClusterRequest\032..google.cloud.orac" - + "ledatabase.v1.ExadbVmCluster\"B\332A\004name\202\323\344" - + "\223\0025\0223/v1/{name=projects/*/locations/*/ex" - + "adbVmClusters/*}\022\226\002\n\024CreateExadbVmCluste" - + "r\022;.google.cloud.oracledatabase.v1.Creat" - + "eExadbVmClusterRequest\032\035.google.longrunn" - + "ing.Operation\"\241\001\312A#\n\016ExadbVmCluster\022\021Ope" - + "rationMetadata\332A+parent,exadb_vm_cluster" - + ",exadb_vm_cluster_id\202\323\344\223\002G\"3/v1/{parent=" - + "projects/*/locations/*}/exadbVmClusters:" - + "\020exadb_vm_cluster\022\343\001\n\024DeleteExadbVmClust" - + "er\022;.google.cloud.oracledatabase.v1.Dele" - + "teExadbVmClusterRequest\032\035.google.longrun" - + "ning.Operation\"o\312A*\n\025google.protobuf.Emp" - + "ty\022\021OperationMetadata\332A\004name\202\323\344\223\0025*3/v1/" - + "{name=projects/*/locations/*/exadbVmClus" - + "ters/*}\022\230\002\n\024UpdateExadbVmCluster\022;.googl" - + "e.cloud.oracledatabase.v1.UpdateExadbVmC" - + "lusterRequest\032\035.google.longrunning.Opera" - + "tion\"\243\001\312A#\n\016ExadbVmCluster\022\021OperationMet" - + "adata\332A\034exadb_vm_cluster,update_mask\202\323\344\223" - + "\002X2D/v1/{exadb_vm_cluster.name=projects/" - + "*/locations/*/exadbVmClusters/*}:\020exadb_" - + "vm_cluster\022\233\002\n\"RemoveVirtualMachineExadb" - + "VmCluster\022I.google.cloud.oracledatabase." - + "v1.RemoveVirtualMachineExadbVmClusterReq" - + "uest\032\035.google.longrunning.Operation\"\212\001\312A" - + "#\n\016ExadbVmCluster\022\021OperationMetadata\332A\016n" - + "ame,hostnames\202\323\344\223\002M\"H/v1/{name=projects/" - + "*/locations/*/exadbVmClusters/*}:removeV" - + "irtualMachine:\001*\022\364\001\n\033ListExascaleDbStora" - + "geVaults\022B.google.cloud.oracledatabase.v" - + "1.ListExascaleDbStorageVaultsRequest\032C.g" - + "oogle.cloud.oracledatabase.v1.ListExasca" - + "leDbStorageVaultsResponse\"L\332A\006parent\202\323\344\223" - + "\002=\022;/v1/{parent=projects/*/locations/*}/" - + "exascaleDbStorageVaults\022\341\001\n\031GetExascaleD" - + "bStorageVault\022@.google.cloud.oracledatab" - + "ase.v1.GetExascaleDbStorageVaultRequest\032" - + "6.google.cloud.oracledatabase.v1.Exascal" - + "eDbStorageVault\"J\332A\004name\202\323\344\223\002=\022;/v1/{nam" - + "e=projects/*/locations/*/exascaleDbStora" - + "geVaults/*}\022\321\002\n\034CreateExascaleDbStorageV" - + "ault\022C.google.cloud.oracledatabase.v1.Cr" - + "eateExascaleDbStorageVaultRequest\032\035.goog" - + "le.longrunning.Operation\"\314\001\312A+\n\026Exascale" - + "DbStorageVault\022\021OperationMetadata\332A=pare" - + "nt,exascale_db_storage_vault,exascale_db" - + "_storage_vault_id\202\323\344\223\002X\";/v1/{parent=pro" - + "jects/*/locations/*}/exascaleDbStorageVa" - + "ults:\031exascale_db_storage_vault\022\323\002\n\034Upda" - + "teExascaleDbStorageVault\022C.google.cloud." - + "oracledatabase.v1.UpdateExascaleDbStorag" - + "eVaultRequest\032\035.google.longrunning.Opera" - + "tion\"\316\001\312A+\n\026ExascaleDbStorageVault\022\021Oper" - + "ationMetadata\332A%exascale_db_storage_vaul" - + "t,update_mask\202\323\344\223\002r2U/v1/{exascale_db_st" - + "orage_vault.name=projects/*/locations/*/" - + "exascaleDbStorageVaults/*}:\031exascale_db_" - + "storage_vault\022\373\001\n\034DeleteExascaleDbStorag" - + "eVault\022C.google.cloud.oracledatabase.v1." - + "DeleteExascaleDbStorageVaultRequest\032\035.go" - + "ogle.longrunning.Operation\"w\312A*\n\025google." - + "protobuf.Empty\022\021OperationMetadata\332A\004name" - + "\202\323\344\223\002=*;/v1/{name=projects/*/locations/*" - + "/exascaleDbStorageVaults/*}\022\204\002\n\037ListDbSy" - + "stemInitialStorageSizes\022F.google.cloud.o" - + "racledatabase.v1.ListDbSystemInitialStor" - + "ageSizesRequest\032G.google.cloud.oracledat" - + "abase.v1.ListDbSystemInitialStorageSizes" - + "Response\"P\332A\006parent\202\323\344\223\002A\022?/v1/{parent=p" - + "rojects/*/locations/*}/dbSystemInitialSt" - + "orageSizes\022\204\002\n\037ListDbSystemComputePerfor" - + "mances\022F.google.cloud.oracledatabase.v1." - + "ListDbSystemComputePerformancesRequest\032G" + + "on\"\235\001\312A\037\n\nOdbDnsZone\022\021OperationMetadata\332" + + "A\030odb_dns_zone,update_mask\202\323\344\223\002Z2J/v1/{o" + + "db_dns_zone.name=projects/*/locations/*/" + + "odbNetworks/*/odbDnsZones/*}:\014odb_dns_zo" + + "ne\022\345\001\n\020DeleteOdbDnsZone\0227.google.cloud.o" + + "racledatabase.v1.DeleteOdbDnsZoneRequest" + + "\032\035.google.longrunning.Operation\"y\312A*\n\025go" + + "ogle.protobuf.Empty\022\021OperationMetadata\332A" + + "\004name\202\323\344\223\002?*=/v1/{name=projects/*/locati" + + "ons/*/odbNetworks/*/odbDnsZones/*}\022\324\001\n\023L" + + "istExadbVmClusters\022:.google.cloud.oracle" + + "database.v1.ListExadbVmClustersRequest\032;" + + ".google.cloud.oracledatabase.v1.ListExad" + + "bVmClustersResponse\"D\332A\006parent\202\323\344\223\0025\0223/v" + + "1/{parent=projects/*/locations/*}/exadbV" + + "mClusters\022\301\001\n\021GetExadbVmCluster\0228.google" + + ".cloud.oracledatabase.v1.GetExadbVmClust" + + "erRequest\032..google.cloud.oracledatabase." + + "v1.ExadbVmCluster\"B\332A\004name\202\323\344\223\0025\0223/v1/{n" + + "ame=projects/*/locations/*/exadbVmCluste" + + "rs/*}\022\226\002\n\024CreateExadbVmCluster\022;.google." + + "cloud.oracledatabase.v1.CreateExadbVmClu" + + "sterRequest\032\035.google.longrunning.Operati" + + "on\"\241\001\312A#\n\016ExadbVmCluster\022\021OperationMetad" + + "ata\332A+parent,exadb_vm_cluster,exadb_vm_c" + + "luster_id\202\323\344\223\002G\"3/v1/{parent=projects/*/" + + "locations/*}/exadbVmClusters:\020exadb_vm_c" + + "luster\022\343\001\n\024DeleteExadbVmCluster\022;.google" + + ".cloud.oracledatabase.v1.DeleteExadbVmCl" + + "usterRequest\032\035.google.longrunning.Operat" + + "ion\"o\312A*\n\025google.protobuf.Empty\022\021Operati" + + "onMetadata\332A\004name\202\323\344\223\0025*3/v1/{name=proje" + + "cts/*/locations/*/exadbVmClusters/*}\022\230\002\n" + + "\024UpdateExadbVmCluster\022;.google.cloud.ora" + + "cledatabase.v1.UpdateExadbVmClusterReque" + + "st\032\035.google.longrunning.Operation\"\243\001\312A#\n" + + "\016ExadbVmCluster\022\021OperationMetadata\332A\034exa" + + "db_vm_cluster,update_mask\202\323\344\223\002X2D/v1/{ex" + + "adb_vm_cluster.name=projects/*/locations" + + "/*/exadbVmClusters/*}:\020exadb_vm_cluster\022" + + "\233\002\n\"RemoveVirtualMachineExadbVmCluster\022I" + + ".google.cloud.oracledatabase.v1.RemoveVi" + + "rtualMachineExadbVmClusterRequest\032\035.goog" + + "le.longrunning.Operation\"\212\001\312A#\n\016ExadbVmC" + + "luster\022\021OperationMetadata\332A\016name,hostnam" + + "es\202\323\344\223\002M\"H/v1/{name=projects/*/locations" + + "/*/exadbVmClusters/*}:removeVirtualMachi" + + "ne:\001*\022\364\001\n\033ListExascaleDbStorageVaults\022B." + + "google.cloud.oracledatabase.v1.ListExasc" + + "aleDbStorageVaultsRequest\032C.google.cloud" + + ".oracledatabase.v1.ListExascaleDbStorage" + + "VaultsResponse\"L\332A\006parent\202\323\344\223\002=\022;/v1/{pa" + + "rent=projects/*/locations/*}/exascaleDbS" + + "torageVaults\022\341\001\n\031GetExascaleDbStorageVau" + + "lt\022@.google.cloud.oracledatabase.v1.GetE" + + "xascaleDbStorageVaultRequest\0326.google.cl" + + "oud.oracledatabase.v1.ExascaleDbStorageV" + + "ault\"J\332A\004name\202\323\344\223\002=\022;/v1/{name=projects/" + + "*/locations/*/exascaleDbStorageVaults/*}" + + "\022\321\002\n\034CreateExascaleDbStorageVault\022C.goog" + + "le.cloud.oracledatabase.v1.CreateExascal" + + "eDbStorageVaultRequest\032\035.google.longrunn" + + "ing.Operation\"\314\001\312A+\n\026ExascaleDbStorageVa" + + "ult\022\021OperationMetadata\332A=parent,exascale" + + "_db_storage_vault,exascale_db_storage_va" + + "ult_id\202\323\344\223\002X\";/v1/{parent=projects/*/loc" + + "ations/*}/exascaleDbStorageVaults:\031exasc" + + "ale_db_storage_vault\022\323\002\n\034UpdateExascaleD" + + "bStorageVault\022C.google.cloud.oracledatab" + + "ase.v1.UpdateExascaleDbStorageVaultReque" + + "st\032\035.google.longrunning.Operation\"\316\001\312A+\n" + + "\026ExascaleDbStorageVault\022\021OperationMetada" + + "ta\332A%exascale_db_storage_vault,update_ma" + + "sk\202\323\344\223\002r2U/v1/{exascale_db_storage_vault" + + ".name=projects/*/locations/*/exascaleDbS" + + "torageVaults/*}:\031exascale_db_storage_vau" + + "lt\022\373\001\n\034DeleteExascaleDbStorageVault\022C.go" + + "ogle.cloud.oracledatabase.v1.DeleteExasc" + + "aleDbStorageVaultRequest\032\035.google.longru" + + "nning.Operation\"w\312A*\n\025google.protobuf.Em" + + "pty\022\021OperationMetadata\332A\004name\202\323\344\223\002=*;/v1" + + "/{name=projects/*/locations/*/exascaleDb" + + "StorageVaults/*}\022\204\002\n\037ListDbSystemInitial" + + "StorageSizes\022F.google.cloud.oracledataba" + + "se.v1.ListDbSystemInitialStorageSizesReq" + + "uest\032G.google.cloud.oracledatabase.v1.Li" + + "stDbSystemInitialStorageSizesResponse\"P\332" + + "A\006parent\202\323\344\223\002A\022?/v1/{parent=projects/*/l" + + "ocations/*}/dbSystemInitialStorageSizes\022" + + "\204\002\n\037ListDbSystemComputePerformances\022F.go" + + "ogle.cloud.oracledatabase.v1.ListDbSyste" + + "mComputePerformancesRequest\032G.google.clo" + + "ud.oracledatabase.v1.ListDbSystemCompute" + + "PerformancesResponse\"P\332A\006parent\202\323\344\223\002A\022?/" + + "v1/{parent=projects/*/locations/*}/dbSys" + + "temComputePerformances\022\274\001\n\rListDatabases" + + "\0224.google.cloud.oracledatabase.v1.ListDa" + + "tabasesRequest\0325.google.cloud.oracledata" + + "base.v1.ListDatabasesResponse\">\332A\006parent" + + "\202\323\344\223\002/\022-/v1/{parent=projects/*/locations" + + "/*}/databases\022\251\001\n\013GetDatabase\0222.google.c" + + "loud.oracledatabase.v1.GetDatabaseReques" + + "t\032(.google.cloud.oracledatabase.v1.Datab" + + "ase\"<\332A\004name\202\323\344\223\002/\022-/v1/{name=projects/*" + + "/locations/*/databases/*}\022\340\001\n\026ListPlugga" + + "bleDatabases\022=.google.cloud.oracledataba" + + "se.v1.ListPluggableDatabasesRequest\032>.go" + + "ogle.cloud.oracledatabase.v1.ListPluggab" + + "leDatabasesResponse\"G\332A\006parent\202\323\344\223\0028\0226/v" + + "1/{parent=projects/*/locations/*}/plugga" + + "bleDatabases\022\315\001\n\024GetPluggableDatabase\022;." + + "google.cloud.oracledatabase.v1.GetPlugga" + + "bleDatabaseRequest\0321.google.cloud.oracle" + + "database.v1.PluggableDatabase\"E\332A\004name\202\323" + + "\344\223\0028\0226/v1/{name=projects/*/locations/*/p" + + "luggableDatabases/*}\022\274\001\n\rListDbSystems\0224" + ".google.cloud.oracledatabase.v1.ListDbSy" - + "stemComputePerformancesResponse\"P\332A\006pare" - + "nt\202\323\344\223\002A\022?/v1/{parent=projects/*/locatio" - + "ns/*}/dbSystemComputePerformances\022\274\001\n\rLi" - + "stDatabases\0224.google.cloud.oracledatabas" - + "e.v1.ListDatabasesRequest\0325.google.cloud" - + ".oracledatabase.v1.ListDatabasesResponse" - + "\">\332A\006parent\202\323\344\223\002/\022-/v1/{parent=projects/" - + "*/locations/*}/databases\022\251\001\n\013GetDatabase" - + "\0222.google.cloud.oracledatabase.v1.GetDat" - + "abaseRequest\032(.google.cloud.oracledataba" - + "se.v1.Database\"<\332A\004name\202\323\344\223\002/\022-/v1/{name" - + "=projects/*/locations/*/databases/*}\022\340\001\n" - + "\026ListPluggableDatabases\022=.google.cloud.o" - + "racledatabase.v1.ListPluggableDatabasesR" - + "equest\032>.google.cloud.oracledatabase.v1." - + "ListPluggableDatabasesResponse\"G\332A\006paren" - + "t\202\323\344\223\0028\0226/v1/{parent=projects/*/location" - + "s/*}/pluggableDatabases\022\315\001\n\024GetPluggable" - + "Database\022;.google.cloud.oracledatabase.v" - + "1.GetPluggableDatabaseRequest\0321.google.c" - + "loud.oracledatabase.v1.PluggableDatabase" - + "\"E\332A\004name\202\323\344\223\0028\0226/v1/{name=projects/*/lo" - + "cations/*/pluggableDatabases/*}\022\274\001\n\rList" - + "DbSystems\0224.google.cloud.oracledatabase." - + "v1.ListDbSystemsRequest\0325.google.cloud.o" - + "racledatabase.v1.ListDbSystemsResponse\">" - + "\332A\006parent\202\323\344\223\002/\022-/v1/{parent=projects/*/" - + "locations/*}/dbSystems\022\251\001\n\013GetDbSystem\0222" - + ".google.cloud.oracledatabase.v1.GetDbSys" - + "temRequest\032(.google.cloud.oracledatabase" - + ".v1.DbSystem\"<\332A\004name\202\323\344\223\002/\022-/v1/{name=p" - + "rojects/*/locations/*/dbSystems/*}\022\351\001\n\016C" - + "reateDbSystem\0225.google.cloud.oracledatab" - + "ase.v1.CreateDbSystemRequest\032\035.google.lo" - + "ngrunning.Operation\"\200\001\312A\035\n\010DbSystem\022\021Ope" - + "rationMetadata\332A\035parent,db_system,db_sys" - + "tem_id\202\323\344\223\002:\"-/v1/{parent=projects/*/loc" - + "ations/*}/dbSystems:\tdb_system\022\353\001\n\016Updat" - + "eDbSystem\0225.google.cloud.oracledatabase." - + "v1.UpdateDbSystemRequest\032\035.google.longru" - + "nning.Operation\"\202\001\312A\035\n\010DbSystem\022\021Operati" - + "onMetadata\332A\025db_system,update_mask\202\323\344\223\002D" - + "27/v1/{db_system.name=projects/*/locatio" - + "ns/*/dbSystems/*}:\tdb_system\022\321\001\n\016DeleteD" - + "bSystem\0225.google.cloud.oracledatabase.v1" - + ".DeleteDbSystemRequest\032\035.google.longrunn" - + "ing.Operation\"i\312A*\n\025google.protobuf.Empt" - + "y\022\021OperationMetadata\332A\004name\202\323\344\223\002/*-/v1/{" - + "name=projects/*/locations/*/dbSystems/*}" - + "\022\354\001\n\031ListGoldengateDeployments\022@.google." - + "cloud.oracledatabase.v1.ListGoldengateDe" - + "ploymentsRequest\032A.google.cloud.oracleda" - + "tabase.v1.ListGoldengateDeploymentsRespo" - + "nse\"J\332A\006parent\202\323\344\223\002;\0229/v1/{parent=projec" - + "ts/*/locations/*}/goldengateDeployments\022" - + "\331\001\n\027GetGoldengateDeployment\022>.google.clo" - + "ud.oracledatabase.v1.GetGoldengateDeploy" - + "mentRequest\0324.google.cloud.oracledatabas" - + "e.v1.GoldengateDeployment\"H\332A\004name\202\323\344\223\002;" - + "\0229/v1/{name=projects/*/locations/*/golde" - + "ngateDeployments/*}\022\275\002\n\032CreateGoldengate" - + "Deployment\022A.google.cloud.oracledatabase" - + ".v1.CreateGoldengateDeploymentRequest\032\035." - + "google.longrunning.Operation\"\274\001\312A)\n\024Gold" - + "engateDeployment\022\021OperationMetadata\332A5pa" - + "rent,goldengate_deployment,goldengate_de" - + "ployment_id\202\323\344\223\002R\"9/v1/{parent=projects/" - + "*/locations/*}/goldengateDeployments:\025go" - + "ldengate_deployment\022\277\002\n\032UpdateGoldengate" - + "Deployment\022A.google.cloud.oracledatabase" - + ".v1.UpdateGoldengateDeploymentRequest\032\035." - + "google.longrunning.Operation\"\276\001\312A)\n\024Gold" - + "engateDeployment\022\021OperationMetadata\332A!go" - + "ldengate_deployment,update_mask\202\323\344\223\002h2O/" - + "v1/{goldengate_deployment.name=projects/" - + "*/locations/*/goldengateDeployments/*}:\025" - + "goldengate_deployment\022\365\001\n\032DeleteGoldenga" - + "teDeployment\022A.google.cloud.oracledataba" - + "se.v1.DeleteGoldengateDeploymentRequest\032" - + "\035.google.longrunning.Operation\"u\312A*\n\025goo" - + "gle.protobuf.Empty\022\021OperationMetadata\332A\004" - + "name\202\323\344\223\002;*9/v1/{name=projects/*/locatio" - + "ns/*/goldengateDeployments/*}\022\370\001\n\030StopGo" - + "ldengateDeployment\022?.google.cloud.oracle" - + "database.v1.StopGoldengateDeploymentRequ" - + "est\032\035.google.longrunning.Operation\"|\312A)\n" - + "\024GoldengateDeployment\022\021OperationMetadata" - + "\332A\004name\202\323\344\223\002C\">/v1/{name=projects/*/loca" - + "tions/*/goldengateDeployments/*}:stop:\001*", - "\022\373\001\n\031StartGoldengateDeployment\022@.google." - + "cloud.oracledatabase.v1.StartGoldengateD" - + "eploymentRequest\032\035.google.longrunning.Op" - + "eration\"}\312A)\n\024GoldengateDeployment\022\021Oper" - + "ationMetadata\332A\004name\202\323\344\223\002D\"?/v1/{name=pr" - + "ojects/*/locations/*/goldengateDeploymen" - + "ts/*}:start:\001*\022\354\001\n\031ListGoldengateConnect" - + "ions\022@.google.cloud.oracledatabase.v1.Li" - + "stGoldengateConnectionsRequest\032A.google." - + "cloud.oracledatabase.v1.ListGoldengateCo" - + "nnectionsResponse\"J\332A\006parent\202\323\344\223\002;\0229/v1/" - + "{parent=projects/*/locations/*}/goldenga" - + "teConnections\022\331\001\n\027GetGoldengateConnectio" - + "n\022>.google.cloud.oracledatabase.v1.GetGo" - + "ldengateConnectionRequest\0324.google.cloud" - + ".oracledatabase.v1.GoldengateConnection\"" - + "H\332A\004name\202\323\344\223\002;\0229/v1/{name=projects/*/loc" - + "ations/*/goldengateConnections/*}\022\275\002\n\032Cr" - + "eateGoldengateConnection\022A.google.cloud." - + "oracledatabase.v1.CreateGoldengateConnec" - + "tionRequest\032\035.google.longrunning.Operati" - + "on\"\274\001\312A)\n\024GoldengateConnection\022\021Operatio" - + "nMetadata\332A5parent,goldengate_connection" - + ",goldengate_connection_id\202\323\344\223\002R\"9/v1/{pa" - + "rent=projects/*/locations/*}/goldengateC" - + "onnections:\025goldengate_connection\022\277\002\n\032Up" - + "dateGoldengateConnection\022A.google.cloud." - + "oracledatabase.v1.UpdateGoldengateConnec" - + "tionRequest\032\035.google.longrunning.Operati" - + "on\"\276\001\312A)\n\024GoldengateConnection\022\021Operatio" - + "nMetadata\332A!goldengate_connection,update" - + "_mask\202\323\344\223\002h2O/v1/{goldengate_connection." - + "name=projects/*/locations/*/goldengateCo" - + "nnections/*}:\025goldengate_connection\022\365\001\n\032" - + "DeleteGoldengateConnection\022A.google.clou" - + "d.oracledatabase.v1.DeleteGoldengateConn" - + "ectionRequest\032\035.google.longrunning.Opera" - + "tion\"u\312A*\n\025google.protobuf.Empty\022\021Operat" - + "ionMetadata\332A\004name\202\323\344\223\002;*9/v1/{name=proj" - + "ects/*/locations/*/goldengateConnections" - + "/*}\022\210\002\n ListGoldengateDeploymentVersions" - + "\022G.google.cloud.oracledatabase.v1.ListGo" - + "ldengateDeploymentVersionsRequest\032H.goog" + + "stemsRequest\0325.google.cloud.oracledataba" + + "se.v1.ListDbSystemsResponse\">\332A\006parent\202\323" + + "\344\223\002/\022-/v1/{parent=projects/*/locations/*" + + "}/dbSystems\022\251\001\n\013GetDbSystem\0222.google.clo" + + "ud.oracledatabase.v1.GetDbSystemRequest\032" + + "(.google.cloud.oracledatabase.v1.DbSyste" + + "m\"<\332A\004name\202\323\344\223\002/\022-/v1/{name=projects/*/l" + + "ocations/*/dbSystems/*}\022\351\001\n\016CreateDbSyst" + + "em\0225.google.cloud.oracledatabase.v1.Crea" + + "teDbSystemRequest\032\035.google.longrunning.O" + + "peration\"\200\001\312A\035\n\010DbSystem\022\021OperationMetad" + + "ata\332A\035parent,db_system,db_system_id\202\323\344\223\002" + + ":\"-/v1/{parent=projects/*/locations/*}/d" + + "bSystems:\tdb_system\022\353\001\n\016UpdateDbSystem\0225" + + ".google.cloud.oracledatabase.v1.UpdateDb" + + "SystemRequest\032\035.google.longrunning.Opera" + + "tion\"\202\001\312A\035\n\010DbSystem\022\021OperationMetadata\332" + + "A\025db_system,update_mask\202\323\344\223\002D27/v1/{db_s" + + "ystem.name=projects/*/locations/*/dbSyst" + + "ems/*}:\tdb_system\022\321\001\n\016DeleteDbSystem\0225.g" + + "oogle.cloud.oracledatabase.v1.DeleteDbSy" + + "stemRequest\032\035.google.longrunning.Operati" + + "on\"i\312A*\n\025google.protobuf.Empty\022\021Operatio" + + "nMetadata\332A\004name\202\323\344\223\002/*-/v1/{name=projec" + + "ts/*/locations/*/dbSystems/*}\022\354\001\n\031ListGo" + + "ldengateDeployments\022@.google.cloud.oracl" + + "edatabase.v1.ListGoldengateDeploymentsRe" + + "quest\032A.google.cloud.oracledatabase.v1.L" + + "istGoldengateDeploymentsResponse\"J\332A\006par" + + "ent\202\323\344\223\002;\0229/v1/{parent=projects/*/locati" + + "ons/*}/goldengateDeployments\022\331\001\n\027GetGold" + + "engateDeployment\022>.google.cloud.oracleda" + + "tabase.v1.GetGoldengateDeploymentRequest" + + "\0324.google.cloud.oracledatabase.v1.Golden" + + "gateDeployment\"H\332A\004name\202\323\344\223\002;\0229/v1/{name" + + "=projects/*/locations/*/goldengateDeploy" + + "ments/*}\022\275\002\n\032CreateGoldengateDeployment\022" + + "A.google.cloud.oracledatabase.v1.CreateG" + + "oldengateDeploymentRequest\032\035.google.long" + + "running.Operation\"\274\001\312A)\n\024GoldengateDeplo" + + "yment\022\021OperationMetadata\332A5parent,golden" + + "gate_deployment,goldengate_deployment_id" + + "\202\323\344\223\002R\"9/v1/{parent=projects/*/locations" + + "/*}/goldengateDeployments:\025goldengate_de" + + "ployment\022\277\002\n\032UpdateGoldengateDeployment\022" + + "A.google.cloud.oracledatabase.v1.UpdateG" + + "oldengateDeploymentRequest\032\035.google.long" + + "running.Operation\"\276\001\312A)\n\024GoldengateDeplo" + + "yment\022\021OperationMetadata\332A!goldengate_de" + + "ployment,update_mask\202\323\344\223\002h2O/v1/{goldeng" + + "ate_deployment.name=projects/*/locations" + + "/*/goldengateDeployments/*}:\025goldengate_" + + "deployment\022\365\001\n\032DeleteGoldengateDeploymen" + + "t\022A.google.cloud.oracledatabase.v1.Delet" + + "eGoldengateDeploymentRequest\032\035.google.lo" + + "ngrunning.Operation\"u\312A*\n\025google.protobu" + + "f.Empty\022\021OperationMetadata\332A\004name\202\323\344\223\002;*" + + "9/v1/{name=projects/*/locations/*/golden", + "gateDeployments/*}\022\370\001\n\030StopGoldengateDep" + + "loyment\022?.google.cloud.oracledatabase.v1" + + ".StopGoldengateDeploymentRequest\032\035.googl" + + "e.longrunning.Operation\"|\312A)\n\024Goldengate" + + "Deployment\022\021OperationMetadata\332A\004name\202\323\344\223" + + "\002C\">/v1/{name=projects/*/locations/*/gol" + + "dengateDeployments/*}:stop:\001*\022\373\001\n\031StartG" + + "oldengateDeployment\022@.google.cloud.oracl" + + "edatabase.v1.StartGoldengateDeploymentRe" + + "quest\032\035.google.longrunning.Operation\"}\312A" + + ")\n\024GoldengateDeployment\022\021OperationMetada" + + "ta\332A\004name\202\323\344\223\002D\"?/v1/{name=projects/*/lo" + + "cations/*/goldengateDeployments/*}:start" + + ":\001*\022\354\001\n\031ListGoldengateConnections\022@.goog" + "le.cloud.oracledatabase.v1.ListGoldengat" - + "eDeploymentVersionsResponse\"Q\332A\006parent\202\323" - + "\344\223\002B\022@/v1/{parent=projects/*/locations/*" - + "}/goldengateDeploymentVersions\022\374\001\n\035ListG" - + "oldengateDeploymentTypes\022D.google.cloud." - + "oracledatabase.v1.ListGoldengateDeployme" - + "ntTypesRequest\032E.google.cloud.oracledata" - + "base.v1.ListGoldengateDeploymentTypesRes" - + "ponse\"N\332A\006parent\202\323\344\223\002?\022=/v1/{parent=proj" - + "ects/*/locations/*}/goldengateDeployment" - + "Types\022\230\002\n$ListGoldengateDeploymentEnviro" - + "nments\022K.google.cloud.oracledatabase.v1." - + "ListGoldengateDeploymentEnvironmentsRequ" - + "est\032L.google.cloud.oracledatabase.v1.Lis" - + "tGoldengateDeploymentEnvironmentsRespons" - + "e\"U\332A\006parent\202\323\344\223\002F\022D/v1/{parent=projects" - + "/*/locations/*}/goldengateDeploymentEnvi" - + "ronments\022\374\001\n\035ListGoldengateConnectionTyp" - + "es\022D.google.cloud.oracledatabase.v1.List" - + "GoldengateConnectionTypesRequest\032E.googl" + + "eConnectionsRequest\032A.google.cloud.oracl" + + "edatabase.v1.ListGoldengateConnectionsRe" + + "sponse\"J\332A\006parent\202\323\344\223\002;\0229/v1/{parent=pro" + + "jects/*/locations/*}/goldengateConnectio" + + "ns\022\331\001\n\027GetGoldengateConnection\022>.google." + + "cloud.oracledatabase.v1.GetGoldengateCon" + + "nectionRequest\0324.google.cloud.oracledata" + + "base.v1.GoldengateConnection\"H\332A\004name\202\323\344" + + "\223\002;\0229/v1/{name=projects/*/locations/*/go" + + "ldengateConnections/*}\022\275\002\n\032CreateGoldeng" + + "ateConnection\022A.google.cloud.oracledatab" + + "ase.v1.CreateGoldengateConnectionRequest" + + "\032\035.google.longrunning.Operation\"\274\001\312A)\n\024G" + + "oldengateConnection\022\021OperationMetadata\332A" + + "5parent,goldengate_connection,goldengate" + + "_connection_id\202\323\344\223\002R\"9/v1/{parent=projec" + + "ts/*/locations/*}/goldengateConnections:" + + "\025goldengate_connection\022\277\002\n\032UpdateGoldeng" + + "ateConnection\022A.google.cloud.oracledatab" + + "ase.v1.UpdateGoldengateConnectionRequest" + + "\032\035.google.longrunning.Operation\"\276\001\312A)\n\024G" + + "oldengateConnection\022\021OperationMetadata\332A" + + "!goldengate_connection,update_mask\202\323\344\223\002h" + + "2O/v1/{goldengate_connection.name=projec" + + "ts/*/locations/*/goldengateConnections/*" + + "}:\025goldengate_connection\022\365\001\n\032DeleteGolde" + + "ngateConnection\022A.google.cloud.oracledat" + + "abase.v1.DeleteGoldengateConnectionReque" + + "st\032\035.google.longrunning.Operation\"u\312A*\n\025" + + "google.protobuf.Empty\022\021OperationMetadata" + + "\332A\004name\202\323\344\223\002;*9/v1/{name=projects/*/loca" + + "tions/*/goldengateConnections/*}\022\210\002\n Lis" + + "tGoldengateDeploymentVersions\022G.google.c" + + "loud.oracledatabase.v1.ListGoldengateDep" + + "loymentVersionsRequest\032H.google.cloud.or" + + "acledatabase.v1.ListGoldengateDeployment" + + "VersionsResponse\"Q\332A\006parent\202\323\344\223\002B\022@/v1/{" + + "parent=projects/*/locations/*}/goldengat" + + "eDeploymentVersions\022\374\001\n\035ListGoldengateDe" + + "ploymentTypes\022D.google.cloud.oracledatab" + + "ase.v1.ListGoldengateDeploymentTypesRequ" + + "est\032E.google.cloud.oracledatabase.v1.Lis" + + "tGoldengateDeploymentTypesResponse\"N\332A\006p" + + "arent\202\323\344\223\002?\022=/v1/{parent=projects/*/loca" + + "tions/*}/goldengateDeploymentTypes\022\230\002\n$L" + + "istGoldengateDeploymentEnvironments\022K.go" + + "ogle.cloud.oracledatabase.v1.ListGoldeng" + + "ateDeploymentEnvironmentsRequest\032L.googl" + "e.cloud.oracledatabase.v1.ListGoldengate" - + "ConnectionTypesResponse\"N\332A\006parent\202\323\344\223\002?" - + "\022=/v1/{parent=projects/*/locations/*}/go" - + "ldengateConnectionTypes\022\300\001\n\016ListDbVersio" - + "ns\0225.google.cloud.oracledatabase.v1.List" - + "DbVersionsRequest\0326.google.cloud.oracled" - + "atabase.v1.ListDbVersionsResponse\"?\332A\006pa" - + "rent\202\323\344\223\0020\022./v1/{parent=projects/*/locat" - + "ions/*}/dbVersions\022\354\001\n\031ListDatabaseChara" - + "cterSets\022@.google.cloud.oracledatabase.v" - + "1.ListDatabaseCharacterSetsRequest\032A.goo" - + "gle.cloud.oracledatabase.v1.ListDatabase" - + "CharacterSetsResponse\"J\332A\006parent\202\323\344\223\002;\0229" - + "/v1/{parent=projects/*/locations/*}/data" - + "baseCharacterSets\022\224\002\n#ListGoldengateConn" - + "ectionAssignments\022J.google.cloud.oracled" - + "atabase.v1.ListGoldengateConnectionAssig" - + "nmentsRequest\032K.google.cloud.oracledatab" - + "ase.v1.ListGoldengateConnectionAssignmen" - + "tsResponse\"T\332A\006parent\202\323\344\223\002E\022C/v1/{parent" - + "=projects/*/locations/*}/goldengateConne" - + "ctionAssignments\022\201\002\n!GetGoldengateConnec" - + "tionAssignment\022H.google.cloud.oracledata" - + "base.v1.GetGoldengateConnectionAssignmen" - + "tRequest\032>.google.cloud.oracledatabase.v" - + "1.GoldengateConnectionAssignment\"R\332A\004nam" - + "e\202\323\344\223\002E\022C/v1/{name=projects/*/locations/" - + "*/goldengateConnectionAssignments/*}\022\206\003\n" - + "$CreateGoldengateConnectionAssignment\022K." - + "google.cloud.oracledatabase.v1.CreateGol" - + "dengateConnectionAssignmentRequest\032\035.goo" - + "gle.longrunning.Operation\"\361\001\312A3\n\036Goldeng" - + "ateConnectionAssignment\022\021OperationMetada" - + "ta\332AKparent,goldengate_connection_assign" - + "ment,goldengate_connection_assignment_id" - + "\202\323\344\223\002g\"C/v1/{parent=projects/*/locations" - + "/*}/goldengateConnectionAssignments: gol" - + "dengate_connection_assignment\022\211\003\n$Update" - + "GoldengateConnectionAssignment\022K.google." - + "cloud.oracledatabase.v1.UpdateGoldengate" - + "ConnectionAssignmentRequest\032\035.google.lon" - + "grunning.Operation\"\364\001\312A3\n\036GoldengateConn" - + "ectionAssignment\022\021OperationMetadata\332A,go" - + "ldengate_connection_assignment,update_ma" - + "sk\202\323\344\223\002\210\0012d/v1/{goldengate_connection_as" - + "signment.name=projects/*/locations/*/gol" - + "dengateConnectionAssignments/*}: goldeng" - + "ate_connection_assignment\022\223\002\n$DeleteGold" + + "DeploymentEnvironmentsResponse\"U\332A\006paren" + + "t\202\323\344\223\002F\022D/v1/{parent=projects/*/location" + + "s/*}/goldengateDeploymentEnvironments\022\374\001" + + "\n\035ListGoldengateConnectionTypes\022D.google" + + ".cloud.oracledatabase.v1.ListGoldengateC" + + "onnectionTypesRequest\032E.google.cloud.ora" + + "cledatabase.v1.ListGoldengateConnectionT" + + "ypesResponse\"N\332A\006parent\202\323\344\223\002?\022=/v1/{pare" + + "nt=projects/*/locations/*}/goldengateCon" + + "nectionTypes\022\300\001\n\016ListDbVersions\0225.google" + + ".cloud.oracledatabase.v1.ListDbVersionsR" + + "equest\0326.google.cloud.oracledatabase.v1." + + "ListDbVersionsResponse\"?\332A\006parent\202\323\344\223\0020\022" + + "./v1/{parent=projects/*/locations/*}/dbV" + + "ersions\022\354\001\n\031ListDatabaseCharacterSets\022@." + + "google.cloud.oracledatabase.v1.ListDatab" + + "aseCharacterSetsRequest\032A.google.cloud.o" + + "racledatabase.v1.ListDatabaseCharacterSe" + + "tsResponse\"J\332A\006parent\202\323\344\223\002;\0229/v1/{parent" + + "=projects/*/locations/*}/databaseCharact" + + "erSets\022\224\002\n#ListGoldengateConnectionAssig" + + "nments\022J.google.cloud.oracledatabase.v1." + + "ListGoldengateConnectionAssignmentsReque" + + "st\032K.google.cloud.oracledatabase.v1.List" + + "GoldengateConnectionAssignmentsResponse\"" + + "T\332A\006parent\202\323\344\223\002E\022C/v1/{parent=projects/*" + + "/locations/*}/goldengateConnectionAssign" + + "ments\022\201\002\n!GetGoldengateConnectionAssignm" + + "ent\022H.google.cloud.oracledatabase.v1.Get" + + "GoldengateConnectionAssignmentRequest\032>." + + "google.cloud.oracledatabase.v1.Goldengat" + + "eConnectionAssignment\"R\332A\004name\202\323\344\223\002E\022C/v" + + "1/{name=projects/*/locations/*/goldengat" + + "eConnectionAssignments/*}\022\206\003\n$CreateGold" + "engateConnectionAssignment\022K.google.clou" - + "d.oracledatabase.v1.DeleteGoldengateConn" + + "d.oracledatabase.v1.CreateGoldengateConn" + "ectionAssignmentRequest\032\035.google.longrun" - + "ning.Operation\"\177\312A*\n\025google.protobuf.Emp" - + "ty\022\021OperationMetadata\332A\004name\202\323\344\223\002E*C/v1/" - + "{name=projects/*/locations/*/goldengateC" - + "onnectionAssignments/*}\022\227\002\n\"TestGoldenga" - + "teConnectionAssignment\022I.google.cloud.or" - + "acledatabase.v1.TestGoldengateConnection" - + "AssignmentRequest\032J.google.cloud.oracled" - + "atabase.v1.TestGoldengateConnectionAssig" - + "nmentResponse\"Z\332A\004name\202\323\344\223\002M\"H/v1/{name=" - + "projects/*/locations/*/goldengateConnect" - + "ionAssignments/*}:test:\001*\022\344\001\n\027ListDataba" - + "seConnections\022>.google.cloud.oracledatab" - + "ase.v1.ListDatabaseConnectionsRequest\032?." - + "google.cloud.oracledatabase.v1.ListDatab" - + "aseConnectionsResponse\"H\332A\006parent\202\323\344\223\0029\022" - + "7/v1/{parent=projects/*/locations/*}/dat" - + "abaseConnections\022\321\001\n\025GetDatabaseConnecti" - + "on\022<.google.cloud.oracledatabase.v1.GetD" - + "atabaseConnectionRequest\0322.google.cloud." - + "oracledatabase.v1.DatabaseConnection\"F\332A" - + "\004name\202\323\344\223\0029\0227/v1/{name=projects/*/locati" - + "ons/*/databaseConnections/*}\022\257\002\n\030CreateD" - + "atabaseConnection\022?.google.cloud.oracled" - + "atabase.v1.CreateDatabaseConnectionReque" - + "st\032\035.google.longrunning.Operation\"\262\001\312A\'\n" - + "\022DatabaseConnection\022\021OperationMetadata\332A" - + "1parent,database_connection,database_con" - + "nection_id\202\323\344\223\002N\"7/v1/{parent=projects/*" - + "/locations/*}/databaseConnections:\023datab" - + "ase_connection\022\261\002\n\030UpdateDatabaseConnect" - + "ion\022?.google.cloud.oracledatabase.v1.Upd" - + "ateDatabaseConnectionRequest\032\035.google.lo" - + "ngrunning.Operation\"\264\001\312A\'\n\022DatabaseConne" - + "ction\022\021OperationMetadata\332A\037database_conn" - + "ection,update_mask\202\323\344\223\002b2K/v1/{database_" - + "connection.name=projects/*/locations/*/d" - + "atabaseConnections/*}:\023database_connecti" - + "on\022\357\001\n\030DeleteDatabaseConnection\022?.google" - + ".cloud.oracledatabase.v1.DeleteDatabaseC" - + "onnectionRequest\032\035.google.longrunning.Op" - + "eration\"s\312A*\n\025google.protobuf.Empty\022\021Ope" - + "rationMetadata\332A\004name\202\323\344\223\0029*7/v1/{name=p" - + "rojects/*/locations/*/databaseConnection" - + "s/*}\022\347\001\n\026TestDatabaseConnection\022=.google" - + ".cloud.oracledatabase.v1.TestDatabaseCon" - + "nectionRequest\032>.google.cloud.oracledata" - + "base.v1.TestDatabaseConnectionResponse\"N" - + "\332A\004name\202\323\344\223\002A\".google.cloud.oracledatabase.v1.List" + + "DatabaseConnectionsRequest\032?.google.clou" + + "d.oracledatabase.v1.ListDatabaseConnecti" + + "onsResponse\"H\332A\006parent\202\323\344\223\0029\0227/v1/{paren" + + "t=projects/*/locations/*}/databaseConnec" + + "tions\022\321\001\n\025GetDatabaseConnection\022<.google" + + ".cloud.oracledatabase.v1.GetDatabaseConn" + + "ectionRequest\0322.google.cloud.oracledatab" + + "ase.v1.DatabaseConnection\"F\332A\004name\202\323\344\223\0029" + + "\0227/v1/{name=projects/*/locations/*/datab" + + "aseConnections/*}\022\257\002\n\030CreateDatabaseConn" + + "ection\022?.google.cloud.oracledatabase.v1." + + "CreateDatabaseConnectionRequest\032\035.google" + + ".longrunning.Operation\"\262\001\312A\'\n\022DatabaseCo" + + "nnection\022\021OperationMetadata\332A1parent,dat" + + "abase_connection,database_connection_id\202" + + "\323\344\223\002N\"7/v1/{parent=projects/*/locations/" + + "*}/databaseConnections:\023database_connect" + + "ion\022\261\002\n\030UpdateDatabaseConnection\022?.googl" + + "e.cloud.oracledatabase.v1.UpdateDatabase" + + "ConnectionRequest\032\035.google.longrunning.O" + + "peration\"\264\001\312A\'\n\022DatabaseConnection\022\021Oper" + + "ationMetadata\332A\037database_connection,upda" + + "te_mask\202\323\344\223\002b2K/v1/{database_connection." + + "name=projects/*/locations/*/databaseConn" + + "ections/*}:\023database_connection\022\357\001\n\030Dele" + + "teDatabaseConnection\022?.google.cloud.orac" + + "ledatabase.v1.DeleteDatabaseConnectionRe" + + "quest\032\035.google.longrunning.Operation\"s\312A" + + "*\n\025google.protobuf.Empty\022\021OperationMetad" + + "ata\332A\004name\202\323\344\223\0029*7/v1/{name=projects/*/l" + + "ocations/*/databaseConnections/*}\022\347\001\n\026Te" + + "stDatabaseConnection\022=.google.cloud.orac" + + "ledatabase.v1.TestDatabaseConnectionRequ" + + "est\032>.google.cloud.oracledatabase.v1.Tes" + + "tDatabaseConnectionResponse\"N\332A\004name\202\323\344\223" + + "\002A\" future = + oracleDatabaseClient.updateOdbDnsZoneCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END oracledatabase_v1_generated_OracleDatabase_UpdateOdbDnsZone_async] diff --git a/java-oracledatabase/samples/snippets/generated/com/google/cloud/oracledatabase/v1/oracledatabase/updateodbdnszone/AsyncUpdateOdbDnsZoneLRO.java b/java-oracledatabase/samples/snippets/generated/com/google/cloud/oracledatabase/v1/oracledatabase/updateodbdnszone/AsyncUpdateOdbDnsZoneLRO.java new file mode 100644 index 000000000000..7348d38044ec --- /dev/null +++ b/java-oracledatabase/samples/snippets/generated/com/google/cloud/oracledatabase/v1/oracledatabase/updateodbdnszone/AsyncUpdateOdbDnsZoneLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.oracledatabase.v1.samples; + +// [START oracledatabase_v1_generated_OracleDatabase_UpdateOdbDnsZone_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.oracledatabase.v1.OdbDnsZone; +import com.google.cloud.oracledatabase.v1.OperationMetadata; +import com.google.cloud.oracledatabase.v1.OracleDatabaseClient; +import com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateOdbDnsZoneLRO { + + public static void main(String[] args) throws Exception { + asyncUpdateOdbDnsZoneLRO(); + } + + public static void asyncUpdateOdbDnsZoneLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (OracleDatabaseClient oracleDatabaseClient = OracleDatabaseClient.create()) { + UpdateOdbDnsZoneRequest request = + UpdateOdbDnsZoneRequest.newBuilder() + .setUpdateMask(FieldMask.newBuilder().build()) + .setOdbDnsZone(OdbDnsZone.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + OperationFuture future = + oracleDatabaseClient.updateOdbDnsZoneOperationCallable().futureCall(request); + // Do something. + OdbDnsZone response = future.get(); + } + } +} +// [END oracledatabase_v1_generated_OracleDatabase_UpdateOdbDnsZone_LRO_async] diff --git a/java-oracledatabase/samples/snippets/generated/com/google/cloud/oracledatabase/v1/oracledatabase/updateodbdnszone/SyncUpdateOdbDnsZone.java b/java-oracledatabase/samples/snippets/generated/com/google/cloud/oracledatabase/v1/oracledatabase/updateodbdnszone/SyncUpdateOdbDnsZone.java new file mode 100644 index 000000000000..dd40c35a174a --- /dev/null +++ b/java-oracledatabase/samples/snippets/generated/com/google/cloud/oracledatabase/v1/oracledatabase/updateodbdnszone/SyncUpdateOdbDnsZone.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.oracledatabase.v1.samples; + +// [START oracledatabase_v1_generated_OracleDatabase_UpdateOdbDnsZone_sync] +import com.google.cloud.oracledatabase.v1.OdbDnsZone; +import com.google.cloud.oracledatabase.v1.OracleDatabaseClient; +import com.google.cloud.oracledatabase.v1.UpdateOdbDnsZoneRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateOdbDnsZone { + + public static void main(String[] args) throws Exception { + syncUpdateOdbDnsZone(); + } + + public static void syncUpdateOdbDnsZone() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (OracleDatabaseClient oracleDatabaseClient = OracleDatabaseClient.create()) { + UpdateOdbDnsZoneRequest request = + UpdateOdbDnsZoneRequest.newBuilder() + .setUpdateMask(FieldMask.newBuilder().build()) + .setOdbDnsZone(OdbDnsZone.newBuilder().build()) + .setRequestId("requestId693933066") + .build(); + OdbDnsZone response = oracleDatabaseClient.updateOdbDnsZoneAsync(request).get(); + } + } +} +// [END oracledatabase_v1_generated_OracleDatabase_UpdateOdbDnsZone_sync] diff --git a/java-oracledatabase/samples/snippets/generated/com/google/cloud/oracledatabase/v1/oracledatabase/updateodbdnszone/SyncUpdateOdbDnsZoneOdbdnszoneFieldmask.java b/java-oracledatabase/samples/snippets/generated/com/google/cloud/oracledatabase/v1/oracledatabase/updateodbdnszone/SyncUpdateOdbDnsZoneOdbdnszoneFieldmask.java new file mode 100644 index 000000000000..277190f1fe74 --- /dev/null +++ b/java-oracledatabase/samples/snippets/generated/com/google/cloud/oracledatabase/v1/oracledatabase/updateodbdnszone/SyncUpdateOdbDnsZoneOdbdnszoneFieldmask.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.oracledatabase.v1.samples; + +// [START oracledatabase_v1_generated_OracleDatabase_UpdateOdbDnsZone_OdbdnszoneFieldmask_sync] +import com.google.cloud.oracledatabase.v1.OdbDnsZone; +import com.google.cloud.oracledatabase.v1.OracleDatabaseClient; +import com.google.protobuf.FieldMask; + +public class SyncUpdateOdbDnsZoneOdbdnszoneFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateOdbDnsZoneOdbdnszoneFieldmask(); + } + + public static void syncUpdateOdbDnsZoneOdbdnszoneFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (OracleDatabaseClient oracleDatabaseClient = OracleDatabaseClient.create()) { + OdbDnsZone odbDnsZone = OdbDnsZone.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + OdbDnsZone response = + oracleDatabaseClient.updateOdbDnsZoneAsync(odbDnsZone, updateMask).get(); + } + } +} +// [END oracledatabase_v1_generated_OracleDatabase_UpdateOdbDnsZone_OdbdnszoneFieldmask_sync] diff --git a/java-orchestration-airflow/README.md b/java-orchestration-airflow/README.md index 100a1dc333c2..5884c90d2a00 100644 --- a/java-orchestration-airflow/README.md +++ b/java-orchestration-airflow/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-orchestration-airflow - 1.102.0 + 1.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-orchestration-airflow' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-orchestration-airflow:1.102.0' +implementation 'com.google.cloud:google-cloud-orchestration-airflow:1.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-orchestration-airflow" % "1.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-orchestration-airflow" % "1.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-orchestration-airflow/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-orchestration-airflow.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-orchestration-airflow/1.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-orchestration-airflow/1.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-orgpolicy/README.md b/java-orgpolicy/README.md index fde001eef2d0..5952a2eed2e1 100644 --- a/java-orgpolicy/README.md +++ b/java-orgpolicy/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-orgpolicy - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-orgpolicy' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-orgpolicy:2.102.0' +implementation 'com.google.cloud:google-cloud-orgpolicy:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-orgpolicy" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-orgpolicy" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/proto-google-cloud-orgpolicy-v1/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-orgpolicy.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-orgpolicy/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-orgpolicy/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-os-config/README.md b/java-os-config/README.md index e7504cdd4b96..ff43bece03bc 100644 --- a/java-os-config/README.md +++ b/java-os-config/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-os-config - 2.104.0 + 2.105.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-os-config' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-os-config:2.104.0' +implementation 'com.google.cloud:google-cloud-os-config:2.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-os-config" % "2.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-os-config" % "2.105.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-os-config/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-os-config.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-os-config/2.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-os-config/2.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-os-login/README.md b/java-os-login/README.md index 11a50e7ac95c..4b45991198c1 100644 --- a/java-os-login/README.md +++ b/java-os-login/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-os-login - 2.101.0 + 2.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-os-login' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-os-login:2.101.0' +implementation 'com.google.cloud:google-cloud-os-login:2.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-os-login" % "2.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-os-login" % "2.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-os-login/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-os-login.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-os-login/2.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-os-login/2.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-parallelstore/README.md b/java-parallelstore/README.md index 49d1f2c76e82..20e0051fbb86 100644 --- a/java-parallelstore/README.md +++ b/java-parallelstore/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-parallelstore - 0.65.0 + 0.66.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-parallelstore' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-parallelstore:0.65.0' +implementation 'com.google.cloud:google-cloud-parallelstore:0.66.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-parallelstore" % "0.65.0" +libraryDependencies += "com.google.cloud" % "google-cloud-parallelstore" % "0.66.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-parallelstore/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-parallelstore.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-parallelstore/0.65.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-parallelstore/0.66.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-parametermanager/README.md b/java-parametermanager/README.md index c803a19cbe51..d6c2d1667a08 100644 --- a/java-parametermanager/README.md +++ b/java-parametermanager/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-parametermanager - 0.46.0 + 0.47.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-parametermanager' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-parametermanager:0.46.0' +implementation 'com.google.cloud:google-cloud-parametermanager:0.47.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-parametermanager" % "0.46.0" +libraryDependencies += "com.google.cloud" % "google-cloud-parametermanager" % "0.47.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-parametermanager/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-parametermanager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-parametermanager/0.46.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-parametermanager/0.47.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-phishingprotection/README.md b/java-phishingprotection/README.md index b7de4ad29ced..3f64d4590ae4 100644 --- a/java-phishingprotection/README.md +++ b/java-phishingprotection/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-phishingprotection - 0.133.0 + 0.134.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-phishingprotection' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-phishingprotection:0.133.0' +implementation 'com.google.cloud:google-cloud-phishingprotection:0.134.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-phishingprotection" % "0.133.0" +libraryDependencies += "com.google.cloud" % "google-cloud-phishingprotection" % "0.134.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-phishingprotection/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-phishingprotection.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-phishingprotection/0.133.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-phishingprotection/0.134.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-policy-troubleshooter/README.md b/java-policy-troubleshooter/README.md index ab59fec8e240..be01f968992d 100644 --- a/java-policy-troubleshooter/README.md +++ b/java-policy-troubleshooter/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-policy-troubleshooter - 1.101.0 + 1.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-policy-troubleshooter' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-policy-troubleshooter:1.101.0' +implementation 'com.google.cloud:google-cloud-policy-troubleshooter:1.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-policy-troubleshooter" % "1.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-policy-troubleshooter" % "1.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-policy-troubleshooter/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-policy-troubleshooter.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-policy-troubleshooter/1.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-policy-troubleshooter/1.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-policysimulator/README.md b/java-policysimulator/README.md index e96997ec433c..aabac6d95a79 100644 --- a/java-policysimulator/README.md +++ b/java-policysimulator/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-policysimulator - 0.81.0 + 0.82.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-policysimulator' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-policysimulator:0.81.0' +implementation 'com.google.cloud:google-cloud-policysimulator:0.82.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-policysimulator" % "0.81.0" +libraryDependencies += "com.google.cloud" % "google-cloud-policysimulator" % "0.82.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-policysimulator/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-policysimulator.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-policysimulator/0.81.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-policysimulator/0.82.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-private-catalog/README.md b/java-private-catalog/README.md index 0217249e7523..b439e2ab3e12 100644 --- a/java-private-catalog/README.md +++ b/java-private-catalog/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-private-catalog - 0.104.0 + 0.105.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-private-catalog' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-private-catalog:0.104.0' +implementation 'com.google.cloud:google-cloud-private-catalog:0.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-private-catalog" % "0.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-private-catalog" % "0.105.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-private-catalog/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-private-catalog.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-private-catalog/0.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-private-catalog/0.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-privilegedaccessmanager/README.md b/java-privilegedaccessmanager/README.md index 684a0051c6e6..ed3b7ad2cec6 100644 --- a/java-privilegedaccessmanager/README.md +++ b/java-privilegedaccessmanager/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-privilegedaccessmanager - 0.56.0 + 0.57.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-privilegedaccessmanager' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-privilegedaccessmanager:0.56.0' +implementation 'com.google.cloud:google-cloud-privilegedaccessmanager:0.57.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-privilegedaccessmanager" % "0.56.0" +libraryDependencies += "com.google.cloud" % "google-cloud-privilegedaccessmanager" % "0.57.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-privilegedaccessmanager/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-privilegedaccessmanager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-privilegedaccessmanager/0.56.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-privilegedaccessmanager/0.57.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-productregistry/README.md b/java-productregistry/README.md index c61db22a1bea..456741dc54b9 100644 --- a/java-productregistry/README.md +++ b/java-productregistry/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-productregistry - 0.8.0 + 0.9.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-productregistry' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-productregistry:0.8.0' +implementation 'com.google.cloud:google-cloud-productregistry:0.9.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-productregistry" % "0.8.0" +libraryDependencies += "com.google.cloud" % "google-cloud-productregistry" % "0.9.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-productregistry/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-productregistry.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-productregistry/0.8.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-productregistry/0.9.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-profiler/README.md b/java-profiler/README.md index a935af7575f3..1c72489a1c33 100644 --- a/java-profiler/README.md +++ b/java-profiler/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-profiler - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-profiler' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-profiler:2.102.0' +implementation 'com.google.cloud:google-cloud-profiler:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-profiler" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-profiler" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-profiler/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-profiler.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-profiler/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-profiler/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-publicca/README.md b/java-publicca/README.md index 53b07d4a03fd..c35893719c4d 100644 --- a/java-publicca/README.md +++ b/java-publicca/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-publicca - 0.99.0 + 0.100.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-publicca' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-publicca:0.99.0' +implementation 'com.google.cloud:google-cloud-publicca:0.100.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-publicca" % "0.99.0" +libraryDependencies += "com.google.cloud" % "google-cloud-publicca" % "0.100.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-publicca/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-publicca.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-publicca/0.99.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-publicca/0.100.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-pubsub/README.md b/java-pubsub/README.md index ae38ceda2668..3b3595f69780 100644 --- a/java-pubsub/README.md +++ b/java-pubsub/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-pubsub - 1.160.0 + 1.161.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-pubsub' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-pubsub:1.160.0' +implementation 'com.google.cloud:google-cloud-pubsub:1.161.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-pubsub" % "1.160.0" +libraryDependencies += "com.google.cloud" % "google-cloud-pubsub" % "1.161.0" ``` ## Authentication @@ -398,7 +398,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-pubsub/latest/history [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-pubsub.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-pubsub/1.160.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-pubsub/1.161.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-rapidmigrationassessment/README.md b/java-rapidmigrationassessment/README.md index 67eb10f86046..bb6225e3367e 100644 --- a/java-rapidmigrationassessment/README.md +++ b/java-rapidmigrationassessment/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-rapidmigrationassessment - 0.85.0 + 0.86.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-rapidmigrationassessment' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-rapidmigrationassessment:0.85.0' +implementation 'com.google.cloud:google-cloud-rapidmigrationassessment:0.86.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-rapidmigrationassessment" % "0.85.0" +libraryDependencies += "com.google.cloud" % "google-cloud-rapidmigrationassessment" % "0.86.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-rapidmigrationassessment/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-rapidmigrationassessment.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-rapidmigrationassessment/0.85.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-rapidmigrationassessment/0.86.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-recaptchaenterprise/README.md b/java-recaptchaenterprise/README.md index 7f999bb17e21..f72972f6c32a 100644 --- a/java-recaptchaenterprise/README.md +++ b/java-recaptchaenterprise/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-recaptchaenterprise - 3.99.0 + 3.100.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-recaptchaenterprise' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-recaptchaenterprise:3.99.0' +implementation 'com.google.cloud:google-cloud-recaptchaenterprise:3.100.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-recaptchaenterprise" % "3.99.0" +libraryDependencies += "com.google.cloud" % "google-cloud-recaptchaenterprise" % "3.100.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-recaptchaenterprise/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-recaptchaenterprise.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-recaptchaenterprise/3.99.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-recaptchaenterprise/3.100.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-recommendations-ai/README.md b/java-recommendations-ai/README.md index a427e5042fbc..b8bd55a8c658 100644 --- a/java-recommendations-ai/README.md +++ b/java-recommendations-ai/README.md @@ -45,7 +45,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-recommendations-ai - 0.109.0 + 0.110.0 ``` @@ -60,13 +60,13 @@ implementation 'com.google.cloud:google-cloud-recommendations-ai' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-recommendations-ai:0.109.0' +implementation 'com.google.cloud:google-cloud-recommendations-ai:0.110.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-recommendations-ai" % "0.109.0" +libraryDependencies += "com.google.cloud" % "google-cloud-recommendations-ai" % "0.110.0" ``` ## Authentication @@ -187,7 +187,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-recommendations-ai/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-recommendations-ai.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-recommendations-ai/0.109.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-recommendations-ai/0.110.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-recommender/README.md b/java-recommender/README.md index 36026b2a0138..0b8f4f801cea 100644 --- a/java-recommender/README.md +++ b/java-recommender/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-recommender - 2.104.0 + 2.105.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-recommender' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-recommender:2.104.0' +implementation 'com.google.cloud:google-cloud-recommender:2.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-recommender" % "2.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-recommender" % "2.105.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-recommender/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-recommender.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-recommender/2.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-recommender/2.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-redis-cluster/README.md b/java-redis-cluster/README.md index 64ce52a1012f..61ea7ef2b2d1 100644 --- a/java-redis-cluster/README.md +++ b/java-redis-cluster/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-redis-cluster - 0.74.0 + 0.75.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-redis-cluster' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-redis-cluster:0.74.0' +implementation 'com.google.cloud:google-cloud-redis-cluster:0.75.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-redis-cluster" % "0.74.0" +libraryDependencies += "com.google.cloud" % "google-cloud-redis-cluster" % "0.75.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-redis-cluster/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-redis-cluster.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-redis-cluster/0.74.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-redis-cluster/0.75.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-redis/README.md b/java-redis/README.md index c2f2e27a545e..35aaa58d9100 100644 --- a/java-redis/README.md +++ b/java-redis/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-redis - 2.105.0 + 2.106.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-redis' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-redis:2.105.0' +implementation 'com.google.cloud:google-cloud-redis:2.106.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-redis" % "2.105.0" +libraryDependencies += "com.google.cloud" % "google-cloud-redis" % "2.106.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-redis/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-redis.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-redis/2.105.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-redis/2.106.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-resourcemanager/README.md b/java-resourcemanager/README.md index 25a6c4b57a6e..f0ad53792e8f 100644 --- a/java-resourcemanager/README.md +++ b/java-resourcemanager/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-resourcemanager - 1.104.0 + 1.105.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-resourcemanager' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-resourcemanager:1.104.0' +implementation 'com.google.cloud:google-cloud-resourcemanager:1.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-resourcemanager" % "1.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-resourcemanager" % "1.105.0" ``` ## Authentication @@ -323,7 +323,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-resourcemanager/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-resourcemanager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-resourcemanager/1.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-resourcemanager/1.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-retail/README.md b/java-retail/README.md index da68076d1282..108ec5cdd337 100644 --- a/java-retail/README.md +++ b/java-retail/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-retail - 2.104.0 + 2.105.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-retail' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-retail:2.104.0' +implementation 'com.google.cloud:google-cloud-retail:2.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-retail" % "2.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-retail" % "2.105.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-retail/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-retail.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-retail/2.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-retail/2.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-run/README.md b/java-run/README.md index 9ffd2b28e88f..382aa782c203 100644 --- a/java-run/README.md +++ b/java-run/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-run - 0.102.0 + 0.103.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-run' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-run:0.102.0' +implementation 'com.google.cloud:google-cloud-run:0.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-run" % "0.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-run" % "0.103.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-run/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-run.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-run/0.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-run/0.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-saasservicemgmt/README.md b/java-saasservicemgmt/README.md index 6de8f7f3e577..dc88eb9c41b0 100644 --- a/java-saasservicemgmt/README.md +++ b/java-saasservicemgmt/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-saasservicemgmt - 0.32.0 + 0.33.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-saasservicemgmt' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-saasservicemgmt:0.32.0' +implementation 'com.google.cloud:google-cloud-saasservicemgmt:0.33.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-saasservicemgmt" % "0.32.0" +libraryDependencies += "com.google.cloud" % "google-cloud-saasservicemgmt" % "0.33.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-saasservicemgmt/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-saasservicemgmt.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-saasservicemgmt/0.32.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-saasservicemgmt/0.33.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-scheduler/README.md b/java-scheduler/README.md index 915e7dacc0e4..642eb008bb0f 100644 --- a/java-scheduler/README.md +++ b/java-scheduler/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-scheduler - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-scheduler' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-scheduler:2.102.0' +implementation 'com.google.cloud:google-cloud-scheduler:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-scheduler" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-scheduler" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-scheduler/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-scheduler.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-scheduler/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-scheduler/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-secretmanager/README.md b/java-secretmanager/README.md index d2819c02e23d..97e5601c13d3 100644 --- a/java-secretmanager/README.md +++ b/java-secretmanager/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-secretmanager - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-secretmanager' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-secretmanager:2.102.0' +implementation 'com.google.cloud:google-cloud-secretmanager:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-secretmanager" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-secretmanager" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-secretmanager/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-secretmanager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-secretmanager/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-secretmanager/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceClient.java b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceClient.java new file mode 100644 index 000000000000..63dff0ae86a8 --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceClient.java @@ -0,0 +1,1625 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1; + +import com.google.api.core.ApiFuture; +import com.google.api.core.ApiFutures; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.httpjson.longrunning.OperationsClient; +import com.google.api.gax.longrunning.OperationFuture; +import com.google.api.gax.paging.AbstractFixedSizeCollection; +import com.google.api.gax.paging.AbstractPage; +import com.google.api.gax.paging.AbstractPagedListResponse; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.secretmanager.v1.stub.SecretOperationsServiceStub; +import com.google.cloud.secretmanager.v1.stub.SecretOperationsServiceStubSettings; +import com.google.common.util.concurrent.MoreExecutors; +import com.google.longrunning.Operation; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import java.io.IOException; +import java.util.List; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Service Description: Secret Operations Service + * + *

    Manages backups of secrets. Implements a REST model with the following objects: + * + *

      + *
    • [Backup][google.cloud.secretmanager.v1.Backup] + *
    + * + *

    Note: `SecretOperationsService` is a regional service and must be called using regional + * endpoints (`secretmanager.{location}.rep.googleapis.com`). + * + *

    This class provides the ability to make remote calls to the backing service through method + * calls that map to API methods. Sample code to get started: + * + *

    {@code
    + * // This snippet has been automatically generated and should be regarded as a code template only.
    + * // It will require modifications to work:
    + * // - It may require correct/in-range values for request initialization.
    + * // - It may require specifying regional endpoints when creating the service client as shown in
    + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    + * try (SecretOperationsServiceClient secretOperationsServiceClient =
    + *     SecretOperationsServiceClient.create()) {
    + *   BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]");
    + *   Backup response = secretOperationsServiceClient.getBackup(name);
    + * }
    + * }
    + * + *

    Note: close() needs to be called on the SecretOperationsServiceClient object to clean up + * resources such as threads. In the example above, try-with-resources is used, which automatically + * calls close(). + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
    Methods
    MethodDescriptionMethod Variants

    ListBackups

    Lists Backups in a given project and location.

    + *

    Request object method variants only take one parameter, a request object, which must be constructed before the call.

    + *
      + *
    • listBackups(ListBackupsRequest request) + *

    + *

    "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

    + *
      + *
    • listBackups(LocationName parent) + *

    • listBackups(String parent) + *

    + *

    Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

    + *
      + *
    • listBackupsPagedCallable() + *

    • listBackupsCallable() + *

    + *

    GetBackup

    Gets details of a single Backup.

    + *

    Request object method variants only take one parameter, a request object, which must be constructed before the call.

    + *
      + *
    • getBackup(GetBackupRequest request) + *

    + *

    "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

    + *
      + *
    • getBackup(BackupName name) + *

    • getBackup(String name) + *

    + *

    Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

    + *
      + *
    • getBackupCallable() + *

    + *

    CreateBackup

    Creates a new Backup in a given project and location.

    + *

    Request object method variants only take one parameter, a request object, which must be constructed before the call.

    + *
      + *
    • createBackupAsync(CreateBackupRequest request) + *

    + *

    Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

    + *
      + *
    • createBackupAsync(LocationName parent, Backup backup, String backupId) + *

    • createBackupAsync(String parent, Backup backup, String backupId) + *

    + *

    Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

    + *
      + *
    • createBackupOperationCallable() + *

    • createBackupCallable() + *

    + *

    UpdateBackup

    Updates the parameters of a single Backup.

    + *

    Request object method variants only take one parameter, a request object, which must be constructed before the call.

    + *
      + *
    • updateBackupAsync(UpdateBackupRequest request) + *

    + *

    Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

    + *
      + *
    • updateBackupAsync(Backup backup, FieldMask updateMask) + *

    + *

    Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

    + *
      + *
    • updateBackupOperationCallable() + *

    • updateBackupCallable() + *

    + *

    DeleteBackup

    Deletes a single Backup.

    + *

    Request object method variants only take one parameter, a request object, which must be constructed before the call.

    + *
      + *
    • deleteBackupAsync(DeleteBackupRequest request) + *

    + *

    Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

    + *
      + *
    • deleteBackupAsync(BackupName name) + *

    • deleteBackupAsync(String name) + *

    + *

    Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

    + *
      + *
    • deleteBackupOperationCallable() + *

    • deleteBackupCallable() + *

    + *

    RestoreBackup

    Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new* [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the restoration process, and the result of the LRO is the newly created Secret.

    + *

    Request object method variants only take one parameter, a request object, which must be constructed before the call.

    + *
      + *
    • restoreBackupAsync(RestoreBackupRequest request) + *

    + *

    Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service.

    + *
      + *
    • restoreBackupAsync(BackupName name, LocationName destinationSecretParent, String destinationSecretId) + *

    • restoreBackupAsync(BackupName name, ProjectName destinationSecretParent, String destinationSecretId) + *

    • restoreBackupAsync(BackupName name, String destinationSecretParent, String destinationSecretId) + *

    • restoreBackupAsync(String name, LocationName destinationSecretParent, String destinationSecretId) + *

    • restoreBackupAsync(String name, ProjectName destinationSecretParent, String destinationSecretId) + *

    • restoreBackupAsync(String name, String destinationSecretParent, String destinationSecretId) + *

    + *

    Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

    + *
      + *
    • restoreBackupOperationCallable() + *

    • restoreBackupCallable() + *

    + *
    + * + *

    See the individual methods for example code. + * + *

    Many parameters require resource names to be formatted in a particular way. To assist with + * these names, this class includes a format method for each type of name, and additionally a parse + * method to extract the individual identifiers contained within names that are returned. + * + *

    This class can be customized by passing in a custom instance of + * SecretOperationsServiceSettings to create(). For example: + * + *

    To customize credentials: + * + *

    {@code
    + * // This snippet has been automatically generated and should be regarded as a code template only.
    + * // It will require modifications to work:
    + * // - It may require correct/in-range values for request initialization.
    + * // - It may require specifying regional endpoints when creating the service client as shown in
    + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    + * SecretOperationsServiceSettings secretOperationsServiceSettings =
    + *     SecretOperationsServiceSettings.newBuilder()
    + *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
    + *         .build();
    + * SecretOperationsServiceClient secretOperationsServiceClient =
    + *     SecretOperationsServiceClient.create(secretOperationsServiceSettings);
    + * }
    + * + *

    To customize the endpoint: + * + *

    {@code
    + * // This snippet has been automatically generated and should be regarded as a code template only.
    + * // It will require modifications to work:
    + * // - It may require correct/in-range values for request initialization.
    + * // - It may require specifying regional endpoints when creating the service client as shown in
    + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    + * SecretOperationsServiceSettings secretOperationsServiceSettings =
    + *     SecretOperationsServiceSettings.newBuilder().setEndpoint(myEndpoint).build();
    + * SecretOperationsServiceClient secretOperationsServiceClient =
    + *     SecretOperationsServiceClient.create(secretOperationsServiceSettings);
    + * }
    + * + *

    To use REST (HTTP1.1/JSON) transport (instead of gRPC) for sending and receiving requests over + * the wire: + * + *

    {@code
    + * // This snippet has been automatically generated and should be regarded as a code template only.
    + * // It will require modifications to work:
    + * // - It may require correct/in-range values for request initialization.
    + * // - It may require specifying regional endpoints when creating the service client as shown in
    + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    + * SecretOperationsServiceSettings secretOperationsServiceSettings =
    + *     SecretOperationsServiceSettings.newHttpJsonBuilder().build();
    + * SecretOperationsServiceClient secretOperationsServiceClient =
    + *     SecretOperationsServiceClient.create(secretOperationsServiceSettings);
    + * }
    + * + *

    Please refer to the GitHub repository's samples for more quickstart code snippets. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class SecretOperationsServiceClient implements BackgroundResource { + private final @Nullable SecretOperationsServiceSettings settings; + private final SecretOperationsServiceStub stub; + private final OperationsClient httpJsonOperationsClient; + private final com.google.longrunning.OperationsClient operationsClient; + + /** Constructs an instance of SecretOperationsServiceClient with default settings. */ + public static final SecretOperationsServiceClient create() throws IOException { + return create(SecretOperationsServiceSettings.newBuilder().build()); + } + + /** + * Constructs an instance of SecretOperationsServiceClient, using the given settings. The channels + * are created based on the settings passed in, or defaults for any settings that are not set. + */ + public static final SecretOperationsServiceClient create(SecretOperationsServiceSettings settings) + throws IOException { + return new SecretOperationsServiceClient(settings); + } + + /** + * Constructs an instance of SecretOperationsServiceClient, using the given stub for making calls. + * This is for advanced usage - prefer using create(SecretOperationsServiceSettings). + */ + public static final SecretOperationsServiceClient create(SecretOperationsServiceStub stub) { + return new SecretOperationsServiceClient(stub); + } + + /** + * Constructs an instance of SecretOperationsServiceClient, using the given settings. This is + * protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected SecretOperationsServiceClient(SecretOperationsServiceSettings settings) + throws IOException { + this.settings = settings; + this.stub = ((SecretOperationsServiceStubSettings) settings.getStubSettings()).createStub(); + this.operationsClient = + com.google.longrunning.OperationsClient.create(this.stub.getOperationsStub()); + this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); + } + + protected SecretOperationsServiceClient(SecretOperationsServiceStub stub) { + this.settings = null; + this.stub = stub; + this.operationsClient = + com.google.longrunning.OperationsClient.create(this.stub.getOperationsStub()); + this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); + } + + public final @Nullable SecretOperationsServiceSettings getSettings() { + return settings; + } + + public SecretOperationsServiceStub getStub() { + return stub; + } + + /** + * Returns the OperationsClient that can be used to query the status of a long-running operation + * returned by another API method call. + */ + public final com.google.longrunning.OperationsClient getOperationsClient() { + return operationsClient; + } + + /** + * Returns the OperationsClient that can be used to query the status of a long-running operation + * returned by another API method call. + */ + @BetaApi + public final OperationsClient getHttpJsonOperationsClient() { + return httpJsonOperationsClient; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Backups in a given project and location. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
    +   *   for (Backup element : secretOperationsServiceClient.listBackups(parent).iterateAll()) {
    +   *     // doThingsWith(element);
    +   *   }
    +   * }
    +   * }
    + * + * @param parent Required. The resource name of the location associated with the + * [Backups][google.cloud.secretmanager.v1.Backup], in the format + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListBackupsPagedResponse listBackups(@Nullable LocationName parent) { + ListBackupsRequest request = + ListBackupsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listBackups(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Backups in a given project and location. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
    +   *   for (Backup element : secretOperationsServiceClient.listBackups(parent).iterateAll()) {
    +   *     // doThingsWith(element);
    +   *   }
    +   * }
    +   * }
    + * + * @param parent Required. The resource name of the location associated with the + * [Backups][google.cloud.secretmanager.v1.Backup], in the format + * `projects/{project}/locations/{location}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListBackupsPagedResponse listBackups(String parent) { + ListBackupsRequest request = ListBackupsRequest.newBuilder().setParent(parent).build(); + return listBackups(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Backups in a given project and location. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   ListBackupsRequest request =
    +   *       ListBackupsRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .setPageSize(883849137)
    +   *           .setPageToken("pageToken873572522")
    +   *           .setFilter("filter-1274492040")
    +   *           .setOrderBy("orderBy-1207110587")
    +   *           .build();
    +   *   for (Backup element : secretOperationsServiceClient.listBackups(request).iterateAll()) {
    +   *     // doThingsWith(element);
    +   *   }
    +   * }
    +   * }
    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListBackupsPagedResponse listBackups(ListBackupsRequest request) { + return listBackupsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Backups in a given project and location. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   ListBackupsRequest request =
    +   *       ListBackupsRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .setPageSize(883849137)
    +   *           .setPageToken("pageToken873572522")
    +   *           .setFilter("filter-1274492040")
    +   *           .setOrderBy("orderBy-1207110587")
    +   *           .build();
    +   *   ApiFuture future =
    +   *       secretOperationsServiceClient.listBackupsPagedCallable().futureCall(request);
    +   *   // Do something.
    +   *   for (Backup element : future.get().iterateAll()) {
    +   *     // doThingsWith(element);
    +   *   }
    +   * }
    +   * }
    + */ + public final UnaryCallable + listBackupsPagedCallable() { + return stub.listBackupsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Backups in a given project and location. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   ListBackupsRequest request =
    +   *       ListBackupsRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .setPageSize(883849137)
    +   *           .setPageToken("pageToken873572522")
    +   *           .setFilter("filter-1274492040")
    +   *           .setOrderBy("orderBy-1207110587")
    +   *           .build();
    +   *   while (true) {
    +   *     ListBackupsResponse response =
    +   *         secretOperationsServiceClient.listBackupsCallable().call(request);
    +   *     for (Backup element : response.getBackupsList()) {
    +   *       // doThingsWith(element);
    +   *     }
    +   *     String nextPageToken = response.getNextPageToken();
    +   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
    +   *       request = request.toBuilder().setPageToken(nextPageToken).build();
    +   *     } else {
    +   *       break;
    +   *     }
    +   *   }
    +   * }
    +   * }
    + */ + public final UnaryCallable listBackupsCallable() { + return stub.listBackupsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]");
    +   *   Backup response = secretOperationsServiceClient.getBackup(name);
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the [Backup][google.cloud.secretmanager.v1.Backup], + * in the format `projects/{project}/locations/{location}/backups/{backup}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Backup getBackup(@Nullable BackupName name) { + GetBackupRequest request = + GetBackupRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getBackup(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   String name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString();
    +   *   Backup response = secretOperationsServiceClient.getBackup(name);
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the [Backup][google.cloud.secretmanager.v1.Backup], + * in the format `projects/{project}/locations/{location}/backups/{backup}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Backup getBackup(String name) { + GetBackupRequest request = GetBackupRequest.newBuilder().setName(name).build(); + return getBackup(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   GetBackupRequest request =
    +   *       GetBackupRequest.newBuilder()
    +   *           .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString())
    +   *           .build();
    +   *   Backup response = secretOperationsServiceClient.getBackup(request);
    +   * }
    +   * }
    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Backup getBackup(GetBackupRequest request) { + return getBackupCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets details of a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   GetBackupRequest request =
    +   *       GetBackupRequest.newBuilder()
    +   *           .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString())
    +   *           .build();
    +   *   ApiFuture future =
    +   *       secretOperationsServiceClient.getBackupCallable().futureCall(request);
    +   *   // Do something.
    +   *   Backup response = future.get();
    +   * }
    +   * }
    + */ + public final UnaryCallable getBackupCallable() { + return stub.getBackupCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Backup in a given project and location. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
    +   *   Backup backup = Backup.newBuilder().build();
    +   *   String backupId = "backupId2121930365";
    +   *   Backup response =
    +   *       secretOperationsServiceClient.createBackupAsync(parent, backup, backupId).get();
    +   * }
    +   * }
    + * + * @param parent Required. The resource name of the location where the + * [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the format + * `projects/{project}/locations/{location}`. + * @param backup Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to create. + * @param backupId Required. The ID to use for the backup, which will become the final component + * of the backup's resource name. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createBackupAsync( + @Nullable LocationName parent, Backup backup, String backupId) { + CreateBackupRequest request = + CreateBackupRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setBackup(backup) + .setBackupId(backupId) + .build(); + return createBackupAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Backup in a given project and location. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
    +   *   Backup backup = Backup.newBuilder().build();
    +   *   String backupId = "backupId2121930365";
    +   *   Backup response =
    +   *       secretOperationsServiceClient.createBackupAsync(parent, backup, backupId).get();
    +   * }
    +   * }
    + * + * @param parent Required. The resource name of the location where the + * [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the format + * `projects/{project}/locations/{location}`. + * @param backup Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to create. + * @param backupId Required. The ID to use for the backup, which will become the final component + * of the backup's resource name. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createBackupAsync( + String parent, Backup backup, String backupId) { + CreateBackupRequest request = + CreateBackupRequest.newBuilder() + .setParent(parent) + .setBackup(backup) + .setBackupId(backupId) + .build(); + return createBackupAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Backup in a given project and location. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   CreateBackupRequest request =
    +   *       CreateBackupRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .setBackupId("backupId2121930365")
    +   *           .setBackup(Backup.newBuilder().build())
    +   *           .build();
    +   *   Backup response = secretOperationsServiceClient.createBackupAsync(request).get();
    +   * }
    +   * }
    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createBackupAsync( + CreateBackupRequest request) { + return createBackupOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Backup in a given project and location. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   CreateBackupRequest request =
    +   *       CreateBackupRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .setBackupId("backupId2121930365")
    +   *           .setBackup(Backup.newBuilder().build())
    +   *           .build();
    +   *   OperationFuture future =
    +   *       secretOperationsServiceClient.createBackupOperationCallable().futureCall(request);
    +   *   // Do something.
    +   *   Backup response = future.get();
    +   * }
    +   * }
    + */ + public final OperationCallable + createBackupOperationCallable() { + return stub.createBackupOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Backup in a given project and location. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   CreateBackupRequest request =
    +   *       CreateBackupRequest.newBuilder()
    +   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
    +   *           .setBackupId("backupId2121930365")
    +   *           .setBackup(Backup.newBuilder().build())
    +   *           .build();
    +   *   ApiFuture future =
    +   *       secretOperationsServiceClient.createBackupCallable().futureCall(request);
    +   *   // Do something.
    +   *   Operation response = future.get();
    +   * }
    +   * }
    + */ + public final UnaryCallable createBackupCallable() { + return stub.createBackupCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   Backup backup = Backup.newBuilder().build();
    +   *   FieldMask updateMask = FieldMask.newBuilder().build();
    +   *   Backup response = secretOperationsServiceClient.updateBackupAsync(backup, updateMask).get();
    +   * }
    +   * }
    + * + * @param backup Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with + * updated fields. + * @param updateMask Optional. Field mask is used to specify the fields to be overwritten in the + * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update. The fields specified + * in the `update_mask` are relative to the resource, not the full request. A field will be + * overwritten if it is in the mask. If the user does not provide a mask then all fields + * present in the request will be overwritten. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateBackupAsync( + Backup backup, FieldMask updateMask) { + UpdateBackupRequest request = + UpdateBackupRequest.newBuilder().setBackup(backup).setUpdateMask(updateMask).build(); + return updateBackupAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   UpdateBackupRequest request =
    +   *       UpdateBackupRequest.newBuilder()
    +   *           .setUpdateMask(FieldMask.newBuilder().build())
    +   *           .setBackup(Backup.newBuilder().build())
    +   *           .build();
    +   *   Backup response = secretOperationsServiceClient.updateBackupAsync(request).get();
    +   * }
    +   * }
    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateBackupAsync( + UpdateBackupRequest request) { + return updateBackupOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   UpdateBackupRequest request =
    +   *       UpdateBackupRequest.newBuilder()
    +   *           .setUpdateMask(FieldMask.newBuilder().build())
    +   *           .setBackup(Backup.newBuilder().build())
    +   *           .build();
    +   *   OperationFuture future =
    +   *       secretOperationsServiceClient.updateBackupOperationCallable().futureCall(request);
    +   *   // Do something.
    +   *   Backup response = future.get();
    +   * }
    +   * }
    + */ + public final OperationCallable + updateBackupOperationCallable() { + return stub.updateBackupOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the parameters of a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   UpdateBackupRequest request =
    +   *       UpdateBackupRequest.newBuilder()
    +   *           .setUpdateMask(FieldMask.newBuilder().build())
    +   *           .setBackup(Backup.newBuilder().build())
    +   *           .build();
    +   *   ApiFuture future =
    +   *       secretOperationsServiceClient.updateBackupCallable().futureCall(request);
    +   *   // Do something.
    +   *   Operation response = future.get();
    +   * }
    +   * }
    + */ + public final UnaryCallable updateBackupCallable() { + return stub.updateBackupCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]");
    +   *   secretOperationsServiceClient.deleteBackupAsync(name).get();
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the [Backup][google.cloud.secretmanager.v1.Backup] + * to delete, in the format `projects/{project}/locations/{location}/backups/{backup}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteBackupAsync( + @Nullable BackupName name) { + DeleteBackupRequest request = + DeleteBackupRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return deleteBackupAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   String name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString();
    +   *   secretOperationsServiceClient.deleteBackupAsync(name).get();
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the [Backup][google.cloud.secretmanager.v1.Backup] + * to delete, in the format `projects/{project}/locations/{location}/backups/{backup}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteBackupAsync(String name) { + DeleteBackupRequest request = DeleteBackupRequest.newBuilder().setName(name).build(); + return deleteBackupAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   DeleteBackupRequest request =
    +   *       DeleteBackupRequest.newBuilder()
    +   *           .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString())
    +   *           .setEtag("etag3123477")
    +   *           .build();
    +   *   secretOperationsServiceClient.deleteBackupAsync(request).get();
    +   * }
    +   * }
    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteBackupAsync( + DeleteBackupRequest request) { + return deleteBackupOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   DeleteBackupRequest request =
    +   *       DeleteBackupRequest.newBuilder()
    +   *           .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString())
    +   *           .setEtag("etag3123477")
    +   *           .build();
    +   *   OperationFuture future =
    +   *       secretOperationsServiceClient.deleteBackupOperationCallable().futureCall(request);
    +   *   // Do something.
    +   *   future.get();
    +   * }
    +   * }
    + */ + public final OperationCallable + deleteBackupOperationCallable() { + return stub.deleteBackupOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a single Backup. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   DeleteBackupRequest request =
    +   *       DeleteBackupRequest.newBuilder()
    +   *           .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString())
    +   *           .setEtag("etag3123477")
    +   *           .build();
    +   *   ApiFuture future =
    +   *       secretOperationsServiceClient.deleteBackupCallable().futureCall(request);
    +   *   // Do something.
    +   *   future.get();
    +   * }
    +   * }
    + */ + public final UnaryCallable deleteBackupCallable() { + return stub.deleteBackupCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given + * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new* + * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the restoration + * process, and the result of the LRO is the newly created Secret. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]");
    +   *   LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]");
    +   *   String destinationSecretId = "destinationSecretId171779609";
    +   *   Secret response =
    +   *       secretOperationsServiceClient
    +   *           .restoreBackupAsync(name, destinationSecretParent, destinationSecretId)
    +   *           .get();
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the [Backup][google.cloud.secretmanager.v1.Backup] + * to restore from. Format: `projects/{project}/locations/{location}/backups/{backup}` + * @param destinationSecretParent Required. Parent of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. Formats: - + * `projects/{project}/locations/{location}` (for regional secrets) - `projects/{project}` + * (for global secrets) + * @param destinationSecretId Required. ID of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. This must be + * unique within the project. + *

    A secret ID is a string with a maximum length of 255 characters and can contain + * uppercase and lowercase letters, numerals, and the hyphen (`-`) and underscore (`_`) + * characters. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture restoreBackupAsync( + @Nullable BackupName name, + @Nullable LocationName destinationSecretParent, + String destinationSecretId) { + RestoreBackupRequest request = + RestoreBackupRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .setDestinationSecretParent( + destinationSecretParent == null ? null : destinationSecretParent.toString()) + .setDestinationSecretId(destinationSecretId) + .build(); + return restoreBackupAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given + * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new* + * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the restoration + * process, and the result of the LRO is the newly created Secret. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]");
    +   *   ProjectName destinationSecretParent = ProjectName.of("[PROJECT]");
    +   *   String destinationSecretId = "destinationSecretId171779609";
    +   *   Secret response =
    +   *       secretOperationsServiceClient
    +   *           .restoreBackupAsync(name, destinationSecretParent, destinationSecretId)
    +   *           .get();
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the [Backup][google.cloud.secretmanager.v1.Backup] + * to restore from. Format: `projects/{project}/locations/{location}/backups/{backup}` + * @param destinationSecretParent Required. Parent of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. Formats: - + * `projects/{project}/locations/{location}` (for regional secrets) - `projects/{project}` + * (for global secrets) + * @param destinationSecretId Required. ID of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. This must be + * unique within the project. + *

    A secret ID is a string with a maximum length of 255 characters and can contain + * uppercase and lowercase letters, numerals, and the hyphen (`-`) and underscore (`_`) + * characters. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture restoreBackupAsync( + @Nullable BackupName name, + @Nullable ProjectName destinationSecretParent, + String destinationSecretId) { + RestoreBackupRequest request = + RestoreBackupRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .setDestinationSecretParent( + destinationSecretParent == null ? null : destinationSecretParent.toString()) + .setDestinationSecretId(destinationSecretId) + .build(); + return restoreBackupAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given + * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new* + * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the restoration + * process, and the result of the LRO is the newly created Secret. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]");
    +   *   String destinationSecretParent = ProjectName.of("[PROJECT]").toString();
    +   *   String destinationSecretId = "destinationSecretId171779609";
    +   *   Secret response =
    +   *       secretOperationsServiceClient
    +   *           .restoreBackupAsync(name, destinationSecretParent, destinationSecretId)
    +   *           .get();
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the [Backup][google.cloud.secretmanager.v1.Backup] + * to restore from. Format: `projects/{project}/locations/{location}/backups/{backup}` + * @param destinationSecretParent Required. Parent of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. Formats: - + * `projects/{project}/locations/{location}` (for regional secrets) - `projects/{project}` + * (for global secrets) + * @param destinationSecretId Required. ID of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. This must be + * unique within the project. + *

    A secret ID is a string with a maximum length of 255 characters and can contain + * uppercase and lowercase letters, numerals, and the hyphen (`-`) and underscore (`_`) + * characters. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture restoreBackupAsync( + @Nullable BackupName name, String destinationSecretParent, String destinationSecretId) { + RestoreBackupRequest request = + RestoreBackupRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .setDestinationSecretParent(destinationSecretParent) + .setDestinationSecretId(destinationSecretId) + .build(); + return restoreBackupAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given + * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new* + * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the restoration + * process, and the result of the LRO is the newly created Secret. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   String name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString();
    +   *   LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]");
    +   *   String destinationSecretId = "destinationSecretId171779609";
    +   *   Secret response =
    +   *       secretOperationsServiceClient
    +   *           .restoreBackupAsync(name, destinationSecretParent, destinationSecretId)
    +   *           .get();
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the [Backup][google.cloud.secretmanager.v1.Backup] + * to restore from. Format: `projects/{project}/locations/{location}/backups/{backup}` + * @param destinationSecretParent Required. Parent of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. Formats: - + * `projects/{project}/locations/{location}` (for regional secrets) - `projects/{project}` + * (for global secrets) + * @param destinationSecretId Required. ID of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. This must be + * unique within the project. + *

    A secret ID is a string with a maximum length of 255 characters and can contain + * uppercase and lowercase letters, numerals, and the hyphen (`-`) and underscore (`_`) + * characters. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture restoreBackupAsync( + String name, @Nullable LocationName destinationSecretParent, String destinationSecretId) { + RestoreBackupRequest request = + RestoreBackupRequest.newBuilder() + .setName(name) + .setDestinationSecretParent( + destinationSecretParent == null ? null : destinationSecretParent.toString()) + .setDestinationSecretId(destinationSecretId) + .build(); + return restoreBackupAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given + * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new* + * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the restoration + * process, and the result of the LRO is the newly created Secret. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   String name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString();
    +   *   ProjectName destinationSecretParent = ProjectName.of("[PROJECT]");
    +   *   String destinationSecretId = "destinationSecretId171779609";
    +   *   Secret response =
    +   *       secretOperationsServiceClient
    +   *           .restoreBackupAsync(name, destinationSecretParent, destinationSecretId)
    +   *           .get();
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the [Backup][google.cloud.secretmanager.v1.Backup] + * to restore from. Format: `projects/{project}/locations/{location}/backups/{backup}` + * @param destinationSecretParent Required. Parent of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. Formats: - + * `projects/{project}/locations/{location}` (for regional secrets) - `projects/{project}` + * (for global secrets) + * @param destinationSecretId Required. ID of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. This must be + * unique within the project. + *

    A secret ID is a string with a maximum length of 255 characters and can contain + * uppercase and lowercase letters, numerals, and the hyphen (`-`) and underscore (`_`) + * characters. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture restoreBackupAsync( + String name, @Nullable ProjectName destinationSecretParent, String destinationSecretId) { + RestoreBackupRequest request = + RestoreBackupRequest.newBuilder() + .setName(name) + .setDestinationSecretParent( + destinationSecretParent == null ? null : destinationSecretParent.toString()) + .setDestinationSecretId(destinationSecretId) + .build(); + return restoreBackupAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given + * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new* + * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the restoration + * process, and the result of the LRO is the newly created Secret. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   String name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString();
    +   *   String destinationSecretParent = ProjectName.of("[PROJECT]").toString();
    +   *   String destinationSecretId = "destinationSecretId171779609";
    +   *   Secret response =
    +   *       secretOperationsServiceClient
    +   *           .restoreBackupAsync(name, destinationSecretParent, destinationSecretId)
    +   *           .get();
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the [Backup][google.cloud.secretmanager.v1.Backup] + * to restore from. Format: `projects/{project}/locations/{location}/backups/{backup}` + * @param destinationSecretParent Required. Parent of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. Formats: - + * `projects/{project}/locations/{location}` (for regional secrets) - `projects/{project}` + * (for global secrets) + * @param destinationSecretId Required. ID of the new + * [Secret][google.cloud.secretmanager.v1.Secret] to be created from this backup. This must be + * unique within the project. + *

    A secret ID is a string with a maximum length of 255 characters and can contain + * uppercase and lowercase letters, numerals, and the hyphen (`-`) and underscore (`_`) + * characters. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture restoreBackupAsync( + String name, String destinationSecretParent, String destinationSecretId) { + RestoreBackupRequest request = + RestoreBackupRequest.newBuilder() + .setName(name) + .setDestinationSecretParent(destinationSecretParent) + .setDestinationSecretId(destinationSecretId) + .build(); + return restoreBackupAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given + * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new* + * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the restoration + * process, and the result of the LRO is the newly created Secret. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   RestoreBackupRequest request =
    +   *       RestoreBackupRequest.newBuilder()
    +   *           .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString())
    +   *           .setDestinationSecretParent(ProjectName.of("[PROJECT]").toString())
    +   *           .setDestinationSecretId("destinationSecretId171779609")
    +   *           .setKmsKeyName(
    +   *               CryptoKeyName.of("[PROJECT]", "[LOCATION]", "[KEY_RING]", "[CRYPTO_KEY]")
    +   *                   .toString())
    +   *           .build();
    +   *   Secret response = secretOperationsServiceClient.restoreBackupAsync(request).get();
    +   * }
    +   * }
    + * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture restoreBackupAsync( + RestoreBackupRequest request) { + return restoreBackupOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given + * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new* + * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the restoration + * process, and the result of the LRO is the newly created Secret. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   RestoreBackupRequest request =
    +   *       RestoreBackupRequest.newBuilder()
    +   *           .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString())
    +   *           .setDestinationSecretParent(ProjectName.of("[PROJECT]").toString())
    +   *           .setDestinationSecretId("destinationSecretId171779609")
    +   *           .setKmsKeyName(
    +   *               CryptoKeyName.of("[PROJECT]", "[LOCATION]", "[KEY_RING]", "[CRYPTO_KEY]")
    +   *                   .toString())
    +   *           .build();
    +   *   OperationFuture future =
    +   *       secretOperationsServiceClient.restoreBackupOperationCallable().futureCall(request);
    +   *   // Do something.
    +   *   Secret response = future.get();
    +   * }
    +   * }
    + */ + public final OperationCallable + restoreBackupOperationCallable() { + return stub.restoreBackupOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given + * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new* + * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the restoration + * process, and the result of the LRO is the newly created Secret. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (SecretOperationsServiceClient secretOperationsServiceClient =
    +   *     SecretOperationsServiceClient.create()) {
    +   *   RestoreBackupRequest request =
    +   *       RestoreBackupRequest.newBuilder()
    +   *           .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString())
    +   *           .setDestinationSecretParent(ProjectName.of("[PROJECT]").toString())
    +   *           .setDestinationSecretId("destinationSecretId171779609")
    +   *           .setKmsKeyName(
    +   *               CryptoKeyName.of("[PROJECT]", "[LOCATION]", "[KEY_RING]", "[CRYPTO_KEY]")
    +   *                   .toString())
    +   *           .build();
    +   *   ApiFuture future =
    +   *       secretOperationsServiceClient.restoreBackupCallable().futureCall(request);
    +   *   // Do something.
    +   *   Operation response = future.get();
    +   * }
    +   * }
    + */ + public final UnaryCallable restoreBackupCallable() { + return stub.restoreBackupCallable(); + } + + @Override + public final void close() { + stub.close(); + } + + @Override + public void shutdown() { + stub.shutdown(); + } + + @Override + public boolean isShutdown() { + return stub.isShutdown(); + } + + @Override + public boolean isTerminated() { + return stub.isTerminated(); + } + + @Override + public void shutdownNow() { + stub.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return stub.awaitTermination(duration, unit); + } + + public static class ListBackupsPagedResponse + extends AbstractPagedListResponse< + ListBackupsRequest, + ListBackupsResponse, + Backup, + ListBackupsPage, + ListBackupsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListBackupsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, input -> new ListBackupsPagedResponse(input), MoreExecutors.directExecutor()); + } + + private ListBackupsPagedResponse(ListBackupsPage page) { + super(page, ListBackupsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListBackupsPage + extends AbstractPage { + + private ListBackupsPage( + @Nullable PageContext context, + @Nullable ListBackupsResponse response) { + super(context, response); + } + + private static ListBackupsPage createEmptyPage() { + return new ListBackupsPage(null, null); + } + + @Override + protected ListBackupsPage createPage( + @Nullable PageContext context, + @Nullable ListBackupsResponse response) { + return new ListBackupsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + @Nullable PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListBackupsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListBackupsRequest, + ListBackupsResponse, + Backup, + ListBackupsPage, + ListBackupsFixedSizeCollection> { + + private ListBackupsFixedSizeCollection( + @Nullable List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListBackupsFixedSizeCollection createEmptyCollection() { + return new ListBackupsFixedSizeCollection(null, 0); + } + + @Override + protected ListBackupsFixedSizeCollection createCollection( + @Nullable List pages, int collectionSize) { + return new ListBackupsFixedSizeCollection(pages, collectionSize); + } + } +} diff --git a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceSettings.java b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceSettings.java new file mode 100644 index 000000000000..5e0202816dbf --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceSettings.java @@ -0,0 +1,358 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1; + +import static com.google.cloud.secretmanager.v1.SecretOperationsServiceClient.ListBackupsPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.httpjson.InstantiatingHttpJsonChannelProvider; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientSettings; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.cloud.secretmanager.v1.stub.SecretOperationsServiceStubSettings; +import com.google.longrunning.Operation; +import com.google.protobuf.Empty; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link SecretOperationsServiceClient}. + * + *

    The default instance has everything set to sensible defaults: + * + *

      + *
    • The default service address (secretmanager.googleapis.com) and default port (443) are used. + *
    • Credentials are acquired automatically through Application Default Credentials. + *
    • Retries are configured for idempotent methods but not for non-idempotent methods. + *
    + * + *

    The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. + * + *

    For example, to set the + * [RetrySettings](https://cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.retrying.RetrySettings) + * of getBackup: + * + *

    {@code
    + * // This snippet has been automatically generated and should be regarded as a code template only.
    + * // It will require modifications to work:
    + * // - It may require correct/in-range values for request initialization.
    + * // - It may require specifying regional endpoints when creating the service client as shown in
    + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    + * SecretOperationsServiceSettings.Builder secretOperationsServiceSettingsBuilder =
    + *     SecretOperationsServiceSettings.newBuilder();
    + * secretOperationsServiceSettingsBuilder
    + *     .getBackupSettings()
    + *     .setRetrySettings(
    + *         secretOperationsServiceSettingsBuilder
    + *             .getBackupSettings()
    + *             .getRetrySettings()
    + *             .toBuilder()
    + *             .setInitialRetryDelayDuration(Duration.ofSeconds(1))
    + *             .setInitialRpcTimeoutDuration(Duration.ofSeconds(5))
    + *             .setMaxAttempts(5)
    + *             .setMaxRetryDelayDuration(Duration.ofSeconds(30))
    + *             .setMaxRpcTimeoutDuration(Duration.ofSeconds(60))
    + *             .setRetryDelayMultiplier(1.3)
    + *             .setRpcTimeoutMultiplier(1.5)
    + *             .setTotalTimeoutDuration(Duration.ofSeconds(300))
    + *             .build());
    + * SecretOperationsServiceSettings secretOperationsServiceSettings =
    + *     secretOperationsServiceSettingsBuilder.build();
    + * }
    + * + * Please refer to the [Client Side Retry + * Guide](https://docs.cloud.google.com/java/docs/client-retries) for additional support in setting + * retries. + * + *

    To configure the RetrySettings of a Long Running Operation method, create an + * OperationTimedPollAlgorithm object and update the RPC's polling algorithm. For example, to + * configure the RetrySettings for createBackup: + * + *

    {@code
    + * // This snippet has been automatically generated and should be regarded as a code template only.
    + * // It will require modifications to work:
    + * // - It may require correct/in-range values for request initialization.
    + * // - It may require specifying regional endpoints when creating the service client as shown in
    + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    + * SecretOperationsServiceSettings.Builder secretOperationsServiceSettingsBuilder =
    + *     SecretOperationsServiceSettings.newBuilder();
    + * TimedRetryAlgorithm timedRetryAlgorithm =
    + *     OperationalTimedPollAlgorithm.create(
    + *         RetrySettings.newBuilder()
    + *             .setInitialRetryDelayDuration(Duration.ofMillis(500))
    + *             .setRetryDelayMultiplier(1.5)
    + *             .setMaxRetryDelayDuration(Duration.ofMillis(5000))
    + *             .setTotalTimeoutDuration(Duration.ofHours(24))
    + *             .build());
    + * secretOperationsServiceSettingsBuilder
    + *     .createClusterOperationSettings()
    + *     .setPollingAlgorithm(timedRetryAlgorithm)
    + *     .build();
    + * }
    + */ +@NullMarked +@Generated("by gapic-generator-java") +public class SecretOperationsServiceSettings + extends ClientSettings { + + /** Returns the object with the settings used for calls to listBackups. */ + public PagedCallSettings + listBackupsSettings() { + return ((SecretOperationsServiceStubSettings) getStubSettings()).listBackupsSettings(); + } + + /** Returns the object with the settings used for calls to getBackup. */ + public UnaryCallSettings getBackupSettings() { + return ((SecretOperationsServiceStubSettings) getStubSettings()).getBackupSettings(); + } + + /** Returns the object with the settings used for calls to createBackup. */ + public UnaryCallSettings createBackupSettings() { + return ((SecretOperationsServiceStubSettings) getStubSettings()).createBackupSettings(); + } + + /** Returns the object with the settings used for calls to createBackup. */ + public OperationCallSettings + createBackupOperationSettings() { + return ((SecretOperationsServiceStubSettings) getStubSettings()) + .createBackupOperationSettings(); + } + + /** Returns the object with the settings used for calls to updateBackup. */ + public UnaryCallSettings updateBackupSettings() { + return ((SecretOperationsServiceStubSettings) getStubSettings()).updateBackupSettings(); + } + + /** Returns the object with the settings used for calls to updateBackup. */ + public OperationCallSettings + updateBackupOperationSettings() { + return ((SecretOperationsServiceStubSettings) getStubSettings()) + .updateBackupOperationSettings(); + } + + /** Returns the object with the settings used for calls to deleteBackup. */ + public UnaryCallSettings deleteBackupSettings() { + return ((SecretOperationsServiceStubSettings) getStubSettings()).deleteBackupSettings(); + } + + /** Returns the object with the settings used for calls to deleteBackup. */ + public OperationCallSettings + deleteBackupOperationSettings() { + return ((SecretOperationsServiceStubSettings) getStubSettings()) + .deleteBackupOperationSettings(); + } + + /** Returns the object with the settings used for calls to restoreBackup. */ + public UnaryCallSettings restoreBackupSettings() { + return ((SecretOperationsServiceStubSettings) getStubSettings()).restoreBackupSettings(); + } + + /** Returns the object with the settings used for calls to restoreBackup. */ + public OperationCallSettings + restoreBackupOperationSettings() { + return ((SecretOperationsServiceStubSettings) getStubSettings()) + .restoreBackupOperationSettings(); + } + + public static final SecretOperationsServiceSettings create( + SecretOperationsServiceStubSettings stub) throws IOException { + return new SecretOperationsServiceSettings.Builder(stub.toBuilder()).build(); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return SecretOperationsServiceStubSettings.defaultExecutorProviderBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return SecretOperationsServiceStubSettings.getDefaultEndpoint(); + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return SecretOperationsServiceStubSettings.getDefaultServiceScopes(); + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return SecretOperationsServiceStubSettings.defaultCredentialsProviderBuilder(); + } + + /** Returns a builder for the default gRPC ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return SecretOperationsServiceStubSettings.defaultGrpcTransportProviderBuilder(); + } + + /** Returns a builder for the default REST ChannelProvider for this service. */ + @BetaApi + public static InstantiatingHttpJsonChannelProvider.Builder + defaultHttpJsonTransportProviderBuilder() { + return SecretOperationsServiceStubSettings.defaultHttpJsonTransportProviderBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return SecretOperationsServiceStubSettings.defaultTransportChannelProvider(); + } + + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return SecretOperationsServiceStubSettings.defaultApiClientHeaderProviderBuilder(); + } + + /** Returns a new gRPC builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new REST builder for this class. */ + public static Builder newHttpJsonBuilder() { + return Builder.createHttpJsonDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(@Nullable ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected SecretOperationsServiceSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + } + + /** Builder for SecretOperationsServiceSettings. */ + public static class Builder + extends ClientSettings.Builder { + + protected Builder() throws IOException { + this(((ClientContext) null)); + } + + protected Builder(@Nullable ClientContext clientContext) { + super(SecretOperationsServiceStubSettings.newBuilder(clientContext)); + } + + protected Builder(SecretOperationsServiceSettings settings) { + super(settings.getStubSettings().toBuilder()); + } + + protected Builder(SecretOperationsServiceStubSettings.Builder stubSettings) { + super(stubSettings); + } + + private static Builder createDefault() { + return new Builder(SecretOperationsServiceStubSettings.newBuilder()); + } + + private static Builder createHttpJsonDefault() { + return new Builder(SecretOperationsServiceStubSettings.newHttpJsonBuilder()); + } + + public SecretOperationsServiceStubSettings.Builder getStubSettingsBuilder() { + return ((SecretOperationsServiceStubSettings.Builder) getStubSettings()); + } + + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

    Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) { + super.applyToAllUnaryMethods( + getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); + return this; + } + + /** Returns the builder for the settings used for calls to listBackups. */ + public PagedCallSettings.Builder< + ListBackupsRequest, ListBackupsResponse, ListBackupsPagedResponse> + listBackupsSettings() { + return getStubSettingsBuilder().listBackupsSettings(); + } + + /** Returns the builder for the settings used for calls to getBackup. */ + public UnaryCallSettings.Builder getBackupSettings() { + return getStubSettingsBuilder().getBackupSettings(); + } + + /** Returns the builder for the settings used for calls to createBackup. */ + public UnaryCallSettings.Builder createBackupSettings() { + return getStubSettingsBuilder().createBackupSettings(); + } + + /** Returns the builder for the settings used for calls to createBackup. */ + public OperationCallSettings.Builder + createBackupOperationSettings() { + return getStubSettingsBuilder().createBackupOperationSettings(); + } + + /** Returns the builder for the settings used for calls to updateBackup. */ + public UnaryCallSettings.Builder updateBackupSettings() { + return getStubSettingsBuilder().updateBackupSettings(); + } + + /** Returns the builder for the settings used for calls to updateBackup. */ + public OperationCallSettings.Builder + updateBackupOperationSettings() { + return getStubSettingsBuilder().updateBackupOperationSettings(); + } + + /** Returns the builder for the settings used for calls to deleteBackup. */ + public UnaryCallSettings.Builder deleteBackupSettings() { + return getStubSettingsBuilder().deleteBackupSettings(); + } + + /** Returns the builder for the settings used for calls to deleteBackup. */ + public OperationCallSettings.Builder + deleteBackupOperationSettings() { + return getStubSettingsBuilder().deleteBackupOperationSettings(); + } + + /** Returns the builder for the settings used for calls to restoreBackup. */ + public UnaryCallSettings.Builder restoreBackupSettings() { + return getStubSettingsBuilder().restoreBackupSettings(); + } + + /** Returns the builder for the settings used for calls to restoreBackup. */ + public OperationCallSettings.Builder + restoreBackupOperationSettings() { + return getStubSettingsBuilder().restoreBackupOperationSettings(); + } + + @Override + public SecretOperationsServiceSettings build() throws IOException { + return new SecretOperationsServiceSettings(this); + } + } +} diff --git a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/gapic_metadata.json b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/gapic_metadata.json index bf49bafdf61e..e1c507531f65 100644 --- a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/gapic_metadata.json +++ b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/gapic_metadata.json @@ -5,6 +5,33 @@ "protoPackage": "google.cloud.secretmanager.v1", "libraryPackage": "com.google.cloud.secretmanager.v1", "services": { + "SecretOperationsService": { + "clients": { + "grpc": { + "libraryClient": "SecretOperationsServiceClient", + "rpcs": { + "CreateBackup": { + "methods": ["createBackupAsync", "createBackupAsync", "createBackupAsync", "createBackupOperationCallable", "createBackupCallable"] + }, + "DeleteBackup": { + "methods": ["deleteBackupAsync", "deleteBackupAsync", "deleteBackupAsync", "deleteBackupOperationCallable", "deleteBackupCallable"] + }, + "GetBackup": { + "methods": ["getBackup", "getBackup", "getBackup", "getBackupCallable"] + }, + "ListBackups": { + "methods": ["listBackups", "listBackups", "listBackups", "listBackupsPagedCallable", "listBackupsCallable"] + }, + "RestoreBackup": { + "methods": ["restoreBackupAsync", "restoreBackupAsync", "restoreBackupAsync", "restoreBackupAsync", "restoreBackupAsync", "restoreBackupAsync", "restoreBackupAsync", "restoreBackupOperationCallable", "restoreBackupCallable"] + }, + "UpdateBackup": { + "methods": ["updateBackupAsync", "updateBackupAsync", "updateBackupOperationCallable", "updateBackupCallable"] + } + } + } + } + }, "SecretManagerService": { "clients": { "grpc": { diff --git a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/package-info.java b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/package-info.java index d9387970760c..ddbbbf96440b 100644 --- a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/package-info.java +++ b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/package-info.java @@ -19,6 +19,34 @@ * *

    The interfaces provided are listed below, along with usage samples. * + *

    ======================= SecretOperationsServiceClient ======================= + * + *

    Service Description: Secret Operations Service + * + *

    Manages backups of secrets. Implements a REST model with the following objects: + * + *

      + *
    • [Backup][google.cloud.secretmanager.v1.Backup] + *
    + * + *

    Note: `SecretOperationsService` is a regional service and must be called using regional + * endpoints (`secretmanager.{location}.rep.googleapis.com`). + * + *

    Sample for SecretOperationsServiceClient: + * + *

    {@code
    + * // This snippet has been automatically generated and should be regarded as a code template only.
    + * // It will require modifications to work:
    + * // - It may require correct/in-range values for request initialization.
    + * // - It may require specifying regional endpoints when creating the service client as shown in
    + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    + * try (SecretOperationsServiceClient secretOperationsServiceClient =
    + *     SecretOperationsServiceClient.create()) {
    + *   BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]");
    + *   Backup response = secretOperationsServiceClient.getBackup(name);
    + * }
    + * }
    + * *

    ======================= SecretManagerServiceClient ======================= * *

    Service Description: Secret Manager Service diff --git a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/GrpcSecretOperationsServiceCallableFactory.java b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/GrpcSecretOperationsServiceCallableFactory.java new file mode 100644 index 000000000000..006206585d74 --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/GrpcSecretOperationsServiceCallableFactory.java @@ -0,0 +1,115 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.stub; + +import com.google.api.gax.grpc.GrpcCallSettings; +import com.google.api.gax.grpc.GrpcCallableFactory; +import com.google.api.gax.grpc.GrpcStubCallableFactory; +import com.google.api.gax.rpc.BatchingCallSettings; +import com.google.api.gax.rpc.BidiStreamingCallable; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientStreamingCallable; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallable; +import com.google.api.gax.rpc.StreamingCallSettings; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.OperationsStub; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC callable factory implementation for the SecretOperationsService service API. + * + *

    This class is for advanced usage. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class GrpcSecretOperationsServiceCallableFactory implements GrpcStubCallableFactory { + + @Override + public UnaryCallable createUnaryCallable( + GrpcCallSettings grpcCallSettings, + UnaryCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createUnaryCallable(grpcCallSettings, callSettings, clientContext); + } + + @Override + public + UnaryCallable createPagedCallable( + GrpcCallSettings grpcCallSettings, + PagedCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createPagedCallable(grpcCallSettings, callSettings, clientContext); + } + + @Override + public UnaryCallable createBatchingCallable( + GrpcCallSettings grpcCallSettings, + BatchingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createBatchingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + OperationCallable createOperationCallable( + GrpcCallSettings grpcCallSettings, + OperationCallSettings callSettings, + ClientContext clientContext, + OperationsStub operationsStub) { + return GrpcCallableFactory.createOperationCallable( + grpcCallSettings, callSettings, clientContext, operationsStub); + } + + @Override + public + BidiStreamingCallable createBidiStreamingCallable( + GrpcCallSettings grpcCallSettings, + StreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createBidiStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + ServerStreamingCallable createServerStreamingCallable( + GrpcCallSettings grpcCallSettings, + ServerStreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createServerStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + ClientStreamingCallable createClientStreamingCallable( + GrpcCallSettings grpcCallSettings, + StreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createClientStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } +} diff --git a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/GrpcSecretOperationsServiceStub.java b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/GrpcSecretOperationsServiceStub.java new file mode 100644 index 000000000000..8a2bc57db2bb --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/GrpcSecretOperationsServiceStub.java @@ -0,0 +1,400 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.stub; + +import static com.google.cloud.secretmanager.v1.SecretOperationsServiceClient.ListBackupsPagedResponse; + +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.core.BackgroundResourceAggregation; +import com.google.api.gax.grpc.GrpcCallSettings; +import com.google.api.gax.grpc.GrpcStubCallableFactory; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.RequestParamsBuilder; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.CreateBackupRequest; +import com.google.cloud.secretmanager.v1.DeleteBackupRequest; +import com.google.cloud.secretmanager.v1.GetBackupRequest; +import com.google.cloud.secretmanager.v1.ListBackupsRequest; +import com.google.cloud.secretmanager.v1.ListBackupsResponse; +import com.google.cloud.secretmanager.v1.OperationMetadata; +import com.google.cloud.secretmanager.v1.RestoreBackupRequest; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.UpdateBackupRequest; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.GrpcOperationsStub; +import com.google.protobuf.Empty; +import io.grpc.MethodDescriptor; +import io.grpc.protobuf.ProtoUtils; +import java.io.IOException; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC stub implementation for the SecretOperationsService service API. + * + *

    This class is for advanced usage and reflects the underlying API directly. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class GrpcSecretOperationsServiceStub extends SecretOperationsServiceStub { + private static final MethodDescriptor + listBackupsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.secretmanager.v1.SecretOperationsService/ListBackups") + .setRequestMarshaller(ProtoUtils.marshaller(ListBackupsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListBackupsResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor getBackupMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.secretmanager.v1.SecretOperationsService/GetBackup") + .setRequestMarshaller(ProtoUtils.marshaller(GetBackupRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Backup.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + createBackupMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.secretmanager.v1.SecretOperationsService/CreateBackup") + .setRequestMarshaller(ProtoUtils.marshaller(CreateBackupRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + updateBackupMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.secretmanager.v1.SecretOperationsService/UpdateBackup") + .setRequestMarshaller(ProtoUtils.marshaller(UpdateBackupRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + deleteBackupMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.secretmanager.v1.SecretOperationsService/DeleteBackup") + .setRequestMarshaller(ProtoUtils.marshaller(DeleteBackupRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + restoreBackupMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.secretmanager.v1.SecretOperationsService/RestoreBackup") + .setRequestMarshaller( + ProtoUtils.marshaller(RestoreBackupRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private final UnaryCallable listBackupsCallable; + private final UnaryCallable + listBackupsPagedCallable; + private final UnaryCallable getBackupCallable; + private final UnaryCallable createBackupCallable; + private final OperationCallable + createBackupOperationCallable; + private final UnaryCallable updateBackupCallable; + private final OperationCallable + updateBackupOperationCallable; + private final UnaryCallable deleteBackupCallable; + private final OperationCallable + deleteBackupOperationCallable; + private final UnaryCallable restoreBackupCallable; + private final OperationCallable + restoreBackupOperationCallable; + + private final BackgroundResource backgroundResources; + private final GrpcOperationsStub operationsStub; + private final GrpcStubCallableFactory callableFactory; + + public static final GrpcSecretOperationsServiceStub create( + SecretOperationsServiceStubSettings settings) throws IOException { + return new GrpcSecretOperationsServiceStub(settings, ClientContext.create(settings)); + } + + public static final GrpcSecretOperationsServiceStub create(ClientContext clientContext) + throws IOException { + return new GrpcSecretOperationsServiceStub( + SecretOperationsServiceStubSettings.newBuilder().build(), clientContext); + } + + public static final GrpcSecretOperationsServiceStub create( + ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { + return new GrpcSecretOperationsServiceStub( + SecretOperationsServiceStubSettings.newBuilder().build(), clientContext, callableFactory); + } + + /** + * Constructs an instance of GrpcSecretOperationsServiceStub, using the given settings. This is + * protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected GrpcSecretOperationsServiceStub( + SecretOperationsServiceStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new GrpcSecretOperationsServiceCallableFactory()); + } + + /** + * Constructs an instance of GrpcSecretOperationsServiceStub, using the given settings. This is + * protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected GrpcSecretOperationsServiceStub( + SecretOperationsServiceStubSettings settings, + ClientContext clientContext, + GrpcStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); + + GrpcCallSettings listBackupsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listBackupsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings getBackupTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getBackupMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings createBackupTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createBackupMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + GrpcCallSettings updateBackupTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateBackupMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("backup.name", String.valueOf(request.getBackup().getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings deleteBackupTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteBackupMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + GrpcCallSettings restoreBackupTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(restoreBackupMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + + this.listBackupsCallable = + callableFactory.createUnaryCallable( + listBackupsTransportSettings, settings.listBackupsSettings(), clientContext); + this.listBackupsPagedCallable = + callableFactory.createPagedCallable( + listBackupsTransportSettings, settings.listBackupsSettings(), clientContext); + this.getBackupCallable = + callableFactory.createUnaryCallable( + getBackupTransportSettings, settings.getBackupSettings(), clientContext); + this.createBackupCallable = + callableFactory.createUnaryCallable( + createBackupTransportSettings, settings.createBackupSettings(), clientContext); + this.createBackupOperationCallable = + callableFactory.createOperationCallable( + createBackupTransportSettings, + settings.createBackupOperationSettings(), + clientContext, + operationsStub); + this.updateBackupCallable = + callableFactory.createUnaryCallable( + updateBackupTransportSettings, settings.updateBackupSettings(), clientContext); + this.updateBackupOperationCallable = + callableFactory.createOperationCallable( + updateBackupTransportSettings, + settings.updateBackupOperationSettings(), + clientContext, + operationsStub); + this.deleteBackupCallable = + callableFactory.createUnaryCallable( + deleteBackupTransportSettings, settings.deleteBackupSettings(), clientContext); + this.deleteBackupOperationCallable = + callableFactory.createOperationCallable( + deleteBackupTransportSettings, + settings.deleteBackupOperationSettings(), + clientContext, + operationsStub); + this.restoreBackupCallable = + callableFactory.createUnaryCallable( + restoreBackupTransportSettings, settings.restoreBackupSettings(), clientContext); + this.restoreBackupOperationCallable = + callableFactory.createOperationCallable( + restoreBackupTransportSettings, + settings.restoreBackupOperationSettings(), + clientContext, + operationsStub); + + this.backgroundResources = + new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + public GrpcOperationsStub getOperationsStub() { + return operationsStub; + } + + @Override + public UnaryCallable listBackupsCallable() { + return listBackupsCallable; + } + + @Override + public UnaryCallable listBackupsPagedCallable() { + return listBackupsPagedCallable; + } + + @Override + public UnaryCallable getBackupCallable() { + return getBackupCallable; + } + + @Override + public UnaryCallable createBackupCallable() { + return createBackupCallable; + } + + @Override + public OperationCallable + createBackupOperationCallable() { + return createBackupOperationCallable; + } + + @Override + public UnaryCallable updateBackupCallable() { + return updateBackupCallable; + } + + @Override + public OperationCallable + updateBackupOperationCallable() { + return updateBackupOperationCallable; + } + + @Override + public UnaryCallable deleteBackupCallable() { + return deleteBackupCallable; + } + + @Override + public OperationCallable + deleteBackupOperationCallable() { + return deleteBackupOperationCallable; + } + + @Override + public UnaryCallable restoreBackupCallable() { + return restoreBackupCallable; + } + + @Override + public OperationCallable + restoreBackupOperationCallable() { + return restoreBackupOperationCallable; + } + + @Override + public final void close() { + try { + backgroundResources.close(); + } catch (RuntimeException e) { + throw e; + } catch (Exception e) { + throw new IllegalStateException("Failed to close resource", e); + } + } + + @Override + public void shutdown() { + backgroundResources.shutdown(); + } + + @Override + public boolean isShutdown() { + return backgroundResources.isShutdown(); + } + + @Override + public boolean isTerminated() { + return backgroundResources.isTerminated(); + } + + @Override + public void shutdownNow() { + backgroundResources.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return backgroundResources.awaitTermination(duration, unit); + } +} diff --git a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/HttpJsonSecretOperationsServiceCallableFactory.java b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/HttpJsonSecretOperationsServiceCallableFactory.java new file mode 100644 index 000000000000..967d82526ca5 --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/HttpJsonSecretOperationsServiceCallableFactory.java @@ -0,0 +1,103 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.stub; + +import com.google.api.gax.httpjson.HttpJsonCallSettings; +import com.google.api.gax.httpjson.HttpJsonCallableFactory; +import com.google.api.gax.httpjson.HttpJsonOperationSnapshotCallable; +import com.google.api.gax.httpjson.HttpJsonStubCallableFactory; +import com.google.api.gax.httpjson.longrunning.stub.OperationsStub; +import com.google.api.gax.rpc.BatchingCallSettings; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallable; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.longrunning.Operation; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * REST callable factory implementation for the SecretOperationsService service API. + * + *

    This class is for advanced usage. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class HttpJsonSecretOperationsServiceCallableFactory + implements HttpJsonStubCallableFactory { + + @Override + public UnaryCallable createUnaryCallable( + HttpJsonCallSettings httpJsonCallSettings, + UnaryCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createUnaryCallable( + httpJsonCallSettings, callSettings, clientContext); + } + + @Override + public + UnaryCallable createPagedCallable( + HttpJsonCallSettings httpJsonCallSettings, + PagedCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createPagedCallable( + httpJsonCallSettings, callSettings, clientContext); + } + + @Override + public UnaryCallable createBatchingCallable( + HttpJsonCallSettings httpJsonCallSettings, + BatchingCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createBatchingCallable( + httpJsonCallSettings, callSettings, clientContext); + } + + @Override + public + OperationCallable createOperationCallable( + HttpJsonCallSettings httpJsonCallSettings, + OperationCallSettings callSettings, + ClientContext clientContext, + OperationsStub operationsStub) { + UnaryCallable innerCallable = + HttpJsonCallableFactory.createBaseUnaryCallable( + httpJsonCallSettings, callSettings.getInitialCallSettings(), clientContext); + HttpJsonOperationSnapshotCallable initialCallable = + new HttpJsonOperationSnapshotCallable( + innerCallable, + httpJsonCallSettings.getMethodDescriptor().getOperationSnapshotFactory()); + return HttpJsonCallableFactory.createOperationCallable( + callSettings, clientContext, operationsStub.longRunningClient(), initialCallable); + } + + @Override + public + ServerStreamingCallable createServerStreamingCallable( + HttpJsonCallSettings httpJsonCallSettings, + ServerStreamingCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createServerStreamingCallable( + httpJsonCallSettings, callSettings, clientContext); + } +} diff --git a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/HttpJsonSecretOperationsServiceStub.java b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/HttpJsonSecretOperationsServiceStub.java new file mode 100644 index 000000000000..670edfe8e32d --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/HttpJsonSecretOperationsServiceStub.java @@ -0,0 +1,631 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.stub; + +import static com.google.cloud.secretmanager.v1.SecretOperationsServiceClient.ListBackupsPagedResponse; + +import com.google.api.HttpRule; +import com.google.api.core.InternalApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.core.BackgroundResourceAggregation; +import com.google.api.gax.httpjson.ApiMethodDescriptor; +import com.google.api.gax.httpjson.HttpJsonCallSettings; +import com.google.api.gax.httpjson.HttpJsonOperationSnapshot; +import com.google.api.gax.httpjson.HttpJsonStubCallableFactory; +import com.google.api.gax.httpjson.ProtoMessageRequestFormatter; +import com.google.api.gax.httpjson.ProtoMessageResponseParser; +import com.google.api.gax.httpjson.ProtoRestSerializer; +import com.google.api.gax.httpjson.longrunning.stub.HttpJsonOperationsStub; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.RequestParamsBuilder; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.CreateBackupRequest; +import com.google.cloud.secretmanager.v1.DeleteBackupRequest; +import com.google.cloud.secretmanager.v1.GetBackupRequest; +import com.google.cloud.secretmanager.v1.ListBackupsRequest; +import com.google.cloud.secretmanager.v1.ListBackupsResponse; +import com.google.cloud.secretmanager.v1.OperationMetadata; +import com.google.cloud.secretmanager.v1.RestoreBackupRequest; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.UpdateBackupRequest; +import com.google.common.collect.ImmutableMap; +import com.google.longrunning.Operation; +import com.google.protobuf.Empty; +import com.google.protobuf.TypeRegistry; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * REST stub implementation for the SecretOperationsService service API. + * + *

    This class is for advanced usage and reflects the underlying API directly. + */ +@NullMarked +@Generated("by gapic-generator-java") +public class HttpJsonSecretOperationsServiceStub extends SecretOperationsServiceStub { + private static final TypeRegistry typeRegistry = + TypeRegistry.newBuilder() + .add(Empty.getDescriptor()) + .add(OperationMetadata.getDescriptor()) + .add(Secret.getDescriptor()) + .add(Backup.getDescriptor()) + .build(); + + private static final ApiMethodDescriptor + listBackupsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.secretmanager.v1.SecretOperationsService/ListBackups") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/backups", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "filter", request.getFilter()); + serializer.putQueryParam(fields, "orderBy", request.getOrderBy()); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListBackupsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor getBackupMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.secretmanager.v1.SecretOperationsService/GetBackup") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/backups/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Backup.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + createBackupMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.secretmanager.v1.SecretOperationsService/CreateBackup") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/backups", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "backupId", request.getBackupId()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("backup", request.getBackup(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (CreateBackupRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + updateBackupMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.secretmanager.v1.SecretOperationsService/UpdateBackup") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{backup.name=projects/*/locations/*/backups/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, "backup.name", request.getBackup().getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("backup", request.getBackup(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (UpdateBackupRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + deleteBackupMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.secretmanager.v1.SecretOperationsService/DeleteBackup") + .setHttpMethod("DELETE") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/backups/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "etag", request.getEtag()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (DeleteBackupRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + restoreBackupMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.secretmanager.v1.SecretOperationsService/RestoreBackup") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/backups/*}:restore", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("*", request.toBuilder().clearName().build(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (RestoreBackupRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private final UnaryCallable listBackupsCallable; + private final UnaryCallable + listBackupsPagedCallable; + private final UnaryCallable getBackupCallable; + private final UnaryCallable createBackupCallable; + private final OperationCallable + createBackupOperationCallable; + private final UnaryCallable updateBackupCallable; + private final OperationCallable + updateBackupOperationCallable; + private final UnaryCallable deleteBackupCallable; + private final OperationCallable + deleteBackupOperationCallable; + private final UnaryCallable restoreBackupCallable; + private final OperationCallable + restoreBackupOperationCallable; + + private final BackgroundResource backgroundResources; + private final HttpJsonOperationsStub httpJsonOperationsStub; + private final HttpJsonStubCallableFactory callableFactory; + + public static final HttpJsonSecretOperationsServiceStub create( + SecretOperationsServiceStubSettings settings) throws IOException { + return new HttpJsonSecretOperationsServiceStub(settings, ClientContext.create(settings)); + } + + public static final HttpJsonSecretOperationsServiceStub create(ClientContext clientContext) + throws IOException { + return new HttpJsonSecretOperationsServiceStub( + SecretOperationsServiceStubSettings.newHttpJsonBuilder().build(), clientContext); + } + + public static final HttpJsonSecretOperationsServiceStub create( + ClientContext clientContext, HttpJsonStubCallableFactory callableFactory) throws IOException { + return new HttpJsonSecretOperationsServiceStub( + SecretOperationsServiceStubSettings.newHttpJsonBuilder().build(), + clientContext, + callableFactory); + } + + /** + * Constructs an instance of HttpJsonSecretOperationsServiceStub, using the given settings. This + * is protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected HttpJsonSecretOperationsServiceStub( + SecretOperationsServiceStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new HttpJsonSecretOperationsServiceCallableFactory()); + } + + /** + * Constructs an instance of HttpJsonSecretOperationsServiceStub, using the given settings. This + * is protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected HttpJsonSecretOperationsServiceStub( + SecretOperationsServiceStubSettings settings, + ClientContext clientContext, + HttpJsonStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + this.httpJsonOperationsStub = + HttpJsonOperationsStub.create( + clientContext, + callableFactory, + typeRegistry, + ImmutableMap.builder() + .put( + "google.longrunning.Operations.CancelOperation", + HttpRule.newBuilder() + .setPost("/v1/{name=projects/*/locations/*/operations/*}:cancel") + .build()) + .put( + "google.longrunning.Operations.GetOperation", + HttpRule.newBuilder() + .setGet("/v1/{name=projects/*/locations/*/operations/*}") + .build()) + .put( + "google.longrunning.Operations.ListOperations", + HttpRule.newBuilder() + .setGet("/v1/{name=projects/*/locations/*}/operations") + .build()) + .build()); + + HttpJsonCallSettings listBackupsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listBackupsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings getBackupTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getBackupMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings createBackupTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createBackupMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getParent()) + .build(); + HttpJsonCallSettings updateBackupTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateBackupMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("backup.name", String.valueOf(request.getBackup().getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings deleteBackupTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(deleteBackupMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + HttpJsonCallSettings restoreBackupTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(restoreBackupMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .setResourceNameExtractor(request -> request.getName()) + .build(); + + this.listBackupsCallable = + callableFactory.createUnaryCallable( + listBackupsTransportSettings, settings.listBackupsSettings(), clientContext); + this.listBackupsPagedCallable = + callableFactory.createPagedCallable( + listBackupsTransportSettings, settings.listBackupsSettings(), clientContext); + this.getBackupCallable = + callableFactory.createUnaryCallable( + getBackupTransportSettings, settings.getBackupSettings(), clientContext); + this.createBackupCallable = + callableFactory.createUnaryCallable( + createBackupTransportSettings, settings.createBackupSettings(), clientContext); + this.createBackupOperationCallable = + callableFactory.createOperationCallable( + createBackupTransportSettings, + settings.createBackupOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.updateBackupCallable = + callableFactory.createUnaryCallable( + updateBackupTransportSettings, settings.updateBackupSettings(), clientContext); + this.updateBackupOperationCallable = + callableFactory.createOperationCallable( + updateBackupTransportSettings, + settings.updateBackupOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.deleteBackupCallable = + callableFactory.createUnaryCallable( + deleteBackupTransportSettings, settings.deleteBackupSettings(), clientContext); + this.deleteBackupOperationCallable = + callableFactory.createOperationCallable( + deleteBackupTransportSettings, + settings.deleteBackupOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.restoreBackupCallable = + callableFactory.createUnaryCallable( + restoreBackupTransportSettings, settings.restoreBackupSettings(), clientContext); + this.restoreBackupOperationCallable = + callableFactory.createOperationCallable( + restoreBackupTransportSettings, + settings.restoreBackupOperationSettings(), + clientContext, + httpJsonOperationsStub); + + this.backgroundResources = + new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + @InternalApi + public static List getMethodDescriptors() { + List methodDescriptors = new ArrayList<>(); + methodDescriptors.add(listBackupsMethodDescriptor); + methodDescriptors.add(getBackupMethodDescriptor); + methodDescriptors.add(createBackupMethodDescriptor); + methodDescriptors.add(updateBackupMethodDescriptor); + methodDescriptors.add(deleteBackupMethodDescriptor); + methodDescriptors.add(restoreBackupMethodDescriptor); + return methodDescriptors; + } + + public HttpJsonOperationsStub getHttpJsonOperationsStub() { + return httpJsonOperationsStub; + } + + @Override + public UnaryCallable listBackupsCallable() { + return listBackupsCallable; + } + + @Override + public UnaryCallable listBackupsPagedCallable() { + return listBackupsPagedCallable; + } + + @Override + public UnaryCallable getBackupCallable() { + return getBackupCallable; + } + + @Override + public UnaryCallable createBackupCallable() { + return createBackupCallable; + } + + @Override + public OperationCallable + createBackupOperationCallable() { + return createBackupOperationCallable; + } + + @Override + public UnaryCallable updateBackupCallable() { + return updateBackupCallable; + } + + @Override + public OperationCallable + updateBackupOperationCallable() { + return updateBackupOperationCallable; + } + + @Override + public UnaryCallable deleteBackupCallable() { + return deleteBackupCallable; + } + + @Override + public OperationCallable + deleteBackupOperationCallable() { + return deleteBackupOperationCallable; + } + + @Override + public UnaryCallable restoreBackupCallable() { + return restoreBackupCallable; + } + + @Override + public OperationCallable + restoreBackupOperationCallable() { + return restoreBackupOperationCallable; + } + + @Override + public final void close() { + try { + backgroundResources.close(); + } catch (RuntimeException e) { + throw e; + } catch (Exception e) { + throw new IllegalStateException("Failed to close resource", e); + } + } + + @Override + public void shutdown() { + backgroundResources.shutdown(); + } + + @Override + public boolean isShutdown() { + return backgroundResources.isShutdown(); + } + + @Override + public boolean isTerminated() { + return backgroundResources.isTerminated(); + } + + @Override + public void shutdownNow() { + backgroundResources.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return backgroundResources.awaitTermination(duration, unit); + } +} diff --git a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/SecretOperationsServiceStub.java b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/SecretOperationsServiceStub.java new file mode 100644 index 000000000000..f0be8fb91c97 --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/SecretOperationsServiceStub.java @@ -0,0 +1,110 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.stub; + +import static com.google.cloud.secretmanager.v1.SecretOperationsServiceClient.ListBackupsPagedResponse; + +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.CreateBackupRequest; +import com.google.cloud.secretmanager.v1.DeleteBackupRequest; +import com.google.cloud.secretmanager.v1.GetBackupRequest; +import com.google.cloud.secretmanager.v1.ListBackupsRequest; +import com.google.cloud.secretmanager.v1.ListBackupsResponse; +import com.google.cloud.secretmanager.v1.OperationMetadata; +import com.google.cloud.secretmanager.v1.RestoreBackupRequest; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.UpdateBackupRequest; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.OperationsStub; +import com.google.protobuf.Empty; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Base stub class for the SecretOperationsService service API. + * + *

    This class is for advanced usage and reflects the underlying API directly. + */ +@NullMarked +@Generated("by gapic-generator-java") +public abstract class SecretOperationsServiceStub implements BackgroundResource { + + public @Nullable OperationsStub getOperationsStub() { + return null; + } + + public com.google.api.gax.httpjson.longrunning.stub.@Nullable OperationsStub + getHttpJsonOperationsStub() { + return null; + } + + public UnaryCallable listBackupsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listBackupsPagedCallable()"); + } + + public UnaryCallable listBackupsCallable() { + throw new UnsupportedOperationException("Not implemented: listBackupsCallable()"); + } + + public UnaryCallable getBackupCallable() { + throw new UnsupportedOperationException("Not implemented: getBackupCallable()"); + } + + public OperationCallable + createBackupOperationCallable() { + throw new UnsupportedOperationException("Not implemented: createBackupOperationCallable()"); + } + + public UnaryCallable createBackupCallable() { + throw new UnsupportedOperationException("Not implemented: createBackupCallable()"); + } + + public OperationCallable + updateBackupOperationCallable() { + throw new UnsupportedOperationException("Not implemented: updateBackupOperationCallable()"); + } + + public UnaryCallable updateBackupCallable() { + throw new UnsupportedOperationException("Not implemented: updateBackupCallable()"); + } + + public OperationCallable + deleteBackupOperationCallable() { + throw new UnsupportedOperationException("Not implemented: deleteBackupOperationCallable()"); + } + + public UnaryCallable deleteBackupCallable() { + throw new UnsupportedOperationException("Not implemented: deleteBackupCallable()"); + } + + public OperationCallable + restoreBackupOperationCallable() { + throw new UnsupportedOperationException("Not implemented: restoreBackupOperationCallable()"); + } + + public UnaryCallable restoreBackupCallable() { + throw new UnsupportedOperationException("Not implemented: restoreBackupCallable()"); + } + + @Override + public abstract void close(); +} diff --git a/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/SecretOperationsServiceStubSettings.java b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/SecretOperationsServiceStubSettings.java new file mode 100644 index 000000000000..11494ba87b21 --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/main/java/com/google/cloud/secretmanager/v1/stub/SecretOperationsServiceStubSettings.java @@ -0,0 +1,745 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.stub; + +import static com.google.cloud.secretmanager.v1.SecretOperationsServiceClient.ListBackupsPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.ApiFuture; +import com.google.api.core.BetaApi; +import com.google.api.core.ObsoleteApi; +import com.google.api.gax.core.GaxProperties; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.GrpcTransportChannel; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.grpc.ProtoOperationTransformers; +import com.google.api.gax.httpjson.GaxHttpJsonProperties; +import com.google.api.gax.httpjson.HttpJsonTransportChannel; +import com.google.api.gax.httpjson.InstantiatingHttpJsonChannelProvider; +import com.google.api.gax.longrunning.OperationSnapshot; +import com.google.api.gax.longrunning.OperationTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.rpc.ApiCallContext; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.LibraryMetadata; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.PagedListDescriptor; +import com.google.api.gax.rpc.PagedListResponseFactory; +import com.google.api.gax.rpc.StatusCode; +import com.google.api.gax.rpc.StubSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.CreateBackupRequest; +import com.google.cloud.secretmanager.v1.DeleteBackupRequest; +import com.google.cloud.secretmanager.v1.GetBackupRequest; +import com.google.cloud.secretmanager.v1.ListBackupsRequest; +import com.google.cloud.secretmanager.v1.ListBackupsResponse; +import com.google.cloud.secretmanager.v1.OperationMetadata; +import com.google.cloud.secretmanager.v1.RestoreBackupRequest; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.UpdateBackupRequest; +import com.google.common.collect.ImmutableList; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableSet; +import com.google.common.collect.Lists; +import com.google.longrunning.Operation; +import com.google.protobuf.Empty; +import java.io.IOException; +import java.time.Duration; +import java.util.List; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link SecretOperationsServiceStub}. + * + *

    The default instance has everything set to sensible defaults: + * + *

      + *
    • The default service address (secretmanager.googleapis.com) and default port (443) are used. + *
    • Credentials are acquired automatically through Application Default Credentials. + *
    • Retries are configured for idempotent methods but not for non-idempotent methods. + *
    + * + *

    The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. + * + *

    For example, to set the + * [RetrySettings](https://cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.retrying.RetrySettings) + * of getBackup: + * + *

    {@code
    + * // This snippet has been automatically generated and should be regarded as a code template only.
    + * // It will require modifications to work:
    + * // - It may require correct/in-range values for request initialization.
    + * // - It may require specifying regional endpoints when creating the service client as shown in
    + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    + * SecretOperationsServiceStubSettings.Builder secretOperationsServiceSettingsBuilder =
    + *     SecretOperationsServiceStubSettings.newBuilder();
    + * secretOperationsServiceSettingsBuilder
    + *     .getBackupSettings()
    + *     .setRetrySettings(
    + *         secretOperationsServiceSettingsBuilder
    + *             .getBackupSettings()
    + *             .getRetrySettings()
    + *             .toBuilder()
    + *             .setInitialRetryDelayDuration(Duration.ofSeconds(1))
    + *             .setInitialRpcTimeoutDuration(Duration.ofSeconds(5))
    + *             .setMaxAttempts(5)
    + *             .setMaxRetryDelayDuration(Duration.ofSeconds(30))
    + *             .setMaxRpcTimeoutDuration(Duration.ofSeconds(60))
    + *             .setRetryDelayMultiplier(1.3)
    + *             .setRpcTimeoutMultiplier(1.5)
    + *             .setTotalTimeoutDuration(Duration.ofSeconds(300))
    + *             .build());
    + * SecretOperationsServiceStubSettings secretOperationsServiceSettings =
    + *     secretOperationsServiceSettingsBuilder.build();
    + * }
    + * + * Please refer to the [Client Side Retry + * Guide](https://docs.cloud.google.com/java/docs/client-retries) for additional support in setting + * retries. + * + *

    To configure the RetrySettings of a Long Running Operation method, create an + * OperationTimedPollAlgorithm object and update the RPC's polling algorithm. For example, to + * configure the RetrySettings for createBackup: + * + *

    {@code
    + * // This snippet has been automatically generated and should be regarded as a code template only.
    + * // It will require modifications to work:
    + * // - It may require correct/in-range values for request initialization.
    + * // - It may require specifying regional endpoints when creating the service client as shown in
    + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    + * SecretOperationsServiceStubSettings.Builder secretOperationsServiceSettingsBuilder =
    + *     SecretOperationsServiceStubSettings.newBuilder();
    + * TimedRetryAlgorithm timedRetryAlgorithm =
    + *     OperationalTimedPollAlgorithm.create(
    + *         RetrySettings.newBuilder()
    + *             .setInitialRetryDelayDuration(Duration.ofMillis(500))
    + *             .setRetryDelayMultiplier(1.5)
    + *             .setMaxRetryDelayDuration(Duration.ofMillis(5000))
    + *             .setTotalTimeoutDuration(Duration.ofHours(24))
    + *             .build());
    + * secretOperationsServiceSettingsBuilder
    + *     .createClusterOperationSettings()
    + *     .setPollingAlgorithm(timedRetryAlgorithm)
    + *     .build();
    + * }
    + */ +@NullMarked +@Generated("by gapic-generator-java") +@SuppressWarnings("CanonicalDuration") +public class SecretOperationsServiceStubSettings + extends StubSettings { + /** The default scopes of the service. */ + private static final ImmutableList DEFAULT_SERVICE_SCOPES = + ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + + private final PagedCallSettings + listBackupsSettings; + private final UnaryCallSettings getBackupSettings; + private final UnaryCallSettings createBackupSettings; + private final OperationCallSettings + createBackupOperationSettings; + private final UnaryCallSettings updateBackupSettings; + private final OperationCallSettings + updateBackupOperationSettings; + private final UnaryCallSettings deleteBackupSettings; + private final OperationCallSettings + deleteBackupOperationSettings; + private final UnaryCallSettings restoreBackupSettings; + private final OperationCallSettings + restoreBackupOperationSettings; + + private static final PagedListDescriptor + LIST_BACKUPS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListBackupsRequest injectToken(ListBackupsRequest payload, String token) { + return ListBackupsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListBackupsRequest injectPageSize(ListBackupsRequest payload, int pageSize) { + return ListBackupsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListBackupsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListBackupsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListBackupsResponse payload) { + return payload.getBackupsList(); + } + }; + + private static final PagedListResponseFactory< + ListBackupsRequest, ListBackupsResponse, ListBackupsPagedResponse> + LIST_BACKUPS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListBackupsRequest, ListBackupsResponse, ListBackupsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListBackupsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_BACKUPS_PAGE_STR_DESC, request, context); + return ListBackupsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + /** Returns the object with the settings used for calls to listBackups. */ + public PagedCallSettings + listBackupsSettings() { + return listBackupsSettings; + } + + /** Returns the object with the settings used for calls to getBackup. */ + public UnaryCallSettings getBackupSettings() { + return getBackupSettings; + } + + /** Returns the object with the settings used for calls to createBackup. */ + public UnaryCallSettings createBackupSettings() { + return createBackupSettings; + } + + /** Returns the object with the settings used for calls to createBackup. */ + public OperationCallSettings + createBackupOperationSettings() { + return createBackupOperationSettings; + } + + /** Returns the object with the settings used for calls to updateBackup. */ + public UnaryCallSettings updateBackupSettings() { + return updateBackupSettings; + } + + /** Returns the object with the settings used for calls to updateBackup. */ + public OperationCallSettings + updateBackupOperationSettings() { + return updateBackupOperationSettings; + } + + /** Returns the object with the settings used for calls to deleteBackup. */ + public UnaryCallSettings deleteBackupSettings() { + return deleteBackupSettings; + } + + /** Returns the object with the settings used for calls to deleteBackup. */ + public OperationCallSettings + deleteBackupOperationSettings() { + return deleteBackupOperationSettings; + } + + /** Returns the object with the settings used for calls to restoreBackup. */ + public UnaryCallSettings restoreBackupSettings() { + return restoreBackupSettings; + } + + /** Returns the object with the settings used for calls to restoreBackup. */ + public OperationCallSettings + restoreBackupOperationSettings() { + return restoreBackupOperationSettings; + } + + public SecretOperationsServiceStub createStub() throws IOException { + if (getTransportChannelProvider() + .getTransportName() + .equals(GrpcTransportChannel.getGrpcTransportName())) { + return GrpcSecretOperationsServiceStub.create(this); + } + if (getTransportChannelProvider() + .getTransportName() + .equals(HttpJsonTransportChannel.getHttpJsonTransportName())) { + return HttpJsonSecretOperationsServiceStub.create(this); + } + throw new UnsupportedOperationException( + String.format( + "Transport not supported: %s", getTransportChannelProvider().getTransportName())); + } + + /** Returns the default service name. */ + @Override + public String getServiceName() { + return "secretmanager"; + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return InstantiatingExecutorProvider.newBuilder(); + } + + /** Returns the default service endpoint. */ + @ObsoleteApi("Use getEndpoint() instead") + public static String getDefaultEndpoint() { + return "secretmanager.googleapis.com:443"; + } + + /** Returns the default mTLS service endpoint. */ + public static String getDefaultMtlsEndpoint() { + return "secretmanager.mtls.googleapis.com:443"; + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return DEFAULT_SERVICE_SCOPES; + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return GoogleCredentialsProvider.newBuilder() + .setScopesToApply(DEFAULT_SERVICE_SCOPES) + .setUseJwtAccessWithScope(true); + } + + /** Returns a builder for the default gRPC ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return InstantiatingGrpcChannelProvider.newBuilder() + .setMaxInboundMessageSize(Integer.MAX_VALUE); + } + + /** Returns a builder for the default REST ChannelProvider for this service. */ + @BetaApi + public static InstantiatingHttpJsonChannelProvider.Builder + defaultHttpJsonTransportProviderBuilder() { + return InstantiatingHttpJsonChannelProvider.newBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return defaultGrpcTransportProviderBuilder().build(); + } + + public static ApiClientHeaderProvider.Builder defaultGrpcApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken( + "gapic", GaxProperties.getLibraryVersion(SecretOperationsServiceStubSettings.class)) + .setTransportToken( + GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); + } + + public static ApiClientHeaderProvider.Builder defaultHttpJsonApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken( + "gapic", GaxProperties.getLibraryVersion(SecretOperationsServiceStubSettings.class)) + .setTransportToken( + GaxHttpJsonProperties.getHttpJsonTokenName(), + GaxHttpJsonProperties.getHttpJsonVersion()); + } + + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return SecretOperationsServiceStubSettings.defaultGrpcApiClientHeaderProviderBuilder(); + } + + /** Returns a new gRPC builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new REST builder for this class. */ + public static Builder newHttpJsonBuilder() { + return Builder.createHttpJsonDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(@Nullable ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected SecretOperationsServiceStubSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + + listBackupsSettings = settingsBuilder.listBackupsSettings().build(); + getBackupSettings = settingsBuilder.getBackupSettings().build(); + createBackupSettings = settingsBuilder.createBackupSettings().build(); + createBackupOperationSettings = settingsBuilder.createBackupOperationSettings().build(); + updateBackupSettings = settingsBuilder.updateBackupSettings().build(); + updateBackupOperationSettings = settingsBuilder.updateBackupOperationSettings().build(); + deleteBackupSettings = settingsBuilder.deleteBackupSettings().build(); + deleteBackupOperationSettings = settingsBuilder.deleteBackupOperationSettings().build(); + restoreBackupSettings = settingsBuilder.restoreBackupSettings().build(); + restoreBackupOperationSettings = settingsBuilder.restoreBackupOperationSettings().build(); + } + + @Override + protected LibraryMetadata getLibraryMetadata() { + return LibraryMetadata.newBuilder() + .setArtifactName("com.google.cloud:google-cloud-secretmanager") + .setRepository("googleapis/google-cloud-java") + .setVersion(Version.VERSION) + .build(); + } + + /** Builder for SecretOperationsServiceStubSettings. */ + public static class Builder + extends StubSettings.Builder { + private final ImmutableList> unaryMethodSettingsBuilders; + private final PagedCallSettings.Builder< + ListBackupsRequest, ListBackupsResponse, ListBackupsPagedResponse> + listBackupsSettings; + private final UnaryCallSettings.Builder getBackupSettings; + private final UnaryCallSettings.Builder createBackupSettings; + private final OperationCallSettings.Builder + createBackupOperationSettings; + private final UnaryCallSettings.Builder updateBackupSettings; + private final OperationCallSettings.Builder + updateBackupOperationSettings; + private final UnaryCallSettings.Builder deleteBackupSettings; + private final OperationCallSettings.Builder + deleteBackupOperationSettings; + private final UnaryCallSettings.Builder restoreBackupSettings; + private final OperationCallSettings.Builder + restoreBackupOperationSettings; + private static final ImmutableMap> + RETRYABLE_CODE_DEFINITIONS; + + static { + ImmutableMap.Builder> definitions = + ImmutableMap.builder(); + definitions.put( + "no_retry_0_codes", ImmutableSet.copyOf(Lists.newArrayList())); + RETRYABLE_CODE_DEFINITIONS = definitions.build(); + } + + private static final ImmutableMap RETRY_PARAM_DEFINITIONS; + + static { + ImmutableMap.Builder definitions = ImmutableMap.builder(); + RetrySettings settings = null; + settings = + RetrySettings.newBuilder() + .setInitialRpcTimeoutDuration(Duration.ofMillis(60000L)) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ofMillis(60000L)) + .setTotalTimeoutDuration(Duration.ofMillis(60000L)) + .build(); + definitions.put("no_retry_0_params", settings); + RETRY_PARAM_DEFINITIONS = definitions.build(); + } + + protected Builder() { + this(((ClientContext) null)); + } + + protected Builder(@Nullable ClientContext clientContext) { + super(clientContext); + + listBackupsSettings = PagedCallSettings.newBuilder(LIST_BACKUPS_PAGE_STR_FACT); + getBackupSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createBackupSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createBackupOperationSettings = OperationCallSettings.newBuilder(); + updateBackupSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateBackupOperationSettings = OperationCallSettings.newBuilder(); + deleteBackupSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteBackupOperationSettings = OperationCallSettings.newBuilder(); + restoreBackupSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + restoreBackupOperationSettings = OperationCallSettings.newBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + listBackupsSettings, + getBackupSettings, + createBackupSettings, + updateBackupSettings, + deleteBackupSettings, + restoreBackupSettings); + initDefaults(this); + } + + protected Builder(SecretOperationsServiceStubSettings settings) { + super(settings); + + listBackupsSettings = settings.listBackupsSettings.toBuilder(); + getBackupSettings = settings.getBackupSettings.toBuilder(); + createBackupSettings = settings.createBackupSettings.toBuilder(); + createBackupOperationSettings = settings.createBackupOperationSettings.toBuilder(); + updateBackupSettings = settings.updateBackupSettings.toBuilder(); + updateBackupOperationSettings = settings.updateBackupOperationSettings.toBuilder(); + deleteBackupSettings = settings.deleteBackupSettings.toBuilder(); + deleteBackupOperationSettings = settings.deleteBackupOperationSettings.toBuilder(); + restoreBackupSettings = settings.restoreBackupSettings.toBuilder(); + restoreBackupOperationSettings = settings.restoreBackupOperationSettings.toBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + listBackupsSettings, + getBackupSettings, + createBackupSettings, + updateBackupSettings, + deleteBackupSettings, + restoreBackupSettings); + } + + private static Builder createDefault() { + Builder builder = new Builder(((ClientContext) null)); + + builder.setTransportChannelProvider(defaultTransportChannelProvider()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); + builder.setMtlsEndpoint(getDefaultMtlsEndpoint()); + builder.setSwitchToMtlsEndpointAllowed(true); + + return initDefaults(builder); + } + + private static Builder createHttpJsonDefault() { + Builder builder = new Builder(((ClientContext) null)); + + builder.setTransportChannelProvider(defaultHttpJsonTransportProviderBuilder().build()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultHttpJsonApiClientHeaderProviderBuilder().build()); + builder.setMtlsEndpoint(getDefaultMtlsEndpoint()); + builder.setSwitchToMtlsEndpointAllowed(true); + + return initDefaults(builder); + } + + private static Builder initDefaults(Builder builder) { + builder + .listBackupsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_0_params")); + + builder + .getBackupSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_0_params")); + + builder + .createBackupSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_0_params")); + + builder + .updateBackupSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_0_params")); + + builder + .deleteBackupSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_0_params")); + + builder + .restoreBackupSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_0_params")); + + builder + .createBackupOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_0_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Backup.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .updateBackupOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_0_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Backup.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .deleteBackupOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_0_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Empty.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + builder + .restoreBackupOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_0_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Secret.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(45000L)) + .setInitialRpcTimeoutDuration(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeoutDuration(Duration.ZERO) + .setTotalTimeoutDuration(Duration.ofMillis(300000L)) + .build())); + + return builder; + } + + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

    Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) { + super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); + return this; + } + + public ImmutableList> unaryMethodSettingsBuilders() { + return unaryMethodSettingsBuilders; + } + + /** Returns the builder for the settings used for calls to listBackups. */ + public PagedCallSettings.Builder< + ListBackupsRequest, ListBackupsResponse, ListBackupsPagedResponse> + listBackupsSettings() { + return listBackupsSettings; + } + + /** Returns the builder for the settings used for calls to getBackup. */ + public UnaryCallSettings.Builder getBackupSettings() { + return getBackupSettings; + } + + /** Returns the builder for the settings used for calls to createBackup. */ + public UnaryCallSettings.Builder createBackupSettings() { + return createBackupSettings; + } + + /** Returns the builder for the settings used for calls to createBackup. */ + public OperationCallSettings.Builder + createBackupOperationSettings() { + return createBackupOperationSettings; + } + + /** Returns the builder for the settings used for calls to updateBackup. */ + public UnaryCallSettings.Builder updateBackupSettings() { + return updateBackupSettings; + } + + /** Returns the builder for the settings used for calls to updateBackup. */ + public OperationCallSettings.Builder + updateBackupOperationSettings() { + return updateBackupOperationSettings; + } + + /** Returns the builder for the settings used for calls to deleteBackup. */ + public UnaryCallSettings.Builder deleteBackupSettings() { + return deleteBackupSettings; + } + + /** Returns the builder for the settings used for calls to deleteBackup. */ + public OperationCallSettings.Builder + deleteBackupOperationSettings() { + return deleteBackupOperationSettings; + } + + /** Returns the builder for the settings used for calls to restoreBackup. */ + public UnaryCallSettings.Builder restoreBackupSettings() { + return restoreBackupSettings; + } + + /** Returns the builder for the settings used for calls to restoreBackup. */ + public OperationCallSettings.Builder + restoreBackupOperationSettings() { + return restoreBackupOperationSettings; + } + + @Override + public SecretOperationsServiceStubSettings build() throws IOException { + return new SecretOperationsServiceStubSettings(this); + } + } +} diff --git a/java-secretmanager/google-cloud-secretmanager/src/main/resources/META-INF/native-image/com.google.cloud.secretmanager.v1/reflect-config.json b/java-secretmanager/google-cloud-secretmanager/src/main/resources/META-INF/native-image/com.google.cloud.secretmanager.v1/reflect-config.json index a3f5fb8be0be..19f3409dee8d 100644 --- a/java-secretmanager/google-cloud-secretmanager/src/main/resources/META-INF/native-image/com.google.cloud.secretmanager.v1/reflect-config.json +++ b/java-secretmanager/google-cloud-secretmanager/src/main/resources/META-INF/native-image/com.google.cloud.secretmanager.v1/reflect-config.json @@ -530,6 +530,33 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.secretmanager.v1.Backup", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.Backup$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.Backup$State", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.secretmanager.v1.CloudSqlSingleUserCredentials", "queryAllDeclaredConstructors": true, @@ -548,6 +575,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.secretmanager.v1.CreateBackupRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.CreateBackupRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.secretmanager.v1.CreateSecretRequest", "queryAllDeclaredConstructors": true, @@ -602,6 +647,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.secretmanager.v1.DeleteBackupRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.DeleteBackupRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.secretmanager.v1.DeleteSecretRequest", "queryAllDeclaredConstructors": true, @@ -692,6 +755,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.secretmanager.v1.GetBackupRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.GetBackupRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.secretmanager.v1.GetSecretRequest", "queryAllDeclaredConstructors": true, @@ -728,6 +809,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.secretmanager.v1.ListBackupsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.ListBackupsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.ListBackupsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.ListBackupsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.secretmanager.v1.ListSecretVersionsRequest", "queryAllDeclaredConstructors": true, @@ -800,6 +917,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.secretmanager.v1.OperationMetadata", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.OperationMetadata$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.OperationMetadata$Progress", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.OperationMetadata$Progress$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.secretmanager.v1.Replication", "queryAllDeclaredConstructors": true, @@ -944,6 +1097,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.secretmanager.v1.RestoreBackupRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.RestoreBackupRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.secretmanager.v1.RotateSecretRequest", "queryAllDeclaredConstructors": true, @@ -1034,6 +1205,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.secretmanager.v1.Secret$State", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.secretmanager.v1.SecretPayload", "queryAllDeclaredConstructors": true, @@ -1097,6 +1277,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.secretmanager.v1.UpdateBackupRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.secretmanager.v1.UpdateBackupRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.secretmanager.v1.UpdateSecretRequest", "queryAllDeclaredConstructors": true, @@ -1376,6 +1574,150 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.longrunning.CancelOperationRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.CancelOperationRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.DeleteOperationRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.DeleteOperationRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.GetOperationRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.GetOperationRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.ListOperationsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.ListOperationsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.ListOperationsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.ListOperationsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.Operation", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.Operation$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.OperationInfo", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.OperationInfo$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.WaitOperationRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.longrunning.WaitOperationRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.protobuf.Any", "queryAllDeclaredConstructors": true, diff --git a/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/MockSecretOperationsService.java b/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/MockSecretOperationsService.java new file mode 100644 index 000000000000..555abb552df1 --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/MockSecretOperationsService.java @@ -0,0 +1,59 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1; + +import com.google.api.core.BetaApi; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.protobuf.AbstractMessage; +import io.grpc.ServerServiceDefinition; +import java.util.List; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockSecretOperationsService implements MockGrpcService { + private final MockSecretOperationsServiceImpl serviceImpl; + + public MockSecretOperationsService() { + serviceImpl = new MockSecretOperationsServiceImpl(); + } + + @Override + public List getRequests() { + return serviceImpl.getRequests(); + } + + @Override + public void addResponse(AbstractMessage response) { + serviceImpl.addResponse(response); + } + + @Override + public void addException(Exception exception) { + serviceImpl.addException(exception); + } + + @Override + public ServerServiceDefinition getServiceDefinition() { + return serviceImpl.bindService(); + } + + @Override + public void reset() { + serviceImpl.reset(); + } +} diff --git a/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/MockSecretOperationsServiceImpl.java b/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/MockSecretOperationsServiceImpl.java new file mode 100644 index 000000000000..6ec9c7f5bb4d --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/MockSecretOperationsServiceImpl.java @@ -0,0 +1,186 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1; + +import com.google.api.core.BetaApi; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceGrpc.SecretOperationsServiceImplBase; +import com.google.longrunning.Operation; +import com.google.protobuf.AbstractMessage; +import io.grpc.stub.StreamObserver; +import java.util.ArrayList; +import java.util.LinkedList; +import java.util.List; +import java.util.Queue; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockSecretOperationsServiceImpl extends SecretOperationsServiceImplBase { + private List requests; + private Queue responses; + + public MockSecretOperationsServiceImpl() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + public List getRequests() { + return requests; + } + + public void addResponse(AbstractMessage response) { + responses.add(response); + } + + public void setResponses(List responses) { + this.responses = new LinkedList(responses); + } + + public void addException(Exception exception) { + responses.add(exception); + } + + public void reset() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + @Override + public void listBackups( + ListBackupsRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListBackupsResponse) { + requests.add(request); + responseObserver.onNext(((ListBackupsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListBackups, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListBackupsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getBackup(GetBackupRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Backup) { + requests.add(request); + responseObserver.onNext(((Backup) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetBackup, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Backup.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void createBackup( + CreateBackupRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method CreateBackup, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void updateBackup( + UpdateBackupRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method UpdateBackup, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteBackup( + DeleteBackupRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method DeleteBackup, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void restoreBackup( + RestoreBackupRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method RestoreBackup, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } +} diff --git a/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceClientHttpJsonTest.java b/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceClientHttpJsonTest.java new file mode 100644 index 000000000000..f7079d02aa91 --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceClientHttpJsonTest.java @@ -0,0 +1,973 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1; + +import static com.google.cloud.secretmanager.v1.SecretOperationsServiceClient.ListBackupsPagedResponse; + +import com.google.api.gax.core.NoCredentialsProvider; +import com.google.api.gax.httpjson.GaxHttpJsonProperties; +import com.google.api.gax.httpjson.testing.MockHttpService; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ApiException; +import com.google.api.gax.rpc.ApiExceptionFactory; +import com.google.api.gax.rpc.InvalidArgumentException; +import com.google.api.gax.rpc.StatusCode; +import com.google.api.gax.rpc.testing.FakeStatusCode; +import com.google.cloud.secretmanager.v1.stub.HttpJsonSecretOperationsServiceStub; +import com.google.common.collect.Lists; +import com.google.iam.v1.ResourcePolicyMember; +import com.google.longrunning.Operation; +import com.google.protobuf.Any; +import com.google.protobuf.Duration; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import com.google.protobuf.Timestamp; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.concurrent.ExecutionException; +import javax.annotation.Generated; +import org.junit.After; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; + +@Generated("by gapic-generator-java") +public class SecretOperationsServiceClientHttpJsonTest { + private static MockHttpService mockService; + private static SecretOperationsServiceClient client; + + @BeforeClass + public static void startStaticServer() throws IOException { + mockService = + new MockHttpService( + HttpJsonSecretOperationsServiceStub.getMethodDescriptors(), + SecretOperationsServiceSettings.getDefaultEndpoint()); + SecretOperationsServiceSettings settings = + SecretOperationsServiceSettings.newHttpJsonBuilder() + .setTransportChannelProvider( + SecretOperationsServiceSettings.defaultHttpJsonTransportProviderBuilder() + .setHttpTransport(mockService) + .build()) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = SecretOperationsServiceClient.create(settings); + } + + @AfterClass + public static void stopServer() { + client.close(); + } + + @Before + public void setUp() {} + + @After + public void tearDown() throws Exception { + mockService.reset(); + } + + @Test + public void listBackupsTest() throws Exception { + Backup responsesElement = Backup.newBuilder().build(); + ListBackupsResponse expectedResponse = + ListBackupsResponse.newBuilder() + .setNextPageToken("") + .addAllBackups(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListBackupsPagedResponse pagedListResponse = client.listBackups(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getBackupsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listBackupsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listBackups(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listBackupsTest2() throws Exception { + Backup responsesElement = Backup.newBuilder().build(); + ListBackupsResponse expectedResponse = + ListBackupsResponse.newBuilder() + .setNextPageToken("") + .addAllBackups(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + + ListBackupsPagedResponse pagedListResponse = client.listBackups(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getBackupsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listBackupsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + client.listBackups(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getBackupTest() throws Exception { + Backup expectedResponse = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + mockService.addResponse(expectedResponse); + + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + + Backup actualResponse = client.getBackup(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getBackupExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + client.getBackup(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getBackupTest2() throws Exception { + Backup expectedResponse = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-1607/locations/location-1607/backups/backup-1607"; + + Backup actualResponse = client.getBackup(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getBackupExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-1607/locations/location-1607/backups/backup-1607"; + client.getBackup(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createBackupTest() throws Exception { + Backup expectedResponse = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Backup backup = Backup.newBuilder().build(); + String backupId = "backupId2121930365"; + + Backup actualResponse = client.createBackupAsync(parent, backup, backupId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createBackupExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Backup backup = Backup.newBuilder().build(); + String backupId = "backupId2121930365"; + client.createBackupAsync(parent, backup, backupId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void createBackupTest2() throws Exception { + Backup expectedResponse = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String parent = "projects/project-5833/locations/location-5833"; + Backup backup = Backup.newBuilder().build(); + String backupId = "backupId2121930365"; + + Backup actualResponse = client.createBackupAsync(parent, backup, backupId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createBackupExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + Backup backup = Backup.newBuilder().build(); + String backupId = "backupId2121930365"; + client.createBackupAsync(parent, backup, backupId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void updateBackupTest() throws Exception { + Backup expectedResponse = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + Backup backup = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Backup actualResponse = client.updateBackupAsync(backup, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void updateBackupExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + Backup backup = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateBackupAsync(backup, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteBackupTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + + client.deleteBackupAsync(name).get(); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteBackupExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + client.deleteBackupAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteBackupTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String name = "projects/project-1607/locations/location-1607/backups/backup-1607"; + + client.deleteBackupAsync(name).get(); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteBackupExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-1607/locations/location-1607/backups/backup-1607"; + client.deleteBackupAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void restoreBackupTest() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]"); + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void restoreBackupExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]"); + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void restoreBackupTest2() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + ProjectName destinationSecretParent = ProjectName.of("[PROJECT]"); + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void restoreBackupExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + ProjectName destinationSecretParent = ProjectName.of("[PROJECT]"); + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void restoreBackupTest3() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + String destinationSecretParent = "destinationSecretParent-929598808"; + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void restoreBackupExceptionTest3() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + String destinationSecretParent = "destinationSecretParent-929598808"; + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void restoreBackupTest4() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String name = "projects/project-1607/locations/location-1607/backups/backup-1607"; + LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]"); + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void restoreBackupExceptionTest4() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-1607/locations/location-1607/backups/backup-1607"; + LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]"); + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void restoreBackupTest5() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String name = "projects/project-1607/locations/location-1607/backups/backup-1607"; + ProjectName destinationSecretParent = ProjectName.of("[PROJECT]"); + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void restoreBackupExceptionTest5() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-1607/locations/location-1607/backups/backup-1607"; + ProjectName destinationSecretParent = ProjectName.of("[PROJECT]"); + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void restoreBackupTest6() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String name = "projects/project-1607/locations/location-1607/backups/backup-1607"; + String destinationSecretParent = "destinationSecretParent-929598808"; + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void restoreBackupExceptionTest6() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-1607/locations/location-1607/backups/backup-1607"; + String destinationSecretParent = "destinationSecretParent-929598808"; + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } +} diff --git a/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceClientTest.java b/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceClientTest.java new file mode 100644 index 000000000000..9c517bb1f28d --- /dev/null +++ b/java-secretmanager/google-cloud-secretmanager/src/test/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceClientTest.java @@ -0,0 +1,922 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1; + +import static com.google.cloud.secretmanager.v1.SecretOperationsServiceClient.ListBackupsPagedResponse; + +import com.google.api.gax.core.NoCredentialsProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.testing.LocalChannelProvider; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.api.gax.grpc.testing.MockServiceHelper; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.InvalidArgumentException; +import com.google.api.gax.rpc.StatusCode; +import com.google.common.collect.Lists; +import com.google.iam.v1.ResourcePolicyMember; +import com.google.longrunning.Operation; +import com.google.protobuf.AbstractMessage; +import com.google.protobuf.Any; +import com.google.protobuf.Duration; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import com.google.protobuf.Timestamp; +import io.grpc.StatusRuntimeException; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.UUID; +import java.util.concurrent.ExecutionException; +import javax.annotation.Generated; +import org.junit.After; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; + +@Generated("by gapic-generator-java") +public class SecretOperationsServiceClientTest { + private static MockSecretOperationsService mockSecretOperationsService; + private static MockServiceHelper mockServiceHelper; + private LocalChannelProvider channelProvider; + private SecretOperationsServiceClient client; + + @BeforeClass + public static void startStaticServer() { + mockSecretOperationsService = new MockSecretOperationsService(); + mockServiceHelper = + new MockServiceHelper( + UUID.randomUUID().toString(), + Arrays.asList(mockSecretOperationsService)); + mockServiceHelper.start(); + } + + @AfterClass + public static void stopServer() { + mockServiceHelper.stop(); + } + + @Before + public void setUp() throws IOException { + mockServiceHelper.reset(); + channelProvider = mockServiceHelper.createChannelProvider(); + SecretOperationsServiceSettings settings = + SecretOperationsServiceSettings.newBuilder() + .setTransportChannelProvider(channelProvider) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = SecretOperationsServiceClient.create(settings); + } + + @After + public void tearDown() throws Exception { + client.close(); + } + + @Test + public void listBackupsTest() throws Exception { + Backup responsesElement = Backup.newBuilder().build(); + ListBackupsResponse expectedResponse = + ListBackupsResponse.newBuilder() + .setNextPageToken("") + .addAllBackups(Arrays.asList(responsesElement)) + .build(); + mockSecretOperationsService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListBackupsPagedResponse pagedListResponse = client.listBackups(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getBackupsList().get(0), resources.get(0)); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListBackupsRequest actualRequest = ((ListBackupsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listBackupsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listBackups(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listBackupsTest2() throws Exception { + Backup responsesElement = Backup.newBuilder().build(); + ListBackupsResponse expectedResponse = + ListBackupsResponse.newBuilder() + .setNextPageToken("") + .addAllBackups(Arrays.asList(responsesElement)) + .build(); + mockSecretOperationsService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListBackupsPagedResponse pagedListResponse = client.listBackups(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getBackupsList().get(0), resources.get(0)); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListBackupsRequest actualRequest = ((ListBackupsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listBackupsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + String parent = "parent-995424086"; + client.listBackups(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getBackupTest() throws Exception { + Backup expectedResponse = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + mockSecretOperationsService.addResponse(expectedResponse); + + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + + Backup actualResponse = client.getBackup(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetBackupRequest actualRequest = ((GetBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getBackupExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + client.getBackup(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getBackupTest2() throws Exception { + Backup expectedResponse = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + mockSecretOperationsService.addResponse(expectedResponse); + + String name = "name3373707"; + + Backup actualResponse = client.getBackup(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetBackupRequest actualRequest = ((GetBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getBackupExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + String name = "name3373707"; + client.getBackup(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createBackupTest() throws Exception { + Backup expectedResponse = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockSecretOperationsService.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Backup backup = Backup.newBuilder().build(); + String backupId = "backupId2121930365"; + + Backup actualResponse = client.createBackupAsync(parent, backup, backupId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateBackupRequest actualRequest = ((CreateBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(backup, actualRequest.getBackup()); + Assert.assertEquals(backupId, actualRequest.getBackupId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createBackupExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Backup backup = Backup.newBuilder().build(); + String backupId = "backupId2121930365"; + client.createBackupAsync(parent, backup, backupId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void createBackupTest2() throws Exception { + Backup expectedResponse = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockSecretOperationsService.addResponse(resultOperation); + + String parent = "parent-995424086"; + Backup backup = Backup.newBuilder().build(); + String backupId = "backupId2121930365"; + + Backup actualResponse = client.createBackupAsync(parent, backup, backupId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateBackupRequest actualRequest = ((CreateBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(backup, actualRequest.getBackup()); + Assert.assertEquals(backupId, actualRequest.getBackupId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createBackupExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + String parent = "parent-995424086"; + Backup backup = Backup.newBuilder().build(); + String backupId = "backupId2121930365"; + client.createBackupAsync(parent, backup, backupId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void updateBackupTest() throws Exception { + Backup expectedResponse = + Backup.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setSourceSecret(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setSourceSecretCreateTime(Timestamp.newBuilder().build()) + .setVersionCount(1102434024) + .putAllLabels(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockSecretOperationsService.addResponse(resultOperation); + + Backup backup = Backup.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Backup actualResponse = client.updateBackupAsync(backup, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateBackupRequest actualRequest = ((UpdateBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(backup, actualRequest.getBackup()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateBackupExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + Backup backup = Backup.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateBackupAsync(backup, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteBackupTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockSecretOperationsService.addResponse(resultOperation); + + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + + client.deleteBackupAsync(name).get(); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteBackupRequest actualRequest = ((DeleteBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteBackupExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + client.deleteBackupAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteBackupTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockSecretOperationsService.addResponse(resultOperation); + + String name = "name3373707"; + + client.deleteBackupAsync(name).get(); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteBackupRequest actualRequest = ((DeleteBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteBackupExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + String name = "name3373707"; + client.deleteBackupAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void restoreBackupTest() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockSecretOperationsService.addResponse(resultOperation); + + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]"); + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + RestoreBackupRequest actualRequest = ((RestoreBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertEquals( + destinationSecretParent.toString(), actualRequest.getDestinationSecretParent()); + Assert.assertEquals(destinationSecretId, actualRequest.getDestinationSecretId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void restoreBackupExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]"); + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void restoreBackupTest2() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockSecretOperationsService.addResponse(resultOperation); + + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + ProjectName destinationSecretParent = ProjectName.of("[PROJECT]"); + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + RestoreBackupRequest actualRequest = ((RestoreBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertEquals( + destinationSecretParent.toString(), actualRequest.getDestinationSecretParent()); + Assert.assertEquals(destinationSecretId, actualRequest.getDestinationSecretId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void restoreBackupExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + ProjectName destinationSecretParent = ProjectName.of("[PROJECT]"); + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void restoreBackupTest3() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockSecretOperationsService.addResponse(resultOperation); + + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + String destinationSecretParent = "destinationSecretParent-929598808"; + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + RestoreBackupRequest actualRequest = ((RestoreBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertEquals(destinationSecretParent, actualRequest.getDestinationSecretParent()); + Assert.assertEquals(destinationSecretId, actualRequest.getDestinationSecretId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void restoreBackupExceptionTest3() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + String destinationSecretParent = "destinationSecretParent-929598808"; + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void restoreBackupTest4() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockSecretOperationsService.addResponse(resultOperation); + + String name = "name3373707"; + LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]"); + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + RestoreBackupRequest actualRequest = ((RestoreBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertEquals( + destinationSecretParent.toString(), actualRequest.getDestinationSecretParent()); + Assert.assertEquals(destinationSecretId, actualRequest.getDestinationSecretId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void restoreBackupExceptionTest4() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + String name = "name3373707"; + LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]"); + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void restoreBackupTest5() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockSecretOperationsService.addResponse(resultOperation); + + String name = "name3373707"; + ProjectName destinationSecretParent = ProjectName.of("[PROJECT]"); + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + RestoreBackupRequest actualRequest = ((RestoreBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertEquals( + destinationSecretParent.toString(), actualRequest.getDestinationSecretParent()); + Assert.assertEquals(destinationSecretId, actualRequest.getDestinationSecretId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void restoreBackupExceptionTest5() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + String name = "name3373707"; + ProjectName destinationSecretParent = ProjectName.of("[PROJECT]"); + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void restoreBackupTest6() throws Exception { + Secret expectedResponse = + Secret.newBuilder() + .setName(SecretName.ofProjectSecretName("[PROJECT]", "[SECRET]").toString()) + .setReplication(Replication.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .addAllTopics(new ArrayList()) + .setEtag("etag3123477") + .setRotation(Rotation.newBuilder().build()) + .putAllVersionAliases(new HashMap()) + .putAllAnnotations(new HashMap()) + .setVersionDestroyTtl(Duration.newBuilder().build()) + .setCustomerManagedEncryption(CustomerManagedEncryption.newBuilder().build()) + .putAllTags(new HashMap()) + .setPolicyMember(ResourcePolicyMember.newBuilder().build()) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("restoreBackupTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockSecretOperationsService.addResponse(resultOperation); + + String name = "name3373707"; + String destinationSecretParent = "destinationSecretParent-929598808"; + String destinationSecretId = "destinationSecretId171779609"; + + Secret actualResponse = + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecretOperationsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + RestoreBackupRequest actualRequest = ((RestoreBackupRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertEquals(destinationSecretParent, actualRequest.getDestinationSecretParent()); + Assert.assertEquals(destinationSecretId, actualRequest.getDestinationSecretId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void restoreBackupExceptionTest6() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecretOperationsService.addException(exception); + + try { + String name = "name3373707"; + String destinationSecretParent = "destinationSecretParent-929598808"; + String destinationSecretId = "destinationSecretId171779609"; + client.restoreBackupAsync(name, destinationSecretParent, destinationSecretId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } +} diff --git a/java-secretmanager/grpc-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceGrpc.java b/java-secretmanager/grpc-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceGrpc.java new file mode 100644 index 000000000000..1a5402d00f20 --- /dev/null +++ b/java-secretmanager/grpc-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/SecretOperationsServiceGrpc.java @@ -0,0 +1,1110 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +package com.google.cloud.secretmanager.v1; + +import static io.grpc.MethodDescriptor.generateFullMethodName; + +/** + * + * + *
    + * Secret Operations Service
    + * Manages backups of secrets. Implements a REST model with the following
    + * objects:
    + * * [Backup][google.cloud.secretmanager.v1.Backup]
    + * Note: `SecretOperationsService` is a regional service and must be called
    + * using regional endpoints (`secretmanager.{location}.rep.googleapis.com`).
    + * 
    + */ +@io.grpc.stub.annotations.GrpcGenerated +public final class SecretOperationsServiceGrpc { + + private SecretOperationsServiceGrpc() {} + + public static final java.lang.String SERVICE_NAME = + "google.cloud.secretmanager.v1.SecretOperationsService"; + + // Static method descriptors that strictly reflect the proto. + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.ListBackupsRequest, + com.google.cloud.secretmanager.v1.ListBackupsResponse> + getListBackupsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListBackups", + requestType = com.google.cloud.secretmanager.v1.ListBackupsRequest.class, + responseType = com.google.cloud.secretmanager.v1.ListBackupsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.ListBackupsRequest, + com.google.cloud.secretmanager.v1.ListBackupsResponse> + getListBackupsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.ListBackupsRequest, + com.google.cloud.secretmanager.v1.ListBackupsResponse> + getListBackupsMethod; + if ((getListBackupsMethod = SecretOperationsServiceGrpc.getListBackupsMethod) == null) { + synchronized (SecretOperationsServiceGrpc.class) { + if ((getListBackupsMethod = SecretOperationsServiceGrpc.getListBackupsMethod) == null) { + SecretOperationsServiceGrpc.getListBackupsMethod = + getListBackupsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListBackups")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.secretmanager.v1.ListBackupsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.secretmanager.v1.ListBackupsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new SecretOperationsServiceMethodDescriptorSupplier("ListBackups")) + .build(); + } + } + } + return getListBackupsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.GetBackupRequest, + com.google.cloud.secretmanager.v1.Backup> + getGetBackupMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetBackup", + requestType = com.google.cloud.secretmanager.v1.GetBackupRequest.class, + responseType = com.google.cloud.secretmanager.v1.Backup.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.GetBackupRequest, + com.google.cloud.secretmanager.v1.Backup> + getGetBackupMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.GetBackupRequest, + com.google.cloud.secretmanager.v1.Backup> + getGetBackupMethod; + if ((getGetBackupMethod = SecretOperationsServiceGrpc.getGetBackupMethod) == null) { + synchronized (SecretOperationsServiceGrpc.class) { + if ((getGetBackupMethod = SecretOperationsServiceGrpc.getGetBackupMethod) == null) { + SecretOperationsServiceGrpc.getGetBackupMethod = + getGetBackupMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetBackup")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.secretmanager.v1.GetBackupRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.secretmanager.v1.Backup.getDefaultInstance())) + .setSchemaDescriptor( + new SecretOperationsServiceMethodDescriptorSupplier("GetBackup")) + .build(); + } + } + } + return getGetBackupMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.CreateBackupRequest, com.google.longrunning.Operation> + getCreateBackupMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateBackup", + requestType = com.google.cloud.secretmanager.v1.CreateBackupRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.CreateBackupRequest, com.google.longrunning.Operation> + getCreateBackupMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.CreateBackupRequest, com.google.longrunning.Operation> + getCreateBackupMethod; + if ((getCreateBackupMethod = SecretOperationsServiceGrpc.getCreateBackupMethod) == null) { + synchronized (SecretOperationsServiceGrpc.class) { + if ((getCreateBackupMethod = SecretOperationsServiceGrpc.getCreateBackupMethod) == null) { + SecretOperationsServiceGrpc.getCreateBackupMethod = + getCreateBackupMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateBackup")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.secretmanager.v1.CreateBackupRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new SecretOperationsServiceMethodDescriptorSupplier("CreateBackup")) + .build(); + } + } + } + return getCreateBackupMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.UpdateBackupRequest, com.google.longrunning.Operation> + getUpdateBackupMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateBackup", + requestType = com.google.cloud.secretmanager.v1.UpdateBackupRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.UpdateBackupRequest, com.google.longrunning.Operation> + getUpdateBackupMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.UpdateBackupRequest, com.google.longrunning.Operation> + getUpdateBackupMethod; + if ((getUpdateBackupMethod = SecretOperationsServiceGrpc.getUpdateBackupMethod) == null) { + synchronized (SecretOperationsServiceGrpc.class) { + if ((getUpdateBackupMethod = SecretOperationsServiceGrpc.getUpdateBackupMethod) == null) { + SecretOperationsServiceGrpc.getUpdateBackupMethod = + getUpdateBackupMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateBackup")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.secretmanager.v1.UpdateBackupRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new SecretOperationsServiceMethodDescriptorSupplier("UpdateBackup")) + .build(); + } + } + } + return getUpdateBackupMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.DeleteBackupRequest, com.google.longrunning.Operation> + getDeleteBackupMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteBackup", + requestType = com.google.cloud.secretmanager.v1.DeleteBackupRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.DeleteBackupRequest, com.google.longrunning.Operation> + getDeleteBackupMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.DeleteBackupRequest, com.google.longrunning.Operation> + getDeleteBackupMethod; + if ((getDeleteBackupMethod = SecretOperationsServiceGrpc.getDeleteBackupMethod) == null) { + synchronized (SecretOperationsServiceGrpc.class) { + if ((getDeleteBackupMethod = SecretOperationsServiceGrpc.getDeleteBackupMethod) == null) { + SecretOperationsServiceGrpc.getDeleteBackupMethod = + getDeleteBackupMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteBackup")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.secretmanager.v1.DeleteBackupRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new SecretOperationsServiceMethodDescriptorSupplier("DeleteBackup")) + .build(); + } + } + } + return getDeleteBackupMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.RestoreBackupRequest, com.google.longrunning.Operation> + getRestoreBackupMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "RestoreBackup", + requestType = com.google.cloud.secretmanager.v1.RestoreBackupRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.RestoreBackupRequest, com.google.longrunning.Operation> + getRestoreBackupMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.secretmanager.v1.RestoreBackupRequest, + com.google.longrunning.Operation> + getRestoreBackupMethod; + if ((getRestoreBackupMethod = SecretOperationsServiceGrpc.getRestoreBackupMethod) == null) { + synchronized (SecretOperationsServiceGrpc.class) { + if ((getRestoreBackupMethod = SecretOperationsServiceGrpc.getRestoreBackupMethod) == null) { + SecretOperationsServiceGrpc.getRestoreBackupMethod = + getRestoreBackupMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "RestoreBackup")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.secretmanager.v1.RestoreBackupRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new SecretOperationsServiceMethodDescriptorSupplier("RestoreBackup")) + .build(); + } + } + } + return getRestoreBackupMethod; + } + + /** Creates a new async stub that supports all call types for the service */ + public static SecretOperationsServiceStub newStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public SecretOperationsServiceStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecretOperationsServiceStub(channel, callOptions); + } + }; + return SecretOperationsServiceStub.newStub(factory, channel); + } + + /** Creates a new blocking-style stub that supports all types of calls on the service */ + public static SecretOperationsServiceBlockingV2Stub newBlockingV2Stub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public SecretOperationsServiceBlockingV2Stub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecretOperationsServiceBlockingV2Stub(channel, callOptions); + } + }; + return SecretOperationsServiceBlockingV2Stub.newStub(factory, channel); + } + + /** + * Creates a new blocking-style stub that supports unary and streaming output calls on the service + */ + public static SecretOperationsServiceBlockingStub newBlockingStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public SecretOperationsServiceBlockingStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecretOperationsServiceBlockingStub(channel, callOptions); + } + }; + return SecretOperationsServiceBlockingStub.newStub(factory, channel); + } + + /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ + public static SecretOperationsServiceFutureStub newFutureStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public SecretOperationsServiceFutureStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecretOperationsServiceFutureStub(channel, callOptions); + } + }; + return SecretOperationsServiceFutureStub.newStub(factory, channel); + } + + /** + * + * + *
    +   * Secret Operations Service
    +   * Manages backups of secrets. Implements a REST model with the following
    +   * objects:
    +   * * [Backup][google.cloud.secretmanager.v1.Backup]
    +   * Note: `SecretOperationsService` is a regional service and must be called
    +   * using regional endpoints (`secretmanager.{location}.rep.googleapis.com`).
    +   * 
    + */ + public interface AsyncService { + + /** + * + * + *
    +     * Lists Backups in a given project and location.
    +     * 
    + */ + default void listBackups( + com.google.cloud.secretmanager.v1.ListBackupsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListBackupsMethod(), responseObserver); + } + + /** + * + * + *
    +     * Gets details of a single Backup.
    +     * 
    + */ + default void getBackup( + com.google.cloud.secretmanager.v1.GetBackupRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetBackupMethod(), responseObserver); + } + + /** + * + * + *
    +     * Creates a new Backup in a given project and location.
    +     * 
    + */ + default void createBackup( + com.google.cloud.secretmanager.v1.CreateBackupRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateBackupMethod(), responseObserver); + } + + /** + * + * + *
    +     * Updates the parameters of a single Backup.
    +     * 
    + */ + default void updateBackup( + com.google.cloud.secretmanager.v1.UpdateBackupRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateBackupMethod(), responseObserver); + } + + /** + * + * + *
    +     * Deletes a single Backup.
    +     * 
    + */ + default void deleteBackup( + com.google.cloud.secretmanager.v1.DeleteBackupRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteBackupMethod(), responseObserver); + } + + /** + * + * + *
    +     * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given
    +     * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new*
    +     * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the
    +     * restoration process, and the result of the LRO is the newly created Secret.
    +     * 
    + */ + default void restoreBackup( + com.google.cloud.secretmanager.v1.RestoreBackupRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getRestoreBackupMethod(), responseObserver); + } + } + + /** + * Base class for the server implementation of the service SecretOperationsService. + * + *
    +   * Secret Operations Service
    +   * Manages backups of secrets. Implements a REST model with the following
    +   * objects:
    +   * * [Backup][google.cloud.secretmanager.v1.Backup]
    +   * Note: `SecretOperationsService` is a regional service and must be called
    +   * using regional endpoints (`secretmanager.{location}.rep.googleapis.com`).
    +   * 
    + */ + public abstract static class SecretOperationsServiceImplBase + implements io.grpc.BindableService, AsyncService { + + @java.lang.Override + public final io.grpc.ServerServiceDefinition bindService() { + return SecretOperationsServiceGrpc.bindService(this); + } + } + + /** + * A stub to allow clients to do asynchronous rpc calls to service SecretOperationsService. + * + *
    +   * Secret Operations Service
    +   * Manages backups of secrets. Implements a REST model with the following
    +   * objects:
    +   * * [Backup][google.cloud.secretmanager.v1.Backup]
    +   * Note: `SecretOperationsService` is a regional service and must be called
    +   * using regional endpoints (`secretmanager.{location}.rep.googleapis.com`).
    +   * 
    + */ + public static final class SecretOperationsServiceStub + extends io.grpc.stub.AbstractAsyncStub { + private SecretOperationsServiceStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected SecretOperationsServiceStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecretOperationsServiceStub(channel, callOptions); + } + + /** + * + * + *
    +     * Lists Backups in a given project and location.
    +     * 
    + */ + public void listBackups( + com.google.cloud.secretmanager.v1.ListBackupsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListBackupsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
    +     * Gets details of a single Backup.
    +     * 
    + */ + public void getBackup( + com.google.cloud.secretmanager.v1.GetBackupRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetBackupMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
    +     * Creates a new Backup in a given project and location.
    +     * 
    + */ + public void createBackup( + com.google.cloud.secretmanager.v1.CreateBackupRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateBackupMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
    +     * Updates the parameters of a single Backup.
    +     * 
    + */ + public void updateBackup( + com.google.cloud.secretmanager.v1.UpdateBackupRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateBackupMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
    +     * Deletes a single Backup.
    +     * 
    + */ + public void deleteBackup( + com.google.cloud.secretmanager.v1.DeleteBackupRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteBackupMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
    +     * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given
    +     * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new*
    +     * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the
    +     * restoration process, and the result of the LRO is the newly created Secret.
    +     * 
    + */ + public void restoreBackup( + com.google.cloud.secretmanager.v1.RestoreBackupRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getRestoreBackupMethod(), getCallOptions()), + request, + responseObserver); + } + } + + /** + * A stub to allow clients to do synchronous rpc calls to service SecretOperationsService. + * + *
    +   * Secret Operations Service
    +   * Manages backups of secrets. Implements a REST model with the following
    +   * objects:
    +   * * [Backup][google.cloud.secretmanager.v1.Backup]
    +   * Note: `SecretOperationsService` is a regional service and must be called
    +   * using regional endpoints (`secretmanager.{location}.rep.googleapis.com`).
    +   * 
    + */ + public static final class SecretOperationsServiceBlockingV2Stub + extends io.grpc.stub.AbstractBlockingStub { + private SecretOperationsServiceBlockingV2Stub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected SecretOperationsServiceBlockingV2Stub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecretOperationsServiceBlockingV2Stub(channel, callOptions); + } + + /** + * + * + *
    +     * Lists Backups in a given project and location.
    +     * 
    + */ + public com.google.cloud.secretmanager.v1.ListBackupsResponse listBackups( + com.google.cloud.secretmanager.v1.ListBackupsRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getListBackupsMethod(), getCallOptions(), request); + } + + /** + * + * + *
    +     * Gets details of a single Backup.
    +     * 
    + */ + public com.google.cloud.secretmanager.v1.Backup getBackup( + com.google.cloud.secretmanager.v1.GetBackupRequest request) throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getGetBackupMethod(), getCallOptions(), request); + } + + /** + * + * + *
    +     * Creates a new Backup in a given project and location.
    +     * 
    + */ + public com.google.longrunning.Operation createBackup( + com.google.cloud.secretmanager.v1.CreateBackupRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getCreateBackupMethod(), getCallOptions(), request); + } + + /** + * + * + *
    +     * Updates the parameters of a single Backup.
    +     * 
    + */ + public com.google.longrunning.Operation updateBackup( + com.google.cloud.secretmanager.v1.UpdateBackupRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getUpdateBackupMethod(), getCallOptions(), request); + } + + /** + * + * + *
    +     * Deletes a single Backup.
    +     * 
    + */ + public com.google.longrunning.Operation deleteBackup( + com.google.cloud.secretmanager.v1.DeleteBackupRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getDeleteBackupMethod(), getCallOptions(), request); + } + + /** + * + * + *
    +     * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given
    +     * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new*
    +     * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the
    +     * restoration process, and the result of the LRO is the newly created Secret.
    +     * 
    + */ + public com.google.longrunning.Operation restoreBackup( + com.google.cloud.secretmanager.v1.RestoreBackupRequest request) + throws io.grpc.StatusException { + return io.grpc.stub.ClientCalls.blockingV2UnaryCall( + getChannel(), getRestoreBackupMethod(), getCallOptions(), request); + } + } + + /** + * A stub to allow clients to do limited synchronous rpc calls to service SecretOperationsService. + * + *
    +   * Secret Operations Service
    +   * Manages backups of secrets. Implements a REST model with the following
    +   * objects:
    +   * * [Backup][google.cloud.secretmanager.v1.Backup]
    +   * Note: `SecretOperationsService` is a regional service and must be called
    +   * using regional endpoints (`secretmanager.{location}.rep.googleapis.com`).
    +   * 
    + */ + public static final class SecretOperationsServiceBlockingStub + extends io.grpc.stub.AbstractBlockingStub { + private SecretOperationsServiceBlockingStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected SecretOperationsServiceBlockingStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecretOperationsServiceBlockingStub(channel, callOptions); + } + + /** + * + * + *
    +     * Lists Backups in a given project and location.
    +     * 
    + */ + public com.google.cloud.secretmanager.v1.ListBackupsResponse listBackups( + com.google.cloud.secretmanager.v1.ListBackupsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListBackupsMethod(), getCallOptions(), request); + } + + /** + * + * + *
    +     * Gets details of a single Backup.
    +     * 
    + */ + public com.google.cloud.secretmanager.v1.Backup getBackup( + com.google.cloud.secretmanager.v1.GetBackupRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetBackupMethod(), getCallOptions(), request); + } + + /** + * + * + *
    +     * Creates a new Backup in a given project and location.
    +     * 
    + */ + public com.google.longrunning.Operation createBackup( + com.google.cloud.secretmanager.v1.CreateBackupRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateBackupMethod(), getCallOptions(), request); + } + + /** + * + * + *
    +     * Updates the parameters of a single Backup.
    +     * 
    + */ + public com.google.longrunning.Operation updateBackup( + com.google.cloud.secretmanager.v1.UpdateBackupRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateBackupMethod(), getCallOptions(), request); + } + + /** + * + * + *
    +     * Deletes a single Backup.
    +     * 
    + */ + public com.google.longrunning.Operation deleteBackup( + com.google.cloud.secretmanager.v1.DeleteBackupRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteBackupMethod(), getCallOptions(), request); + } + + /** + * + * + *
    +     * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given
    +     * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new*
    +     * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the
    +     * restoration process, and the result of the LRO is the newly created Secret.
    +     * 
    + */ + public com.google.longrunning.Operation restoreBackup( + com.google.cloud.secretmanager.v1.RestoreBackupRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getRestoreBackupMethod(), getCallOptions(), request); + } + } + + /** + * A stub to allow clients to do ListenableFuture-style rpc calls to service + * SecretOperationsService. + * + *
    +   * Secret Operations Service
    +   * Manages backups of secrets. Implements a REST model with the following
    +   * objects:
    +   * * [Backup][google.cloud.secretmanager.v1.Backup]
    +   * Note: `SecretOperationsService` is a regional service and must be called
    +   * using regional endpoints (`secretmanager.{location}.rep.googleapis.com`).
    +   * 
    + */ + public static final class SecretOperationsServiceFutureStub + extends io.grpc.stub.AbstractFutureStub { + private SecretOperationsServiceFutureStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected SecretOperationsServiceFutureStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecretOperationsServiceFutureStub(channel, callOptions); + } + + /** + * + * + *
    +     * Lists Backups in a given project and location.
    +     * 
    + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.secretmanager.v1.ListBackupsResponse> + listBackups(com.google.cloud.secretmanager.v1.ListBackupsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListBackupsMethod(), getCallOptions()), request); + } + + /** + * + * + *
    +     * Gets details of a single Backup.
    +     * 
    + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.secretmanager.v1.Backup> + getBackup(com.google.cloud.secretmanager.v1.GetBackupRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetBackupMethod(), getCallOptions()), request); + } + + /** + * + * + *
    +     * Creates a new Backup in a given project and location.
    +     * 
    + */ + public com.google.common.util.concurrent.ListenableFuture + createBackup(com.google.cloud.secretmanager.v1.CreateBackupRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateBackupMethod(), getCallOptions()), request); + } + + /** + * + * + *
    +     * Updates the parameters of a single Backup.
    +     * 
    + */ + public com.google.common.util.concurrent.ListenableFuture + updateBackup(com.google.cloud.secretmanager.v1.UpdateBackupRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateBackupMethod(), getCallOptions()), request); + } + + /** + * + * + *
    +     * Deletes a single Backup.
    +     * 
    + */ + public com.google.common.util.concurrent.ListenableFuture + deleteBackup(com.google.cloud.secretmanager.v1.DeleteBackupRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteBackupMethod(), getCallOptions()), request); + } + + /** + * + * + *
    +     * Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given
    +     * [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new*
    +     * [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the
    +     * restoration process, and the result of the LRO is the newly created Secret.
    +     * 
    + */ + public com.google.common.util.concurrent.ListenableFuture + restoreBackup(com.google.cloud.secretmanager.v1.RestoreBackupRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getRestoreBackupMethod(), getCallOptions()), request); + } + } + + private static final int METHODID_LIST_BACKUPS = 0; + private static final int METHODID_GET_BACKUP = 1; + private static final int METHODID_CREATE_BACKUP = 2; + private static final int METHODID_UPDATE_BACKUP = 3; + private static final int METHODID_DELETE_BACKUP = 4; + private static final int METHODID_RESTORE_BACKUP = 5; + + private static final class MethodHandlers + implements io.grpc.stub.ServerCalls.UnaryMethod, + io.grpc.stub.ServerCalls.ServerStreamingMethod, + io.grpc.stub.ServerCalls.ClientStreamingMethod, + io.grpc.stub.ServerCalls.BidiStreamingMethod { + private final AsyncService serviceImpl; + private final int methodId; + + MethodHandlers(AsyncService serviceImpl, int methodId) { + this.serviceImpl = serviceImpl; + this.methodId = methodId; + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + case METHODID_LIST_BACKUPS: + serviceImpl.listBackups( + (com.google.cloud.secretmanager.v1.ListBackupsRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_GET_BACKUP: + serviceImpl.getBackup( + (com.google.cloud.secretmanager.v1.GetBackupRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_CREATE_BACKUP: + serviceImpl.createBackup( + (com.google.cloud.secretmanager.v1.CreateBackupRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_UPDATE_BACKUP: + serviceImpl.updateBackup( + (com.google.cloud.secretmanager.v1.UpdateBackupRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DELETE_BACKUP: + serviceImpl.deleteBackup( + (com.google.cloud.secretmanager.v1.DeleteBackupRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_RESTORE_BACKUP: + serviceImpl.restoreBackup( + (com.google.cloud.secretmanager.v1.RestoreBackupRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + default: + throw new AssertionError(); + } + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public io.grpc.stub.StreamObserver invoke( + io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + default: + throw new AssertionError(); + } + } + } + + public static final io.grpc.ServerServiceDefinition bindService(AsyncService service) { + return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) + .addMethod( + getListBackupsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.secretmanager.v1.ListBackupsRequest, + com.google.cloud.secretmanager.v1.ListBackupsResponse>( + service, METHODID_LIST_BACKUPS))) + .addMethod( + getGetBackupMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.secretmanager.v1.GetBackupRequest, + com.google.cloud.secretmanager.v1.Backup>(service, METHODID_GET_BACKUP))) + .addMethod( + getCreateBackupMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.secretmanager.v1.CreateBackupRequest, + com.google.longrunning.Operation>(service, METHODID_CREATE_BACKUP))) + .addMethod( + getUpdateBackupMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.secretmanager.v1.UpdateBackupRequest, + com.google.longrunning.Operation>(service, METHODID_UPDATE_BACKUP))) + .addMethod( + getDeleteBackupMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.secretmanager.v1.DeleteBackupRequest, + com.google.longrunning.Operation>(service, METHODID_DELETE_BACKUP))) + .addMethod( + getRestoreBackupMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.secretmanager.v1.RestoreBackupRequest, + com.google.longrunning.Operation>(service, METHODID_RESTORE_BACKUP))) + .build(); + } + + private abstract static class SecretOperationsServiceBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoFileDescriptorSupplier, + io.grpc.protobuf.ProtoServiceDescriptorSupplier { + SecretOperationsServiceBaseDescriptorSupplier() {} + + @java.lang.Override + public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto.getDescriptor(); + } + + @java.lang.Override + public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { + return getFileDescriptor().findServiceByName("SecretOperationsService"); + } + } + + private static final class SecretOperationsServiceFileDescriptorSupplier + extends SecretOperationsServiceBaseDescriptorSupplier { + SecretOperationsServiceFileDescriptorSupplier() {} + } + + private static final class SecretOperationsServiceMethodDescriptorSupplier + extends SecretOperationsServiceBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { + private final java.lang.String methodName; + + SecretOperationsServiceMethodDescriptorSupplier(java.lang.String methodName) { + this.methodName = methodName; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { + return getServiceDescriptor().findMethodByName(methodName); + } + } + + private static volatile io.grpc.ServiceDescriptor serviceDescriptor; + + public static io.grpc.ServiceDescriptor getServiceDescriptor() { + io.grpc.ServiceDescriptor result = serviceDescriptor; + if (result == null) { + synchronized (SecretOperationsServiceGrpc.class) { + result = serviceDescriptor; + if (result == null) { + serviceDescriptor = + result = + io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) + .setSchemaDescriptor(new SecretOperationsServiceFileDescriptorSupplier()) + .addMethod(getListBackupsMethod()) + .addMethod(getGetBackupMethod()) + .addMethod(getCreateBackupMethod()) + .addMethod(getUpdateBackupMethod()) + .addMethod(getDeleteBackupMethod()) + .addMethod(getRestoreBackupMethod()) + .build(); + } + } + } + return result; + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/Backup.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/Backup.java new file mode 100644 index 000000000000..6198dea68520 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/Backup.java @@ -0,0 +1,2828 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +/** + * + * + *
    + * A Backup of a Secret.
    + * Backups are regional resources.
    + * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.Backup} + */ +@com.google.protobuf.Generated +public final class Backup extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.secretmanager.v1.Backup) + BackupOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Backup"); + } + + // Use Backup.newBuilder() to construct. + private Backup(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Backup() { + name_ = ""; + sourceSecret_ = ""; + state_ = 0; + etag_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_Backup_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 7: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_Backup_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.Backup.class, + com.google.cloud.secretmanager.v1.Backup.Builder.class); + } + + /** + * + * + *
    +   * Enum representing the state of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup].
    +   * 
    + * + * Protobuf enum {@code google.cloud.secretmanager.v1.Backup.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
    +     * Backup state is unspecified.
    +     * 
    + * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
    +     * The backup is being created.
    +     * 
    + * + * CREATING = 1; + */ + CREATING(1), + /** + * + * + *
    +     * The backup is active and can be used.
    +     * 
    + * + * ACTIVE = 2; + */ + ACTIVE(2), + /** + * + * + *
    +     * The backup is being updated.
    +     * 
    + * + * UPDATING = 3; + */ + UPDATING(3), + /** + * + * + *
    +     * The backup creation or update failed.
    +     * 
    + * + * FAILED = 4; + */ + FAILED(4), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "State"); + } + + /** + * + * + *
    +     * Backup state is unspecified.
    +     * 
    + * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
    +     * The backup is being created.
    +     * 
    + * + * CREATING = 1; + */ + public static final int CREATING_VALUE = 1; + + /** + * + * + *
    +     * The backup is active and can be used.
    +     * 
    + * + * ACTIVE = 2; + */ + public static final int ACTIVE_VALUE = 2; + + /** + * + * + *
    +     * The backup is being updated.
    +     * 
    + * + * UPDATING = 3; + */ + public static final int UPDATING_VALUE = 3; + + /** + * + * + *
    +     * The backup creation or update failed.
    +     * 
    + * + * FAILED = 4; + */ + public static final int FAILED_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return CREATING; + case 2: + return ACTIVE; + case 3: + return UPDATING; + case 4: + return FAILED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public State findValueByNumber(int number) { + return State.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.Backup.getDescriptor().getEnumTypes().get(0); + } + + private static final State[] VALUES = values(); + + public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private State(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.secretmanager.v1.Backup.State) + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
    +   * Identifier. Resource name of the backup.
    +   * Format: `projects/{project}/locations/{location}/backups/{backup}`
    +   * 
    + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
    +   * Identifier. Resource name of the backup.
    +   * Format: `projects/{project}/locations/{location}/backups/{backup}`
    +   * 
    + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SOURCE_SECRET_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object sourceSecret_ = ""; + + /** + * + * + *
    +   * Required. Immutable. Resource name of the
    +   * [Secret][google.cloud.secretmanager.v1.Secret] that this backup is for. The
    +   * source [Secret][google.cloud.secretmanager.v1.Secret] can be in a different
    +   * region than the [Backup][google.cloud.secretmanager.v1.Backup]. This field
    +   * is immutable after creation. Formats:
    +   * - `projects/{project}/locations/{location}/secrets/{secret}` (for regional
    +   * secrets)
    +   * - `projects/{project}/secrets/{secret}` (for global secrets)
    +   * 
    + * + * + * string source_secret = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } + * + * + * @return The sourceSecret. + */ + @java.lang.Override + public java.lang.String getSourceSecret() { + java.lang.Object ref = sourceSecret_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sourceSecret_ = s; + return s; + } + } + + /** + * + * + *
    +   * Required. Immutable. Resource name of the
    +   * [Secret][google.cloud.secretmanager.v1.Secret] that this backup is for. The
    +   * source [Secret][google.cloud.secretmanager.v1.Secret] can be in a different
    +   * region than the [Backup][google.cloud.secretmanager.v1.Backup]. This field
    +   * is immutable after creation. Formats:
    +   * - `projects/{project}/locations/{location}/secrets/{secret}` (for regional
    +   * secrets)
    +   * - `projects/{project}/secrets/{secret}` (for global secrets)
    +   * 
    + * + * + * string source_secret = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for sourceSecret. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSourceSecretBytes() { + java.lang.Object ref = sourceSecret_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sourceSecret_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 3; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
    +   * Output only. Time at which the backup resource was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +   * Output only. Time at which the backup resource was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
    +   * Output only. Time at which the backup resource was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 4; + private com.google.protobuf.Timestamp updateTime_; + + /** + * + * + *
    +   * Output only. Time at which the backup resource was last updated.
    +   * 
    + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
    +   * Output only. Time at which the backup resource was last updated.
    +   * 
    + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + /** + * + * + *
    +   * Output only. Time at which the backup resource was last updated.
    +   * 
    + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + + public static final int SOURCE_SECRET_CREATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp sourceSecretCreateTime_; + + /** + * + * + *
    +   * Output only. Creation time of the source
    +   * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +   * initiated.
    +   * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the sourceSecretCreateTime field is set. + */ + @java.lang.Override + public boolean hasSourceSecretCreateTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
    +   * Output only. Creation time of the source
    +   * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +   * initiated.
    +   * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The sourceSecretCreateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getSourceSecretCreateTime() { + return sourceSecretCreateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : sourceSecretCreateTime_; + } + + /** + * + * + *
    +   * Output only. Creation time of the source
    +   * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +   * initiated.
    +   * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getSourceSecretCreateTimeOrBuilder() { + return sourceSecretCreateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : sourceSecretCreateTime_; + } + + public static final int VERSION_COUNT_FIELD_NUMBER = 6; + private int versionCount_ = 0; + + /** + * + * + *
    +   * Output only. Number of non-destroyed secret versions contained in this
    +   * backup.
    +   * 
    + * + * int32 version_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The versionCount. + */ + @java.lang.Override + public int getVersionCount() { + return versionCount_; + } + + public static final int LABELS_FIELD_NUMBER = 7; + + private static final class LabelsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_Backup_LabelsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + + @SuppressWarnings("serial") + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + + /** + * + * + *
    +   * Optional. Labels with user-defined metadata.
    +   * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetLabels().getMap().containsKey(key); + } + + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + + /** + * + * + *
    +   * Optional. Labels with user-defined metadata.
    +   * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
    +   * Optional. Labels with user-defined metadata.
    +   * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public /* nullable */ java.lang.String getLabelsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
    +   * Optional. Labels with user-defined metadata.
    +   * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public static final int STATE_FIELD_NUMBER = 8; + private int state_ = 0; + + /** + * + * + *
    +   * Output only. Current state of the Backup.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
    +   * Output only. Current state of the Backup.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.Backup.State getState() { + com.google.cloud.secretmanager.v1.Backup.State result = + com.google.cloud.secretmanager.v1.Backup.State.forNumber(state_); + return result == null ? com.google.cloud.secretmanager.v1.Backup.State.UNRECOGNIZED : result; + } + + public static final int ETAG_FIELD_NUMBER = 11; + + @SuppressWarnings("serial") + private volatile java.lang.Object etag_ = ""; + + /** + * + * + *
    +   * Optional. Used for optimistic concurrency control as a way to help prevent
    +   * simultaneous updates of a backup from overwriting each other.
    +   * 
    + * + * string etag = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The etag. + */ + @java.lang.Override + public java.lang.String getEtag() { + java.lang.Object ref = etag_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + etag_ = s; + return s; + } + } + + /** + * + * + *
    +   * Optional. Used for optimistic concurrency control as a way to help prevent
    +   * simultaneous updates of a backup from overwriting each other.
    +   * 
    + * + * string etag = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for etag. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEtagBytes() { + java.lang.Object ref = etag_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + etag_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceSecret_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, sourceSecret_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(4, getUpdateTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(5, getSourceSecretCreateTime()); + } + if (versionCount_ != 0) { + output.writeInt32(6, versionCount_); + } + com.google.protobuf.GeneratedMessage.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 7); + if (state_ != com.google.cloud.secretmanager.v1.Backup.State.STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(8, state_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(etag_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 11, etag_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sourceSecret_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, sourceSecret_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getUpdateTime()); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(5, getSourceSecretCreateTime()); + } + if (versionCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(6, versionCount_); + } + for (java.util.Map.Entry entry : + internalGetLabels().getMap().entrySet()) { + com.google.protobuf.MapEntry labels__ = + LabelsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, labels__); + } + if (state_ != com.google.cloud.secretmanager.v1.Backup.State.STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(8, state_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(etag_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(11, etag_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.secretmanager.v1.Backup)) { + return super.equals(obj); + } + com.google.cloud.secretmanager.v1.Backup other = (com.google.cloud.secretmanager.v1.Backup) obj; + + if (!getName().equals(other.getName())) return false; + if (!getSourceSecret().equals(other.getSourceSecret())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (hasSourceSecretCreateTime() != other.hasSourceSecretCreateTime()) return false; + if (hasSourceSecretCreateTime()) { + if (!getSourceSecretCreateTime().equals(other.getSourceSecretCreateTime())) return false; + } + if (getVersionCount() != other.getVersionCount()) return false; + if (!internalGetLabels().equals(other.internalGetLabels())) return false; + if (state_ != other.state_) return false; + if (!getEtag().equals(other.getEtag())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + SOURCE_SECRET_FIELD_NUMBER; + hash = (53 * hash) + getSourceSecret().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + if (hasSourceSecretCreateTime()) { + hash = (37 * hash) + SOURCE_SECRET_CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getSourceSecretCreateTime().hashCode(); + } + hash = (37 * hash) + VERSION_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getVersionCount(); + if (!internalGetLabels().getMap().isEmpty()) { + hash = (37 * hash) + LABELS_FIELD_NUMBER; + hash = (53 * hash) + internalGetLabels().hashCode(); + } + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + hash = (37 * hash) + ETAG_FIELD_NUMBER; + hash = (53 * hash) + getEtag().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.secretmanager.v1.Backup parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.Backup parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.Backup parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.Backup parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.Backup parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.Backup parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.Backup parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.Backup parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.Backup parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.Backup parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.Backup parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.Backup parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.secretmanager.v1.Backup prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * A Backup of a Secret.
    +   * Backups are regional resources.
    +   * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.Backup} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.secretmanager.v1.Backup) + com.google.cloud.secretmanager.v1.BackupOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_Backup_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 7: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection( + int number) { + switch (number) { + case 7: + return internalGetMutableLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_Backup_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.Backup.class, + com.google.cloud.secretmanager.v1.Backup.Builder.class); + } + + // Construct using com.google.cloud.secretmanager.v1.Backup.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetCreateTimeFieldBuilder(); + internalGetUpdateTimeFieldBuilder(); + internalGetSourceSecretCreateTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + sourceSecret_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + sourceSecretCreateTime_ = null; + if (sourceSecretCreateTimeBuilder_ != null) { + sourceSecretCreateTimeBuilder_.dispose(); + sourceSecretCreateTimeBuilder_ = null; + } + versionCount_ = 0; + internalGetMutableLabels().clear(); + state_ = 0; + etag_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_Backup_descriptor; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.Backup getDefaultInstanceForType() { + return com.google.cloud.secretmanager.v1.Backup.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.Backup build() { + com.google.cloud.secretmanager.v1.Backup result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.Backup buildPartial() { + com.google.cloud.secretmanager.v1.Backup result = + new com.google.cloud.secretmanager.v1.Backup(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.secretmanager.v1.Backup result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.sourceSecret_ = sourceSecret_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.sourceSecretCreateTime_ = + sourceSecretCreateTimeBuilder_ == null + ? sourceSecretCreateTime_ + : sourceSecretCreateTimeBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.versionCount_ = versionCount_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.labels_ = internalGetLabels(); + result.labels_.makeImmutable(); + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.state_ = state_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.etag_ = etag_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.secretmanager.v1.Backup) { + return mergeFrom((com.google.cloud.secretmanager.v1.Backup) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.secretmanager.v1.Backup other) { + if (other == com.google.cloud.secretmanager.v1.Backup.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getSourceSecret().isEmpty()) { + sourceSecret_ = other.sourceSecret_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (other.hasSourceSecretCreateTime()) { + mergeSourceSecretCreateTime(other.getSourceSecretCreateTime()); + } + if (other.getVersionCount() != 0) { + setVersionCount(other.getVersionCount()); + } + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); + bitField0_ |= 0x00000040; + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (!other.getEtag().isEmpty()) { + etag_ = other.etag_; + bitField0_ |= 0x00000100; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + sourceSecret_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + input.readMessage( + internalGetUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + input.readMessage( + internalGetSourceSecretCreateTimeFieldBuilder().getBuilder(), + extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 48: + { + versionCount_ = input.readInt32(); + bitField0_ |= 0x00000020; + break; + } // case 48 + case 58: + { + com.google.protobuf.MapEntry labels__ = + input.readMessage( + LabelsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableLabels() + .getMutableMap() + .put(labels__.getKey(), labels__.getValue()); + bitField0_ |= 0x00000040; + break; + } // case 58 + case 64: + { + state_ = input.readEnum(); + bitField0_ |= 0x00000080; + break; + } // case 64 + case 90: + { + etag_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000100; + break; + } // case 90 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
    +     * Identifier. Resource name of the backup.
    +     * Format: `projects/{project}/locations/{location}/backups/{backup}`
    +     * 
    + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Identifier. Resource name of the backup.
    +     * Format: `projects/{project}/locations/{location}/backups/{backup}`
    +     * 
    + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Identifier. Resource name of the backup.
    +     * Format: `projects/{project}/locations/{location}/backups/{backup}`
    +     * 
    + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Identifier. Resource name of the backup.
    +     * Format: `projects/{project}/locations/{location}/backups/{backup}`
    +     * 
    + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Identifier. Resource name of the backup.
    +     * Format: `projects/{project}/locations/{location}/backups/{backup}`
    +     * 
    + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object sourceSecret_ = ""; + + /** + * + * + *
    +     * Required. Immutable. Resource name of the
    +     * [Secret][google.cloud.secretmanager.v1.Secret] that this backup is for. The
    +     * source [Secret][google.cloud.secretmanager.v1.Secret] can be in a different
    +     * region than the [Backup][google.cloud.secretmanager.v1.Backup]. This field
    +     * is immutable after creation. Formats:
    +     * - `projects/{project}/locations/{location}/secrets/{secret}` (for regional
    +     * secrets)
    +     * - `projects/{project}/secrets/{secret}` (for global secrets)
    +     * 
    + * + * + * string source_secret = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } + * + * + * @return The sourceSecret. + */ + public java.lang.String getSourceSecret() { + java.lang.Object ref = sourceSecret_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sourceSecret_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Required. Immutable. Resource name of the
    +     * [Secret][google.cloud.secretmanager.v1.Secret] that this backup is for. The
    +     * source [Secret][google.cloud.secretmanager.v1.Secret] can be in a different
    +     * region than the [Backup][google.cloud.secretmanager.v1.Backup]. This field
    +     * is immutable after creation. Formats:
    +     * - `projects/{project}/locations/{location}/secrets/{secret}` (for regional
    +     * secrets)
    +     * - `projects/{project}/secrets/{secret}` (for global secrets)
    +     * 
    + * + * + * string source_secret = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for sourceSecret. + */ + public com.google.protobuf.ByteString getSourceSecretBytes() { + java.lang.Object ref = sourceSecret_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sourceSecret_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Required. Immutable. Resource name of the
    +     * [Secret][google.cloud.secretmanager.v1.Secret] that this backup is for. The
    +     * source [Secret][google.cloud.secretmanager.v1.Secret] can be in a different
    +     * region than the [Backup][google.cloud.secretmanager.v1.Backup]. This field
    +     * is immutable after creation. Formats:
    +     * - `projects/{project}/locations/{location}/secrets/{secret}` (for regional
    +     * secrets)
    +     * - `projects/{project}/secrets/{secret}` (for global secrets)
    +     * 
    + * + * + * string source_secret = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } + * + * + * @param value The sourceSecret to set. + * @return This builder for chaining. + */ + public Builder setSourceSecret(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sourceSecret_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. Immutable. Resource name of the
    +     * [Secret][google.cloud.secretmanager.v1.Secret] that this backup is for. The
    +     * source [Secret][google.cloud.secretmanager.v1.Secret] can be in a different
    +     * region than the [Backup][google.cloud.secretmanager.v1.Backup]. This field
    +     * is immutable after creation. Formats:
    +     * - `projects/{project}/locations/{location}/secrets/{secret}` (for regional
    +     * secrets)
    +     * - `projects/{project}/secrets/{secret}` (for global secrets)
    +     * 
    + * + * + * string source_secret = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearSourceSecret() { + sourceSecret_ = getDefaultInstance().getSourceSecret(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. Immutable. Resource name of the
    +     * [Secret][google.cloud.secretmanager.v1.Secret] that this backup is for. The
    +     * source [Secret][google.cloud.secretmanager.v1.Secret] can be in a different
    +     * region than the [Backup][google.cloud.secretmanager.v1.Backup]. This field
    +     * is immutable after creation. Formats:
    +     * - `projects/{project}/locations/{location}/secrets/{secret}` (for regional
    +     * secrets)
    +     * - `projects/{project}/secrets/{secret}` (for global secrets)
    +     * 
    + * + * + * string source_secret = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for sourceSecret to set. + * @return This builder for chaining. + */ + public Builder setSourceSecretBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sourceSecret_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
    +     * Output only. Time at which the backup resource was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000004); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
    +     * Output only. Time at which the backup resource was last updated.
    +     * 
    + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was last updated.
    +     * 
    + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was last updated.
    +     * 
    + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + } else { + updateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was last updated.
    +     * 
    + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was last updated.
    +     * 
    + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0) + && updateTime_ != null + && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getUpdateTimeBuilder().mergeFrom(value); + } else { + updateTime_ = value; + } + } else { + updateTimeBuilder_.mergeFrom(value); + } + if (updateTime_ != null) { + bitField0_ |= 0x00000008; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was last updated.
    +     * 
    + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + bitField0_ = (bitField0_ & ~0x00000008); + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was last updated.
    +     * 
    + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return internalGetUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was last updated.
    +     * 
    + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + + /** + * + * + *
    +     * Output only. Time at which the backup resource was last updated.
    +     * 
    + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private com.google.protobuf.Timestamp sourceSecretCreateTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + sourceSecretCreateTimeBuilder_; + + /** + * + * + *
    +     * Output only. Creation time of the source
    +     * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +     * initiated.
    +     * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the sourceSecretCreateTime field is set. + */ + public boolean hasSourceSecretCreateTime() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
    +     * Output only. Creation time of the source
    +     * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +     * initiated.
    +     * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The sourceSecretCreateTime. + */ + public com.google.protobuf.Timestamp getSourceSecretCreateTime() { + if (sourceSecretCreateTimeBuilder_ == null) { + return sourceSecretCreateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : sourceSecretCreateTime_; + } else { + return sourceSecretCreateTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Output only. Creation time of the source
    +     * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +     * initiated.
    +     * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setSourceSecretCreateTime(com.google.protobuf.Timestamp value) { + if (sourceSecretCreateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + sourceSecretCreateTime_ = value; + } else { + sourceSecretCreateTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Creation time of the source
    +     * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +     * initiated.
    +     * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setSourceSecretCreateTime( + com.google.protobuf.Timestamp.Builder builderForValue) { + if (sourceSecretCreateTimeBuilder_ == null) { + sourceSecretCreateTime_ = builderForValue.build(); + } else { + sourceSecretCreateTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Creation time of the source
    +     * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +     * initiated.
    +     * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeSourceSecretCreateTime(com.google.protobuf.Timestamp value) { + if (sourceSecretCreateTimeBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && sourceSecretCreateTime_ != null + && sourceSecretCreateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getSourceSecretCreateTimeBuilder().mergeFrom(value); + } else { + sourceSecretCreateTime_ = value; + } + } else { + sourceSecretCreateTimeBuilder_.mergeFrom(value); + } + if (sourceSecretCreateTime_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Output only. Creation time of the source
    +     * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +     * initiated.
    +     * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearSourceSecretCreateTime() { + bitField0_ = (bitField0_ & ~0x00000010); + sourceSecretCreateTime_ = null; + if (sourceSecretCreateTimeBuilder_ != null) { + sourceSecretCreateTimeBuilder_.dispose(); + sourceSecretCreateTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Creation time of the source
    +     * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +     * initiated.
    +     * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getSourceSecretCreateTimeBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetSourceSecretCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Output only. Creation time of the source
    +     * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +     * initiated.
    +     * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getSourceSecretCreateTimeOrBuilder() { + if (sourceSecretCreateTimeBuilder_ != null) { + return sourceSecretCreateTimeBuilder_.getMessageOrBuilder(); + } else { + return sourceSecretCreateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : sourceSecretCreateTime_; + } + } + + /** + * + * + *
    +     * Output only. Creation time of the source
    +     * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +     * initiated.
    +     * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetSourceSecretCreateTimeFieldBuilder() { + if (sourceSecretCreateTimeBuilder_ == null) { + sourceSecretCreateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getSourceSecretCreateTime(), getParentForChildren(), isClean()); + sourceSecretCreateTime_ = null; + } + return sourceSecretCreateTimeBuilder_; + } + + private int versionCount_; + + /** + * + * + *
    +     * Output only. Number of non-destroyed secret versions contained in this
    +     * backup.
    +     * 
    + * + * int32 version_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The versionCount. + */ + @java.lang.Override + public int getVersionCount() { + return versionCount_; + } + + /** + * + * + *
    +     * Output only. Number of non-destroyed secret versions contained in this
    +     * backup.
    +     * 
    + * + * int32 version_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The versionCount to set. + * @return This builder for chaining. + */ + public Builder setVersionCount(int value) { + + versionCount_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Number of non-destroyed secret versions contained in this
    +     * backup.
    +     * 
    + * + * int32 version_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearVersionCount() { + bitField0_ = (bitField0_ & ~0x00000020); + versionCount_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + private com.google.protobuf.MapField + internalGetMutableLabels() { + if (labels_ == null) { + labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); + } + if (!labels_.isMutable()) { + labels_ = labels_.copy(); + } + bitField0_ |= 0x00000040; + onChanged(); + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + + /** + * + * + *
    +     * Optional. Labels with user-defined metadata.
    +     * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetLabels().getMap().containsKey(key); + } + + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + + /** + * + * + *
    +     * Optional. Labels with user-defined metadata.
    +     * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
    +     * Optional. Labels with user-defined metadata.
    +     * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public /* nullable */ java.lang.String getLabelsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
    +     * Optional. Labels with user-defined metadata.
    +     * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearLabels() { + bitField0_ = (bitField0_ & ~0x00000040); + internalGetMutableLabels().getMutableMap().clear(); + return this; + } + + /** + * + * + *
    +     * Optional. Labels with user-defined metadata.
    +     * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder removeLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableLabels().getMutableMap().remove(key); + return this; + } + + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableLabels() { + bitField0_ |= 0x00000040; + return internalGetMutableLabels().getMutableMap(); + } + + /** + * + * + *
    +     * Optional. Labels with user-defined metadata.
    +     * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder putLabels(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + internalGetMutableLabels().getMutableMap().put(key, value); + bitField0_ |= 0x00000040; + return this; + } + + /** + * + * + *
    +     * Optional. Labels with user-defined metadata.
    +     * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder putAllLabels(java.util.Map values) { + internalGetMutableLabels().getMutableMap().putAll(values); + bitField0_ |= 0x00000040; + return this; + } + + private int state_ = 0; + + /** + * + * + *
    +     * Output only. Current state of the Backup.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
    +     * Output only. Current state of the Backup.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Current state of the Backup.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.Backup.State getState() { + com.google.cloud.secretmanager.v1.Backup.State result = + com.google.cloud.secretmanager.v1.Backup.State.forNumber(state_); + return result == null ? com.google.cloud.secretmanager.v1.Backup.State.UNRECOGNIZED : result; + } + + /** + * + * + *
    +     * Output only. Current state of the Backup.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.secretmanager.v1.Backup.State value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000080; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Current state of the Backup.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000080); + state_ = 0; + onChanged(); + return this; + } + + private java.lang.Object etag_ = ""; + + /** + * + * + *
    +     * Optional. Used for optimistic concurrency control as a way to help prevent
    +     * simultaneous updates of a backup from overwriting each other.
    +     * 
    + * + * string etag = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The etag. + */ + public java.lang.String getEtag() { + java.lang.Object ref = etag_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + etag_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Optional. Used for optimistic concurrency control as a way to help prevent
    +     * simultaneous updates of a backup from overwriting each other.
    +     * 
    + * + * string etag = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for etag. + */ + public com.google.protobuf.ByteString getEtagBytes() { + java.lang.Object ref = etag_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + etag_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Optional. Used for optimistic concurrency control as a way to help prevent
    +     * simultaneous updates of a backup from overwriting each other.
    +     * 
    + * + * string etag = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The etag to set. + * @return This builder for chaining. + */ + public Builder setEtag(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + etag_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Used for optimistic concurrency control as a way to help prevent
    +     * simultaneous updates of a backup from overwriting each other.
    +     * 
    + * + * string etag = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearEtag() { + etag_ = getDefaultInstance().getEtag(); + bitField0_ = (bitField0_ & ~0x00000100); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Used for optimistic concurrency control as a way to help prevent
    +     * simultaneous updates of a backup from overwriting each other.
    +     * 
    + * + * string etag = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for etag to set. + * @return This builder for chaining. + */ + public Builder setEtagBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + etag_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.secretmanager.v1.Backup) + } + + // @@protoc_insertion_point(class_scope:google.cloud.secretmanager.v1.Backup) + private static final com.google.cloud.secretmanager.v1.Backup DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.secretmanager.v1.Backup(); + } + + public static com.google.cloud.secretmanager.v1.Backup getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Backup parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.Backup getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/BackupName.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/BackupName.java new file mode 100644 index 000000000000..e44751e458d4 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/BackupName.java @@ -0,0 +1,226 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class BackupName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_BACKUP = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/backups/{backup}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String backup; + + @Deprecated + protected BackupName() { + project = null; + location = null; + backup = null; + } + + private BackupName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + backup = Preconditions.checkNotNull(builder.getBackup()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getBackup() { + return backup; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static BackupName of(String project, String location, String backup) { + return newBuilder().setProject(project).setLocation(location).setBackup(backup).build(); + } + + public static String format(String project, String location, String backup) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setBackup(backup) + .build() + .toString(); + } + + public static @Nullable BackupName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_BACKUP.validatedMatch( + formattedString, "BackupName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("backup")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable BackupName> values) { + List list = new ArrayList<>(values.size()); + for (BackupName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_BACKUP.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (backup != null) { + fieldMapBuilder.put("backup", backup); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_BACKUP.instantiate( + "project", project, "location", location, "backup", backup); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + BackupName that = ((BackupName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.backup, that.backup); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(backup); + return h; + } + + /** Builder for projects/{project}/locations/{location}/backups/{backup}. */ + public static class Builder { + private String project; + private String location; + private String backup; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getBackup() { + return backup; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setBackup(String backup) { + this.backup = backup; + return this; + } + + private Builder(BackupName backupName) { + this.project = backupName.project; + this.location = backupName.location; + this.backup = backupName.backup; + } + + public BackupName build() { + return new BackupName(this); + } + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/BackupOrBuilder.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/BackupOrBuilder.java new file mode 100644 index 000000000000..be20c9661bcd --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/BackupOrBuilder.java @@ -0,0 +1,364 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +@com.google.protobuf.Generated +public interface BackupOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.secretmanager.v1.Backup) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * Identifier. Resource name of the backup.
    +   * Format: `projects/{project}/locations/{location}/backups/{backup}`
    +   * 
    + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
    +   * Identifier. Resource name of the backup.
    +   * Format: `projects/{project}/locations/{location}/backups/{backup}`
    +   * 
    + * + * string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
    +   * Required. Immutable. Resource name of the
    +   * [Secret][google.cloud.secretmanager.v1.Secret] that this backup is for. The
    +   * source [Secret][google.cloud.secretmanager.v1.Secret] can be in a different
    +   * region than the [Backup][google.cloud.secretmanager.v1.Backup]. This field
    +   * is immutable after creation. Formats:
    +   * - `projects/{project}/locations/{location}/secrets/{secret}` (for regional
    +   * secrets)
    +   * - `projects/{project}/secrets/{secret}` (for global secrets)
    +   * 
    + * + * + * string source_secret = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } + * + * + * @return The sourceSecret. + */ + java.lang.String getSourceSecret(); + + /** + * + * + *
    +   * Required. Immutable. Resource name of the
    +   * [Secret][google.cloud.secretmanager.v1.Secret] that this backup is for. The
    +   * source [Secret][google.cloud.secretmanager.v1.Secret] can be in a different
    +   * region than the [Backup][google.cloud.secretmanager.v1.Backup]. This field
    +   * is immutable after creation. Formats:
    +   * - `projects/{project}/locations/{location}/secrets/{secret}` (for regional
    +   * secrets)
    +   * - `projects/{project}/secrets/{secret}` (for global secrets)
    +   * 
    + * + * + * string source_secret = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for sourceSecret. + */ + com.google.protobuf.ByteString getSourceSecretBytes(); + + /** + * + * + *
    +   * Output only. Time at which the backup resource was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
    +   * Output only. Time at which the backup resource was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
    +   * Output only. Time at which the backup resource was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
    +   * Output only. Time at which the backup resource was last updated.
    +   * 
    + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + + /** + * + * + *
    +   * Output only. Time at which the backup resource was last updated.
    +   * 
    + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + + /** + * + * + *
    +   * Output only. Time at which the backup resource was last updated.
    +   * 
    + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
    +   * Output only. Creation time of the source
    +   * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +   * initiated.
    +   * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the sourceSecretCreateTime field is set. + */ + boolean hasSourceSecretCreateTime(); + + /** + * + * + *
    +   * Output only. Creation time of the source
    +   * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +   * initiated.
    +   * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The sourceSecretCreateTime. + */ + com.google.protobuf.Timestamp getSourceSecretCreateTime(); + + /** + * + * + *
    +   * Output only. Creation time of the source
    +   * [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was
    +   * initiated.
    +   * 
    + * + * + * .google.protobuf.Timestamp source_secret_create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getSourceSecretCreateTimeOrBuilder(); + + /** + * + * + *
    +   * Output only. Number of non-destroyed secret versions contained in this
    +   * backup.
    +   * 
    + * + * int32 version_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The versionCount. + */ + int getVersionCount(); + + /** + * + * + *
    +   * Optional. Labels with user-defined metadata.
    +   * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + int getLabelsCount(); + + /** + * + * + *
    +   * Optional. Labels with user-defined metadata.
    +   * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + boolean containsLabels(java.lang.String key); + + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Deprecated + java.util.Map getLabels(); + + /** + * + * + *
    +   * Optional. Labels with user-defined metadata.
    +   * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.util.Map getLabelsMap(); + + /** + * + * + *
    +   * Optional. Labels with user-defined metadata.
    +   * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + /* nullable */ + java.lang.String getLabelsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue); + + /** + * + * + *
    +   * Optional. Labels with user-defined metadata.
    +   * 
    + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.lang.String getLabelsOrThrow(java.lang.String key); + + /** + * + * + *
    +   * Output only. Current state of the Backup.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
    +   * Output only. Current state of the Backup.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.secretmanager.v1.Backup.State getState(); + + /** + * + * + *
    +   * Optional. Used for optimistic concurrency control as a way to help prevent
    +   * simultaneous updates of a backup from overwriting each other.
    +   * 
    + * + * string etag = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The etag. + */ + java.lang.String getEtag(); + + /** + * + * + *
    +   * Optional. Used for optimistic concurrency control as a way to help prevent
    +   * simultaneous updates of a backup from overwriting each other.
    +   * 
    + * + * string etag = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for etag. + */ + com.google.protobuf.ByteString getEtagBytes(); +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/CreateBackupRequest.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/CreateBackupRequest.java new file mode 100644 index 000000000000..5d86c5ed3693 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/CreateBackupRequest.java @@ -0,0 +1,1150 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +/** + * + * + *
    + * Request message for
    + * [SecretOperationsService.CreateBackup][google.cloud.secretmanager.v1.SecretOperationsService.CreateBackup].
    + * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.CreateBackupRequest} + */ +@com.google.protobuf.Generated +public final class CreateBackupRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.secretmanager.v1.CreateBackupRequest) + CreateBackupRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "CreateBackupRequest"); + } + + // Use CreateBackupRequest.newBuilder() to construct. + private CreateBackupRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private CreateBackupRequest() { + parent_ = ""; + backupId_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_CreateBackupRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_CreateBackupRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.CreateBackupRequest.class, + com.google.cloud.secretmanager.v1.CreateBackupRequest.Builder.class); + } + + private int bitField0_; + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
    +   * Required. The resource name of the location where the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the
    +   * format `projects/{project}/locations/{location}`.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
    +   * Required. The resource name of the location where the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the
    +   * format `projects/{project}/locations/{location}`.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int BACKUP_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object backupId_ = ""; + + /** + * + * + *
    +   * Required. The ID to use for the backup, which will become the final
    +   * component of the backup's resource name.
    +   * 
    + * + * string backup_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The backupId. + */ + @java.lang.Override + public java.lang.String getBackupId() { + java.lang.Object ref = backupId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + backupId_ = s; + return s; + } + } + + /** + * + * + *
    +   * Required. The ID to use for the backup, which will become the final
    +   * component of the backup's resource name.
    +   * 
    + * + * string backup_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for backupId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getBackupIdBytes() { + java.lang.Object ref = backupId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + backupId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int BACKUP_FIELD_NUMBER = 3; + private com.google.cloud.secretmanager.v1.Backup backup_; + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +   * create.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the backup field is set. + */ + @java.lang.Override + public boolean hasBackup() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +   * create.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The backup. + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.Backup getBackup() { + return backup_ == null + ? com.google.cloud.secretmanager.v1.Backup.getDefaultInstance() + : backup_; + } + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +   * create.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.BackupOrBuilder getBackupOrBuilder() { + return backup_ == null + ? com.google.cloud.secretmanager.v1.Backup.getDefaultInstance() + : backup_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(backupId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, backupId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getBackup()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(backupId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, backupId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getBackup()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.secretmanager.v1.CreateBackupRequest)) { + return super.equals(obj); + } + com.google.cloud.secretmanager.v1.CreateBackupRequest other = + (com.google.cloud.secretmanager.v1.CreateBackupRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (!getBackupId().equals(other.getBackupId())) return false; + if (hasBackup() != other.hasBackup()) return false; + if (hasBackup()) { + if (!getBackup().equals(other.getBackup())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + BACKUP_ID_FIELD_NUMBER; + hash = (53 * hash) + getBackupId().hashCode(); + if (hasBackup()) { + hash = (37 * hash) + BACKUP_FIELD_NUMBER; + hash = (53 * hash) + getBackup().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.secretmanager.v1.CreateBackupRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * Request message for
    +   * [SecretOperationsService.CreateBackup][google.cloud.secretmanager.v1.SecretOperationsService.CreateBackup].
    +   * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.CreateBackupRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.secretmanager.v1.CreateBackupRequest) + com.google.cloud.secretmanager.v1.CreateBackupRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_CreateBackupRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_CreateBackupRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.CreateBackupRequest.class, + com.google.cloud.secretmanager.v1.CreateBackupRequest.Builder.class); + } + + // Construct using com.google.cloud.secretmanager.v1.CreateBackupRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetBackupFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + backupId_ = ""; + backup_ = null; + if (backupBuilder_ != null) { + backupBuilder_.dispose(); + backupBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_CreateBackupRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.CreateBackupRequest getDefaultInstanceForType() { + return com.google.cloud.secretmanager.v1.CreateBackupRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.CreateBackupRequest build() { + com.google.cloud.secretmanager.v1.CreateBackupRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.CreateBackupRequest buildPartial() { + com.google.cloud.secretmanager.v1.CreateBackupRequest result = + new com.google.cloud.secretmanager.v1.CreateBackupRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.secretmanager.v1.CreateBackupRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.backupId_ = backupId_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.backup_ = backupBuilder_ == null ? backup_ : backupBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.secretmanager.v1.CreateBackupRequest) { + return mergeFrom((com.google.cloud.secretmanager.v1.CreateBackupRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.secretmanager.v1.CreateBackupRequest other) { + if (other == com.google.cloud.secretmanager.v1.CreateBackupRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getBackupId().isEmpty()) { + backupId_ = other.backupId_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasBackup()) { + mergeBackup(other.getBackup()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + backupId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage(internalGetBackupFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
    +     * Required. The resource name of the location where the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the
    +     * format `projects/{project}/locations/{location}`.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Required. The resource name of the location where the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the
    +     * format `projects/{project}/locations/{location}`.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Required. The resource name of the location where the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the
    +     * format `projects/{project}/locations/{location}`.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource name of the location where the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the
    +     * format `projects/{project}/locations/{location}`.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource name of the location where the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the
    +     * format `projects/{project}/locations/{location}`.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object backupId_ = ""; + + /** + * + * + *
    +     * Required. The ID to use for the backup, which will become the final
    +     * component of the backup's resource name.
    +     * 
    + * + * string backup_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The backupId. + */ + public java.lang.String getBackupId() { + java.lang.Object ref = backupId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + backupId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Required. The ID to use for the backup, which will become the final
    +     * component of the backup's resource name.
    +     * 
    + * + * string backup_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for backupId. + */ + public com.google.protobuf.ByteString getBackupIdBytes() { + java.lang.Object ref = backupId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + backupId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Required. The ID to use for the backup, which will become the final
    +     * component of the backup's resource name.
    +     * 
    + * + * string backup_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The backupId to set. + * @return This builder for chaining. + */ + public Builder setBackupId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + backupId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The ID to use for the backup, which will become the final
    +     * component of the backup's resource name.
    +     * 
    + * + * string backup_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearBackupId() { + backupId_ = getDefaultInstance().getBackupId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The ID to use for the backup, which will become the final
    +     * component of the backup's resource name.
    +     * 
    + * + * string backup_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for backupId to set. + * @return This builder for chaining. + */ + public Builder setBackupIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + backupId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.cloud.secretmanager.v1.Backup backup_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.secretmanager.v1.Backup, + com.google.cloud.secretmanager.v1.Backup.Builder, + com.google.cloud.secretmanager.v1.BackupOrBuilder> + backupBuilder_; + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +     * create.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the backup field is set. + */ + public boolean hasBackup() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +     * create.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The backup. + */ + public com.google.cloud.secretmanager.v1.Backup getBackup() { + if (backupBuilder_ == null) { + return backup_ == null + ? com.google.cloud.secretmanager.v1.Backup.getDefaultInstance() + : backup_; + } else { + return backupBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +     * create.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setBackup(com.google.cloud.secretmanager.v1.Backup value) { + if (backupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + backup_ = value; + } else { + backupBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +     * create.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setBackup(com.google.cloud.secretmanager.v1.Backup.Builder builderForValue) { + if (backupBuilder_ == null) { + backup_ = builderForValue.build(); + } else { + backupBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +     * create.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeBackup(com.google.cloud.secretmanager.v1.Backup value) { + if (backupBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && backup_ != null + && backup_ != com.google.cloud.secretmanager.v1.Backup.getDefaultInstance()) { + getBackupBuilder().mergeFrom(value); + } else { + backup_ = value; + } + } else { + backupBuilder_.mergeFrom(value); + } + if (backup_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +     * create.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearBackup() { + bitField0_ = (bitField0_ & ~0x00000004); + backup_ = null; + if (backupBuilder_ != null) { + backupBuilder_.dispose(); + backupBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +     * create.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.secretmanager.v1.Backup.Builder getBackupBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return internalGetBackupFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +     * create.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.secretmanager.v1.BackupOrBuilder getBackupOrBuilder() { + if (backupBuilder_ != null) { + return backupBuilder_.getMessageOrBuilder(); + } else { + return backup_ == null + ? com.google.cloud.secretmanager.v1.Backup.getDefaultInstance() + : backup_; + } + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +     * create.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.secretmanager.v1.Backup, + com.google.cloud.secretmanager.v1.Backup.Builder, + com.google.cloud.secretmanager.v1.BackupOrBuilder> + internalGetBackupFieldBuilder() { + if (backupBuilder_ == null) { + backupBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.secretmanager.v1.Backup, + com.google.cloud.secretmanager.v1.Backup.Builder, + com.google.cloud.secretmanager.v1.BackupOrBuilder>( + getBackup(), getParentForChildren(), isClean()); + backup_ = null; + } + return backupBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.secretmanager.v1.CreateBackupRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.secretmanager.v1.CreateBackupRequest) + private static final com.google.cloud.secretmanager.v1.CreateBackupRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.secretmanager.v1.CreateBackupRequest(); + } + + public static com.google.cloud.secretmanager.v1.CreateBackupRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateBackupRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.CreateBackupRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/CreateBackupRequestOrBuilder.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/CreateBackupRequestOrBuilder.java new file mode 100644 index 000000000000..d5c3e0f4f9af --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/CreateBackupRequestOrBuilder.java @@ -0,0 +1,136 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +@com.google.protobuf.Generated +public interface CreateBackupRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.secretmanager.v1.CreateBackupRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * Required. The resource name of the location where the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the
    +   * format `projects/{project}/locations/{location}`.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
    +   * Required. The resource name of the location where the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the
    +   * format `projects/{project}/locations/{location}`.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
    +   * Required. The ID to use for the backup, which will become the final
    +   * component of the backup's resource name.
    +   * 
    + * + * string backup_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The backupId. + */ + java.lang.String getBackupId(); + + /** + * + * + *
    +   * Required. The ID to use for the backup, which will become the final
    +   * component of the backup's resource name.
    +   * 
    + * + * string backup_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for backupId. + */ + com.google.protobuf.ByteString getBackupIdBytes(); + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +   * create.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the backup field is set. + */ + boolean hasBackup(); + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +   * create.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The backup. + */ + com.google.cloud.secretmanager.v1.Backup getBackup(); + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to
    +   * create.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.secretmanager.v1.BackupOrBuilder getBackupOrBuilder(); +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/CryptoKeyName.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/CryptoKeyName.java new file mode 100644 index 000000000000..ec324dc14a4c --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/CryptoKeyName.java @@ -0,0 +1,264 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; +import org.jspecify.annotations.NullMarked; +import org.jspecify.annotations.Nullable; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@NullMarked +@Generated("by gapic-generator-java") +public class CryptoKeyName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_KEY_RING_CRYPTO_KEY = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String keyRing; + private final String cryptoKey; + + @Deprecated + protected CryptoKeyName() { + project = null; + location = null; + keyRing = null; + cryptoKey = null; + } + + private CryptoKeyName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + keyRing = Preconditions.checkNotNull(builder.getKeyRing()); + cryptoKey = Preconditions.checkNotNull(builder.getCryptoKey()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getKeyRing() { + return keyRing; + } + + public String getCryptoKey() { + return cryptoKey; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static CryptoKeyName of( + String project, String location, String keyRing, String cryptoKey) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setKeyRing(keyRing) + .setCryptoKey(cryptoKey) + .build(); + } + + public static String format(String project, String location, String keyRing, String cryptoKey) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setKeyRing(keyRing) + .setCryptoKey(cryptoKey) + .build() + .toString(); + } + + public static @Nullable CryptoKeyName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_KEY_RING_CRYPTO_KEY.validatedMatch( + formattedString, "CryptoKeyName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("key_ring"), + matchMap.get("crypto_key")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List<@Nullable CryptoKeyName> values) { + List list = new ArrayList<>(values.size()); + for (CryptoKeyName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_KEY_RING_CRYPTO_KEY.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (keyRing != null) { + fieldMapBuilder.put("key_ring", keyRing); + } + if (cryptoKey != null) { + fieldMapBuilder.put("crypto_key", cryptoKey); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_KEY_RING_CRYPTO_KEY.instantiate( + "project", project, "location", location, "key_ring", keyRing, "crypto_key", cryptoKey); + } + + @Override + public boolean equals(@Nullable Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + CryptoKeyName that = ((CryptoKeyName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.keyRing, that.keyRing) + && Objects.equals(this.cryptoKey, that.cryptoKey); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(keyRing); + h *= 1000003; + h ^= Objects.hashCode(cryptoKey); + return h; + } + + /** + * Builder for + * projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}. + */ + public static class Builder { + private String project; + private String location; + private String keyRing; + private String cryptoKey; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getKeyRing() { + return keyRing; + } + + public String getCryptoKey() { + return cryptoKey; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setKeyRing(String keyRing) { + this.keyRing = keyRing; + return this; + } + + public Builder setCryptoKey(String cryptoKey) { + this.cryptoKey = cryptoKey; + return this; + } + + private Builder(CryptoKeyName cryptoKeyName) { + this.project = cryptoKeyName.project; + this.location = cryptoKeyName.location; + this.keyRing = cryptoKeyName.keyRing; + this.cryptoKey = cryptoKeyName.cryptoKey; + } + + public CryptoKeyName build() { + return new CryptoKeyName(this); + } + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/DeleteBackupRequest.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/DeleteBackupRequest.java new file mode 100644 index 000000000000..6c1e1fde7991 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/DeleteBackupRequest.java @@ -0,0 +1,823 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +/** + * + * + *
    + * Request message for
    + * [SecretOperationsService.DeleteBackup][google.cloud.secretmanager.v1.SecretOperationsService.DeleteBackup].
    + * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.DeleteBackupRequest} + */ +@com.google.protobuf.Generated +public final class DeleteBackupRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.secretmanager.v1.DeleteBackupRequest) + DeleteBackupRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "DeleteBackupRequest"); + } + + // Use DeleteBackupRequest.newBuilder() to construct. + private DeleteBackupRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private DeleteBackupRequest() { + name_ = ""; + etag_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_DeleteBackupRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_DeleteBackupRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.DeleteBackupRequest.class, + com.google.cloud.secretmanager.v1.DeleteBackupRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] to delete, in the format
    +   * `projects/{project}/locations/{location}/backups/{backup}`.
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] to delete, in the format
    +   * `projects/{project}/locations/{location}/backups/{backup}`.
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ETAG_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object etag_ = ""; + + /** + * + * + *
    +   * Optional. If set, the request will only succeed if it matches the etag of
    +   * the currently stored [Backup][google.cloud.secretmanager.v1.Backup].
    +   * 
    + * + * string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The etag. + */ + @java.lang.Override + public java.lang.String getEtag() { + java.lang.Object ref = etag_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + etag_ = s; + return s; + } + } + + /** + * + * + *
    +   * Optional. If set, the request will only succeed if it matches the etag of
    +   * the currently stored [Backup][google.cloud.secretmanager.v1.Backup].
    +   * 
    + * + * string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for etag. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEtagBytes() { + java.lang.Object ref = etag_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + etag_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(etag_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, etag_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(etag_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, etag_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.secretmanager.v1.DeleteBackupRequest)) { + return super.equals(obj); + } + com.google.cloud.secretmanager.v1.DeleteBackupRequest other = + (com.google.cloud.secretmanager.v1.DeleteBackupRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getEtag().equals(other.getEtag())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + ETAG_FIELD_NUMBER; + hash = (53 * hash) + getEtag().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.secretmanager.v1.DeleteBackupRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * Request message for
    +   * [SecretOperationsService.DeleteBackup][google.cloud.secretmanager.v1.SecretOperationsService.DeleteBackup].
    +   * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.DeleteBackupRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.secretmanager.v1.DeleteBackupRequest) + com.google.cloud.secretmanager.v1.DeleteBackupRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_DeleteBackupRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_DeleteBackupRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.DeleteBackupRequest.class, + com.google.cloud.secretmanager.v1.DeleteBackupRequest.Builder.class); + } + + // Construct using com.google.cloud.secretmanager.v1.DeleteBackupRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + etag_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_DeleteBackupRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.DeleteBackupRequest getDefaultInstanceForType() { + return com.google.cloud.secretmanager.v1.DeleteBackupRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.DeleteBackupRequest build() { + com.google.cloud.secretmanager.v1.DeleteBackupRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.DeleteBackupRequest buildPartial() { + com.google.cloud.secretmanager.v1.DeleteBackupRequest result = + new com.google.cloud.secretmanager.v1.DeleteBackupRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.secretmanager.v1.DeleteBackupRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.etag_ = etag_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.secretmanager.v1.DeleteBackupRequest) { + return mergeFrom((com.google.cloud.secretmanager.v1.DeleteBackupRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.secretmanager.v1.DeleteBackupRequest other) { + if (other == com.google.cloud.secretmanager.v1.DeleteBackupRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getEtag().isEmpty()) { + etag_ = other.etag_; + bitField0_ |= 0x00000002; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + etag_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] to delete, in the format
    +     * `projects/{project}/locations/{location}/backups/{backup}`.
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] to delete, in the format
    +     * `projects/{project}/locations/{location}/backups/{backup}`.
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] to delete, in the format
    +     * `projects/{project}/locations/{location}/backups/{backup}`.
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] to delete, in the format
    +     * `projects/{project}/locations/{location}/backups/{backup}`.
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] to delete, in the format
    +     * `projects/{project}/locations/{location}/backups/{backup}`.
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object etag_ = ""; + + /** + * + * + *
    +     * Optional. If set, the request will only succeed if it matches the etag of
    +     * the currently stored [Backup][google.cloud.secretmanager.v1.Backup].
    +     * 
    + * + * string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The etag. + */ + public java.lang.String getEtag() { + java.lang.Object ref = etag_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + etag_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Optional. If set, the request will only succeed if it matches the etag of
    +     * the currently stored [Backup][google.cloud.secretmanager.v1.Backup].
    +     * 
    + * + * string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for etag. + */ + public com.google.protobuf.ByteString getEtagBytes() { + java.lang.Object ref = etag_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + etag_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Optional. If set, the request will only succeed if it matches the etag of
    +     * the currently stored [Backup][google.cloud.secretmanager.v1.Backup].
    +     * 
    + * + * string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The etag to set. + * @return This builder for chaining. + */ + public Builder setEtag(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + etag_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. If set, the request will only succeed if it matches the etag of
    +     * the currently stored [Backup][google.cloud.secretmanager.v1.Backup].
    +     * 
    + * + * string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearEtag() { + etag_ = getDefaultInstance().getEtag(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. If set, the request will only succeed if it matches the etag of
    +     * the currently stored [Backup][google.cloud.secretmanager.v1.Backup].
    +     * 
    + * + * string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for etag to set. + * @return This builder for chaining. + */ + public Builder setEtagBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + etag_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.secretmanager.v1.DeleteBackupRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.secretmanager.v1.DeleteBackupRequest) + private static final com.google.cloud.secretmanager.v1.DeleteBackupRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.secretmanager.v1.DeleteBackupRequest(); + } + + public static com.google.cloud.secretmanager.v1.DeleteBackupRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteBackupRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.DeleteBackupRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/DeleteBackupRequestOrBuilder.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/DeleteBackupRequestOrBuilder.java new file mode 100644 index 000000000000..019951251776 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/DeleteBackupRequestOrBuilder.java @@ -0,0 +1,90 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +@com.google.protobuf.Generated +public interface DeleteBackupRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.secretmanager.v1.DeleteBackupRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] to delete, in the format
    +   * `projects/{project}/locations/{location}/backups/{backup}`.
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] to delete, in the format
    +   * `projects/{project}/locations/{location}/backups/{backup}`.
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
    +   * Optional. If set, the request will only succeed if it matches the etag of
    +   * the currently stored [Backup][google.cloud.secretmanager.v1.Backup].
    +   * 
    + * + * string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The etag. + */ + java.lang.String getEtag(); + + /** + * + * + *
    +   * Optional. If set, the request will only succeed if it matches the etag of
    +   * the currently stored [Backup][google.cloud.secretmanager.v1.Backup].
    +   * 
    + * + * string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for etag. + */ + com.google.protobuf.ByteString getEtagBytes(); +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/GetBackupRequest.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/GetBackupRequest.java new file mode 100644 index 000000000000..64f890f42a30 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/GetBackupRequest.java @@ -0,0 +1,626 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +/** + * + * + *
    + * Request message for
    + * [SecretOperationsService.GetBackup][google.cloud.secretmanager.v1.SecretOperationsService.GetBackup].
    + * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.GetBackupRequest} + */ +@com.google.protobuf.Generated +public final class GetBackupRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.secretmanager.v1.GetBackupRequest) + GetBackupRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "GetBackupRequest"); + } + + // Use GetBackupRequest.newBuilder() to construct. + private GetBackupRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private GetBackupRequest() { + name_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_GetBackupRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_GetBackupRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.GetBackupRequest.class, + com.google.cloud.secretmanager.v1.GetBackupRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup], in the format
    +   * `projects/{project}/locations/{location}/backups/{backup}`.
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup], in the format
    +   * `projects/{project}/locations/{location}/backups/{backup}`.
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.secretmanager.v1.GetBackupRequest)) { + return super.equals(obj); + } + com.google.cloud.secretmanager.v1.GetBackupRequest other = + (com.google.cloud.secretmanager.v1.GetBackupRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.secretmanager.v1.GetBackupRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * Request message for
    +   * [SecretOperationsService.GetBackup][google.cloud.secretmanager.v1.SecretOperationsService.GetBackup].
    +   * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.GetBackupRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.secretmanager.v1.GetBackupRequest) + com.google.cloud.secretmanager.v1.GetBackupRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_GetBackupRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_GetBackupRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.GetBackupRequest.class, + com.google.cloud.secretmanager.v1.GetBackupRequest.Builder.class); + } + + // Construct using com.google.cloud.secretmanager.v1.GetBackupRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_GetBackupRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.GetBackupRequest getDefaultInstanceForType() { + return com.google.cloud.secretmanager.v1.GetBackupRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.GetBackupRequest build() { + com.google.cloud.secretmanager.v1.GetBackupRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.GetBackupRequest buildPartial() { + com.google.cloud.secretmanager.v1.GetBackupRequest result = + new com.google.cloud.secretmanager.v1.GetBackupRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.secretmanager.v1.GetBackupRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.secretmanager.v1.GetBackupRequest) { + return mergeFrom((com.google.cloud.secretmanager.v1.GetBackupRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.secretmanager.v1.GetBackupRequest other) { + if (other == com.google.cloud.secretmanager.v1.GetBackupRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup], in the format
    +     * `projects/{project}/locations/{location}/backups/{backup}`.
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup], in the format
    +     * `projects/{project}/locations/{location}/backups/{backup}`.
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup], in the format
    +     * `projects/{project}/locations/{location}/backups/{backup}`.
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup], in the format
    +     * `projects/{project}/locations/{location}/backups/{backup}`.
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup], in the format
    +     * `projects/{project}/locations/{location}/backups/{backup}`.
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.secretmanager.v1.GetBackupRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.secretmanager.v1.GetBackupRequest) + private static final com.google.cloud.secretmanager.v1.GetBackupRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.secretmanager.v1.GetBackupRequest(); + } + + public static com.google.cloud.secretmanager.v1.GetBackupRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetBackupRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.GetBackupRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/GetBackupRequestOrBuilder.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/GetBackupRequestOrBuilder.java new file mode 100644 index 000000000000..840702f1ba7a --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/GetBackupRequestOrBuilder.java @@ -0,0 +1,62 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +@com.google.protobuf.Generated +public interface GetBackupRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.secretmanager.v1.GetBackupRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup], in the format
    +   * `projects/{project}/locations/{location}/backups/{backup}`.
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup], in the format
    +   * `projects/{project}/locations/{location}/backups/{backup}`.
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsRequest.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsRequest.java new file mode 100644 index 000000000000..e35ddda79cc9 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsRequest.java @@ -0,0 +1,1305 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +/** + * + * + *
    + * Request message for
    + * [SecretOperationsService.ListBackups][google.cloud.secretmanager.v1.SecretOperationsService.ListBackups].
    + * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.ListBackupsRequest} + */ +@com.google.protobuf.Generated +public final class ListBackupsRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.secretmanager.v1.ListBackupsRequest) + ListBackupsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListBackupsRequest"); + } + + // Use ListBackupsRequest.newBuilder() to construct. + private ListBackupsRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListBackupsRequest() { + parent_ = ""; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_ListBackupsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_ListBackupsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.ListBackupsRequest.class, + com.google.cloud.secretmanager.v1.ListBackupsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
    +   * Required. The resource name of the location associated with the
    +   * [Backups][google.cloud.secretmanager.v1.Backup], in the format
    +   * `projects/{project}/locations/{location}`.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + + /** + * + * + *
    +   * Required. The resource name of the location associated with the
    +   * [Backups][google.cloud.secretmanager.v1.Backup], in the format
    +   * `projects/{project}/locations/{location}`.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_ = 0; + + /** + * + * + *
    +   * Optional. Maximum number of backups to return. The service may return fewer
    +   * than this value. If unspecified, at most 50 backups will be returned. The
    +   * maximum value is 1000; values above 1000 will be coerced to 1000.
    +   * 
    + * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object pageToken_ = ""; + + /** + * + * + *
    +   * Optional. A token identifying a page of results the server should return.
    +   * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + + /** + * + * + *
    +   * Optional. A token identifying a page of results the server should return.
    +   * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object filter_ = ""; + + /** + * + * + *
    +   * Optional. Filter expression to restrict the returned
    +   * [Backups][google.cloud.secretmanager.v1.Backup].
    +   * 
    + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + + /** + * + * + *
    +   * Optional. Filter expression to restrict the returned
    +   * [Backups][google.cloud.secretmanager.v1.Backup].
    +   * 
    + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ORDER_BY_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object orderBy_ = ""; + + /** + * + * + *
    +   * Optional. Field specification for sorting the results in the response.
    +   * 
    + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + @java.lang.Override + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } + } + + /** + * + * + *
    +   * Optional. Field specification for sorting the results in the response.
    +   * 
    + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + @java.lang.Override + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, filter_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, orderBy_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, filter_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, orderBy_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.secretmanager.v1.ListBackupsRequest)) { + return super.equals(obj); + } + com.google.cloud.secretmanager.v1.ListBackupsRequest other = + (com.google.cloud.secretmanager.v1.ListBackupsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (37 * hash) + ORDER_BY_FIELD_NUMBER; + hash = (53 * hash) + getOrderBy().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.secretmanager.v1.ListBackupsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * Request message for
    +   * [SecretOperationsService.ListBackups][google.cloud.secretmanager.v1.SecretOperationsService.ListBackups].
    +   * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.ListBackupsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.secretmanager.v1.ListBackupsRequest) + com.google.cloud.secretmanager.v1.ListBackupsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_ListBackupsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_ListBackupsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.ListBackupsRequest.class, + com.google.cloud.secretmanager.v1.ListBackupsRequest.Builder.class); + } + + // Construct using com.google.cloud.secretmanager.v1.ListBackupsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + pageSize_ = 0; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_ListBackupsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.ListBackupsRequest getDefaultInstanceForType() { + return com.google.cloud.secretmanager.v1.ListBackupsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.ListBackupsRequest build() { + com.google.cloud.secretmanager.v1.ListBackupsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.ListBackupsRequest buildPartial() { + com.google.cloud.secretmanager.v1.ListBackupsRequest result = + new com.google.cloud.secretmanager.v1.ListBackupsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.secretmanager.v1.ListBackupsRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.pageSize_ = pageSize_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.pageToken_ = pageToken_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.filter_ = filter_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.orderBy_ = orderBy_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.secretmanager.v1.ListBackupsRequest) { + return mergeFrom((com.google.cloud.secretmanager.v1.ListBackupsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.secretmanager.v1.ListBackupsRequest other) { + if (other == com.google.cloud.secretmanager.v1.ListBackupsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (!other.getOrderBy().isEmpty()) { + orderBy_ = other.orderBy_; + bitField0_ |= 0x00000010; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + filter_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + orderBy_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object parent_ = ""; + + /** + * + * + *
    +     * Required. The resource name of the location associated with the
    +     * [Backups][google.cloud.secretmanager.v1.Backup], in the format
    +     * `projects/{project}/locations/{location}`.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Required. The resource name of the location associated with the
    +     * [Backups][google.cloud.secretmanager.v1.Backup], in the format
    +     * `projects/{project}/locations/{location}`.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Required. The resource name of the location associated with the
    +     * [Backups][google.cloud.secretmanager.v1.Backup], in the format
    +     * `projects/{project}/locations/{location}`.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource name of the location associated with the
    +     * [Backups][google.cloud.secretmanager.v1.Backup], in the format
    +     * `projects/{project}/locations/{location}`.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource name of the location associated with the
    +     * [Backups][google.cloud.secretmanager.v1.Backup], in the format
    +     * `projects/{project}/locations/{location}`.
    +     * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private int pageSize_; + + /** + * + * + *
    +     * Optional. Maximum number of backups to return. The service may return fewer
    +     * than this value. If unspecified, at most 50 backups will be returned. The
    +     * maximum value is 1000; values above 1000 will be coerced to 1000.
    +     * 
    + * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + /** + * + * + *
    +     * Optional. Maximum number of backups to return. The service may return fewer
    +     * than this value. If unspecified, at most 50 backups will be returned. The
    +     * maximum value is 1000; values above 1000 will be coerced to 1000.
    +     * 
    + * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Maximum number of backups to return. The service may return fewer
    +     * than this value. If unspecified, at most 50 backups will be returned. The
    +     * maximum value is 1000; values above 1000 will be coerced to 1000.
    +     * 
    + * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + bitField0_ = (bitField0_ & ~0x00000002); + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + + /** + * + * + *
    +     * Optional. A token identifying a page of results the server should return.
    +     * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Optional. A token identifying a page of results the server should return.
    +     * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Optional. A token identifying a page of results the server should return.
    +     * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. A token identifying a page of results the server should return.
    +     * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + pageToken_ = getDefaultInstance().getPageToken(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. A token identifying a page of results the server should return.
    +     * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + + /** + * + * + *
    +     * Optional. Filter expression to restrict the returned
    +     * [Backups][google.cloud.secretmanager.v1.Backup].
    +     * 
    + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Optional. Filter expression to restrict the returned
    +     * [Backups][google.cloud.secretmanager.v1.Backup].
    +     * 
    + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Optional. Filter expression to restrict the returned
    +     * [Backups][google.cloud.secretmanager.v1.Backup].
    +     * 
    + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Filter expression to restrict the returned
    +     * [Backups][google.cloud.secretmanager.v1.Backup].
    +     * 
    + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + filter_ = getDefaultInstance().getFilter(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Filter expression to restrict the returned
    +     * [Backups][google.cloud.secretmanager.v1.Backup].
    +     * 
    + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private java.lang.Object orderBy_ = ""; + + /** + * + * + *
    +     * Optional. Field specification for sorting the results in the response.
    +     * 
    + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Optional. Field specification for sorting the results in the response.
    +     * 
    + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Optional. Field specification for sorting the results in the response.
    +     * 
    + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderBy(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + orderBy_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Field specification for sorting the results in the response.
    +     * 
    + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearOrderBy() { + orderBy_ = getDefaultInstance().getOrderBy(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Field specification for sorting the results in the response.
    +     * 
    + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + orderBy_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.secretmanager.v1.ListBackupsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.secretmanager.v1.ListBackupsRequest) + private static final com.google.cloud.secretmanager.v1.ListBackupsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.secretmanager.v1.ListBackupsRequest(); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListBackupsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.ListBackupsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsRequestOrBuilder.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsRequestOrBuilder.java new file mode 100644 index 000000000000..b3900548ba07 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsRequestOrBuilder.java @@ -0,0 +1,157 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +@com.google.protobuf.Generated +public interface ListBackupsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.secretmanager.v1.ListBackupsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * Required. The resource name of the location associated with the
    +   * [Backups][google.cloud.secretmanager.v1.Backup], in the format
    +   * `projects/{project}/locations/{location}`.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
    +   * Required. The resource name of the location associated with the
    +   * [Backups][google.cloud.secretmanager.v1.Backup], in the format
    +   * `projects/{project}/locations/{location}`.
    +   * 
    + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
    +   * Optional. Maximum number of backups to return. The service may return fewer
    +   * than this value. If unspecified, at most 50 backups will be returned. The
    +   * maximum value is 1000; values above 1000 will be coerced to 1000.
    +   * 
    + * + * int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
    +   * Optional. A token identifying a page of results the server should return.
    +   * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + + /** + * + * + *
    +   * Optional. A token identifying a page of results the server should return.
    +   * 
    + * + * string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
    +   * Optional. Filter expression to restrict the returned
    +   * [Backups][google.cloud.secretmanager.v1.Backup].
    +   * 
    + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
    +   * Optional. Filter expression to restrict the returned
    +   * [Backups][google.cloud.secretmanager.v1.Backup].
    +   * 
    + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
    +   * Optional. Field specification for sorting the results in the response.
    +   * 
    + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + + /** + * + * + *
    +   * Optional. Field specification for sorting the results in the response.
    +   * 
    + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsResponse.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsResponse.java new file mode 100644 index 000000000000..37c7f6ec2837 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsResponse.java @@ -0,0 +1,1440 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +/** + * + * + *
    + * Response message for
    + * [SecretOperationsService.ListBackups][google.cloud.secretmanager.v1.SecretOperationsService.ListBackups].
    + * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.ListBackupsResponse} + */ +@com.google.protobuf.Generated +public final class ListBackupsResponse extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.secretmanager.v1.ListBackupsResponse) + ListBackupsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "ListBackupsResponse"); + } + + // Use ListBackupsResponse.newBuilder() to construct. + private ListBackupsResponse(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private ListBackupsResponse() { + backups_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_ListBackupsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_ListBackupsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.ListBackupsResponse.class, + com.google.cloud.secretmanager.v1.ListBackupsResponse.Builder.class); + } + + public static final int BACKUPS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List backups_; + + /** + * + * + *
    +   * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +   * location.
    +   * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + @java.lang.Override + public java.util.List getBackupsList() { + return backups_; + } + + /** + * + * + *
    +   * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +   * location.
    +   * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + @java.lang.Override + public java.util.List + getBackupsOrBuilderList() { + return backups_; + } + + /** + * + * + *
    +   * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +   * location.
    +   * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + @java.lang.Override + public int getBackupsCount() { + return backups_.size(); + } + + /** + * + * + *
    +   * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +   * location.
    +   * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.Backup getBackups(int index) { + return backups_.get(index); + } + + /** + * + * + *
    +   * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +   * location.
    +   * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.BackupOrBuilder getBackupsOrBuilder(int index) { + return backups_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
    +   * A token identifying a page of results the server should return.
    +   * 
    + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + + /** + * + * + *
    +   * A token identifying a page of results the server should return.
    +   * 
    + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UNREACHABLE_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList unreachable_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
    +   * Unordered list. Resource names of the unreachable locations.
    +   * Format: `projects/{project}/locations/{location}`
    +   * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_; + } + + /** + * + * + *
    +   * Unordered list. Resource names of the unreachable locations.
    +   * Format: `projects/{project}/locations/{location}`
    +   * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + + /** + * + * + *
    +   * Unordered list. Resource names of the unreachable locations.
    +   * Format: `projects/{project}/locations/{location}`
    +   * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + + /** + * + * + *
    +   * Unordered list. Resource names of the unreachable locations.
    +   * Format: `projects/{project}/locations/{location}`
    +   * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < backups_.size(); i++) { + output.writeMessage(1, backups_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, nextPageToken_); + } + for (int i = 0; i < unreachable_.size(); i++) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, unreachable_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < backups_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, backups_.get(i)); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, nextPageToken_); + } + { + int dataSize = 0; + for (int i = 0; i < unreachable_.size(); i++) { + dataSize += computeStringSizeNoTag(unreachable_.getRaw(i)); + } + size += dataSize; + size += 1 * getUnreachableList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.secretmanager.v1.ListBackupsResponse)) { + return super.equals(obj); + } + com.google.cloud.secretmanager.v1.ListBackupsResponse other = + (com.google.cloud.secretmanager.v1.ListBackupsResponse) obj; + + if (!getBackupsList().equals(other.getBackupsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getBackupsCount() > 0) { + hash = (37 * hash) + BACKUPS_FIELD_NUMBER; + hash = (53 * hash) + getBackupsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (getUnreachableCount() > 0) { + hash = (37 * hash) + UNREACHABLE_FIELD_NUMBER; + hash = (53 * hash) + getUnreachableList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.secretmanager.v1.ListBackupsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * Response message for
    +   * [SecretOperationsService.ListBackups][google.cloud.secretmanager.v1.SecretOperationsService.ListBackups].
    +   * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.ListBackupsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.secretmanager.v1.ListBackupsResponse) + com.google.cloud.secretmanager.v1.ListBackupsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_ListBackupsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_ListBackupsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.ListBackupsResponse.class, + com.google.cloud.secretmanager.v1.ListBackupsResponse.Builder.class); + } + + // Construct using com.google.cloud.secretmanager.v1.ListBackupsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (backupsBuilder_ == null) { + backups_ = java.util.Collections.emptyList(); + } else { + backups_ = null; + backupsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_ListBackupsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.ListBackupsResponse getDefaultInstanceForType() { + return com.google.cloud.secretmanager.v1.ListBackupsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.ListBackupsResponse build() { + com.google.cloud.secretmanager.v1.ListBackupsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.ListBackupsResponse buildPartial() { + com.google.cloud.secretmanager.v1.ListBackupsResponse result = + new com.google.cloud.secretmanager.v1.ListBackupsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.secretmanager.v1.ListBackupsResponse result) { + if (backupsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + backups_ = java.util.Collections.unmodifiableList(backups_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.backups_ = backups_; + } else { + result.backups_ = backupsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.secretmanager.v1.ListBackupsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + unreachable_.makeImmutable(); + result.unreachable_ = unreachable_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.secretmanager.v1.ListBackupsResponse) { + return mergeFrom((com.google.cloud.secretmanager.v1.ListBackupsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.secretmanager.v1.ListBackupsResponse other) { + if (other == com.google.cloud.secretmanager.v1.ListBackupsResponse.getDefaultInstance()) + return this; + if (backupsBuilder_ == null) { + if (!other.backups_.isEmpty()) { + if (backups_.isEmpty()) { + backups_ = other.backups_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureBackupsIsMutable(); + backups_.addAll(other.backups_); + } + onChanged(); + } + } else { + if (!other.backups_.isEmpty()) { + if (backupsBuilder_.isEmpty()) { + backupsBuilder_.dispose(); + backupsBuilder_ = null; + backups_ = other.backups_; + bitField0_ = (bitField0_ & ~0x00000001); + backupsBuilder_ = + com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders + ? internalGetBackupsFieldBuilder() + : null; + } else { + backupsBuilder_.addAllMessages(other.backups_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.unreachable_.isEmpty()) { + if (unreachable_.isEmpty()) { + unreachable_ = other.unreachable_; + bitField0_ |= 0x00000004; + } else { + ensureUnreachableIsMutable(); + unreachable_.addAll(other.unreachable_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.secretmanager.v1.Backup m = + input.readMessage( + com.google.cloud.secretmanager.v1.Backup.parser(), extensionRegistry); + if (backupsBuilder_ == null) { + ensureBackupsIsMutable(); + backups_.add(m); + } else { + backupsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List backups_ = + java.util.Collections.emptyList(); + + private void ensureBackupsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + backups_ = new java.util.ArrayList(backups_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.secretmanager.v1.Backup, + com.google.cloud.secretmanager.v1.Backup.Builder, + com.google.cloud.secretmanager.v1.BackupOrBuilder> + backupsBuilder_; + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public java.util.List getBackupsList() { + if (backupsBuilder_ == null) { + return java.util.Collections.unmodifiableList(backups_); + } else { + return backupsBuilder_.getMessageList(); + } + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public int getBackupsCount() { + if (backupsBuilder_ == null) { + return backups_.size(); + } else { + return backupsBuilder_.getCount(); + } + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public com.google.cloud.secretmanager.v1.Backup getBackups(int index) { + if (backupsBuilder_ == null) { + return backups_.get(index); + } else { + return backupsBuilder_.getMessage(index); + } + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public Builder setBackups(int index, com.google.cloud.secretmanager.v1.Backup value) { + if (backupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureBackupsIsMutable(); + backups_.set(index, value); + onChanged(); + } else { + backupsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public Builder setBackups( + int index, com.google.cloud.secretmanager.v1.Backup.Builder builderForValue) { + if (backupsBuilder_ == null) { + ensureBackupsIsMutable(); + backups_.set(index, builderForValue.build()); + onChanged(); + } else { + backupsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public Builder addBackups(com.google.cloud.secretmanager.v1.Backup value) { + if (backupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureBackupsIsMutable(); + backups_.add(value); + onChanged(); + } else { + backupsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public Builder addBackups(int index, com.google.cloud.secretmanager.v1.Backup value) { + if (backupsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureBackupsIsMutable(); + backups_.add(index, value); + onChanged(); + } else { + backupsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public Builder addBackups(com.google.cloud.secretmanager.v1.Backup.Builder builderForValue) { + if (backupsBuilder_ == null) { + ensureBackupsIsMutable(); + backups_.add(builderForValue.build()); + onChanged(); + } else { + backupsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public Builder addBackups( + int index, com.google.cloud.secretmanager.v1.Backup.Builder builderForValue) { + if (backupsBuilder_ == null) { + ensureBackupsIsMutable(); + backups_.add(index, builderForValue.build()); + onChanged(); + } else { + backupsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public Builder addAllBackups( + java.lang.Iterable values) { + if (backupsBuilder_ == null) { + ensureBackupsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, backups_); + onChanged(); + } else { + backupsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public Builder clearBackups() { + if (backupsBuilder_ == null) { + backups_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + backupsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public Builder removeBackups(int index) { + if (backupsBuilder_ == null) { + ensureBackupsIsMutable(); + backups_.remove(index); + onChanged(); + } else { + backupsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public com.google.cloud.secretmanager.v1.Backup.Builder getBackupsBuilder(int index) { + return internalGetBackupsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public com.google.cloud.secretmanager.v1.BackupOrBuilder getBackupsOrBuilder(int index) { + if (backupsBuilder_ == null) { + return backups_.get(index); + } else { + return backupsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public java.util.List + getBackupsOrBuilderList() { + if (backupsBuilder_ != null) { + return backupsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(backups_); + } + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public com.google.cloud.secretmanager.v1.Backup.Builder addBackupsBuilder() { + return internalGetBackupsFieldBuilder() + .addBuilder(com.google.cloud.secretmanager.v1.Backup.getDefaultInstance()); + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public com.google.cloud.secretmanager.v1.Backup.Builder addBackupsBuilder(int index) { + return internalGetBackupsFieldBuilder() + .addBuilder(index, com.google.cloud.secretmanager.v1.Backup.getDefaultInstance()); + } + + /** + * + * + *
    +     * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +     * location.
    +     * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + public java.util.List + getBackupsBuilderList() { + return internalGetBackupsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.secretmanager.v1.Backup, + com.google.cloud.secretmanager.v1.Backup.Builder, + com.google.cloud.secretmanager.v1.BackupOrBuilder> + internalGetBackupsFieldBuilder() { + if (backupsBuilder_ == null) { + backupsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilder< + com.google.cloud.secretmanager.v1.Backup, + com.google.cloud.secretmanager.v1.Backup.Builder, + com.google.cloud.secretmanager.v1.BackupOrBuilder>( + backups_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + backups_ = null; + } + return backupsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + + /** + * + * + *
    +     * A token identifying a page of results the server should return.
    +     * 
    + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * A token identifying a page of results the server should return.
    +     * 
    + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * A token identifying a page of results the server should return.
    +     * 
    + * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * A token identifying a page of results the server should return.
    +     * 
    + * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + nextPageToken_ = getDefaultInstance().getNextPageToken(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
    +     * A token identifying a page of results the server should return.
    +     * 
    + * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList unreachable_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureUnreachableIsMutable() { + if (!unreachable_.isModifiable()) { + unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); + } + bitField0_ |= 0x00000004; + } + + /** + * + * + *
    +     * Unordered list. Resource names of the unreachable locations.
    +     * Format: `projects/{project}/locations/{location}`
    +     * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + unreachable_.makeImmutable(); + return unreachable_; + } + + /** + * + * + *
    +     * Unordered list. Resource names of the unreachable locations.
    +     * Format: `projects/{project}/locations/{location}`
    +     * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + + /** + * + * + *
    +     * Unordered list. Resource names of the unreachable locations.
    +     * Format: `projects/{project}/locations/{location}`
    +     * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + + /** + * + * + *
    +     * Unordered list. Resource names of the unreachable locations.
    +     * Format: `projects/{project}/locations/{location}`
    +     * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + /** + * + * + *
    +     * Unordered list. Resource names of the unreachable locations.
    +     * Format: `projects/{project}/locations/{location}`
    +     * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index to set the value at. + * @param value The unreachable to set. + * @return This builder for chaining. + */ + public Builder setUnreachable(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.set(index, value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Unordered list. Resource names of the unreachable locations.
    +     * Format: `projects/{project}/locations/{location}`
    +     * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param value The unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Unordered list. Resource names of the unreachable locations.
    +     * Format: `projects/{project}/locations/{location}`
    +     * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param values The unreachable to add. + * @return This builder for chaining. + */ + public Builder addAllUnreachable(java.lang.Iterable values) { + ensureUnreachableIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Unordered list. Resource names of the unreachable locations.
    +     * Format: `projects/{project}/locations/{location}`
    +     * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return This builder for chaining. + */ + public Builder clearUnreachable() { + unreachable_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + ; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Unordered list. Resource names of the unreachable locations.
    +     * Format: `projects/{project}/locations/{location}`
    +     * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param value The bytes of the unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUnreachableIsMutable(); + unreachable_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.secretmanager.v1.ListBackupsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.secretmanager.v1.ListBackupsResponse) + private static final com.google.cloud.secretmanager.v1.ListBackupsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.secretmanager.v1.ListBackupsResponse(); + } + + public static com.google.cloud.secretmanager.v1.ListBackupsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListBackupsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.ListBackupsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsResponseOrBuilder.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsResponseOrBuilder.java new file mode 100644 index 000000000000..1df3fe9746be --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ListBackupsResponseOrBuilder.java @@ -0,0 +1,173 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +@com.google.protobuf.Generated +public interface ListBackupsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.secretmanager.v1.ListBackupsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +   * location.
    +   * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + java.util.List getBackupsList(); + + /** + * + * + *
    +   * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +   * location.
    +   * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + com.google.cloud.secretmanager.v1.Backup getBackups(int index); + + /** + * + * + *
    +   * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +   * location.
    +   * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + int getBackupsCount(); + + /** + * + * + *
    +   * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +   * location.
    +   * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + java.util.List + getBackupsOrBuilderList(); + + /** + * + * + *
    +   * The list of [Backups][google.cloud.secretmanager.v1.Backup] in the
    +   * location.
    +   * 
    + * + * repeated .google.cloud.secretmanager.v1.Backup backups = 1; + */ + com.google.cloud.secretmanager.v1.BackupOrBuilder getBackupsOrBuilder(int index); + + /** + * + * + *
    +   * A token identifying a page of results the server should return.
    +   * 
    + * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + + /** + * + * + *
    +   * A token identifying a page of results the server should return.
    +   * 
    + * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); + + /** + * + * + *
    +   * Unordered list. Resource names of the unreachable locations.
    +   * Format: `projects/{project}/locations/{location}`
    +   * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return A list containing the unreachable. + */ + java.util.List getUnreachableList(); + + /** + * + * + *
    +   * Unordered list. Resource names of the unreachable locations.
    +   * Format: `projects/{project}/locations/{location}`
    +   * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @return The count of unreachable. + */ + int getUnreachableCount(); + + /** + * + * + *
    +   * Unordered list. Resource names of the unreachable locations.
    +   * Format: `projects/{project}/locations/{location}`
    +   * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + java.lang.String getUnreachable(int index); + + /** + * + * + *
    +   * Unordered list. Resource names of the unreachable locations.
    +   * Format: `projects/{project}/locations/{location}`
    +   * 
    + * + * repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + com.google.protobuf.ByteString getUnreachableBytes(int index); +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/OperationMetadata.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/OperationMetadata.java new file mode 100644 index 000000000000..1acf1f25f4b0 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/OperationMetadata.java @@ -0,0 +1,2940 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +/** + * + * + *
    + * Represents the metadata of the long-running operation.
    + * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.OperationMetadata} + */ +@com.google.protobuf.Generated +public final class OperationMetadata extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.secretmanager.v1.OperationMetadata) + OperationMetadataOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "OperationMetadata"); + } + + // Use OperationMetadata.newBuilder() to construct. + private OperationMetadata(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private OperationMetadata() { + target_ = ""; + verb_ = ""; + statusMessage_ = ""; + apiVersion_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_OperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_OperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.OperationMetadata.class, + com.google.cloud.secretmanager.v1.OperationMetadata.Builder.class); + } + + public interface ProgressOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.secretmanager.v1.OperationMetadata.Progress) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +     * Output only. Provides the total number of secret versions to be processed
    +     * by the operation.
    +     * 
    + * + * int32 total_version_count = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The totalVersionCount. + */ + int getTotalVersionCount(); + + /** + * + * + *
    +     * Output only. Number of secret versions that have been successfully
    +     * processed so far.
    +     * 
    + * + * int32 completed_version_count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The completedVersionCount. + */ + int getCompletedVersionCount(); + + /** + * + * + *
    +     * Output only. Number of secret versions that failed to process.
    +     * 
    + * + * int32 failed_version_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The failedVersionCount. + */ + int getFailedVersionCount(); + } + + /** + * + * + *
    +   * Represents progress information for operations involving multiple secret
    +   * versions.
    +   * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.OperationMetadata.Progress} + */ + public static final class Progress extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.secretmanager.v1.OperationMetadata.Progress) + ProgressOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "Progress"); + } + + // Use Progress.newBuilder() to construct. + private Progress(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private Progress() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_OperationMetadata_Progress_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_OperationMetadata_Progress_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.OperationMetadata.Progress.class, + com.google.cloud.secretmanager.v1.OperationMetadata.Progress.Builder.class); + } + + public static final int TOTAL_VERSION_COUNT_FIELD_NUMBER = 1; + private int totalVersionCount_ = 0; + + /** + * + * + *
    +     * Output only. Provides the total number of secret versions to be processed
    +     * by the operation.
    +     * 
    + * + * int32 total_version_count = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The totalVersionCount. + */ + @java.lang.Override + public int getTotalVersionCount() { + return totalVersionCount_; + } + + public static final int COMPLETED_VERSION_COUNT_FIELD_NUMBER = 2; + private int completedVersionCount_ = 0; + + /** + * + * + *
    +     * Output only. Number of secret versions that have been successfully
    +     * processed so far.
    +     * 
    + * + * int32 completed_version_count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The completedVersionCount. + */ + @java.lang.Override + public int getCompletedVersionCount() { + return completedVersionCount_; + } + + public static final int FAILED_VERSION_COUNT_FIELD_NUMBER = 3; + private int failedVersionCount_ = 0; + + /** + * + * + *
    +     * Output only. Number of secret versions that failed to process.
    +     * 
    + * + * int32 failed_version_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The failedVersionCount. + */ + @java.lang.Override + public int getFailedVersionCount() { + return failedVersionCount_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (totalVersionCount_ != 0) { + output.writeInt32(1, totalVersionCount_); + } + if (completedVersionCount_ != 0) { + output.writeInt32(2, completedVersionCount_); + } + if (failedVersionCount_ != 0) { + output.writeInt32(3, failedVersionCount_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (totalVersionCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(1, totalVersionCount_); + } + if (completedVersionCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, completedVersionCount_); + } + if (failedVersionCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, failedVersionCount_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.secretmanager.v1.OperationMetadata.Progress)) { + return super.equals(obj); + } + com.google.cloud.secretmanager.v1.OperationMetadata.Progress other = + (com.google.cloud.secretmanager.v1.OperationMetadata.Progress) obj; + + if (getTotalVersionCount() != other.getTotalVersionCount()) return false; + if (getCompletedVersionCount() != other.getCompletedVersionCount()) return false; + if (getFailedVersionCount() != other.getFailedVersionCount()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TOTAL_VERSION_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getTotalVersionCount(); + hash = (37 * hash) + COMPLETED_VERSION_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getCompletedVersionCount(); + hash = (37 * hash) + FAILED_VERSION_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getFailedVersionCount(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.secretmanager.v1.OperationMetadata.Progress prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +     * Represents progress information for operations involving multiple secret
    +     * versions.
    +     * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.OperationMetadata.Progress} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.secretmanager.v1.OperationMetadata.Progress) + com.google.cloud.secretmanager.v1.OperationMetadata.ProgressOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_OperationMetadata_Progress_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_OperationMetadata_Progress_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.OperationMetadata.Progress.class, + com.google.cloud.secretmanager.v1.OperationMetadata.Progress.Builder.class); + } + + // Construct using com.google.cloud.secretmanager.v1.OperationMetadata.Progress.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + totalVersionCount_ = 0; + completedVersionCount_ = 0; + failedVersionCount_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_OperationMetadata_Progress_descriptor; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.OperationMetadata.Progress + getDefaultInstanceForType() { + return com.google.cloud.secretmanager.v1.OperationMetadata.Progress.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.OperationMetadata.Progress build() { + com.google.cloud.secretmanager.v1.OperationMetadata.Progress result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.OperationMetadata.Progress buildPartial() { + com.google.cloud.secretmanager.v1.OperationMetadata.Progress result = + new com.google.cloud.secretmanager.v1.OperationMetadata.Progress(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.secretmanager.v1.OperationMetadata.Progress result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.totalVersionCount_ = totalVersionCount_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.completedVersionCount_ = completedVersionCount_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.failedVersionCount_ = failedVersionCount_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.secretmanager.v1.OperationMetadata.Progress) { + return mergeFrom((com.google.cloud.secretmanager.v1.OperationMetadata.Progress) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.secretmanager.v1.OperationMetadata.Progress other) { + if (other + == com.google.cloud.secretmanager.v1.OperationMetadata.Progress.getDefaultInstance()) + return this; + if (other.getTotalVersionCount() != 0) { + setTotalVersionCount(other.getTotalVersionCount()); + } + if (other.getCompletedVersionCount() != 0) { + setCompletedVersionCount(other.getCompletedVersionCount()); + } + if (other.getFailedVersionCount() != 0) { + setFailedVersionCount(other.getFailedVersionCount()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + totalVersionCount_ = input.readInt32(); + bitField0_ |= 0x00000001; + break; + } // case 8 + case 16: + { + completedVersionCount_ = input.readInt32(); + bitField0_ |= 0x00000002; + break; + } // case 16 + case 24: + { + failedVersionCount_ = input.readInt32(); + bitField0_ |= 0x00000004; + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private int totalVersionCount_; + + /** + * + * + *
    +       * Output only. Provides the total number of secret versions to be processed
    +       * by the operation.
    +       * 
    + * + * int32 total_version_count = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The totalVersionCount. + */ + @java.lang.Override + public int getTotalVersionCount() { + return totalVersionCount_; + } + + /** + * + * + *
    +       * Output only. Provides the total number of secret versions to be processed
    +       * by the operation.
    +       * 
    + * + * int32 total_version_count = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The totalVersionCount to set. + * @return This builder for chaining. + */ + public Builder setTotalVersionCount(int value) { + + totalVersionCount_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +       * Output only. Provides the total number of secret versions to be processed
    +       * by the operation.
    +       * 
    + * + * int32 total_version_count = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearTotalVersionCount() { + bitField0_ = (bitField0_ & ~0x00000001); + totalVersionCount_ = 0; + onChanged(); + return this; + } + + private int completedVersionCount_; + + /** + * + * + *
    +       * Output only. Number of secret versions that have been successfully
    +       * processed so far.
    +       * 
    + * + * int32 completed_version_count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The completedVersionCount. + */ + @java.lang.Override + public int getCompletedVersionCount() { + return completedVersionCount_; + } + + /** + * + * + *
    +       * Output only. Number of secret versions that have been successfully
    +       * processed so far.
    +       * 
    + * + * int32 completed_version_count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The completedVersionCount to set. + * @return This builder for chaining. + */ + public Builder setCompletedVersionCount(int value) { + + completedVersionCount_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +       * Output only. Number of secret versions that have been successfully
    +       * processed so far.
    +       * 
    + * + * int32 completed_version_count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearCompletedVersionCount() { + bitField0_ = (bitField0_ & ~0x00000002); + completedVersionCount_ = 0; + onChanged(); + return this; + } + + private int failedVersionCount_; + + /** + * + * + *
    +       * Output only. Number of secret versions that failed to process.
    +       * 
    + * + * int32 failed_version_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The failedVersionCount. + */ + @java.lang.Override + public int getFailedVersionCount() { + return failedVersionCount_; + } + + /** + * + * + *
    +       * Output only. Number of secret versions that failed to process.
    +       * 
    + * + * int32 failed_version_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The failedVersionCount to set. + * @return This builder for chaining. + */ + public Builder setFailedVersionCount(int value) { + + failedVersionCount_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +       * Output only. Number of secret versions that failed to process.
    +       * 
    + * + * int32 failed_version_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearFailedVersionCount() { + bitField0_ = (bitField0_ & ~0x00000004); + failedVersionCount_ = 0; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.secretmanager.v1.OperationMetadata.Progress) + } + + // @@protoc_insertion_point(class_scope:google.cloud.secretmanager.v1.OperationMetadata.Progress) + private static final com.google.cloud.secretmanager.v1.OperationMetadata.Progress + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.secretmanager.v1.OperationMetadata.Progress(); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata.Progress + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Progress parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.OperationMetadata.Progress + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int CREATE_TIME_FIELD_NUMBER = 1; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
    +   * Output only. Time the operation was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +   * Output only. Time the operation was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + /** + * + * + *
    +   * Output only. Time the operation was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + + public static final int END_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp endTime_; + + /** + * + * + *
    +   * Output only. Time the operation finished running.
    +   * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the endTime field is set. + */ + @java.lang.Override + public boolean hasEndTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
    +   * Output only. Time the operation finished running.
    +   * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The endTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getEndTime() { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + + /** + * + * + *
    +   * Output only. Time the operation finished running.
    +   * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + + public static final int TARGET_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object target_ = ""; + + /** + * + * + *
    +   * Output only. Server-defined resource path for the target of the operation.
    +   * 
    + * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + @java.lang.Override + public java.lang.String getTarget() { + java.lang.Object ref = target_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + target_ = s; + return s; + } + } + + /** + * + * + *
    +   * Output only. Server-defined resource path for the target of the operation.
    +   * 
    + * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTargetBytes() { + java.lang.Object ref = target_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + target_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VERB_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object verb_ = ""; + + /** + * + * + *
    +   * Output only. Name of the verb executed by the operation.
    +   * 
    + * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The verb. + */ + @java.lang.Override + public java.lang.String getVerb() { + java.lang.Object ref = verb_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + verb_ = s; + return s; + } + } + + /** + * + * + *
    +   * Output only. Name of the verb executed by the operation.
    +   * 
    + * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for verb. + */ + @java.lang.Override + public com.google.protobuf.ByteString getVerbBytes() { + java.lang.Object ref = verb_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + verb_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STATUS_MESSAGE_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object statusMessage_ = ""; + + /** + * + * + *
    +   * Output only. Human-readable status of the operation, if any.
    +   * 
    + * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The statusMessage. + */ + @java.lang.Override + public java.lang.String getStatusMessage() { + java.lang.Object ref = statusMessage_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + statusMessage_ = s; + return s; + } + } + + /** + * + * + *
    +   * Output only. Human-readable status of the operation, if any.
    +   * 
    + * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for statusMessage. + */ + @java.lang.Override + public com.google.protobuf.ByteString getStatusMessageBytes() { + java.lang.Object ref = statusMessage_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + statusMessage_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int REQUESTED_CANCELLATION_FIELD_NUMBER = 6; + private boolean requestedCancellation_ = false; + + /** + * + * + *
    +   * Output only. Identifies whether the user has requested cancellation
    +   * of the operation. Operations that have been cancelled successfully
    +   * have
    +   * [google.longrunning.Operation.error][google.longrunning.Operation.error]
    +   * value with a [google.rpc.Status.code][google.rpc.Status.code] of `1`,
    +   * corresponding to `Code.CANCELLED`.
    +   * 
    + * + * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The requestedCancellation. + */ + @java.lang.Override + public boolean getRequestedCancellation() { + return requestedCancellation_; + } + + public static final int API_VERSION_FIELD_NUMBER = 7; + + @SuppressWarnings("serial") + private volatile java.lang.Object apiVersion_ = ""; + + /** + * + * + *
    +   * Output only. API version used to start the operation.
    +   * 
    + * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The apiVersion. + */ + @java.lang.Override + public java.lang.String getApiVersion() { + java.lang.Object ref = apiVersion_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + apiVersion_ = s; + return s; + } + } + + /** + * + * + *
    +   * Output only. API version used to start the operation.
    +   * 
    + * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for apiVersion. + */ + @java.lang.Override + public com.google.protobuf.ByteString getApiVersionBytes() { + java.lang.Object ref = apiVersion_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + apiVersion_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PROGRESS_FIELD_NUMBER = 8; + private com.google.cloud.secretmanager.v1.OperationMetadata.Progress progress_; + + /** + * + * + *
    +   * Output only. Represents the progress of the operation. This field is
    +   * populated for operations that involve processing multiple secret versions.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the progress field is set. + */ + @java.lang.Override + public boolean hasProgress() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
    +   * Output only. Represents the progress of the operation. This field is
    +   * populated for operations that involve processing multiple secret versions.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The progress. + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.OperationMetadata.Progress getProgress() { + return progress_ == null + ? com.google.cloud.secretmanager.v1.OperationMetadata.Progress.getDefaultInstance() + : progress_; + } + + /** + * + * + *
    +   * Output only. Represents the progress of the operation. This field is
    +   * populated for operations that involve processing multiple secret versions.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.OperationMetadata.ProgressOrBuilder + getProgressOrBuilder() { + return progress_ == null + ? com.google.cloud.secretmanager.v1.OperationMetadata.Progress.getDefaultInstance() + : progress_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getEndTime()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(target_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, target_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(verb_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, verb_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(statusMessage_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 5, statusMessage_); + } + if (requestedCancellation_ != false) { + output.writeBool(6, requestedCancellation_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(apiVersion_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 7, apiVersion_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(8, getProgress()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getEndTime()); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(target_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, target_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(verb_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, verb_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(statusMessage_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(5, statusMessage_); + } + if (requestedCancellation_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, requestedCancellation_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(apiVersion_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(7, apiVersion_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getProgress()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.secretmanager.v1.OperationMetadata)) { + return super.equals(obj); + } + com.google.cloud.secretmanager.v1.OperationMetadata other = + (com.google.cloud.secretmanager.v1.OperationMetadata) obj; + + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasEndTime() != other.hasEndTime()) return false; + if (hasEndTime()) { + if (!getEndTime().equals(other.getEndTime())) return false; + } + if (!getTarget().equals(other.getTarget())) return false; + if (!getVerb().equals(other.getVerb())) return false; + if (!getStatusMessage().equals(other.getStatusMessage())) return false; + if (getRequestedCancellation() != other.getRequestedCancellation()) return false; + if (!getApiVersion().equals(other.getApiVersion())) return false; + if (hasProgress() != other.hasProgress()) return false; + if (hasProgress()) { + if (!getProgress().equals(other.getProgress())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasEndTime()) { + hash = (37 * hash) + END_TIME_FIELD_NUMBER; + hash = (53 * hash) + getEndTime().hashCode(); + } + hash = (37 * hash) + TARGET_FIELD_NUMBER; + hash = (53 * hash) + getTarget().hashCode(); + hash = (37 * hash) + VERB_FIELD_NUMBER; + hash = (53 * hash) + getVerb().hashCode(); + hash = (37 * hash) + STATUS_MESSAGE_FIELD_NUMBER; + hash = (53 * hash) + getStatusMessage().hashCode(); + hash = (37 * hash) + REQUESTED_CANCELLATION_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getRequestedCancellation()); + hash = (37 * hash) + API_VERSION_FIELD_NUMBER; + hash = (53 * hash) + getApiVersion().hashCode(); + if (hasProgress()) { + hash = (37 * hash) + PROGRESS_FIELD_NUMBER; + hash = (53 * hash) + getProgress().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.secretmanager.v1.OperationMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * Represents the metadata of the long-running operation.
    +   * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.OperationMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.secretmanager.v1.OperationMetadata) + com.google.cloud.secretmanager.v1.OperationMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_OperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_OperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.OperationMetadata.class, + com.google.cloud.secretmanager.v1.OperationMetadata.Builder.class); + } + + // Construct using com.google.cloud.secretmanager.v1.OperationMetadata.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetCreateTimeFieldBuilder(); + internalGetEndTimeFieldBuilder(); + internalGetProgressFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + endTime_ = null; + if (endTimeBuilder_ != null) { + endTimeBuilder_.dispose(); + endTimeBuilder_ = null; + } + target_ = ""; + verb_ = ""; + statusMessage_ = ""; + requestedCancellation_ = false; + apiVersion_ = ""; + progress_ = null; + if (progressBuilder_ != null) { + progressBuilder_.dispose(); + progressBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_OperationMetadata_descriptor; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.OperationMetadata getDefaultInstanceForType() { + return com.google.cloud.secretmanager.v1.OperationMetadata.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.OperationMetadata build() { + com.google.cloud.secretmanager.v1.OperationMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.OperationMetadata buildPartial() { + com.google.cloud.secretmanager.v1.OperationMetadata result = + new com.google.cloud.secretmanager.v1.OperationMetadata(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.secretmanager.v1.OperationMetadata result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.endTime_ = endTimeBuilder_ == null ? endTime_ : endTimeBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.target_ = target_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.verb_ = verb_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.statusMessage_ = statusMessage_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.requestedCancellation_ = requestedCancellation_; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.apiVersion_ = apiVersion_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.progress_ = progressBuilder_ == null ? progress_ : progressBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.secretmanager.v1.OperationMetadata) { + return mergeFrom((com.google.cloud.secretmanager.v1.OperationMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.secretmanager.v1.OperationMetadata other) { + if (other == com.google.cloud.secretmanager.v1.OperationMetadata.getDefaultInstance()) + return this; + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasEndTime()) { + mergeEndTime(other.getEndTime()); + } + if (!other.getTarget().isEmpty()) { + target_ = other.target_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getVerb().isEmpty()) { + verb_ = other.verb_; + bitField0_ |= 0x00000008; + onChanged(); + } + if (!other.getStatusMessage().isEmpty()) { + statusMessage_ = other.statusMessage_; + bitField0_ |= 0x00000010; + onChanged(); + } + if (other.getRequestedCancellation() != false) { + setRequestedCancellation(other.getRequestedCancellation()); + } + if (!other.getApiVersion().isEmpty()) { + apiVersion_ = other.apiVersion_; + bitField0_ |= 0x00000040; + onChanged(); + } + if (other.hasProgress()) { + mergeProgress(other.getProgress()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage(internalGetEndTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + target_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + verb_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + statusMessage_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 48: + { + requestedCancellation_ = input.readBool(); + bitField0_ |= 0x00000020; + break; + } // case 48 + case 58: + { + apiVersion_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000040; + break; + } // case 58 + case 66: + { + input.readMessage( + internalGetProgressFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000080; + break; + } // case 66 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
    +     * Output only. Time the operation was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +     * Output only. Time the operation was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Output only. Time the operation was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + } else { + createTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time the operation was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time the operation was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && createTime_ != null + && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getCreateTimeBuilder().mergeFrom(value); + } else { + createTime_ = value; + } + } else { + createTimeBuilder_.mergeFrom(value); + } + if (createTime_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Output only. Time the operation was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + bitField0_ = (bitField0_ & ~0x00000001); + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time the operation was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Output only. Time the operation was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + + /** + * + * + *
    +     * Output only. Time the operation was created.
    +     * 
    + * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp endTime_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + endTimeBuilder_; + + /** + * + * + *
    +     * Output only. Time the operation finished running.
    +     * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the endTime field is set. + */ + public boolean hasEndTime() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
    +     * Output only. Time the operation finished running.
    +     * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The endTime. + */ + public com.google.protobuf.Timestamp getEndTime() { + if (endTimeBuilder_ == null) { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } else { + return endTimeBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Output only. Time the operation finished running.
    +     * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + endTime_ = value; + } else { + endTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time the operation finished running.
    +     * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setEndTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (endTimeBuilder_ == null) { + endTime_ = builderForValue.build(); + } else { + endTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time the operation finished running.
    +     * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && endTime_ != null + && endTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getEndTimeBuilder().mergeFrom(value); + } else { + endTime_ = value; + } + } else { + endTimeBuilder_.mergeFrom(value); + } + if (endTime_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Output only. Time the operation finished running.
    +     * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearEndTime() { + bitField0_ = (bitField0_ & ~0x00000002); + endTime_ = null; + if (endTimeBuilder_ != null) { + endTimeBuilder_.dispose(); + endTimeBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Time the operation finished running.
    +     * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getEndTimeBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetEndTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Output only. Time the operation finished running.
    +     * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + if (endTimeBuilder_ != null) { + return endTimeBuilder_.getMessageOrBuilder(); + } else { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + } + + /** + * + * + *
    +     * Output only. Time the operation finished running.
    +     * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + internalGetEndTimeFieldBuilder() { + if (endTimeBuilder_ == null) { + endTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getEndTime(), getParentForChildren(), isClean()); + endTime_ = null; + } + return endTimeBuilder_; + } + + private java.lang.Object target_ = ""; + + /** + * + * + *
    +     * Output only. Server-defined resource path for the target of the operation.
    +     * 
    + * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + public java.lang.String getTarget() { + java.lang.Object ref = target_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + target_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Output only. Server-defined resource path for the target of the operation.
    +     * 
    + * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + public com.google.protobuf.ByteString getTargetBytes() { + java.lang.Object ref = target_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + target_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Output only. Server-defined resource path for the target of the operation.
    +     * 
    + * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The target to set. + * @return This builder for chaining. + */ + public Builder setTarget(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + target_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Server-defined resource path for the target of the operation.
    +     * 
    + * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearTarget() { + target_ = getDefaultInstance().getTarget(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Server-defined resource path for the target of the operation.
    +     * 
    + * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for target to set. + * @return This builder for chaining. + */ + public Builder setTargetBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + target_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object verb_ = ""; + + /** + * + * + *
    +     * Output only. Name of the verb executed by the operation.
    +     * 
    + * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The verb. + */ + public java.lang.String getVerb() { + java.lang.Object ref = verb_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + verb_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Output only. Name of the verb executed by the operation.
    +     * 
    + * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for verb. + */ + public com.google.protobuf.ByteString getVerbBytes() { + java.lang.Object ref = verb_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + verb_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Output only. Name of the verb executed by the operation.
    +     * 
    + * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The verb to set. + * @return This builder for chaining. + */ + public Builder setVerb(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + verb_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Name of the verb executed by the operation.
    +     * 
    + * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearVerb() { + verb_ = getDefaultInstance().getVerb(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Name of the verb executed by the operation.
    +     * 
    + * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for verb to set. + * @return This builder for chaining. + */ + public Builder setVerbBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + verb_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private java.lang.Object statusMessage_ = ""; + + /** + * + * + *
    +     * Output only. Human-readable status of the operation, if any.
    +     * 
    + * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The statusMessage. + */ + public java.lang.String getStatusMessage() { + java.lang.Object ref = statusMessage_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + statusMessage_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Output only. Human-readable status of the operation, if any.
    +     * 
    + * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for statusMessage. + */ + public com.google.protobuf.ByteString getStatusMessageBytes() { + java.lang.Object ref = statusMessage_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + statusMessage_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Output only. Human-readable status of the operation, if any.
    +     * 
    + * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The statusMessage to set. + * @return This builder for chaining. + */ + public Builder setStatusMessage(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + statusMessage_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Human-readable status of the operation, if any.
    +     * 
    + * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearStatusMessage() { + statusMessage_ = getDefaultInstance().getStatusMessage(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Human-readable status of the operation, if any.
    +     * 
    + * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for statusMessage to set. + * @return This builder for chaining. + */ + public Builder setStatusMessageBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + statusMessage_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private boolean requestedCancellation_; + + /** + * + * + *
    +     * Output only. Identifies whether the user has requested cancellation
    +     * of the operation. Operations that have been cancelled successfully
    +     * have
    +     * [google.longrunning.Operation.error][google.longrunning.Operation.error]
    +     * value with a [google.rpc.Status.code][google.rpc.Status.code] of `1`,
    +     * corresponding to `Code.CANCELLED`.
    +     * 
    + * + * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The requestedCancellation. + */ + @java.lang.Override + public boolean getRequestedCancellation() { + return requestedCancellation_; + } + + /** + * + * + *
    +     * Output only. Identifies whether the user has requested cancellation
    +     * of the operation. Operations that have been cancelled successfully
    +     * have
    +     * [google.longrunning.Operation.error][google.longrunning.Operation.error]
    +     * value with a [google.rpc.Status.code][google.rpc.Status.code] of `1`,
    +     * corresponding to `Code.CANCELLED`.
    +     * 
    + * + * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The requestedCancellation to set. + * @return This builder for chaining. + */ + public Builder setRequestedCancellation(boolean value) { + + requestedCancellation_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Identifies whether the user has requested cancellation
    +     * of the operation. Operations that have been cancelled successfully
    +     * have
    +     * [google.longrunning.Operation.error][google.longrunning.Operation.error]
    +     * value with a [google.rpc.Status.code][google.rpc.Status.code] of `1`,
    +     * corresponding to `Code.CANCELLED`.
    +     * 
    + * + * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearRequestedCancellation() { + bitField0_ = (bitField0_ & ~0x00000020); + requestedCancellation_ = false; + onChanged(); + return this; + } + + private java.lang.Object apiVersion_ = ""; + + /** + * + * + *
    +     * Output only. API version used to start the operation.
    +     * 
    + * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The apiVersion. + */ + public java.lang.String getApiVersion() { + java.lang.Object ref = apiVersion_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + apiVersion_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Output only. API version used to start the operation.
    +     * 
    + * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for apiVersion. + */ + public com.google.protobuf.ByteString getApiVersionBytes() { + java.lang.Object ref = apiVersion_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + apiVersion_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Output only. API version used to start the operation.
    +     * 
    + * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The apiVersion to set. + * @return This builder for chaining. + */ + public Builder setApiVersion(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + apiVersion_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. API version used to start the operation.
    +     * 
    + * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearApiVersion() { + apiVersion_ = getDefaultInstance().getApiVersion(); + bitField0_ = (bitField0_ & ~0x00000040); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. API version used to start the operation.
    +     * 
    + * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for apiVersion to set. + * @return This builder for chaining. + */ + public Builder setApiVersionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + apiVersion_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + private com.google.cloud.secretmanager.v1.OperationMetadata.Progress progress_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.secretmanager.v1.OperationMetadata.Progress, + com.google.cloud.secretmanager.v1.OperationMetadata.Progress.Builder, + com.google.cloud.secretmanager.v1.OperationMetadata.ProgressOrBuilder> + progressBuilder_; + + /** + * + * + *
    +     * Output only. Represents the progress of the operation. This field is
    +     * populated for operations that involve processing multiple secret versions.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the progress field is set. + */ + public boolean hasProgress() { + return ((bitField0_ & 0x00000080) != 0); + } + + /** + * + * + *
    +     * Output only. Represents the progress of the operation. This field is
    +     * populated for operations that involve processing multiple secret versions.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The progress. + */ + public com.google.cloud.secretmanager.v1.OperationMetadata.Progress getProgress() { + if (progressBuilder_ == null) { + return progress_ == null + ? com.google.cloud.secretmanager.v1.OperationMetadata.Progress.getDefaultInstance() + : progress_; + } else { + return progressBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Output only. Represents the progress of the operation. This field is
    +     * populated for operations that involve processing multiple secret versions.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setProgress(com.google.cloud.secretmanager.v1.OperationMetadata.Progress value) { + if (progressBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + progress_ = value; + } else { + progressBuilder_.setMessage(value); + } + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Represents the progress of the operation. This field is
    +     * populated for operations that involve processing multiple secret versions.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setProgress( + com.google.cloud.secretmanager.v1.OperationMetadata.Progress.Builder builderForValue) { + if (progressBuilder_ == null) { + progress_ = builderForValue.build(); + } else { + progressBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Represents the progress of the operation. This field is
    +     * populated for operations that involve processing multiple secret versions.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeProgress( + com.google.cloud.secretmanager.v1.OperationMetadata.Progress value) { + if (progressBuilder_ == null) { + if (((bitField0_ & 0x00000080) != 0) + && progress_ != null + && progress_ + != com.google.cloud.secretmanager.v1.OperationMetadata.Progress + .getDefaultInstance()) { + getProgressBuilder().mergeFrom(value); + } else { + progress_ = value; + } + } else { + progressBuilder_.mergeFrom(value); + } + if (progress_ != null) { + bitField0_ |= 0x00000080; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Output only. Represents the progress of the operation. This field is
    +     * populated for operations that involve processing multiple secret versions.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearProgress() { + bitField0_ = (bitField0_ & ~0x00000080); + progress_ = null; + if (progressBuilder_ != null) { + progressBuilder_.dispose(); + progressBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. Represents the progress of the operation. This field is
    +     * populated for operations that involve processing multiple secret versions.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.secretmanager.v1.OperationMetadata.Progress.Builder + getProgressBuilder() { + bitField0_ |= 0x00000080; + onChanged(); + return internalGetProgressFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Output only. Represents the progress of the operation. This field is
    +     * populated for operations that involve processing multiple secret versions.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.secretmanager.v1.OperationMetadata.ProgressOrBuilder + getProgressOrBuilder() { + if (progressBuilder_ != null) { + return progressBuilder_.getMessageOrBuilder(); + } else { + return progress_ == null + ? com.google.cloud.secretmanager.v1.OperationMetadata.Progress.getDefaultInstance() + : progress_; + } + } + + /** + * + * + *
    +     * Output only. Represents the progress of the operation. This field is
    +     * populated for operations that involve processing multiple secret versions.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.secretmanager.v1.OperationMetadata.Progress, + com.google.cloud.secretmanager.v1.OperationMetadata.Progress.Builder, + com.google.cloud.secretmanager.v1.OperationMetadata.ProgressOrBuilder> + internalGetProgressFieldBuilder() { + if (progressBuilder_ == null) { + progressBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.secretmanager.v1.OperationMetadata.Progress, + com.google.cloud.secretmanager.v1.OperationMetadata.Progress.Builder, + com.google.cloud.secretmanager.v1.OperationMetadata.ProgressOrBuilder>( + getProgress(), getParentForChildren(), isClean()); + progress_ = null; + } + return progressBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.secretmanager.v1.OperationMetadata) + } + + // @@protoc_insertion_point(class_scope:google.cloud.secretmanager.v1.OperationMetadata) + private static final com.google.cloud.secretmanager.v1.OperationMetadata DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.secretmanager.v1.OperationMetadata(); + } + + public static com.google.cloud.secretmanager.v1.OperationMetadata getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public OperationMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.OperationMetadata getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/OperationMetadataOrBuilder.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/OperationMetadataOrBuilder.java new file mode 100644 index 000000000000..9ca438912d38 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/OperationMetadataOrBuilder.java @@ -0,0 +1,276 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +@com.google.protobuf.Generated +public interface OperationMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.secretmanager.v1.OperationMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * Output only. Time the operation was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + + /** + * + * + *
    +   * Output only. Time the operation was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + + /** + * + * + *
    +   * Output only. Time the operation was created.
    +   * 
    + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
    +   * Output only. Time the operation finished running.
    +   * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the endTime field is set. + */ + boolean hasEndTime(); + + /** + * + * + *
    +   * Output only. Time the operation finished running.
    +   * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The endTime. + */ + com.google.protobuf.Timestamp getEndTime(); + + /** + * + * + *
    +   * Output only. Time the operation finished running.
    +   * 
    + * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder(); + + /** + * + * + *
    +   * Output only. Server-defined resource path for the target of the operation.
    +   * 
    + * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + java.lang.String getTarget(); + + /** + * + * + *
    +   * Output only. Server-defined resource path for the target of the operation.
    +   * 
    + * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + com.google.protobuf.ByteString getTargetBytes(); + + /** + * + * + *
    +   * Output only. Name of the verb executed by the operation.
    +   * 
    + * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The verb. + */ + java.lang.String getVerb(); + + /** + * + * + *
    +   * Output only. Name of the verb executed by the operation.
    +   * 
    + * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for verb. + */ + com.google.protobuf.ByteString getVerbBytes(); + + /** + * + * + *
    +   * Output only. Human-readable status of the operation, if any.
    +   * 
    + * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The statusMessage. + */ + java.lang.String getStatusMessage(); + + /** + * + * + *
    +   * Output only. Human-readable status of the operation, if any.
    +   * 
    + * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for statusMessage. + */ + com.google.protobuf.ByteString getStatusMessageBytes(); + + /** + * + * + *
    +   * Output only. Identifies whether the user has requested cancellation
    +   * of the operation. Operations that have been cancelled successfully
    +   * have
    +   * [google.longrunning.Operation.error][google.longrunning.Operation.error]
    +   * value with a [google.rpc.Status.code][google.rpc.Status.code] of `1`,
    +   * corresponding to `Code.CANCELLED`.
    +   * 
    + * + * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The requestedCancellation. + */ + boolean getRequestedCancellation(); + + /** + * + * + *
    +   * Output only. API version used to start the operation.
    +   * 
    + * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The apiVersion. + */ + java.lang.String getApiVersion(); + + /** + * + * + *
    +   * Output only. API version used to start the operation.
    +   * 
    + * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for apiVersion. + */ + com.google.protobuf.ByteString getApiVersionBytes(); + + /** + * + * + *
    +   * Output only. Represents the progress of the operation. This field is
    +   * populated for operations that involve processing multiple secret versions.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the progress field is set. + */ + boolean hasProgress(); + + /** + * + * + *
    +   * Output only. Represents the progress of the operation. This field is
    +   * populated for operations that involve processing multiple secret versions.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The progress. + */ + com.google.cloud.secretmanager.v1.OperationMetadata.Progress getProgress(); + + /** + * + * + *
    +   * Output only. Represents the progress of the operation. This field is
    +   * populated for operations that involve processing multiple secret versions.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.OperationMetadata.Progress progress = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.secretmanager.v1.OperationMetadata.ProgressOrBuilder getProgressOrBuilder(); +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/OperationsServiceProto.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/OperationsServiceProto.java new file mode 100644 index 000000000000..1b4ce5f3d65b --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/OperationsServiceProto.java @@ -0,0 +1,363 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +@com.google.protobuf.Generated +public final class OperationsServiceProto extends com.google.protobuf.GeneratedFile { + private OperationsServiceProto() {} + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "OperationsServiceProto"); + } + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_secretmanager_v1_ListBackupsRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_secretmanager_v1_ListBackupsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_secretmanager_v1_ListBackupsResponse_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_secretmanager_v1_ListBackupsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_secretmanager_v1_GetBackupRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_secretmanager_v1_GetBackupRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_secretmanager_v1_CreateBackupRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_secretmanager_v1_CreateBackupRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_secretmanager_v1_UpdateBackupRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_secretmanager_v1_UpdateBackupRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_secretmanager_v1_DeleteBackupRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_secretmanager_v1_DeleteBackupRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_secretmanager_v1_RestoreBackupRequest_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_secretmanager_v1_RestoreBackupRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_secretmanager_v1_OperationMetadata_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_secretmanager_v1_OperationMetadata_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_secretmanager_v1_OperationMetadata_Progress_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_secretmanager_v1_OperationMetadata_Progress_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_secretmanager_v1_Backup_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_secretmanager_v1_Backup_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_secretmanager_v1_Backup_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_secretmanager_v1_Backup_LabelsEntry_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n" + + "6google/cloud/secretmanager/v1/operations_service.proto\022\035google.cloud.secretman" + + "ager.v1\032\034google/api/annotations.proto\032\027g" + + "oogle/api/client.proto\032\037google/api/field" + + "_behavior.proto\032\031google/api/resource.pro" + + "to\032-google/cloud/secretmanager/v1/resour" + + "ces.proto\032#google/longrunning/operations.proto\032\033google/protobuf/empty.proto\032" + + " google/protobuf/field_mask.proto\032\037google/protobuf/timestamp.proto\"\263\001\n" + + "\022ListBackupsRequest\022<\n" + + "\006parent\030\001 \001(" + + "\tB,\342A\001\002\372A%\022#secretmanager.googleapis.com/Backup\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + + "\006filter\030\004 \001(\tB\004\342A\001\001\022\026\n" + + "\010order_by\030\005 \001(\tB\004\342A\001\001\"\201\001\n" + + "\023ListBackupsResponse\0226\n" + + "\007backups\030\001 \003(\0132%.google.cloud.secretmanager.v1.Backup\022\027\n" + + "\017next_page_token\030\002 \001(\t\022\031\n" + + "\013unreachable\030\003 \003(\tB\004\342A\001\006\"N\n" + + "\020GetBackupRequest\022:\n" + + "\004name\030\001 \001(\tB,\342A\001\002\372A%\n" + + "#secretmanager.googleapis.com/Backup\"\251\001\n" + + "\023CreateBackupRequest\022<\n" + + "\006parent\030\001 \001(" + + "\tB,\342A\001\002\372A%\022#secretmanager.googleapis.com/Backup\022\027\n" + + "\tbackup_id\030\002 \001(\tB\004\342A\001\002\022;\n" + + "\006backup\030\003" + + " \001(\0132%.google.cloud.secretmanager.v1.BackupB\004\342A\001\002\"\211\001\n" + + "\023UpdateBackupRequest\0225\n" + + "\013update_mask\030\001" + + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022;\n" + + "\006backup\030\002 " + + "\001(\0132%.google.cloud.secretmanager.v1.BackupB\004\342A\001\002\"e\n" + + "\023DeleteBackupRequest\022:\n" + + "\004name\030\001 \001(\tB,\342A\001\002\372A%\n" + + "#secretmanager.googleapis.com/Backup\022\022\n" + + "\004etag\030\002 \001(\tB\004\342A\001\001\"\212\002\n" + + "\024RestoreBackupRequest\022:\n" + + "\004name\030\001 \001(\tB,\342A\001\002\372A%\n" + + "#secretmanager.googleapis.com/Backup\022O\n" + + "\031destination_secret_parent\030\002 \001(" + + "\tB,\342A\001\002\372A%\022#secretmanager.googleapis.com/Secret\022#\n" + + "\025destination_secret_id\030\003 \001(\tB\004\342A\001\002\022@\n" + + "\014kms_key_name\030\004 \001(\tB*\342A\001\001\372A#\n" + + "!cloudkms.googleapis.com/CryptoKey\"\324\003\n" + + "\021OperationMetadata\0225\n" + + "\013create_time\030\001" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0222\n" + + "\010end_time\030\002" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022\024\n" + + "\006target\030\003 \001(\tB\004\342A\001\003\022\022\n" + + "\004verb\030\004 \001(\tB\004\342A\001\003\022\034\n" + + "\016status_message\030\005 \001(\tB\004\342A\001\003\022$\n" + + "\026requested_cancellation\030\006 \001(\010B\004\342A\001\003\022\031\n" + + "\013api_version\030\007 \001(\tB\004\342A\001\003\022Q\n" + + "\010progress\030\010 \001(\01329.google.cloud." + + "secretmanager.v1.OperationMetadata.ProgressB\004\342A\001\003\032x\n" + + "\010Progress\022!\n" + + "\023total_version_count\030\001 \001(\005B\004\342A\001\003\022%\n" + + "\027completed_version_count\030\002 \001(\005B\004\342A\001\003\022\"\n" + + "\024failed_version_count\030\003 \001(\005B\004\342A\001\003\"\311\005\n" + + "\006Backup\022\022\n" + + "\004name\030\001 \001(\tB\004\342A\001\010\022D\n\r" + + "source_secret\030\002 \001(\tB-\342A\002\002\005\372A%\n" + + "#secretmanager.googleapis.com/Secret\0225\n" + + "\013create_time\030\003" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0225\n" + + "\013update_time\030\004" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022C\n" + + "\031source_secret_create_time\030\005" + + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022\033\n\r" + + "version_count\030\006 \001(\005B\004\342A\001\003\022G\n" + + "\006labels\030\007" + + " \003(\01321.google.cloud.secretmanager.v1.Backup.LabelsEntryB\004\342A\001\001\022@\n" + + "\005state\030\010" + + " \001(\0162+.google.cloud.secretmanager.v1.Backup.StateB\004\342A\001\003\022\022\n" + + "\004etag\030\013 \001(\tB\004\342A\001\001\032-\n" + + "\013LabelsEntry\022\013\n" + + "\003key\030\001 \001(\t\022\r\n" + + "\005value\030\002 \001(\t:\0028\001\"R\n" + + "\005State\022\025\n" + + "\021STATE_UNSPECIFIED\020\000\022\014\n" + + "\010CREATING\020\001\022\n\n" + + "\006ACTIVE\020\002\022\014\n" + + "\010UPDATING\020\003\022\n" + + "\n" + + "\006FAILED\020\004:s\352Ap\n" + + "#secretmanager.googleapis.com/Backup\0228projects/{project}/locatio" + + "ns/{location}/backups/{backup}*\007backups2\006backup2\335\n\n" + + "\027SecretOperationsService\022\262\001\n" + + "\013ListBackups\0221.google.cloud.secretmanager" + + ".v1.ListBackupsRequest\0322.google.cloud.se" + + "cretmanager.v1.ListBackupsResponse\"<\332A\006p" + + "arent\202\323\344\223\002-\022+/v1/{parent=projects/*/locations/*}/backups\022\237\001\n" + + "\tGetBackup\022/.google.cloud.secretmanager.v1.GetBackupRequest\032" + + "%.google.cloud.secretmanager.v1.Backup\":" + + "\332A\004name\202\323\344\223\002-\022+/v1/{name=projects/*/locations/*/backups/*}\022\326\001\n" + + "\014CreateBackup\0222.google.cloud.secretmanager.v1.CreateBackup" + + "Request\032\035.google.longrunning.Operation\"s\312A\033\n" + + "\006Backup\022\021OperationMetadata\332A\027parent," + + "backup,backup_id\202\323\344\223\0025\"+/v1/{parent=projects/*/locations/*}/backups:\006backup\022\330\001\n" + + "\014UpdateBackup\0222.google.cloud.secretmanage" + + "r.v1.UpdateBackupRequest\032\035.google.longrunning.Operation\"u\312A\033\n" + + "\006Backup\022\021OperationM" + + "etadata\332A\022backup,update_mask\202\323\344\223\002<22/v1/" + + "{backup.name=projects/*/locations/*/backups/*}:\006backup\022\312\001\n" + + "\014DeleteBackup\0222.google" + + ".cloud.secretmanager.v1.DeleteBackupRequest\032\035.google.longrunning.Operation\"g\312A*\n" + + "\025google.protobuf.Empty\022\021OperationMetadat" + + "a\332A\004name\202\323\344\223\002-*+/v1/{name=projects/*/locations/*/backups/*}\022\227\002\n\r" + + "RestoreBackup\0223.google.cloud.secretmanager.v1.RestoreBac" + + "kupRequest\032\035.google.longrunning.Operation\"\261\001\312A9\n" + + "$google.cloud.secretmanager.v1.Secret\022\021OperationMetadata\332A4name,destinat" + + "ion_secret_parent,destination_secret_id\202" + + "\323\344\223\0028\"3/v1/{name=projects/*/locations/*/" + + "backups/*}:restore:\001*\032P\312A\034secretmanager." + + "googleapis.com\322A.https://www.googleapis.com/auth/cloud-platformB\352\002\n" + + "!com.google.cloud.secretmanager.v1B\026OperationsService" + + "ProtoP\001ZGcloud.google.com/go/secretmanager/apiv1/secretmanagerpb;secretmanagerpb" + + "\242\002\003GSM\252\002\035Google.Cloud.SecretManager.V1\312\002\035Google\\Cloud\\SecretManager\\V1\352\002" + + " Google::Cloud::SecretManager::V1\352Ax\n" + + "!cloudkms.googleapis.com/CryptoKey\022Sprojects/{proje" + + "ct}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.AnnotationsProto.getDescriptor(), + com.google.api.ClientProto.getDescriptor(), + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.cloud.secretmanager.v1.ResourcesProto.getDescriptor(), + com.google.longrunning.OperationsProto.getDescriptor(), + com.google.protobuf.EmptyProto.getDescriptor(), + com.google.protobuf.FieldMaskProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_secretmanager_v1_ListBackupsRequest_descriptor = + getDescriptor().getMessageType(0); + internal_static_google_cloud_secretmanager_v1_ListBackupsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_secretmanager_v1_ListBackupsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "Filter", "OrderBy", + }); + internal_static_google_cloud_secretmanager_v1_ListBackupsResponse_descriptor = + getDescriptor().getMessageType(1); + internal_static_google_cloud_secretmanager_v1_ListBackupsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_secretmanager_v1_ListBackupsResponse_descriptor, + new java.lang.String[] { + "Backups", "NextPageToken", "Unreachable", + }); + internal_static_google_cloud_secretmanager_v1_GetBackupRequest_descriptor = + getDescriptor().getMessageType(2); + internal_static_google_cloud_secretmanager_v1_GetBackupRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_secretmanager_v1_GetBackupRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_secretmanager_v1_CreateBackupRequest_descriptor = + getDescriptor().getMessageType(3); + internal_static_google_cloud_secretmanager_v1_CreateBackupRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_secretmanager_v1_CreateBackupRequest_descriptor, + new java.lang.String[] { + "Parent", "BackupId", "Backup", + }); + internal_static_google_cloud_secretmanager_v1_UpdateBackupRequest_descriptor = + getDescriptor().getMessageType(4); + internal_static_google_cloud_secretmanager_v1_UpdateBackupRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_secretmanager_v1_UpdateBackupRequest_descriptor, + new java.lang.String[] { + "UpdateMask", "Backup", + }); + internal_static_google_cloud_secretmanager_v1_DeleteBackupRequest_descriptor = + getDescriptor().getMessageType(5); + internal_static_google_cloud_secretmanager_v1_DeleteBackupRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_secretmanager_v1_DeleteBackupRequest_descriptor, + new java.lang.String[] { + "Name", "Etag", + }); + internal_static_google_cloud_secretmanager_v1_RestoreBackupRequest_descriptor = + getDescriptor().getMessageType(6); + internal_static_google_cloud_secretmanager_v1_RestoreBackupRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_secretmanager_v1_RestoreBackupRequest_descriptor, + new java.lang.String[] { + "Name", "DestinationSecretParent", "DestinationSecretId", "KmsKeyName", + }); + internal_static_google_cloud_secretmanager_v1_OperationMetadata_descriptor = + getDescriptor().getMessageType(7); + internal_static_google_cloud_secretmanager_v1_OperationMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_secretmanager_v1_OperationMetadata_descriptor, + new java.lang.String[] { + "CreateTime", + "EndTime", + "Target", + "Verb", + "StatusMessage", + "RequestedCancellation", + "ApiVersion", + "Progress", + }); + internal_static_google_cloud_secretmanager_v1_OperationMetadata_Progress_descriptor = + internal_static_google_cloud_secretmanager_v1_OperationMetadata_descriptor.getNestedType(0); + internal_static_google_cloud_secretmanager_v1_OperationMetadata_Progress_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_secretmanager_v1_OperationMetadata_Progress_descriptor, + new java.lang.String[] { + "TotalVersionCount", "CompletedVersionCount", "FailedVersionCount", + }); + internal_static_google_cloud_secretmanager_v1_Backup_descriptor = + getDescriptor().getMessageType(8); + internal_static_google_cloud_secretmanager_v1_Backup_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_secretmanager_v1_Backup_descriptor, + new java.lang.String[] { + "Name", + "SourceSecret", + "CreateTime", + "UpdateTime", + "SourceSecretCreateTime", + "VersionCount", + "Labels", + "State", + "Etag", + }); + internal_static_google_cloud_secretmanager_v1_Backup_LabelsEntry_descriptor = + internal_static_google_cloud_secretmanager_v1_Backup_descriptor.getNestedType(0); + internal_static_google_cloud_secretmanager_v1_Backup_LabelsEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_secretmanager_v1_Backup_LabelsEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + descriptor.resolveAllFeaturesImmutable(); + com.google.api.AnnotationsProto.getDescriptor(); + com.google.api.ClientProto.getDescriptor(); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.cloud.secretmanager.v1.ResourcesProto.getDescriptor(); + com.google.longrunning.OperationsProto.getDescriptor(); + com.google.protobuf.EmptyProto.getDescriptor(); + com.google.protobuf.FieldMaskProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.ClientProto.defaultHost); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.AnnotationsProto.http); + registry.add(com.google.api.ClientProto.methodSignature); + registry.add(com.google.api.ClientProto.oauthScopes); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceDefinition); + registry.add(com.google.api.ResourceProto.resourceReference); + registry.add(com.google.longrunning.OperationsProto.operationInfo); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ResourcesProto.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ResourcesProto.java index 7cd0123239db..05d237eda2c3 100644 --- a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ResourcesProto.java +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/ResourcesProto.java @@ -139,7 +139,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "google/api/field_behavior.proto\032\031google/" + "api/resource.proto\032*google/iam/v1/resour" + "ce_policy_member.proto\032\036google/protobuf/" - + "duration.proto\032\037google/protobuf/timestamp.proto\032\027google/rpc/status.proto\"\200\014\n" + + "duration.proto\032\037google/protobuf/timestamp.proto\032\027google/rpc/status.proto\"\211\r\n" + "\006Secret\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\003\022F\n" + "\013replication\030\002" @@ -170,7 +170,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013secret_type\030\021" + " \001(\01620.google.cloud.secretmanager.v1.Secret.SecretTypeB\005\342A\002\005\001\022@\n\r" + "policy_member\030\022" - + " \001(\0132#.google.iam.v1.ResourcePolicyMemberB\004\342A\001\003\032-\n" + + " \001(\0132#.google.iam.v1.ResourcePolicyMemberB\004\342A\001\003\022@\n" + + "\005state\030\023 \001(\0162+.goog" + + "le.cloud.secretmanager.v1.Secret.StateB\004\342A\001\003\032-\n" + "\013LabelsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001\0325\n" @@ -181,9 +183,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001\032+\n" + "\tTagsEntry\022\013\n" - + "\003key\030\001 \001(\t\022\r" - + "\n" - + "\005value\030\002 \001(\t:\0028\001\"\215\001\n\n" + + "\003key\030\001 \001(\t\022\r\n" + + "\005value\030\002 \001(\t:\0028\001\"E\n" + + "\005State\022\025\n" + + "\021STATE_UNSPECIFIED\020\000\022\020\n" + + "\014STATE_ACTIVE\020\001\022\023\n" + + "\017STATE_RESTORING\020\002\"\215\001\n\n" + "SecretType\022\033\n" + "\027SECRET_TYPE_UNSPECIFIED\020\000\022\034\n" + "\030CLOUD_SQL_DB_CREDENTIALS\020\001\022\016\n\n" @@ -191,9 +196,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013CERTIFICATE\020\003\022\030\n" + "\024OTHER_DB_CREDENTIALS\020\004\022\t\n" + "\005OTHER\0202:\231\001\352A\225\001\n" - + "#secretmanager.googleapis.com/Secret\022#projects/{project}/secrets/{secre" - + "t}\0228projects/{project}/locations/{location}/secrets/{secret}*\007secrets2\006secretB\014\n" - + "\n" + + "#secretmanager.googleapis.com/Secret\022#projects/{projec" + + "t}/secrets/{secret}\0228projects/{project}/" + + "locations/{location}/secrets/{secret}*\007secrets2\006secretB\014\n\n" + "expiration\"\312\006\n\r" + "SecretVersion\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\003\0225\n" @@ -201,59 +206,58 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\0226\n" + "\014destroy_time\030\003" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022G\n" - + "\005state\030\004" - + " \001(\01622.google.cloud.secretmanager.v1.SecretVersion.StateB\004\342A\001\003\022L\n" - + "\022replication_status\030\005" - + " \001(\01320.google.cloud.secretmanager.v1.ReplicationStatus\022\022\n" + + "\005state\030\004 \001(\01622.googl" + + "e.cloud.secretmanager.v1.SecretVersion.StateB\004\342A\001\003\022L\n" + + "\022replication_status\030\005 \001(\01320" + + ".google.cloud.secretmanager.v1.ReplicationStatus\022\022\n" + "\004etag\030\006 \001(\tB\004\342A\001\003\022/\n" + "!client_specified_payload_checksum\030\007 \001(\010B\004\342A\001\003\022@\n" + "\026scheduled_destroy_time\030\010" + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\003\022i\n" - + "\033customer_managed_encryption\030\t " - + "\001(\0132>.google.cloud.secretmanager.v1.CustomerManagedEncryptionStatusB\004\342A\001\003\"H\n" + + "\033customer_managed_encryption\030\t \001(\0132>.google.cloud.secr" + + "etmanager.v1.CustomerManagedEncryptionStatusB\004\342A\001\003\"H\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\013\n" + "\007ENABLED\020\001\022\014\n" + "\010DISABLED\020\002\022\r\n" + "\tDESTROYED\020\003:\342\001\352A\336\001\n" - + "*secretmanager.googleapis.com/SecretVersion\022=" - + "projects/{project}/secrets/{secret}/versions/{secret_version}\022Rprojects/{project" - + "}/locations/{location}/secrets/{secret}/" - + "versions/{secret_version}*\016secretVersions2\r" + + "*secretmanager.googleapis.com/SecretVersion\022=projects/{project}/secr" + + "ets/{secret}/versions/{secret_version}\022Rprojects/{project}/locations/{location}/" + + "secrets/{secret}/versions/{secret_version}*\016secretVersions2\r" + "secretVersion\"\224\004\n" + "\013Replication\022I\n" - + "\tautomatic\030\001" - + " \001(\01324.google.cloud.secretmanager.v1.Replication.AutomaticH\000\022N\n" - + "\014user_managed\030\002" - + " \001(\01326.google.cloud.secretmanager.v1.Replication.UserManagedH\000\032p\n" + + "\tautomatic\030\001 \001(\01324.google.cl" + + "oud.secretmanager.v1.Replication.AutomaticH\000\022N\n" + + "\014user_managed\030\002 \001(\01326.google.clou" + + "d.secretmanager.v1.Replication.UserManagedH\000\032p\n" + "\tAutomatic\022c\n" - + "\033customer_managed_encryption\030\001 \001(\01328." - + "google.cloud.secretmanager.v1.CustomerManagedEncryptionB\004\342A\001\001\032\350\001\n" + + "\033customer_managed_encryption\030\001 \001(\01328.google.cloud.secretmana" + + "ger.v1.CustomerManagedEncryptionB\004\342A\001\001\032\350\001\n" + "\013UserManaged\022V\n" - + "\010replicas\030\001 \003(\0132>.google.cloud.secretman" - + "ager.v1.Replication.UserManaged.ReplicaB\004\342A\001\002\032\200\001\n" + + "\010replicas\030\001 \003(\0132>.googl" + + "e.cloud.secretmanager.v1.Replication.UserManaged.ReplicaB\004\342A\001\002\032\200\001\n" + "\007Replica\022\020\n" + "\010location\030\001 \001(\t\022c\n" - + "\033customer_managed_encryption\030\002 \001(\01328.googl" - + "e.cloud.secretmanager.v1.CustomerManagedEncryptionB\004\342A\001\001B\r\n" + + "\033customer_managed_encryption\030\002" + + " \001(\01328.google.cloud.secretmanager.v1.CustomerManagedEncryptionB\004\342A\001\001B\r\n" + "\013replication\"7\n" + "\031CustomerManagedEncryption\022\032\n" + "\014kms_key_name\030\001 \001(\tB\004\342A\001\002\"\357\004\n" + "\021ReplicationStatus\022U\n" - + "\tautomatic\030\001" - + " \001(\0132@.google.cloud.secretmanager.v1.ReplicationStatus.AutomaticStatusH\000\022Z\n" - + "\014user_managed\030\002 \001(\0132B.google.cloud.secre" - + "tmanager.v1.ReplicationStatus.UserManagedStatusH\000\032|\n" + + "\tautomatic\030\001 \001(\0132@.google.clou" + + "d.secretmanager.v1.ReplicationStatus.AutomaticStatusH\000\022Z\n" + + "\014user_managed\030\002 \001(\0132B.g" + + "oogle.cloud.secretmanager.v1.ReplicationStatus.UserManagedStatusH\000\032|\n" + "\017AutomaticStatus\022i\n" - + "\033customer_managed_encryption\030\001 \001(\0132>.google.cloud" - + ".secretmanager.v1.CustomerManagedEncryptionStatusB\004\342A\001\003\032\222\002\n" + + "\033customer_managed_encryption\030\001 \001" + + "(\0132>.google.cloud.secretmanager.v1.CustomerManagedEncryptionStatusB\004\342A\001\003\032\222\002\n" + "\021UserManagedStatus\022h\n" - + "\010replicas\030\001 \003(\0132P.google.cloud.secretman" - + "ager.v1.ReplicationStatus.UserManagedStatus.ReplicaStatusB\004\342A\001\003\032\222\001\n\r" + + "\010replicas\030\001 \003(\0132P.google.cloud.secretmanager.v1.ReplicationStat" + + "us.UserManagedStatus.ReplicaStatusB\004\342A\001\003\032\222\001\n\r" + "ReplicaStatus\022\026\n" + "\010location\030\001 \001(\tB\004\342A\001\003\022i\n" - + "\033customer_managed_encryption\030\002 \001(\0132>.google.cloud.se" - + "cretmanager.v1.CustomerManagedEncryptionStatusB\004\342A\001\003B\024\n" + + "\033customer_managed_encryption\030\002 \001(\0132" + + ">.google.cloud.secretmanager.v1.CustomerManagedEncryptionStatusB\004\342A\001\003B\024\n" + "\022replication_status\"E\n" + "\037CustomerManagedEncryptionStatus\022\"\n" + "\024kms_key_version_name\030\001 \001(\tB\004\342A\001\002\"`\n" @@ -265,11 +269,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\0132\032.google.protobuf.TimestampB\004\342A\001\001\0228\n" + "\017rotation_period\030\002" + " \001(\0132\031.google.protobuf.DurationB\004\342A\001\004\022d\n" - + "\027managed_rotation_status\030\003 \001(\0132=.google.cloud.secretmanager.v" - + "1.Rotation.ManagedRotationStatusB\004\342A\001\003\032\324\001\n" + + "\027managed_rotation_status\030\003 \001(\0132=.google.clou" + + "d.secretmanager.v1.Rotation.ManagedRotationStatusB\004\342A\001\003\032\324\001\n" + "\025ManagedRotationStatus\022X\n" - + "\005state\030\001 \001(\0162" - + "C.google.cloud.secretmanager.v1.Rotation.ManagedRotationStatus.StateB\004\342A\001\003\022\'\n" + + "\005state\030\001 \001(\0162C.google.cloud.secretma" + + "nager.v1.Rotation.ManagedRotationStatus.StateB\004\342A\001\003\022\'\n" + "\005error\030\002 \001(\0132\022.google.rpc.StatusB\004\342A\001\003\"8\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\n\n" @@ -283,10 +287,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013instance_id\030\001 \001(\tB\004\342A\001\002\022\026\n" + "\010username\030\002 \001(\tB\004\342A\001\002\022\026\n" + "\010password\030\003 \001(\tB\004\342A\001\001B\347\001\n" - + "!com.google.cloud.secretmanager.v1B\016ResourcesProtoP\001ZGcloud.google.com/go/se" - + "cretmanager/apiv1/secretmanagerpb;secret" - + "managerpb\242\002\003GSM\252\002\035Google.Cloud.SecretMan" - + "ager.V1\312\002\035Google\\Cloud\\SecretManager\\V1\352\002" + + "!com.google.cloud.secretmanager.v1B\016ResourcesProtoP\001ZGcloud" + + ".google.com/go/secretmanager/apiv1/secre" + + "tmanagerpb;secretmanagerpb\242\002\003GSM\252\002\035Googl" + + "e.Cloud.SecretManager.V1\312\002\035Google\\Cloud\\SecretManager\\V1\352\002" + " Google::Cloud::SecretManager::V1b\006proto3" }; descriptor = @@ -322,6 +326,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Tags", "SecretType", "PolicyMember", + "State", "Expiration", }); internal_static_google_cloud_secretmanager_v1_Secret_LabelsEntry_descriptor = diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/RestoreBackupRequest.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/RestoreBackupRequest.java new file mode 100644 index 000000000000..9772df24d113 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/RestoreBackupRequest.java @@ -0,0 +1,1299 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +/** + * + * + *
    + * Request message for
    + * [SecretOperationsService.RestoreBackup][google.cloud.secretmanager.v1.SecretOperationsService.RestoreBackup].
    + * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.RestoreBackupRequest} + */ +@com.google.protobuf.Generated +public final class RestoreBackupRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.secretmanager.v1.RestoreBackupRequest) + RestoreBackupRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "RestoreBackupRequest"); + } + + // Use RestoreBackupRequest.newBuilder() to construct. + private RestoreBackupRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private RestoreBackupRequest() { + name_ = ""; + destinationSecretParent_ = ""; + destinationSecretId_ = ""; + kmsKeyName_ = ""; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_RestoreBackupRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_RestoreBackupRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.RestoreBackupRequest.class, + com.google.cloud.secretmanager.v1.RestoreBackupRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] to restore from. Format:
    +   * `projects/{project}/locations/{location}/backups/{backup}`
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] to restore from. Format:
    +   * `projects/{project}/locations/{location}/backups/{backup}`
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESTINATION_SECRET_PARENT_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object destinationSecretParent_ = ""; + + /** + * + * + *
    +   * Required. Parent of the new [Secret][google.cloud.secretmanager.v1.Secret]
    +   * to be created from this backup. Formats:
    +   * - `projects/{project}/locations/{location}` (for regional secrets)
    +   * - `projects/{project}` (for global secrets)
    +   * 
    + * + * + * string destination_secret_parent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The destinationSecretParent. + */ + @java.lang.Override + public java.lang.String getDestinationSecretParent() { + java.lang.Object ref = destinationSecretParent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationSecretParent_ = s; + return s; + } + } + + /** + * + * + *
    +   * Required. Parent of the new [Secret][google.cloud.secretmanager.v1.Secret]
    +   * to be created from this backup. Formats:
    +   * - `projects/{project}/locations/{location}` (for regional secrets)
    +   * - `projects/{project}` (for global secrets)
    +   * 
    + * + * + * string destination_secret_parent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for destinationSecretParent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDestinationSecretParentBytes() { + java.lang.Object ref = destinationSecretParent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationSecretParent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESTINATION_SECRET_ID_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object destinationSecretId_ = ""; + + /** + * + * + *
    +   * Required. ID of the new [Secret][google.cloud.secretmanager.v1.Secret] to
    +   * be created from this backup. This must be unique within the project.
    +   *
    +   * A secret ID is a string with a maximum length of 255 characters and can
    +   * contain uppercase and lowercase letters, numerals, and the hyphen (`-`)
    +   * and underscore (`_`) characters.
    +   * 
    + * + * string destination_secret_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The destinationSecretId. + */ + @java.lang.Override + public java.lang.String getDestinationSecretId() { + java.lang.Object ref = destinationSecretId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationSecretId_ = s; + return s; + } + } + + /** + * + * + *
    +   * Required. ID of the new [Secret][google.cloud.secretmanager.v1.Secret] to
    +   * be created from this backup. This must be unique within the project.
    +   *
    +   * A secret ID is a string with a maximum length of 255 characters and can
    +   * contain uppercase and lowercase letters, numerals, and the hyphen (`-`)
    +   * and underscore (`_`) characters.
    +   * 
    + * + * string destination_secret_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for destinationSecretId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDestinationSecretIdBytes() { + java.lang.Object ref = destinationSecretId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationSecretId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int KMS_KEY_NAME_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private volatile java.lang.Object kmsKeyName_ = ""; + + /** + * + * + *
    +   * Optional. The resource name of the Cloud KMS CryptoKey to be used to
    +   * encrypt the [Secret][google.cloud.secretmanager.v1.Secret].
    +   * Format:
    +   * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`
    +   * 
    + * + * + * string kms_key_name = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The kmsKeyName. + */ + @java.lang.Override + public java.lang.String getKmsKeyName() { + java.lang.Object ref = kmsKeyName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + kmsKeyName_ = s; + return s; + } + } + + /** + * + * + *
    +   * Optional. The resource name of the Cloud KMS CryptoKey to be used to
    +   * encrypt the [Secret][google.cloud.secretmanager.v1.Secret].
    +   * Format:
    +   * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`
    +   * 
    + * + * + * string kms_key_name = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for kmsKeyName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getKmsKeyNameBytes() { + java.lang.Object ref = kmsKeyName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + kmsKeyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(destinationSecretParent_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 2, destinationSecretParent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(destinationSecretId_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 3, destinationSecretId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(kmsKeyName_)) { + com.google.protobuf.GeneratedMessage.writeString(output, 4, kmsKeyName_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(destinationSecretParent_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(2, destinationSecretParent_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(destinationSecretId_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(3, destinationSecretId_); + } + if (!com.google.protobuf.GeneratedMessage.isStringEmpty(kmsKeyName_)) { + size += com.google.protobuf.GeneratedMessage.computeStringSize(4, kmsKeyName_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.secretmanager.v1.RestoreBackupRequest)) { + return super.equals(obj); + } + com.google.cloud.secretmanager.v1.RestoreBackupRequest other = + (com.google.cloud.secretmanager.v1.RestoreBackupRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getDestinationSecretParent().equals(other.getDestinationSecretParent())) return false; + if (!getDestinationSecretId().equals(other.getDestinationSecretId())) return false; + if (!getKmsKeyName().equals(other.getKmsKeyName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DESTINATION_SECRET_PARENT_FIELD_NUMBER; + hash = (53 * hash) + getDestinationSecretParent().hashCode(); + hash = (37 * hash) + DESTINATION_SECRET_ID_FIELD_NUMBER; + hash = (53 * hash) + getDestinationSecretId().hashCode(); + hash = (37 * hash) + KMS_KEY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getKmsKeyName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.secretmanager.v1.RestoreBackupRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * Request message for
    +   * [SecretOperationsService.RestoreBackup][google.cloud.secretmanager.v1.SecretOperationsService.RestoreBackup].
    +   * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.RestoreBackupRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.secretmanager.v1.RestoreBackupRequest) + com.google.cloud.secretmanager.v1.RestoreBackupRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_RestoreBackupRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_RestoreBackupRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.RestoreBackupRequest.class, + com.google.cloud.secretmanager.v1.RestoreBackupRequest.Builder.class); + } + + // Construct using com.google.cloud.secretmanager.v1.RestoreBackupRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + destinationSecretParent_ = ""; + destinationSecretId_ = ""; + kmsKeyName_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_RestoreBackupRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.RestoreBackupRequest getDefaultInstanceForType() { + return com.google.cloud.secretmanager.v1.RestoreBackupRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.RestoreBackupRequest build() { + com.google.cloud.secretmanager.v1.RestoreBackupRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.RestoreBackupRequest buildPartial() { + com.google.cloud.secretmanager.v1.RestoreBackupRequest result = + new com.google.cloud.secretmanager.v1.RestoreBackupRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.secretmanager.v1.RestoreBackupRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.destinationSecretParent_ = destinationSecretParent_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.destinationSecretId_ = destinationSecretId_; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.kmsKeyName_ = kmsKeyName_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.secretmanager.v1.RestoreBackupRequest) { + return mergeFrom((com.google.cloud.secretmanager.v1.RestoreBackupRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.secretmanager.v1.RestoreBackupRequest other) { + if (other == com.google.cloud.secretmanager.v1.RestoreBackupRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getDestinationSecretParent().isEmpty()) { + destinationSecretParent_ = other.destinationSecretParent_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getDestinationSecretId().isEmpty()) { + destinationSecretId_ = other.destinationSecretId_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (!other.getKmsKeyName().isEmpty()) { + kmsKeyName_ = other.kmsKeyName_; + bitField0_ |= 0x00000008; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + destinationSecretParent_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + destinationSecretId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + kmsKeyName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] to restore from. Format:
    +     * `projects/{project}/locations/{location}/backups/{backup}`
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] to restore from. Format:
    +     * `projects/{project}/locations/{location}/backups/{backup}`
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] to restore from. Format:
    +     * `projects/{project}/locations/{location}/backups/{backup}`
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] to restore from. Format:
    +     * `projects/{project}/locations/{location}/backups/{backup}`
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The resource name of the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] to restore from. Format:
    +     * `projects/{project}/locations/{location}/backups/{backup}`
    +     * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object destinationSecretParent_ = ""; + + /** + * + * + *
    +     * Required. Parent of the new [Secret][google.cloud.secretmanager.v1.Secret]
    +     * to be created from this backup. Formats:
    +     * - `projects/{project}/locations/{location}` (for regional secrets)
    +     * - `projects/{project}` (for global secrets)
    +     * 
    + * + * + * string destination_secret_parent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The destinationSecretParent. + */ + public java.lang.String getDestinationSecretParent() { + java.lang.Object ref = destinationSecretParent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationSecretParent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Required. Parent of the new [Secret][google.cloud.secretmanager.v1.Secret]
    +     * to be created from this backup. Formats:
    +     * - `projects/{project}/locations/{location}` (for regional secrets)
    +     * - `projects/{project}` (for global secrets)
    +     * 
    + * + * + * string destination_secret_parent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for destinationSecretParent. + */ + public com.google.protobuf.ByteString getDestinationSecretParentBytes() { + java.lang.Object ref = destinationSecretParent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationSecretParent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Required. Parent of the new [Secret][google.cloud.secretmanager.v1.Secret]
    +     * to be created from this backup. Formats:
    +     * - `projects/{project}/locations/{location}` (for regional secrets)
    +     * - `projects/{project}` (for global secrets)
    +     * 
    + * + * + * string destination_secret_parent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The destinationSecretParent to set. + * @return This builder for chaining. + */ + public Builder setDestinationSecretParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + destinationSecretParent_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. Parent of the new [Secret][google.cloud.secretmanager.v1.Secret]
    +     * to be created from this backup. Formats:
    +     * - `projects/{project}/locations/{location}` (for regional secrets)
    +     * - `projects/{project}` (for global secrets)
    +     * 
    + * + * + * string destination_secret_parent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearDestinationSecretParent() { + destinationSecretParent_ = getDefaultInstance().getDestinationSecretParent(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. Parent of the new [Secret][google.cloud.secretmanager.v1.Secret]
    +     * to be created from this backup. Formats:
    +     * - `projects/{project}/locations/{location}` (for regional secrets)
    +     * - `projects/{project}` (for global secrets)
    +     * 
    + * + * + * string destination_secret_parent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for destinationSecretParent to set. + * @return This builder for chaining. + */ + public Builder setDestinationSecretParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + destinationSecretParent_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object destinationSecretId_ = ""; + + /** + * + * + *
    +     * Required. ID of the new [Secret][google.cloud.secretmanager.v1.Secret] to
    +     * be created from this backup. This must be unique within the project.
    +     *
    +     * A secret ID is a string with a maximum length of 255 characters and can
    +     * contain uppercase and lowercase letters, numerals, and the hyphen (`-`)
    +     * and underscore (`_`) characters.
    +     * 
    + * + * string destination_secret_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The destinationSecretId. + */ + public java.lang.String getDestinationSecretId() { + java.lang.Object ref = destinationSecretId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationSecretId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Required. ID of the new [Secret][google.cloud.secretmanager.v1.Secret] to
    +     * be created from this backup. This must be unique within the project.
    +     *
    +     * A secret ID is a string with a maximum length of 255 characters and can
    +     * contain uppercase and lowercase letters, numerals, and the hyphen (`-`)
    +     * and underscore (`_`) characters.
    +     * 
    + * + * string destination_secret_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for destinationSecretId. + */ + public com.google.protobuf.ByteString getDestinationSecretIdBytes() { + java.lang.Object ref = destinationSecretId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationSecretId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Required. ID of the new [Secret][google.cloud.secretmanager.v1.Secret] to
    +     * be created from this backup. This must be unique within the project.
    +     *
    +     * A secret ID is a string with a maximum length of 255 characters and can
    +     * contain uppercase and lowercase letters, numerals, and the hyphen (`-`)
    +     * and underscore (`_`) characters.
    +     * 
    + * + * string destination_secret_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The destinationSecretId to set. + * @return This builder for chaining. + */ + public Builder setDestinationSecretId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + destinationSecretId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. ID of the new [Secret][google.cloud.secretmanager.v1.Secret] to
    +     * be created from this backup. This must be unique within the project.
    +     *
    +     * A secret ID is a string with a maximum length of 255 characters and can
    +     * contain uppercase and lowercase letters, numerals, and the hyphen (`-`)
    +     * and underscore (`_`) characters.
    +     * 
    + * + * string destination_secret_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDestinationSecretId() { + destinationSecretId_ = getDefaultInstance().getDestinationSecretId(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. ID of the new [Secret][google.cloud.secretmanager.v1.Secret] to
    +     * be created from this backup. This must be unique within the project.
    +     *
    +     * A secret ID is a string with a maximum length of 255 characters and can
    +     * contain uppercase and lowercase letters, numerals, and the hyphen (`-`)
    +     * and underscore (`_`) characters.
    +     * 
    + * + * string destination_secret_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for destinationSecretId to set. + * @return This builder for chaining. + */ + public Builder setDestinationSecretIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + destinationSecretId_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private java.lang.Object kmsKeyName_ = ""; + + /** + * + * + *
    +     * Optional. The resource name of the Cloud KMS CryptoKey to be used to
    +     * encrypt the [Secret][google.cloud.secretmanager.v1.Secret].
    +     * Format:
    +     * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`
    +     * 
    + * + * + * string kms_key_name = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The kmsKeyName. + */ + public java.lang.String getKmsKeyName() { + java.lang.Object ref = kmsKeyName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + kmsKeyName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
    +     * Optional. The resource name of the Cloud KMS CryptoKey to be used to
    +     * encrypt the [Secret][google.cloud.secretmanager.v1.Secret].
    +     * Format:
    +     * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`
    +     * 
    + * + * + * string kms_key_name = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for kmsKeyName. + */ + public com.google.protobuf.ByteString getKmsKeyNameBytes() { + java.lang.Object ref = kmsKeyName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + kmsKeyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
    +     * Optional. The resource name of the Cloud KMS CryptoKey to be used to
    +     * encrypt the [Secret][google.cloud.secretmanager.v1.Secret].
    +     * Format:
    +     * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`
    +     * 
    + * + * + * string kms_key_name = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The kmsKeyName to set. + * @return This builder for chaining. + */ + public Builder setKmsKeyName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + kmsKeyName_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. The resource name of the Cloud KMS CryptoKey to be used to
    +     * encrypt the [Secret][google.cloud.secretmanager.v1.Secret].
    +     * Format:
    +     * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`
    +     * 
    + * + * + * string kms_key_name = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearKmsKeyName() { + kmsKeyName_ = getDefaultInstance().getKmsKeyName(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. The resource name of the Cloud KMS CryptoKey to be used to
    +     * encrypt the [Secret][google.cloud.secretmanager.v1.Secret].
    +     * Format:
    +     * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`
    +     * 
    + * + * + * string kms_key_name = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for kmsKeyName to set. + * @return This builder for chaining. + */ + public Builder setKmsKeyNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + kmsKeyName_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.secretmanager.v1.RestoreBackupRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.secretmanager.v1.RestoreBackupRequest) + private static final com.google.cloud.secretmanager.v1.RestoreBackupRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.secretmanager.v1.RestoreBackupRequest(); + } + + public static com.google.cloud.secretmanager.v1.RestoreBackupRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RestoreBackupRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.RestoreBackupRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/RestoreBackupRequestOrBuilder.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/RestoreBackupRequestOrBuilder.java new file mode 100644 index 000000000000..fbebf2ceaf80 --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/RestoreBackupRequestOrBuilder.java @@ -0,0 +1,170 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +@com.google.protobuf.Generated +public interface RestoreBackupRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.secretmanager.v1.RestoreBackupRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] to restore from. Format:
    +   * `projects/{project}/locations/{location}/backups/{backup}`
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
    +   * Required. The resource name of the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] to restore from. Format:
    +   * `projects/{project}/locations/{location}/backups/{backup}`
    +   * 
    + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
    +   * Required. Parent of the new [Secret][google.cloud.secretmanager.v1.Secret]
    +   * to be created from this backup. Formats:
    +   * - `projects/{project}/locations/{location}` (for regional secrets)
    +   * - `projects/{project}` (for global secrets)
    +   * 
    + * + * + * string destination_secret_parent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The destinationSecretParent. + */ + java.lang.String getDestinationSecretParent(); + + /** + * + * + *
    +   * Required. Parent of the new [Secret][google.cloud.secretmanager.v1.Secret]
    +   * to be created from this backup. Formats:
    +   * - `projects/{project}/locations/{location}` (for regional secrets)
    +   * - `projects/{project}` (for global secrets)
    +   * 
    + * + * + * string destination_secret_parent = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for destinationSecretParent. + */ + com.google.protobuf.ByteString getDestinationSecretParentBytes(); + + /** + * + * + *
    +   * Required. ID of the new [Secret][google.cloud.secretmanager.v1.Secret] to
    +   * be created from this backup. This must be unique within the project.
    +   *
    +   * A secret ID is a string with a maximum length of 255 characters and can
    +   * contain uppercase and lowercase letters, numerals, and the hyphen (`-`)
    +   * and underscore (`_`) characters.
    +   * 
    + * + * string destination_secret_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The destinationSecretId. + */ + java.lang.String getDestinationSecretId(); + + /** + * + * + *
    +   * Required. ID of the new [Secret][google.cloud.secretmanager.v1.Secret] to
    +   * be created from this backup. This must be unique within the project.
    +   *
    +   * A secret ID is a string with a maximum length of 255 characters and can
    +   * contain uppercase and lowercase letters, numerals, and the hyphen (`-`)
    +   * and underscore (`_`) characters.
    +   * 
    + * + * string destination_secret_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for destinationSecretId. + */ + com.google.protobuf.ByteString getDestinationSecretIdBytes(); + + /** + * + * + *
    +   * Optional. The resource name of the Cloud KMS CryptoKey to be used to
    +   * encrypt the [Secret][google.cloud.secretmanager.v1.Secret].
    +   * Format:
    +   * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`
    +   * 
    + * + * + * string kms_key_name = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The kmsKeyName. + */ + java.lang.String getKmsKeyName(); + + /** + * + * + *
    +   * Optional. The resource name of the Cloud KMS CryptoKey to be used to
    +   * encrypt the [Secret][google.cloud.secretmanager.v1.Secret].
    +   * Format:
    +   * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`
    +   * 
    + * + * + * string kms_key_name = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for kmsKeyName. + */ + com.google.protobuf.ByteString getKmsKeyNameBytes(); +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/Secret.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/Secret.java index 79967cb3051f..5deb06c8f3c7 100644 --- a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/Secret.java +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/Secret.java @@ -61,6 +61,7 @@ private Secret() { topics_ = java.util.Collections.emptyList(); etag_ = ""; secretType_ = 0; + state_ = 0; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { @@ -96,6 +97,177 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldRefl com.google.cloud.secretmanager.v1.Secret.Builder.class); } + /** + * + * + *
    +   * Represents the current state of the Secret.
    +   * 
    + * + * Protobuf enum {@code google.cloud.secretmanager.v1.Secret.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
    +     * Not specified.
    +     * 
    + * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
    +     * Secret is in active state, usage is allowed.
    +     * 
    + * + * STATE_ACTIVE = 1; + */ + STATE_ACTIVE(1), + /** + * + * + *
    +     * Secret is being restored from a backup. Operations on the secret and its
    +     * versions are restricted.
    +     * 
    + * + * STATE_RESTORING = 2; + */ + STATE_RESTORING(2), + UNRECOGNIZED(-1), + ; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "State"); + } + + /** + * + * + *
    +     * Not specified.
    +     * 
    + * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
    +     * Secret is in active state, usage is allowed.
    +     * 
    + * + * STATE_ACTIVE = 1; + */ + public static final int STATE_ACTIVE_VALUE = 1; + + /** + * + * + *
    +     * Secret is being restored from a backup. Operations on the secret and its
    +     * versions are restricted.
    +     * 
    + * + * STATE_RESTORING = 2; + */ + public static final int STATE_RESTORING_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return STATE_ACTIVE; + case 2: + return STATE_RESTORING; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public State findValueByNumber(int number) { + return State.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.Secret.getDescriptor().getEnumTypes().get(0); + } + + private static final State[] VALUES = values(); + + public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private State(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.secretmanager.v1.Secret.State) + } + /** * * @@ -316,7 +488,7 @@ public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType } public static com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.secretmanager.v1.Secret.getDescriptor().getEnumTypes().get(0); + return com.google.cloud.secretmanager.v1.Secret.getDescriptor().getEnumTypes().get(1); } private static final SecretType[] VALUES = values(); @@ -1771,6 +1943,47 @@ public com.google.iam.v1.ResourcePolicyMemberOrBuilder getPolicyMemberOrBuilder( : policyMember_; } + public static final int STATE_FIELD_NUMBER = 19; + private int state_ = 0; + + /** + * + * + *
    +   * Output only. The current state of the Secret.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Secret.State state = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
    +   * Output only. The current state of the Secret.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Secret.State state = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.Secret.State getState() { + com.google.cloud.secretmanager.v1.Secret.State result = + com.google.cloud.secretmanager.v1.Secret.State.forNumber(state_); + return result == null ? com.google.cloud.secretmanager.v1.Secret.State.UNRECOGNIZED : result; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -1831,6 +2044,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000020) != 0)) { output.writeMessage(18, getPolicyMember()); } + if (state_ != com.google.cloud.secretmanager.v1.Secret.State.STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(19, state_); + } getUnknownFields().writeTo(output); } @@ -1924,6 +2140,9 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000020) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(18, getPolicyMember()); } + if (state_ != com.google.cloud.secretmanager.v1.Secret.State.STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(19, state_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1972,6 +2191,7 @@ public boolean equals(final java.lang.Object obj) { if (hasPolicyMember()) { if (!getPolicyMember().equals(other.getPolicyMember())) return false; } + if (state_ != other.state_) return false; if (!getExpirationCase().equals(other.getExpirationCase())) return false; switch (expirationCase_) { case 6: @@ -2044,6 +2264,8 @@ public int hashCode() { hash = (37 * hash) + POLICY_MEMBER_FIELD_NUMBER; hash = (53 * hash) + getPolicyMember().hashCode(); } + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; switch (expirationCase_) { case 6: hash = (37 * hash) + EXPIRE_TIME_FIELD_NUMBER; @@ -2300,6 +2522,7 @@ public Builder clear() { policyMemberBuilder_.dispose(); policyMemberBuilder_ = null; } + state_ = 0; expirationCase_ = 0; expiration_ = null; return this; @@ -2410,6 +2633,9 @@ private void buildPartial0(com.google.cloud.secretmanager.v1.Secret result) { policyMemberBuilder_ == null ? policyMember_ : policyMemberBuilder_.build(); to_bitField0_ |= 0x00000020; } + if (((from_bitField0_ & 0x00010000) != 0)) { + result.state_ = state_; + } result.bitField0_ |= to_bitField0_; } @@ -2502,6 +2728,9 @@ public Builder mergeFrom(com.google.cloud.secretmanager.v1.Secret other) { if (other.hasPolicyMember()) { mergePolicyMember(other.getPolicyMember()); } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } switch (other.getExpirationCase()) { case EXPIRE_TIME: { @@ -2676,6 +2905,12 @@ public Builder mergeFrom( bitField0_ |= 0x00008000; break; } // case 146 + case 152: + { + state_ = input.readEnum(); + bitField0_ |= 0x00010000; + break; + } // case 152 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -6411,6 +6646,111 @@ public com.google.iam.v1.ResourcePolicyMemberOrBuilder getPolicyMemberOrBuilder( return policyMemberBuilder_; } + private int state_ = 0; + + /** + * + * + *
    +     * Output only. The current state of the Secret.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Secret.State state = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + + /** + * + * + *
    +     * Output only. The current state of the Secret.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Secret.State state = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + state_ = value; + bitField0_ |= 0x00010000; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The current state of the Secret.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Secret.State state = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.Secret.State getState() { + com.google.cloud.secretmanager.v1.Secret.State result = + com.google.cloud.secretmanager.v1.Secret.State.forNumber(state_); + return result == null ? com.google.cloud.secretmanager.v1.Secret.State.UNRECOGNIZED : result; + } + + /** + * + * + *
    +     * Output only. The current state of the Secret.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Secret.State state = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.secretmanager.v1.Secret.State value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00010000; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
    +     * Output only. The current state of the Secret.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Secret.State state = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00010000); + state_ = 0; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.secretmanager.v1.Secret) } diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/SecretOrBuilder.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/SecretOrBuilder.java index 65ab6535dcd7..a88d8b1e820e 100644 --- a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/SecretOrBuilder.java +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/SecretOrBuilder.java @@ -1054,5 +1054,35 @@ java.lang.String getTagsOrDefault( */ com.google.iam.v1.ResourcePolicyMemberOrBuilder getPolicyMemberOrBuilder(); + /** + * + * + *
    +   * Output only. The current state of the Secret.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Secret.State state = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
    +   * Output only. The current state of the Secret.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Secret.State state = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.secretmanager.v1.Secret.State getState(); + com.google.cloud.secretmanager.v1.Secret.ExpirationCase getExpirationCase(); } diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/UpdateBackupRequest.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/UpdateBackupRequest.java new file mode 100644 index 000000000000..db37e27f932c --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/UpdateBackupRequest.java @@ -0,0 +1,1085 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +/** + * + * + *
    + * Request message for
    + * [SecretOperationsService.UpdateBackup][google.cloud.secretmanager.v1.SecretOperationsService.UpdateBackup].
    + * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.UpdateBackupRequest} + */ +@com.google.protobuf.Generated +public final class UpdateBackupRequest extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.secretmanager.v1.UpdateBackupRequest) + UpdateBackupRequestOrBuilder { + private static final long serialVersionUID = 0L; + + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "UpdateBackupRequest"); + } + + // Use UpdateBackupRequest.newBuilder() to construct. + private UpdateBackupRequest(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } + + private UpdateBackupRequest() {} + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_UpdateBackupRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_UpdateBackupRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.UpdateBackupRequest.class, + com.google.cloud.secretmanager.v1.UpdateBackupRequest.Builder.class); + } + + private int bitField0_; + public static final int UPDATE_MASK_FIELD_NUMBER = 1; + private com.google.protobuf.FieldMask updateMask_; + + /** + * + * + *
    +   * Optional. Field mask is used to specify the fields to be overwritten in the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +   * The fields specified in the `update_mask` are relative to the resource, not
    +   * the full request. A field will be overwritten if it is in the mask. If the
    +   * user does not provide a mask then all fields present in the request will be
    +   * overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +   * Optional. Field mask is used to specify the fields to be overwritten in the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +   * The fields specified in the `update_mask` are relative to the resource, not
    +   * the full request. A field will be overwritten if it is in the mask. If the
    +   * user does not provide a mask then all fields present in the request will be
    +   * overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + /** + * + * + *
    +   * Optional. Field mask is used to specify the fields to be overwritten in the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +   * The fields specified in the `update_mask` are relative to the resource, not
    +   * the full request. A field will be overwritten if it is in the mask. If the
    +   * user does not provide a mask then all fields present in the request will be
    +   * overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + + public static final int BACKUP_FIELD_NUMBER = 2; + private com.google.cloud.secretmanager.v1.Backup backup_; + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +   * updated fields.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the backup field is set. + */ + @java.lang.Override + public boolean hasBackup() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +   * updated fields.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The backup. + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.Backup getBackup() { + return backup_ == null + ? com.google.cloud.secretmanager.v1.Backup.getDefaultInstance() + : backup_; + } + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +   * updated fields.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.secretmanager.v1.BackupOrBuilder getBackupOrBuilder() { + return backup_ == null + ? com.google.cloud.secretmanager.v1.Backup.getDefaultInstance() + : backup_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getUpdateMask()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getBackup()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getUpdateMask()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getBackup()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.secretmanager.v1.UpdateBackupRequest)) { + return super.equals(obj); + } + com.google.cloud.secretmanager.v1.UpdateBackupRequest other = + (com.google.cloud.secretmanager.v1.UpdateBackupRequest) obj; + + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (hasBackup() != other.hasBackup()) return false; + if (hasBackup()) { + if (!getBackup().equals(other.getBackup())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + if (hasBackup()) { + hash = (37 * hash) + BACKUP_FIELD_NUMBER; + hash = (53 * hash) + getBackup().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.secretmanager.v1.UpdateBackupRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +   * Request message for
    +   * [SecretOperationsService.UpdateBackup][google.cloud.secretmanager.v1.SecretOperationsService.UpdateBackup].
    +   * 
    + * + * Protobuf type {@code google.cloud.secretmanager.v1.UpdateBackupRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.secretmanager.v1.UpdateBackupRequest) + com.google.cloud.secretmanager.v1.UpdateBackupRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_UpdateBackupRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_UpdateBackupRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.secretmanager.v1.UpdateBackupRequest.class, + com.google.cloud.secretmanager.v1.UpdateBackupRequest.Builder.class); + } + + // Construct using com.google.cloud.secretmanager.v1.UpdateBackupRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetUpdateMaskFieldBuilder(); + internalGetBackupFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + backup_ = null; + if (backupBuilder_ != null) { + backupBuilder_.dispose(); + backupBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.secretmanager.v1.OperationsServiceProto + .internal_static_google_cloud_secretmanager_v1_UpdateBackupRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.UpdateBackupRequest getDefaultInstanceForType() { + return com.google.cloud.secretmanager.v1.UpdateBackupRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.UpdateBackupRequest build() { + com.google.cloud.secretmanager.v1.UpdateBackupRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.UpdateBackupRequest buildPartial() { + com.google.cloud.secretmanager.v1.UpdateBackupRequest result = + new com.google.cloud.secretmanager.v1.UpdateBackupRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.secretmanager.v1.UpdateBackupRequest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.updateMask_ = updateMaskBuilder_ == null ? updateMask_ : updateMaskBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.backup_ = backupBuilder_ == null ? backup_ : backupBuilder_.build(); + to_bitField0_ |= 0x00000002; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.secretmanager.v1.UpdateBackupRequest) { + return mergeFrom((com.google.cloud.secretmanager.v1.UpdateBackupRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.secretmanager.v1.UpdateBackupRequest other) { + if (other == com.google.cloud.secretmanager.v1.UpdateBackupRequest.getDefaultInstance()) + return this; + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + if (other.hasBackup()) { + mergeBackup(other.getBackup()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + internalGetUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage(internalGetBackupFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + + /** + * + * + *
    +     * Optional. Field mask is used to specify the fields to be overwritten in the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +     * The fields specified in the `update_mask` are relative to the resource, not
    +     * the full request. A field will be overwritten if it is in the mask. If the
    +     * user does not provide a mask then all fields present in the request will be
    +     * overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +     * Optional. Field mask is used to specify the fields to be overwritten in the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +     * The fields specified in the `update_mask` are relative to the resource, not
    +     * the full request. A field will be overwritten if it is in the mask. If the
    +     * user does not provide a mask then all fields present in the request will be
    +     * overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Optional. Field mask is used to specify the fields to be overwritten in the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +     * The fields specified in the `update_mask` are relative to the resource, not
    +     * the full request. A field will be overwritten if it is in the mask. If the
    +     * user does not provide a mask then all fields present in the request will be
    +     * overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + } else { + updateMaskBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Field mask is used to specify the fields to be overwritten in the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +     * The fields specified in the `update_mask` are relative to the resource, not
    +     * the full request. A field will be overwritten if it is in the mask. If the
    +     * user does not provide a mask then all fields present in the request will be
    +     * overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Field mask is used to specify the fields to be overwritten in the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +     * The fields specified in the `update_mask` are relative to the resource, not
    +     * the full request. A field will be overwritten if it is in the mask. If the
    +     * user does not provide a mask then all fields present in the request will be
    +     * overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && updateMask_ != null + && updateMask_ != com.google.protobuf.FieldMask.getDefaultInstance()) { + getUpdateMaskBuilder().mergeFrom(value); + } else { + updateMask_ = value; + } + } else { + updateMaskBuilder_.mergeFrom(value); + } + if (updateMask_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Optional. Field mask is used to specify the fields to be overwritten in the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +     * The fields specified in the `update_mask` are relative to the resource, not
    +     * the full request. A field will be overwritten if it is in the mask. If the
    +     * user does not provide a mask then all fields present in the request will be
    +     * overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearUpdateMask() { + bitField0_ = (bitField0_ & ~0x00000001); + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Field mask is used to specify the fields to be overwritten in the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +     * The fields specified in the `update_mask` are relative to the resource, not
    +     * the full request. A field will be overwritten if it is in the mask. If the
    +     * user does not provide a mask then all fields present in the request will be
    +     * overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return internalGetUpdateMaskFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Optional. Field mask is used to specify the fields to be overwritten in the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +     * The fields specified in the `update_mask` are relative to the resource, not
    +     * the full request. A field will be overwritten if it is in the mask. If the
    +     * user does not provide a mask then all fields present in the request will be
    +     * overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + + /** + * + * + *
    +     * Optional. Field mask is used to specify the fields to be overwritten in the
    +     * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +     * The fields specified in the `update_mask` are relative to the resource, not
    +     * the full request. A field will be overwritten if it is in the mask. If the
    +     * user does not provide a mask then all fields present in the request will be
    +     * overwritten.
    +     * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + internalGetUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + private com.google.cloud.secretmanager.v1.Backup backup_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.secretmanager.v1.Backup, + com.google.cloud.secretmanager.v1.Backup.Builder, + com.google.cloud.secretmanager.v1.BackupOrBuilder> + backupBuilder_; + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +     * updated fields.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the backup field is set. + */ + public boolean hasBackup() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +     * updated fields.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The backup. + */ + public com.google.cloud.secretmanager.v1.Backup getBackup() { + if (backupBuilder_ == null) { + return backup_ == null + ? com.google.cloud.secretmanager.v1.Backup.getDefaultInstance() + : backup_; + } else { + return backupBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +     * updated fields.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setBackup(com.google.cloud.secretmanager.v1.Backup value) { + if (backupBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + backup_ = value; + } else { + backupBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +     * updated fields.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setBackup(com.google.cloud.secretmanager.v1.Backup.Builder builderForValue) { + if (backupBuilder_ == null) { + backup_ = builderForValue.build(); + } else { + backupBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +     * updated fields.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeBackup(com.google.cloud.secretmanager.v1.Backup value) { + if (backupBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && backup_ != null + && backup_ != com.google.cloud.secretmanager.v1.Backup.getDefaultInstance()) { + getBackupBuilder().mergeFrom(value); + } else { + backup_ = value; + } + } else { + backupBuilder_.mergeFrom(value); + } + if (backup_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +     * updated fields.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearBackup() { + bitField0_ = (bitField0_ & ~0x00000002); + backup_ = null; + if (backupBuilder_ != null) { + backupBuilder_.dispose(); + backupBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +     * updated fields.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.secretmanager.v1.Backup.Builder getBackupBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetBackupFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +     * updated fields.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.secretmanager.v1.BackupOrBuilder getBackupOrBuilder() { + if (backupBuilder_ != null) { + return backupBuilder_.getMessageOrBuilder(); + } else { + return backup_ == null + ? com.google.cloud.secretmanager.v1.Backup.getDefaultInstance() + : backup_; + } + } + + /** + * + * + *
    +     * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +     * updated fields.
    +     * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.secretmanager.v1.Backup, + com.google.cloud.secretmanager.v1.Backup.Builder, + com.google.cloud.secretmanager.v1.BackupOrBuilder> + internalGetBackupFieldBuilder() { + if (backupBuilder_ == null) { + backupBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.secretmanager.v1.Backup, + com.google.cloud.secretmanager.v1.Backup.Builder, + com.google.cloud.secretmanager.v1.BackupOrBuilder>( + getBackup(), getParentForChildren(), isClean()); + backup_ = null; + } + return backupBuilder_; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.secretmanager.v1.UpdateBackupRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.secretmanager.v1.UpdateBackupRequest) + private static final com.google.cloud.secretmanager.v1.UpdateBackupRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.secretmanager.v1.UpdateBackupRequest(); + } + + public static com.google.cloud.secretmanager.v1.UpdateBackupRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateBackupRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.secretmanager.v1.UpdateBackupRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/UpdateBackupRequestOrBuilder.java b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/UpdateBackupRequestOrBuilder.java new file mode 100644 index 000000000000..199b5e0b6d4d --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/java/com/google/cloud/secretmanager/v1/UpdateBackupRequestOrBuilder.java @@ -0,0 +1,129 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// NO CHECKED-IN PROTOBUF GENCODE +// source: google/cloud/secretmanager/v1/operations_service.proto +// Protobuf Java Version: 4.33.6 + +package com.google.cloud.secretmanager.v1; + +@com.google.protobuf.Generated +public interface UpdateBackupRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.secretmanager.v1.UpdateBackupRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
    +   * Optional. Field mask is used to specify the fields to be overwritten in the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +   * The fields specified in the `update_mask` are relative to the resource, not
    +   * the full request. A field will be overwritten if it is in the mask. If the
    +   * user does not provide a mask then all fields present in the request will be
    +   * overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + + /** + * + * + *
    +   * Optional. Field mask is used to specify the fields to be overwritten in the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +   * The fields specified in the `update_mask` are relative to the resource, not
    +   * the full request. A field will be overwritten if it is in the mask. If the
    +   * user does not provide a mask then all fields present in the request will be
    +   * overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + + /** + * + * + *
    +   * Optional. Field mask is used to specify the fields to be overwritten in the
    +   * [Backup][google.cloud.secretmanager.v1.Backup] resource by the update.
    +   * The fields specified in the `update_mask` are relative to the resource, not
    +   * the full request. A field will be overwritten if it is in the mask. If the
    +   * user does not provide a mask then all fields present in the request will be
    +   * overwritten.
    +   * 
    + * + * .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +   * updated fields.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the backup field is set. + */ + boolean hasBackup(); + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +   * updated fields.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The backup. + */ + com.google.cloud.secretmanager.v1.Backup getBackup(); + + /** + * + * + *
    +   * Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with
    +   * updated fields.
    +   * 
    + * + * + * .google.cloud.secretmanager.v1.Backup backup = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.secretmanager.v1.BackupOrBuilder getBackupOrBuilder(); +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/proto/google/cloud/secretmanager/v1/operations_service.proto b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/proto/google/cloud/secretmanager/v1/operations_service.proto new file mode 100644 index 000000000000..10643585d1cd --- /dev/null +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/proto/google/cloud/secretmanager/v1/operations_service.proto @@ -0,0 +1,416 @@ +// Copyright 2026 Google LLC +// +// 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. + +syntax = "proto3"; + +package google.cloud.secretmanager.v1; + +import "google/api/annotations.proto"; +import "google/api/client.proto"; +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/cloud/secretmanager/v1/resources.proto"; +import "google/longrunning/operations.proto"; +import "google/protobuf/empty.proto"; +import "google/protobuf/field_mask.proto"; +import "google/protobuf/timestamp.proto"; + +option csharp_namespace = "Google.Cloud.SecretManager.V1"; +option go_package = "cloud.google.com/go/secretmanager/apiv1/secretmanagerpb;secretmanagerpb"; +option java_multiple_files = true; +option java_outer_classname = "OperationsServiceProto"; +option java_package = "com.google.cloud.secretmanager.v1"; +option objc_class_prefix = "GSM"; +option php_namespace = "Google\\Cloud\\SecretManager\\V1"; +option ruby_package = "Google::Cloud::SecretManager::V1"; +option (google.api.resource_definition) = { + type: "cloudkms.googleapis.com/CryptoKey" + pattern: "projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}" +}; + +// Secret Operations Service +// +// Manages backups of secrets. Implements a REST model with the following +// objects: +// +// * [Backup][google.cloud.secretmanager.v1.Backup] +// +// Note: `SecretOperationsService` is a regional service and must be called +// using regional endpoints (`secretmanager.{location}.rep.googleapis.com`). +service SecretOperationsService { + option (google.api.default_host) = "secretmanager.googleapis.com"; + option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/cloud-platform"; + + // Lists Backups in a given project and location. + rpc ListBackups(ListBackupsRequest) returns (ListBackupsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/backups" + }; + option (google.api.method_signature) = "parent"; + } + + // Gets details of a single Backup. + rpc GetBackup(GetBackupRequest) returns (Backup) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/backups/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Creates a new Backup in a given project and location. + rpc CreateBackup(CreateBackupRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*}/backups" + body: "backup" + }; + option (google.api.method_signature) = "parent,backup,backup_id"; + option (google.longrunning.operation_info) = { + response_type: "Backup" + metadata_type: "OperationMetadata" + }; + } + + // Updates the parameters of a single Backup. + rpc UpdateBackup(UpdateBackupRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + patch: "/v1/{backup.name=projects/*/locations/*/backups/*}" + body: "backup" + }; + option (google.api.method_signature) = "backup,update_mask"; + option (google.longrunning.operation_info) = { + response_type: "Backup" + metadata_type: "OperationMetadata" + }; + } + + // Deletes a single Backup. + rpc DeleteBackup(DeleteBackupRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/backups/*}" + }; + option (google.api.method_signature) = "name"; + option (google.longrunning.operation_info) = { + response_type: "google.protobuf.Empty" + metadata_type: "OperationMetadata" + }; + } + + // Restores a [Secret][google.cloud.secretmanager.v1.Secret] from the given + // [Backup][google.cloud.secretmanager.v1.Backup]. This creates a *new* + // [Secret][google.cloud.secretmanager.v1.Secret] resource. The LRO tracks the + // restoration process, and the result of the LRO is the newly created Secret. + rpc RestoreBackup(RestoreBackupRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{name=projects/*/locations/*/backups/*}:restore" + body: "*" + }; + option (google.api.method_signature) = + "name,destination_secret_parent,destination_secret_id"; + option (google.longrunning.operation_info) = { + response_type: "google.cloud.secretmanager.v1.Secret" + metadata_type: "OperationMetadata" + }; + } +} + +// Request message for +// [SecretOperationsService.ListBackups][google.cloud.secretmanager.v1.SecretOperationsService.ListBackups]. +message ListBackupsRequest { + // Required. The resource name of the location associated with the + // [Backups][google.cloud.secretmanager.v1.Backup], in the format + // `projects/{project}/locations/{location}`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "secretmanager.googleapis.com/Backup" + } + ]; + + // Optional. Maximum number of backups to return. The service may return fewer + // than this value. If unspecified, at most 50 backups will be returned. The + // maximum value is 1000; values above 1000 will be coerced to 1000. + int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A token identifying a page of results the server should return. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Filter expression to restrict the returned + // [Backups][google.cloud.secretmanager.v1.Backup]. + string filter = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Field specification for sorting the results in the response. + string order_by = 5 [(google.api.field_behavior) = OPTIONAL]; +} + +// Response message for +// [SecretOperationsService.ListBackups][google.cloud.secretmanager.v1.SecretOperationsService.ListBackups]. +message ListBackupsResponse { + // The list of [Backups][google.cloud.secretmanager.v1.Backup] in the + // location. + repeated Backup backups = 1; + + // A token identifying a page of results the server should return. + string next_page_token = 2; + + // Unordered list. Resource names of the unreachable locations. + // Format: `projects/{project}/locations/{location}` + repeated string unreachable = 3 + [(google.api.field_behavior) = UNORDERED_LIST]; +} + +// Request message for +// [SecretOperationsService.GetBackup][google.cloud.secretmanager.v1.SecretOperationsService.GetBackup]. +message GetBackupRequest { + // Required. The resource name of the + // [Backup][google.cloud.secretmanager.v1.Backup], in the format + // `projects/{project}/locations/{location}/backups/{backup}`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "secretmanager.googleapis.com/Backup" + } + ]; +} + +// Request message for +// [SecretOperationsService.CreateBackup][google.cloud.secretmanager.v1.SecretOperationsService.CreateBackup]. +message CreateBackupRequest { + // Required. The resource name of the location where the + // [Backup][google.cloud.secretmanager.v1.Backup] will be created, in the + // format `projects/{project}/locations/{location}`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "secretmanager.googleapis.com/Backup" + } + ]; + + // Required. The ID to use for the backup, which will become the final + // component of the backup's resource name. + string backup_id = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource to + // create. + Backup backup = 3 [(google.api.field_behavior) = REQUIRED]; +} + +// Request message for +// [SecretOperationsService.UpdateBackup][google.cloud.secretmanager.v1.SecretOperationsService.UpdateBackup]. +message UpdateBackupRequest { + // Optional. Field mask is used to specify the fields to be overwritten in the + // [Backup][google.cloud.secretmanager.v1.Backup] resource by the update. + // The fields specified in the `update_mask` are relative to the resource, not + // the full request. A field will be overwritten if it is in the mask. If the + // user does not provide a mask then all fields present in the request will be + // overwritten. + google.protobuf.FieldMask update_mask = 1 + [(google.api.field_behavior) = OPTIONAL]; + + // Required. The [Backup][google.cloud.secretmanager.v1.Backup] resource with + // updated fields. + Backup backup = 2 [(google.api.field_behavior) = REQUIRED]; +} + +// Request message for +// [SecretOperationsService.DeleteBackup][google.cloud.secretmanager.v1.SecretOperationsService.DeleteBackup]. +message DeleteBackupRequest { + // Required. The resource name of the + // [Backup][google.cloud.secretmanager.v1.Backup] to delete, in the format + // `projects/{project}/locations/{location}/backups/{backup}`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "secretmanager.googleapis.com/Backup" + } + ]; + + // Optional. If set, the request will only succeed if it matches the etag of + // the currently stored [Backup][google.cloud.secretmanager.v1.Backup]. + string etag = 2 [(google.api.field_behavior) = OPTIONAL]; +} + +// Request message for +// [SecretOperationsService.RestoreBackup][google.cloud.secretmanager.v1.SecretOperationsService.RestoreBackup]. +message RestoreBackupRequest { + // Required. The resource name of the + // [Backup][google.cloud.secretmanager.v1.Backup] to restore from. Format: + // `projects/{project}/locations/{location}/backups/{backup}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "secretmanager.googleapis.com/Backup" + } + ]; + + // Required. Parent of the new [Secret][google.cloud.secretmanager.v1.Secret] + // to be created from this backup. Formats: + // - `projects/{project}/locations/{location}` (for regional secrets) + // - `projects/{project}` (for global secrets) + string destination_secret_parent = 2 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "secretmanager.googleapis.com/Secret" + } + ]; + + // Required. ID of the new [Secret][google.cloud.secretmanager.v1.Secret] to + // be created from this backup. This must be unique within the project. + // + // A secret ID is a string with a maximum length of 255 characters and can + // contain uppercase and lowercase letters, numerals, and the hyphen (`-`) + // and underscore (`_`) characters. + string destination_secret_id = 3 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The resource name of the Cloud KMS CryptoKey to be used to + // encrypt the [Secret][google.cloud.secretmanager.v1.Secret]. + // Format: + // `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}` + string kms_key_name = 4 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.resource_reference) = { + type: "cloudkms.googleapis.com/CryptoKey" + } + ]; +} + +// Represents the metadata of the long-running operation. +message OperationMetadata { + // Represents progress information for operations involving multiple secret + // versions. + message Progress { + // Output only. Provides the total number of secret versions to be processed + // by the operation. + int32 total_version_count = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Number of secret versions that have been successfully + // processed so far. + int32 completed_version_count = 2 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Number of secret versions that failed to process. + int32 failed_version_count = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + } + + // Output only. Time the operation was created. + google.protobuf.Timestamp create_time = 1 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Time the operation finished running. + google.protobuf.Timestamp end_time = 2 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Server-defined resource path for the target of the operation. + string target = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Name of the verb executed by the operation. + string verb = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Human-readable status of the operation, if any. + string status_message = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Identifies whether the user has requested cancellation + // of the operation. Operations that have been cancelled successfully + // have + // [google.longrunning.Operation.error][google.longrunning.Operation.error] + // value with a [google.rpc.Status.code][google.rpc.Status.code] of `1`, + // corresponding to `Code.CANCELLED`. + bool requested_cancellation = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. API version used to start the operation. + string api_version = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Represents the progress of the operation. This field is + // populated for operations that involve processing multiple secret versions. + Progress progress = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; +} + +// A Backup of a Secret. +// Backups are regional resources. +message Backup { + option (google.api.resource) = { + type: "secretmanager.googleapis.com/Backup" + pattern: "projects/{project}/locations/{location}/backups/{backup}" + plural: "backups" + singular: "backup" + }; + + // Enum representing the state of the + // [Backup][google.cloud.secretmanager.v1.Backup]. + enum State { + // Backup state is unspecified. + STATE_UNSPECIFIED = 0; + + // The backup is being created. + CREATING = 1; + + // The backup is active and can be used. + ACTIVE = 2; + + // The backup is being updated. + UPDATING = 3; + + // The backup creation or update failed. + FAILED = 4; + } + + // Identifier. Resource name of the backup. + // Format: `projects/{project}/locations/{location}/backups/{backup}` + string name = 1 [(google.api.field_behavior) = IDENTIFIER]; + + // Required. Immutable. Resource name of the + // [Secret][google.cloud.secretmanager.v1.Secret] that this backup is for. The + // source [Secret][google.cloud.secretmanager.v1.Secret] can be in a different + // region than the [Backup][google.cloud.secretmanager.v1.Backup]. This field + // is immutable after creation. Formats: + // - `projects/{project}/locations/{location}/secrets/{secret}` (for regional + // secrets) + // - `projects/{project}/secrets/{secret}` (for global secrets) + string source_secret = 2 [ + (google.api.field_behavior) = REQUIRED, + (google.api.field_behavior) = IMMUTABLE, + (google.api.resource_reference) = { + type: "secretmanager.googleapis.com/Secret" + } + ]; + + // Output only. Time at which the backup resource was created. + google.protobuf.Timestamp create_time = 3 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Time at which the backup resource was last updated. + google.protobuf.Timestamp update_time = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Creation time of the source + // [Secret][google.cloud.secretmanager.v1.Secret] at the moment the backup was + // initiated. + google.protobuf.Timestamp source_secret_create_time = 5 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Number of non-destroyed secret versions contained in this + // backup. + int32 version_count = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Labels with user-defined metadata. + map labels = 7 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. Current state of the Backup. + State state = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Used for optimistic concurrency control as a way to help prevent + // simultaneous updates of a backup from overwriting each other. + string etag = 11 [(google.api.field_behavior) = OPTIONAL]; +} diff --git a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/proto/google/cloud/secretmanager/v1/resources.proto b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/proto/google/cloud/secretmanager/v1/resources.proto index dd26f3ea8f3f..d884b2680d5c 100644 --- a/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/proto/google/cloud/secretmanager/v1/resources.proto +++ b/java-secretmanager/proto-google-cloud-secretmanager-v1/src/main/proto/google/cloud/secretmanager/v1/resources.proto @@ -47,6 +47,19 @@ message Secret { singular: "secret" }; + // Represents the current state of the Secret. + enum State { + // Not specified. + STATE_UNSPECIFIED = 0; + + // Secret is in active state, usage is allowed. + STATE_ACTIVE = 1; + + // Secret is being restored from a backup. Operations on the secret and its + // versions are restricted. + STATE_RESTORING = 2; + } + // This defines the various values of the type of secret can be. enum SecretType { // Applicable to all secrets which do not have any restriction on the @@ -216,6 +229,9 @@ message Secret { // certain operations on the typed secret. google.iam.v1.ResourcePolicyMember policy_member = 18 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The current state of the Secret. + State state = 19 [(google.api.field_behavior) = OUTPUT_ONLY]; } // A secret version resource in the Secret Manager API. diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/create/SyncCreateSetCredentialsProvider.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/create/SyncCreateSetCredentialsProvider.java new file mode 100644 index 000000000000..233c3c45ad07 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/create/SyncCreateSetCredentialsProvider.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_Create_SetCredentialsProvider_sync] +import com.google.api.gax.core.FixedCredentialsProvider; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceSettings; +import com.google.cloud.secretmanager.v1.myCredentials; + +public class SyncCreateSetCredentialsProvider { + + public static void main(String[] args) throws Exception { + syncCreateSetCredentialsProvider(); + } + + public static void syncCreateSetCredentialsProvider() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + SecretOperationsServiceSettings secretOperationsServiceSettings = + SecretOperationsServiceSettings.newBuilder() + .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials)) + .build(); + SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create(secretOperationsServiceSettings); + } +} +// [END secretmanager_v1_generated_SecretOperationsService_Create_SetCredentialsProvider_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/create/SyncCreateSetEndpoint.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/create/SyncCreateSetEndpoint.java new file mode 100644 index 000000000000..a4bc64da299d --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/create/SyncCreateSetEndpoint.java @@ -0,0 +1,42 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_Create_SetEndpoint_sync] +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceSettings; +import com.google.cloud.secretmanager.v1.myEndpoint; + +public class SyncCreateSetEndpoint { + + public static void main(String[] args) throws Exception { + syncCreateSetEndpoint(); + } + + public static void syncCreateSetEndpoint() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + SecretOperationsServiceSettings secretOperationsServiceSettings = + SecretOperationsServiceSettings.newBuilder().setEndpoint(myEndpoint).build(); + SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create(secretOperationsServiceSettings); + } +} +// [END secretmanager_v1_generated_SecretOperationsService_Create_SetEndpoint_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/create/SyncCreateUseHttpJsonTransport.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/create/SyncCreateUseHttpJsonTransport.java new file mode 100644 index 000000000000..9fb8f10d41ed --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/create/SyncCreateUseHttpJsonTransport.java @@ -0,0 +1,41 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_Create_UseHttpJsonTransport_sync] +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceSettings; + +public class SyncCreateUseHttpJsonTransport { + + public static void main(String[] args) throws Exception { + syncCreateUseHttpJsonTransport(); + } + + public static void syncCreateUseHttpJsonTransport() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + SecretOperationsServiceSettings secretOperationsServiceSettings = + SecretOperationsServiceSettings.newHttpJsonBuilder().build(); + SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create(secretOperationsServiceSettings); + } +} +// [END secretmanager_v1_generated_SecretOperationsService_Create_UseHttpJsonTransport_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/AsyncCreateBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/AsyncCreateBackup.java new file mode 100644 index 000000000000..3ca8e95c2362 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/AsyncCreateBackup.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_CreateBackup_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.CreateBackupRequest; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.longrunning.Operation; + +public class AsyncCreateBackup { + + public static void main(String[] args) throws Exception { + asyncCreateBackup(); + } + + public static void asyncCreateBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + CreateBackupRequest request = + CreateBackupRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setBackupId("backupId2121930365") + .setBackup(Backup.newBuilder().build()) + .build(); + ApiFuture future = + secretOperationsServiceClient.createBackupCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_CreateBackup_async] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/AsyncCreateBackupLRO.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/AsyncCreateBackupLRO.java new file mode 100644 index 000000000000..2c8490c3e01f --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/AsyncCreateBackupLRO.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_CreateBackup_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.CreateBackupRequest; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.OperationMetadata; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class AsyncCreateBackupLRO { + + public static void main(String[] args) throws Exception { + asyncCreateBackupLRO(); + } + + public static void asyncCreateBackupLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + CreateBackupRequest request = + CreateBackupRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setBackupId("backupId2121930365") + .setBackup(Backup.newBuilder().build()) + .build(); + OperationFuture future = + secretOperationsServiceClient.createBackupOperationCallable().futureCall(request); + // Do something. + Backup response = future.get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_CreateBackup_LRO_async] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/SyncCreateBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/SyncCreateBackup.java new file mode 100644 index 000000000000..f348e0cf7966 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/SyncCreateBackup.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_CreateBackup_sync] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.CreateBackupRequest; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncCreateBackup { + + public static void main(String[] args) throws Exception { + syncCreateBackup(); + } + + public static void syncCreateBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + CreateBackupRequest request = + CreateBackupRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setBackupId("backupId2121930365") + .setBackup(Backup.newBuilder().build()) + .build(); + Backup response = secretOperationsServiceClient.createBackupAsync(request).get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_CreateBackup_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/SyncCreateBackupLocationnameBackupString.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/SyncCreateBackupLocationnameBackupString.java new file mode 100644 index 000000000000..56c13a607aa8 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/SyncCreateBackupLocationnameBackupString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_CreateBackup_LocationnameBackupString_sync] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncCreateBackupLocationnameBackupString { + + public static void main(String[] args) throws Exception { + syncCreateBackupLocationnameBackupString(); + } + + public static void syncCreateBackupLocationnameBackupString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Backup backup = Backup.newBuilder().build(); + String backupId = "backupId2121930365"; + Backup response = + secretOperationsServiceClient.createBackupAsync(parent, backup, backupId).get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_CreateBackup_LocationnameBackupString_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/SyncCreateBackupStringBackupString.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/SyncCreateBackupStringBackupString.java new file mode 100644 index 000000000000..1f76aa39d6ff --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/createbackup/SyncCreateBackupStringBackupString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_CreateBackup_StringBackupString_sync] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncCreateBackupStringBackupString { + + public static void main(String[] args) throws Exception { + syncCreateBackupStringBackupString(); + } + + public static void syncCreateBackupStringBackupString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + Backup backup = Backup.newBuilder().build(); + String backupId = "backupId2121930365"; + Backup response = + secretOperationsServiceClient.createBackupAsync(parent, backup, backupId).get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_CreateBackup_StringBackupString_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/AsyncDeleteBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/AsyncDeleteBackup.java new file mode 100644 index 000000000000..f976eb3bf7de --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/AsyncDeleteBackup.java @@ -0,0 +1,52 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_DeleteBackup_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.DeleteBackupRequest; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.longrunning.Operation; + +public class AsyncDeleteBackup { + + public static void main(String[] args) throws Exception { + asyncDeleteBackup(); + } + + public static void asyncDeleteBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + DeleteBackupRequest request = + DeleteBackupRequest.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setEtag("etag3123477") + .build(); + ApiFuture future = + secretOperationsServiceClient.deleteBackupCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_DeleteBackup_async] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/AsyncDeleteBackupLRO.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/AsyncDeleteBackupLRO.java new file mode 100644 index 000000000000..0b6d2ab68b8c --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/AsyncDeleteBackupLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_DeleteBackup_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.DeleteBackupRequest; +import com.google.cloud.secretmanager.v1.OperationMetadata; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.protobuf.Empty; + +public class AsyncDeleteBackupLRO { + + public static void main(String[] args) throws Exception { + asyncDeleteBackupLRO(); + } + + public static void asyncDeleteBackupLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + DeleteBackupRequest request = + DeleteBackupRequest.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setEtag("etag3123477") + .build(); + OperationFuture future = + secretOperationsServiceClient.deleteBackupOperationCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_DeleteBackup_LRO_async] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/SyncDeleteBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/SyncDeleteBackup.java new file mode 100644 index 000000000000..dd7bfcd1bcdc --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/SyncDeleteBackup.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_DeleteBackup_sync] +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.DeleteBackupRequest; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.protobuf.Empty; + +public class SyncDeleteBackup { + + public static void main(String[] args) throws Exception { + syncDeleteBackup(); + } + + public static void syncDeleteBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + DeleteBackupRequest request = + DeleteBackupRequest.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setEtag("etag3123477") + .build(); + secretOperationsServiceClient.deleteBackupAsync(request).get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_DeleteBackup_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/SyncDeleteBackupBackupname.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/SyncDeleteBackupBackupname.java new file mode 100644 index 000000000000..627e26958cbf --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/SyncDeleteBackupBackupname.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_DeleteBackup_Backupname_sync] +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.protobuf.Empty; + +public class SyncDeleteBackupBackupname { + + public static void main(String[] args) throws Exception { + syncDeleteBackupBackupname(); + } + + public static void syncDeleteBackupBackupname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + secretOperationsServiceClient.deleteBackupAsync(name).get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_DeleteBackup_Backupname_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/SyncDeleteBackupString.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/SyncDeleteBackupString.java new file mode 100644 index 000000000000..31d2784ca80f --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/deletebackup/SyncDeleteBackupString.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_DeleteBackup_String_sync] +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.protobuf.Empty; + +public class SyncDeleteBackupString { + + public static void main(String[] args) throws Exception { + syncDeleteBackupString(); + } + + public static void syncDeleteBackupString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + String name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString(); + secretOperationsServiceClient.deleteBackupAsync(name).get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_DeleteBackup_String_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/AsyncGetBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/AsyncGetBackup.java new file mode 100644 index 000000000000..2b015a791a8c --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/AsyncGetBackup.java @@ -0,0 +1,51 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_GetBackup_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.GetBackupRequest; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class AsyncGetBackup { + + public static void main(String[] args) throws Exception { + asyncGetBackup(); + } + + public static void asyncGetBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + GetBackupRequest request = + GetBackupRequest.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .build(); + ApiFuture future = + secretOperationsServiceClient.getBackupCallable().futureCall(request); + // Do something. + Backup response = future.get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_GetBackup_async] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/SyncGetBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/SyncGetBackup.java new file mode 100644 index 000000000000..e89e90a2c048 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/SyncGetBackup.java @@ -0,0 +1,47 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_GetBackup_sync] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.GetBackupRequest; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncGetBackup { + + public static void main(String[] args) throws Exception { + syncGetBackup(); + } + + public static void syncGetBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + GetBackupRequest request = + GetBackupRequest.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .build(); + Backup response = secretOperationsServiceClient.getBackup(request); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_GetBackup_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/SyncGetBackupBackupname.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/SyncGetBackupBackupname.java new file mode 100644 index 000000000000..237f42650fe5 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/SyncGetBackupBackupname.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_GetBackup_Backupname_sync] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncGetBackupBackupname { + + public static void main(String[] args) throws Exception { + syncGetBackupBackupname(); + } + + public static void syncGetBackupBackupname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + Backup response = secretOperationsServiceClient.getBackup(name); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_GetBackup_Backupname_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/SyncGetBackupString.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/SyncGetBackupString.java new file mode 100644 index 000000000000..0d6f41d9b07e --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/getbackup/SyncGetBackupString.java @@ -0,0 +1,43 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_GetBackup_String_sync] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncGetBackupString { + + public static void main(String[] args) throws Exception { + syncGetBackupString(); + } + + public static void syncGetBackupString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + String name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString(); + Backup response = secretOperationsServiceClient.getBackup(name); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_GetBackup_String_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/AsyncListBackups.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/AsyncListBackups.java new file mode 100644 index 000000000000..25102097ea52 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/AsyncListBackups.java @@ -0,0 +1,57 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_ListBackups_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.ListBackupsRequest; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class AsyncListBackups { + + public static void main(String[] args) throws Exception { + asyncListBackups(); + } + + public static void asyncListBackups() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + ListBackupsRequest request = + ListBackupsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + ApiFuture future = + secretOperationsServiceClient.listBackupsPagedCallable().futureCall(request); + // Do something. + for (Backup element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_ListBackups_async] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/AsyncListBackupsPaged.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/AsyncListBackupsPaged.java new file mode 100644 index 000000000000..ebf630fb1380 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/AsyncListBackupsPaged.java @@ -0,0 +1,65 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_ListBackups_Paged_async] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.ListBackupsRequest; +import com.google.cloud.secretmanager.v1.ListBackupsResponse; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.common.base.Strings; + +public class AsyncListBackupsPaged { + + public static void main(String[] args) throws Exception { + asyncListBackupsPaged(); + } + + public static void asyncListBackupsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + ListBackupsRequest request = + ListBackupsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + while (true) { + ListBackupsResponse response = + secretOperationsServiceClient.listBackupsCallable().call(request); + for (Backup element : response.getBackupsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_ListBackups_Paged_async] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/SyncListBackups.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/SyncListBackups.java new file mode 100644 index 000000000000..d86ae126173e --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/SyncListBackups.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_ListBackups_sync] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.ListBackupsRequest; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncListBackups { + + public static void main(String[] args) throws Exception { + syncListBackups(); + } + + public static void syncListBackups() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + ListBackupsRequest request = + ListBackupsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + for (Backup element : secretOperationsServiceClient.listBackups(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_ListBackups_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/SyncListBackupsLocationname.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/SyncListBackupsLocationname.java new file mode 100644 index 000000000000..5cccf2b8c299 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/SyncListBackupsLocationname.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_ListBackups_Locationname_sync] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncListBackupsLocationname { + + public static void main(String[] args) throws Exception { + syncListBackupsLocationname(); + } + + public static void syncListBackupsLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (Backup element : secretOperationsServiceClient.listBackups(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_ListBackups_Locationname_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/SyncListBackupsString.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/SyncListBackupsString.java new file mode 100644 index 000000000000..24fa89b25c73 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/listbackups/SyncListBackupsString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_ListBackups_String_sync] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncListBackupsString { + + public static void main(String[] args) throws Exception { + syncListBackupsString(); + } + + public static void syncListBackupsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (Backup element : secretOperationsServiceClient.listBackups(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_ListBackups_String_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/AsyncRestoreBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/AsyncRestoreBackup.java new file mode 100644 index 000000000000..8b260e4f2d57 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/AsyncRestoreBackup.java @@ -0,0 +1,58 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_RestoreBackup_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.CryptoKeyName; +import com.google.cloud.secretmanager.v1.ProjectName; +import com.google.cloud.secretmanager.v1.RestoreBackupRequest; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.longrunning.Operation; + +public class AsyncRestoreBackup { + + public static void main(String[] args) throws Exception { + asyncRestoreBackup(); + } + + public static void asyncRestoreBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + RestoreBackupRequest request = + RestoreBackupRequest.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setDestinationSecretParent(ProjectName.of("[PROJECT]").toString()) + .setDestinationSecretId("destinationSecretId171779609") + .setKmsKeyName( + CryptoKeyName.of("[PROJECT]", "[LOCATION]", "[KEY_RING]", "[CRYPTO_KEY]") + .toString()) + .build(); + ApiFuture future = + secretOperationsServiceClient.restoreBackupCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_RestoreBackup_async] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/AsyncRestoreBackupLRO.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/AsyncRestoreBackupLRO.java new file mode 100644 index 000000000000..c05bfdc7eb96 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/AsyncRestoreBackupLRO.java @@ -0,0 +1,59 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_RestoreBackup_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.CryptoKeyName; +import com.google.cloud.secretmanager.v1.OperationMetadata; +import com.google.cloud.secretmanager.v1.ProjectName; +import com.google.cloud.secretmanager.v1.RestoreBackupRequest; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class AsyncRestoreBackupLRO { + + public static void main(String[] args) throws Exception { + asyncRestoreBackupLRO(); + } + + public static void asyncRestoreBackupLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + RestoreBackupRequest request = + RestoreBackupRequest.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setDestinationSecretParent(ProjectName.of("[PROJECT]").toString()) + .setDestinationSecretId("destinationSecretId171779609") + .setKmsKeyName( + CryptoKeyName.of("[PROJECT]", "[LOCATION]", "[KEY_RING]", "[CRYPTO_KEY]") + .toString()) + .build(); + OperationFuture future = + secretOperationsServiceClient.restoreBackupOperationCallable().futureCall(request); + // Do something. + Secret response = future.get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_RestoreBackup_LRO_async] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackup.java new file mode 100644 index 000000000000..30e0185c3883 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackup.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_RestoreBackup_sync] +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.CryptoKeyName; +import com.google.cloud.secretmanager.v1.ProjectName; +import com.google.cloud.secretmanager.v1.RestoreBackupRequest; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncRestoreBackup { + + public static void main(String[] args) throws Exception { + syncRestoreBackup(); + } + + public static void syncRestoreBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + RestoreBackupRequest request = + RestoreBackupRequest.newBuilder() + .setName(BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString()) + .setDestinationSecretParent(ProjectName.of("[PROJECT]").toString()) + .setDestinationSecretId("destinationSecretId171779609") + .setKmsKeyName( + CryptoKeyName.of("[PROJECT]", "[LOCATION]", "[KEY_RING]", "[CRYPTO_KEY]") + .toString()) + .build(); + Secret response = secretOperationsServiceClient.restoreBackupAsync(request).get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_RestoreBackup_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupBackupnameLocationnameString.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupBackupnameLocationnameString.java new file mode 100644 index 000000000000..db2baa24113b --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupBackupnameLocationnameString.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_RestoreBackup_BackupnameLocationnameString_sync] +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncRestoreBackupBackupnameLocationnameString { + + public static void main(String[] args) throws Exception { + syncRestoreBackupBackupnameLocationnameString(); + } + + public static void syncRestoreBackupBackupnameLocationnameString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]"); + String destinationSecretId = "destinationSecretId171779609"; + Secret response = + secretOperationsServiceClient + .restoreBackupAsync(name, destinationSecretParent, destinationSecretId) + .get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_RestoreBackup_BackupnameLocationnameString_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupBackupnameProjectnameString.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupBackupnameProjectnameString.java new file mode 100644 index 000000000000..1a2166b4fd32 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupBackupnameProjectnameString.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_RestoreBackup_BackupnameProjectnameString_sync] +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.ProjectName; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncRestoreBackupBackupnameProjectnameString { + + public static void main(String[] args) throws Exception { + syncRestoreBackupBackupnameProjectnameString(); + } + + public static void syncRestoreBackupBackupnameProjectnameString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + ProjectName destinationSecretParent = ProjectName.of("[PROJECT]"); + String destinationSecretId = "destinationSecretId171779609"; + Secret response = + secretOperationsServiceClient + .restoreBackupAsync(name, destinationSecretParent, destinationSecretId) + .get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_RestoreBackup_BackupnameProjectnameString_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupBackupnameStringString.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupBackupnameStringString.java new file mode 100644 index 000000000000..8f3c1187bef6 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupBackupnameStringString.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_RestoreBackup_BackupnameStringString_sync] +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.ProjectName; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncRestoreBackupBackupnameStringString { + + public static void main(String[] args) throws Exception { + syncRestoreBackupBackupnameStringString(); + } + + public static void syncRestoreBackupBackupnameStringString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + BackupName name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]"); + String destinationSecretParent = ProjectName.of("[PROJECT]").toString(); + String destinationSecretId = "destinationSecretId171779609"; + Secret response = + secretOperationsServiceClient + .restoreBackupAsync(name, destinationSecretParent, destinationSecretId) + .get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_RestoreBackup_BackupnameStringString_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupStringLocationnameString.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupStringLocationnameString.java new file mode 100644 index 000000000000..4233d5dec612 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupStringLocationnameString.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_RestoreBackup_StringLocationnameString_sync] +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.LocationName; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncRestoreBackupStringLocationnameString { + + public static void main(String[] args) throws Exception { + syncRestoreBackupStringLocationnameString(); + } + + public static void syncRestoreBackupStringLocationnameString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + String name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString(); + LocationName destinationSecretParent = LocationName.of("[PROJECT]", "[LOCATION]"); + String destinationSecretId = "destinationSecretId171779609"; + Secret response = + secretOperationsServiceClient + .restoreBackupAsync(name, destinationSecretParent, destinationSecretId) + .get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_RestoreBackup_StringLocationnameString_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupStringProjectnameString.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupStringProjectnameString.java new file mode 100644 index 000000000000..8256ac4bd495 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupStringProjectnameString.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_RestoreBackup_StringProjectnameString_sync] +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.ProjectName; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncRestoreBackupStringProjectnameString { + + public static void main(String[] args) throws Exception { + syncRestoreBackupStringProjectnameString(); + } + + public static void syncRestoreBackupStringProjectnameString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + String name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString(); + ProjectName destinationSecretParent = ProjectName.of("[PROJECT]"); + String destinationSecretId = "destinationSecretId171779609"; + Secret response = + secretOperationsServiceClient + .restoreBackupAsync(name, destinationSecretParent, destinationSecretId) + .get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_RestoreBackup_StringProjectnameString_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupStringStringString.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupStringStringString.java new file mode 100644 index 000000000000..4ca393bbb0ca --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/restorebackup/SyncRestoreBackupStringStringString.java @@ -0,0 +1,49 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_RestoreBackup_StringStringString_sync] +import com.google.cloud.secretmanager.v1.BackupName; +import com.google.cloud.secretmanager.v1.ProjectName; +import com.google.cloud.secretmanager.v1.Secret; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; + +public class SyncRestoreBackupStringStringString { + + public static void main(String[] args) throws Exception { + syncRestoreBackupStringStringString(); + } + + public static void syncRestoreBackupStringStringString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + String name = BackupName.of("[PROJECT]", "[LOCATION]", "[BACKUP]").toString(); + String destinationSecretParent = ProjectName.of("[PROJECT]").toString(); + String destinationSecretId = "destinationSecretId171779609"; + Secret response = + secretOperationsServiceClient + .restoreBackupAsync(name, destinationSecretParent, destinationSecretId) + .get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_RestoreBackup_StringStringString_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/AsyncUpdateBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/AsyncUpdateBackup.java new file mode 100644 index 000000000000..f21b4c9df255 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/AsyncUpdateBackup.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_UpdateBackup_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.cloud.secretmanager.v1.UpdateBackupRequest; +import com.google.longrunning.Operation; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateBackup { + + public static void main(String[] args) throws Exception { + asyncUpdateBackup(); + } + + public static void asyncUpdateBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + UpdateBackupRequest request = + UpdateBackupRequest.newBuilder() + .setUpdateMask(FieldMask.newBuilder().build()) + .setBackup(Backup.newBuilder().build()) + .build(); + ApiFuture future = + secretOperationsServiceClient.updateBackupCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_UpdateBackup_async] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/AsyncUpdateBackupLRO.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/AsyncUpdateBackupLRO.java new file mode 100644 index 000000000000..f72bdaa08398 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/AsyncUpdateBackupLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_UpdateBackup_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.OperationMetadata; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.cloud.secretmanager.v1.UpdateBackupRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateBackupLRO { + + public static void main(String[] args) throws Exception { + asyncUpdateBackupLRO(); + } + + public static void asyncUpdateBackupLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + UpdateBackupRequest request = + UpdateBackupRequest.newBuilder() + .setUpdateMask(FieldMask.newBuilder().build()) + .setBackup(Backup.newBuilder().build()) + .build(); + OperationFuture future = + secretOperationsServiceClient.updateBackupOperationCallable().futureCall(request); + // Do something. + Backup response = future.get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_UpdateBackup_LRO_async] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/SyncUpdateBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/SyncUpdateBackup.java new file mode 100644 index 000000000000..29311870e1f8 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/SyncUpdateBackup.java @@ -0,0 +1,48 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_UpdateBackup_sync] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.cloud.secretmanager.v1.UpdateBackupRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateBackup { + + public static void main(String[] args) throws Exception { + syncUpdateBackup(); + } + + public static void syncUpdateBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + UpdateBackupRequest request = + UpdateBackupRequest.newBuilder() + .setUpdateMask(FieldMask.newBuilder().build()) + .setBackup(Backup.newBuilder().build()) + .build(); + Backup response = secretOperationsServiceClient.updateBackupAsync(request).get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_UpdateBackup_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/SyncUpdateBackupBackupFieldmask.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/SyncUpdateBackupBackupFieldmask.java new file mode 100644 index 000000000000..905931cf0e51 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservice/updatebackup/SyncUpdateBackupBackupFieldmask.java @@ -0,0 +1,44 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsService_UpdateBackup_BackupFieldmask_sync] +import com.google.cloud.secretmanager.v1.Backup; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceClient; +import com.google.protobuf.FieldMask; + +public class SyncUpdateBackupBackupFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateBackupBackupFieldmask(); + } + + public static void syncUpdateBackupBackupFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (SecretOperationsServiceClient secretOperationsServiceClient = + SecretOperationsServiceClient.create()) { + Backup backup = Backup.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + Backup response = secretOperationsServiceClient.updateBackupAsync(backup, updateMask).get(); + } + } +} +// [END secretmanager_v1_generated_SecretOperationsService_UpdateBackup_BackupFieldmask_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservicesettings/createbackup/SyncCreateBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservicesettings/createbackup/SyncCreateBackup.java new file mode 100644 index 000000000000..fbc90fd70b50 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservicesettings/createbackup/SyncCreateBackup.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsServiceSettings_CreateBackup_sync] +import com.google.api.gax.longrunning.OperationalTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.retrying.TimedRetryAlgorithm; +import com.google.cloud.secretmanager.v1.SecretOperationsServiceSettings; +import java.time.Duration; + +public class SyncCreateBackup { + + public static void main(String[] args) throws Exception { + syncCreateBackup(); + } + + public static void syncCreateBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + SecretOperationsServiceSettings.Builder secretOperationsServiceSettingsBuilder = + SecretOperationsServiceSettings.newBuilder(); + TimedRetryAlgorithm timedRetryAlgorithm = + OperationalTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(500)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(5000)) + .setTotalTimeoutDuration(Duration.ofHours(24)) + .build()); + secretOperationsServiceSettingsBuilder + .createClusterOperationSettings() + .setPollingAlgorithm(timedRetryAlgorithm) + .build(); + } +} +// [END secretmanager_v1_generated_SecretOperationsServiceSettings_CreateBackup_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservicesettings/getbackup/SyncGetBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservicesettings/getbackup/SyncGetBackup.java new file mode 100644 index 000000000000..adcd3525b661 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/secretoperationsservicesettings/getbackup/SyncGetBackup.java @@ -0,0 +1,57 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.samples; + +// [START secretmanager_v1_generated_SecretOperationsServiceSettings_GetBackup_sync] +import com.google.cloud.secretmanager.v1.SecretOperationsServiceSettings; +import java.time.Duration; + +public class SyncGetBackup { + + public static void main(String[] args) throws Exception { + syncGetBackup(); + } + + public static void syncGetBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + SecretOperationsServiceSettings.Builder secretOperationsServiceSettingsBuilder = + SecretOperationsServiceSettings.newBuilder(); + secretOperationsServiceSettingsBuilder + .getBackupSettings() + .setRetrySettings( + secretOperationsServiceSettingsBuilder + .getBackupSettings() + .getRetrySettings() + .toBuilder() + .setInitialRetryDelayDuration(Duration.ofSeconds(1)) + .setInitialRpcTimeoutDuration(Duration.ofSeconds(5)) + .setMaxAttempts(5) + .setMaxRetryDelayDuration(Duration.ofSeconds(30)) + .setMaxRpcTimeoutDuration(Duration.ofSeconds(60)) + .setRetryDelayMultiplier(1.3) + .setRpcTimeoutMultiplier(1.5) + .setTotalTimeoutDuration(Duration.ofSeconds(300)) + .build()); + SecretOperationsServiceSettings secretOperationsServiceSettings = + secretOperationsServiceSettingsBuilder.build(); + } +} +// [END secretmanager_v1_generated_SecretOperationsServiceSettings_GetBackup_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/stub/secretoperationsservicestubsettings/createbackup/SyncCreateBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/stub/secretoperationsservicestubsettings/createbackup/SyncCreateBackup.java new file mode 100644 index 000000000000..63f86dfa5c4a --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/stub/secretoperationsservicestubsettings/createbackup/SyncCreateBackup.java @@ -0,0 +1,54 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.stub.samples; + +// [START secretmanager_v1_generated_SecretOperationsServiceStubSettings_CreateBackup_sync] +import com.google.api.gax.longrunning.OperationalTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.retrying.TimedRetryAlgorithm; +import com.google.cloud.secretmanager.v1.stub.SecretOperationsServiceStubSettings; +import java.time.Duration; + +public class SyncCreateBackup { + + public static void main(String[] args) throws Exception { + syncCreateBackup(); + } + + public static void syncCreateBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + SecretOperationsServiceStubSettings.Builder secretOperationsServiceSettingsBuilder = + SecretOperationsServiceStubSettings.newBuilder(); + TimedRetryAlgorithm timedRetryAlgorithm = + OperationalTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(500)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(5000)) + .setTotalTimeoutDuration(Duration.ofHours(24)) + .build()); + secretOperationsServiceSettingsBuilder + .createClusterOperationSettings() + .setPollingAlgorithm(timedRetryAlgorithm) + .build(); + } +} +// [END secretmanager_v1_generated_SecretOperationsServiceStubSettings_CreateBackup_sync] diff --git a/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/stub/secretoperationsservicestubsettings/getbackup/SyncGetBackup.java b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/stub/secretoperationsservicestubsettings/getbackup/SyncGetBackup.java new file mode 100644 index 000000000000..e23001a73fd7 --- /dev/null +++ b/java-secretmanager/samples/snippets/generated/com/google/cloud/secretmanager/v1/stub/secretoperationsservicestubsettings/getbackup/SyncGetBackup.java @@ -0,0 +1,57 @@ +/* + * Copyright 2026 Google LLC + * + * 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 + * + * https://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. + */ + +package com.google.cloud.secretmanager.v1.stub.samples; + +// [START secretmanager_v1_generated_SecretOperationsServiceStubSettings_GetBackup_sync] +import com.google.cloud.secretmanager.v1.stub.SecretOperationsServiceStubSettings; +import java.time.Duration; + +public class SyncGetBackup { + + public static void main(String[] args) throws Exception { + syncGetBackup(); + } + + public static void syncGetBackup() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + SecretOperationsServiceStubSettings.Builder secretOperationsServiceSettingsBuilder = + SecretOperationsServiceStubSettings.newBuilder(); + secretOperationsServiceSettingsBuilder + .getBackupSettings() + .setRetrySettings( + secretOperationsServiceSettingsBuilder + .getBackupSettings() + .getRetrySettings() + .toBuilder() + .setInitialRetryDelayDuration(Duration.ofSeconds(1)) + .setInitialRpcTimeoutDuration(Duration.ofSeconds(5)) + .setMaxAttempts(5) + .setMaxRetryDelayDuration(Duration.ofSeconds(30)) + .setMaxRpcTimeoutDuration(Duration.ofSeconds(60)) + .setRetryDelayMultiplier(1.3) + .setRpcTimeoutMultiplier(1.5) + .setTotalTimeoutDuration(Duration.ofSeconds(300)) + .build()); + SecretOperationsServiceStubSettings secretOperationsServiceSettings = + secretOperationsServiceSettingsBuilder.build(); + } +} +// [END secretmanager_v1_generated_SecretOperationsServiceStubSettings_GetBackup_sync] diff --git a/java-securesourcemanager/README.md b/java-securesourcemanager/README.md index 07ff66cec8c0..29775cf2ce2a 100644 --- a/java-securesourcemanager/README.md +++ b/java-securesourcemanager/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-securesourcemanager - 0.72.0 + 0.73.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-securesourcemanager' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-securesourcemanager:0.72.0' +implementation 'com.google.cloud:google-cloud-securesourcemanager:0.73.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-securesourcemanager" % "0.72.0" +libraryDependencies += "com.google.cloud" % "google-cloud-securesourcemanager" % "0.73.0" ``` ## Authentication @@ -181,7 +181,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-securesourcemanager/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-securesourcemanager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-securesourcemanager/0.72.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-securesourcemanager/0.73.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-securesourcemanager/google-cloud-securesourcemanager/src/main/resources/META-INF/native-image/com.google.cloud.securesourcemanager.v1/reflect-config.json b/java-securesourcemanager/google-cloud-securesourcemanager/src/main/resources/META-INF/native-image/com.google.cloud.securesourcemanager.v1/reflect-config.json index f26d605443f8..db1f12dbca65 100644 --- a/java-securesourcemanager/google-cloud-securesourcemanager/src/main/resources/META-INF/native-image/com.google.cloud.securesourcemanager.v1/reflect-config.json +++ b/java-securesourcemanager/google-cloud-securesourcemanager/src/main/resources/META-INF/native-image/com.google.cloud.securesourcemanager.v1/reflect-config.json @@ -2087,6 +2087,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.securesourcemanager.v1.Repository$ScanConfig$VulnerabilityScanConfig", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.securesourcemanager.v1.Repository$ScanConfig$VulnerabilityScanConfig$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.securesourcemanager.v1.Repository$URIs", "queryAllDeclaredConstructors": true, diff --git a/java-securesourcemanager/google-cloud-securesourcemanager/src/test/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerClientHttpJsonTest.java b/java-securesourcemanager/google-cloud-securesourcemanager/src/test/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerClientHttpJsonTest.java index 946f1b18041b..d708c74d1daf 100644 --- a/java-securesourcemanager/google-cloud-securesourcemanager/src/test/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerClientHttpJsonTest.java +++ b/java-securesourcemanager/google-cloud-securesourcemanager/src/test/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerClientHttpJsonTest.java @@ -1158,6 +1158,7 @@ public void getHookTest() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); mockService.addResponse(expectedResponse); @@ -1210,6 +1211,7 @@ public void getHookTest2() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); mockService.addResponse(expectedResponse); @@ -1264,6 +1266,7 @@ public void createHookTest() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -1325,6 +1328,7 @@ public void createHookTest2() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -1386,6 +1390,7 @@ public void updateHookTest() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -1406,6 +1411,7 @@ public void updateHookTest() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); @@ -1446,6 +1452,7 @@ public void updateHookExceptionTest() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); FieldMask updateMask = FieldMask.newBuilder().build(); client.updateHookAsync(hook, updateMask).get(); diff --git a/java-securesourcemanager/google-cloud-securesourcemanager/src/test/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerClientTest.java b/java-securesourcemanager/google-cloud-securesourcemanager/src/test/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerClientTest.java index af958eb5c34a..b189ea95b889 100644 --- a/java-securesourcemanager/google-cloud-securesourcemanager/src/test/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerClientTest.java +++ b/java-securesourcemanager/google-cloud-securesourcemanager/src/test/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerClientTest.java @@ -1063,6 +1063,7 @@ public void getHookTest() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); mockSecureSourceManager.addResponse(expectedResponse); @@ -1109,6 +1110,7 @@ public void getHookTest2() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); mockSecureSourceManager.addResponse(expectedResponse); @@ -1155,6 +1157,7 @@ public void createHookTest() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -1215,6 +1218,7 @@ public void createHookTest2() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -1275,6 +1279,7 @@ public void updateHookTest() throws Exception { .setUid("uid115792") .setPushOption(Hook.PushOption.newBuilder().build()) .setSensitiveQueryString("sensitiveQueryString-690213245") + .setServiceAccountAuth(true) .build(); Operation resultOperation = Operation.newBuilder() diff --git a/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/Hook.java b/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/Hook.java index 497a4782d596..cb6171783a9b 100644 --- a/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/Hook.java +++ b/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/Hook.java @@ -1400,6 +1400,26 @@ public com.google.protobuf.ByteString getSensitiveQueryStringBytes() { } } + public static final int SERVICE_ACCOUNT_AUTH_FIELD_NUMBER = 11; + private boolean serviceAccountAuth_ = false; + + /** + * + * + *
    +   * Optional. Determines if the hook uses the Repository Service Account to
    +   * generate an OIDC ID Token for webhook authentication.
    +   * 
    + * + * bool service_account_auth = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The serviceAccountAuth. + */ + @java.lang.Override + public boolean getServiceAccountAuth() { + return serviceAccountAuth_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -1446,6 +1466,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sensitiveQueryString_)) { com.google.protobuf.GeneratedMessage.writeString(output, 10, sensitiveQueryString_); } + if (serviceAccountAuth_ != false) { + output.writeBool(11, serviceAccountAuth_); + } getUnknownFields().writeTo(output); } @@ -1491,6 +1514,9 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessage.isStringEmpty(sensitiveQueryString_)) { size += com.google.protobuf.GeneratedMessage.computeStringSize(10, sensitiveQueryString_); } + if (serviceAccountAuth_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(11, serviceAccountAuth_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1525,6 +1551,7 @@ public boolean equals(final java.lang.Object obj) { if (!getPushOption().equals(other.getPushOption())) return false; } if (!getSensitiveQueryString().equals(other.getSensitiveQueryString())) return false; + if (getServiceAccountAuth() != other.getServiceAccountAuth()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1562,6 +1589,8 @@ public int hashCode() { } hash = (37 * hash) + SENSITIVE_QUERY_STRING_FIELD_NUMBER; hash = (53 * hash) + getSensitiveQueryString().hashCode(); + hash = (37 * hash) + SERVICE_ACCOUNT_AUTH_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getServiceAccountAuth()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1734,6 +1763,7 @@ public Builder clear() { pushOptionBuilder_ = null; } sensitiveQueryString_ = ""; + serviceAccountAuth_ = false; return this; } @@ -1802,6 +1832,9 @@ private void buildPartial0(com.google.cloud.securesourcemanager.v1.Hook result) if (((from_bitField0_ & 0x00000100) != 0)) { result.sensitiveQueryString_ = sensitiveQueryString_; } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.serviceAccountAuth_ = serviceAccountAuth_; + } result.bitField0_ |= to_bitField0_; } @@ -1860,6 +1893,9 @@ public Builder mergeFrom(com.google.cloud.securesourcemanager.v1.Hook other) { bitField0_ |= 0x00000100; onChanged(); } + if (other.getServiceAccountAuth() != false) { + setServiceAccountAuth(other.getServiceAccountAuth()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1955,6 +1991,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000100; break; } // case 82 + case 88: + { + serviceAccountAuth_ = input.readBool(); + bitField0_ |= 0x00000200; + break; + } // case 88 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -3396,6 +3438,65 @@ public Builder setSensitiveQueryStringBytes(com.google.protobuf.ByteString value return this; } + private boolean serviceAccountAuth_; + + /** + * + * + *
    +     * Optional. Determines if the hook uses the Repository Service Account to
    +     * generate an OIDC ID Token for webhook authentication.
    +     * 
    + * + * bool service_account_auth = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The serviceAccountAuth. + */ + @java.lang.Override + public boolean getServiceAccountAuth() { + return serviceAccountAuth_; + } + + /** + * + * + *
    +     * Optional. Determines if the hook uses the Repository Service Account to
    +     * generate an OIDC ID Token for webhook authentication.
    +     * 
    + * + * bool service_account_auth = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The serviceAccountAuth to set. + * @return This builder for chaining. + */ + public Builder setServiceAccountAuth(boolean value) { + + serviceAccountAuth_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional. Determines if the hook uses the Repository Service Account to
    +     * generate an OIDC ID Token for webhook authentication.
    +     * 
    + * + * bool service_account_auth = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearServiceAccountAuth() { + bitField0_ = (bitField0_ & ~0x00000200); + serviceAccountAuth_ = false; + onChanged(); + return this; + } + // @@protoc_insertion_point(builder_scope:google.cloud.securesourcemanager.v1.Hook) } diff --git a/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/HookOrBuilder.java b/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/HookOrBuilder.java index eba56c03f874..c262ba64b57b 100644 --- a/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/HookOrBuilder.java +++ b/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/HookOrBuilder.java @@ -351,4 +351,18 @@ public interface HookOrBuilder * @return The bytes for sensitiveQueryString. */ com.google.protobuf.ByteString getSensitiveQueryStringBytes(); + + /** + * + * + *
    +   * Optional. Determines if the hook uses the Repository Service Account to
    +   * generate an OIDC ID Token for webhook authentication.
    +   * 
    + * + * bool service_account_auth = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The serviceAccountAuth. + */ + boolean getServiceAccountAuth(); } diff --git a/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/Repository.java b/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/Repository.java index bc1d0719a3cc..0427575cae2d 100644 --- a/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/Repository.java +++ b/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/Repository.java @@ -3936,6 +3936,51 @@ public interface ScanConfigOrBuilder */ com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfigOrBuilder getSecretScanConfigOrBuilder(); + + /** + * + * + *
    +     * Optional. Configuration for vulnerability scanning.
    +     * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the vulnerabilityScanConfig field is set. + */ + boolean hasVulnerabilityScanConfig(); + + /** + * + * + *
    +     * Optional. Configuration for vulnerability scanning.
    +     * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The vulnerabilityScanConfig. + */ + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + getVulnerabilityScanConfig(); + + /** + * + * + *
    +     * Optional. Configuration for vulnerability scanning.
    +     * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfigOrBuilder + getVulnerabilityScanConfigOrBuilder(); } /** @@ -4759,158 +4804,803 @@ public com.google.protobuf.Parser getParserForType() { } } - private int bitField0_; - public static final int SECRET_SCAN_CONFIG_FIELD_NUMBER = 1; - private com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig - secretScanConfig_; + public interface VulnerabilityScanConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig) + com.google.protobuf.MessageOrBuilder { - /** - * - * - *
    -     * Optional. Configuration for secret scanning.
    -     * 
    - * - * - * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig secret_scan_config = 1 [(.google.api.field_behavior) = OPTIONAL]; - * - * - * @return Whether the secretScanConfig field is set. - */ - @java.lang.Override - public boolean hasSecretScanConfig() { - return ((bitField0_ & 0x00000001) != 0); + /** + * + * + *
    +       * Optional. Enables vulnerability scanning for the repository.
    +       * 
    + * + * bool enabled = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The enabled. + */ + boolean getEnabled(); } /** * * *
    -     * Optional. Configuration for secret scanning.
    +     * Configuration for vulnerability scanning.
          * 
    * - * - * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig secret_scan_config = 1 [(.google.api.field_behavior) = OPTIONAL]; - * - * - * @return The secretScanConfig. + * Protobuf type {@code + * google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig} */ - @java.lang.Override - public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig - getSecretScanConfig() { - return secretScanConfig_ == null - ? com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig - .getDefaultInstance() - : secretScanConfig_; - } + public static final class VulnerabilityScanConfig extends com.google.protobuf.GeneratedMessage + implements + // @@protoc_insertion_point(message_implements:google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig) + VulnerabilityScanConfigOrBuilder { + private static final long serialVersionUID = 0L; - /** - * - * - *
    -     * Optional. Configuration for secret scanning.
    -     * 
    - * - * - * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig secret_scan_config = 1 [(.google.api.field_behavior) = OPTIONAL]; - * - */ - @java.lang.Override - public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfigOrBuilder - getSecretScanConfigOrBuilder() { - return secretScanConfig_ == null - ? com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig - .getDefaultInstance() - : secretScanConfig_; - } + static { + com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion( + com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC, + /* major= */ 4, + /* minor= */ 33, + /* patch= */ 6, + /* suffix= */ "", + "VulnerabilityScanConfig"); + } - private byte memoizedIsInitialized = -1; + // Use VulnerabilityScanConfig.newBuilder() to construct. + private VulnerabilityScanConfig(com.google.protobuf.GeneratedMessage.Builder builder) { + super(builder); + } - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; + private VulnerabilityScanConfig() {} - memoizedIsInitialized = 1; - return true; - } + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.securesourcemanager.v1.SecureSourceManagerProto + .internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_VulnerabilityScanConfig_descriptor; + } - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (((bitField0_ & 0x00000001) != 0)) { - output.writeMessage(1, getSecretScanConfig()); + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.securesourcemanager.v1.SecureSourceManagerProto + .internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_VulnerabilityScanConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig.class, + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig.Builder.class); } - getUnknownFields().writeTo(output); - } - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; + public static final int ENABLED_FIELD_NUMBER = 1; + private boolean enabled_ = false; - size = 0; - if (((bitField0_ & 0x00000001) != 0)) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getSecretScanConfig()); + /** + * + * + *
    +       * Optional. Enables vulnerability scanning for the repository.
    +       * 
    + * + * bool enabled = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The enabled. + */ + @java.lang.Override + public boolean getEnabled() { + return enabled_; } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; return true; } - if (!(obj instanceof com.google.cloud.securesourcemanager.v1.Repository.ScanConfig)) { - return super.equals(obj); - } - com.google.cloud.securesourcemanager.v1.Repository.ScanConfig other = - (com.google.cloud.securesourcemanager.v1.Repository.ScanConfig) obj; - if (hasSecretScanConfig() != other.hasSecretScanConfig()) return false; - if (hasSecretScanConfig()) { - if (!getSecretScanConfig().equals(other.getSecretScanConfig())) return false; + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (enabled_ != false) { + output.writeBool(1, enabled_); + } + getUnknownFields().writeTo(output); } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasSecretScanConfig()) { - hash = (37 * hash) + SECRET_SCAN_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getSecretScanConfig().hashCode(); + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (enabled_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, enabled_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig)) { + return super.equals(obj); + } + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + other = + (com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig) + obj; - public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } + if (getEnabled() != other.getEnabled()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } - public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ENABLED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getEnabled()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } - public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig parseFrom( + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessage.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
    +       * Configuration for vulnerability scanning.
    +       * 
    + * + * Protobuf type {@code + * google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessage.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig) + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.securesourcemanager.v1.SecureSourceManagerProto + .internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_VulnerabilityScanConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.securesourcemanager.v1.SecureSourceManagerProto + .internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_VulnerabilityScanConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig.class, + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig.Builder.class); + } + + // Construct using + // com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + enabled_ = false; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.securesourcemanager.v1.SecureSourceManagerProto + .internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_VulnerabilityScanConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + getDefaultInstanceForType() { + return com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + build() { + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + buildPartial() { + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + result = + new com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.enabled_ = enabled_; + } + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig) { + return mergeFrom( + (com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + other) { + if (other + == com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig.getDefaultInstance()) return this; + if (other.getEnabled() != false) { + setEnabled(other.getEnabled()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + enabled_ = input.readBool(); + bitField0_ |= 0x00000001; + break; + } // case 8 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private boolean enabled_; + + /** + * + * + *
    +         * Optional. Enables vulnerability scanning for the repository.
    +         * 
    + * + * bool enabled = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The enabled. + */ + @java.lang.Override + public boolean getEnabled() { + return enabled_; + } + + /** + * + * + *
    +         * Optional. Enables vulnerability scanning for the repository.
    +         * 
    + * + * bool enabled = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The enabled to set. + * @return This builder for chaining. + */ + public Builder setEnabled(boolean value) { + + enabled_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
    +         * Optional. Enables vulnerability scanning for the repository.
    +         * 
    + * + * bool enabled = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearEnabled() { + bitField0_ = (bitField0_ & ~0x00000001); + enabled_ = false; + onChanged(); + return this; + } + + // @@protoc_insertion_point(builder_scope:google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig) + private static final com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig(); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public VulnerabilityScanConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int SECRET_SCAN_CONFIG_FIELD_NUMBER = 1; + private com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig + secretScanConfig_; + + /** + * + * + *
    +     * Optional. Configuration for secret scanning.
    +     * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig secret_scan_config = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the secretScanConfig field is set. + */ + @java.lang.Override + public boolean hasSecretScanConfig() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +     * Optional. Configuration for secret scanning.
    +     * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig secret_scan_config = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The secretScanConfig. + */ + @java.lang.Override + public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig + getSecretScanConfig() { + return secretScanConfig_ == null + ? com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig + .getDefaultInstance() + : secretScanConfig_; + } + + /** + * + * + *
    +     * Optional. Configuration for secret scanning.
    +     * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig secret_scan_config = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfigOrBuilder + getSecretScanConfigOrBuilder() { + return secretScanConfig_ == null + ? com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.SecretScanConfig + .getDefaultInstance() + : secretScanConfig_; + } + + public static final int VULNERABILITY_SCAN_CONFIG_FIELD_NUMBER = 2; + private com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + vulnerabilityScanConfig_; + + /** + * + * + *
    +     * Optional. Configuration for vulnerability scanning.
    +     * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the vulnerabilityScanConfig field is set. + */ + @java.lang.Override + public boolean hasVulnerabilityScanConfig() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
    +     * Optional. Configuration for vulnerability scanning.
    +     * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The vulnerabilityScanConfig. + */ + @java.lang.Override + public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + getVulnerabilityScanConfig() { + return vulnerabilityScanConfig_ == null + ? com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + .getDefaultInstance() + : vulnerabilityScanConfig_; + } + + /** + * + * + *
    +     * Optional. Configuration for vulnerability scanning.
    +     * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfigOrBuilder + getVulnerabilityScanConfigOrBuilder() { + return vulnerabilityScanConfig_ == null + ? com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + .getDefaultInstance() + : vulnerabilityScanConfig_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(1, getSecretScanConfig()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getVulnerabilityScanConfig()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getSecretScanConfig()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, getVulnerabilityScanConfig()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.securesourcemanager.v1.Repository.ScanConfig)) { + return super.equals(obj); + } + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig other = + (com.google.cloud.securesourcemanager.v1.Repository.ScanConfig) obj; + + if (hasSecretScanConfig() != other.hasSecretScanConfig()) return false; + if (hasSecretScanConfig()) { + if (!getSecretScanConfig().equals(other.getSecretScanConfig())) return false; + } + if (hasVulnerabilityScanConfig() != other.hasVulnerabilityScanConfig()) return false; + if (hasVulnerabilityScanConfig()) { + if (!getVulnerabilityScanConfig().equals(other.getVulnerabilityScanConfig())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasSecretScanConfig()) { + hash = (37 * hash) + SECRET_SCAN_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getSecretScanConfig().hashCode(); + } + if (hasVulnerabilityScanConfig()) { + hash = (37 * hash) + VULNERABILITY_SCAN_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getVulnerabilityScanConfig().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.securesourcemanager.v1.Repository.ScanConfig parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { @@ -5031,6 +5721,7 @@ private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { internalGetSecretScanConfigFieldBuilder(); + internalGetVulnerabilityScanConfigFieldBuilder(); } } @@ -5043,6 +5734,11 @@ public Builder clear() { secretScanConfigBuilder_.dispose(); secretScanConfigBuilder_ = null; } + vulnerabilityScanConfig_ = null; + if (vulnerabilityScanConfigBuilder_ != null) { + vulnerabilityScanConfigBuilder_.dispose(); + vulnerabilityScanConfigBuilder_ = null; + } return this; } @@ -5089,6 +5785,13 @@ private void buildPartial0( : secretScanConfigBuilder_.build(); to_bitField0_ |= 0x00000001; } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.vulnerabilityScanConfig_ = + vulnerabilityScanConfigBuilder_ == null + ? vulnerabilityScanConfig_ + : vulnerabilityScanConfigBuilder_.build(); + to_bitField0_ |= 0x00000002; + } result.bitField0_ |= to_bitField0_; } @@ -5110,6 +5813,9 @@ public Builder mergeFrom( if (other.hasSecretScanConfig()) { mergeSecretScanConfig(other.getSecretScanConfig()); } + if (other.hasVulnerabilityScanConfig()) { + mergeVulnerabilityScanConfig(other.getVulnerabilityScanConfig()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -5143,6 +5849,14 @@ public Builder mergeFrom( bitField0_ |= 0x00000001; break; } // case 10 + case 18: + { + input.readMessage( + internalGetVulnerabilityScanConfigFieldBuilder().getBuilder(), + extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -5392,6 +6106,242 @@ public Builder clearSecretScanConfig() { return secretScanConfigBuilder_; } + private com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + vulnerabilityScanConfig_; + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig, + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + .Builder, + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfigOrBuilder> + vulnerabilityScanConfigBuilder_; + + /** + * + * + *
    +       * Optional. Configuration for vulnerability scanning.
    +       * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the vulnerabilityScanConfig field is set. + */ + public boolean hasVulnerabilityScanConfig() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
    +       * Optional. Configuration for vulnerability scanning.
    +       * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The vulnerabilityScanConfig. + */ + public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + getVulnerabilityScanConfig() { + if (vulnerabilityScanConfigBuilder_ == null) { + return vulnerabilityScanConfig_ == null + ? com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig.getDefaultInstance() + : vulnerabilityScanConfig_; + } else { + return vulnerabilityScanConfigBuilder_.getMessage(); + } + } + + /** + * + * + *
    +       * Optional. Configuration for vulnerability scanning.
    +       * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setVulnerabilityScanConfig( + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + value) { + if (vulnerabilityScanConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + vulnerabilityScanConfig_ = value; + } else { + vulnerabilityScanConfigBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +       * Optional. Configuration for vulnerability scanning.
    +       * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setVulnerabilityScanConfig( + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + .Builder + builderForValue) { + if (vulnerabilityScanConfigBuilder_ == null) { + vulnerabilityScanConfig_ = builderForValue.build(); + } else { + vulnerabilityScanConfigBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
    +       * Optional. Configuration for vulnerability scanning.
    +       * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeVulnerabilityScanConfig( + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + value) { + if (vulnerabilityScanConfigBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && vulnerabilityScanConfig_ != null + && vulnerabilityScanConfig_ + != com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig.getDefaultInstance()) { + getVulnerabilityScanConfigBuilder().mergeFrom(value); + } else { + vulnerabilityScanConfig_ = value; + } + } else { + vulnerabilityScanConfigBuilder_.mergeFrom(value); + } + if (vulnerabilityScanConfig_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
    +       * Optional. Configuration for vulnerability scanning.
    +       * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearVulnerabilityScanConfig() { + bitField0_ = (bitField0_ & ~0x00000002); + vulnerabilityScanConfig_ = null; + if (vulnerabilityScanConfigBuilder_ != null) { + vulnerabilityScanConfigBuilder_.dispose(); + vulnerabilityScanConfigBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +       * Optional. Configuration for vulnerability scanning.
    +       * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + .Builder + getVulnerabilityScanConfigBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return internalGetVulnerabilityScanConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +       * Optional. Configuration for vulnerability scanning.
    +       * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfigOrBuilder + getVulnerabilityScanConfigOrBuilder() { + if (vulnerabilityScanConfigBuilder_ != null) { + return vulnerabilityScanConfigBuilder_.getMessageOrBuilder(); + } else { + return vulnerabilityScanConfig_ == null + ? com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig.getDefaultInstance() + : vulnerabilityScanConfig_; + } + } + + /** + * + * + *
    +       * Optional. Configuration for vulnerability scanning.
    +       * 
    + * + * + * .google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig vulnerability_scan_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig, + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig.VulnerabilityScanConfig + .Builder, + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfigOrBuilder> + internalGetVulnerabilityScanConfigFieldBuilder() { + if (vulnerabilityScanConfigBuilder_ == null) { + vulnerabilityScanConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig, + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfig.Builder, + com.google.cloud.securesourcemanager.v1.Repository.ScanConfig + .VulnerabilityScanConfigOrBuilder>( + getVulnerabilityScanConfig(), getParentForChildren(), isClean()); + vulnerabilityScanConfig_ = null; + } + return vulnerabilityScanConfigBuilder_; + } + // @@protoc_insertion_point(builder_scope:google.cloud.securesourcemanager.v1.Repository.ScanConfig) } diff --git a/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerProto.java b/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerProto.java index bb964e53843a..b0c9a00f804f 100644 --- a/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerProto.java +++ b/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/java/com/google/cloud/securesourcemanager/v1/SecureSourceManagerProto.java @@ -84,6 +84,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_SecretScanConfig_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_SecretScanConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_VulnerabilityScanConfig_descriptor; + static final com.google.protobuf.GeneratedMessage.FieldAccessorTable + internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_VulnerabilityScanConfig_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_securesourcemanager_v1_Hook_descriptor; static final com.google.protobuf.GeneratedMessage.FieldAccessorTable @@ -495,7 +499,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\027PAUSED_CMEK_UNAVAILABLE\020\001\022\031\n" + "\021INSTANCE_RESUMING\020\002\032\002\010\001:q\352An\n" + "+securesourcemanager.googleapis.com/Instance\022.google.cloud.securesourcemanager.v1.PullRequestComment.ReviewB\004\342A\001\001H\000\022X\n" - + "\007comment\030\005 \001(\0132?.google.cloud.securesourceman" - + "ager.v1.PullRequestComment.CommentB\004\342A\001\001H\000\022R\n" - + "\004code\030\006 \001(\0132<.google.cloud.secureso" - + "urcemanager.v1.PullRequestComment.CodeB\004\342A\001\001H\000\032\202\002\n" + + "\006review\030\004 \001(\0132>.google.cloud.securesourcem" + + "anager.v1.PullRequestComment.ReviewB\004\342A\001\001H\000\022X\n" + + "\007comment\030\005 \001(\0132?.google.cloud.secu" + + "resourcemanager.v1.PullRequestComment.CommentB\004\342A\001\001H\000\022R\n" + + "\004code\030\006 \001(\0132<.google.clo" + + "ud.securesourcemanager.v1.PullRequestComment.CodeB\004\342A\001\001H\000\032\202\002\n" + "\006Review\022d\n" - + "\013action_type\030\001 \001(\0162I.google.cloud.securesourcemanager.v1.Pul" - + "lRequestComment.Review.ActionTypeB\004\342A\001\002\022\022\n" + + "\013action_type\030\001 \001(\0162I.google.cloud.securesourceman" + + "ager.v1.PullRequestComment.Review.ActionTypeB\004\342A\001\002\022\022\n" + "\004body\030\002 \001(\tB\004\342A\001\001\022\"\n" + "\024effective_commit_sha\030\004 \001(\tB\004\342A\001\003\"Z\n\n" + "ActionType\022\033\n" @@ -682,30 +692,30 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004Code\022\022\n" + "\004body\030\001 \001(\tB\004\342A\001\002\022\024\n" + "\005reply\030\002 \001(\tB\005\342A\002\001\004\022X\n" - + "\010position\030\003 \001(\0132@.google.cloud.securesourcemanag" - + "er.v1.PullRequestComment.PositionB\004\342A\001\001\022$\n" + + "\010position\030\003 \001(\0132@.google.cloud.secure" + + "sourcemanager.v1.PullRequestComment.PositionB\004\342A\001\001\022$\n" + "\026effective_root_comment\030\004 \001(\tB\004\342A\001\003\022\026\n" + "\010resolved\030\005 \001(\010B\004\342A\001\003\022\"\n" + "\024effective_commit_sha\030\007 \001(\tB\004\342A\001\003\0322\n" + "\010Position\022\022\n" + "\004path\030\001 \001(\tB\004\342A\001\002\022\022\n" + "\004line\030\002 \001(\003B\004\342A\001\002:\270\001\352A\264\001\n" - + "5securesourcemanager.googleapis.com/PullRequestComment\022{projects/{project}/location" - + "s/{location}/repositories/{repository}/p" - + "ullRequests/{pull_request}/pullRequestComments/{comment}B\020\n" + + "5securesourcemanager.googleapis.com/PullRequestComment\022{projects/{projec" + + "t}/locations/{location}/repositories/{re" + + "pository}/pullRequests/{pull_request}/pullRequestComments/{comment}B\020\n" + "\016comment_detail\"\301\001\n" + "\003Ref\022\022\n" + "\004name\030\001 \001(\tB\004\342A\001\010\022\024\n" + "\006target\030\002 \001(\tB\004\342A\001\003\022D\n" - + "\004type\030\003" - + " \001(\01620.google.cloud.securesourcemanager.v1.Ref.RefTypeB\004\342A\001\003\"J\n" + + "\004type\030\003 \001(\01620.google.c" + + "loud.securesourcemanager.v1.Ref.RefTypeB\004\342A\001\003\"J\n" + "\007RefType\022\030\n" + "\024REF_TYPE_UNSPECIFIED\020\000\022\023\n" + "\017REF_TYPE_BRANCH\020\001\022\020\n" + "\014REF_TYPE_TAG\020\002\"\275\001\n" + "\024ListInstancesRequest\022D\n" - + "\006parent\030\001 \001(\tB4\342A\001\002\372A-" - + "\022+securesourcemanager.googleapis.com/Instance\022\027\n" + + "\006parent\030\001 \001(" + + "\tB4\342A\001\002\372A-\022+securesourcemanager.googleapis.com/Instance\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\022\026\n" @@ -721,8 +731,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006parent\030\001 \001(" + "\tB4\342A\001\002\372A-\022+securesourcemanager.googleapis.com/Instance\022\031\n" + "\013instance_id\030\002 \001(\tB\004\342A\001\002\022E\n" - + "\010instance\030\003 \001(\0132-.google" - + ".cloud.securesourcemanager.v1.InstanceB\004\342A\001\002\022 \n\n" + + "\010instance\030\003 \001" + + "(\0132-.google.cloud.securesourcemanager.v1.InstanceB\004\342A\001\002\022 \n\n" + "request_id\030\004 \001(" + "\tB\014\342A\001\001\342\214\317\327\010\002\010\001\"\222\001\n" + "\025DeleteInstanceRequest\022B\n" @@ -741,39 +751,39 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\026requested_cancellation\030\006 \001(\010B\004\342A\001\003\022\031\n" + "\013api_version\030\007 \001(\tB\004\342A\001\003\"\362\001\n" + "\027ListRepositoriesRequest\022F\n" - + "\006parent\030\001 \001(" - + "\tB6\342A\001\002\372A/\022-securesourcemanager.googleapis.com/Repository\022\027\n" + + "\006parent\030\001 \001(\tB6\342A\001\002\372A/\022-s" + + "ecuresourcemanager.googleapis.com/Repository\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\022F\n" + "\010instance\030\005 \001(\tB4\342A\001\001\372A-\n" + "+securesourcemanager.googleapis.com/Instance\"z\n" + "\030ListRepositoriesResponse\022E\n" - + "\014repositories\030\001" - + " \003(\0132/.google.cloud.securesourcemanager.v1.Repository\022\027\n" + + "\014repositories\030\001 \003(\0132" + + "/.google.cloud.securesourcemanager.v1.Repository\022\027\n" + "\017next_page_token\030\002 \001(\t\"\\\n" + "\024GetRepositoryRequest\022D\n" + "\004name\030\001 \001(\tB6\342A\001\002\372A/\n" + "-securesourcemanager.googleapis.com/Repository\"\311\001\n" + "\027CreateRepositoryRequest\022F\n" - + "\006parent\030\001 \001(\t" - + "B6\342A\001\002\372A/\022-securesourcemanager.googleapis.com/Repository\022I\n\n" - + "repository\030\002 \001(\0132/.g" - + "oogle.cloud.securesourcemanager.v1.RepositoryB\004\342A\001\002\022\033\n\r" + + "\006parent\030\001 \001(" + + "\tB6\342A\001\002\372A/\022-securesourcemanager.googleapis.com/Repository\022I\n\n" + + "repository\030\002" + + " \001(\0132/.google.cloud.securesourcemanager.v1.RepositoryB\004\342A\001\002\022\033\n\r" + "repository_id\030\003 \001(\tB\004\342A\001\002\"\270\001\n" + "\027UpdateRepositoryRequest\0225\n" + "\013update_mask\030\001" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022I\n\n" - + "repository\030\002 \001(\0132/.google.cloud.s" - + "ecuresourcemanager.v1.RepositoryB\004\342A\001\002\022\033\n\r" + + "repository\030\002 \001(\0132/.goo" + + "gle.cloud.securesourcemanager.v1.RepositoryB\004\342A\001\002\022\033\n\r" + "validate_only\030\003 \001(\010B\004\342A\001\001\"|\n" + "\027DeleteRepositoryRequest\022D\n" + "\004name\030\001 \001(\tB6\342A\001\002\372A/\n" + "-securesourcemanager.googleapis.com/Repository\022\033\n\r" + "allow_missing\030\002 \001(\010B\004\342A\001\001\"\207\001\n" + "\020ListHooksRequest\022@\n" - + "\006parent\030\001 \001(\tB0\342A\001\002\372A)\022" - + "\'securesourcemanager.googleapis.com/Hook\022\027\n" + + "\006parent\030\001 \001(" + + "\tB0\342A\001\002\372A)\022\'securesourcemanager.googleapis.com/Hook\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"f\n" + "\021ListHooksResponse\0228\n" @@ -785,14 +795,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\021CreateHookRequest\022F\n" + "\006parent\030\001 \001(\tB6\342A\001\002\372A/\n" + "-securesourcemanager.googleapis.com/Repository\022=\n" - + "\004hook\030\002" - + " \001(\0132).google.cloud.securesourcemanager.v1.HookB\004\342A\001\002\022\025\n" + + "\004hook\030\002 \001(\0132).g" + + "oogle.cloud.securesourcemanager.v1.HookB\004\342A\001\002\022\025\n" + "\007hook_id\030\003 \001(\tB\004\342A\001\002\"\211\001\n" + "\021UpdateHookRequest\0225\n" + "\013update_mask\030\001" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\022=\n" - + "\004hook\030\002" - + " \001(\0132).google.cloud.securesourcemanager.v1.HookB\004\342A\001\002\"S\n" + + "\004hook\030\002 \001(\0132" + + ").google.cloud.securesourcemanager.v1.HookB\004\342A\001\002\"S\n" + "\021DeleteHookRequest\022>\n" + "\004name\030\001 \001(\tB0\342A\001\002\372A)\n" + "\'securesourcemanager.googleapis.com/Hook\"\\\n" @@ -800,23 +810,24 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004name\030\001 \001(\tB6\342A\001\002\372A/\n" + "-securesourcemanager.googleapis.com/BranchRule\"\313\001\n" + "\027CreateBranchRuleRequest\022F\n" - + "\006parent\030\001 \001(" - + "\tB6\342A\001\002\372A/\022-securesourcemanager.googleapis.com/BranchRule\022J\n" - + "\013branch_rule\030\002" - + " \001(\0132/.google.cloud.securesourcemanager.v1.BranchRuleB\004\342A\001\002\022\034\n" + + "\006parent\030\001 \001(\tB6\342A\001\002\372A/" + + "\022-securesourcemanager.googleapis.com/BranchRule\022J\n" + + "\013branch_rule\030\002 \001(\0132/.google.cl" + + "oud.securesourcemanager.v1.BranchRuleB\004\342A\001\002\022\034\n" + "\016branch_rule_id\030\003 \001(\tB\004\342A\001\002\"\223\001\n" + "\026ListBranchRulesRequest\022F\n" - + "\006parent\030\001 \001(\tB6\342A\001\002\372A/\022-secu" - + "resourcemanager.googleapis.com/BranchRule\022\027\n" - + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + + "\006parent\030\001 \001(\tB6\342A" + + "\001\002\372A/\022-securesourcemanager.googleapis.com/BranchRule\022\027\n" + + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n" + + "\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"|\n" + "\027DeleteBranchRuleRequest\022D\n" + "\004name\030\001 \001(\tB6\342A\001\002\372A/\n" + "-securesourcemanager.googleapis.com/BranchRule\022\033\n\r" + "allow_missing\030\002 \001(\010B\004\342A\001\001\"\271\001\n" + "\027UpdateBranchRuleRequest\022J\n" - + "\013branch_rule\030\001 \001(\0132/.google.clo" - + "ud.securesourcemanager.v1.BranchRuleB\004\342A\001\002\022\033\n\r" + + "\013branch_rule\030\001 \001(\0132/" + + ".google.cloud.securesourcemanager.v1.BranchRuleB\004\342A\001\002\022\033\n\r" + "validate_only\030\002 \001(\010B\004\342A\001\001\0225\n" + "\013update_mask\030\003" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\"y\n" @@ -827,8 +838,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\030CreatePullRequestRequest\022F\n" + "\006parent\030\001 \001(\tB6\342A\001\002\372A/\n" + "-securesourcemanager.googleapis.com/Repository\022L\n" - + "\014pull_request\030\002" - + " \001(\01320.google.cloud.securesourcemanager.v1.PullRequestB\004\342A\001\002\"^\n" + + "\014pull_request\030\002 \001(\01320.google.cloud.s" + + "ecuresourcemanager.v1.PullRequestB\004\342A\001\002\"^\n" + "\025GetPullRequestRequest\022E\n" + "\004name\030\001 \001(\tB7\342A\001\002\372A0\n" + ".securesourcemanager.googleapis.com/PullRequest\"\224\001\n" @@ -842,8 +853,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \003(\01320.google.cloud.securesourcemanager.v1.PullRequest\022\027\n" + "\017next_page_token\030\002 \001(\t\"\237\001\n" + "\030UpdatePullRequestRequest\022L\n" - + "\014pull_request\030\001" - + " \001(\01320.google.cloud.securesourcemanager.v1.PullRequestB\004\342A\001\002\0225\n" + + "\014pull_request\030\001 \001(\01320.google.cloud.s" + + "ecuresourcemanager.v1.PullRequestB\004\342A\001\002\0225\n" + "\013update_mask\030\002" + " \001(\0132\032.google.protobuf.FieldMaskB\004\342A\001\001\"`\n" + "\027MergePullRequestRequest\022E\n" @@ -872,8 +883,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004name\030\001 \001(\tB1\342A\001\002\372A*\n" + "(securesourcemanager.googleapis.com/Issue\"\237\001\n" + "\021ListIssuesRequest\022A\n" - + "\006parent\030\001 \001(" - + "\tB1\342A\001\002\372A*\022(securesourcemanager.googleapis.com/Issue\022\027\n" + + "\006parent\030\001 \001(\tB1\342A\001" + + "\002\372A*\022(securesourcemanager.googleapis.com/Issue\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\022\024\n" + "\006filter\030\004 \001(\tB\004\342A\001\001\"i\n" @@ -898,8 +909,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "(securesourcemanager.googleapis.com/Issue\022\022\n" + "\004etag\030\002 \001(\tB\004\342A\001\001\"\364\001\n" + "\tTreeEntry\022M\n" - + "\004type\030\001 \001(\01629.google.cloud." - + "securesourcemanager.v1.TreeEntry.ObjectTypeB\004\342A\001\003\022\021\n" + + "\004type\030\001 \001(\01629.go" + + "ogle.cloud.securesourcemanager.v1.TreeEntry.ObjectTypeB\004\342A\001\003\022\021\n" + "\003sha\030\002 \001(\tB\004\342A\001\003\022\022\n" + "\004path\030\003 \001(\tB\004\342A\001\003\022\022\n" + "\004mode\030\004 \001(\tB\004\342A\001\003\022\022\n" @@ -917,8 +928,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tpage_size\030\004 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\005 \001(\tB\004\342A\001\001\"r\n" + "\021FetchTreeResponse\022D\n" - + "\014tree_entries\030\001 \003(\0132." - + ".google.cloud.securesourcemanager.v1.TreeEntry\022\027\n" + + "\014tree_entries\030\001" + + " \003(\0132..google.cloud.securesourcemanager.v1.TreeEntry\022\027\n" + "\017next_page_token\030\002 \001(\t\"q\n" + "\020FetchBlobRequest\022J\n\n" + "repository\030\001 \001(\tB6\342A\001\002\372A/\n" @@ -930,435 +941,435 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\020FetchRefsRequest\022J\n\n" + "repository\030\001 \001(\tB6\342A\001\002\372A/\n" + "-securesourcemanager.googleapis.com/Repository\022D\n" - + "\004type\030\002 \001(\01620.google.cl" - + "oud.securesourcemanager.v1.Ref.RefTypeB\004\342A\001\001\022\027\n" + + "\004type\030\002 \001(\0162" + + "0.google.cloud.securesourcemanager.v1.Ref.RefTypeB\004\342A\001\001\022\027\n" + "\tpage_size\030\003 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\004 \001(\tB\004\342A\001\001\"d\n" + "\021FetchRefsResponse\0226\n" + "\004refs\030\001 \003(\0132(.google.cloud.securesourcemanager.v1.Ref\022\027\n" + "\017next_page_token\030\002 \001(\t\"\243\001\n" + "\036ListPullRequestCommentsRequest\022N\n" - + "\006parent\030\001 \001(" - + "\tB>\342A\001\002\372A7\0225securesourcemanager.googleapis.com/PullRequestComment\022\027\n" + + "\006parent\030\001 \001(\tB>\342A\001\002\372A7\0225securesour" + + "cemanager.googleapis.com/PullRequestComment\022\027\n" + "\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\n" + "page_token\030\003 \001(\tB\004\342A\001\001\"\222\001\n" + "\037ListPullRequestCommentsResponse\022V\n" - + "\025pull_request_comments\030\001 \003(\01327.google." - + "cloud.securesourcemanager.v1.PullRequestComment\022\027\n" + + "\025pull_request_comments\030\001 \003(" + + "\01327.google.cloud.securesourcemanager.v1.PullRequestComment\022\027\n" + "\017next_page_token\030\002 \001(\t\"\316\001\n" + "\037CreatePullRequestCommentRequest\022N\n" - + "\006parent\030\001 \001(" - + "\tB>\342A\001\002\372A7\0225securesourcemanager.googleapis.com/PullRequestComment\022[\n" - + "\024pull_request_comment\030\002 \001(\01327.google.cloud.secure" - + "sourcemanager.v1.PullRequestCommentB\004\342A\001\002\"\325\001\n" + + "\006parent\030\001 \001(\tB>\342A\001\002\372A7\0225securesourcema" + + "nager.googleapis.com/PullRequestComment\022[\n" + + "\024pull_request_comment\030\002 \001(\01327.google.c" + + "loud.securesourcemanager.v1.PullRequestCommentB\004\342A\001\002\"\325\001\n" + "%BatchCreatePullRequestCommentsRequest\022N\n" - + "\006parent\030\001 \001(\tB>\342A\001\002\372A7\0225securesour" - + "cemanager.googleapis.com/PullRequestComment\022\\\n" - + "\010requests\030\002 \003(\0132D.google.cloud.sec" - + "uresourcemanager.v1.CreatePullRequestCommentRequestB\004\342A\001\002\"\200\001\n" - + "&BatchCreatePullRequestCommentsResponse\022V\n" - + "\025pull_request_com", - "ments\030\001 \003(\01327.google.cloud.securesourcem" - + "anager.v1.PullRequestComment\"\265\001\n\037UpdateP" - + "ullRequestCommentRequest\022[\n\024pull_request" - + "_comment\030\001 \001(\01327.google.cloud.securesour" - + "cemanager.v1.PullRequestCommentB\004\342A\001\002\0225\n" - + "\013update_mask\030\002 \001(\0132\032.google.protobuf.Fie" - + "ldMaskB\004\342A\001\001\"o\n\037DeletePullRequestComment" - + "Request\022L\n\004name\030\001 \001(\tB>\342A\001\002\372A7\n5secureso" - + "urcemanager.googleapis.com/PullRequestCo" - + "mment\"l\n\034GetPullRequestCommentRequest\022L\n" - + "\004name\030\001 \001(\tB>\342A\001\002\372A7\n5securesourcemanage" - + "r.googleapis.com/PullRequestComment\"\333\001\n!" - + "ResolvePullRequestCommentsRequest\022N\n\006par" - + "ent\030\001 \001(\tB>\342A\001\002\372A7\0225securesourcemanager." - + "googleapis.com/PullRequestComment\022M\n\005nam" - + "es\030\002 \003(\tB>\342A\001\002\372A7\n5securesourcemanager.g" - + "oogleapis.com/PullRequestComment\022\027\n\tauto" - + "_fill\030\003 \001(\010B\004\342A\001\001\"|\n\"ResolvePullRequestC" - + "ommentsResponse\022V\n\025pull_request_comments" - + "\030\001 \003(\01327.google.cloud.securesourcemanage" - + "r.v1.PullRequestComment\"\335\001\n#UnresolvePul" - + "lRequestCommentsRequest\022N\n\006parent\030\001 \001(\tB" - + ">\342A\001\002\372A7\0225securesourcemanager.googleapis" - + ".com/PullRequestComment\022M\n\005names\030\002 \003(\tB>" - + "\342A\001\002\372A7\n5securesourcemanager.googleapis." - + "com/PullRequestComment\022\027\n\tauto_fill\030\003 \001(" - + "\010B\004\342A\001\001\"~\n$UnresolvePullRequestCommentsR" - + "esponse\022V\n\025pull_request_comments\030\001 \003(\01327" - + ".google.cloud.securesourcemanager.v1.Pul" - + "lRequestComment\"\256\001\n\031CreateIssueCommentRe" - + "quest\022A\n\006parent\030\001 \001(\tB1\342A\001\002\372A*\n(secureso" - + "urcemanager.googleapis.com/Issue\022N\n\rissu" - + "e_comment\030\002 \001(\01321.google.cloud.securesou" - + "rcemanager.v1.IssueCommentB\004\342A\001\002\"`\n\026GetI" + + "\006parent\030\001 \001(\tB>\342A\001\002\372A7\022", + "5securesourcemanager.googleapis.com/Pull" + + "RequestComment\022\\\n\010requests\030\002 \003(\0132D.googl" + + "e.cloud.securesourcemanager.v1.CreatePul" + + "lRequestCommentRequestB\004\342A\001\002\"\200\001\n&BatchCr" + + "eatePullRequestCommentsResponse\022V\n\025pull_" + + "request_comments\030\001 \003(\01327.google.cloud.se" + + "curesourcemanager.v1.PullRequestComment\"" + + "\265\001\n\037UpdatePullRequestCommentRequest\022[\n\024p" + + "ull_request_comment\030\001 \001(\01327.google.cloud" + + ".securesourcemanager.v1.PullRequestComme" + + "ntB\004\342A\001\002\0225\n\013update_mask\030\002 \001(\0132\032.google.p" + + "rotobuf.FieldMaskB\004\342A\001\001\"o\n\037DeletePullReq" + + "uestCommentRequest\022L\n\004name\030\001 \001(\tB>\342A\001\002\372A" + + "7\n5securesourcemanager.googleapis.com/Pu" + + "llRequestComment\"l\n\034GetPullRequestCommen" + + "tRequest\022L\n\004name\030\001 \001(\tB>\342A\001\002\372A7\n5secures" + + "ourcemanager.googleapis.com/PullRequestC" + + "omment\"\333\001\n!ResolvePullRequestCommentsReq" + + "uest\022N\n\006parent\030\001 \001(\tB>\342A\001\002\372A7\0225securesou" + + "rcemanager.googleapis.com/PullRequestCom" + + "ment\022M\n\005names\030\002 \003(\tB>\342A\001\002\372A7\n5securesour" + + "cemanager.googleapis.com/PullRequestComm" + + "ent\022\027\n\tauto_fill\030\003 \001(\010B\004\342A\001\001\"|\n\"ResolveP" + + "ullRequestCommentsResponse\022V\n\025pull_reque" + + "st_comments\030\001 \003(\01327.google.cloud.secures" + + "ourcemanager.v1.PullRequestComment\"\335\001\n#U" + + "nresolvePullRequestCommentsRequest\022N\n\006pa" + + "rent\030\001 \001(\tB>\342A\001\002\372A7\0225securesourcemanager" + + ".googleapis.com/PullRequestComment\022M\n\005na" + + "mes\030\002 \003(\tB>\342A\001\002\372A7\n5securesourcemanager." + + "googleapis.com/PullRequestComment\022\027\n\taut" + + "o_fill\030\003 \001(\010B\004\342A\001\001\"~\n$UnresolvePullReque" + + "stCommentsResponse\022V\n\025pull_request_comme" + + "nts\030\001 \003(\01327.google.cloud.securesourceman" + + "ager.v1.PullRequestComment\"\256\001\n\031CreateIss" + + "ueCommentRequest\022A\n\006parent\030\001 \001(\tB1\342A\001\002\372A" + + "*\n(securesourcemanager.googleapis.com/Is" + + "sue\022N\n\rissue_comment\030\002 \001(\01321.google.clou" + + "d.securesourcemanager.v1.IssueCommentB\004\342" + + "A\001\002\"`\n\026GetIssueCommentRequest\022F\n\004name\030\001 " + + "\001(\tB8\342A\001\002\372A1\n/securesourcemanager.google" + + "apis.com/IssueComment\"\227\001\n\030ListIssueComme" + + "ntsRequest\022H\n\006parent\030\001 \001(\tB8\342A\001\002\372A1\022/sec" + + "uresourcemanager.googleapis.com/IssueCom" + + "ment\022\027\n\tpage_size\030\002 \001(\005B\004\342A\001\001\022\030\n\npage_to" + + "ken\030\003 \001(\tB\004\342A\001\001\"\177\n\031ListIssueCommentsResp" + + "onse\022I\n\016issue_comments\030\001 \003(\01321.google.cl" + + "oud.securesourcemanager.v1.IssueComment\022" + + "\027\n\017next_page_token\030\002 \001(\t\"\242\001\n\031UpdateIssue" + + "CommentRequest\022N\n\rissue_comment\030\001 \001(\01321." + + "google.cloud.securesourcemanager.v1.Issu" + + "eCommentB\004\342A\001\002\0225\n\013update_mask\030\002 \001(\0132\032.go" + + "ogle.protobuf.FieldMaskB\004\342A\001\001\"c\n\031DeleteI" + "ssueCommentRequest\022F\n\004name\030\001 \001(\tB8\342A\001\002\372A" + "1\n/securesourcemanager.googleapis.com/Is" - + "sueComment\"\227\001\n\030ListIssueCommentsRequest\022" - + "H\n\006parent\030\001 \001(\tB8\342A\001\002\372A1\022/securesourcema" - + "nager.googleapis.com/IssueComment\022\027\n\tpag" - + "e_size\030\002 \001(\005B\004\342A\001\001\022\030\n\npage_token\030\003 \001(\tB\004" - + "\342A\001\001\"\177\n\031ListIssueCommentsResponse\022I\n\016iss" - + "ue_comments\030\001 \003(\01321.google.cloud.secures" - + "ourcemanager.v1.IssueComment\022\027\n\017next_pag" - + "e_token\030\002 \001(\t\"\242\001\n\031UpdateIssueCommentRequ" - + "est\022N\n\rissue_comment\030\001 \001(\01321.google.clou" - + "d.securesourcemanager.v1.IssueCommentB\004\342" - + "A\001\002\0225\n\013update_mask\030\002 \001(\0132\032.google.protob" - + "uf.FieldMaskB\004\342A\001\001\"c\n\031DeleteIssueComment" - + "Request\022F\n\004name\030\001 \001(\tB8\342A\001\002\372A1\n/secureso" - + "urcemanager.googleapis.com/IssueComment2" - + "\205g\n\023SecureSourceManager\022\306\001\n\rListInstance" - + "s\0229.google.cloud.securesourcemanager.v1." - + "ListInstancesRequest\032:.google.cloud.secu" - + "resourcemanager.v1.ListInstancesResponse" - + "\">\332A\006parent\202\323\344\223\002/\022-/v1/{parent=projects/" - + "*/locations/*}/instances\022\263\001\n\013GetInstance" - + "\0227.google.cloud.securesourcemanager.v1.G" - + "etInstanceRequest\032-.google.cloud.secures" - + "ourcemanager.v1.Instance\"<\332A\004name\202\323\344\223\002/\022" - + "-/v1/{name=projects/*/locations/*/instan" - + "ces/*}\022\352\001\n\016CreateInstance\022:.google.cloud" - + ".securesourcemanager.v1.CreateInstanceRe" - + "quest\032\035.google.longrunning.Operation\"}\312A" - + "\035\n\010Instance\022\021OperationMetadata\332A\033parent," - + "instance,instance_id\202\323\344\223\0029\"-/v1/{parent=" - + "projects/*/locations/*}/instances:\010insta" - + "nce\022\326\001\n\016DeleteInstance\022:.google.cloud.se" - + "curesourcemanager.v1.DeleteInstanceReque" - + "st\032\035.google.longrunning.Operation\"i\312A*\n\025" - + "google.protobuf.Empty\022\021OperationMetadata" - + "\332A\004name\202\323\344\223\002/*-/v1/{name=projects/*/loca" - + "tions/*/instances/*}\022\322\001\n\020ListRepositorie" - + "s\022<.google.cloud.securesourcemanager.v1." - + "ListRepositoriesRequest\032=.google.cloud.s" - + "ecuresourcemanager.v1.ListRepositoriesRe" - + "sponse\"A\332A\006parent\202\323\344\223\0022\0220/v1/{parent=pro" - + "jects/*/locations/*}/repositories\022\274\001\n\rGe" - + "tRepository\0229.google.cloud.securesourcem" - + "anager.v1.GetRepositoryRequest\032/.google." - + "cloud.securesourcemanager.v1.Repository\"" - + "?\332A\004name\202\323\344\223\0022\0220/v1/{name=projects/*/loc" - + "ations/*/repositories/*}\022\372\001\n\020CreateRepos" - + "itory\022<.google.cloud.securesourcemanager" - + ".v1.CreateRepositoryRequest\032\035.google.lon" - + "grunning.Operation\"\210\001\312A\037\n\nRepository\022\021Op" - + "erationMetadata\332A\037parent,repository,repo" - + "sitory_id\202\323\344\223\002>\"0/v1/{parent=projects/*/" - + "locations/*}/repositories:\nrepository\022\374\001" - + "\n\020UpdateRepository\022<.google.cloud.secure" - + "sourcemanager.v1.UpdateRepositoryRequest" - + "\032\035.google.longrunning.Operation\"\212\001\312A\037\n\nR" - + "epository\022\021OperationMetadata\332A\026repositor" - + "y,update_mask\202\323\344\223\002I2;/v1/{repository.nam" - + "e=projects/*/locations/*/repositories/*}" - + ":\nrepository\022\335\001\n\020DeleteRepository\022<.goog" - + "le.cloud.securesourcemanager.v1.DeleteRe" - + "positoryRequest\032\035.google.longrunning.Ope" - + "ration\"l\312A*\n\025google.protobuf.Empty\022\021Oper" - + "ationMetadata\332A\004name\202\323\344\223\0022*0/v1/{name=pr" - + "ojects/*/locations/*/repositories/*}\022\305\001\n" - + "\tListHooks\0225.google.cloud.securesourcema" - + "nager.v1.ListHooksRequest\0326.google.cloud" - + ".securesourcemanager.v1.ListHooksRespons" - + "e\"I\332A\006parent\202\323\344\223\002:\0228/v1/{parent=projects" - + "/*/locations/*/repositories/*}/hooks\022\262\001\n" - + "\007GetHook\0223.google.cloud.securesourcemana" - + "ger.v1.GetHookRequest\032).google.cloud.sec" - + "uresourcemanager.v1.Hook\"G\332A\004name\202\323\344\223\002:\022" - + "8/v1/{name=projects/*/locations/*/reposi" - + "tories/*/hooks/*}\022\335\001\n\nCreateHook\0226.googl" - + "e.cloud.securesourcemanager.v1.CreateHoo" - + "kRequest\032\035.google.longrunning.Operation\"" - + "x\312A\031\n\004Hook\022\021OperationMetadata\332A\023parent,h" - + "ook,hook_id\202\323\344\223\002@\"8/v1/{parent=projects/" - + "*/locations/*/repositories/*}/hooks:\004hoo" - + "k\022\337\001\n\nUpdateHook\0226.google.cloud.secureso" - + "urcemanager.v1.UpdateHookRequest\032\035.googl" - + "e.longrunning.Operation\"z\312A\031\n\004Hook\022\021Oper" - + "ationMetadata\332A\020hook,update_mask\202\323\344\223\002E2=" - + "/v1/{hook.name=projects/*/locations/*/re" - + "positories/*/hooks/*}:\004hook\022\331\001\n\nDeleteHo" - + "ok\0226.google.cloud.securesourcemanager.v1" - + ".DeleteHookRequest\032\035.google.longrunning." - + "Operation\"t\312A*\n\025google.protobuf.Empty\022\021O" - + "perationMetadata\332A\004name\202\323\344\223\002:*8/v1/{name" - + "=projects/*/locations/*/repositories/*/h" - + "ooks/*}\022\243\001\n\020GetIamPolicyRepo\022\".google.ia" - + "m.v1.GetIamPolicyRequest\032\025.google.iam.v1" - + ".Policy\"T\332A\010resource\202\323\344\223\002C\022A/v1/{resourc" - + "e=projects/*/locations/*/repositories/*}" - + ":getIamPolicy\022\246\001\n\020SetIamPolicyRepo\022\".goo" - + "gle.iam.v1.SetIamPolicyRequest\032\025.google." - + "iam.v1.Policy\"W\332A\010resource\202\323\344\223\002F\"A/v1/{r" - + "esource=projects/*/locations/*/repositor" - + "ies/*}:setIamPolicy:\001*\022\314\001\n\026TestIamPermis" - + "sionsRepo\022(.google.iam.v1.TestIamPermiss" - + "ionsRequest\032).google.iam.v1.TestIamPermi" - + "ssionsResponse\"]\332A\010resource\202\323\344\223\002L\"G/v1/{" - + "resource=projects/*/locations/*/reposito" - + "ries/*}:testIamPermissions:\001*\022\213\002\n\020Create" - + "BranchRule\022<.google.cloud.securesourcema" - + "nager.v1.CreateBranchRuleRequest\032\035.googl" - + "e.longrunning.Operation\"\231\001\312A\037\n\nBranchRul" - + "e\022\021OperationMetadata\332A!parent,branch_rul" - + "e,branch_rule_id\202\323\344\223\002M\">/v1/{parent=proj" - + "ects/*/locations/*/repositories/*}/branc" - + "hRules:\013branch_rule\022\335\001\n\017ListBranchRules\022" - + ";.google.cloud.securesourcemanager.v1.Li" - + "stBranchRulesRequest\032<.google.cloud.secu" - + "resourcemanager.v1.ListBranchRulesRespon" - + "se\"O\332A\006parent\202\323\344\223\002@\022>/v1/{parent=project" - + "s/*/locations/*/repositories/*}/branchRu" - + "les\022\312\001\n\rGetBranchRule\0229.google.cloud.sec" - + "uresourcemanager.v1.GetBranchRuleRequest" - + "\032/.google.cloud.securesourcemanager.v1.B" - + "ranchRule\"M\332A\004name\202\323\344\223\002@\022>/v1/{name=proj" - + "ects/*/locations/*/repositories/*/branch" - + "Rules/*}\022\215\002\n\020UpdateBranchRule\022<.google.c" - + "loud.securesourcemanager.v1.UpdateBranch" - + "RuleRequest\032\035.google.longrunning.Operati" - + "on\"\233\001\312A\037\n\nBranchRule\022\021OperationMetadata\332" - + "A\027branch_rule,update_mask\202\323\344\223\002Y2J/v1/{br" - + "anch_rule.name=projects/*/locations/*/re" - + "positories/*/branchRules/*}:\013branch_rule" - + "\022\353\001\n\020DeleteBranchRule\022<.google.cloud.sec" - + "uresourcemanager.v1.DeleteBranchRuleRequ" - + "est\032\035.google.longrunning.Operation\"z\312A*\n" - + "\025google.protobuf.Empty\022\021OperationMetadat" - + "a\332A\004name\202\323\344\223\002@*>/v1/{name=projects/*/loc" - + "ations/*/repositories/*/branchRules/*}\022\246" - + "\002\n\021CreatePullRequest\022=.google.cloud.secu" - + "resourcemanager.v1.CreatePullRequestRequ" - + "est\032\035.google.longrunning.Operation\"\262\001\312AD" - + "\n/google.cloud.securesourcemanager.v1.Pu" - + "llRequest\022\021OperationMetadata\332A\023parent,pu" - + "ll_request\202\323\344\223\002O\"?/v1/{parent=projects/*" - + "/locations/*/repositories/*}/pullRequest" - + "s:\014pull_request\022\316\001\n\016GetPullRequest\022:.goo" - + "gle.cloud.securesourcemanager.v1.GetPull" - + "RequestRequest\0320.google.cloud.securesour" - + "cemanager.v1.PullRequest\"N\332A\004name\202\323\344\223\002A\022" - + "?/v1/{name=projects/*/locations/*/reposi" - + "tories/*/pullRequests/*}\022\341\001\n\020ListPullReq" - + "uests\022<.google.cloud.securesourcemanager" - + ".v1.ListPullRequestsRequest\032=.google.clo" - + "ud.securesourcemanager.v1.ListPullReques" - + "tsResponse\"P\332A\006parent\202\323\344\223\002A\022?/v1/{parent" - + "=projects/*/locations/*/repositories/*}/" - + "pullRequests\022\270\002\n\021UpdatePullRequest\022=.goo" - + "gle.cloud.securesourcemanager.v1.UpdateP" - + "ullRequestRequest\032\035.google.longrunning.O" - + "peration\"\304\001\312AD\n/google.cloud.securesourc" - + "emanager.v1.PullRequest\022\021OperationMetada" - + "ta\332A\030pull_request,update_mask\202\323\344\223\002\\2L/v1" - + "/{pull_request.name=projects/*/locations" - + "/*/repositories/*/pullRequests/*}:\014pull_" - + "request\022\220\002\n\020MergePullRequest\022<.google.cl" - + "oud.securesourcemanager.v1.MergePullRequ" - + "estRequest\032\035.google.longrunning.Operatio" - + "n\"\236\001\312AD\n/google.cloud.securesourcemanage" - + "r.v1.PullRequest\022\021OperationMetadata\332A\004na" - + "me\202\323\344\223\002J\"E/v1/{name=projects/*/locations" - + "/*/repositories/*/pullRequests/*}:merge:" - + "\001*\022\215\002\n\017OpenPullRequest\022;.google.cloud.se" - + "curesourcemanager.v1.OpenPullRequestRequ" - + "est\032\035.google.longrunning.Operation\"\235\001\312AD" - + "\n/google.cloud.securesourcemanager.v1.Pu" - + "llRequest\022\021OperationMetadata\332A\004name\202\323\344\223\002" - + "I\"D/v1/{name=projects/*/locations/*/repo" - + "sitories/*/pullRequests/*}:open:\001*\022\220\002\n\020C" - + "losePullRequest\022<.google.cloud.securesou" - + "rcemanager.v1.ClosePullRequestRequest\032\035." - + "google.longrunning.Operation\"\236\001\312AD\n/goog" - + "le.cloud.securesourcemanager.v1.PullRequ" - + "est\022\021OperationMetadata\332A\004name\202\323\344\223\002J\"E/v1" + + "sueComment2\205g\n\023SecureSourceManager\022\306\001\n\rL" + + "istInstances\0229.google.cloud.securesource" + + "manager.v1.ListInstancesRequest\032:.google" + + ".cloud.securesourcemanager.v1.ListInstan" + + "cesResponse\">\332A\006parent\202\323\344\223\002/\022-/v1/{paren" + + "t=projects/*/locations/*}/instances\022\263\001\n\013" + + "GetInstance\0227.google.cloud.securesourcem" + + "anager.v1.GetInstanceRequest\032-.google.cl" + + "oud.securesourcemanager.v1.Instance\"<\332A\004" + + "name\202\323\344\223\002/\022-/v1/{name=projects/*/locatio" + + "ns/*/instances/*}\022\352\001\n\016CreateInstance\022:.g" + + "oogle.cloud.securesourcemanager.v1.Creat" + + "eInstanceRequest\032\035.google.longrunning.Op" + + "eration\"}\312A\035\n\010Instance\022\021OperationMetadat" + + "a\332A\033parent,instance,instance_id\202\323\344\223\0029\"-/" + + "v1/{parent=projects/*/locations/*}/insta" + + "nces:\010instance\022\326\001\n\016DeleteInstance\022:.goog" + + "le.cloud.securesourcemanager.v1.DeleteIn" + + "stanceRequest\032\035.google.longrunning.Opera" + + "tion\"i\312A*\n\025google.protobuf.Empty\022\021Operat" + + "ionMetadata\332A\004name\202\323\344\223\002/*-/v1/{name=proj" + + "ects/*/locations/*/instances/*}\022\322\001\n\020List" + + "Repositories\022<.google.cloud.securesource" + + "manager.v1.ListRepositoriesRequest\032=.goo" + + "gle.cloud.securesourcemanager.v1.ListRep" + + "ositoriesResponse\"A\332A\006parent\202\323\344\223\0022\0220/v1/" + + "{parent=projects/*/locations/*}/reposito" + + "ries\022\274\001\n\rGetRepository\0229.google.cloud.se" + + "curesourcemanager.v1.GetRepositoryReques" + + "t\032/.google.cloud.securesourcemanager.v1." + + "Repository\"?\332A\004name\202\323\344\223\0022\0220/v1/{name=pro" + + "jects/*/locations/*/repositories/*}\022\372\001\n\020" + + "CreateRepository\022<.google.cloud.secureso" + + "urcemanager.v1.CreateRepositoryRequest\032\035" + + ".google.longrunning.Operation\"\210\001\312A\037\n\nRep" + + "ository\022\021OperationMetadata\332A\037parent,repo" + + "sitory,repository_id\202\323\344\223\002>\"0/v1/{parent=" + + "projects/*/locations/*}/repositories:\nre" + + "pository\022\374\001\n\020UpdateRepository\022<.google.c" + + "loud.securesourcemanager.v1.UpdateReposi" + + "toryRequest\032\035.google.longrunning.Operati" + + "on\"\212\001\312A\037\n\nRepository\022\021OperationMetadata\332" + + "A\026repository,update_mask\202\323\344\223\002I2;/v1/{rep" + + "ository.name=projects/*/locations/*/repo" + + "sitories/*}:\nrepository\022\335\001\n\020DeleteReposi" + + "tory\022<.google.cloud.securesourcemanager." + + "v1.DeleteRepositoryRequest\032\035.google.long" + + "running.Operation\"l\312A*\n\025google.protobuf." + + "Empty\022\021OperationMetadata\332A\004name\202\323\344\223\0022*0/" + + "v1/{name=projects/*/locations/*/reposito" + + "ries/*}\022\305\001\n\tListHooks\0225.google.cloud.sec" + + "uresourcemanager.v1.ListHooksRequest\0326.g" + + "oogle.cloud.securesourcemanager.v1.ListH" + + "ooksResponse\"I\332A\006parent\202\323\344\223\002:\0228/v1/{pare" + + "nt=projects/*/locations/*/repositories/*" + + "}/hooks\022\262\001\n\007GetHook\0223.google.cloud.secur" + + "esourcemanager.v1.GetHookRequest\032).googl" + + "e.cloud.securesourcemanager.v1.Hook\"G\332A\004" + + "name\202\323\344\223\002:\0228/v1/{name=projects/*/locatio" + + "ns/*/repositories/*/hooks/*}\022\335\001\n\nCreateH" + + "ook\0226.google.cloud.securesourcemanager.v" + + "1.CreateHookRequest\032\035.google.longrunning" + + ".Operation\"x\312A\031\n\004Hook\022\021OperationMetadata" + + "\332A\023parent,hook,hook_id\202\323\344\223\002@\"8/v1/{paren" + + "t=projects/*/locations/*/repositories/*}" + + "/hooks:\004hook\022\337\001\n\nUpdateHook\0226.google.clo" + + "ud.securesourcemanager.v1.UpdateHookRequ" + + "est\032\035.google.longrunning.Operation\"z\312A\031\n" + + "\004Hook\022\021OperationMetadata\332A\020hook,update_m" + + "ask\202\323\344\223\002E2=/v1/{hook.name=projects/*/loc" + + "ations/*/repositories/*/hooks/*}:\004hook\022\331" + + "\001\n\nDeleteHook\0226.google.cloud.securesourc" + + "emanager.v1.DeleteHookRequest\032\035.google.l" + + "ongrunning.Operation\"t\312A*\n\025google.protob" + + "uf.Empty\022\021OperationMetadata\332A\004name\202\323\344\223\002:" + + "*8/v1/{name=projects/*/locations/*/repos" + + "itories/*/hooks/*}\022\243\001\n\020GetIamPolicyRepo\022" + + "\".google.iam.v1.GetIamPolicyRequest\032\025.go" + + "ogle.iam.v1.Policy\"T\332A\010resource\202\323\344\223\002C\022A/" + + "v1/{resource=projects/*/locations/*/repo" + + "sitories/*}:getIamPolicy\022\246\001\n\020SetIamPolic" + + "yRepo\022\".google.iam.v1.SetIamPolicyReques" + + "t\032\025.google.iam.v1.Policy\"W\332A\010resource\202\323\344" + + "\223\002F\"A/v1/{resource=projects/*/locations/" + + "*/repositories/*}:setIamPolicy:\001*\022\314\001\n\026Te" + + "stIamPermissionsRepo\022(.google.iam.v1.Tes" + + "tIamPermissionsRequest\032).google.iam.v1.T" + + "estIamPermissionsResponse\"]\332A\010resource\202\323" + + "\344\223\002L\"G/v1/{resource=projects/*/locations" + + "/*/repositories/*}:testIamPermissions:\001*" + + "\022\213\002\n\020CreateBranchRule\022<.google.cloud.sec" + + "uresourcemanager.v1.CreateBranchRuleRequ" + + "est\032\035.google.longrunning.Operation\"\231\001\312A\037" + + "\n\nBranchRule\022\021OperationMetadata\332A!parent" + + ",branch_rule,branch_rule_id\202\323\344\223\002M\">/v1/{" + + "parent=projects/*/locations/*/repositori" + + "es/*}/branchRules:\013branch_rule\022\335\001\n\017ListB" + + "ranchRules\022;.google.cloud.securesourcema" + + "nager.v1.ListBranchRulesRequest\032<.google" + + ".cloud.securesourcemanager.v1.ListBranch" + + "RulesResponse\"O\332A\006parent\202\323\344\223\002@\022>/v1/{par" + + "ent=projects/*/locations/*/repositories/" + + "*}/branchRules\022\312\001\n\rGetBranchRule\0229.googl" + + "e.cloud.securesourcemanager.v1.GetBranch" + + "RuleRequest\032/.google.cloud.securesourcem" + + "anager.v1.BranchRule\"M\332A\004name\202\323\344\223\002@\022>/v1" + "/{name=projects/*/locations/*/repositori" - + "es/*/pullRequests/*}:close:\001*\022\205\002\n\030ListPu" - + "llRequestFileDiffs\022D.google.cloud.secure" - + "sourcemanager.v1.ListPullRequestFileDiff" - + "sRequest\032E.google.cloud.securesourcemana" - + "ger.v1.ListPullRequestFileDiffsResponse\"" - + "\\\332A\004name\202\323\344\223\002O\022M/v1/{name=projects/*/loc" - + "ations/*/repositories/*/pullRequests/*}:" - + "listFileDiffs\022\304\001\n\tFetchTree\0225.google.clo" - + "ud.securesourcemanager.v1.FetchTreeReque" - + "st\0326.google.cloud.securesourcemanager.v1" - + ".FetchTreeResponse\"H\202\323\344\223\002B\022@/v1/{reposit" - + "ory=projects/*/locations/*/repositories/" - + "*}:fetchTree\022\304\001\n\tFetchBlob\0225.google.clou" - + "d.securesourcemanager.v1.FetchBlobReques" - + "t\0326.google.cloud.securesourcemanager.v1." - + "FetchBlobResponse\"H\202\323\344\223\002B\022@/v1/{reposito" - + "ry=projects/*/locations/*/repositories/*" - + "}:fetchBlob\022\304\001\n\tFetchRefs\0225.google.cloud" - + ".securesourcemanager.v1.FetchRefsRequest" - + "\0326.google.cloud.securesourcemanager.v1.F" - + "etchRefsResponse\"H\202\323\344\223\002B\022@/v1/{repositor" - + "y=projects/*/locations/*/repositories/*}" - + ":fetchRefs\022\200\002\n\013CreateIssue\0227.google.clou" - + "d.securesourcemanager.v1.CreateIssueRequ" - + "est\032\035.google.longrunning.Operation\"\230\001\312A>" - + "\n)google.cloud.securesourcemanager.v1.Is" - + "sue\022\021OperationMetadata\332A\014parent,issue\202\323\344" - + "\223\002B\"9/v1/{parent=projects/*/locations/*/" - + "repositories/*}/issues:\005issue\022\266\001\n\010GetIss" - + "ue\0224.google.cloud.securesourcemanager.v1" - + ".GetIssueRequest\032*.google.cloud.secureso" - + "urcemanager.v1.Issue\"H\332A\004name\202\323\344\223\002;\0229/v1" - + "/{name=projects/*/locations/*/repositori" - + "es/*/issues/*}\022\311\001\n\nListIssues\0226.google.c" - + "loud.securesourcemanager.v1.ListIssuesRe" - + "quest\0327.google.cloud.securesourcemanager" - + ".v1.ListIssuesResponse\"J\332A\006parent\202\323\344\223\002;\022" - + "9/v1/{parent=projects/*/locations/*/repo" - + "sitories/*}/issues\022\213\002\n\013UpdateIssue\0227.goo" - + "gle.cloud.securesourcemanager.v1.UpdateI" - + "ssueRequest\032\035.google.longrunning.Operati" - + "on\"\243\001\312A>\n)google.cloud.securesourcemanag" - + "er.v1.Issue\022\021OperationMetadata\332A\021issue,u" - + "pdate_mask\202\323\344\223\002H2?/v1/{issue.name=projec" - + "ts/*/locations/*/repositories/*/issues/*" - + "}:\005issue\022\334\001\n\013DeleteIssue\0227.google.cloud." - + "securesourcemanager.v1.DeleteIssueReques" - + "t\032\035.google.longrunning.Operation\"u\312A*\n\025g" - + "oogle.protobuf.Empty\022\021OperationMetadata\332" - + "A\004name\202\323\344\223\002;*9/v1/{name=projects/*/locat" - + "ions/*/repositories/*/issues/*}\022\365\001\n\tOpen" - + "Issue\0225.google.cloud.securesourcemanager" - + ".v1.OpenIssueRequest\032\035.google.longrunnin" - + "g.Operation\"\221\001\312A>\n)google.cloud.secureso" - + "urcemanager.v1.Issue\022\021OperationMetadata\332" - + "A\004name\202\323\344\223\002C\">/v1/{name=projects/*/locat" - + "ions/*/repositories/*/issues/*}:open:\001*\022" - + "\370\001\n\nCloseIssue\0226.google.cloud.securesour" - + "cemanager.v1.CloseIssueRequest\032\035.google." - + "longrunning.Operation\"\222\001\312A>\n)google.clou" - + "d.securesourcemanager.v1.Issue\022\021Operatio" - + "nMetadata\332A\004name\202\323\344\223\002D\"?/v1/{name=projec" - + "ts/*/locations/*/repositories/*/issues/*" - + "}:close:\001*\022\371\001\n\025GetPullRequestComment\022A.g" - + "oogle.cloud.securesourcemanager.v1.GetPu" - + "llRequestCommentRequest\0327.google.cloud.s" - + "ecuresourcemanager.v1.PullRequestComment" - + "\"d\332A\004name\202\323\344\223\002W\022U/v1/{name=projects/*/lo" - + "cations/*/repositories/*/pullRequests/*/" - + "pullRequestComments/*}\022\214\002\n\027ListPullReque" - + "stComments\022C.google.cloud.securesourcema" - + "nager.v1.ListPullRequestCommentsRequest\032" - + "D.google.cloud.securesourcemanager.v1.Li" - + "stPullRequestCommentsResponse\"f\332A\006parent" - + "\202\323\344\223\002W\022U/v1/{parent=projects/*/locations" - + "/*/repositories/*/pullRequests/*}/pullRe" - + "questComments\022\341\002\n\030CreatePullRequestComme" - + "nt\022D.google.cloud.securesourcemanager.v1" - + ".CreatePullRequestCommentRequest\032\035.googl" - + "e.longrunning.Operation\"\337\001\312AK\n6google.cl" - + "oud.securesourcemanager.v1.PullRequestCo" - + "mment\022\021OperationMetadata\332A\033parent,pull_r" - + "equest_comment\202\323\344\223\002m\"U/v1/{parent=projec" - + "ts/*/locations/*/repositories/*/pullRequ" - + "ests/*}/pullRequestComments:\024pull_reques" - + "t_comment\022\374\002\n\030UpdatePullRequestComment\022D" - + ".google.cloud.securesourcemanager.v1.Upd" - + "atePullRequestCommentRequest\032\035.google.lo" - + "ngrunning.Operation\"\372\001\312AK\n6google.cloud." - + "securesourcemanager.v1.PullRequestCommen" - + "t\022\021OperationMetadata\332A pull_request_comm" - + "ent,update_mask\202\323\344\223\002\202\0012j/v1/{pull_reques" - + "t_comment.name=projects/*/locations/*/re" - + "positories/*/pullRequests/*/pullRequestC" - + "omments/*}:\024pull_request_comment\022\223\002\n\030Del" - + "etePullRequestComment\022D.google.cloud.sec" - + "uresourcemanager.v1.DeletePullRequestCom" - + "mentRequest\032\035.google.longrunning.Operati" - + "on\"\221\001\312A*\n\025google.protobuf.Empty\022\021Operati" - + "onMetadata\332A\004name\202\323\344\223\002W*U/v1/{name=proje" - + "cts/*/locations/*/repositories/*/pullReq" - + "uests/*/pullRequestComments/*}\022\312\002\n\036Batch" - + "CreatePullRequestComments\022J.google.cloud" - + ".securesourcemanager.v1.BatchCreatePullR" - + "equestCommentsRequest\032\035.google.longrunni" - + "ng.Operation\"\274\001\312A;\n&BatchCreatePullReque" - + "stCommentsResponse\022\021OperationMetadata\332A\017" - + "parent,requests\202\323\344\223\002f\"a/v1/{parent=proje" - + "cts/*/locations/*/repositories/*/pullReq" - + "uests/*}/pullRequestComments:batchCreate" - + ":\001*\022\267\002\n\032ResolvePullRequestComments\022F.goo" - + "gle.cloud.securesourcemanager.v1.Resolve" - + "PullRequestCommentsRequest\032\035.google.long" - + "running.Operation\"\261\001\312A7\n\"ResolvePullRequ" - + "estCommentsResponse\022\021OperationMetadata\332A" - + "\014parent,names\202\323\344\223\002b\"]/v1/{parent=project" - + "s/*/locations/*/repositories/*/pullReque" - + "sts/*}/pullRequestComments:resolve:\001*\022\277\002" - + "\n\034UnresolvePullRequestComments\022H.google." - + "cloud.securesourcemanager.v1.UnresolvePu" - + "llRequestCommentsRequest\032\035.google.longru" - + "nning.Operation\"\265\001\312A9\n$UnresolvePullRequ" - + "estCommentsResponse\022\021OperationMetadata\332A" - + "\014parent,names\202\323\344\223\002d\"_/v1/{parent=project" - + "s/*/locations/*/repositories/*/pullReque" - + "sts/*}/pullRequestComments:unresolve:\001*\022" - + "\265\002\n\022CreateIssueComment\022>.google.cloud.se" - + "curesourcemanager.v1.CreateIssueCommentR" - + "equest\032\035.google.longrunning.Operation\"\277\001" - + "\312AE\n0google.cloud.securesourcemanager.v1" - + ".IssueComment\022\021OperationMetadata\332A\024paren" - + "t,issue_comment\202\323\344\223\002Z\"I/v1/{parent=proje" + + "es/*/branchRules/*}\022\215\002\n\020UpdateBranchRule" + + "\022<.google.cloud.securesourcemanager.v1.U" + + "pdateBranchRuleRequest\032\035.google.longrunn" + + "ing.Operation\"\233\001\312A\037\n\nBranchRule\022\021Operati" + + "onMetadata\332A\027branch_rule,update_mask\202\323\344\223" + + "\002Y2J/v1/{branch_rule.name=projects/*/loc" + + "ations/*/repositories/*/branchRules/*}:\013" + + "branch_rule\022\353\001\n\020DeleteBranchRule\022<.googl" + + "e.cloud.securesourcemanager.v1.DeleteBra" + + "nchRuleRequest\032\035.google.longrunning.Oper" + + "ation\"z\312A*\n\025google.protobuf.Empty\022\021Opera" + + "tionMetadata\332A\004name\202\323\344\223\002@*>/v1/{name=pro" + + "jects/*/locations/*/repositories/*/branc" + + "hRules/*}\022\246\002\n\021CreatePullRequest\022=.google" + + ".cloud.securesourcemanager.v1.CreatePull" + + "RequestRequest\032\035.google.longrunning.Oper" + + "ation\"\262\001\312AD\n/google.cloud.securesourcema" + + "nager.v1.PullRequest\022\021OperationMetadata\332" + + "A\023parent,pull_request\202\323\344\223\002O\"?/v1/{parent" + + "=projects/*/locations/*/repositories/*}/" + + "pullRequests:\014pull_request\022\316\001\n\016GetPullRe" + + "quest\022:.google.cloud.securesourcemanager" + + ".v1.GetPullRequestRequest\0320.google.cloud" + + ".securesourcemanager.v1.PullRequest\"N\332A\004" + + "name\202\323\344\223\002A\022?/v1/{name=projects/*/locatio" + + "ns/*/repositories/*/pullRequests/*}\022\341\001\n\020" + + "ListPullRequests\022<.google.cloud.secureso" + + "urcemanager.v1.ListPullRequestsRequest\032=" + + ".google.cloud.securesourcemanager.v1.Lis" + + "tPullRequestsResponse\"P\332A\006parent\202\323\344\223\002A\022?" + + "/v1/{parent=projects/*/locations/*/repos" + + "itories/*}/pullRequests\022\270\002\n\021UpdatePullRe" + + "quest\022=.google.cloud.securesourcemanager" + + ".v1.UpdatePullRequestRequest\032\035.google.lo" + + "ngrunning.Operation\"\304\001\312AD\n/google.cloud." + + "securesourcemanager.v1.PullRequest\022\021Oper" + + "ationMetadata\332A\030pull_request,update_mask" + + "\202\323\344\223\002\\2L/v1/{pull_request.name=projects/" + + "*/locations/*/repositories/*/pullRequest" + + "s/*}:\014pull_request\022\220\002\n\020MergePullRequest\022" + + "<.google.cloud.securesourcemanager.v1.Me" + + "rgePullRequestRequest\032\035.google.longrunni" + + "ng.Operation\"\236\001\312AD\n/google.cloud.secures" + + "ourcemanager.v1.PullRequest\022\021OperationMe" + + "tadata\332A\004name\202\323\344\223\002J\"E/v1/{name=projects/" + + "*/locations/*/repositories/*/pullRequest" + + "s/*}:merge:\001*\022\215\002\n\017OpenPullRequest\022;.goog" + + "le.cloud.securesourcemanager.v1.OpenPull" + + "RequestRequest\032\035.google.longrunning.Oper" + + "ation\"\235\001\312AD\n/google.cloud.securesourcema" + + "nager.v1.PullRequest\022\021OperationMetadata\332" + + "A\004name\202\323\344\223\002I\"D/v1/{name=projects/*/locat" + + "ions/*/repositories/*/pullRequests/*}:op" + + "en:\001*\022\220\002\n\020ClosePullRequest\022<.google.clou" + + "d.securesourcemanager.v1.ClosePullReques" + + "tRequest\032\035.google.longrunning.Operation\"" + + "\236\001\312AD\n/google.cloud.securesourcemanager." + + "v1.PullRequest\022\021OperationMetadata\332A\004name" + + "\202\323\344\223\002J\"E/v1/{name=projects/*/locations/*" + + "/repositories/*/pullRequests/*}:close:\001*" + + "\022\205\002\n\030ListPullRequestFileDiffs\022D.google.c" + + "loud.securesourcemanager.v1.ListPullRequ" + + "estFileDiffsRequest\032E.google.cloud.secur" + + "esourcemanager.v1.ListPullRequestFileDif" + + "fsResponse\"\\\332A\004name\202\323\344\223\002O\022M/v1/{name=pro" + + "jects/*/locations/*/repositories/*/pullR" + + "equests/*}:listFileDiffs\022\304\001\n\tFetchTree\0225" + + ".google.cloud.securesourcemanager.v1.Fet" + + "chTreeRequest\0326.google.cloud.securesourc" + + "emanager.v1.FetchTreeResponse\"H\202\323\344\223\002B\022@/" + + "v1/{repository=projects/*/locations/*/re" + + "positories/*}:fetchTree\022\304\001\n\tFetchBlob\0225." + + "google.cloud.securesourcemanager.v1.Fetc" + + "hBlobRequest\0326.google.cloud.securesource" + + "manager.v1.FetchBlobResponse\"H\202\323\344\223\002B\022@/v" + + "1/{repository=projects/*/locations/*/rep" + + "ositories/*}:fetchBlob\022\304\001\n\tFetchRefs\0225.g" + + "oogle.cloud.securesourcemanager.v1.Fetch" + + "RefsRequest\0326.google.cloud.securesourcem" + + "anager.v1.FetchRefsResponse\"H\202\323\344\223\002B\022@/v1" + + "/{repository=projects/*/locations/*/repo" + + "sitories/*}:fetchRefs\022\200\002\n\013CreateIssue\0227." + + "google.cloud.securesourcemanager.v1.Crea" + + "teIssueRequest\032\035.google.longrunning.Oper" + + "ation\"\230\001\312A>\n)google.cloud.securesourcema" + + "nager.v1.Issue\022\021OperationMetadata\332A\014pare" + + "nt,issue\202\323\344\223\002B\"9/v1/{parent=projects/*/l" + + "ocations/*/repositories/*}/issues:\005issue" + + "\022\266\001\n\010GetIssue\0224.google.cloud.securesourc" + + "emanager.v1.GetIssueRequest\032*.google.clo" + + "ud.securesourcemanager.v1.Issue\"H\332A\004name" + + "\202\323\344\223\002;\0229/v1/{name=projects/*/locations/*" + + "/repositories/*/issues/*}\022\311\001\n\nListIssues" + + "\0226.google.cloud.securesourcemanager.v1.L" + + "istIssuesRequest\0327.google.cloud.secureso" + + "urcemanager.v1.ListIssuesResponse\"J\332A\006pa" + + "rent\202\323\344\223\002;\0229/v1/{parent=projects/*/locat" + + "ions/*/repositories/*}/issues\022\213\002\n\013Update" + + "Issue\0227.google.cloud.securesourcemanager" + + ".v1.UpdateIssueRequest\032\035.google.longrunn" + + "ing.Operation\"\243\001\312A>\n)google.cloud.secure" + + "sourcemanager.v1.Issue\022\021OperationMetadat" + + "a\332A\021issue,update_mask\202\323\344\223\002H2?/v1/{issue." + + "name=projects/*/locations/*/repositories" + + "/*/issues/*}:\005issue\022\334\001\n\013DeleteIssue\0227.go" + + "ogle.cloud.securesourcemanager.v1.Delete" + + "IssueRequest\032\035.google.longrunning.Operat" + + "ion\"u\312A*\n\025google.protobuf.Empty\022\021Operati" + + "onMetadata\332A\004name\202\323\344\223\002;*9/v1/{name=proje" + "cts/*/locations/*/repositories/*/issues/" - + "*}/issueComments:\rissue_comment\022\333\001\n\017GetI" - + "ssueComment\022;.google.cloud.securesourcem" - + "anager.v1.GetIssueCommentRequest\0321.googl" - + "e.cloud.securesourcemanager.v1.IssueComm" - + "ent\"X\332A\004name\202\323\344\223\002K\022I/v1/{name=projects/*" - + "/locations/*/repositories/*/issues/*/iss" - + "ueComments/*}\022\356\001\n\021ListIssueComments\022=.go" - + "ogle.cloud.securesourcemanager.v1.ListIs" - + "sueCommentsRequest\032>.google.cloud.secure" - + "sourcemanager.v1.ListIssueCommentsRespon" - + "se\"Z\332A\006parent\202\323\344\223\002K\022I/v1/{parent=project" - + "s/*/locations/*/repositories/*/issues/*}" - + "/issueComments\022\310\002\n\022UpdateIssueComment\022>." - + "google.cloud.securesourcemanager.v1.Upda" - + "teIssueCommentRequest\032\035.google.longrunni" - + "ng.Operation\"\322\001\312AE\n0google.cloud.secures" - + "ourcemanager.v1.IssueComment\022\021OperationM" - + "etadata\332A\031issue_comment,update_mask\202\323\344\223\002" - + "h2W/v1/{issue_comment.name=projects/*/lo" - + "cations/*/repositories/*/issues/*/issueC" - + "omments/*}:\rissue_comment\022\373\001\n\022DeleteIssu" + + "*}\022\365\001\n\tOpenIssue\0225.google.cloud.secureso" + + "urcemanager.v1.OpenIssueRequest\032\035.google" + + ".longrunning.Operation\"\221\001\312A>\n)google.clo" + + "ud.securesourcemanager.v1.Issue\022\021Operati" + + "onMetadata\332A\004name\202\323\344\223\002C\">/v1/{name=proje" + + "cts/*/locations/*/repositories/*/issues/" + + "*}:open:\001*\022\370\001\n\nCloseIssue\0226.google.cloud" + + ".securesourcemanager.v1.CloseIssueReques" + + "t\032\035.google.longrunning.Operation\"\222\001\312A>\n)" + + "google.cloud.securesourcemanager.v1.Issu" + + "e\022\021OperationMetadata\332A\004name\202\323\344\223\002D\"?/v1/{" + + "name=projects/*/locations/*/repositories" + + "/*/issues/*}:close:\001*\022\371\001\n\025GetPullRequest" + + "Comment\022A.google.cloud.securesourcemanag" + + "er.v1.GetPullRequestCommentRequest\0327.goo" + + "gle.cloud.securesourcemanager.v1.PullReq" + + "uestComment\"d\332A\004name\202\323\344\223\002W\022U/v1/{name=pr" + + "ojects/*/locations/*/repositories/*/pull" + + "Requests/*/pullRequestComments/*}\022\214\002\n\027Li" + + "stPullRequestComments\022C.google.cloud.sec" + + "uresourcemanager.v1.ListPullRequestComme" + + "ntsRequest\032D.google.cloud.securesourcema" + + "nager.v1.ListPullRequestCommentsResponse" + + "\"f\332A\006parent\202\323\344\223\002W\022U/v1/{parent=projects/" + + "*/locations/*/repositories/*/pullRequest" + + "s/*}/pullRequestComments\022\341\002\n\030CreatePullR" + + "equestComment\022D.google.cloud.securesourc" + + "emanager.v1.CreatePullRequestCommentRequ" + + "est\032\035.google.longrunning.Operation\"\337\001\312AK" + + "\n6google.cloud.securesourcemanager.v1.Pu" + + "llRequestComment\022\021OperationMetadata\332A\033pa" + + "rent,pull_request_comment\202\323\344\223\002m\"U/v1/{pa" + + "rent=projects/*/locations/*/repositories" + + "/*/pullRequests/*}/pullRequestComments:\024" + + "pull_request_comment\022\374\002\n\030UpdatePullReque" + + "stComment\022D.google.cloud.securesourceman" + + "ager.v1.UpdatePullRequestCommentRequest\032" + + "\035.google.longrunning.Operation\"\372\001\312AK\n6go" + + "ogle.cloud.securesourcemanager.v1.PullRe" + + "questComment\022\021OperationMetadata\332A pull_r" + + "equest_comment,update_mask\202\323\344\223\002\202\0012j/v1/{" + + "pull_request_comment.name=projects/*/loc" + + "ations/*/repositories/*/pullRequests/*/p" + + "ullRequestComments/*}:\024pull_request_comm" + + "ent\022\223\002\n\030DeletePullRequestComment\022D.googl" + + "e.cloud.securesourcemanager.v1.DeletePul" + + "lRequestCommentRequest\032\035.google.longrunn" + + "ing.Operation\"\221\001\312A*\n\025google.protobuf.Emp" + + "ty\022\021OperationMetadata\332A\004name\202\323\344\223\002W*U/v1/" + + "{name=projects/*/locations/*/repositorie" + + "s/*/pullRequests/*/pullRequestComments/*" + + "}\022\312\002\n\036BatchCreatePullRequestComments\022J.g" + + "oogle.cloud.securesourcemanager.v1.Batch" + + "CreatePullRequestCommentsRequest\032\035.googl" + + "e.longrunning.Operation\"\274\001\312A;\n&BatchCrea" + + "tePullRequestCommentsResponse\022\021Operation" + + "Metadata\332A\017parent,requests\202\323\344\223\002f\"a/v1/{p" + + "arent=projects/*/locations/*/repositorie" + + "s/*/pullRequests/*}/pullRequestComments:" + + "batchCreate:\001*\022\267\002\n\032ResolvePullRequestCom" + + "ments\022F.google.cloud.securesourcemanager" + + ".v1.ResolvePullRequestCommentsRequest\032\035." + + "google.longrunning.Operation\"\261\001\312A7\n\"Reso" + + "lvePullRequestCommentsResponse\022\021Operatio" + + "nMetadata\332A\014parent,names\202\323\344\223\002b\"]/v1/{par" + + "ent=projects/*/locations/*/repositories/" + + "*/pullRequests/*}/pullRequestComments:re" + + "solve:\001*\022\277\002\n\034UnresolvePullRequestComment" + + "s\022H.google.cloud.securesourcemanager.v1." + + "UnresolvePullRequestCommentsRequest\032\035.go" + + "ogle.longrunning.Operation\"\265\001\312A9\n$Unreso" + + "lvePullRequestCommentsResponse\022\021Operatio" + + "nMetadata\332A\014parent,names\202\323\344\223\002d\"_/v1/{par" + + "ent=projects/*/locations/*/repositories/" + + "*/pullRequests/*}/pullRequestComments:un" + + "resolve:\001*\022\265\002\n\022CreateIssueComment\022>.goog" + + "le.cloud.securesourcemanager.v1.CreateIs" + + "sueCommentRequest\032\035.google.longrunning.O" + + "peration\"\277\001\312AE\n0google.cloud.securesourc" + + "emanager.v1.IssueComment\022\021OperationMetad" + + "ata\332A\024parent,issue_comment\202\323\344\223\002Z\"I/v1/{p" + + "arent=projects/*/locations/*/repositorie" + + "s/*/issues/*}/issueComments:\rissue_comme" + + "nt\022\333\001\n\017GetIssueComment\022;.google.cloud.se" + + "curesourcemanager.v1.GetIssueCommentRequ" + + "est\0321.google.cloud.securesourcemanager.v" + + "1.IssueComment\"X\332A\004name\202\323\344\223\002K\022I/v1/{name" + + "=projects/*/locations/*/repositories/*/i" + + "ssues/*/issueComments/*}\022\356\001\n\021ListIssueCo" + + "mments\022=.google.cloud.securesourcemanage" + + "r.v1.ListIssueCommentsRequest\032>.google.c" + + "loud.securesourcemanager.v1.ListIssueCom" + + "mentsResponse\"Z\332A\006parent\202\323\344\223\002K\022I/v1/{par" + + "ent=projects/*/locations/*/repositories/" + + "*/issues/*}/issueComments\022\310\002\n\022UpdateIssu" + "eComment\022>.google.cloud.securesourcemana" - + "ger.v1.DeleteIssueCommentRequest\032\035.googl" - + "e.longrunning.Operation\"\205\001\312A*\n\025google.pr" - + "otobuf.Empty\022\021OperationMetadata\332A\004name\202\323" - + "\344\223\002K*I/v1/{name=projects/*/locations/*/r" - + "epositories/*/issues/*/issueComments/*}\032" - + "\225\001\312A\"securesourcemanager.googleapis.com\322" - + "Amhttps://www.googleapis.com/auth/cloud-" - + "platform,https://www.googleapis.com/auth" - + "/securesourcemanager.read-writeB\271\006\n\'com." - + "google.cloud.securesourcemanager.v1B\030Sec" - + "ureSourceManagerProtoP\001ZYcloud.google.co" - + "m/go/securesourcemanager/apiv1/securesou" - + "rcemanagerpb;securesourcemanagerpb\252\002#Goo" - + "gle.Cloud.SecureSourceManager.V1\312\002#Googl" - + "e\\Cloud\\SecureSourceManager\\V1\352\002&Google:" - + ":Cloud::SecureSourceManager::V1\352Ax\n!clou" - + "dkms.googleapis.com/CryptoKey\022Sprojects/" - + "{project}/locations/{location}/keyRings/" - + "{key_ring}/cryptoKeys/{crypto_key}\352A\\\n\037p" - + "rivateca.googleapis.com/CaPool\0229projects" - + "/{project}/locations/{location}/caPools/" - + "{ca_pool}\352AY\n!iam.googleapis.com/Service" - + "Account\0224projects/{project}/serviceAccou" - + "nts/{service_account}\352Aw\n(compute.google" - + "apis.com/ServiceAttachment\022Kprojects/{pr" - + "oject}/regions/{region}/serviceAttachmen" - + "ts/{service_attachment}\352Aq\n\"dlp.googleap" - + "is.com/InspectTemplate\022Kprojects/{projec" - + "t}/locations/{location}/inspectTemplates", - "/{inspect_template}b\006proto3" + + "ger.v1.UpdateIssueCommentRequest\032\035.googl" + + "e.longrunning.Operation\"\322\001\312AE\n0google.cl" + + "oud.securesourcemanager.v1.IssueComment\022" + + "\021OperationMetadata\332A\031issue_comment,updat" + + "e_mask\202\323\344\223\002h2W/v1/{issue_comment.name=pr" + + "ojects/*/locations/*/repositories/*/issu" + + "es/*/issueComments/*}:\rissue_comment\022\373\001\n" + + "\022DeleteIssueComment\022>.google.cloud.secur" + + "esourcemanager.v1.DeleteIssueCommentRequ" + + "est\032\035.google.longrunning.Operation\"\205\001\312A*" + + "\n\025google.protobuf.Empty\022\021OperationMetada" + + "ta\332A\004name\202\323\344\223\002K*I/v1/{name=projects/*/lo" + + "cations/*/repositories/*/issues/*/issueC" + + "omments/*}\032\225\001\312A\"securesourcemanager.goog" + + "leapis.com\322Amhttps://www.googleapis.com/" + + "auth/cloud-platform,https://www.googleap" + + "is.com/auth/securesourcemanager.read-wri" + + "teB\271\006\n\'com.google.cloud.securesourcemana" + + "ger.v1B\030SecureSourceManagerProtoP\001ZYclou" + + "d.google.com/go/securesourcemanager/apiv" + + "1/securesourcemanagerpb;securesourcemana" + + "gerpb\252\002#Google.Cloud.SecureSourceManager" + + ".V1\312\002#Google\\Cloud\\SecureSourceManager\\V" + + "1\352\002&Google::Cloud::SecureSourceManager::" + + "V1\352Ax\n!cloudkms.googleapis.com/CryptoKey" + + "\022Sprojects/{project}/locations/{location" + + "}/keyRings/{key_ring}/cryptoKeys/{crypto" + + "_key}\352A\\\n\037privateca.googleapis.com/CaPoo" + + "l\0229projects/{project}/locations/{locatio" + + "n}/caPools/{ca_pool}\352AY\n!iam.googleapis." + + "com/ServiceAccount\0224projects/{project}/s" + + "erviceAccounts/{service_account}\352Aw\n(com", + "pute.googleapis.com/ServiceAttachment\022Kp" + + "rojects/{project}/regions/{region}/servi" + + "ceAttachments/{service_attachment}\352Aq\n\"d" + + "lp.googleapis.com/InspectTemplate\022Kproje" + + "cts/{project}/locations/{location}/inspe" + + "ctTemplates/{inspect_template}b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -1481,7 +1492,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_descriptor, new java.lang.String[] { - "SecretScanConfig", + "SecretScanConfig", "VulnerabilityScanConfig", }); internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_SecretScanConfig_descriptor = internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_descriptor @@ -1492,6 +1503,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Enabled", "InspectTemplate", }); + internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_VulnerabilityScanConfig_descriptor = + internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_descriptor + .getNestedType(1); + internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_VulnerabilityScanConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessage.FieldAccessorTable( + internal_static_google_cloud_securesourcemanager_v1_Repository_ScanConfig_VulnerabilityScanConfig_descriptor, + new java.lang.String[] { + "Enabled", + }); internal_static_google_cloud_securesourcemanager_v1_Hook_descriptor = getDescriptor().getMessageType(2); internal_static_google_cloud_securesourcemanager_v1_Hook_fieldAccessorTable = @@ -1507,6 +1527,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Uid", "PushOption", "SensitiveQueryString", + "ServiceAccountAuth", }); internal_static_google_cloud_securesourcemanager_v1_Hook_PushOption_descriptor = internal_static_google_cloud_securesourcemanager_v1_Hook_descriptor.getNestedType(0); diff --git a/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/proto/google/cloud/securesourcemanager/v1/secure_source_manager.proto b/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/proto/google/cloud/securesourcemanager/v1/secure_source_manager.proto index 00ad249e4b9e..9715bb60c9fd 100644 --- a/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/proto/google/cloud/securesourcemanager/v1/secure_source_manager.proto +++ b/java-securesourcemanager/proto-google-cloud-securesourcemanager-v1/src/main/proto/google/cloud/securesourcemanager/v1/secure_source_manager.proto @@ -1056,9 +1056,19 @@ message Repository { ]; } + // Configuration for vulnerability scanning. + message VulnerabilityScanConfig { + // Optional. Enables vulnerability scanning for the repository. + bool enabled = 1 [(google.api.field_behavior) = OPTIONAL]; + } + // Optional. Configuration for secret scanning. SecretScanConfig secret_scan_config = 1 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Configuration for vulnerability scanning. + VulnerabilityScanConfig vulnerability_scan_config = 2 + [(google.api.field_behavior) = OPTIONAL]; } // Identifier. A unique identifier for a repository. The name should be of the @@ -1185,6 +1195,10 @@ message Hook { // Optional. The sensitive query string to be appended to the target URI. string sensitive_query_string = 10 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Determines if the hook uses the Repository Service Account to + // generate an OIDC ID Token for webhook authentication. + bool service_account_auth = 11 [(google.api.field_behavior) = OPTIONAL]; } // Metadata of a BranchRule. BranchRule is the protection rule to enforce diff --git a/java-security-private-ca/README.md b/java-security-private-ca/README.md index d6d42f1ede94..05b798ccbe3a 100644 --- a/java-security-private-ca/README.md +++ b/java-security-private-ca/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-security-private-ca - 2.104.0 + 2.105.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-security-private-ca' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-security-private-ca:2.104.0' +implementation 'com.google.cloud:google-cloud-security-private-ca:2.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-security-private-ca" % "2.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-security-private-ca" % "2.105.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-security-private-ca/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-security-private-ca.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-security-private-ca/2.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-security-private-ca/2.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-securitycenter-settings/README.md b/java-securitycenter-settings/README.md index a15bf01ca62d..4ce19cfb6c46 100644 --- a/java-securitycenter-settings/README.md +++ b/java-securitycenter-settings/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-securitycenter-settings - 0.105.0 + 0.106.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-securitycenter-settings' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-securitycenter-settings:0.105.0' +implementation 'com.google.cloud:google-cloud-securitycenter-settings:0.106.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-securitycenter-settings" % "0.105.0" +libraryDependencies += "com.google.cloud" % "google-cloud-securitycenter-settings" % "0.106.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-securitycenter-settings/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-securitycenter-settings.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-securitycenter-settings/0.105.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-securitycenter-settings/0.106.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-securitycenter/README.md b/java-securitycenter/README.md index 0a53e7ec294e..a36373d6b3ce 100644 --- a/java-securitycenter/README.md +++ b/java-securitycenter/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-securitycenter - 2.110.0 + 2.111.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-securitycenter' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-securitycenter:2.110.0' +implementation 'com.google.cloud:google-cloud-securitycenter:2.111.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-securitycenter" % "2.110.0" +libraryDependencies += "com.google.cloud" % "google-cloud-securitycenter" % "2.111.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-securitycenter/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-securitycenter.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-securitycenter/2.110.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-securitycenter/2.111.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-securitycentermanagement/README.md b/java-securitycentermanagement/README.md index 72b17e81267e..0bb68b7e536b 100644 --- a/java-securitycentermanagement/README.md +++ b/java-securitycentermanagement/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-securitycentermanagement - 0.70.0 + 0.71.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-securitycentermanagement' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-securitycentermanagement:0.70.0' +implementation 'com.google.cloud:google-cloud-securitycentermanagement:0.71.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-securitycentermanagement" % "0.70.0" +libraryDependencies += "com.google.cloud" % "google-cloud-securitycentermanagement" % "0.71.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-securitycentermanagement/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-securitycentermanagement.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-securitycentermanagement/0.70.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-securitycentermanagement/0.71.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-securityposture/README.md b/java-securityposture/README.md index 79d7d7d70950..9e0bf35bf639 100644 --- a/java-securityposture/README.md +++ b/java-securityposture/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-securityposture - 0.67.0 + 0.68.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-securityposture' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-securityposture:0.67.0' +implementation 'com.google.cloud:google-cloud-securityposture:0.68.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-securityposture" % "0.67.0" +libraryDependencies += "com.google.cloud" % "google-cloud-securityposture" % "0.68.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-securityposture/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-securityposture.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-securityposture/0.67.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-securityposture/0.68.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-service-control/README.md b/java-service-control/README.md index 0c9a70166f94..b1d7d82f7dc5 100644 --- a/java-service-control/README.md +++ b/java-service-control/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-service-control - 1.102.0 + 1.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-service-control' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-service-control:1.102.0' +implementation 'com.google.cloud:google-cloud-service-control:1.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-service-control" % "1.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-service-control" % "1.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-service-control/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-service-control.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-service-control/1.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-service-control/1.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-service-management/README.md b/java-service-management/README.md index f4aa5e385d88..c76d9d0e8320 100644 --- a/java-service-management/README.md +++ b/java-service-management/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-service-management - 3.100.0 + 3.101.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-service-management' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-service-management:3.100.0' +implementation 'com.google.cloud:google-cloud-service-management:3.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-service-management" % "3.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-service-management" % "3.101.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-service-management/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-service-management.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-service-management/3.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-service-management/3.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-service-usage/README.md b/java-service-usage/README.md index 81e47e5dacc9..89f5637eab46 100644 --- a/java-service-usage/README.md +++ b/java-service-usage/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-service-usage - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-service-usage' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-service-usage:2.102.0' +implementation 'com.google.cloud:google-cloud-service-usage:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-service-usage" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-service-usage" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-service-usage/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-service-usage.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-service-usage/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-service-usage/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-servicedirectory/README.md b/java-servicedirectory/README.md index fee832f14e4a..e8310c016242 100644 --- a/java-servicedirectory/README.md +++ b/java-servicedirectory/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-servicedirectory - 2.103.0 + 2.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-servicedirectory' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-servicedirectory:2.103.0' +implementation 'com.google.cloud:google-cloud-servicedirectory:2.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-servicedirectory" % "2.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-servicedirectory" % "2.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-servicedirectory/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-servicedirectory.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-servicedirectory/2.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-servicedirectory/2.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-servicehealth/README.md b/java-servicehealth/README.md index 39ca368d8439..f9e3e357b426 100644 --- a/java-servicehealth/README.md +++ b/java-servicehealth/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-servicehealth - 0.69.0 + 0.70.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-servicehealth' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-servicehealth:0.69.0' +implementation 'com.google.cloud:google-cloud-servicehealth:0.70.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-servicehealth" % "0.69.0" +libraryDependencies += "com.google.cloud" % "google-cloud-servicehealth" % "0.70.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-servicehealth/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-servicehealth.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-servicehealth/0.69.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-servicehealth/0.70.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shell/README.md b/java-shell/README.md index 28765edcef64..20c3e4dcbe70 100644 --- a/java-shell/README.md +++ b/java-shell/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-shell - 2.101.0 + 2.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-shell' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-shell:2.101.0' +implementation 'com.google.cloud:google-cloud-shell:2.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-shell" % "2.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-shell" % "2.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-shell/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-shell.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-shell/2.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-shell/2.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-css/README.md b/java-shopping-css/README.md index e375e33bc87a..58da170d6e84 100644 --- a/java-shopping-css/README.md +++ b/java-shopping-css/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-css - 0.70.0 + 0.71.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-css:0.70.0' +implementation 'com.google.shopping:google-shopping-css:0.71.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-css" % "0.70.0" +libraryDependencies += "com.google.shopping" % "google-shopping-css" % "0.71.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-css/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-css.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-css/0.70.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-css/0.71.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-accounts/README.md b/java-shopping-merchant-accounts/README.md index 565612b19d10..c9863a884709 100644 --- a/java-shopping-merchant-accounts/README.md +++ b/java-shopping-merchant-accounts/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-accounts - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-accounts:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-accounts:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-accounts" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-accounts" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-accounts/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-accounts.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-accounts/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-accounts/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-conversions/README.md b/java-shopping-merchant-conversions/README.md index b77c0cfe68c6..e07da3f295aa 100644 --- a/java-shopping-merchant-conversions/README.md +++ b/java-shopping-merchant-conversions/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-conversions - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-conversions:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-conversions:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-conversions" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-conversions" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-conversions/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-conversions.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-conversions/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-conversions/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-datasources/README.md b/java-shopping-merchant-datasources/README.md index 3e8c20219586..e5ff1a11c5e1 100644 --- a/java-shopping-merchant-datasources/README.md +++ b/java-shopping-merchant-datasources/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-datasources - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-datasources:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-datasources:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-datasources" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-datasources" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-datasources/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-datasources.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-datasources/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-datasources/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-inventories/README.md b/java-shopping-merchant-inventories/README.md index 83dc44826ea2..942ee3978ad3 100644 --- a/java-shopping-merchant-inventories/README.md +++ b/java-shopping-merchant-inventories/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-inventories - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-inventories:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-inventories:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-inventories" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-inventories" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-inventories/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-inventories.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-inventories/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-inventories/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-issue-resolution/README.md b/java-shopping-merchant-issue-resolution/README.md index 9d969391e6d8..dca07198273a 100644 --- a/java-shopping-merchant-issue-resolution/README.md +++ b/java-shopping-merchant-issue-resolution/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-issue-resolution - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-issue-resolution:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-issue-resolution:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-issue-resolution" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-issue-resolution" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-issue-resolution/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-issue-resolution.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-issue-resolution/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-issue-resolution/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-lfp/README.md b/java-shopping-merchant-lfp/README.md index 2c6450aa01c9..6c4bba152346 100644 --- a/java-shopping-merchant-lfp/README.md +++ b/java-shopping-merchant-lfp/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-lfp - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-lfp:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-lfp:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-lfp" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-lfp" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-lfp/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-lfp.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-lfp/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-lfp/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-loyaltycustomers/README.md b/java-shopping-merchant-loyaltycustomers/README.md index 2bcd67eec061..fdb4431f7530 100644 --- a/java-shopping-merchant-loyaltycustomers/README.md +++ b/java-shopping-merchant-loyaltycustomers/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-loyaltycustomers - 0.6.0 + 0.7.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-loyaltycustomers:0.6.0' +implementation 'com.google.shopping:google-shopping-merchant-loyaltycustomers:0.7.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-loyaltycustomers" % "0.6.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-loyaltycustomers" % "0.7.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-loyaltycustomers/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-loyaltycustomers.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-loyaltycustomers/0.6.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-loyaltycustomers/0.7.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-notifications/README.md b/java-shopping-merchant-notifications/README.md index 9af112722a57..b05b5824a718 100644 --- a/java-shopping-merchant-notifications/README.md +++ b/java-shopping-merchant-notifications/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-notifications - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-notifications:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-notifications:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-notifications" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-notifications" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-notifications/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-notifications.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-notifications/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-notifications/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-order-tracking/README.md b/java-shopping-merchant-order-tracking/README.md index 66e00a4de745..1167477b1551 100644 --- a/java-shopping-merchant-order-tracking/README.md +++ b/java-shopping-merchant-order-tracking/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-order-tracking - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-order-tracking:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-order-tracking:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-order-tracking" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-order-tracking" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-order-tracking/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-order-tracking.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-order-tracking/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-order-tracking/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-product-studio/README.md b/java-shopping-merchant-product-studio/README.md index 8ee5738681a5..a0c1bf0bd9b0 100644 --- a/java-shopping-merchant-product-studio/README.md +++ b/java-shopping-merchant-product-studio/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-productstudio - 0.42.0 + 0.43.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-productstudio:0.42.0' +implementation 'com.google.shopping:google-shopping-merchant-productstudio:0.43.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-productstudio" % "0.42.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-productstudio" % "0.43.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-productstudio/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-productstudio.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-productstudio/0.42.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-productstudio/0.43.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-products/README.md b/java-shopping-merchant-products/README.md index 62a839e398d3..a4b2eb23d83e 100644 --- a/java-shopping-merchant-products/README.md +++ b/java-shopping-merchant-products/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-products - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-products:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-products:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-products" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-products" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-products/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-products.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-products/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-products/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-promotions/README.md b/java-shopping-merchant-promotions/README.md index 788f49f4a723..601681ebb42b 100644 --- a/java-shopping-merchant-promotions/README.md +++ b/java-shopping-merchant-promotions/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-promotions - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-promotions:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-promotions:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-promotions" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-promotions" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-promotions/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-promotions.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-promotions/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-promotions/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-quota/README.md b/java-shopping-merchant-quota/README.md index d8c213edb69b..9879ffc0edaf 100644 --- a/java-shopping-merchant-quota/README.md +++ b/java-shopping-merchant-quota/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-quota - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-quota:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-quota:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-quota" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-quota" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-quota/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-quota.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-quota/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-quota/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-reports/README.md b/java-shopping-merchant-reports/README.md index 779fa26837fc..6d52cabe10fc 100644 --- a/java-shopping-merchant-reports/README.md +++ b/java-shopping-merchant-reports/README.md @@ -18,20 +18,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-reports - 1.30.0 + 1.31.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-reports:1.30.0' +implementation 'com.google.shopping:google-shopping-merchant-reports:1.31.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-reports" % "1.30.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-reports" % "1.31.0" ``` ## Authentication @@ -149,7 +149,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-reports/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-reports.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-reports/1.30.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-reports/1.31.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-shopping-merchant-reviews/README.md b/java-shopping-merchant-reviews/README.md index 3d46f57df9b0..3f6d3fe0c8b2 100644 --- a/java-shopping-merchant-reviews/README.md +++ b/java-shopping-merchant-reviews/README.md @@ -21,20 +21,20 @@ If you are using Maven, add this to your pom.xml file: com.google.shopping google-shopping-merchant-reviews - 0.48.0 + 0.49.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.shopping:google-shopping-merchant-reviews:0.48.0' +implementation 'com.google.shopping:google-shopping-merchant-reviews:0.49.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.shopping" % "google-shopping-merchant-reviews" % "0.48.0" +libraryDependencies += "com.google.shopping" % "google-shopping-merchant-reviews" % "0.49.0" ``` ## Authentication @@ -155,7 +155,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-shopping-merchant-reviews/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.shopping/google-shopping-merchant-reviews.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-reviews/0.48.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.shopping/google-shopping-merchant-reviews/0.49.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-spanner/README.md b/java-spanner/README.md index 514f4baf4832..b8bf66e45a83 100644 --- a/java-spanner/README.md +++ b/java-spanner/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-spanner - 6.127.0 + 6.128.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-spanner' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-spanner:6.127.0' +implementation 'com.google.cloud:google-cloud-spanner:6.128.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-spanner" % "6.127.0" +libraryDependencies += "com.google.cloud" % "google-cloud-spanner" % "6.128.0" ``` ## Authentication @@ -592,7 +592,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-spanner/latest/history [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-spanner.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-spanner/6.127.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-spanner/6.128.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-spanner/google-cloud-spanner/src/test/java/com/google/cloud/spanner/connection/ConnectionOptionsTest.java b/java-spanner/google-cloud-spanner/src/test/java/com/google/cloud/spanner/connection/ConnectionOptionsTest.java index 81257037a8ed..c7b4852e5e62 100644 --- a/java-spanner/google-cloud-spanner/src/test/java/com/google/cloud/spanner/connection/ConnectionOptionsTest.java +++ b/java-spanner/google-cloud-spanner/src/test/java/com/google/cloud/spanner/connection/ConnectionOptionsTest.java @@ -1180,8 +1180,8 @@ public void testValidCredentialsProvider_WithoutEnablingSystemProperty() throws assertEquals(ErrorCode.FAILED_PRECONDITION, exception.getErrorCode()); assertEquals( "FAILED_PRECONDITION: credentialsProvider can only be used if the system property" - + " ENABLE_CREDENTIALS_PROVIDER has been set to true. Start the application with the" - + " JVM command line option -DENABLE_CREDENTIALS_PROVIDER=true", + + " ENABLE_CREDENTIALS_PROVIDER has been set to true. Start the application with" + + " the JVM command line option -DENABLE_CREDENTIALS_PROVIDER=true", exception.getMessage()); }); } @@ -1228,8 +1228,8 @@ public void testCredentialsProvider_NotLoadedWithoutSystemProperty() throws Thro assertEquals(ErrorCode.FAILED_PRECONDITION, exception.getErrorCode()); assertEquals( "FAILED_PRECONDITION: credentialsProvider can only be used if the system property" - + " ENABLE_CREDENTIALS_PROVIDER has been set to true. Start the application with the" - + " JVM command line option -DENABLE_CREDENTIALS_PROVIDER=true", + + " ENABLE_CREDENTIALS_PROVIDER has been set to true. Start the application with" + + " the JVM command line option -DENABLE_CREDENTIALS_PROVIDER=true", exception.getMessage()); }); } @@ -1287,7 +1287,8 @@ public void testCredentialsProvider_NonExistentClass() throws Throwable { exception .getMessage() .contains( - "Unknown or invalid CredentialsProvider class name: com.google.cloud.spanner.connection.NonExistentClass")); + "Unknown or invalid CredentialsProvider class name:" + + " com.google.cloud.spanner.connection.NonExistentClass")); }); } @@ -1781,7 +1782,8 @@ public void testExternalChannelProvider_NonExistentClass() throws Throwable { exception .getMessage() .contains( - "Unknown or invalid ExternalChannelProvider class name: com.google.cloud.spanner.connection.NonExistentClass")); + "Unknown or invalid ExternalChannelProvider class name:" + + " com.google.cloud.spanner.connection.NonExistentClass")); }); } diff --git a/java-spanner/google-cloud-spanner/src/test/java/com/google/cloud/spanner/connection/GrpcInterceptorProviderTest.java b/java-spanner/google-cloud-spanner/src/test/java/com/google/cloud/spanner/connection/GrpcInterceptorProviderTest.java index 18f3bbfaf063..0a4a8e796515 100644 --- a/java-spanner/google-cloud-spanner/src/test/java/com/google/cloud/spanner/connection/GrpcInterceptorProviderTest.java +++ b/java-spanner/google-cloud-spanner/src/test/java/com/google/cloud/spanner/connection/GrpcInterceptorProviderTest.java @@ -225,7 +225,8 @@ public void testGrpcInterceptorProvider_NonExistentClass() throws Throwable { exception .getMessage() .contains( - "Unknown or invalid GrpcInterceptorProvider class name: com.google.cloud.spanner.connection.NonExistentClass")); + "Unknown or invalid GrpcInterceptorProvider class name:" + + " com.google.cloud.spanner.connection.NonExistentClass")); }); } diff --git a/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/CloudExecutorProto.java b/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/CloudExecutorProto.java index b0dd409b44d3..c4ec1d6ad909 100644 --- a/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/CloudExecutorProto.java +++ b/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/CloudExecutorProto.java @@ -739,12 +739,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "sdl_statement\030\004 \003(\t\022\024\n" + "\014operation_id\030\005 \001(\t\022\036\n" + "\021proto_descriptors\030\006 \001(\014H\000\210\001\001B\024\n" - + "\022_proto_descriptors\"{\n" + + "\022_proto_descriptors\"\312\001\n" + "\031UpdateCloudDatabaseAction\022\023\n" + "\013instance_id\030\001 \001(\t\022\022\n\n" + "project_id\030\002 \001(\t\022\025\n\r" + "database_name\030\003 \001(\t\022\036\n" - + "\026enable_drop_protection\030\004 \001(\010\"W\n" + + "\026enable_drop_protection\030\004 \001(\010\022M\n" + + "\021encryption_config\030\005" + + " \001(\01322.google.spanner.admin.database.v1.EncryptionConfig\"W\n" + "\027DropCloudDatabaseAction\022\023\n" + "\013instance_id\030\001 \001(\t\022\022\n\n" + "project_id\030\002 \001(\t\022\023\n" @@ -918,9 +920,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ogle.spanner.executor.v1.AdminResultH\006\210\001\001\022\031\n" + "\021dml_rows_modified\030\t \003(\003\022M\n" + "\025change_stream_records\030\n" - + " \003(\0132..google.spanner.executor.v1.ChangeStreamRecord\0222\n" - + "%snapshot_isolation_txn_read_timestamp\030\013 \001(\003H\007\210\001\001B", - "\t\n" + + " \003(\0132..google.spanner.exe", + "cutor.v1.ChangeStreamRecord\0222\n" + + "%snapshot_isolation_txn_read_timestamp\030\013 \001(\003H\007\210\001\001B\t\n" + "\007_statusB\016\n" + "\014_commit_timeB\016\n" + "\014_read_resultB\017\n\r" @@ -1484,7 +1486,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_google_spanner_executor_v1_UpdateCloudDatabaseAction_descriptor, new java.lang.String[] { - "InstanceId", "ProjectId", "DatabaseName", "EnableDropProtection", + "InstanceId", "ProjectId", "DatabaseName", "EnableDropProtection", "EncryptionConfig", }); internal_static_google_spanner_executor_v1_DropCloudDatabaseAction_descriptor = getDescriptor().getMessageType(32); diff --git a/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/UpdateCloudDatabaseAction.java b/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/UpdateCloudDatabaseAction.java index d604bc78dbef..d59cb2cd3040 100644 --- a/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/UpdateCloudDatabaseAction.java +++ b/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/UpdateCloudDatabaseAction.java @@ -72,6 +72,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { com.google.spanner.executor.v1.UpdateCloudDatabaseAction.Builder.class); } + private int bitField0_; public static final int INSTANCE_ID_FIELD_NUMBER = 1; @SuppressWarnings("serial") @@ -238,8 +239,7 @@ public com.google.protobuf.ByteString getDatabaseNameBytes() { * * *
    -   * Updated value of enable_drop_protection, this is the only field that has
    -   * supported to be updated.
    +   * Updated value of enable_drop_protection.
        * 
    * * bool enable_drop_protection = 4; @@ -251,6 +251,60 @@ public boolean getEnableDropProtection() { return enableDropProtection_; } + public static final int ENCRYPTION_CONFIG_FIELD_NUMBER = 5; + private com.google.spanner.admin.database.v1.EncryptionConfig encryptionConfig_; + + /** + * + * + *
    +   * Optional encryption config for key changes.
    +   * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + * + * @return Whether the encryptionConfig field is set. + */ + @java.lang.Override + public boolean hasEncryptionConfig() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
    +   * Optional encryption config for key changes.
    +   * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + * + * @return The encryptionConfig. + */ + @java.lang.Override + public com.google.spanner.admin.database.v1.EncryptionConfig getEncryptionConfig() { + return encryptionConfig_ == null + ? com.google.spanner.admin.database.v1.EncryptionConfig.getDefaultInstance() + : encryptionConfig_; + } + + /** + * + * + *
    +   * Optional encryption config for key changes.
    +   * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + */ + @java.lang.Override + public com.google.spanner.admin.database.v1.EncryptionConfigOrBuilder + getEncryptionConfigOrBuilder() { + return encryptionConfig_ == null + ? com.google.spanner.admin.database.v1.EncryptionConfig.getDefaultInstance() + : encryptionConfig_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -277,6 +331,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (enableDropProtection_ != false) { output.writeBool(4, enableDropProtection_); } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getEncryptionConfig()); + } getUnknownFields().writeTo(output); } @@ -298,6 +355,9 @@ public int getSerializedSize() { if (enableDropProtection_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, enableDropProtection_); } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getEncryptionConfig()); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -318,6 +378,10 @@ public boolean equals(final java.lang.Object obj) { if (!getProjectId().equals(other.getProjectId())) return false; if (!getDatabaseName().equals(other.getDatabaseName())) return false; if (getEnableDropProtection() != other.getEnableDropProtection()) return false; + if (hasEncryptionConfig() != other.hasEncryptionConfig()) return false; + if (hasEncryptionConfig()) { + if (!getEncryptionConfig().equals(other.getEncryptionConfig())) return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -337,6 +401,10 @@ public int hashCode() { hash = (53 * hash) + getDatabaseName().hashCode(); hash = (37 * hash) + ENABLE_DROP_PROTECTION_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getEnableDropProtection()); + if (hasEncryptionConfig()) { + hash = (37 * hash) + ENCRYPTION_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getEncryptionConfig().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -468,10 +536,19 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.spanner.executor.v1.UpdateCloudDatabaseAction.newBuilder() - private Builder() {} + private Builder() { + maybeForceBuilderInitialization(); + } private Builder(com.google.protobuf.GeneratedMessage.BuilderParent parent) { super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + internalGetEncryptionConfigFieldBuilder(); + } } @java.lang.Override @@ -482,6 +559,11 @@ public Builder clear() { projectId_ = ""; databaseName_ = ""; enableDropProtection_ = false; + encryptionConfig_ = null; + if (encryptionConfigBuilder_ != null) { + encryptionConfigBuilder_.dispose(); + encryptionConfigBuilder_ = null; + } return this; } @@ -530,6 +612,13 @@ private void buildPartial0(com.google.spanner.executor.v1.UpdateCloudDatabaseAct if (((from_bitField0_ & 0x00000008) != 0)) { result.enableDropProtection_ = enableDropProtection_; } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000010) != 0)) { + result.encryptionConfig_ = + encryptionConfigBuilder_ == null ? encryptionConfig_ : encryptionConfigBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; } @java.lang.Override @@ -563,6 +652,9 @@ public Builder mergeFrom(com.google.spanner.executor.v1.UpdateCloudDatabaseActio if (other.getEnableDropProtection() != false) { setEnableDropProtection(other.getEnableDropProtection()); } + if (other.hasEncryptionConfig()) { + mergeEncryptionConfig(other.getEncryptionConfig()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -613,6 +705,13 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 32 + case 42: + { + input.readMessage( + internalGetEncryptionConfigFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -971,8 +1070,7 @@ public Builder setDatabaseNameBytes(com.google.protobuf.ByteString value) { * * *
    -     * Updated value of enable_drop_protection, this is the only field that has
    -     * supported to be updated.
    +     * Updated value of enable_drop_protection.
          * 
    * * bool enable_drop_protection = 4; @@ -988,8 +1086,7 @@ public boolean getEnableDropProtection() { * * *
    -     * Updated value of enable_drop_protection, this is the only field that has
    -     * supported to be updated.
    +     * Updated value of enable_drop_protection.
          * 
    * * bool enable_drop_protection = 4; @@ -1009,8 +1106,7 @@ public Builder setEnableDropProtection(boolean value) { * * *
    -     * Updated value of enable_drop_protection, this is the only field that has
    -     * supported to be updated.
    +     * Updated value of enable_drop_protection.
          * 
    * * bool enable_drop_protection = 4; @@ -1024,6 +1120,206 @@ public Builder clearEnableDropProtection() { return this; } + private com.google.spanner.admin.database.v1.EncryptionConfig encryptionConfig_; + private com.google.protobuf.SingleFieldBuilder< + com.google.spanner.admin.database.v1.EncryptionConfig, + com.google.spanner.admin.database.v1.EncryptionConfig.Builder, + com.google.spanner.admin.database.v1.EncryptionConfigOrBuilder> + encryptionConfigBuilder_; + + /** + * + * + *
    +     * Optional encryption config for key changes.
    +     * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + * + * @return Whether the encryptionConfig field is set. + */ + public boolean hasEncryptionConfig() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
    +     * Optional encryption config for key changes.
    +     * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + * + * @return The encryptionConfig. + */ + public com.google.spanner.admin.database.v1.EncryptionConfig getEncryptionConfig() { + if (encryptionConfigBuilder_ == null) { + return encryptionConfig_ == null + ? com.google.spanner.admin.database.v1.EncryptionConfig.getDefaultInstance() + : encryptionConfig_; + } else { + return encryptionConfigBuilder_.getMessage(); + } + } + + /** + * + * + *
    +     * Optional encryption config for key changes.
    +     * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + */ + public Builder setEncryptionConfig( + com.google.spanner.admin.database.v1.EncryptionConfig value) { + if (encryptionConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + encryptionConfig_ = value; + } else { + encryptionConfigBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional encryption config for key changes.
    +     * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + */ + public Builder setEncryptionConfig( + com.google.spanner.admin.database.v1.EncryptionConfig.Builder builderForValue) { + if (encryptionConfigBuilder_ == null) { + encryptionConfig_ = builderForValue.build(); + } else { + encryptionConfigBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional encryption config for key changes.
    +     * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + */ + public Builder mergeEncryptionConfig( + com.google.spanner.admin.database.v1.EncryptionConfig value) { + if (encryptionConfigBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && encryptionConfig_ != null + && encryptionConfig_ + != com.google.spanner.admin.database.v1.EncryptionConfig.getDefaultInstance()) { + getEncryptionConfigBuilder().mergeFrom(value); + } else { + encryptionConfig_ = value; + } + } else { + encryptionConfigBuilder_.mergeFrom(value); + } + if (encryptionConfig_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
    +     * Optional encryption config for key changes.
    +     * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + */ + public Builder clearEncryptionConfig() { + bitField0_ = (bitField0_ & ~0x00000010); + encryptionConfig_ = null; + if (encryptionConfigBuilder_ != null) { + encryptionConfigBuilder_.dispose(); + encryptionConfigBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
    +     * Optional encryption config for key changes.
    +     * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + */ + public com.google.spanner.admin.database.v1.EncryptionConfig.Builder + getEncryptionConfigBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return internalGetEncryptionConfigFieldBuilder().getBuilder(); + } + + /** + * + * + *
    +     * Optional encryption config for key changes.
    +     * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + */ + public com.google.spanner.admin.database.v1.EncryptionConfigOrBuilder + getEncryptionConfigOrBuilder() { + if (encryptionConfigBuilder_ != null) { + return encryptionConfigBuilder_.getMessageOrBuilder(); + } else { + return encryptionConfig_ == null + ? com.google.spanner.admin.database.v1.EncryptionConfig.getDefaultInstance() + : encryptionConfig_; + } + } + + /** + * + * + *
    +     * Optional encryption config for key changes.
    +     * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + */ + private com.google.protobuf.SingleFieldBuilder< + com.google.spanner.admin.database.v1.EncryptionConfig, + com.google.spanner.admin.database.v1.EncryptionConfig.Builder, + com.google.spanner.admin.database.v1.EncryptionConfigOrBuilder> + internalGetEncryptionConfigFieldBuilder() { + if (encryptionConfigBuilder_ == null) { + encryptionConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilder< + com.google.spanner.admin.database.v1.EncryptionConfig, + com.google.spanner.admin.database.v1.EncryptionConfig.Builder, + com.google.spanner.admin.database.v1.EncryptionConfigOrBuilder>( + getEncryptionConfig(), getParentForChildren(), isClean()); + encryptionConfig_ = null; + } + return encryptionConfigBuilder_; + } + // @@protoc_insertion_point(builder_scope:google.spanner.executor.v1.UpdateCloudDatabaseAction) } diff --git a/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/UpdateCloudDatabaseActionOrBuilder.java b/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/UpdateCloudDatabaseActionOrBuilder.java index 4a2d2d143ddc..e843ef5fe302 100644 --- a/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/UpdateCloudDatabaseActionOrBuilder.java +++ b/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/java/com/google/spanner/executor/v1/UpdateCloudDatabaseActionOrBuilder.java @@ -108,8 +108,7 @@ public interface UpdateCloudDatabaseActionOrBuilder * * *
    -   * Updated value of enable_drop_protection, this is the only field that has
    -   * supported to be updated.
    +   * Updated value of enable_drop_protection.
        * 
    * * bool enable_drop_protection = 4; @@ -117,4 +116,41 @@ public interface UpdateCloudDatabaseActionOrBuilder * @return The enableDropProtection. */ boolean getEnableDropProtection(); + + /** + * + * + *
    +   * Optional encryption config for key changes.
    +   * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + * + * @return Whether the encryptionConfig field is set. + */ + boolean hasEncryptionConfig(); + + /** + * + * + *
    +   * Optional encryption config for key changes.
    +   * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + * + * @return The encryptionConfig. + */ + com.google.spanner.admin.database.v1.EncryptionConfig getEncryptionConfig(); + + /** + * + * + *
    +   * Optional encryption config for key changes.
    +   * 
    + * + * .google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; + */ + com.google.spanner.admin.database.v1.EncryptionConfigOrBuilder getEncryptionConfigOrBuilder(); } diff --git a/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/proto/google/spanner/executor/v1/cloud_executor.proto b/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/proto/google/spanner/executor/v1/cloud_executor.proto index 05fbd39d8561..e8d83af0ae00 100644 --- a/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/proto/google/spanner/executor/v1/cloud_executor.proto +++ b/java-spanner/proto-google-cloud-spanner-executor-v1/src/main/proto/google/spanner/executor/v1/cloud_executor.proto @@ -806,9 +806,11 @@ message UpdateCloudDatabaseAction { // Cloud database name (not full path), e.g. "db0". string database_name = 3; - // Updated value of enable_drop_protection, this is the only field that has - // supported to be updated. + // Updated value of enable_drop_protection. bool enable_drop_protection = 4; + + // Optional encryption config for key changes. + google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5; } // Action that drops a Cloud Spanner database. diff --git a/java-spanneradapter/README.md b/java-spanneradapter/README.md index bb699b3d8db1..4119d667bdca 100644 --- a/java-spanneradapter/README.md +++ b/java-spanneradapter/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-spanneradapter - 0.38.0 + 0.39.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-spanneradapter' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-spanneradapter:0.38.0' +implementation 'com.google.cloud:google-cloud-spanneradapter:0.39.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-spanneradapter" % "0.38.0" +libraryDependencies += "com.google.cloud" % "google-cloud-spanneradapter" % "0.39.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-spanneradapter/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-spanneradapter.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-spanneradapter/0.38.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-spanneradapter/0.39.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-speech/README.md b/java-speech/README.md index 0f688c3fbf71..c5edfb78bc15 100644 --- a/java-speech/README.md +++ b/java-speech/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-speech - 4.97.0 + 4.98.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-speech' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-speech:4.97.0' +implementation 'com.google.cloud:google-cloud-speech:4.98.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-speech" % "4.97.0" +libraryDependencies += "com.google.cloud" % "google-cloud-speech" % "4.98.0" ``` ## Authentication @@ -218,7 +218,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-speech/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-speech.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-speech/4.97.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-speech/4.98.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-storage-transfer/README.md b/java-storage-transfer/README.md index 93a90db4fd11..b4189a0bf936 100644 --- a/java-storage-transfer/README.md +++ b/java-storage-transfer/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-storage-transfer - 1.102.0 + 1.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-storage-transfer' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-storage-transfer:1.102.0' +implementation 'com.google.cloud:google-cloud-storage-transfer:1.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-storage-transfer" % "1.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-storage-transfer" % "1.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-storage-transfer/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-storage-transfer.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-storage-transfer/1.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-storage-transfer/1.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-storage/README.md b/java-storage/README.md index 8744cbf5d95f..d57aa5607997 100644 --- a/java-storage/README.md +++ b/java-storage/README.md @@ -45,12 +45,12 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-storage - 2.78.0 + 2.79.0 com.google.cloud google-cloud-storage-control - 2.78.0 + 2.79.0 ``` @@ -65,13 +65,13 @@ implementation 'com.google.cloud:google-cloud-storage' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-storage:2.78.0' +implementation 'com.google.cloud:google-cloud-storage:2.79.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-storage" % "2.78.0" +libraryDependencies += "com.google.cloud" % "google-cloud-storage" % "2.79.0" ``` ## Authentication @@ -485,7 +485,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-storage/latest/history [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-storage.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-storage/2.78.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-storage/2.79.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-storagebatchoperations/README.md b/java-storagebatchoperations/README.md index bb2bd74e772b..38420184b47c 100644 --- a/java-storagebatchoperations/README.md +++ b/java-storagebatchoperations/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-storagebatchoperations - 0.42.0 + 0.43.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-storagebatchoperations' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-storagebatchoperations:0.42.0' +implementation 'com.google.cloud:google-cloud-storagebatchoperations:0.43.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-storagebatchoperations" % "0.42.0" +libraryDependencies += "com.google.cloud" % "google-cloud-storagebatchoperations" % "0.43.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-storagebatchoperations/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-storagebatchoperations.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-storagebatchoperations/0.42.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-storagebatchoperations/0.43.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-storageinsights/README.md b/java-storageinsights/README.md index f7818fc6e35a..962c4da7b5b9 100644 --- a/java-storageinsights/README.md +++ b/java-storageinsights/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-storageinsights - 0.87.0 + 0.88.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-storageinsights' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-storageinsights:0.87.0' +implementation 'com.google.cloud:google-cloud-storageinsights:0.88.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-storageinsights" % "0.87.0" +libraryDependencies += "com.google.cloud" % "google-cloud-storageinsights" % "0.88.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-storageinsights/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-storageinsights.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-storageinsights/0.87.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-storageinsights/0.88.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-talent/README.md b/java-talent/README.md index be3c4f6119e4..0a3eb0e5a754 100644 --- a/java-talent/README.md +++ b/java-talent/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-talent - 2.103.0 + 2.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-talent' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-talent:2.103.0' +implementation 'com.google.cloud:google-cloud-talent:2.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-talent" % "2.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-talent" % "2.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-talent/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-talent.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-talent/2.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-talent/2.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-tasks/README.md b/java-tasks/README.md index ddf4aacafdaf..aa402eb94046 100644 --- a/java-tasks/README.md +++ b/java-tasks/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-tasks - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-tasks' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-tasks:2.102.0' +implementation 'com.google.cloud:google-cloud-tasks:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-tasks" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-tasks" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-tasks/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-tasks.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-tasks/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-tasks/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-telcoautomation/README.md b/java-telcoautomation/README.md index 7125f424d732..10f54c479ef7 100644 --- a/java-telcoautomation/README.md +++ b/java-telcoautomation/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-telcoautomation - 0.72.0 + 0.73.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-telcoautomation' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-telcoautomation:0.72.0' +implementation 'com.google.cloud:google-cloud-telcoautomation:0.73.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-telcoautomation" % "0.72.0" +libraryDependencies += "com.google.cloud" % "google-cloud-telcoautomation" % "0.73.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-telcoautomation/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-telcoautomation.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-telcoautomation/0.72.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-telcoautomation/0.73.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-texttospeech/README.md b/java-texttospeech/README.md index 01a42c6b498a..82b7cfe71bc4 100644 --- a/java-texttospeech/README.md +++ b/java-texttospeech/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-texttospeech - 2.103.0 + 2.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-texttospeech' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-texttospeech:2.103.0' +implementation 'com.google.cloud:google-cloud-texttospeech:2.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-texttospeech" % "2.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-texttospeech" % "2.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-texttospeech/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-texttospeech.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-texttospeech/2.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-texttospeech/2.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-tpu/README.md b/java-tpu/README.md index 7d13d1eab8e8..dbecfd550816 100644 --- a/java-tpu/README.md +++ b/java-tpu/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-tpu - 2.103.0 + 2.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-tpu' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-tpu:2.103.0' +implementation 'com.google.cloud:google-cloud-tpu:2.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-tpu" % "2.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-tpu" % "2.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-tpu/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-tpu.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-tpu/2.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-tpu/2.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-trace/README.md b/java-trace/README.md index 0b5f3779c65c..08ea48d7aadf 100644 --- a/java-trace/README.md +++ b/java-trace/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-trace - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-trace' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-trace:2.102.0' +implementation 'com.google.cloud:google-cloud-trace:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-trace" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-trace" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-trace/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-trace.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-trace/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-trace/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-translate/README.md b/java-translate/README.md index 6cddba08ee6f..fb74349bea3c 100644 --- a/java-translate/README.md +++ b/java-translate/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-translate - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-translate' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-translate:2.102.0' +implementation 'com.google.cloud:google-cloud-translate:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-translate" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-translate" % "2.103.0" ``` ## Authentication @@ -259,7 +259,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-translate/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-translate.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-translate/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-translate/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-valkey/README.md b/java-valkey/README.md index cc436fe84ae4..b7cbe204740d 100644 --- a/java-valkey/README.md +++ b/java-valkey/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-valkey - 0.48.0 + 0.49.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-valkey' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-valkey:0.48.0' +implementation 'com.google.cloud:google-cloud-valkey:0.49.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-valkey" % "0.48.0" +libraryDependencies += "com.google.cloud" % "google-cloud-valkey" % "0.49.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-memorystore/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-valkey.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-valkey/0.48.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-valkey/0.49.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-vectorsearch/README.md b/java-vectorsearch/README.md index ad84eac6982a..dd959f80538d 100644 --- a/java-vectorsearch/README.md +++ b/java-vectorsearch/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-vectorsearch - 0.24.0 + 0.25.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-vectorsearch' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-vectorsearch:0.24.0' +implementation 'com.google.cloud:google-cloud-vectorsearch:0.25.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-vectorsearch" % "0.24.0" +libraryDependencies += "com.google.cloud" % "google-cloud-vectorsearch" % "0.25.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-vectorsearch/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-vectorsearch.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-vectorsearch/0.24.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-vectorsearch/0.25.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-video-intelligence/README.md b/java-video-intelligence/README.md index 5252dd03267c..be3df25f304e 100644 --- a/java-video-intelligence/README.md +++ b/java-video-intelligence/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-video-intelligence - 2.101.0 + 2.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-video-intelligence' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-video-intelligence:2.101.0' +implementation 'com.google.cloud:google-cloud-video-intelligence:2.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-video-intelligence" % "2.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-video-intelligence" % "2.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-video-intelligence/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-video-intelligence.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-video-intelligence/2.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-video-intelligence/2.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-video-live-stream/README.md b/java-video-live-stream/README.md index 42ef2e97503f..ef89a57d2b34 100644 --- a/java-video-live-stream/README.md +++ b/java-video-live-stream/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-live-stream - 0.104.0 + 0.105.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-live-stream' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-live-stream:0.104.0' +implementation 'com.google.cloud:google-cloud-live-stream:0.105.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-live-stream" % "0.104.0" +libraryDependencies += "com.google.cloud" % "google-cloud-live-stream" % "0.105.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-live-stream/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-live-stream.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-live-stream/0.104.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-live-stream/0.105.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-video-stitcher/README.md b/java-video-stitcher/README.md index 8fef5ab8ed8b..52c0f186f836 100644 --- a/java-video-stitcher/README.md +++ b/java-video-stitcher/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-video-stitcher - 0.102.0 + 0.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-video-stitcher' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-video-stitcher:0.102.0' +implementation 'com.google.cloud:google-cloud-video-stitcher:0.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-video-stitcher" % "0.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-video-stitcher" % "0.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-video-stitcher/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-video-stitcher.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-video-stitcher/0.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-video-stitcher/0.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-video-transcoder/README.md b/java-video-transcoder/README.md index f155dd409786..02759311074b 100644 --- a/java-video-transcoder/README.md +++ b/java-video-transcoder/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-video-transcoder - 1.101.0 + 1.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-video-transcoder' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-video-transcoder:1.101.0' +implementation 'com.google.cloud:google-cloud-video-transcoder:1.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-video-transcoder" % "1.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-video-transcoder" % "1.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-video-transcoder/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-video-transcoder.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-video-transcoder/1.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-video-transcoder/1.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-vision/README.md b/java-vision/README.md index 1a5f4ecc8f6f..d24b23042bef 100644 --- a/java-vision/README.md +++ b/java-vision/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-vision - 3.100.0 + 3.101.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-vision' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-vision:3.100.0' +implementation 'com.google.cloud:google-cloud-vision:3.101.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-vision" % "3.100.0" +libraryDependencies += "com.google.cloud" % "google-cloud-vision" % "3.101.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-vision/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-vision.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-vision/3.100.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-vision/3.101.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-visionai/README.md b/java-visionai/README.md index 1f834580ef79..7ddd2c431cf5 100644 --- a/java-visionai/README.md +++ b/java-visionai/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-visionai - 0.59.0 + 0.60.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-visionai' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-visionai:0.59.0' +implementation 'com.google.cloud:google-cloud-visionai:0.60.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-visionai" % "0.59.0" +libraryDependencies += "com.google.cloud" % "google-cloud-visionai" % "0.60.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-visionai/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-visionai.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-visionai/0.59.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-visionai/0.60.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-vmmigration/README.md b/java-vmmigration/README.md index dab9d4ccec2d..f67056046c73 100644 --- a/java-vmmigration/README.md +++ b/java-vmmigration/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-vmmigration - 1.102.0 + 1.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-vmmigration' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-vmmigration:1.102.0' +implementation 'com.google.cloud:google-cloud-vmmigration:1.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-vmmigration" % "1.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-vmmigration" % "1.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-vmmigration/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-vmmigration.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-vmmigration/1.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-vmmigration/1.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-vmwareengine/README.md b/java-vmwareengine/README.md index 99e99b841f57..91f303d01b33 100644 --- a/java-vmwareengine/README.md +++ b/java-vmwareengine/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-vmwareengine - 0.96.0 + 0.97.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-vmwareengine' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-vmwareengine:0.96.0' +implementation 'com.google.cloud:google-cloud-vmwareengine:0.97.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-vmwareengine" % "0.96.0" +libraryDependencies += "com.google.cloud" % "google-cloud-vmwareengine" % "0.97.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-vmwareengine/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-vmwareengine.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-vmwareengine/0.96.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-vmwareengine/0.97.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-vpcaccess/README.md b/java-vpcaccess/README.md index 07f04cc70fc3..002071b869b0 100644 --- a/java-vpcaccess/README.md +++ b/java-vpcaccess/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-vpcaccess - 2.103.0 + 2.104.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-vpcaccess' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-vpcaccess:2.103.0' +implementation 'com.google.cloud:google-cloud-vpcaccess:2.104.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-vpcaccess" % "2.103.0" +libraryDependencies += "com.google.cloud" % "google-cloud-vpcaccess" % "2.104.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-vpcaccess/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-vpcaccess.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-vpcaccess/2.103.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-vpcaccess/2.104.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-webrisk/README.md b/java-webrisk/README.md index 7b615d950dfd..82cd7a84a6db 100644 --- a/java-webrisk/README.md +++ b/java-webrisk/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-webrisk - 2.101.0 + 2.102.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-webrisk' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-webrisk:2.101.0' +implementation 'com.google.cloud:google-cloud-webrisk:2.102.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-webrisk" % "2.101.0" +libraryDependencies += "com.google.cloud" % "google-cloud-webrisk" % "2.102.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-webrisk/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-webrisk.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-webrisk/2.101.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-webrisk/2.102.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-websecurityscanner/README.md b/java-websecurityscanner/README.md index c26bbaa6171e..2c1b5e0405cf 100644 --- a/java-websecurityscanner/README.md +++ b/java-websecurityscanner/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-websecurityscanner - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-websecurityscanner' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-websecurityscanner:2.102.0' +implementation 'com.google.cloud:google-cloud-websecurityscanner:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-websecurityscanner" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-websecurityscanner" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-websecurityscanner/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-websecurityscanner.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-websecurityscanner/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-websecurityscanner/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-workflow-executions/README.md b/java-workflow-executions/README.md index 86b407a3a849..a4735cef69cd 100644 --- a/java-workflow-executions/README.md +++ b/java-workflow-executions/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-workflow-executions - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-workflow-executions' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-workflow-executions:2.102.0' +implementation 'com.google.cloud:google-cloud-workflow-executions:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-workflow-executions" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-workflow-executions" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-workflow-executions/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-workflow-executions.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workflow-executions/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workflow-executions/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-workflows/README.md b/java-workflows/README.md index 30f8c68cd94c..9de95cf001b6 100644 --- a/java-workflows/README.md +++ b/java-workflows/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-workflows - 2.102.0 + 2.103.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-workflows' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-workflows:2.102.0' +implementation 'com.google.cloud:google-cloud-workflows:2.103.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-workflows" % "2.102.0" +libraryDependencies += "com.google.cloud" % "google-cloud-workflows" % "2.103.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-workflows/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-workflows.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workflows/2.102.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workflows/2.103.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-workloadidentity/README.md b/java-workloadidentity/README.md index e85351cdc828..ee48cfa0ef96 100644 --- a/java-workloadidentity/README.md +++ b/java-workloadidentity/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-workloadidentity - 0.7.0 + 0.8.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-workloadidentity' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-workloadidentity:0.7.0' +implementation 'com.google.cloud:google-cloud-workloadidentity:0.8.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-workloadidentity" % "0.7.0" +libraryDependencies += "com.google.cloud" % "google-cloud-workloadidentity" % "0.8.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-workloadidentity/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-workloadidentity.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workloadidentity/0.7.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workloadidentity/0.8.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-workloadmanager/README.md b/java-workloadmanager/README.md index d03b84c3f767..66d873f24ba4 100644 --- a/java-workloadmanager/README.md +++ b/java-workloadmanager/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-workloadmanager - 0.18.0 + 0.19.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-workloadmanager' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-workloadmanager:0.18.0' +implementation 'com.google.cloud:google-cloud-workloadmanager:0.19.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-workloadmanager" % "0.18.0" +libraryDependencies += "com.google.cloud" % "google-cloud-workloadmanager" % "0.19.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-workloadmanager/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-workloadmanager.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workloadmanager/0.18.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workloadmanager/0.19.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-workspaceevents/README.md b/java-workspaceevents/README.md index 21f2fd872680..ba294d678e04 100644 --- a/java-workspaceevents/README.md +++ b/java-workspaceevents/README.md @@ -44,7 +44,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-workspaceevents - 0.66.0 + 0.67.0 ``` @@ -59,13 +59,13 @@ implementation 'com.google.cloud:google-cloud-workspaceevents' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-workspaceevents:0.66.0' +implementation 'com.google.cloud:google-cloud-workspaceevents:0.67.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-workspaceevents" % "0.66.0" +libraryDependencies += "com.google.cloud" % "google-cloud-workspaceevents" % "0.67.0" ``` ## Authentication @@ -186,7 +186,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-workspaceevents/latest/overview [stability-image]: https://img.shields.io/badge/stability-preview-yellow [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-workspaceevents.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workspaceevents/0.66.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workspaceevents/0.67.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/java-workstations/README.md b/java-workstations/README.md index 6163066e4e88..2010924374d5 100644 --- a/java-workstations/README.md +++ b/java-workstations/README.md @@ -41,7 +41,7 @@ If you are using Maven without the BOM, add this to your dependencies: com.google.cloud google-cloud-workstations - 0.90.0 + 0.91.0 ``` @@ -56,13 +56,13 @@ implementation 'com.google.cloud:google-cloud-workstations' If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-workstations:0.90.0' +implementation 'com.google.cloud:google-cloud-workstations:0.91.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-workstations" % "0.90.0" +libraryDependencies += "com.google.cloud" % "google-cloud-workstations" % "0.91.0" ``` ## Authentication @@ -180,7 +180,7 @@ Java is a registered trademark of Oracle and/or its affiliates. [javadocs]: https://cloud.google.com/java/docs/reference/google-cloud-workstations/latest/overview [stability-image]: https://img.shields.io/badge/stability-stable-green [maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-workstations.svg -[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workstations/0.90.0 +[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-workstations/0.91.0 [authentication]: https://github.com/googleapis/google-cloud-java#authentication [auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes [predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles diff --git a/librarian.yaml b/librarian.yaml index f57ea63ec57f..08cdc3438d23 100644 --- a/librarian.yaml +++ b/librarian.yaml @@ -16,8 +16,8 @@ version: v0.52.0 repo: googleapis/google-cloud-java sources: googleapis: - commit: a74d0502444d12c07abc7ed95f90ebb52950e918 - sha256: 9e619a21b96e142c3d017d9a492463419464677d80026a6bea1809d8217d6ec3 + commit: fc38bc195c0db21fbf363f2b6d824b191e7496d1 + sha256: 9353af8ee98308f265fc6229770b0f9a54ef48e7a1923d6c8f1e13fa66b4c398 showcase: commit: 5158967e8a41c751b15776142d190428ddb7e99f sha256: a31271ff2cdeb7cce91e93a4d58a66dcaaac574c51cc14bd74577ab1eafd3ccd